-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: data-variant overwrites (in)valid border colors (#422)
* chore: simplified this attribute * fix: overwriting form stylings for errors * feat: added new programmatic invalid example * refactor: added the correct styling for invalid selects * Update select.scss * refactor: generalizing the form validations * fix: corrected this previously necessary declaration * Revert "fix: corrected this previously necessary declaration" This reverts commit 25e3473. * refactor: we need to differentiate in between the different form elements * refactor: enabled floating labels again * chore: make this more generic * chore: make this more generic * refactor: this obviously was only related to floating labels and not form validation * refactor: modern floating label for selects w/o necessary required on the select, yeah ! * refactor: reunited the form validation SCSS placeholder we've found another way to support floating labels on selects w/o having them as a required element * Revert "refactor: reunited the form validation SCSS placeholder" This reverts commit 48a1acb. * style: further optimizations
- Loading branch information
Showing
12 changed files
with
80 additions
and
47 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
File renamed without changes.
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
5 changes: 5 additions & 0 deletions
5
source/_patterns/01-elements/select/select~invalid-attribute.json
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"id": "select13", | ||
"label": "Devices", | ||
"invalid": "true" | ||
} |
11 changes: 11 additions & 0 deletions
11
source/_patterns/01-elements/select/select~invalid-attribute.md
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
title: Select - Invalid state by HTML attribute | ||
state: complete | ||
order: 7 | ||
--- | ||
|
||
## Form validation | ||
|
||
Please have a look especially at the section for form validation within the overall [components/forms](../components-form/index.html) page. | ||
|
||
Additionally to the browser built-in pseudo-selector `:invalid` we're providing styling for the [`aria-invalid="true"` attribute](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_aria-invalid_attribute) as well. |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,5 +2,5 @@ | |
"id": "textarea06", | ||
"value": "Inpu", | ||
"validation": " minlength=\"5\"", | ||
"aria-invalid": "true" | ||
"invalid": "true" | ||
} |