mirror of
https://github.com/haml/haml.git
synced 2022-11-09 12:33:31 -05:00
[Sass] Make sure !important is converted to !important.
This commit is contained in:
parent
d67de1c368
commit
e6961f0e01
2 changed files with 6 additions and 0 deletions
|
@ -14,6 +14,7 @@ module Sass
|
|||
|
||||
# @return [String] A string representation of the variable
|
||||
def inspect
|
||||
return "!important" if name == "important"
|
||||
"$#{name}"
|
||||
end
|
||||
alias_method :to_sass, :inspect
|
||||
|
|
|
@ -60,6 +60,11 @@ Use "$tumbly-wumbly" instead.
|
|||
WARN
|
||||
end
|
||||
|
||||
def test_important
|
||||
assert_renders "!important"
|
||||
assert_renders "$foo !important"
|
||||
end
|
||||
|
||||
def test_comma_operator
|
||||
assert_renders "$foo, $bar $baz"
|
||||
assert_renders "$foo $bar, $baz"
|
||||
|
|
Loading…
Add table
Reference in a new issue