Sha256: 07dbccb0bcae3886b3ef443c1c5dd0f1181379b6898d3b9646dbfa2cc59a46fc

Contents?: true

Size: 912 Bytes

Versions: 87

Compression:

Stored size: 912 Bytes

Contents

# frozen_string_literal: true

# :nodoc:
# :nocov:
class ImmediateValidationForm < ApplicationForm
  form do |validation_form|
    validation_form.text_field(
      name: :has_error,
      label: "Will have error",
      caption: "Every time this checks with the server, it returns an error",
      auto_check_src: @view_context.example_check_error_path
    )

    validation_form.text_field(
      name: :no_error,
      label: "Will not error",
      caption: "Will not have an error when it checks the server",
      auto_check_src: @view_context.example_check_ok_path,
      validation_message: "This message will go away once you type something"
    )

    validation_form.text_field(
      name: :random_error,
      label: "Random error or success",
      caption: "Server checks will randomly respond with errors or success",
      auto_check_src: @view_context.example_check_random_path
    )
  end
end

Version data entries

87 entries across 87 versions & 2 rubygems

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