1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

[Sass] Add MixinNode#to_sass.

This commit is contained in:
Nathan Weizenbaum 2010-01-26 23:08:52 -08:00
parent bd8b6165ca
commit 5d1c87ff4a

View file

@ -20,6 +20,12 @@ module Sass::Tree
_cssize(parent) # Pass on the parent even if it's not a MixinNode
end
# @see Node#to_sass
def to_sass(tabs, opts = {})
args = '(' + @args.map {|a| a.to_sass}.join(", ") + ')' unless @args.empty?
"#{' ' * tabs}+#{@name}#{args}"
end
protected
# @see Node#_cssize