Skip to content

Commit 20f821c

Browse files
author
aeoth
committed
Reducing repeated CSS files by having a base.css, cleaner footer
1 parent 07e16ff commit 20f821c

File tree

8 files changed

+212
-203
lines changed

8 files changed

+212
-203
lines changed

_includes/footer.html

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
1-
<div class="footer right">
2-
<ul>
3-
<li><a href="/blog.html">blog</a></li>
4-
<li><a href="/rss.xml"><img src="/img/25.png" /> announcements</a></li>
5-
<li><a href="/projectsrss.xml"><img src="/img/25.png" /> progress logs</a></li>
6-
</ul>
1+
<div id="footerContainer">
2+
<div class="footer">
3+
<ul>
4+
<li><a href="/blog.html">blog</a></li>
5+
<li><a href="/rss.xml"><img src="/img/25.png" /> announcements</a></li>
6+
<li><a href="/projectsrss.xml"><img src="/img/25.png" /> progress logs</a></li>
7+
</ul>
8+
9+
<div id="sponsors">
10+
<h3>sponsors</h3>
11+
<div style="position:relative; display:inline-block; background:#fff url(http://www.jetbrains.com/resharper/features/rs/rs1/rs210x60_white.gif) no-repeat 0 0; border:solid 1px #7d255b; margin:0;padding:0;text-decoration:none;text-indent:0;letter-spacing:-0.001em; width:208px; height:58px"><span style="margin: -1px 0 0 63px;padding: 0;float: left;font-size: 10px;cursor:pointer; background-image:none;border:0;color: #7d255b; font-family: trebuchet ms,arial,sans-serif;font-weight: normal;">Can't live without</span><a href="http://www.jetbrains.com/resharper/features/code_refactoring.html" alt="The best C# &amp; VB.NET refactoring plugin for Visual Studio" title="The best C# & VB.NET refactoring plugin for Visual Studio" style="position:absolute;left:0;margin:0;padding:34px 0 2px 8px;width:200px; line-height:11px;font-size:9px;cursor:pointer; background-image:none;border:none;display:block; color:#7d255b; font-family:tahoma,arial,sans-serif;font-weight: normal;text-decoration:none;">The best C# &amp; VB.NET refactoring plugin for Visual Studio</a></div>
12+
<img src="/img/logo_teamcity.png" />
13+
</div>
14+
</div>
715
</div>

_layouts/layout.html

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2-
<html xmlns="http://www.w3.org/1999/xhtml">
1+
<!DOCTYPE html>
2+
<html>
33
<head>
44
<meta content="en-au" http-equiv="Content-Language" />
55
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
@@ -16,7 +16,6 @@
1616
<body>
1717
<div id="container">
1818
<div id="side">
19-
<a href="/" id="home" title="home" alt="home"><img src="/img/logo.png" alt="Code 52 - a new coding project every week" /></a>
2019
<div id="hometext"><a href="/" >code52</a></div>
2120
<div class="section">
2221
<ul>
@@ -35,7 +34,7 @@
3534
<div id="content">
3635
{{content}}
3736
</div>
38-
3937
</div>
38+
{% include footer.html %}
4039
</body>
4140
</html>

_layouts/splash.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,8 @@ <h2 style="display:inline;">a new coding project every week</h2>
3131

3232
{% include links.html %}
3333
</div>
34-
35-
{% include footer.html %}
3634
</div>
35+
{% include footer.html %}
3736
<script>
3837
var defaults = {
3938
animationDuration: 500,

blog.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,8 @@ layout : layout
33
title : code52
44
---
55

6-
{% include latest_project.html %}
7-
86
<ul class="ideas">
9-
{% for post in site.posts limit:5 %}
7+
{% for post in site.posts limit:1 %}
108
<li>
119
<div class="idea">
1210
{% if forloop.first and post.layout == "post" %}
@@ -43,7 +41,7 @@ title : code52
4341

4442
<h3>OLDER</h3>
4543
<ul class="postArchive">
46-
{% for post in site.posts offset:5 %}
44+
{% for post in site.posts offset:1 %}
4745
<li>
4846
<span class="olderpostdate"> {{ post.date | date: "%d %b" }} </span> <a class="postlink" href="{{ post.id }}">{{ post.title }}</a>
4947
</li>

css/base.css

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
body {
2+
padding:0;
3+
margin:0;
4+
overflow:auto;
5+
font-family: "Segoe UI", "Segoe WP", Helvetica, Arial, sans-serif;
6+
}
7+
8+
#footerContainer {
9+
margin-top:25px;
10+
padding-bottom:25px;
11+
padding-top:25px;
12+
width:100%;
13+
background:#e6e6e6;
14+
}
15+
.footer ul {
16+
margin:0;
17+
padding:0;
18+
}
19+
.footer li
20+
{
21+
margin-right:10px;
22+
display:inline;
23+
list-style-type:none;
24+
}
25+
#sponsors {
26+
27+
margin-top:25px;
28+
}
29+
#sponsors h3 { margin-bottom:15px; }
30+
31+
32+
h1,h2,h3,h4,h5,h6
33+
{
34+
font-family: Segoe UI Light, Segoe WP Light, Segoe UI, Helvetica, sans-serif;
35+
font-weight: 100;
36+
margin-bottom:0px;
37+
}
38+
h1
39+
{
40+
font-size: 4em;
41+
}
42+
h2
43+
{
44+
color: #41b1e1;
45+
font-size: 2.5em;
46+
}
47+
a, a:visited
48+
{
49+
text-decoration: none;
50+
color:#13678b;
51+
}
52+
a:hover
53+
{
54+
color:white;
55+
background: #13678b
56+
}

css/landing.css

Lines changed: 17 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@import url("base.css");
2+
13
div.page {max-width:1000px; margin:auto; overflow:hidden;}
24

35
.rightside {float:right;}
@@ -43,60 +45,25 @@ pre.jush {font-size:9pt; background:#F0F0FF; border:dashed 1px #aaa; padding:10p
4345
pre.jush a {text-decoration:none; }
4446
pre.jush a:hover {text-decoration:underline; }
4547

46-
body {
47-
overflow:auto;
48-
font-family: "Segoe UI", "Segoe WP", Helvetica, Arial, sans-serif;
49-
}
50-
#container
48+
#container
5149
{
5250
max-width:800px;
5351
min-height: 500px;
5452
margin-left:auto;
5553
margin-right:auto;
5654
margin-top:150px;
5755
}
56+
.footer {
57+
max-width:800px;
58+
min-height: 500px;
59+
margin-left:auto;
60+
margin-right:auto;
61+
}
5862
.metro-pivot {
5963
min-height:350px;
6064
margin-left:2px;
6165
}
62-
.footer ul {
63-
margin:0;
64-
padding:0;
65-
}
66-
.footer li
67-
{
68-
margin-right:10px;
69-
display:inline;
70-
list-style-type:none;
71-
}
72-
73-
h1,h2,h3,h4,h5,h6
74-
{
75-
font-family: Segoe UI Light, Segoe WP Light, Segoe UI, Helvetica, sans-serif;
76-
font-weight: 100;
77-
margin-bottom:0px;
78-
}
79-
h1
80-
{
81-
font-size: 4em;
82-
}
83-
h2
84-
{
85-
color: #41b1e1;
86-
margin-left:20px;
87-
font-size: 2.5em;
88-
}
89-
a, a:visited
90-
{
91-
text-decoration: none;
92-
color:#13678b;
93-
}
94-
a:hover
95-
{
96-
color:white;
97-
background: #13678b
98-
}
99-
66+
h2 { margin-left:20px; }
10067
.Tile {
10168
float: left;
10269
margin-right: 10px;
@@ -167,4 +134,10 @@ a:hover
167134
h3 {font-size: 1.25em;}
168135
.metro-pivot .pivot-item h3, .metro-pivot .headers .header { font-size: 125%; display:block; }
169136
ul,li { margin-left:0px; padding:0px;}
170-
}
137+
}
138+
139+
#sponsors {
140+
141+
margin-top:25px;
142+
}
143+
#sponsors h3 { margin-bottom:15px; }

0 commit comments

Comments
 (0)