Class: Katalyst::GOVUK::FormBuilder::Elements::RichTextarea
- Inherits:
-
GOVUKDesignSystemFormBuilder::Base
- Object
- GOVUKDesignSystemFormBuilder::Base
- Katalyst::GOVUK::FormBuilder::Elements::RichTextarea
- Includes:
- GOVUKDesignSystemFormBuilder::Traits::Error, GOVUKDesignSystemFormBuilder::Traits::HTMLAttributes, GOVUKDesignSystemFormBuilder::Traits::HTMLClasses, GOVUKDesignSystemFormBuilder::Traits::Hint, GOVUKDesignSystemFormBuilder::Traits::Label, GOVUKDesignSystemFormBuilder::Traits::Supplemental
- Defined in:
- lib/katalyst/govuk/form_builder/elements/rich_textarea.rb
Instance Method Summary collapse
- #html ⇒ Object
-
#initialize(builder, object_name, attribute_name, hint:, label:, caption:, form_group:, **kwargs) ⇒ RichTextarea
constructor
A new instance of RichTextarea.
Constructor Details
#initialize(builder, object_name, attribute_name, hint:, label:, caption:, form_group:, **kwargs) ⇒ RichTextarea
Returns a new instance of RichTextarea.
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/katalyst/govuk/form_builder/elements/rich_textarea.rb', line 19 def initialize( builder, object_name, attribute_name, hint:, label:, caption:, form_group:, **kwargs, & ) super(builder, object_name, attribute_name, &) @label = label @caption = caption @hint = hint @form_group = form_group @html_attributes = kwargs end |
Instance Method Details
#html ⇒ Object
39 40 41 42 43 |
# File 'lib/katalyst/govuk/form_builder/elements/rich_textarea.rb', line 39 def html GOVUKDesignSystemFormBuilder::Containers::FormGroup.new(*bound, **@form_group).html do safe_join([label_element, supplemental_content, hint_element, error_element, rich_textarea]) end end |