Re: [whatwg/dom] Declarative Shadow DOM (#831)

> The [serialization algorithm as it currently proposed](https://github.com/whatwg/html/pull/5465) strips away all the default ARIA properties specified on [ElementInternals](https://html.spec.whatwg.org/multipage/custom-elements.html#the-elementinternals-interface) via [ARIAMixin](https://w3c.github.io/aria/#ARIAMixin). This would mean that whenever a custom element is serialized along with its shadow tree, it loses all of its default ARIA semantics. This is a pretty serious show stopper issue.

This should be doable just by more attributes on the template right? e.g. `<template shadowroot="closed" shadowroot-aria-checked="true">`

On the note of element internals, we probably also want to be able to mirror the [form validity](https://html.spec.whatwg.org/multipage/custom-elements.html#form-associated-custom-elements) and [custom CSS states](https://wicg.github.io/custom-state-pseudo-class/) at the time of serialization.

In general I imagine we'd want most new APIs that are added to `ElementInternals` to be reflected in the declarative form where possible.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/831#issuecomment-817480486

Received on Monday, 12 April 2021 05:00:40 UTC