-
-
Notifications
You must be signed in to change notification settings - Fork 333
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(form): auto add empty rule validation for required fields
This PR adds the ability to add automatically an 'empty' rule for fields that got the required class (or checked for checkboxes). It's disabled by default since I don't want it to be a breaking change, but can be enabled at initialization with autoCheckRequired: true or any time with the .form('set auto check') behavior. It can handle all fields types, grouped fields as well, and is able to detect disabled fields or groups. Rule is added to others if there's already some defined, and isn't duplicated if already set.
- Loading branch information
Showing
1 changed file
with
36 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters