1
- // converted from HTML5 Boilerplate - pre-release w/ normalization - 06/28/11
1
+ // converted from HTML5 Boilerplate v2.0 - 08/10/2011
2
2
3
3
// Default colors
4
- $h5bp-text-selection : #FF5E99 !default
5
- $h5bp-webkit-tap : #FF5E99 !default
4
+ $h5bp-text-selection : #fe57a1 !default
5
+ $h5bp-webkit-tap : #fe57a1 !default
6
6
$h5bp-link : #00e !default
7
- $h5bp-visited-link : #551a8b !default
7
+ $h5bp-link-hover : #06e !default
8
+ $h5bp-link-visited : #551a8b !default
8
9
9
10
// HTML5 ✰ Boilerplate
10
11
//
11
12
// What follows is the result of much research on cross-browser styling.
12
13
// Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
13
14
// Kroc Camen, and the H5BP dev community and team.
15
+ //
16
+ // Detailed information about this CSS: h5bp.com/css
14
17
15
18
16
19
// ==========================================================================
17
- // HTML5 element display
20
+ // HTML5 display definitions
18
21
// ==========================================================================
19
22
20
23
article , aside , details , figcaption , figure , footer , header , hgroup , nav , section
21
24
display : block
22
- audio [controls] , canvas , video
25
+ audio , canvas , video
23
26
display : inline-block
24
27
* display: inline
25
28
* zoom: 1
26
-
29
+ audio :not ([controls ])
30
+ display : none
31
+ [hidden]
32
+ display : none
27
33
28
34
// ==========================================================================
29
35
// Base
30
36
// ==========================================================================
31
37
32
38
// 1. Correct text resizing oddly in IE6/7 when body font-size is set using em units
33
- // http://clagnut.com/blog/348/#c790
34
39
// 2. Force vertical scrollbar in non-IE
35
- // 3. Remove Android and iOS tap highlight color to prevent entire container being highlighted
36
- // www.yuiblog.com/blog/2010/10/01/quick-tip-customizing-the-mobile-safari-tap-highlight-color/
37
- // 4. Prevent iOS text size adjust on device orientation change, without disabling user zoom
38
- // www.456bereastreet.com/archive/201012/controlling_text_size_in_safari_for_ios_without_disabling_user_zoom/
39
-
40
+ // 3. Prevent iOS text size adjust on device orientation change, without disabling user zoom: h5bp.com/g
40
41
html
41
42
font-size : 100%
42
43
overflow-y : scroll
43
- -webkit-tap-highlight-color : $h5bp-text-selection
44
44
-webkit-text-size-adjust : 100%
45
45
-ms-text-size-adjust : 100%
46
46
@@ -53,10 +53,9 @@ body, button, input, select, textarea
53
53
font-family : sans-serif
54
54
color : #222
55
55
56
+ // Remove text-shadow in selection highlight: h5bp.com/i
56
57
// These selection declarations have to be separate
57
- // No text-shadow: twitter.com/miketaylr/status/12228805301
58
- // Also: hot pink!
59
-
58
+ // Also: hot pink! (or customize the background color to match your design)
60
59
::-moz-selection
61
60
background : $h5bp-text-selection
62
61
color : #fff
@@ -74,11 +73,13 @@ body, button, input, select, textarea
74
73
a
75
74
color : $h5bp-link
76
75
& :visited
77
- color : $h5bp-visited-link
76
+ color : $h5bp-link-visited
77
+ & :hover
78
+ color : $h5bp-link-hover
78
79
& :focus
79
80
outline : thin dotted
80
81
81
- // Improve readability when focused and hovered in all browsers: people.opera. com/patrickl/experiments/keyboard/test
82
+ // Improve readability when focused and hovered in all browsers: h5bp. com/h
82
83
& :hover , & :active
83
84
outline : 0
84
85
118
119
font-style : italic
119
120
font-weight : bold
120
121
121
- // Redeclare monospace font family: en.wikipedia.org/wiki/User:Davidgothberg/Test59
122
+ // Redeclare monospace font family: h5bp.com/j
122
123
pre , code , kbd , samp
123
124
font-family : monospace , monospace
124
125
_font-family: 'courier new', monospace
139
140
small
140
141
font-size : 85%
141
142
142
- // Position subscript and superscript content without affecting line-height: gist.github. com/413930
143
+ // Position subscript and superscript content without affecting line-height: h5bp. com/k
143
144
sub , sup
144
145
font-size : 75%
145
146
line-height : 0
162
163
margin : 0 0 0 40px
163
164
nav ul , nav ol
164
165
list-style : none
166
+ list-style-image : none
165
167
margin : 0
166
168
padding : 0
167
169
@@ -170,15 +172,14 @@ nav ul, nav ol
170
172
// Embedded content
171
173
// ==========================================================================
172
174
173
- // Improve image quality when scaled in IE7
174
- // code.flickr.com/blog/2008/11/12/on-ui-quality-the-little-things-client-side-image-resizing/
175
-
175
+ // 1. Improve image quality when scaled in IE7: h5bp.com/d
176
+ // 2. Remove the gap between images and borders on image containers: h5bp.com/e
176
177
img
177
178
border : 0
178
179
-ms-interpolation-mode : bicubic
180
+ vertical-align : middle
179
181
180
182
// Correct overflow displayed oddly in IE9
181
-
182
183
svg :not (:root )
183
184
overflow : hidden
184
185
@@ -202,22 +203,20 @@ fieldset
202
203
margin : 0
203
204
padding : 0
204
205
206
+ // Indicate that 'label' will shift focus to the associated form element
207
+ label
208
+ cursor : pointer
209
+
205
210
// 1. Correct color not inheriting in IE6/7/8/9
206
211
// 2. Correct alignment displayed oddly in IE6/7
207
-
208
212
legend
209
213
border : 0
210
214
* margin-left: -7px
211
215
padding : 0
212
216
213
- // Indicate that 'label' will shift focus to the associated form element
214
- label
215
- cursor : pointer
216
-
217
217
// 1. Correct font-size not inheriting in all browsers
218
218
// 2. Remove margins in FF3/4 S5 Chrome
219
219
// 3. Define consistent vertical alignment display in all browsers
220
-
221
220
button , input , select , textarea
222
221
font-size : 100%
223
222
margin : 0
@@ -226,38 +225,42 @@ button, input, select, textarea
226
225
227
226
// 1. Define line-height as normal to match FF3/4 (set using !important in the UA stylesheet)
228
227
// 2. Correct inner spacing displayed oddly in IE6/7
229
-
230
228
button , input
231
229
line-height : normal
232
230
* overflow: visible
231
+
232
+ // Reintroduce inner spacing in 'table' to avoid overlap and whitespace issues in IE6/7
233
+ table button , table input
234
+ * overflow: auto
233
235
234
236
// 1. Display hand cursor for clickable form elements
235
237
// 2. Allow styling of clickable form elements in iOS
236
-
237
238
button , input [type="button"], input [type="reset"], input [type="submit"]
238
239
cursor : pointer
239
240
-webkit-appearance : butto n
240
241
241
242
// Consistent box sizing and appearance
242
-
243
243
input [type="checkbox"], input [type="radio"]
244
244
box-sizing : border-box
245
245
input [type="search"]
246
+ -webkit-appearance : textfield
246
247
-moz-box-sizing : content-box
247
248
-webkit-box-sizing : content-box
248
249
box-sizing : content-box
250
+ input [type="search"]::-webkit-search-decoration
251
+ -webkit-appearance : none
249
252
250
- // Remove inner padding and border in FF3/4
251
- // www.sitepen.com/blog/2008/05/14/the-devils-in-the-details-fixing-dojos-toolbar-buttons/
252
-
253
+ // Remove inner padding and border in FF3/4: h5bp.com/l
253
254
button ::-moz-focus-inner , input ::-moz-focus-inner
254
255
border : 0
255
256
padding : 0
256
257
257
- // Remove default vertical scrollbar in IE6/7/8/9 */
258
+ // 1. Remove default vertical scrollbar in IE6/7/8/9
259
+ // 2. Allow only vertical resizingtextarea
258
260
textarea
259
261
overflow : auto
260
262
vertical-align : top
263
+ resize : vertical
261
264
262
265
// Colors for form validity
263
266
input :valid , textarea :valid
@@ -272,4 +275,6 @@ input:invalid, textarea:invalid
272
275
273
276
table
274
277
border-collapse : collapse
275
- border-spacing : 0
278
+ border-spacing : 0
279
+ td
280
+ vertical-align : top
0 commit comments