Class: Pageflow::BackgroundImageHelper::DivWithSizeAttributes
- Defined in:
- app/helpers/pageflow/background_image_helper.rb
Constant Summary
Constants inherited from Div
Pageflow::BackgroundImageHelper::Div::FILE_TYPE_CSS_CLASS_PREFIXES
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
80 81 82 83 84 85 86 |
# File 'app/helpers/pageflow/background_image_helper.rb', line 80 def data_attributes if file super.merge(:width => file.width, :height => file.height) else super end end |
#inline_style ⇒ Object
88 89 90 91 92 93 94 |
# File 'app/helpers/pageflow/background_image_helper.rb', line 88 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 |