Class: HtmlSlicer::Mappers::Resizing::Map
- Inherits:
-
Hash
- Object
- Hash
- HtmlSlicer::Mappers::Resizing::Map
- Includes:
- Utilities::NodeIdent
- Defined in:
- lib/html_slicer/mappers/resizing.rb
Overview
:nodoc:
Instance Method Summary collapse
Methods included from Utilities::NodeIdent
Instance Method Details
#commit(node, width, height) ⇒ Object
10 11 12 |
# File 'lib/html_slicer/mappers/resizing.rb', line 10 def commit(node, width, height) self[node_identify(node)] = [width, height] end |
#height(node) ⇒ Object
16 17 18 |
# File 'lib/html_slicer/mappers/resizing.rb', line 16 def height(node) self[node_identify(node)].try(:last) end |
#width(node) ⇒ Object
13 14 15 |
# File 'lib/html_slicer/mappers/resizing.rb', line 13 def width(node) self[node_identify(node)].try(:first) end |