Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
Yep, that's the test I saw failing. If the changes can be manually verified in screen readers, I'm OK with relaxing the rule as it could indeed be related to timing. In the test file, this should do the trick: await expect(el).to.be.accessible({ ignoredRules: ['aria-valid-attr-value'] }); |
|
@claviska I tested with a screen reader enabled and the announcements were correct, so I've added the line you referenced. |
It is probably invalid because the elements reference each other across the shadow DOM boundary. The slide item in the light DOM references the button which is in the shadow DOM, and vice versa. Afaik this is not supported. The default screen reader on Windows does not recognize the tabs pattern in the sl-carousel. Plus, there are duplicate global IDs on the slide items, which triggered accessibility warnings on my end. Edit: I found a possible solution: aria mixin attributes. This is a new browser feature that allows setting aria-relations in JS via object references instead of ID-strings: // Old
tabpanel1.setAttribute('aria-labelledby', 'tab-1');
tab1.setAttribute('aria-controls', 'tabpanel-1');
// New
tabpanel1.ariaLabelledByElements = [tab1];
tab1.ariaControlsElements = [tabpanel1];It is a very recent feature, so I am not sure how well this is supported by browsers and screen readers. References: |

This PR addresses the following (#2303) (#2352)
When pagination is enabled:
The following items are not addressed, since this would touch translation files.
References: