Sha256: e20ef5fc9b095ec27aa4bb8bbcc8d3c61856270fd72190720625a77b614ca32c
Contents?: true
Size: 499 Bytes
Versions: 61
Compression:
Stored size: 499 Bytes
Contents
# frozen_string_literal: true module UiBibzInputs class UiBoxSwitchFieldInput < BaseInput include UiBibz::Ui::Core::Forms::Choices def input(_wrapper_options) UiBibz::Ui::Core::Forms::Choices::BoxSwitchField.new(input_attribute_name, options, new_input_html_options).render end def new_input_html_options input_html_options.merge({ checked: value.nil? ? false : value }) end def value @value ||= @builder.object.send(attribute_name) end end end
Version data entries
61 entries across 61 versions & 1 rubygems