- From: Noam Rosenthal via GitHub <noreply@w3.org>
- Date: Thu, 14 Aug 2025 19:47:14 +0000
- To: public-css-archive@w3.org
... another way to do this is to define this relationship in CSS.
So the element itself would be a standard HTML element, and the relationship to the pseudo-element be entirely in CSS:
```css
dialog {
div.backdrop { display: pseudo(::backdrop) }
}
```
or using name-matching when it's not a direct child:
```css
::view-transition-group(hero-anim) { pseudo-name: hero-anim; }
.hero-animation { display: pseudo(hero-anim); }
```
... and utilities for deciphering which pseudo-element received an events etc. can be added to CSSOM or wherever is needed.
This can probably be improved a lot for ergonomics, but the point is that this can probably be done without the DOM knowing about it at all, and using the `display` property indicates that this proxying replaces actual rendering/layout of the element.
--
GitHub Notification of comment by noamr
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12575#issuecomment-3189684193 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 14 August 2025 19:47:16 UTC