Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Interactive form validation] New interactive form validation package #1562

Draft
wants to merge 2 commits into
base: 2.x
Choose a base branch
from

Conversation

andersmateusz
Copy link
Contributor

@andersmateusz andersmateusz commented Mar 1, 2024

Q A
Bug fix? no
New feature? yes
Issues -
License MIT

Draft pull request for a new package. I am open for suggestions.
Funcionality:

  • Automatic focus on invalid input/form and scroll into the invalid input/form.
  • Alert that notifies user that the form is invalid and why. Two strategies are available. Just emit event with message (then you must implement alert yourself with usage of many alert js libraries available) or show browser native alert.

This should be working well with full page reloads as well with turbo bundle streams and frames.
Global configuration (for each form) and for each form separately is possible.
It is recommended to set form attr novalidate on a form to fully test this functionality. Wondering if novalidate attr should not be set by default on each form with this feature enabled.

@andersmateusz andersmateusz changed the title Feat/interactive form validation package [Interactive form validation] New interactive form validation package Mar 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant