Sha256: 62ce52c58f2b34028f375e2cdf6af3ba200c0a855ed3023490e34ed42cf90c04
Contents?: true
Size: 726 Bytes
Versions: 41
Compression:
Stored size: 726 Bytes
Contents
# frozen_string_literal: true module Ariadne module Forms module Dsl # :nodoc: class ButtonInput < Input attr_reader :name, :label, :block def initialize(name:, label:, **options, &block) @name = name @label = label @caption = options.delete(:caption) @block = block super(**options) end def to_component html_attrs = @input_attributes || {} Ariadne::UI::Button::Component.new(**@options, html_attrs: html_attrs).with_content(@label) end # :nocov: def type :button end def supports_validation? false end end end end end
Version data entries
41 entries across 41 versions & 1 rubygems