Compass / compass

Compass is no longer actively maintained. Compass is a Stylesheet Authoring Environment that makes your website design simpler to implement and easier to maintain.
http://compass-style.org
Other
6.72k stars 1.18k forks source link

using images with color names breaks output_style = :compressed #1543

Open mrbase opened 10 years ago

mrbase commented 10 years ago

we use "color dots" to show true colors on a webshop, but when we set output_style = :compressed the build breaks because compass shortens "black" into #000 - which won't do for naming. the error is:

Syntax error: Invalid CSS after "&:active, &.": expected class name, was "#000_active, &...."
        on line 43 of /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/frameworks/compass/stylesheets/compass/utilities/sprites/_base.scss, in `sprite-selectors'
        from line 33 of /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/frameworks/compass/stylesheets/compass/utilities/sprites/_base.scss, in `sprite'
        from line 62 of /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/frameworks/compass/stylesheets/compass/utilities/sprites/_base.scss, in `sprites'
        from line 871 of colorbuttons/*.png, in `colorbuttons-sprites'
        from line 875 of colorbuttons/*.png, in `all-colorbuttons-sprites'
        from line 161 of /Users/.../sass/_product.scss
        from line 82 of /Users/.../sass/style.scss

we use import to parse a directory:

@import "colorbuttons/*.png";
@include all-colorbuttons-sprites;

here are some sample image files:

black.png
black_active.png
blue.png
blue_active.png
brown.png
brown_active.png
...

is there a way to prevent compass from doing this ? is it a known bug or ... ?

i have the full backtrace if you need it.

chriseppstein commented 10 years ago

Looks like a bug. Will address this post 1.0 release.