summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2013-09-25 16:17:13 +0200
committerJonas Smedegaard <dr@jones.dk>2013-09-25 16:35:02 +0200
commit67c0a17c52fad8dc01f4fc8e157fb54a204ad7da (patch)
tree29c5756fe8ad9f5a5fb9788f1dc6821abc7cf532
parent0028cbe6927c6996b7cbf113c265b6bfac279705 (diff)
Use vertical rhythm.
-rw-r--r--style.scss41
1 files changed, 24 insertions, 17 deletions
diff --git a/style.scss b/style.scss
index f7f6d13..b384ce3 100644
--- a/style.scss
+++ b/style.scss
@@ -1,27 +1,31 @@
@import "h5bp";
@import "../shared/themes/default/style";
+@import "compass/typography/vertical_rhythm";
+
+$round-to-nearest-half-line: true;
@include h5bp-normalize;
+@include establish-baseline;
+
h1 {
color: DarkRed;
- font-size: 2em;
+ @include adjust-font-size-to(2 * $base-font-size, 1);
}
h2 {
- font-size: 1.4em;
+ @include adjust-font-size-to(1.4 * $base-font-size, 1.5);
}
h3 {
- font-size: 1.1em;
+ @include adjust-font-size-to(1.1 * $base-font-size, 1.6em / $base-rhythm-unit);
font-weight: bold;
- line-height: 1.6em;
}
h1,
h2,
h3 {
- margin-bottom: 0.1em;
+ @include trailer (.1);
}
h4,
@@ -40,8 +44,7 @@ a {
}
p {
- margin-top: 0.2em;
- margin-bottom: 1.2em;
+ @include rhythm(.2em / $base-rhythm-unit, $trailer: 1.2em / $base-rhythm-unit);
}
em {
@@ -57,7 +60,7 @@ body {
}
div.header {
- padding: 0.5em 0 0 1.5em;
+ padding: rhythm(.5em / $base-rhythm-unit) 0 0 1.5em;
background-color: LightBlue;
color: LightBlue;
}
@@ -66,12 +69,12 @@ span.author,
div.recentchanges,
span.committype,
div#footer {
- font-size: 80%;
+ @include adjust-font-size-to(.8 * $base-font-size);
}
div.pageheader span.title {
color: white;
- font-size: 1.2em;
+ @include adjust-font-size-to(1.2 * $base-font-size, .8);
}
span.parentlinks {
@@ -90,7 +93,7 @@ div.pageheader div.actions {
}
div.actions ul {
- padding: 1em 0 0.5em 2em;
+ padding: rhythm(2/3) 0 rhythm(1/3) 2em;
a {
color: Lightblue;
&:hover {
@@ -101,9 +104,9 @@ div.actions ul {
div#topbar,
div.topbar {
- height: 60px;
+ height: rhythm(2.5);
margin: 0;
- padding: 20px 0;
+ padding: rhythm(20px / $base-line-height) 0;
background-color: LightBlue;
text-align: center;
text-transform: uppercase;
@@ -135,8 +138,7 @@ div.topbar ul,
div.topbar ul li,
div.topbar ol,
div.topbar ol li {
- font-size: 1.1em;
- line-height: 2em;
+ @include adjust-font-size-to(1.1 * $base-font-size, 2em / $base-rhythm-unit);
}
div#topbar img,
@@ -150,6 +152,7 @@ div#pagebody {
width: 100%;
}
+// FIXME: use vertical rhythm
div#content {
min-height: 480px;
max-width: 48em;
@@ -159,6 +162,7 @@ div#content {
background-color: none;
}
+// FIXME: use vertical rhythm
div#content IMG {
display: block;
clear: both;
@@ -178,7 +182,7 @@ div.inlinepage {
}
div.inlinepage SPAN.header a {
- font-size: 0.9em;
+ @include adjust-font-size-to(.9 * $base-font-size);
font-weight: normal;
color: DarkRed;
}
@@ -187,6 +191,7 @@ div.inlinefooter {
display: none;
}
+// FIXME: use vertical rhythm
div#sidebar,
div.sidebar {
float: left;
@@ -236,6 +241,7 @@ div.sidebar ul li SPAN.selflink {
font-weight: bold;
}
+// FIXME: use vertical rhythm
div#farbar,
div.farbar {
float: left;
@@ -257,6 +263,7 @@ div#backlinks {
display: none;
}
+// FIXME: use vertical rhythm
div#footer {
clear: left;
width: 100%;
@@ -266,7 +273,7 @@ div#footer {
div#pageinfo {
margin: 0;
border-top: 0;
- padding:1em 1em 1em 20px;
+ padding: rhythm(1em / $base-rhythm-unit) 1em rhythm(1em / $base-rhythm-unit) 20px;
background-color: LightBlue;
}