Sha256: 330d7696318b4ff5becd1a4118f5a05fce5173d89dd71b43a85059cdbd4ec909

Contents?: true

Size: 469 Bytes

Versions: 2

Compression:

Stored size: 469 Bytes

Contents

# frozen_string_literal: true

module Yattho
  module Forms
    module Dsl
      # :nodoc:
      class HiddenInput < Input
        attr_reader :name

        def initialize(name:, **system_arguments)
          @name = name
          super(**system_arguments)
        end

        def to_component
          HiddenField.new(input: self)
        end

        def label
          nil
        end

        def type
          :hidden
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
yattho_view_components-0.1.1 lib/yattho/forms/dsl/hidden_input.rb
yattho_view_components-0.0.1 lib/yattho/forms/dsl/hidden_input.rb