Skip to content

Instantly share code, notes, and snippets.

@yavorski
Created October 7, 2013 19:44
Show Gist options
  • Save yavorski/6873760 to your computer and use it in GitHub Desktop.
Save yavorski/6873760 to your computer and use it in GitHub Desktop.
basic normalize, must be configurable ...
*
@extend %bs-border-box
// Prevent iOS text size adjust after orientation change, without disabling user zoom
html
height: 100%
// font-size: 100%
// font-family: sans-serif
background: #fff
-webkit-text-size-adjust: 100%
-ms-text-size-adjust: 100%
-webkit-tap-highlight-color: rgba(0, 0, 0, 0)
body
min-height: 100%
position: relative
margin: 0
color: $base-color
background: rgba(250, 250, 250, 0.5)
// specify font-size and line-height from your project requirements
font: 400 $base-font-size $base-font-family
// Correct 'block' display not defined in IE 8/9.
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
main,
nav,
section,
summary
display: block
// Address `[hidden]` styling not present in IE 8/9.
// Hide the `template` element in IE, Safari, and Firefox < 22.
[hidden]
display: none
// all sort of content links
// again configure this by your's spec
a
color: $link-color
text-decoration: none
&:hover, &:active
outline: 0
&:hover, &:focus
color: $link-color-hover
text-decoration: underline
&:focus
outline: thin dotted #333
outline: 5px auto -webkit-focus-ring-color
outline-offset: -2px
b, strong
font-weight: 700
small
font-size: 80%
sub, sup
position: relative
font-size: 75%
line-height: 0
vertical-align: baseline
sup
top: -0.5em
sub
bottom: -0.25em
hr
// @extend %bs-content-box
clear: both
height: 0
margin: 20px 0
border: 0
border-top: 1px solid #eee
img
display: inline-block
max-width: 100%
height: auto
border: 0
vertical-align: middle
p
margin: 0 0 10px
// headings
// it's nice to define only once your headings per app
h1, .h1
margin: 0 0 20px
font: 400 38px $base-font-family
h2, .h2
margin: 0 0 20px
font: 400 32px $base-font-family
h3, .h3
margin: 0 0 20px
font: 400 24px $base-font-family
h4, .h4
margin: 0 0 10px
font: 400 18px $base-font-family
h5, .h5
margin: 0 0 10px
font: 400 14px $base-font-family
h6, .h6
margin: 0 0 10px
font: 400 12px $base-font-family
ul, ol
margin: 0
list-style: none
table
width: 100%
border-spacing: 0
border-collapse: collapse
background-color: transparent
th
text-align: left
// form elements defaults
input, button, select, textarea
margin: 0
font-size: 100%
line-height: inherit
font-family: inherit
button, input[type="button"], input[type="reset"], input[type="submit"]
cursor: pointer
-webkit-appearance: button
border: none
input[disabled], button[disabled]
cursor: default
input[type="radio"], input[type="checkbox"]
@extend %bs-border-box
padding: 0
line-height: normal
&:focus
outline: thin dotted #333
outline: 5px auto -webkit-focus-ring-color
outline-offset: -2px
input[type="search"]
@extend %bs-border-box
-webkit-appearance: textfield
input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button
-webkit-appearance: none
button::-moz-focus-inner,
input::-moz-focus-inner
padding: 0
border: 0
textarea
overflow: auto
vertical-align: top
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment