Open GoogleCodeExporter opened 9 years ago
I have the same issue.
Input:
@font-face {
font-family: 'Glyphicons Halflings';
src: url(if($bootstrap-sass-asset-helper, twbs-font-path('#{$icon-font-path}#{$icon-font-name}.eot'), '#{$icon-font-path}#{$icon-font-name}.eot'));
src: url(if($bootstrap-sass-asset-helper, twbs-font-path('#{$icon-font-path}#{$icon-font-name}.eot?#iefix'), '#{$icon-font-path}#{$icon-font-name}.eot?#iefix')) format('embedded-opentype'),
url(if($bootstrap-sass-asset-helper, twbs-font-path('#{$icon-font-path}#{$icon-font-name}.woff'), '#{$icon-font-path}#{$icon-font-name}.woff')) format('woff'),
url(if($bootstrap-sass-asset-helper, twbs-font-path('#{$icon-font-path}#{$icon-font-name}.ttf'), '#{$icon-font-path}#{$icon-font-name}.ttf')) format('truetype'),
url(if($bootstrap-sass-asset-helper, twbs-font-path('#{$icon-font-path}#{$icon-font-name}.svg##{$icon-font-svg-id}'), '#{$icon-font-path}#{$icon-font-name}.svg##{$icon-font-svg-id}')) format('svg');
}
.glyphicon {
position: relative;
top: 1px;
display: inline-block;
font-family: 'Glyphicons Halflings';
font-style: normal;
font-weight: normal;
line-height: 1;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
Output using cssmin 3.0.1:
@font-face{position:relative;top:1px;display:inline-block;font-family:'Glyphicon
s
Halflings';font-style:normal;font-weight:normal;line-height:1;-webkit-font-smoot
hing:antialiased;-moz-osx-font-smoothing:grayscale;}
Original comment by towang...@gmail.com
on 28 Jan 2015 at 2:40
**SOLVED**
----------
I have the same problem,
and i solved it by just adding a space after @font-face
$css = file_get_contents(/*whatever*/);
$css = str_replace('@font-face', '@font-face ', $css);
$minified = CssMin::minify(css);
Original comment by ahmed.s....@gmail.com
on 29 Mar 2015 at 2:23
Original issue reported on code.google.com by
s.weiguny
on 27 Feb 2014 at 11:30Attachments: