Class: Pageflow::BackgroundImageHelper::DivWithSizeAttributes
- Defined in:
- app/helpers/pageflow/background_image_helper.rb
Instance Attribute Summary
Attributes inherited from Div
#configuration, #options, #property_base_name
Instance Method Summary collapse
Methods inherited from Div
Constructor Details
This class inherits a constructor from Pageflow::BackgroundImageHelper::Div
Instance Method Details
#data_attributes ⇒ Object
81 82 83 84 85 86 87 |
# File 'app/helpers/pageflow/background_image_helper.rb', line 81 def data_attributes if file super.merge(:width => file.width, :height => file.height) else super end end |
#inline_style ⇒ Object
89 90 91 92 93 94 95 |
# File 'app/helpers/pageflow/background_image_helper.rb', line 89 def inline_style if [:spanning] "padding-top: #{padding_top}%; width: 100%; background-position: 0 0" # fix me (yet disables background_position option) else super end end |