Sha256: 28e22fab8eb1afaede238fe443ddd7043a2ba70e1d6f19ece1d1f591df9a1e9c
Contents?: true
Size: 1.29 KB
Versions: 49
Compression:
Stored size: 1.29 KB
Contents
# typed: false # frozen_string_literal: true module Ariadne module Form module RadioButtonGroup class Component < Ariadne::Form::BaseInputComponent option :name option :label, optional: true option :label_attributes, default: -> { {} } option :input_arguments, default: -> { {} } option :label_arguments, default: -> { {} } def initialize(**) super @choices = [] end def radio_button(**options) @choices << Ariadne::Form::RadioButton::Component.new(name: @name, **options) end def rendered_radio_button(radio_button) @choices << radio_button end style do base do end end style :group do base do [ "ariadne-gap-2", "ariadne-flex", "ariadne-flex-col", "ariadne-space-y-1", ] end end style :label do base do [ "ariadne-text-sm", "ariadne-font-medium", "ariadne-leading-none", "peer-disabled:ariadne-cursor-not-allowed", "peer-disabled:ariadne-opacity-70", ] end end end end end end
Version data entries
49 entries across 49 versions & 1 rubygems