Re: [csswg-drafts] [css-pseudo-4] Proxying pseudo-elements as "real" (`<slot>`) elements (#12575)

> > (I think we do need a new element, we can discuss in the issue.)
> 
> As I mentioned in [#12163 (comment)](https://github.com/w3c/csswg-drafts/issues/12163#issuecomment-3175770246), we don't need to re-use `<slot>`. HTML has the power to mint new elements, especially when they come with special semantics (e.g. a `<scroll-marker>` element representing one or more buttons depending on layout). We can also leverage the principles laid out by `<details>`/`<summary>`, whereby any `<details>` element effectively has a summary slot which has default content, and by adding a `<summary>` element you replace the default slotted content and expose new ways to select/handle events on said element.

Yes, absolutely.
I am converting this proposal to not require HTML support at all (though it would need some JS APIs for reflection).

-- 
GitHub Notification of comment by noamr
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12575#issuecomment-3206284296 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 20 August 2025 13:11:19 UTC