@@ -7,11 +7,15 @@ backgroundModifier: darkRoad
7
7
8
8
@[ toc]
9
9
10
+ ** Note that according to your [ browser scope] ( usage/#browsers ) some
11
+ transformation can be skipped to avoid extra useless output.**
12
+ Eg: if you use don't cover IE 8, rem fallback and rgba fallback might be skipped.
13
+
10
14
## automatic vendor prefixes
11
15
12
16
Vendor prefixes are automatically added (and removed if deprecated/useless
13
17
depending on your browser scope) using
14
- [ autoprefixer] ( https://github.com/postcss/autoprefixer ) )
18
+ ** [ autoprefixer] ( https://github.com/postcss/autoprefixer ) ** ).
15
19
16
20
17
21
## custom properties & ` var() `
@@ -120,7 +124,34 @@ Alows you to create your own selectors
120
124
|
121
125
[ Plugin documentation] ( https://github.com/postcss/postcss-custom-selector )
122
126
123
- ## ` color() `
127
+ ## nesting
128
+
129
+ Allow you to nest selectors
130
+
131
+ ``` scss
132
+ a {
133
+ /* direct nesting (& MUST be the first part of selector)*/
134
+ & span {
135
+ color : white ;
136
+ }
137
+
138
+ /* @nest rule (for complex nesting) */
139
+ @nest span & {
140
+ color : blue ;
141
+ }
142
+
143
+ /* media query automatic nesting */
144
+ @media (min-width : 30em ) {
145
+ color : yellow ;
146
+ }
147
+ }
148
+ ```
149
+
150
+ [ Specification] ( http://tabatkins.github.io/specs/css-nesting/ )
151
+ |
152
+ [ Plugin documentation] ( https://github.com/jonathantneal/postcss-nesting )
153
+
154
+ ## ` color() ` function
124
155
125
156
a color function to modify colors (transpiled to: ` rgba() ` )
126
157
@@ -142,7 +173,7 @@ so be sure to check them !
142
173
|
143
174
[ Plugin documentation] ( https://github.com/postcss/postcss-color-function )
144
175
145
- ## ` hwb() `
176
+ ## ` hwb() ` function
146
177
147
178
Similar to ` hsl() ` but easier for humans to work with (transpiled to: ` rgba() ` ).
148
179
@@ -156,7 +187,7 @@ body {
156
187
|
157
188
[ Plugin documentation] ( https://github.com/postcss/postcss-color-hwb )
158
189
159
- ## ` gray() `
190
+ ## ` gray() ` function
160
191
161
192
Allow you to use more than 50 shades of gray (transpiled to: ` rgba() ` ).
162
193
For the first argument, you can use a number between 0 and 255 or a percentage.
@@ -175,7 +206,7 @@ For the first argument, you can use a number between 0 and 255 or a percentage.
175
206
|
176
207
[ Plugin documentation] ( https://github.com/postcss/postcss-color-gray )
177
208
178
- ## #rrggbbaa
209
+ ## ` #rrggbbaa ` colors
179
210
180
211
Allows use to use 4 or 8 digits hexadecimal notation (transpiled to: ` rgba() ` ).
181
212
@@ -189,7 +220,23 @@ body {
189
220
|
190
221
[ Plugin documentation] ( https://github.com/postcss/postcss-color-hex-alpha )
191
222
192
- ## ` rebeccapurple `
223
+ ## ` rgba ` function (` rgb ` fallback)
224
+
225
+ Add solid colors fallback for rgba colors
226
+ (if you browser scope cover old browsers, eg: IE8).
227
+
228
+ ``` css
229
+ body {
230
+ background : rgba (153 , 221 , 153 , 0.8 );
231
+ /* you will have the same value without alpha as a fallback */
232
+ }
233
+ ```
234
+
235
+ [ Specification] ( http://www.w3.org/TR/css3-color/ )
236
+ |
237
+ [ Plugin documentation] ( https://github.com/postcss/postcss-color-rgba-fallback )
238
+
239
+ ## ` rebeccapurple ` color
193
240
194
241
Allows you to use the new color keyword as a homage to
195
242
[ Eric Meyer’s daughter] ( https://github.com/postcss/postcss-color-rebeccapurple#why-this-plugin- )
@@ -204,8 +251,7 @@ body {
204
251
|
205
252
[ Plugin documentation] ( https://github.com/postcss/postcss-color-rebeccapurple )
206
253
207
-
208
- ## font-variant
254
+ ## ` font-variant ` property
209
255
210
256
properties (fallback: ` font-feature-settings ` )
211
257
@@ -228,7 +274,7 @@ at the support of
228
274
|
229
275
[ Plugin documentation] ( https://github.com/postcss/postcss-font-variant )
230
276
231
- ## filter
277
+ ## ` filter ` property
232
278
233
279
The W3C filters are only transformed as svg filter using the ` url(data:*) ` trick
234
280
for Firefox < 35.
@@ -243,10 +289,38 @@ for Firefox < 35.
243
289
|
244
290
[ Plugin documentation] ( https://github.com/iamvdo/pleeease-filters )
245
291
246
- ## ` rem ` units
292
+ ## ` initial ` value
293
+
294
+ Allow you to use ` initial ` value for any value. This value represents the value
295
+ specified as the property’s initial value. ** It does not mean browser default.**
296
+
297
+ For example, for the ` display ` property, ` initial ` always means ` inline ` ,
298
+ because that’s the designated initial value of the property.
299
+ As an example, using ` div { display: initial } ` , will ** not** be ` block ` , but
300
+ ` inline ` .
301
+
302
+ ``` css
303
+ div {
304
+ display : initial ; /* inline */
305
+ }
306
+ ```
307
+
308
+ _ Killer feature :_
309
+
310
+ ``` css
311
+ div {
312
+ all : initial ; /* use initial for ALL PROPERTIES in one shot */
313
+ }
314
+ ```
315
+
316
+ [ Specification] ( http://www.w3.org/TR/css3-values/#common-keywords )
317
+ |
318
+ [ Plugin documentation] ( https://github.com/maximkoretskiy/postcss-initial )
319
+
320
+ ## ` rem ` unit (` px ` fallback)
247
321
248
322
` rem ` fallback to ` px `
249
- (if you browser scope cover old browsers).
323
+ (if you browser scope cover old browsers, eg: IE8 ).
250
324
251
325
``` css
252
326
h1 {
@@ -303,10 +377,10 @@ p:not(:first-child, .special) {
303
377
|
304
378
[ Plugin documentation] ( https://github.com/postcss/postcss-selector-NOT )
305
379
306
- ## pseudo-elements
380
+ ## ` :: ` pseudo syntax ( ` : ` fallback)
307
381
308
382
Adjust ` :: ` to ` : `
309
- (if you browser scope cover old browsers)
383
+ (if you browser scope cover old browsers, eg: IE8).
310
384
311
385
``` css
312
386
a ::before {
@@ -318,25 +392,6 @@ a::before {
318
392
|
319
393
[ Plugin documentation] ( https://github.com/axa-ch/postcss-pseudoelements )
320
394
321
- ## Alpha colors
322
-
323
- Add solid colors fallback for rgba colors
324
- (if you browser scope cover old browsers)
325
-
326
- ``` css
327
- body {
328
- background : rgba (153 , 221 , 153 , 0.8 );
329
- /* you will have the same value without alpha as a fallback */
330
- }
331
- ```
332
-
333
- [ Specification] ( http://www.w3.org/TR/css3-color/ )
334
- |
335
- [ Plugin documentation] ( https://github.com/postcss/postcss-color-rgba-fallback )
336
-
337
- _ Note that according to your [ browser scope] ( #nodejs-options ) some might be not
338
- transpiled to avoid extra useless output._
339
-
340
395
## @todo
341
396
342
397
Any omissions of the CSS specifications (even in draft) that are subject to be
0 commit comments