Don't output transparent in css2 ouput.
Closes GH-309
This commit is contained in:
parent
a7b8689fb8
commit
119ce9d018
@ -92,4 +92,22 @@ module Sass::Script
|
||||
end
|
||||
end
|
||||
|
||||
class String < Literal
|
||||
def supports?(aspect)
|
||||
aspect == "css2" && value == "transparent" && type == :identifier
|
||||
end
|
||||
|
||||
def has_aspect?
|
||||
true
|
||||
end
|
||||
|
||||
def to_css2(options = self.options)
|
||||
if value == "transparent" && type == :identifier
|
||||
Sass::Script::String.new("")
|
||||
else
|
||||
dup
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
@ -87,6 +87,7 @@ class SassExtensionsTest < Test::Unit::TestCase
|
||||
assert_equal "true", evaluate("blank('')")
|
||||
assert_equal "true", evaluate("blank(' ')")
|
||||
assert_equal "true", evaluate("blank(-compass-space-list(' '))")
|
||||
assert_equal " ", evaluate("-css2(transparent linear-gradient(#fff,#000))")
|
||||
end
|
||||
|
||||
protected
|
||||
|
Loading…
Reference in New Issue
Block a user