Class: GOVUKDesignSystemFormBuilder::Elements::Radios::FieldsetRadioButton
- Inherits:
-
Base
- Object
- Base
- GOVUKDesignSystemFormBuilder::Elements::Radios::FieldsetRadioButton
- Defined in:
- lib/govuk_design_system_formbuilder/elements/radios/fieldset_radio_button.rb
Instance Method Summary collapse
-
#initialize(builder, object_name, attribute_name, value, label:, hint:, link_errors:, **kwargs, &block) ⇒ FieldsetRadioButton
constructor
A new instance of FieldsetRadioButton.
Methods included from Traits::FieldsetItem
Methods included from Traits::HTMLAttributes
Methods included from Traits::Hint
Methods inherited from Base
Constructor Details
#initialize(builder, object_name, attribute_name, value, label:, hint:, link_errors:, **kwargs, &block) ⇒ FieldsetRadioButton
Returns a new instance of FieldsetRadioButton.
10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/govuk_design_system_formbuilder/elements/radios/fieldset_radio_button.rb', line 10 def initialize(builder, object_name, attribute_name, value, label:, hint:, link_errors:, **kwargs, &block) super(builder, object_name, attribute_name, &block) @value = value @label = label @hint = hint @link_errors = has_errors? && link_errors @html_attributes = kwargs conditional_content(@block_content) end |