Sha256: 49921b81c6f7c8510b57fb99688f131bec188b1b708c9228de75a8296d0caae2

Contents?: true

Size: 316 Bytes

Versions: 111

Compression:

Stored size: 316 Bytes

Contents

# frozen_string_literal: true

module Primer
  # :nodoc:
  module Forms
    def self.inline_form(builder, base = nil, &block)
      base ||= defined?(ApplicationForm) ? ApplicationForm : Primer::Forms::Base

      klass = Class.new(base) do
        form(&block)
      end

      klass.new(builder)
    end
  end
end

Version data entries

111 entries across 111 versions & 2 rubygems

Version Path
openproject-primer_view_components-0.33.0 lib/primer/forms.rb
primer_view_components-0.25.1 lib/primer/forms.rb
openproject-primer_view_components-0.32.1 lib/primer/forms.rb
openproject-primer_view_components-0.32.0 lib/primer/forms.rb
openproject-primer_view_components-0.29.1 lib/primer/forms.rb
openproject-primer_view_components-0.29.0 lib/primer/forms.rb
primer_view_components-0.23.0 lib/primer/forms.rb
openproject-primer_view_components-0.28.1 lib/primer/forms.rb
openproject-primer_view_components-0.28.0 lib/primer/forms.rb
openproject-primer_view_components-0.27.0 lib/primer/forms.rb
openproject-primer_view_components-0.26.0 lib/primer/forms.rb
openproject-primer_view_components-0.25.1 lib/primer/forms.rb
primer_view_components-0.22.0 lib/primer/forms.rb
primer_view_components-0.21.1 lib/primer/forms.rb
openproject-primer_view_components-0.25.0 lib/primer/forms.rb
openproject-primer_view_components-0.24.0 lib/primer/forms.rb
primer_view_components-0.21.0 lib/primer/forms.rb
primer_view_components-0.20.1 lib/primer/forms.rb
primer_view_components-0.20.0 lib/primer/forms.rb
openproject-primer_view_components-0.23.0 lib/primer/forms.rb