Sha256: 4199c8253a4ea72b8e8d7ac8864fbb531e9dddbefe719dbb6fef3945ec52f591

Contents?: true

Size: 325 Bytes

Versions: 133

Compression:

Stored size: 325 Bytes

Contents

# frozen_string_literal: true

module Primer
  module Forms
    # :nodoc:
    class FormReference < BaseComponent
      delegate :builder, :form, to: :@input

      def initialize(input:)
        @input = input
      end

      def builder_or_view
        @input.nested? ? builder : @view_context
      end
    end
  end
end

Version data entries

133 entries across 133 versions & 2 rubygems

Version Path
primer_view_components-0.35.2 app/lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.49.1 app/lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.49.0 app/lib/primer/forms/form_reference.rb
primer_view_components-0.35.1 app/lib/primer/forms/form_reference.rb
primer_view_components-0.35.0 app/lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.48.2 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.48.1 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.48.0 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.47.1 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.47.0 lib/primer/forms/form_reference.rb
primer_view_components-0.34.0 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.46.1 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.46.0 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.45.0 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.44.3 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.44.2 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.44.1 lib/primer/forms/form_reference.rb
primer_view_components-0.33.0 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.44.0 lib/primer/forms/form_reference.rb
openproject-primer_view_components-0.43.1 lib/primer/forms/form_reference.rb