Sha256: 16ec394e96df635307cdca7215e155b1b8ad976225a98ec2a88deb55df4d5c6f

Contents?: true

Size: 488 Bytes

Versions: 176

Compression:

Stored size: 488 Bytes

Contents

# frozen_string_literal: true

module Primer
  module Forms
    module Dsl
      # :nodoc:
      class FormObject
        include InputMethods

        attr_reader :builder, :form

        def initialize(builder:, form:)
          @builder = builder
          @form = form

          yield(self) if block_given?
        end

        def group(**options, &block)
          add_input InputGroup.new(builder: @builder, form: @form, **options, &block)
        end
      end
    end
  end
end

Version data entries

176 entries across 176 versions & 2 rubygems

Version Path
openproject-primer_view_components-0.6.3 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.6.0 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.5.1 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.5.0 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.4.0 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.3.1 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.3.0 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.2.0 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.9 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.8 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.7 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.6 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.5 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.4 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.3 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.2 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.1 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.1.0 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.0.123 lib/primer/forms/dsl/form_object.rb
primer_view_components-0.0.122 lib/primer/forms/dsl/form_object.rb