mirror of
https://github.com/mrclay/minify.git
synced 2025-02-21 07:22:26 +01:00
+ BMH and MSIE filters to css/hacks.css. Minify_CSS no longer minifies RGB colors in MSIE filters.
This commit is contained in:
parent
1c1a6f327d
commit
e9035109c9
@ -126,8 +126,8 @@ class Minify_CSS {
|
||||
,array('Minify_CSS', '_selectorsCB'), $css);
|
||||
|
||||
// minimize hex colors
|
||||
$css = preg_replace('/#([a-f\\d])\\1([a-f\\d])\\2([a-f\\d])\\3([\\s;\\}])/i'
|
||||
, '#$1$2$3$4', $css);
|
||||
$css = preg_replace('/([^=])#([a-f\\d])\\2([a-f\\d])\\3([a-f\\d])\\4([\\s;\\}])/i'
|
||||
, '$1#$2$3$4$5', $css);
|
||||
|
||||
$rewrite = false;
|
||||
if (isset($options['prependRelativePath'])) {
|
||||
|
@ -2,30 +2,43 @@
|
||||
.foo {color:red}
|
||||
/* necessary comment */
|
||||
|
||||
/* comment */
|
||||
/* comment to attempt to confuse parser */
|
||||
|
||||
/* feed to ie5/mac \*//*/
|
||||
@import "ie5mac.css";
|
||||
/* necessary comment */
|
||||
|
||||
/* comment */
|
||||
/* comment to attempt to confuse parser */
|
||||
|
||||
/*/ hide from nav4 */
|
||||
.foo {display:block;}
|
||||
/* necessary comment */
|
||||
|
||||
/* comment */
|
||||
/* comment to attempt to confuse parser */
|
||||
|
||||
/*/ feed to nav *//*/
|
||||
.foo {display:crazy;}
|
||||
/* necessary comment */
|
||||
|
||||
/* comment */
|
||||
|
||||
/* hide props from various IE/win */
|
||||
div {
|
||||
width: 140px;
|
||||
width/* */:/**/100px;
|
||||
width: /**/100px;
|
||||
}
|
||||
|
||||
html>/**/body {}
|
||||
html>/**/body {}
|
||||
|
||||
/* Tantek's box model hack */
|
||||
div {
|
||||
width:400px;
|
||||
voice-family: "\"}\"";
|
||||
voice-family:inherit;
|
||||
width:300px;
|
||||
}
|
||||
|
||||
/* don't minimize hex colors in filters */
|
||||
div {
|
||||
filter:chroma(color=#aabbcc);
|
||||
filter:mask(color=#000000) shadow(color=#9BAD71, direction=135) chroma(color=#000000);
|
||||
}
|
2
web/test/_test_files/css/hacks.min.css
vendored
2
web/test/_test_files/css/hacks.min.css
vendored
@ -1 +1 @@
|
||||
/*\*/a{}.foo{color:red}/**//*\*//*/@import "ie5mac.css";/**//*/*/.foo{display:block}/**//*/*//*/.foo{display:crazy}/**/div{width:140px;width/**/:/**/100px;width:/**/100px}html>/**/body{}
|
||||
/*\*/a{}.foo{color:red}/**//*\*//*/@import "ie5mac.css";/**//*/*/.foo{display:block}/**//*/*//*/.foo{display:crazy}/**/div{width:140px;width/**/:/**/100px;width:/**/100px}html>/**/body{}div{width:400px;voice-family: "\"}\"";voice-family:inherit;width:300px}div{filter:chroma(color=#aabbcc);filter:mask(color=#000000) shadow(color=#9BAD71, direction=135) chroma(color=#000000)}
|
Loading…
x
Reference in New Issue
Block a user