cssnano 5.0.3 → 5.0.7

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.
package/dist/index.js CHANGED
@@ -9,7 +9,9 @@ var _path = _interopRequireDefault(require("path"));
9
9
 
10
10
  var _postcss = _interopRequireDefault(require("postcss"));
11
11
 
12
- var _cosmiconfig = require("cosmiconfig");
12
+ var _yaml = _interopRequireDefault(require("yaml"));
13
+
14
+ var _lilconfig = require("lilconfig");
13
15
 
14
16
  var _isResolvable = _interopRequireDefault(require("is-resolvable"));
15
17
 
@@ -66,7 +68,7 @@ function resolvePreset(preset) {
66
68
  }
67
69
  /*
68
70
  * cssnano will look for configuration firstly as options passed
69
- * directly to it, and failing this it will use cosmiconfig to
71
+ * directly to it, and failing this it will use lilconfig to
70
72
  * load an external file.
71
73
  */
72
74
 
@@ -84,7 +86,13 @@ function resolveConfig(options) {
84
86
  configPath = _path.default.resolve(process.cwd(), options.configFile);
85
87
  }
86
88
 
87
- const configExplorer = (0, _cosmiconfig.cosmiconfigSync)(cssnano);
89
+ const configExplorer = (0, _lilconfig.lilconfigSync)(cssnano, {
90
+ searchPlaces: ['package.json', '.cssnanorc', '.cssnanorc.json', '.cssnanorc.yaml', '.cssnanorc.yml', '.cssnanorc.js', 'cssnano.config.js'],
91
+ loaders: {
92
+ '.yaml': (filepath, content) => _yaml.default.parse(content),
93
+ '.yml': (filepath, content) => _yaml.default.parse(content)
94
+ }
95
+ });
88
96
  const config = configPath ? configExplorer.load(configPath) : configExplorer.search(searchPath);
89
97
 
90
98
  if (config === null) {
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "cssnano",
3
- "version": "5.0.3",
3
+ "version": "5.0.7",
4
4
  "description": "A modular minifier, built on top of the PostCSS ecosystem.",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
7
7
  "bundle-size": "webpack --json --config src/__tests__/_webpack.config.js | webpack-bundle-size-analyzer",
8
- "prebuild": "del-cli dist",
8
+ "prebuild": "rimraf dist",
9
9
  "build": "cross-env BABEL_ENV=publish babel src --config-file ../../babel.config.json --out-dir dist --ignore \"**/__tests__/\"",
10
- "prepublish": "yarn build"
10
+ "prepare": "yarn build"
11
11
  },
12
12
  "funding": {
13
13
  "type": "opencollective",
@@ -24,9 +24,10 @@
24
24
  ],
25
25
  "license": "MIT",
26
26
  "dependencies": {
27
- "cosmiconfig": "^7.0.0",
28
- "cssnano-preset-default": "^5.1.0",
29
- "is-resolvable": "^1.1.0"
27
+ "cssnano-preset-default": "^5.1.3",
28
+ "is-resolvable": "^1.1.0",
29
+ "lilconfig": "^2.0.3",
30
+ "yaml": "^1.10.2"
30
31
  },
31
32
  "homepage": "https://github.com/cssnano/cssnano",
32
33
  "author": {
@@ -48,11 +49,11 @@
48
49
  "node": "^10 || ^12 || >=14.0"
49
50
  },
50
51
  "devDependencies": {
51
- "autoprefixer": "^10.0.2",
52
+ "autoprefixer": "^10.2.0",
52
53
  "postcss": "^8.2.15"
53
54
  },
54
55
  "peerDependencies": {
55
56
  "postcss": "^8.2.15"
56
57
  },
57
- "gitHead": "28c247175032fa03f04911cde56ad82d74d211cc"
58
+ "gitHead": "fdb6a8fb922bcb3e857f1fdc341488736af37013"
58
59
  }
package/CHANGELOG.md DELETED
@@ -1,810 +0,0 @@
1
- # Change Log
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- ## [5.0.3](https://github.com/cssnano/cssnano/compare/cssnano@5.0.0...cssnano@5.0.3) (2021-05-19)
7
-
8
-
9
- ### Bug Fixes
10
-
11
- * **cssnano:** many bug fixes in dependent packages. Most notably fixed buggy reordering of border declarations and improved color value minification. See the changelogs for the single presets and plugins for details.
12
-
13
-
14
-
15
-
16
-
17
- ## [5.0.2](https://github.com/cssnano/cssnano/compare/cssnano@5.0.0...cssnano@5.0.2) (2021-04-26)
18
-
19
-
20
- ### Bug Fixes
21
-
22
- * **cssnano:** replace opencollective with funding field. ([#1047](https://github.com/cssnano/cssnano/issues/1047)) ([3dee7c5](https://github.com/cssnano/cssnano/commit/3dee7c553350e43ad0750a9478a63cf897e5510f)), closes [#1046](https://github.com/cssnano/cssnano/issues/1046)
23
-
24
-
25
-
26
-
27
-
28
- ## [5.0.1](https://github.com/cssnano/cssnano/compare/cssnano@5.0.0...cssnano@5.0.1) (2021-04-13)
29
-
30
-
31
- ### Bug Fixes
32
-
33
- * **cssnano:** replace opencollective with funding field. ([#1047](https://github.com/cssnano/cssnano/issues/1047)) ([3dee7c5](https://github.com/cssnano/cssnano/commit/3dee7c553350e43ad0750a9478a63cf897e5510f)), closes [#1046](https://github.com/cssnano/cssnano/issues/1046)
34
-
35
-
36
-
37
-
38
-
39
- # [5.0.0](https://github.com/cssnano/cssnano/compare/cssnano@5.0.0-rc.2...cssnano@5.0.0) (2021-04-06)
40
-
41
- **Note:** Version bump only for package cssnano
42
-
43
-
44
-
45
-
46
-
47
- # [5.0.0-rc.2](https://github.com/cssnano/cssnano/compare/cssnano@5.0.0-rc.1...cssnano@5.0.0-rc.2) (2021-03-15)
48
-
49
-
50
- ### Bug Fixes
51
-
52
- * update SVGO ([aa07cfd](https://github.com/cssnano/cssnano/commit/aa07cfd62c82ed4b1e87219eea8d0ed99635e4ca))
53
-
54
-
55
-
56
-
57
-
58
- # [5.0.0-rc.1](https://github.com/cssnano/cssnano/compare/cssnano@5.0.0-rc.0...cssnano@5.0.0-rc.1) (2021-03-04)
59
-
60
- **Note:** Version bump only for package cssnano
61
-
62
-
63
-
64
-
65
-
66
- # 5.0.0-rc.0 (2021-02-19)
67
-
68
-
69
- ### Bug Fixes
70
-
71
- * **postcss-ordered-values:** columns transform returning string instead of the AST ([#928](https://github.com/cssnano/cssnano/issues/928)) ([a5d6d36](https://github.com/cssnano/cssnano/commit/a5d6d364e0815ecb198a95de301f3554ccce4f78))
72
- * **unique-selector:** removed sorting and involving selector comments ([#857](https://github.com/cssnano/cssnano/issues/857)) ([3fa875d](https://github.com/cssnano/cssnano/commit/3fa875dade2138e1a531dce1f8b79814cb39dbc9))
73
-
74
-
75
- ### chore
76
-
77
- * minimum require version of node is 10.13 ([#871](https://github.com/cssnano/cssnano/issues/871)) ([28bda24](https://github.com/cssnano/cssnano/commit/28bda243e32ce3ba89b3c358a5f78727b3732f11))
78
-
79
-
80
- ### Features
81
-
82
- * css declaration sorter ([#855](https://github.com/cssnano/cssnano/issues/855)) ([613d562](https://github.com/cssnano/cssnano/commit/613d562ae79e7e169c80b523b7c2c9b0093bc1d8))
83
- * migarete to PostCSS 8 ([#975](https://github.com/cssnano/cssnano/issues/975)) ([40b82dc](https://github.com/cssnano/cssnano/commit/40b82dca7f53ac02cd4fe62846dec79b898ccb49))
84
- * **postcss-reduce-transforms:** improve optimizations ([#745](https://github.com/cssnano/cssnano/issues/745)) ([b0f0d89](https://github.com/cssnano/cssnano/commit/b0f0d892316d7b77e8033a6dc8d67745043a5072))
85
-
86
-
87
- ### BREAKING CHANGES
88
-
89
- * minimum supported `postcss` version is `8.2.1`
90
- * minimum require version of node is 10.13
91
-
92
-
93
-
94
- ## 4.1.10 (2019-02-14)
95
-
96
-
97
-
98
- ## 4.1.9 (2019-02-12)
99
-
100
-
101
- ### Bug Fixes
102
-
103
- * initial loading time ([#654](https://github.com/cssnano/cssnano/issues/654)) ([de2ef07](https://github.com/cssnano/cssnano/commit/de2ef074a0c7da94c22a5b0336e6c4ca2a94f1b5))
104
-
105
-
106
-
107
- ## 4.1.7 (2018-10-22)
108
-
109
-
110
-
111
- ## 4.1.6 (2018-10-22)
112
-
113
-
114
-
115
- ## 4.1.5 (2018-10-17)
116
-
117
-
118
- ### Bug Fixes
119
-
120
- * toggling of plugins in presets using boolean configuration option ([#622](https://github.com/cssnano/cssnano/issues/622)) ([15076f1](https://github.com/cssnano/cssnano/commit/15076f145118507e010722cc9ed548ffe1b91f8c))
121
-
122
-
123
-
124
- ## 4.1.4 (2018-09-27)
125
-
126
-
127
-
128
- ## 4.1.3 (2018-09-25)
129
-
130
-
131
-
132
- ## 4.1.2 (2018-09-25)
133
-
134
-
135
-
136
- ## 4.1.1 (2018-09-24)
137
-
138
-
139
- ### Bug Fixes
140
-
141
- * parse error with iPhone X feature ([#614](https://github.com/cssnano/cssnano/issues/614)) ([a3704a7](https://github.com/cssnano/cssnano/commit/a3704a76a631b1cd907ab0c0a8637a622769676d))
142
-
143
-
144
-
145
- # 4.1.0 (2018-08-24)
146
-
147
-
148
-
149
- ## 4.0.5 (2018-07-30)
150
-
151
-
152
-
153
- ## 4.0.4 (2018-07-25)
154
-
155
-
156
-
157
- ## 4.0.3 (2018-07-18)
158
-
159
-
160
- ### Bug Fixes
161
-
162
- * **postcss-merge-longhand:** not mangle border output ([#555](https://github.com/cssnano/cssnano/issues/555)) ([9a70605](https://github.com/cssnano/cssnano/commit/9a706050b621e7795a9bf74eb7110b5c81804ffe)), closes [#553](https://github.com/cssnano/cssnano/issues/553) [#554](https://github.com/cssnano/cssnano/issues/554)
163
-
164
-
165
-
166
-
167
-
168
- # 4.1.10
169
-
170
- ## Bug Fixes
171
-
172
- * `stylehacks` does not throw error on `[attr]` selector
173
-
174
- # 4.1.9
175
-
176
- ## Performance Improvements
177
-
178
- * `postcss-colormin`: increase performance
179
- * `postcss-discard-comments`: increase performance
180
- * `postcss-merge-rules` increase performance
181
- * `postcss-minify-params` increase performance
182
- * `postcss-minify-selectors`: increase performance
183
- * `postcss-normalize-display-values`: increase performance
184
- * `postcss-normalize-positions`: increase performance
185
- * `postcss-normalize-repeat-style`: increase performance
186
- * `postcss-normalize-string`: increase performance
187
- * `postcss-normalize-timing-functions`: increase performance
188
- * `postcss-normalize-whitespace`: increase performance
189
- * `postcss-ordered-values`: increase performance
190
- * `postcss-reduce-transforms`: increase performance
191
- * `postcss-svgo`: increase performance
192
-
193
- ## Bug Fixes
194
-
195
- * `postcss-merge-longhand` handle uppercase properties and values
196
- * `postcss-minify-gradients` handle uppercase properties and values
197
- * `postcss-minify-params` do break `@page` rules
198
- * `postcss-reduce-idents` handle uppercase at-rules
199
- * `postcss-reduce-initial` now uses `repeat` as initial value for `mask-repeat`
200
- * `postcss-reduce-initial` handle uppercase value when you convert to initial
201
- * `stylehacks` handle uppercase properties and values
202
-
203
- # 4.1.8
204
-
205
- ## Performance Improvements
206
-
207
- * initial loading time (`require('cssnano')`).
208
-
209
- ## Bug Fixes
210
-
211
- * `postcss-merge-longhand` correctly merging border properties with custom properties.
212
-
213
- # 4.1.7
214
-
215
- ## Bug Fixes
216
-
217
- * republish `cssnano` due broken release.
218
-
219
- # 4.1.6
220
-
221
- ## Bug Fixes
222
-
223
- * `postcss-merge-longhand` doesn't throw error when merge a border property.
224
-
225
- # 4.1.5
226
-
227
- ## Bug Fixes
228
-
229
- * `cssnano` now allow to toggling of plugins in presets using boolean configuration option.
230
- * `postcss-merge-longhand` doesn't merge properties with `unset`.
231
- * `postcss-merge-longhand` correctly merge borders with custom properties.
232
- * `postcss-merge-longhand` doesn't merge redundant values if declarations are of different importance.
233
-
234
- ## Other changes
235
-
236
- * `postcss-calc` updated to `7.0.0` version.
237
-
238
- # 4.1.4
239
-
240
- ## Other changes
241
-
242
- * `css-declaration-sorter` now use PostCSS 7.
243
- * `postcss-calc` now use PostCSS 7.
244
-
245
- # 4.1.3
246
-
247
- ## Other changes
248
-
249
- * `postcss-minify-font-values` now use PostCSS 7.
250
- * `postcss-discard-duplicates` now use PostCSS 7.
251
-
252
- # 4.1.2
253
-
254
- ## Bug Fixes
255
-
256
- * `postcss-svgo` now handle DataURI with uppercase `data` value (`DATA:image/*;...`).
257
-
258
- # 4.1.1
259
-
260
- ## Bug Fixes
261
-
262
- * `css-declaration-sorter` was removed from default prevent.
263
- * `postcss-normalize-timing-functions` doesn't lowercased property anymore.
264
- * `postcss-normalize-positons` now handles uppercase properties.
265
- * `postcss-normalize-url` now is case-insensitive.
266
- * `postcss-merge-idents` now is case-insensitive.
267
- * `postcss-merge-rules` now is case-insensitive.
268
- * `postcss-minify-selectors` now is case-insensitive.
269
- * `postcss-minify-font-values` now is case-insensitive.
270
- * `postcss-normalize-unicode` now has correct dependencies.
271
- * `postcss-minify-params` now has correct dependencies.
272
-
273
- ## Other changes
274
-
275
- * `cssnano-preset-advanced` use Autoprefixer 9.
276
- * use PostCSS 7 in all plugins.
277
-
278
- # 4.1.0
279
-
280
- ## Bug Fixes
281
-
282
- * `postcss-merge-longhand` doesn't mangle borders.
283
-
284
- ## Features
285
-
286
- * `postcss-ordered-values` support ordering animation values.
287
-
288
- # 4.0.5
289
-
290
- ## Bug Fixes
291
-
292
- * `postcss-merge-longhand` now correctly merges borders with custom properties.
293
- * `postcss-merge-longhand` doesn't throw error in some `border` merge cases.
294
-
295
- # 4.0.4
296
-
297
- ## Bug Fixes
298
-
299
- * `postcss-merge-longhand` doesn't drop border-width with custom property from border shorthand.
300
- * `postcss-merge-longhand` doesn't convert `currentColor`.
301
- * `postcss-merge-longhand` doesn't merge border properties if there is a shorthand property between them.
302
-
303
- # 4.0.3
304
-
305
- ## Bug Fixes
306
-
307
- * `postcss-merge-longhand` incorrect minification of `border` (`border-*`) declarations.
308
-
309
- # 4.0.2
310
-
311
- ## Bug Fixes
312
-
313
- * `postcss-merge-longhand` don't explode declarations with custom properties.
314
- * `postcss-colormin` now better transform to `hsl`.
315
-
316
- # 4.0.1
317
-
318
- ## Bug Fixes
319
-
320
- * `browserslist` version incompatibility with `caniuse-api`.
321
-
322
- # 4.0.0
323
-
324
- ## Breaking changes
325
-
326
- * We dropped support for Node 4, now requiring at least Node 6.9.
327
-
328
- ## Features
329
-
330
- * postcss-merge-longhand now optimises `border-spacing` property.
331
-
332
- ## Bug Fixes
333
-
334
- * postcss-normalize-unicode doesn't change `U` to lowercase for `IE` <= 11 and `Edge` <= 15.
335
- * postcss-merge-longhand works with custom properties (Example `a { border-style:dotted; border-style:var(--variable) }`) correctly.
336
- * postcss-ordered-values handle `border` property with invalid border width value correctly.
337
- * postcss-merge-rules handles `:-ms-input-placeholder` and `::-ms-input-placeholder` selectors correctly.
338
- * postcss-merge-rules works with `all` property correctly.
339
- * postcss-normalize-url don't handle empty `url` function.
340
- * postcss-normalize-url handles `data` and `*-extension://` URLs correctly.
341
- * postcss-colormin adds whitespace after minified value and before function.
342
- * postcss-minify-font-values better escapes font name.
343
- * postcss-minify-params doesn't remove `all` for IE.
344
-
345
- ## Other changes
346
-
347
- * update all dependencies to latest.
348
- * better handles uppercase selectors/properties/values/units.
349
-
350
- # 4.0.0-rc.2
351
-
352
- ## Features
353
-
354
- * Includes the new release candidate for postcss-selector-parser 3.
355
- * Refactors comments tokenizing in postcss-discard-comments to be more
356
- memory efficient.
357
- * Adds css-declaration-sorter for improved gzip compression efficiencies
358
- (thanks to @Siilwyn).
359
- * postcss-svgo now optimises base 64 encoded SVG where possible
360
- (thanks to @evilebottnawi).
361
- * stylehacks now supports `@media \0screen\,screen\9 {}` hacks
362
- (thanks to @evilebottnawi).
363
-
364
- ## Bug Fixes
365
-
366
- * Fixed handling of package.json configuration (thanks to @andyjansson).
367
- * Fixed `resolveConfig` for a `Root` node without a `source` property
368
- (thanks to @darthmaim).
369
- * Improved radial gradient handling (thanks to @pigcan).
370
- * stylehacks now properly accounts for vendor prefixes
371
- (thanks to @evilebottnawi).
372
-
373
- # 4.0.0-rc.1
374
-
375
- ## Bug Fixes
376
-
377
- * cssnano: Resolved an issue with external configuration which wasn't
378
- being loaded correctly (thanks to @andyjansson).
379
- * postcss-minify-params: Resolved an issue with cssnano's handling of the
380
- `@value` syntax from css-modules to better integrate with css-loader.
381
-
382
- # 4.0.0-rc.0
383
-
384
- Since version 4 has been in-development for some time, we thought it would be
385
- best to release an alpha version so that we could catch any issues before
386
- the actual release.
387
-
388
- ## Breaking changes
389
-
390
- * cssnano & its plugins have been upgraded to PostCSS 6.x. Please ensure that
391
- for optimal results that you use cssnano with a PostCSS 6 compatible runner
392
- & that any other plugins are also using PostCSS 6.
393
- * cssnano is now essentially a preset loader and does not contain any built-in
394
- transforms (instead, it delegates to `cssnano-preset-default` by default).
395
- Due to the new architecture, it's not possible to exclude asynchronous
396
- transforms and run it synchronously, unlike in 3.x. Any transforms that
397
- were "core" modules have now been extracted out into separate packages.
398
- * Because of the new preset system, cssnano will not accept any transformation
399
- options; these must be set in the preset. The option names remain mostly the
400
- same, except some cases where "core" modules have been extracted out:
401
-
402
- * `core` is now `normalizeWhitespace`.
403
- * `reduceBackgroundRepeat` is now `normalizeRepeatStyle`.
404
- * `reduceDisplayValues` is now `normalizeDisplayValues`.
405
- * `reducePositions` is now `normalizePositions`.
406
- * `reduceTimingFunctions` is now `normalizeTimingFunctions`.
407
- * `styleCache` is now `rawCache`.
408
-
409
- When excluding transforms, we now have an `exclude` option (in 3.x this was
410
- named `disable`). Similarly, the `safe` option was removed; the defaults
411
- are now much less aggressive.
412
- * By default, the following transforms are no longer applied to any input CSS.
413
- You may see an increased output file size as a result:
414
-
415
- * `autoprefixer`
416
- * `postcss-discard-unused`
417
- * `postcss-merge-idents`
418
- * `postcss-reduce-idents`
419
- * `postcss-zindex`
420
-
421
- Note that you can load `cssnano-preset-advanced` instead which *does* contain
422
- these transforms.
423
- * We no longer detect previous plugins to silently exclude our own, and now
424
- consider this to be an anti-pattern. So `postcss-filter-plugins` was removed.
425
- * We also changed some options to make the default transforms safer:
426
-
427
- * `postcss-minify-font-values`: `removeAfterKeyword` set to `false` from `true`.
428
- * `postcss-normalize-url`: `stripWWW` set to `false` from `true`.
429
-
430
- * cssnano now does not accept the `sourcemap` shortcut option; please refer
431
- to the PostCSS documentation on sourcemaps. The `quickstart.js` file included
432
- with this module will give you a good starting point.
433
- * `cssnano.process` is no longer a custom method; we use the built-in `process`
434
- method exposed on each PostCSS plugin. The new signature is
435
- `cssnano.process(css, postcssOpts, cssnanoOpts)`, in 3.x it was
436
- `cssnano.process(css, cssnanoOpts)`.
437
- * We dropped support for Node 0.12, now requiring at least Node 4.
438
- * Finally, cssnano is now developed as a monorepo, due to the fact that some
439
- transforms have a lot of grey area/overlap. Due to this, some modules have
440
- been refactored to delegate responsibility to others, such that duplication
441
- of functionality is minimized. For instance, `postcss-colormin` will no
442
- longer compress whitespace or compress numbers, as those are handled by
443
- `postcss-normalize-whitespace` & `postcss-convert-values` respectively.
444
-
445
- ## Other changes
446
-
447
- * Due to the PostCSS 6 upgrade, we have been able to reduce usage of custom
448
- methods, such as node `clone` behaviour. In cases where some utility
449
- has been used by several plugins it is now a separate package, reducing
450
- cssnano's footprint.
451
- * cssnano now makes much better use of Browserslist. `postcss-colormin` &
452
- `postcss-reduce-initial` were enhanced with different behaviour depending
453
- on which browsers are passed. And now, the footprint for the `caniuse-db`
454
- dependency is much smaller thanks to `caniuse-lite` - 7 times smaller as
455
- of this writing. This makes cssnano much faster to download from npm!
456
-
457
- # 3.10.0
458
-
459
- * cssnano will no longer `console.warn` any messages when using deprecated
460
- options; these are now sent to PostCSS. You will be able to see them if you
461
- use a PostCSS runner with built-in messages support, or alternately by
462
- loading `postcss-reporter` or `postcss-browser-reporter` in your plugins list.
463
- * Prepares support for `grid` identifier reduction by adding it to the list
464
- of optimisations turned off when `options.safe` is set to `true`.
465
- * Adds support for normalizing `unicode-range` descriptors. Values will
466
- be converted when the code matches `0` & `f` in the same place on both sides
467
- of the range. So, `u+2000-2fff` can be converted to `u+2???`, but
468
- `u+2100-2fff` will be left as it is.
469
-
470
- # 3.9.1
471
-
472
- * Resolves an integration issue with `v3.9.0`, where `undefined` values
473
- would attempt to be parsed.
474
-
475
- # 3.9.0
476
-
477
- * Adds a new option to normalize wrapping quotes for strings & joining
478
- multiple-line strings into a single line. This optimisation can potentially
479
- reduce the final gzipped size of your CSS file.
480
-
481
- # 3.8.2
482
-
483
- * Resolves an issue where `display: list-item inline flow` would be normalized
484
- to `inline list-item` rather than `inline-list-item` (thanks to @mattbasta).
485
-
486
- # 3.8.1
487
-
488
- * Adds a quick start file for easy integration with Runkit. Try cssnano online
489
- at https://runkit.com/npm/cssnano.
490
-
491
- # 3.8.0
492
-
493
- * Adds support for normalizing multiple values for the `display` property. For
494
- example `block flow` can be simplified to `block`.
495
-
496
- # 3.7.7
497
-
498
- * Further improves CSS mixin handling; semicolons will no longer be stripped
499
- from *rules* as well as declarations.
500
-
501
- # 3.7.6
502
-
503
- * Resolves an issue where the semicolon was being incorrectly stripped
504
- from CSS mixins.
505
-
506
- # 3.7.5
507
-
508
- * Resolves an issue where the `safe` flag was not being persisted across
509
- multiple files (thanks to @techmatt101).
510
-
511
- # 3.7.4
512
-
513
- * Improves performance of the reducePositions transform by testing
514
- against `hasOwnProperty` instead of using an array of object keys.
515
- * Removes the redundant `indexes-of` dependency.
516
-
517
- # 3.7.3
518
-
519
- * Unpins postcss-filter-plugins from `2.0.0` as a fix has landed in the new
520
- version of uniqid.
521
-
522
- # 3.7.2
523
-
524
- * Temporarily pins postcss-filter-plugins to version `2.0.0` in order to
525
- mitigate an issue with uniqid `3.0.0`.
526
-
527
- # 3.7.1
528
-
529
- * Enabling safe mode now turns off both postcss-merge-idents &
530
- postcss-normalize-url's `stripWWW` option.
531
-
532
- # 3.7.0
533
-
534
- * Added: Reduce `background-repeat` definitions; works with both this property
535
- & the `background` shorthand, and aims to compress the extended two value
536
- syntax into the single value syntax.
537
- * Added: Reduce `initial` values for properties when the *actual* initial value
538
- is shorter; for example, `min-width: initial` becomes `min-width: 0`.
539
-
540
- # 3.6.2
541
-
542
- * Fixed an issue where cssnano would crash on `steps(1)`.
543
-
544
- # 3.6.1
545
-
546
- * Fixed an issue where cssnano would crash on `steps` functions with a
547
- single argument.
548
-
549
- # 3.6.0
550
-
551
- * Added `postcss-discard-overridden` to safely discard overridden rules with
552
- the same identifier (thanks to @Justineo).
553
- * Added: Reduce animation/transition timing functions. Detects `cubic-bezier`
554
- functions that are equivalent to the timing keywords and compresses, as well
555
- as normalizing the `steps` timing function.
556
- * Added the `perspective-origin` property to the list of supported properties
557
- transformed by the `reduce-positions` transform.
558
-
559
- # 3.5.2
560
-
561
- * Resolves an issue where the 3 or 4 value syntax for `background-position`
562
- were being incorrectly converted.
563
-
564
- # 3.5.1
565
-
566
- * Improves checking for `background-position` values in the `background`
567
- shorthand property.
568
-
569
- # 3.5.0
570
-
571
- * Adds a new optimisation path which can minimise keyword values for
572
- `background-position` and the `background` shorthand.
573
- * Tweaks to performance in the `core` module, now performs less AST passes.
574
- * Now compiled with Babel 6.
575
-
576
- # 3.4.0
577
-
578
- * Adds a new optimisation path which can minimise gradient parameters
579
- automatically.
580
-
581
- # 3.3.2
582
-
583
- * Fixes an issue where using `options.safe` threw an error when cssnano was
584
- not used as part of a PostCSS instance, but standalone (such as in modules
585
- like gulp-cssnano). cssnano now renames `safe` internally to `isSafe`.
586
-
587
- # 3.3.1
588
-
589
- * Unpins postcss-colormin from `2.1.2`, as the `2.1.3` & `2.1.4` patches had
590
- optimization regressions that are now resolved in `2.1.5`.
591
-
592
- # 3.3.0
593
-
594
- * Updated modules to use postcss-value-parser version 3 (thanks to @TrySound).
595
- * Now converts between transform functions with postcss-reduce-transforms.
596
- e.g. `translate3d(0, 0, 0)` becomes `translateZ(0)`.
597
-
598
- # 3.2.0
599
-
600
- * cssnano no longer converts `outline: none` to `outline: 0`, as there are
601
- some cases where the values are not equivalent (thanks to @TrySound).
602
- * cssnano no longer converts for example `16px` to `1pc` *by default*. Length
603
- optimisations can be turned on via `{convertValues: {length: true}}`.
604
- * Improved minimization of css functions (thanks to @TrySound).
605
-
606
- # 3.1.0
607
-
608
- * This release swaps postcss-single-charset for postcss-normalize-charset,
609
- which can detect encoding to determine whether a charset is necessary.
610
- Optionally, you can set the `add` option to `true` to prepend a UTF-8
611
- charset to the output automatically (thanks to @TrySound).
612
- * A `safe` option was added, which disables more aggressive optimisations, as
613
- a convenient preset configuration (thanks to @TrySound).
614
- * Added an option to convert from `deg` to `turn` & vice versa, & improved
615
- minification performance in functions (thanks to @TrySound).
616
-
617
- # 3.0.3
618
-
619
- * Fixes an issue where cssnano was removing spaces around forward slashes in
620
- string literals (thanks to @TrySound).
621
-
622
- # 3.0.2
623
-
624
- * Fixes an issue where cssnano was removing spaces around forward slashes in
625
- calc functions.
626
-
627
- # 3.0.1
628
-
629
- * Replaced css-list & balanced-match with postcss-value-parser, reducing the
630
- module's overall size (thanks to @TrySound).
631
-
632
- # 3.0.0
633
-
634
- * All cssnano plugins and cssnano itself have migrated to PostCSS 5.x. Please
635
- make sure that when using the 3.x releases that you use a 5.x compatible
636
- PostCSS runner.
637
- * cssnano will now compress inline SVG through SVGO. Because of this change,
638
- interfacing with cssnano must now be done through an asynchronous API. The
639
- main `process` method has the same signature as a PostCSS processor instance.
640
- * The old options such as `merge` & `fonts` that were deprecated in
641
- release `2.5.0` were removed. The new architecture allows you to specify any
642
- module name to disable it.
643
- * postcss-minify-selectors' at-rule compression was extracted out into
644
- postcss-minify-params (thanks to @TrySound).
645
- * Overall performance of the module has improved dramatically, thanks to work
646
- by @TrySound and input from the community.
647
- * Improved selector merging/deduplication in certain use cases.
648
- * cssnano no longer compresses hex colours in filter properties, to better
649
- support old versions of Internet Explorer (thanks to @faddee).
650
- * cssnano will not merge properties together that have an `inherit` keyword.
651
- * postcss-minify-font-weight & postcss-font-family were consolidated into
652
- postcss-minify-font-values. Using the old options will print deprecation
653
- warnings (thanks to @TrySound).
654
- * The cssnano CLI was extracted into a separate module, so that dependent
655
- modules such as gulp-cssnano don't download unnecessary extras.
656
-
657
- # 2.6.1
658
-
659
- * Improved performance of the core module `functionOptimiser`.
660
-
661
- # 2.6.0
662
-
663
- * Adds a new optimisation which re-orders properties that accept values in
664
- an arbitrary order. This can lead to improved merging behaviour in certain
665
- cases.
666
-
667
- # 2.5.0
668
-
669
- * Adds support for disabling modules of the user's choosing, with new option
670
- names. The old options (such as `merge` & `fonts`) will be removed in `3.0`.
671
-
672
- # 2.4.0
673
-
674
- * postcss-minify-selectors was extended to add support for conversion of
675
- `::before` to `:before`; this release removes the dedicated
676
- postcss-pseudoelements module.
677
-
678
- # 2.3.0
679
-
680
- * Consolidated postcss-minify-trbl & two integrated modules into
681
- postcss-merge-longhand.
682
-
683
- # 2.2.0
684
-
685
- * Replaced integrated plugin filter with postcss-filter-plugins.
686
- * Improved rule merging logic.
687
- * Improved performance across the board by reducing AST iterations where it
688
- was possible to do so.
689
- * cssnano will now perform better whitespace compression when used with other
690
- PostCSS plugins.
691
-
692
- # 2.1.1
693
-
694
- * Fixes an issue where options were not passed to normalize-url.
695
-
696
- # 2.1.0
697
-
698
- * Allow `postcss-font-family` to be disabled.
699
-
700
- # 2.0.3
701
-
702
- * cssnano can now be consumed with the parentheses-less method in PostCSS; e.g.
703
- `postcss([ cssnano ])`.
704
- * Fixes an issue where 'Din' was being picked up by the logic as a numeric
705
- value, causing the full font name to be incorrectly rearranged.
706
-
707
- # 2.0.2
708
-
709
- * Extract trbl value reducing into a separate module.
710
- * Refactor core longhand optimiser to not rely on trbl cache.
711
- * Adds support for `ch` units; previously they were removed.
712
- * Fixes parsing of some selector hacks.
713
- * Fixes an issue where embedded base 64 data was being converted as if it were
714
- a URL.
715
-
716
- # 2.0.1
717
-
718
- * Add `postcss-plugin` keyword to package.json.
719
- * Wraps all core processors with the PostCSS 4.1 plugin API.
720
-
721
- # 2.0.0
722
-
723
- * Adds removal of outdated vendor prefixes based on browser support.
724
- * Addresses an issue where relative path separators were converted to
725
- backslashes on Windows.
726
- * cssnano will now detect previous plugins and silently disable them when the
727
- functionality overlaps. This is to enable faster interoperation with cssnext.
728
- * cssnano now exports as a PostCSS plugin. The simple interface is exposed
729
- at `cssnano.process(css, opts)` instead of `cssnano(css, opts)`.
730
- * Improved URL detection when using two or more in the same declaration.
731
- * node 0.10 is no longer officially supported.
732
-
733
- # 1.4.3
734
-
735
- * Fixes incorrect minification of `background:none` to `background:0 0`.
736
-
737
- # 1.4.2
738
-
739
- * Fixes an issue with nested URLs inside `url()` functions.
740
-
741
- # 1.4.1
742
-
743
- * Addresses an issue where whitespace removal after a CSS function would cause
744
- rendering issues in Internet Explorer.
745
-
746
- # 1.4.0
747
-
748
- * Adds support for removal of unused `@keyframes` and `@counter-style` at-rules.
749
- * comments: adds support for user-directed removal of comments, with the
750
- `remove` option (thanks to @dmitrykiselyov).
751
- * comments: `removeAllButFirst` now operates on each CSS tree, rather than the
752
- first one passed to cssnano.
753
-
754
- # 1.3.3
755
-
756
- * Fixes incorrect minification of `border:none` to `border:0 0`.
757
-
758
- # 1.3.2
759
-
760
- * Improved selector minifying logic, leading to better compression of attribute
761
- selectors.
762
- * Improved comment discarding logic.
763
-
764
- # 1.3.1
765
-
766
- * Fixes crash on undefined `decl.before` from prior AST.
767
-
768
- # 1.3.0
769
-
770
- * Added support for bundling cssnano using webpack (thanks to @MoOx).
771
-
772
- # 1.2.1
773
-
774
- * Fixed a bug where a CSS function keyword inside its value would throw
775
- an error.
776
-
777
- # 1.2.0
778
-
779
- * Better support for merging properties without the existance of a shorthand
780
- override.
781
- * Can now 'merge forward' adjacent rules as well as the previous 'merge behind'
782
- behaviour, leading to better compression.
783
- * Selector re-ordering now happens last in the chain of plugins, to help clean
784
- up merged selectors.
785
-
786
- # 1.1.0
787
-
788
- * Now can merge identifiers such as `@keyframes` and `@counter-style` if they
789
- have duplicated properties but are named differently.
790
- * Fixes an issue where duplicated keyframes with the same name would cause
791
- an infinite loop.
792
-
793
- # 1.0.2
794
-
795
- * Improve module loading logic (thanks to @tunnckoCore).
796
- * Improve minification of numeric values, with better support for `rem`,
797
- trailing zeroes and slash/comma separated values
798
- (thanks to @TrySound & @tunnckoCore).
799
- * Fixed an issue where `-webkit-tap-highlight-color` values were being
800
- incorrectly transformed to `transparent`. This is not supported in Safari.
801
- * Added support for viewport units (thanks to @TrySound).
802
- * Add MIT license file.
803
-
804
- # 1.0.1
805
-
806
- * Add repository/author links to package.json.
807
-
808
- # 1.0.0
809
-
810
- * Initial release.