Contact emails
Explainer
https://github.com/WICG/webcomponents/blob/gh-pages/proposals/reference-target-explainer.md
Specification
None yet, but explainer has enough detail that developers can understand how to use the feature.
Summary
Reference Target is a feature to enable using IDREF attributes such as `for` and `aria-labelledby` to refer to elements inside a component's shadow DOM, while maintaining encapsulation of the internal details of the shadow DOM. The main goal of this feature is to enable ARIA to work across shadow root boundaries.
A component can specify an element in its shadow tree to act as its "reference target". When the host component is the target of a IDREF like a label's `for` attribute, the reference target becomes the effective target of the label.
The shadow root specifies the ID of the target element inside the shadow DOM. This is done either in JavaScript with the `referenceTarget` attribute on the `ShadowRoot` object, or in HTML markup using the `shadowrootreferencetarget` attribute on the `<template>` element.
Blink component
Blink>DOM>ShadowDOM
TAG review
https://github.com/w3ctag/design-reviews/issues/961
TAG review status
Resolution: Satisfied
Risks
Interoperability and Compatibility
None
Gecko: No signal (https://github.com/mozilla/standards-positions/issues/1035)
WebKit: No signal (https://github.com/WebKit/standards-positions/issues/356)
Web developers: Positive. The cross-root ARIA problem that reference target solves has been a longstanding hurdle for WebComponents adoption. See https://nolanlawson.com/2022/11/28/shadow-dom-and-accessibility-the-trouble-with-aria/, https://alice.pages.igalia.com/blog/how-shadow-dom-and-accessibility-are-in-conflict/, and the results of the WebDX survey https://github.com/web-platform-dx/developer-research/blob/main/mdn-short-surveys/2023-03-31-web-components/interpretation.md#split-by-feature which surfaces this as a need for many users of web components. I have discussed this trial with a partner team at Microsoft who would like to participate.
Other signals:
WebView application risks
Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?
None
Goals for experimentation
We're looking for feedback on all of the following from developers who will have spent some time building with the feature:
Ongoing technical constraints
None
Debuggability
None
Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?
Yes
Is this feature fully tested by web-platform-tests?
Yes: https://wpt.fyi/results/shadow-dom/reference-target (with additional tests in development)
Flag name on about://flags
None
Finch feature name
ShadowRootReferenceTarget
Non-finch justification
None
Requires code in //chrome?
False
Estimated milestones
133-135
Link to entry on the Chrome Platform Status
https://chromestatus.com/feature/5188237101891584?gate=5171533504315392
Links to previous Intent discussions
Intent to Prototype: https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CH3PR00MB1627F4E2554F7969B2B61E94D3FFA%40CH3PR00MB1627.namprd00.prod.outlook.com
This intent message was generated by Chrome Platform Status.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/DS0PR00MB23422839CBB35C320F9CC344C5202%40DS0PR00MB2342.namprd00.prod.outlook.com.
Done!