Automatic update from web-platform-tests
[Reference Target] Use relatedTarget for event propagation
Replace the reference target handling in GetShadowRootParent with an
approach that uses Event's existing relatedTarget concept, per
discussion at [1].
The way this will work is that for CommandEvent, ToggleEvent,
SubmitEvent, and InterestEvent, instead of an internal source/submitter,
the events will use relatedTarget. The getters for these no longer need
individual retargeting since relatedTarget gets retargeted as part of
event dispatch. When relatedTarget is non-null for one of these event
types, we'll dispatch it as a composed event.
The result is that when the source/submitter is in a parent shadow
because of reference target, we'll bubble the event into that shadow
(but no further, due to the way relatedTarget already affects event
dispatch).
[1] https://github.com/whatwg/html/pull/10995#issuecomment-4572681552
Bug: 346835896
Change-Id: I6cb5cde907a3db8492795adb13e971bbd92f5ca5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7902895
Commit-Queue: Dan Clark <daniec@microsoft.com>
Reviewed-by: Mason Freed <masonf@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1650570}
--
wpt-commits: 9911aea5c6a42d47b89c88d43e91ce04d4f1099f
wpt-pr: 60816