Class: LocastyleComponents::Tags::Collapse
- Defined in:
- lib/locastyle_components/tags/collapse.rb
Overview
Instance Attribute Summary collapse
-
#block ⇒ Object
Returns the value of attribute block.
-
#id ⇒ Object
Returns the value of attribute id.
-
#options ⇒ Object
Returns the value of attribute options.
-
#view ⇒ Object
Returns the value of attribute view.
Instance Method Summary collapse
- #build ⇒ Object
-
#initialize(view, block, options) ⇒ Collapse
constructor
A new instance of Collapse.
Constructor Details
#initialize(view, block, options) ⇒ Collapse
Returns a new instance of Collapse.
10 11 12 13 14 15 |
# File 'lib/locastyle_components/tags/collapse.rb', line 10 def initialize(view, block, ) @view = view = Hash() @id = Time.now.to_f.to_s.gsub(/\D/, '') @block = block end |
Instance Attribute Details
#block ⇒ Object
Returns the value of attribute block.
8 9 10 |
# File 'lib/locastyle_components/tags/collapse.rb', line 8 def block @block end |
#id ⇒ Object
Returns the value of attribute id.
8 9 10 |
# File 'lib/locastyle_components/tags/collapse.rb', line 8 def id @id end |
#options ⇒ Object
Returns the value of attribute options.
8 9 10 |
# File 'lib/locastyle_components/tags/collapse.rb', line 8 def end |
#view ⇒ Object
Returns the value of attribute view.
8 9 10 |
# File 'lib/locastyle_components/tags/collapse.rb', line 8 def view @view end |
Instance Method Details
#build ⇒ Object
17 18 19 20 21 |
# File 'lib/locastyle_components/tags/collapse.rb', line 17 def build base do header + body end end |