Method: Less::Node::Color#to_s
- Defined in:
- lib/less/engine/nodes/literal.rb
#to_s ⇒ Object
51 52 53 54 55 56 57 |
# File 'lib/less/engine/nodes/literal.rb', line 51 def to_s if a < 1.0 "rgba(#{r.to_i}, #{g.to_i}, #{b.to_i}, #{a})" else "#%02x%02x%02x" % [r, g, b] end end |