Class: NfgUi::Components::Patterns::TileBody
- Inherits:
-
Base
- Object
- Bootstrap::Components::Base
- Base
- NfgUi::Components::Patterns::TileBody
- Includes:
- Utilities::Iconable
- Defined in:
- lib/nfg_ui/components/patterns/tile_body.rb
Overview
TileBody doc coming soon
Constant Summary
Constants included from Traits
Traits::REGISTERED_TRAITS, Traits::TRAIT_MODULES
Instance Attribute Summary
Attributes inherited from Bootstrap::Components::Base
#body, #options, #view_context
Instance Method Summary collapse
Methods included from Utilities::Iconable
Methods included from Utilities::Traitable
Methods included from Utilities::Renderable
Methods included from Utilities::Describable
Methods inherited from Bootstrap::Components::Base
#data, #href, #html_options, #id, #initialize, #style
Constructor Details
This class inherits a constructor from NfgUi::Bootstrap::Components::Base
Instance Method Details
#component_family ⇒ Object
14 15 16 |
# File 'lib/nfg_ui/components/patterns/tile_body.rb', line 14 def component_family :tile end |
#heading ⇒ Object
10 11 12 |
# File 'lib/nfg_ui/components/patterns/tile_body.rb', line 10 def heading .fetch(:heading, nil) end |
#render ⇒ Object
18 19 20 21 22 23 24 25 |
# File 'lib/nfg_ui/components/patterns/tile_body.rb', line 18 def render super do if heading concat(NfgUi::Components::Foundations::Typeface.new({ heading: heading, icon: icon }, view_context).render) end concat((block_given? ? yield : body)) end end |