Class: Railsboot::CloseButtonComponent
- Inherits:
-
Component
- Object
- Component
- Railsboot::CloseButtonComponent
- Defined in:
- app/components/railsboot/close_button_component.rb
Instance Method Summary collapse
-
#initialize(disabled: false, **html_attributes) ⇒ CloseButtonComponent
constructor
A new instance of CloseButtonComponent.
Constructor Details
#initialize(disabled: false, **html_attributes) ⇒ CloseButtonComponent
Returns a new instance of CloseButtonComponent.
2 3 4 5 6 7 8 9 10 |
# File 'app/components/railsboot/close_button_component.rb', line 2 def initialize(disabled: false, **html_attributes) @disabled = disabled @html_attributes = html_attributes @html_attributes[:class] = class_names( "btn-close", html_attributes.delete(:class) ) end |