-
Notifications
You must be signed in to change notification settings - Fork 555
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Wrap CheckBoxInput in InputWrapper to provide visual feedback (#2423)
### Changes Wrap the `CheckBoxInput` in `InputWrapper` to allow for providing feedback as to what is wrong when a user clicks submit without the checkbox being selected. Below is an example of what this looks like, rather than highlight using a border like other fields we change the text to red. **This image is outdated see below** <img width="301" alt="Screenshot 2023-08-04 at 12 03 18" src="https://github.com/auth0/lock/assets/8705251/cb346e0a-5d3e-4d24-87e8-b037b99dd34b"> I did also see what it looked like without the red text, which is a little less obvious. <img width="300" alt="Screenshot 2023-08-04 at 11 59 11" src="https://github.com/auth0/lock/assets/8705251/688ee97f-cd17-4375-80bb-b00d252529cb"> This is if we add a border around the entire element like the other components ![Screenshot 2023-08-04 at 11 05 07](https://github.com/auth0/lock/assets/8705251/a3eea2dc-c8ee-4e90-b5b9-f7fa68e3d143) I did also try a border/outline around the checkbox element but it looked bad due to inability to set the border radiu Happy to change this up if there's a general preference that looks better. Current status: Invalid hint text provided ![Invalid hint text is red and aligned with checkbox text](https://github.com/auth0/lock/assets/8705251/9ec1f0d1-9d60-46fd-b38b-9165dbc9ae71) No invalid hint text provided ![Checkbox text is red](https://github.com/auth0/lock/assets/8705251/c9452810-11f3-43e3-85e6-bc4298f5d904) ### References #2400 ### Testing <!-- Please describe how this can be tested by reviewers. Be specific about anything not tested and reasons why. If this library has unit and/or integration testing, tests should be added for new functionality and existing tests should complete without errors. --> * [x] This change adds unit test coverage * [ ] This change adds integration test coverage * [ ] This change has been tested on the latest version of the platform/language ### Checklist * [x] I have read the [Auth0 general contribution guidelines](https://github.com/auth0/open-source-template/blob/master/GENERAL-CONTRIBUTING.md) * [x] I have read the [Auth0 Code of Conduct](https://github.com/auth0/open-source-template/blob/master/CODE-OF-CONDUCT.md) * [x] All code quality tools/guidelines have been run/followed * [x] All relevant assets have been compiled
- Loading branch information
1 parent
c9a2598
commit ff14592
Showing
7 changed files
with
185 additions
and
38 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
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
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
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
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
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
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