mirror of
https://github.com/h5bp/html5-boilerplate.git
synced 2026-01-10 15:18:27 -05:00
Converting styles into Sass styles
This commit is contained in:
@@ -1,6 +1 @@
|
||||
* {
|
||||
float: none; /* Screens are not big enough to account for floats */
|
||||
font-size: 80%; /* Slightly reducing font size to reduce need to scroll */
|
||||
background: #fff; /* As much contrast as possible */
|
||||
color: #000;
|
||||
}
|
||||
* { float: none; /* Screens are not big enough to account for floats */ font-size: 80%; /* Slightly reducing font size to reduce need to scroll */ background: white; color: black; /* As much contrast as possible */ }
|
||||
|
||||
252
css/style.css
252
css/style.css
@@ -1,192 +1,104 @@
|
||||
/*
|
||||
reset.css contains both a reset and some base styles.
|
||||
*/
|
||||
|
||||
/*
|
||||
html5doctor.com Reset Stylesheet
|
||||
v1.4 2009-07-27
|
||||
http://html5doctor.com/html-5-reset-stylesheet/
|
||||
Author: Richard Clark - http://richclarkdesign.com
|
||||
*/
|
||||
|
||||
html, body, div, span, object, iframe,
|
||||
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
|
||||
abbr, address, cite, code,
|
||||
del, dfn, em, img, ins, kbd, q, samp,
|
||||
small, strong, sub, sup, var,
|
||||
b, i,
|
||||
dl, dt, dd, ol, ul, li,
|
||||
fieldset, form, label, legend,
|
||||
table, caption, tbody, tfoot, thead, tr, th, td,
|
||||
article, aside, figure, footer, header,
|
||||
hgroup, menu, nav, section, menu,
|
||||
time, mark, audio, video {
|
||||
margin:0;
|
||||
padding:0;
|
||||
border:0;
|
||||
outline:0;
|
||||
font-size:100%;
|
||||
vertical-align:baseline;
|
||||
background:transparent;
|
||||
}
|
||||
|
||||
article, aside, figure, footer, header,
|
||||
hgroup, nav, section { display:block; }
|
||||
|
||||
nav ul { list-style:none; }
|
||||
|
||||
blockquote, q { quotes:none; }
|
||||
|
||||
blockquote:before, blockquote:after,
|
||||
q:before, q:after { content:''; content:none; }
|
||||
|
||||
a { margin:0; padding:0; border:0; font-size:100%; vertical-align:baseline; background:transparent; }
|
||||
|
||||
ins { background-color:#ff9; color:#000; text-decoration:none; }
|
||||
|
||||
mark { background-color:#ff9; color:#000; font-style:italic; font-weight:bold; }
|
||||
|
||||
del { text-decoration: line-through; }
|
||||
|
||||
abbr[title], dfn[title] { border-bottom:1px dotted #000; cursor:help; }
|
||||
|
||||
table { border-collapse:collapse; border-spacing:0; }
|
||||
|
||||
hr { display:block; height:1px; border:0; border-top:1px solid #ccc; margin:1em 0; padding:0; }
|
||||
|
||||
input, select { vertical-align:middle; }
|
||||
|
||||
|
||||
/*
|
||||
fonts.css from the YUI Library: http://developer.yahoo.com/yui/
|
||||
refer to http://developer.yahoo.com/yui/fonts/ for font sizing
|
||||
*/
|
||||
body { font:13px arial,helvetica,"Nimbus Sans L", "Bitstream Vera Sans", sans-serif; *font-size:small; *font:x-small; }
|
||||
|
||||
table { font-size:inherit; font:100%; }
|
||||
|
||||
select, input, textarea { font:99% arial,helvetica,"Nimbus Sans L", "Bitstream Vera Sans", sans-serif; }
|
||||
|
||||
pre, code { font:115% monospace; *font-size:100%; }
|
||||
|
||||
body * { line-height:1.22em; }
|
||||
|
||||
html, body, div, span, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, abbr, address, cite, code, del, dfn, em, img, ins, mark, kbd, q, samp, small, strong, sub, sup, var, b, i, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td, article, aside, figure, footer, header, hgroup, menu, nav, section, menu, time, mark, audio, video { margin: 0; padding: 0; border: 0; outline: 0; font-size: 100%; vertical-align: baseline; background: transparent; }
|
||||
|
||||
/* always force a scrollbar in non-IE */
|
||||
html { overflow-y: scroll; }
|
||||
|
||||
article, aside, figure, footer, header, hgroup, nav, section { display: block; }
|
||||
|
||||
nav ul { list-style: none; }
|
||||
|
||||
blockquote, q { quotes: none; }
|
||||
|
||||
blockquote:before, blockquote:after, q:before, q:after { content: ""; content: none; }
|
||||
|
||||
a { margin: 0; padding: 0; border: 0; font-size: 100%; vertical-align: baseline; background: transparent; /* http://j.mp/webkit-tap-highlight-color */ }
|
||||
a:link { -webkit-tap-highlight-color: rgba(200, 0, 0, 0.4); }
|
||||
|
||||
ins, mark { background-color: #ffff99; color: black; text-decoration: none; }
|
||||
|
||||
mark { font-style: italic; font-weight: bold; }
|
||||
|
||||
del { text-decoration: line-through; }
|
||||
|
||||
abbr[title], dfn[title] { border-bottom: 1px dotted black; cursor: help; }
|
||||
|
||||
table { border-collapse: collapse; border-spacing: 0; }
|
||||
|
||||
hr { display: block; height: 1px; border: 0; border-top: 1px solid #cccccc; margin: 1em 0; padding: 0; }
|
||||
|
||||
input, select { vertical-align: middle; }
|
||||
|
||||
ul { margin-left: 30px; }
|
||||
|
||||
ol { margin-left: 30px; list-style-type: decimal; }
|
||||
|
||||
td, td img { vertical-align: top; }
|
||||
|
||||
/* make buttons play nice in IE: http://www.viget.com/inspire/styling-the-button-element-in-internet-explorer/ */
|
||||
button { width: auto; overflow: visible; }
|
||||
|
||||
button { width: auto; overflow: visible; }
|
||||
|
||||
/* bicubic resizing for non-native sized IMG: http://code.flickr.com/blog/2008/11/12/on-ui-quality-the-little-things-client-side-image-resizing/ */
|
||||
.ie7 img { -ms-interpolation-mode: bicubic; }
|
||||
::-moz-selection, ::selection { background: #ff5e99; color: white; text-shadow: none; }
|
||||
|
||||
/*fonts.css from the YUI Library: http://developer.yahoo.com/yui/ refer to http://developer.yahoo.com/yui/fonts/ for font sizing */
|
||||
body { font: 13px arial, helvetica, "Nimbus Sans L", "Bitstream Vera Sans", sans-serif; line-height: 1.22em; *font-size: small; *font: x-small; }
|
||||
|
||||
table { font-size: inherit; font: 100%; }
|
||||
|
||||
/* styling the basics.
|
||||
original author: paul irish
|
||||
TODO: consider: http://developer.yahoo.com/yui/base/ */
|
||||
|
||||
body, select, input, textarea { color:#444; /* looks better than black: http://twitter.com/H_FJ/statuses/11800719859 */ }
|
||||
|
||||
strong, th, h1,h2,h3,h4,h5,h6 { font-weight: bold; }
|
||||
|
||||
h5 { font-size:85%; margin:8px 0 1px; }
|
||||
h4 { font-size:92%; margin:10px 0 2px; }
|
||||
h3 { font-size:107%; margin:13px 0 3px; }
|
||||
h2 { font-size:122%; margin:15px 0 3px; }
|
||||
h1 { font-size:136%; margin:0 0 10px; }
|
||||
|
||||
p { margin:15px 0 10px; }
|
||||
|
||||
a, a:active { color:#607890; }
|
||||
a:visited { color:#607890; }
|
||||
a:hover { color:#036; }
|
||||
|
||||
ul { margin-left:30px; }
|
||||
ol { margin-left:30px; list-style-type: decimal; }
|
||||
select, input, textarea { font: 99% arial, helvetica, "Nimbus Sans L", "Bitstream Vera Sans", sans-serif; }
|
||||
|
||||
small { font-size:85%; }
|
||||
pre, code { font: 115% monospace; *font-size: 100%; }
|
||||
|
||||
td { vertical-align:top; }
|
||||
td img { vertical-align:top; }
|
||||
/* styling the basics. original author: paul irish */
|
||||
strong, th, h1, h2, h3, h4, h5, h6 { font-weight: bold; }
|
||||
|
||||
/* for image replacement */
|
||||
.ir { display:block; text-indent:-999px; overflow:hidden; background-repeat: none; }
|
||||
h5 { font-size: 85%; margin: 8px 0 1px; }
|
||||
|
||||
h4 { font-size: 92%; margin: 10px 0 2px; }
|
||||
|
||||
h3 { font-size: 107%; margin: 13px 0 3px; }
|
||||
|
||||
h2 { font-size: 122%; margin: 15px 0 3px; }
|
||||
|
||||
h1 { font-size: 136%; margin: 0 0 10px; }
|
||||
|
||||
p { margin: 15px 0 10px; }
|
||||
|
||||
small { font-size: 85%; }
|
||||
|
||||
body, select, input, textarea { color: #444444; }
|
||||
|
||||
a, a:active, a:visited { color: #607890; }
|
||||
|
||||
a:hover { color: #003366; }
|
||||
|
||||
.ir { display: block; text-indent: -999px; overflow: hidden; background-repeat: none; }
|
||||
|
||||
.hidden { display: none; visibility: hidden; }
|
||||
|
||||
.visuallyhidden { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
|
||||
|
||||
.hidden { display:none; visibility:hidden; } /* Hide for both screenreaders and browsers */
|
||||
.visuallyhidden { position:absolute; left:-10000px; top:auto; width:1px; height:1px; overflow:hidden; } /* Hide only visually, but have it available for screenreaders http://www.webaim.org/techniques/css/invisiblecontent/ */
|
||||
.invisible { visibility: hidden; }
|
||||
|
||||
/*
|
||||
===================================
|
||||
>> CSS BUG HACKS <<
|
||||
===================================
|
||||
*/
|
||||
.ie7 img { -ms-interpolation-mode: bicubic; }
|
||||
|
||||
.clearfix:after { content: "."; display: block; height: 0; clear: both; visibility: hidden; }
|
||||
|
||||
.clearfix { display: inline-block; }
|
||||
/* Hides from IE-mac \*/
|
||||
|
||||
* html .clearfix { height: 1%; }
|
||||
|
||||
.clearfix { display: block; }
|
||||
/* End hide from IE-mac */
|
||||
|
||||
/* END RESET CSS */
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
::-moz-selection{ background: #FF5E99; color:#fff; text-shadow: none; }
|
||||
::selection { background:#FF5E99; color:#fff; text-shadow: none; } /* http://twitter.com/miketaylr/status/12228805301 */
|
||||
/* http://j.mp/webkit-tap-highlight-color */
|
||||
a:link { -webkit-tap-highlight-color: #FF5E99; }
|
||||
|
||||
|
||||
/* inline'd print styles avoid required HTTP connection http://www.phpied.com/delay-loading-your-print-css/ */
|
||||
@media print {
|
||||
* { background:transparent !important; color:#444 !important; text-shadow:none; }
|
||||
@media print { * { background: transparent !important; color: #444444 !important; text-shadow: none; }
|
||||
a, a:visited { color: #444444 !important; text-decoration: underline; }
|
||||
a:after { content: " (" attr(href) ")"; }
|
||||
abbr:after { content: " (" attr(title) ")"; }
|
||||
pre, blockquote { border: 1px solid #999999; page-break-inside: avoid; }
|
||||
@page { margin: 0.5cm; }
|
||||
p, h2, h3 { orphans: 3; widows: 3; }
|
||||
h2, h3 { page-break-after: avoid; } }
|
||||
|
||||
a, a:visited { color:#444 !important; text-decoration:underline; }
|
||||
|
||||
a:after { content:" (" attr(href) ")"; }
|
||||
|
||||
abbr:after { content: " (" attr(title) ")"; }
|
||||
|
||||
pre, blockquote { border:1px solid #999; page-break-inside:avoid; }
|
||||
|
||||
@page { margin: 0.5cm; }
|
||||
|
||||
p, h2, h3 { orphans:3; widows:3; }
|
||||
|
||||
h2, h3{ page-break-after:avoid; }
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@media all and (orientation:portrait) {
|
||||
/* Style adjustments for portrait mode goes here */
|
||||
}
|
||||
|
||||
@media all and (orientation:landscape) {
|
||||
/* Style adjustments for landscape mode goes here */
|
||||
}
|
||||
|
||||
@media screen and (max-device-width: 480px) {
|
||||
/* All Capable Mobile Browser (Opera Mobile, iPhone Safari, Android Chrome) CSS goes here */
|
||||
html { -webkit-text-size-adjust:none; } /* Prevent iPhone from adjusting font size */
|
||||
}
|
||||
@media all and (orientation:portrait) {}
|
||||
@media all and (orientation:landscape) {}
|
||||
@media screen and (max-device-width: 480px) { html { -webkit-text-size-adjust: none; } }
|
||||
|
||||
15
src/_colors.sass
Normal file
15
src/_colors.sass
Normal file
@@ -0,0 +1,15 @@
|
||||
// looks better than black: http://twitter.com/H_FJ/statuses/11800719859
|
||||
$bodytextcolor: #444
|
||||
$linkcolor: #607890
|
||||
$linkhovercolor: #036
|
||||
|
||||
body, select, input, textarea
|
||||
color: $bodytextcolor
|
||||
|
||||
a, a:active, a:visited
|
||||
color: $linkcolor
|
||||
|
||||
a:hover
|
||||
color: $linkhovercolor
|
||||
|
||||
|
||||
52
src/_fonts.sass
Normal file
52
src/_fonts.sass
Normal file
@@ -0,0 +1,52 @@
|
||||
/*fonts.css from the YUI Library: http://developer.yahoo.com/yui/ refer to http://developer.yahoo.com/yui/fonts/ for font sizing */
|
||||
body
|
||||
font: 13px arial, helvetica, "Nimbus Sans L", "Bitstream Vera Sans", sans-serif
|
||||
line-height: 1.22em
|
||||
*font-size: small
|
||||
*font: x-small
|
||||
|
||||
table
|
||||
font-size: inherit
|
||||
font: 100%
|
||||
|
||||
select, input, textarea
|
||||
font: 99% arial, helvetica, "Nimbus Sans L", "Bitstream Vera Sans", sans-serif
|
||||
|
||||
pre, code
|
||||
font: 115% monospace
|
||||
*font-size: 100%
|
||||
|
||||
/* styling the basics.
|
||||
original author: paul irish */
|
||||
// TODO: consider: http://developer.yahoo.com/yui/base/
|
||||
|
||||
strong, th, h1, h2, h3, h4, h5, h6
|
||||
font-weight: bold
|
||||
|
||||
//TODO (Divya): Vertical Rhythm?
|
||||
|
||||
h5
|
||||
font-size: 85%
|
||||
margin: 8px 0 1px
|
||||
|
||||
h4
|
||||
font-size: 92%
|
||||
margin: 10px 0 2px
|
||||
|
||||
h3
|
||||
font-size: 107%
|
||||
margin: 13px 0 3px
|
||||
|
||||
h2
|
||||
font-size: 122%
|
||||
margin: 15px 0 3px
|
||||
|
||||
h1
|
||||
font-size: 136%
|
||||
margin: 0 0 10px
|
||||
|
||||
p
|
||||
margin: 15px 0 10px
|
||||
|
||||
small
|
||||
font-size: 85%
|
||||
102
src/_reset.sass
Normal file
102
src/_reset.sass
Normal file
@@ -0,0 +1,102 @@
|
||||
html, body, div, span, object, iframe,
|
||||
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
|
||||
abbr, address, cite, code,
|
||||
del, dfn, em, img, ins, kbd, q, samp,
|
||||
small, strong, sub, sup, var,
|
||||
b, i,
|
||||
dl, dt, dd, ol, ul, li,
|
||||
fieldset, form, label, legend,
|
||||
table, caption, tbody, tfoot, thead, tr, th, td,
|
||||
article, aside, figure, footer, header,
|
||||
hgroup, menu, nav, section, menu,
|
||||
time, mark, audio, video
|
||||
margin: 0
|
||||
padding: 0
|
||||
border: 0
|
||||
outline: 0
|
||||
font-size: 100%
|
||||
vertical-align: baseline
|
||||
background: transparent
|
||||
|
||||
/* always force a scrollbar in non-IE */
|
||||
html
|
||||
overflow-y: scroll
|
||||
|
||||
article, aside, figure, footer, header, hgroup, nav, section
|
||||
display: block
|
||||
|
||||
nav ul
|
||||
list-style: none
|
||||
|
||||
blockquote, q
|
||||
quotes: none
|
||||
|
||||
blockquote:before, blockquote:after,
|
||||
q:before, q:after
|
||||
content: ''
|
||||
content: none
|
||||
|
||||
a
|
||||
margin: 0
|
||||
padding: 0
|
||||
border: 0
|
||||
font-size: 100%
|
||||
vertical-align: baseline
|
||||
background: transparent
|
||||
|
||||
/* http://j.mp/webkit-tap-highlight-color */
|
||||
&:link
|
||||
-webkit-tap-highlight-color: rgba(200,0,0,0.4)
|
||||
|
||||
ins
|
||||
background-color: #ff9
|
||||
color: #000
|
||||
text-decoration: none
|
||||
|
||||
mark
|
||||
@extend ins
|
||||
font-style: italic
|
||||
font-weight: bold
|
||||
|
||||
del
|
||||
text-decoration: line-through
|
||||
|
||||
abbr[title], dfn[title]
|
||||
border-bottom: 1px dotted #000
|
||||
cursor: help
|
||||
|
||||
table
|
||||
border-collapse: collapse
|
||||
border-spacing: 0
|
||||
|
||||
hr
|
||||
display: block
|
||||
height: 1px
|
||||
border: 0
|
||||
border-top: 1px solid #ccc
|
||||
margin: 1em 0
|
||||
padding: 0
|
||||
|
||||
input, select
|
||||
vertical-align: middle
|
||||
|
||||
ul
|
||||
margin-left: 30px
|
||||
ol
|
||||
margin-left: 30px
|
||||
list-style-type: decimal
|
||||
|
||||
td, td img
|
||||
vertical-align: top
|
||||
|
||||
/* make buttons play nice in IE: http://www.viget.com/inspire/styling-the-button-element-in-internet-explorer/ */
|
||||
button
|
||||
width: auto
|
||||
overflow: visible
|
||||
|
||||
::-moz-selection,
|
||||
::selection
|
||||
background: #FF5E99
|
||||
color: #fff
|
||||
// http://twitter.com/miketaylr/status/12228805301
|
||||
text-shadow: none
|
||||
12
src/mobile.sass
Normal file
12
src/mobile.sass
Normal file
@@ -0,0 +1,12 @@
|
||||
*
|
||||
float: none
|
||||
/* Screens are not big enough to account for floats
|
||||
|
||||
font-size: 80%
|
||||
/* Slightly reducing font size to reduce need to scroll
|
||||
|
||||
background: #fff
|
||||
color: #000
|
||||
/* As much contrast as possible
|
||||
|
||||
|
||||
102
src/style.sass
Normal file
102
src/style.sass
Normal file
@@ -0,0 +1,102 @@
|
||||
@import reset.sass
|
||||
|
||||
@import fonts.sass
|
||||
|
||||
@import colors.sass
|
||||
|
||||
// for image replacement
|
||||
.ir
|
||||
display: block
|
||||
text-indent: -999px
|
||||
overflow: hidden
|
||||
background-repeat: none
|
||||
|
||||
// Hide for both screenreaders and browsers
|
||||
.hidden
|
||||
display: none
|
||||
visibility: hidden
|
||||
|
||||
// Hide only visually, but have it available for screenreaders http://www.webaim.org/techniques/css/invisiblecontent/
|
||||
.visuallyhidden
|
||||
position: absolute
|
||||
left: -10000px
|
||||
top: auto
|
||||
width: 1px
|
||||
height: 1px
|
||||
overflow: hidden
|
||||
|
||||
.invisible
|
||||
visibility: hidden
|
||||
|
||||
|
||||
// bicubic resizing for non-native sized IMG: http://code.flickr.com/blog/2008/11/12/on-ui-quality-the-little-things-client-side-image-resizing/
|
||||
.ie7 img
|
||||
-ms-interpolation-mode: bicubic
|
||||
|
||||
|
||||
//===================================
|
||||
//>> CSS BUG HACKS <<
|
||||
//===================================
|
||||
.clearfix:after
|
||||
content: "."
|
||||
display: block
|
||||
height: 0
|
||||
clear: both
|
||||
visibility: hidden
|
||||
|
||||
.clearfix
|
||||
display: inline-block /* Hides from IE-mac \*/
|
||||
|
||||
* html .clearfix
|
||||
height: 1%
|
||||
|
||||
.clearfix
|
||||
display: block
|
||||
|
||||
|
||||
|
||||
/* inline'd print styles avoid required HTTP connection http://www.phpied.com/delay-loading-your-print-css/ */
|
||||
@media print
|
||||
*
|
||||
background: transparent !important
|
||||
color: #444 !important
|
||||
text-shadow: none
|
||||
|
||||
a, a:visited
|
||||
color: #444 !important
|
||||
text-decoration: underline
|
||||
|
||||
a:after
|
||||
content: " (" attr(href) ")"
|
||||
|
||||
abbr:after
|
||||
content: " (" attr(title) ")"
|
||||
|
||||
pre, blockquote
|
||||
border: 1px solid #999
|
||||
page-break-inside: avoid
|
||||
|
||||
@page
|
||||
margin: 0.5cm
|
||||
|
||||
p, h2, h3
|
||||
orphans: 3
|
||||
widows: 3
|
||||
|
||||
h2, h3
|
||||
page-break-after: avoid
|
||||
|
||||
|
||||
@media all and (orientation:portrait)
|
||||
// Style adjustments for portrait mode goes here
|
||||
|
||||
|
||||
@media all and (orientation:landscape)
|
||||
// Style adjustments for landscape mode goes here
|
||||
|
||||
|
||||
@media screen and (max-device-width: 480px)
|
||||
//All Capable Mobile Browser (Opera Mobile, iPhone Safari, Android Chrome) CSS goes here
|
||||
html
|
||||
// Prevent iPhone from adjusting font size
|
||||
-webkit-text-size-adjust: none
|
||||
Reference in New Issue
Block a user