Class: SyntaxTree::Haml::Tag::HashAttributesPart
- Inherits:
-
Struct
- Object
- Struct
- SyntaxTree::Haml::Tag::HashAttributesPart
- Defined in:
- lib/syntax_tree/haml/tag.rb
Instance Attribute Summary collapse
-
#values ⇒ Object
Returns the value of attribute values.
Instance Method Summary collapse
Instance Attribute Details
#values ⇒ Object
Returns the value of attribute values
70 71 72 |
# File 'lib/syntax_tree/haml/tag.rb', line 70 def values @values end |
Instance Method Details
#format(q, align) ⇒ Object
71 72 73 |
# File 'lib/syntax_tree/haml/tag.rb', line 71 def format(q, align) format_value(q, values) end |
#length ⇒ Object
75 76 77 78 79 |
# File 'lib/syntax_tree/haml/tag.rb', line 75 def length values.sum do |key, value| key.length + (value.is_a?(String) ? value : value.to_s).length + 3 end end |