mirror of
https://github.com/haml/haml.git
synced 2022-11-09 12:33:31 -05:00
16 lines
399 B
Ruby
16 lines
399 B
Ruby
require 'sass/tree/node'
|
|
|
|
module Sass::Tree
|
|
class CommentNode < ValueNode
|
|
def initialize(value, style)
|
|
super(value[2..-1].strip, style)
|
|
end
|
|
|
|
def to_s(parent_name = nil)
|
|
unless @style == :compressed
|
|
join_string = @style == :compact ? ' ' : "\n * "
|
|
"/* #{value}#{join_string unless children.empty?}#{children.join join_string} */"
|
|
end
|
|
end
|
|
end
|
|
end
|