piecss 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/sass/piecss/_behavior.css +1 -448
- data/sass/piecss/_behavior.css.map +2 -2
- data/sass/piecss/_settings.css +0 -7
- data/sass/piecss/_settings.css.map +2 -2
- data/sass/piecss/behavior/base/_base.scss +173 -121
- data/sass/piecss/behavior/base/_normalize.scss +463 -0
- data/sass/piecss/behavior/base/_settings.scss +432 -24
- data/sass/piecss/behavior/form/_form.scss +1 -1
- data/sass/piecss/settings/_colour.scss +5 -2
- data/sass/piecss/utilities/_miscellaneous.scss +0 -13
- data/templates/project/examples.html +2 -1
- metadata +2 -1
@@ -21,18 +21,21 @@
|
|
21
21
|
*,
|
22
22
|
*:before,
|
23
23
|
*:after {
|
24
|
+
@if $reset-box-model {
|
24
25
|
box-sizing: border-box; /* 1 */
|
25
26
|
margin: 0; /* 2 */
|
26
|
-
|
27
|
-
|
27
|
+
vertical-align: bottom;
|
28
|
+
}
|
28
29
|
}
|
29
30
|
|
31
|
+
|
30
32
|
/*
|
31
33
|
* 1. Set base font (family, size, line-height) for conversions to rem and/or em.
|
32
34
|
* 2. Set default font family to sans-serif.
|
33
35
|
* 3. Prevent iOS text size adjust after orientation change, without disabling
|
34
36
|
* user zoom.
|
35
37
|
* 4. Set background color.
|
38
|
+
* 5. Set body color.
|
36
39
|
*/
|
37
40
|
|
38
41
|
html {
|
@@ -46,6 +49,7 @@ html {
|
|
46
49
|
$line-height: to-unit($default-line-height, $line-height-unit);
|
47
50
|
|
48
51
|
font: #{$font-style} #{$font-variant} #{$font-weight} #{$font-size}/#{$line-height} #{$font-family}; /* 1, 2 */
|
52
|
+
color: $color-body; /* 5 */
|
49
53
|
|
50
54
|
text-size-adjust: 100%; /* 3 */
|
51
55
|
width: 100%; /* 3 */
|
@@ -57,7 +61,7 @@ html {
|
|
57
61
|
* Remove default margin.
|
58
62
|
*/
|
59
63
|
|
60
|
-
|
64
|
+
#{implode($reset-margin ", ")} {
|
61
65
|
margin: 0;
|
62
66
|
}
|
63
67
|
|
@@ -82,7 +86,9 @@ main,
|
|
82
86
|
nav,
|
83
87
|
section,
|
84
88
|
summary {
|
85
|
-
display
|
89
|
+
@if $normalize-block-display {
|
90
|
+
display: block;
|
91
|
+
}
|
86
92
|
}
|
87
93
|
|
88
94
|
/*
|
@@ -127,8 +133,19 @@ template {
|
|
127
133
|
*/
|
128
134
|
|
129
135
|
a {
|
130
|
-
|
131
|
-
|
136
|
+
@if $normalize-anchor {
|
137
|
+
background: transparent; /* 1 */
|
138
|
+
}
|
139
|
+
color: $color-anchor; /* 2 */
|
140
|
+
&:visited {
|
141
|
+
color: $color-anchor--visited; /* 2 */
|
142
|
+
}
|
143
|
+
&:active {
|
144
|
+
color: $color-anchor--active; /* 2 */
|
145
|
+
}
|
146
|
+
&:hover {
|
147
|
+
color: $color-anchor--hover; /* 2 */
|
148
|
+
}
|
132
149
|
}
|
133
150
|
|
134
151
|
/*
|
@@ -137,7 +154,9 @@ a {
|
|
137
154
|
|
138
155
|
a:active,
|
139
156
|
a:hover {
|
140
|
-
|
157
|
+
@if $normalize-anchor {
|
158
|
+
outline: 0;
|
159
|
+
}
|
141
160
|
}
|
142
161
|
|
143
162
|
/* Text-level semantics
|
@@ -148,35 +167,53 @@ a:hover {
|
|
148
167
|
*/
|
149
168
|
|
150
169
|
abbr[title] {
|
151
|
-
|
170
|
+
@if $normalize-abbr {
|
171
|
+
border-bottom: 1px dotted;
|
172
|
+
}
|
152
173
|
}
|
153
174
|
|
154
175
|
/*
|
155
|
-
* Address
|
176
|
+
* Address variable `h1` font-size and margin within `section` and `article`
|
177
|
+
* contexts in Firefox 4+, Safari, and Chrome.
|
156
178
|
*/
|
157
179
|
|
158
|
-
|
159
|
-
|
160
|
-
|
180
|
+
h1 {
|
181
|
+
@if $normalize-h1 and index($reset-font, "h1")==0 {
|
182
|
+
font-size: $h1-font-size;
|
183
|
+
line-height: $h1-line-height;
|
184
|
+
}
|
161
185
|
}
|
162
186
|
|
163
187
|
/*
|
164
|
-
*
|
188
|
+
* Reset or normalize font-weights.
|
165
189
|
*/
|
166
190
|
|
167
|
-
|
168
|
-
font-
|
191
|
+
@if length($reset-font-weight-to-bold)>0 {
|
192
|
+
#{implode($reset-font-weight-to-bold, ", ")} {
|
193
|
+
font-weight: bold;
|
194
|
+
}
|
195
|
+
}
|
196
|
+
|
197
|
+
@if length($reset-font-weight-to-italic)>0 {
|
198
|
+
#{implode($reset-font-weight-to-italic, ", ")} {
|
199
|
+
font-weight: italic;
|
200
|
+
}
|
201
|
+
}
|
202
|
+
|
203
|
+
@if length($reset-font-weight-to-regular)>0 {
|
204
|
+
#{implode($reset-font-weight-to-regular, ", ")} {
|
205
|
+
font-weight: regular;
|
206
|
+
}
|
169
207
|
}
|
170
208
|
|
171
209
|
/*
|
172
|
-
*
|
173
|
-
* contexts in Firefox 4+, Safari, and Chrome.
|
210
|
+
* Full typographic reset
|
174
211
|
*/
|
175
212
|
|
176
|
-
|
177
|
-
font
|
178
|
-
|
179
|
-
|
213
|
+
@if length($reset-font)>0 {
|
214
|
+
#{implode($reset-font ", ")} {
|
215
|
+
font: inherit;
|
216
|
+
}
|
180
217
|
}
|
181
218
|
|
182
219
|
/*
|
@@ -184,8 +221,10 @@ h1 {
|
|
184
221
|
*/
|
185
222
|
|
186
223
|
mark {
|
187
|
-
|
188
|
-
|
224
|
+
@if $normalize-mark {
|
225
|
+
background: $mark-background;
|
226
|
+
color: $mark-color;
|
227
|
+
}
|
189
228
|
}
|
190
229
|
|
191
230
|
/*
|
@@ -193,7 +232,9 @@ mark {
|
|
193
232
|
*/
|
194
233
|
|
195
234
|
small {
|
196
|
-
|
235
|
+
@if $normalize-small {
|
236
|
+
font-size: $small-font-size;
|
237
|
+
}
|
197
238
|
}
|
198
239
|
|
199
240
|
/*
|
@@ -202,18 +243,24 @@ small {
|
|
202
243
|
|
203
244
|
sub,
|
204
245
|
sup {
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
246
|
+
@if $normalize-sup-sub {
|
247
|
+
font-size: $sup-sub-font-size;
|
248
|
+
line-height: 0;
|
249
|
+
position: relative;
|
250
|
+
vertical-align: baseline;
|
251
|
+
}
|
209
252
|
}
|
210
253
|
|
211
254
|
sup {
|
212
|
-
|
255
|
+
@if $normalize-sup-sub {
|
256
|
+
top: $sup-offset-top;
|
257
|
+
}
|
213
258
|
}
|
214
259
|
|
215
260
|
sub {
|
216
|
-
|
261
|
+
@if $normalize-sup-sub {
|
262
|
+
bottom: $sub-offset-bottom;
|
263
|
+
}
|
217
264
|
}
|
218
265
|
|
219
266
|
/* Embedded content
|
@@ -224,7 +271,9 @@ sub {
|
|
224
271
|
*/
|
225
272
|
|
226
273
|
img {
|
227
|
-
border
|
274
|
+
@if $normalize-img-border {
|
275
|
+
border: 0;
|
276
|
+
}
|
228
277
|
}
|
229
278
|
|
230
279
|
/*
|
@@ -232,7 +281,9 @@ img {
|
|
232
281
|
*/
|
233
282
|
|
234
283
|
svg:not(:root) {
|
235
|
-
|
284
|
+
@if $normalize-svg {
|
285
|
+
overflow: hidden;
|
286
|
+
}
|
236
287
|
}
|
237
288
|
|
238
289
|
/* Grouping content
|
@@ -243,7 +294,9 @@ svg:not(:root) {
|
|
243
294
|
*/
|
244
295
|
|
245
296
|
figure {
|
246
|
-
margin
|
297
|
+
@if $normalize-figure-margin {
|
298
|
+
margin: $figure-margin;
|
299
|
+
}
|
247
300
|
}
|
248
301
|
|
249
302
|
/*
|
@@ -251,8 +304,10 @@ figure {
|
|
251
304
|
*/
|
252
305
|
|
253
306
|
hr {
|
254
|
-
|
255
|
-
|
307
|
+
@if $normalize-horizontal-rule {
|
308
|
+
box-sizing: content-box;
|
309
|
+
height: 0;
|
310
|
+
}
|
256
311
|
}
|
257
312
|
|
258
313
|
/*
|
@@ -260,7 +315,10 @@ hr {
|
|
260
315
|
*/
|
261
316
|
|
262
317
|
pre {
|
263
|
-
|
318
|
+
white-space: pre-wrap;
|
319
|
+
@if $normalize-pre-overflow {
|
320
|
+
overflow: auto;
|
321
|
+
}
|
264
322
|
}
|
265
323
|
|
266
324
|
/*
|
@@ -271,10 +329,15 @@ code,
|
|
271
329
|
kbd,
|
272
330
|
pre,
|
273
331
|
samp {
|
274
|
-
|
275
|
-
|
332
|
+
@if $reset-monospace-elements {
|
333
|
+
font-family: $monospace-elements-font-family;
|
334
|
+
}
|
335
|
+
@if $normalize-monospace-elements {
|
336
|
+
font-size: $monospace-elements-font-size;
|
337
|
+
}
|
276
338
|
}
|
277
339
|
|
340
|
+
|
278
341
|
/* Forms
|
279
342
|
========================================================================== */
|
280
343
|
|
@@ -286,8 +349,6 @@ samp {
|
|
286
349
|
/*
|
287
350
|
* 1. Correct color not being inherited.
|
288
351
|
* Known issue: affects color of disabled elements.
|
289
|
-
* 2. Correct font properties not being inherited.
|
290
|
-
* 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
|
291
352
|
*/
|
292
353
|
|
293
354
|
button,
|
@@ -295,9 +356,9 @@ input,
|
|
295
356
|
optgroup,
|
296
357
|
select,
|
297
358
|
textarea {
|
298
|
-
|
299
|
-
|
300
|
-
|
359
|
+
@if $normalize-form-elements {
|
360
|
+
color: inherit; /* 1 */
|
361
|
+
}
|
301
362
|
}
|
302
363
|
|
303
364
|
/*
|
@@ -305,7 +366,9 @@ textarea {
|
|
305
366
|
*/
|
306
367
|
|
307
368
|
button {
|
308
|
-
|
369
|
+
@if $normalize-form-elements {
|
370
|
+
overflow: visible;
|
371
|
+
}
|
309
372
|
}
|
310
373
|
|
311
374
|
/*
|
@@ -317,7 +380,9 @@ button {
|
|
317
380
|
|
318
381
|
button,
|
319
382
|
select {
|
320
|
-
|
383
|
+
@if $normalize-form-elements {
|
384
|
+
text-transform: none;
|
385
|
+
}
|
321
386
|
}
|
322
387
|
|
323
388
|
/*
|
@@ -332,8 +397,10 @@ button,
|
|
332
397
|
html input[type="button"], /* 1 */
|
333
398
|
input[type="reset"],
|
334
399
|
input[type="submit"] {
|
335
|
-
@
|
336
|
-
|
400
|
+
@if $normalize-form-elements {
|
401
|
+
appearance: button; /* 2 */
|
402
|
+
cursor: pointer; /* 3 */
|
403
|
+
}
|
337
404
|
}
|
338
405
|
|
339
406
|
/*
|
@@ -342,7 +409,9 @@ input[type="submit"] {
|
|
342
409
|
|
343
410
|
button[disabled],
|
344
411
|
html input[disabled] {
|
345
|
-
|
412
|
+
@if $normalize-form-elements {
|
413
|
+
cursor: default;
|
414
|
+
}
|
346
415
|
}
|
347
416
|
|
348
417
|
/*
|
@@ -351,8 +420,10 @@ html input[disabled] {
|
|
351
420
|
|
352
421
|
button::-moz-focus-inner,
|
353
422
|
input::-moz-focus-inner {
|
354
|
-
|
355
|
-
|
423
|
+
@if $normalize-form-elements {
|
424
|
+
border: 0;
|
425
|
+
padding: 0;
|
426
|
+
}
|
356
427
|
}
|
357
428
|
|
358
429
|
/*
|
@@ -361,7 +432,9 @@ input::-moz-focus-inner {
|
|
361
432
|
*/
|
362
433
|
|
363
434
|
input {
|
364
|
-
|
435
|
+
@if $normalize-form-elements {
|
436
|
+
line-height: normal;
|
437
|
+
}
|
365
438
|
}
|
366
439
|
|
367
440
|
/*
|
@@ -370,12 +443,16 @@ input {
|
|
370
443
|
*
|
371
444
|
* 1. Address box sizing set to `content-box` in IE 8/9/10.
|
372
445
|
* 2. Remove excess padding in IE 8/9/10.
|
446
|
+
* 3. Counter reset bottom alignment in box-model reset.
|
373
447
|
*/
|
374
448
|
|
375
449
|
input[type="checkbox"],
|
376
450
|
input[type="radio"] {
|
377
|
-
|
378
|
-
|
451
|
+
@if $normalize-form-elements {
|
452
|
+
box-sizing: border-box; /* 1 */
|
453
|
+
padding: 0; /* 2 */
|
454
|
+
vertical-align: baseline; /* 3 */
|
455
|
+
}
|
379
456
|
}
|
380
457
|
|
381
458
|
/*
|
@@ -386,7 +463,9 @@ input[type="radio"] {
|
|
386
463
|
|
387
464
|
input[type="number"]::-webkit-inner-spin-button,
|
388
465
|
input[type="number"]::-webkit-outer-spin-button {
|
389
|
-
|
466
|
+
@if $normalize-form-elements {
|
467
|
+
height: auto;
|
468
|
+
}
|
390
469
|
}
|
391
470
|
|
392
471
|
/*
|
@@ -396,8 +475,9 @@ input[type="number"]::-webkit-outer-spin-button {
|
|
396
475
|
*/
|
397
476
|
|
398
477
|
input[type="search"] {
|
399
|
-
@
|
400
|
-
|
478
|
+
@if $normalize-form-elements {
|
479
|
+
appearance: textfield; /* 1 */
|
480
|
+
}
|
401
481
|
}
|
402
482
|
|
403
483
|
/*
|
@@ -408,7 +488,9 @@ input[type="search"] {
|
|
408
488
|
|
409
489
|
input[type="search"]::-webkit-search-cancel-button,
|
410
490
|
input[type="search"]::-webkit-search-decoration {
|
411
|
-
@
|
491
|
+
@if $normalize-form-elements {
|
492
|
+
appearance: none;
|
493
|
+
}
|
412
494
|
}
|
413
495
|
|
414
496
|
/*
|
@@ -416,9 +498,11 @@ input[type="search"]::-webkit-search-decoration {
|
|
416
498
|
*/
|
417
499
|
|
418
500
|
fieldset {
|
419
|
-
|
420
|
-
|
421
|
-
|
501
|
+
@if $normalize-fieldset {
|
502
|
+
border: $fieldset-border;
|
503
|
+
margin: $fieldset-margin;
|
504
|
+
padding: $fieldset-padding;
|
505
|
+
}
|
422
506
|
}
|
423
507
|
|
424
508
|
/*
|
@@ -427,8 +511,10 @@ fieldset {
|
|
427
511
|
*/
|
428
512
|
|
429
513
|
legend {
|
430
|
-
|
431
|
-
|
514
|
+
@if $normalize-legend {
|
515
|
+
border: 0; /* 1 */
|
516
|
+
padding: 0; /* 2 */
|
517
|
+
}
|
432
518
|
}
|
433
519
|
|
434
520
|
/*
|
@@ -436,17 +522,11 @@ legend {
|
|
436
522
|
*/
|
437
523
|
|
438
524
|
textarea {
|
439
|
-
|
525
|
+
@if $normalize-textarea {
|
526
|
+
overflow: auto;
|
527
|
+
}
|
440
528
|
}
|
441
529
|
|
442
|
-
/*
|
443
|
-
* Don't inherit the `font-weight` (applied by a rule above).
|
444
|
-
* NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
|
445
|
-
*/
|
446
|
-
|
447
|
-
optgroup {
|
448
|
-
font-weight: bold;
|
449
|
-
}
|
450
530
|
|
451
531
|
/* Tables
|
452
532
|
========================================================================== */
|
@@ -456,65 +536,37 @@ optgroup {
|
|
456
536
|
*/
|
457
537
|
|
458
538
|
table {
|
459
|
-
|
460
|
-
|
539
|
+
@if $reset-table {
|
540
|
+
border-collapse: collapse;
|
541
|
+
border-spacing: 0;
|
542
|
+
}
|
461
543
|
}
|
462
544
|
|
463
545
|
td,
|
464
546
|
th {
|
465
|
-
|
547
|
+
@if $reset-table {
|
548
|
+
padding: 0;
|
549
|
+
}
|
466
550
|
}
|
467
551
|
|
468
|
-
|
469
|
-
// Copyright (C) 2014 Babs Gösgens. Licensed under MIT; see LICENSE.txt
|
470
|
-
|
471
|
-
|
472
552
|
/*
|
473
|
-
|
474
|
-
|
475
|
-
-----------------------------------------------------------------------------
|
476
|
-
*/
|
553
|
+
* Set consistent quote types.
|
554
|
+
*/
|
477
555
|
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
}
|
484
|
-
code,
|
485
|
-
kbd,
|
486
|
-
pre,
|
487
|
-
samp {
|
488
|
-
@include font-family($monospace-regular);
|
489
|
-
font-size: to-unit($default-font-size);
|
490
|
-
}
|
491
|
-
pre {
|
492
|
-
white-space: pre-wrap;
|
493
|
-
}
|
494
|
-
small {
|
495
|
-
font-size: 80%;
|
496
|
-
}
|
497
|
-
sub,
|
498
|
-
sup {
|
499
|
-
font-size: 75%;
|
500
|
-
line-height: 0;
|
501
|
-
position: relative;
|
502
|
-
vertical-align: baseline;
|
503
|
-
}
|
504
|
-
sup {
|
505
|
-
top: -0.5em;
|
506
|
-
}
|
507
|
-
sub {
|
508
|
-
bottom: -0.25em;
|
556
|
+
q {
|
557
|
+
@if $normalize-quote-quotes
|
558
|
+
{
|
559
|
+
quotes: "\201C" "\201D" "\2018" "\2019";
|
560
|
+
}
|
509
561
|
}
|
510
562
|
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
*/
|
563
|
+
/*
|
564
|
+
* Apply a bottom margin of one line-height to any element in this comma
|
565
|
+
* separated list.
|
566
|
+
*/
|
516
567
|
|
517
|
-
|
518
|
-
|
519
|
-
|
568
|
+
@if length($single-direction-elements)>0 {
|
569
|
+
#{implode($single-direction-elements, ", ")} {
|
570
|
+
margin: 0 0 $default-line-height;
|
571
|
+
}
|
520
572
|
}
|