base-ui
base-ui copied to clipboard
[field controls] Respect `validationMode`
Pending:
Sliderbehavior- Tests
Closes #1050
Netlify deploy preview
https://deploy-preview-1053--base-ui.netlify.app/
Generated by :no_entry_sign: dangerJS against e101083712bf84030d7c32bda5db08571055e3c9
Deploy Preview for base-ui ready!
| Name | Link |
|---|---|
| Latest commit | 23438c28204b16a8d246319094cd4d92f43c0d0a |
| Latest deploy log | https://app.netlify.com/sites/base-ui/deploys/67a346af2ef9000007216ac4 |
| Deploy Preview | https://deploy-preview-1053--base-ui.netlify.app |
| Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site configuration.
Side note: I think the using ValidityState terminology for the match prop isn't ideal, some of the values seem vague/unintuitive, e.g. match="badInput", match="valid" Many users may end up just using a validate function on Field and match="customError" for everything just because of convenience (and because many form libraries are like this) CC @colmtuite
I see your point - though in the most basic usage, it allows them to leverage the native HTML validation while still customizing the error message. e.g. <input pattern="..." /> without using JavaScript inside the validate function. Maybe it'd be more intuitive/obvious if each string was documented?