hacks-guide-minimal-mistake.../_sass/typography.scss

147 lines
2.5 KiB
SCSS
Raw Normal View History

2013-09-07 08:44:10 -04:00
// Headings
// --------------------------------------------------
2013-05-24 10:25:31 -04:00
h1, h2, h3, h4, h5, h6 {
2014-07-31 13:09:32 -04:00
font-family: $heading-font;
2013-05-24 10:25:31 -04:00
}
2013-09-07 08:44:10 -04:00
h1 {
2014-07-31 13:09:32 -04:00
@include font-size(32);
2013-09-07 11:59:02 -04:00
}
h2 {
2014-07-31 13:09:32 -04:00
@include font-size(28);
2013-09-07 11:59:02 -04:00
}
h3 {
2014-07-31 13:09:32 -04:00
@include font-size(24);
2013-09-07 11:59:02 -04:00
}
h4 {
2014-07-31 13:09:32 -04:00
@include font-size(18);
2013-09-07 11:59:02 -04:00
}
h5 {
2014-07-31 13:09:32 -04:00
@include font-size(16);
2013-09-07 11:59:02 -04:00
}
h6 {
2014-07-31 13:09:32 -04:00
@include font-size(14);
2013-05-24 10:25:31 -04:00
}
2013-09-07 08:44:10 -04:00
// Links
// --------------------------------------------------
2013-05-24 10:25:31 -04:00
a {
text-decoration: none;
2014-07-31 13:09:32 -04:00
color: $link-color;
2013-05-24 10:25:31 -04:00
&:visited {
2014-07-31 13:09:32 -04:00
color: $linkcolorvisited;
2013-05-24 10:25:31 -04:00
}
&:hover {
2014-07-31 13:09:32 -04:00
color: $linkcolorhover;
2013-05-24 10:25:31 -04:00
}
&:focus {
outline: thin dotted;
2014-07-31 13:09:32 -04:00
color: $linkcolorfocus;
2013-05-24 10:25:31 -04:00
}
&:hover,
&:active {
outline: 0;
}
}
2013-09-07 08:44:10 -04:00
// Figures
// --------------------------------------------------
figcaption {
padding-top: 10px;
2014-07-31 13:09:32 -04:00
@include font(14);
2013-09-07 08:44:10 -04:00
line-height: 1.3;
2014-07-31 13:09:32 -04:00
color: lighten($text-color, 10);
2013-05-24 10:25:31 -04:00
}
2013-09-07 08:44:10 -04:00
// Feature Image Caption
// --------------------------------------------------
.image-credit {
2014-07-31 13:09:32 -04:00
@include grid(12,10);
@include prefix(12,1);
@include suffix(12,1);
display: block;
2013-09-07 08:44:10 -04:00
text-align: right;
2014-07-31 13:09:32 -04:00
@include font(12);
2013-09-07 08:44:10 -04:00
line-height: 1.3;
font-style: italic;
2014-07-31 13:09:32 -04:00
color: lighten($text-color, 30);
@media #{$small} {
@include grid(12,9);
@include prefix(12,0);
@include suffix(12,0);
}
2014-07-31 13:09:32 -04:00
@media #{$x-large} {
@include grid(12,8.5);
}
2013-09-07 08:44:10 -04:00
a {
2014-07-31 13:09:32 -04:00
color: lighten($text-color, 30);
2013-05-24 10:25:31 -04:00
}
}
2013-09-07 08:44:10 -04:00
// Note text
// --------------------------------------------------
2013-05-24 10:25:31 -04:00
.notice {
margin-top: 1.5em;
padding: .5em 1em;
text-indent: 0;
2014-07-31 13:09:32 -04:00
@include font-rem(14);
background-color: $body-color;
border: 1px solid darken($body-color,20);
@include rounded(3px);
2013-05-24 10:25:31 -04:00
}
2013-09-07 08:44:10 -04:00
// Blockquotes
// --------------------------------------------------
2013-05-24 10:25:31 -04:00
blockquote {
2013-09-07 08:44:10 -04:00
margin-left: -28px;
padding-left: 20px;
2014-07-31 13:09:32 -04:00
border-left: 8px solid $border-color;
font-family: $alt-font;
2013-05-24 10:25:31 -04:00
font-style: italic;
}
2013-09-07 08:44:10 -04:00
// Footnotes
// --------------------------------------------------
2013-09-07 12:57:20 -04:00
.footnotes {
2013-09-07 08:44:10 -04:00
ol, li, p {
2013-12-09 09:32:40 -05:00
margin-bottom: 0;
2014-07-31 13:09:32 -04:00
@include font-rem(14);
2013-09-07 08:44:10 -04:00
}
2013-06-30 15:41:53 -04:00
}
2013-09-07 08:44:10 -04:00
2013-09-07 10:10:55 -04:00
// Paragraphs
// --------------------------------------------------
p {
2014-07-31 13:09:32 -04:00
margin: 0 0 $indent-var;
// sibling indentation
@if $paragraph-indent == true {
& + p {
text-indent: $indent-var;
margin-top: -($indent-var);
}
2013-09-07 10:10:55 -04:00
}
}
2013-09-07 08:44:10 -04:00
// Code
// --------------------------------------------------
2013-06-30 15:41:53 -04:00
tt, code, kbd, samp, pre {
2014-07-31 13:09:32 -04:00
font-family: $code-font;
2013-09-07 08:44:10 -04:00
}
p,
li {
code {
2014-07-31 13:09:32 -04:00
@include font-rem(12);
2013-09-07 08:44:10 -04:00
line-height: 1.5;
white-space: nowrap;
margin: 0 2px;
padding: 0 5px;
2014-07-31 13:09:32 -04:00
border: 1px solid lighten($black, 90);
2013-09-09 11:56:09 -04:00
background-color: #efefef;
2014-07-31 13:09:32 -04:00
@include rounded(3px);
2013-09-07 08:44:10 -04:00
}
}
pre {
2014-07-31 13:09:32 -04:00
@include font-rem(12);
2013-09-07 08:44:10 -04:00
line-height: 1.5;
overflow-x: auto;
2013-06-30 15:41:53 -04:00
}