-
Notifications
You must be signed in to change notification settings - Fork 4
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
feat: Render validation messages for Form associated custom elements #1254
Conversation
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
…/IgniteUI/igniteui-webcomponents into rkaraivanov/validation-container
…onents into rkaraivanov/validation-container
This comment was marked as resolved.
This comment was marked as resolved.
…ng end for material and change the icon
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
Fixed timing issues for the igc-icon broadcast channel tests.
it('renders value-missing slot', async () => { | ||
await createFixture(html` | ||
<igc-checkbox required> | ||
<div slot="value-missing"></div> | ||
</igc-checkbox> | ||
`); | ||
|
||
await checkValidationSlots(element, 'valueMissing'); | ||
}); | ||
|
||
it('renders custom-error slot', async () => { | ||
await createFixture(html` | ||
<igc-checkbox> | ||
<div slot="custom-error"></div> | ||
</igc-checkbox> | ||
`); | ||
|
||
element.setCustomValidity('invalid'); | ||
await checkValidationSlots(element, 'customError'); | ||
}); | ||
|
||
it('renders invalid slot', async () => { | ||
await createFixture(html` | ||
<igc-checkbox required> | ||
<div slot="invalid"></div> | ||
</igc-checkbox> | ||
`); | ||
|
||
await checkValidationSlots(element, 'invalid'); | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These could be entirely data driven (either separate tests or a single one) in a loop of slot names. Assuming checkValidationSlots
will handle the slot name directly since it only converts them to kebab case anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pretty much true for the rest of the components running this set of checks it seems.
Added aria-describedby for input/mask-input for the internal native input element when content is projected into the helper-text slot.
Closes #1195
Closes #1043
Specification here