- From: David Bokan via GitHub <sysbot+gh@w3.org>
- Date: Mon, 08 Jan 2024 15:28:24 +0000
- To: public-css-archive@w3.org
I guess the suggestion is that `:hover` isn't special - so if the hover state is activated, a click will also be captured?
> The principled fix for this (credits to @vmpstr) is to route hit-testing from ::view-transition-new to its corresponding DOM element.
I'm not sure simply routing it would work. Consider something like this:
```html
<div id="container" style="view-transition-name:button">
<div class="background">
<button onclick="dosomething()">Foo</button>
</div>
</div>
```
If we route to the v-t-pseudo associated DOM element, we'll dispatch the event at `#container` so clicks won't hit the button, hover might not be applied to background, etc.
Perhaps we could run a new hit test _starting from_ the associated DOM element so that we hit the correct inner-most element and perform the usual event bubbling/routing?
--
GitHub Notification of comment by bokand
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9586#issuecomment-1881229600 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 8 January 2024 15:28:26 UTC