[3.1.4 / 2015-xx-xx](https://github.com/jakubpawlowicz/clean-css/compare/v3.1.3...3.1)
==================
+* Fixes issue [#472](https://github.com/jakubpawlowicz/clean-css/issues/472) - broken function minification.
* Fixes issue [#477](https://github.com/jakubpawlowicz/clean-css/issues/477) - `@import`s order in restructuring.
* Fixes issue [#478](https://github.com/jakubpawlowicz/clean-css/issues/478) - ultimate fix to brace whitespace.
var addSourceMap = context.addSourceMap;
if (string.replace && string.indexOf(')') > 0)
- string = string.replace(/\)([^\s_;:,])/g, context.addSourceMap ? ') __ESCAPED_COMMENT_CLEAN_CSS(0,-1)__$1' : ') $1');
+ string = string.replace(/\)([^\s_;:,\)])/g, context.addSourceMap ? ') __ESCAPED_COMMENT_CLEAN_CSS(0,-1)__$1' : ') $1');
for (var i = 0, l = string.length; i < l; i++) {
current = string[i];
'gets right output': function (minified) {
assert.equal(minified.styles, 'html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}');
}
+ },
+ 'background gradient': {
+ 'topic': new CleanCSS({ sourceMap: true }).minify('a{background: linear-gradient(to bottom, rgba(0, 0, 0, 0.1) 0, rgba(0, 0, 0, 0.1))}'),
+ 'gets right output': function (minified) {
+ assert.equal(minified.styles, 'a{background:linear-gradient(to bottom,rgba(0,0,0,.1) 0,rgba(0,0,0,.1))}');
+ }
}
})
.addBatch({