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
primer_view_components-0.19.0 lib/primer/forms.rb
openproject-primer_view_components-0.22.2 lib/primer/forms.rb
primer_view_components-0.18.2 lib/primer/forms.rb
openproject-primer_view_components-0.22.1 lib/primer/forms.rb
primer_view_components-0.18.1 lib/primer/forms.rb
openproject-primer_view_components-0.22.0 lib/primer/forms.rb
primer_view_components-0.18.0 lib/primer/forms.rb
openproject-primer_view_components-0.21.0 lib/primer/forms.rb
primer_view_components-0.17.0 lib/primer/forms.rb
openproject-primer_view_components-0.20.0 lib/primer/forms.rb
primer_view_components-0.16.1 lib/primer/forms.rb
primer_view_components-0.16.0 lib/primer/forms.rb
openproject-primer_view_components-0.19.0 lib/primer/forms.rb
primer_view_components-0.15.1 lib/primer/forms.rb
primer_view_components-0.15.0 lib/primer/forms.rb
openproject-primer_view_components-0.18.1 lib/primer/forms.rb
openproject-primer_view_components-0.17.1 lib/primer/forms.rb
openproject-primer_view_components-0.17.0 lib/primer/forms.rb
primer_view_components-0.14.0 lib/primer/forms.rb
openproject-primer_view_components-0.16.0 lib/primer/forms.rb