Sha256: f855cafbcb917f8eb79e4d3902627fb3513ec81d5f2df2732a66d85e342c67f4

Contents?: true

Size: 819 Bytes

Versions: 111

Compression:

Stored size: 819 Bytes

Contents

# frozen_string_literal: true

module Primer
  # :nocov:
  # :nodoc:
  module FormHelper
    def primer_form_with(**kwargs, &block)
      form_with(**kwargs, skip_default_ids: false, builder: Primer::Forms::Builder, &block)
    end

    def primer_fields_for(record_name, record_object = nil, options = {}, &block)
      fields_for(
        record_name,
        record_object,
        options.merge(
          skip_default_ids: false,
          builder: Primer::Forms::Builder
        ),
        &block
      )
    end

    def inline_form(*args, &block)
      Primer::Forms.inline_form(*args, &block)
    end

    def render_inline_form(*args, &block)
      # rubocop:disable GitHub/RailsViewRenderLiteral
      render(inline_form(*args, &block))
      # rubocop:enable GitHub/RailsViewRenderLiteral
    end
  end
end

Version data entries

111 entries across 111 versions & 2 rubygems

Version Path
openproject-primer_view_components-0.48.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.47.1 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.47.0 app/helpers/primer/form_helper.rb
primer_view_components-0.34.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.46.1 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.46.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.45.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.44.3 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.44.2 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.44.1 app/helpers/primer/form_helper.rb
primer_view_components-0.33.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.44.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.43.1 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.43.0 app/helpers/primer/form_helper.rb
primer_view_components-0.32.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.42.0 app/helpers/primer/form_helper.rb
primer_view_components-0.31.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.41.1 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.41.0 app/helpers/primer/form_helper.rb
openproject-primer_view_components-0.40.0 app/helpers/primer/form_helper.rb