Class: Tailwinds::Form::SubmitButtonComponent
- Inherits:
-
TailwindComponent
- Object
- ViewComponent::Base
- Tramway::Component::Base
- TailwindComponent
- Tailwinds::Form::SubmitButtonComponent
- Defined in:
- app/components/tailwinds/form/submit_button_component.rb
Overview
Tailwind-styled submit button
Instance Method Summary collapse
-
#initialize(action, **options) ⇒ SubmitButtonComponent
constructor
A new instance of SubmitButtonComponent.
Methods included from Tramway::Helpers::ComponentHelper
Constructor Details
#initialize(action, **options) ⇒ SubmitButtonComponent
Returns a new instance of SubmitButtonComponent.
7 8 9 10 11 |
# File 'app/components/tailwinds/form/submit_button_component.rb', line 7 def initialize(action, **) @options = .except :type @text = action.is_a?(String) ? action : action.to_s.capitalize end |