This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Relying on delegated events in SolidJS breaks functionality in shadow roots #3380
Closed
1 of 3 tasks
Labels
Description
SolidJS uses event delegation for the following events:
https://docs.solidjs.com/concepts/components/event-handlers#list-of-delegated-events
For instance, using the property
onClick
will register a delegated event handler, while theon:click
property will register a native event listener.ArkUI attaches its own event listeners using the delegated syntax, which in some cases, like in the
Tooltip
focus handlers, or in theSelect
outside click handler, breaks functionality when it's used inside a shadow root.This can be somewhat mitigated by fixing the events on runtime if using
asChild
, using the following approach:This however does not work on custom events like
Select
'sonInteractOutside
.Link to Reproduction (or Detailed Explanation)
https://stackblitz.com/~/github.com/ivancuric/solidjs-templates-yge8guon?file=src/App.tsx
Steps to Reproduce
Ark UI Version
5.0.0
Framework
Browser
Chrome
Additional Information
related issue: #3146
The text was updated successfully, but these errors were encountered: