Let Equals Equal Equals
2 days ago
- #ARIA API
- #Web Accessibility
- #Shadow DOM
- Setting ariaDescribedByElements on a node fails silently when the target is in a different shadow root, violating the Priority of Constituencies and harming assistive technology (AT) users.
- The spec breaks cross-root references to preserve encapsulation purity, but this restricts sibling or cousin shadow root connections while allowing ancestor references, causing inconsistent behavior.
- Encapsulation concerns could be addressed by nulling the getter while keeping the internal relationship for AT, but the current spec discards assignments entirely without warning.
- Developers often use the imperative API specifically for cross-root references, as declarative attributes can't reach them, making the silent failure counterproductive.
- Closed shadow roots are rarely used in practice and don't provide real security, so the spec's protection of them prioritizes theoretical purity over user accessibility needs.
- Reference Target is a complementary proposal for declarative ARIA references but doesn't fix the broken imperative API, which should be made to work immediately.
- Suggested fixes include making the setter work for AT, nulling the getter for encapsulation, adding console warnings for failures, and shipping Reference Target as a long-term solution.