Skip to content

Commit c27b361

Browse files
committed
added most recent announce/practice on front pg
- alerts for most recent announcement and practice - cleaned up css further
1 parent 6a7d5eb commit c27b361

8 files changed

+188
-71
lines changed

README.md

+8-6
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,26 @@ Please branch and commit responsibly. The master branch should stay empty, and t
1212
- Front page
1313
- Learn page
1414
- Contact page
15+
- Announcements+Practices pages
16+
- Posting to Announcements and Practices
1517

1618
# Current Working Build
1719
[http://acm-uiuc.github.io/icpc-website/](http://acm-uiuc.github.io/icpc-website/)
1820

1921
# @todo by descending priority
2022
Please follow the spec for page and functionality requirements.
2123

22-
1. working Announcements and Practice pages (jekyll posts; contents.html is the template)
23-
1. working posts and posts template for Announcements and Practice
24+
1. ~~working Announcements and Practice pages (jekyll posts; contents.html is the template)~~
25+
1. ~~working posts and posts template for Announcements and Practice~~
2426
1. working Calendar page (preferably with styled Google Calendar)
25-
1. alert on Front page with most recent announcement
26-
1. test posts
27+
1. ~~alert on Front page with most recent announcement+practice~~
28+
1. ~~test posts~~
2729
1. responsiveness for different **computer** screen sizes (forget mobile for now)
2830
1. choose fonts and colors
29-
1. refactor css, layouts
31+
1. ~~refactor css, layouts~~
3032
1. rename pages?
3133
1. continue expanding site spec
3234
1. logo
33-
1. warbanner image - **at this point the site is completed**
35+
1. warbanner image
3436
1. add instructions for content creators
3537
1. real documentation for future maintainers

_includes/head.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<meta name="viewport" content="width=device-width">
66

77
<!-- brick.im fonts -->
8-
<link rel="stylesheet" href="//brick.a.ssl.fastly.net/Source+Code Pro:400">
8+
<link rel="stylesheet" href="//brick.a.ssl.fastly.net/Source+Code Pro:400,700">
99

1010
<!-- typography fonts -->
1111
<link rel="stylesheet" type="text/css" href="{{ site.baseurl }}/css/typo.css">

_layouts/default.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
{% include head.html %}
44
<body>
55
{% include navbar.html %}
6-
76
{% if page.title == "ICPC" %}
87
<div class="warbanner"></div>
98
{% endif %}
10-
119
<div class="site">
12-
{{ content }}
10+
<div class="resources">
11+
{{ content }}
12+
</div>
1313
</div>
1414
</body>
1515
</html>

_posts/2014-12-12-first-practice.md

+9
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,15 @@ timeam.
1515

1616
{% highlight ruby linenos %}
1717
def show
18+
# test multiple digit lines
19+
# test
20+
# test
21+
# test
22+
# test
23+
# test
24+
# test
25+
# test
26+
# test
1827
@widget = Widget(params[:id])
1928
respond_to do |format|
2029
format.html # show.html.erb

announcements.html

+11-11
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
---
2-
layout: posts
2+
layout: default
33
title: Announcements
44
---
55

66
{% for announcement in site.categories["announcements"] %}
77
<div class="resource">
8-
<a href="{{ site.baseurl }}{{ announcement.url }}">
9-
<h2 class="title">{{ announcement.title }}</h2>
10-
<div class="link">
11-
{{ announcement.time }} • {{ announcement.date | date: "%b %-d, %Y" }}
12-
</div>
13-
<div class="fa fa-comment"></div>
14-
<div>
15-
{{ announcement.content | strip_html | truncatewords:30 }}
16-
</div>
17-
</a>
8+
<a href="{{ site.baseurl }}{{ announcement.url }}">
9+
<h2 class="title">{{ announcement.title }}</h2>
10+
<div class="link">
11+
{{ announcement.time }} • {{ announcement.date | date: "%b %-d, %Y" }}
12+
</div>
13+
<div class="fa fa-comment"></div>
14+
<div>
15+
{{ announcement.content | strip_html | truncatewords:30 }}
16+
</div>
17+
</a>
1818
</div>
1919
{% endfor %}

css/main.css

+68-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,65 @@
1+
.alert {
2+
margin-right: 4.5em;
3+
margin-left: 4.5em;
4+
padding-top: 1em;
5+
border-radius: 3px;
6+
font-size: 16px;
7+
font-family: "Source Code Pro";
8+
}
9+
10+
.alert > .head {
11+
display: inline;
12+
margin-left: 1.5em;
13+
}
14+
15+
.alert > .head > .fa {
16+
float: right;
17+
margin-right: 1.5em;
18+
}
19+
20+
.alert > .body {
21+
margin-top: 1em;
22+
margin-bottom: 1em;
23+
margin-left: 1.5em;
24+
margin-right: 1.5em;
25+
}
26+
27+
.alert > .body > h2 {
28+
margin-bottom: .25em;
29+
}
30+
31+
.announcement {
32+
margin-bottom: 1em;
33+
border: solid 1px #bce8f1;
34+
background-color: #d9edf7;
35+
color: #31708f;
36+
}
37+
38+
.announcement > .head {
39+
padding-bottom: .5em;
40+
border-bottom: solid 1px #bce8f1;
41+
}
42+
43+
.announcement > .head > .fa {
44+
color: #31708f;
45+
}
46+
47+
.practice {
48+
margin-bottom: 3em;
49+
border: solid 1px #d6e9c6;
50+
background-color: #dff0d8;
51+
color: #3c763d;
52+
}
53+
54+
.practice > .head {
55+
padding-bottom: .5em;
56+
border-bottom: solid 1px #d6e9c6;
57+
}
58+
59+
.practice > .head > .fa {
60+
color: #3c763d;
61+
}
62+
163
.navlist > .item > .navlink, .navlist > .item > .brand {
264
display: table-cell;
365
vertical-align: middle;
@@ -48,13 +110,17 @@
48110
background: #333;
49111
}
50112

51-
*/
52113
.post pre.terminal {
53114
border: 1px solid #000;
54115
background: #333;
55116
color: #fff;
56117
}
57118

119+
pre .lineno {
120+
padding-right: 5px;
121+
border-right: solid 1px #aaa;
122+
}
123+
58124
.navbar {
59125
border-bottom: solid 10px #7c75fa;
60126
background: #5856d6;
@@ -63,6 +129,7 @@
63129
.navbar > .navlist-bg > .navlist > .item > .navlink > *,
64130
.navbar > .navlist-bg > .navlist > .item > h1.brand > a {
65131
color: #fff;
132+
font-weight: normal;
66133
font-family: "Source Code Pro";
67134
}
68135

@@ -283,7 +350,6 @@ p {
283350
}
284351

285352
.post code {
286-
padding: 0 .2em;
287353
border: 1px solid #ddd;
288354
background: #eef;
289355
}

index.html

+71-31
Original file line numberDiff line numberDiff line change
@@ -3,34 +3,74 @@
33
title: ICPC
44
---
55

6-
<ul class="about">
7-
<li>
8-
<br>
9-
<h2 class="title">The Competition</h2>
10-
<p class="info">
11-
ICPC is an annual algorithmic programming competition where
12-
teams of three college students compete to solve as many challenging
13-
programming problems as they can within 5 hours. ICPC is separated
14-
into two stages: <b>regional</b> and <b>world finals</b>. The top 3
15-
teams in each region advance to the world finals, which
16-
are held in a different country each year.
17-
</p>
18-
</li>
19-
<hr>
20-
<li>
21-
<br>
22-
<h2 class="title">The Group</h2>
23-
<p class="info">
24-
SIGICPC is for anyone who likes competitive programming, but is
25-
particularly targeted towards those who want to do well in
26-
the competition. We meet every week to practice solving
27-
challenging problems. Being able to solve challenging
28-
problems is particularly helpful for technical interviews as well.
29-
</p>
30-
<p class="info">
31-
In the past 10 years, our school has advanced to world finals 8 times.
32-
</p>
33-
</li>
34-
<hr>
35-
<br>
36-
</ul>
6+
{% for announcement in site.categories["announcements"] limit:1 %}
7+
<a href="{{ site.baseurl }}{{ announcement.url }}">
8+
<div class="alert announcement">
9+
<div class="head">
10+
Hey! Our latest announcement was on <b>{{ announcement.date | date: "%b %-d, %Y" }}</b>.
11+
<div class="fa fa-comment fa-lg"></div>
12+
</div>
13+
<div class="body">
14+
<h2>{{ announcement.title }}</h2>
15+
<div>
16+
{% if announcement.description %}
17+
{{ announcement.description }}
18+
{% else %}
19+
{{ announcement.content | strip_html | truncatewords:30 }}
20+
{% endif %}
21+
</div>
22+
</div>
23+
</div>
24+
</a>
25+
{% endfor %}
26+
27+
{% for practice in site.categories["practices"] limit:1 %}
28+
<a href="{{ site.baseurl }}{{ practice.url }}">
29+
<div class="alert practice">
30+
<div class="head">
31+
Review the latest practice from <b>{{ practice.date | date: "%b %-d, %Y" }}</b>.
32+
<div class="fa fa-code fa-lg"></div>
33+
</div>
34+
<div class="body">
35+
<h2>{{ practice.title }}</h2>
36+
<div>
37+
{% if practice.description %}
38+
{{ practice.description }}
39+
{% else %}
40+
{{ practice.content | strip_html | truncatewords:30 }}
41+
{% endif %}
42+
</div>
43+
</div>
44+
</div>
45+
</a>
46+
{% endfor %}
47+
48+
<div class="resource">
49+
<a>
50+
<h2 class="title">The Competition</h2>
51+
<div>
52+
ICPC is an annual algorithmic programming competition where
53+
teams of three college students compete to solve as many challenging
54+
programming problems as they can within 5 hours. ICPC is separated
55+
into two stages: <b>regional</b> and <b>world finals</b>. The top 3
56+
teams in each region advance to the world finals, which
57+
are held in a different country each year.
58+
</div>
59+
</a>
60+
</div>
61+
62+
<div class="resource">
63+
<a>
64+
<h2 class="title">The Group</h2>
65+
<div>
66+
SIGICPC is for anyone who likes competitive programming, but is
67+
particularly targeted towards those who want to do well in
68+
the competition. We meet every week to practice solving
69+
challenging problems. Being able to solve challenging
70+
problems is particularly helpful for technical interviews as well.
71+
</div>
72+
<div>
73+
In the past 10 years, our school has advanced to world finals 8 times.
74+
</div>
75+
</a>
76+
</div>

practices.html

+17-17
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
---
2-
layout: posts
2+
layout: default
33
title: Practices
44
---
55

66
{% for practice in site.categories["practices"] %}
7-
<div class="resource">
8-
<a href="{{ site.baseurl }}{{ practice.url }}">
9-
<h2 class="title">{{ practice.title }}</h2>
10-
<div class="link">
11-
{{ practice.time }} • {{ practice.date | date: "%b %-d, %Y" }}
12-
</div>
13-
<div class="fa fa-code"></div>
14-
<div>
15-
{% if practice.description %}
16-
{{ practice.description }}
17-
{% else %}
18-
{{ practice.content | strip_html | truncatewords:30 }}
19-
{% endif %}
20-
</div>
21-
</a>
22-
</div>
7+
<div class="resource">
8+
<a href="{{ site.baseurl }}{{ practice.url }}">
9+
<h2 class="title">{{ practice.title }}</h2>
10+
<div class="link">
11+
{{ practice.time }} • {{ practice.date | date: "%b %-d, %Y" }}
12+
</div>
13+
<div class="fa fa-code"></div>
14+
<div>
15+
{% if practice.description %}
16+
{{ practice.description }}
17+
{% else %}
18+
{{ practice.content | strip_html | truncatewords:30 }}
19+
{% endif %}
20+
</div>
21+
</a>
22+
</div>
2323
{% endfor %}

0 commit comments

Comments
 (0)