Class: BootstrapComponentsHelpers::ModalHelper::ModalBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/bootstrap-components-helpers/modal_helper.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(parent) ⇒ ModalBuilder

Returns a new instance of ModalBuilder.



30
31
32
# File 'lib/bootstrap-components-helpers/modal_helper.rb', line 30

def initialize parent
  @parent = parent
end

Instance Attribute Details

#body_contentObject (readonly)

Returns the value of attribute body_content.



27
28
29
# File 'lib/bootstrap-components-helpers/modal_helper.rb', line 27

def body_content
  @body_content
end

Returns the value of attribute footer_content.



27
28
29
# File 'lib/bootstrap-components-helpers/modal_helper.rb', line 27

def footer_content
  @footer_content
end

#parentObject (readonly)

Returns the value of attribute parent.



27
28
29
# File 'lib/bootstrap-components-helpers/modal_helper.rb', line 27

def parent
  @parent
end

Instance Method Details

#body(&block) ⇒ Object



34
35
36
# File 'lib/bootstrap-components-helpers/modal_helper.rb', line 34

def body &block
  @body_content = capture(&block)
end


38
39
40
# File 'lib/bootstrap-components-helpers/modal_helper.rb', line 38

def footer &block
  @footer_content = capture(&block)
end