Skip to content

script: Add an initial implementation of relatedTarget forfocus/blur events#43926

Merged
mrobinson merged 1 commit into
servo:mainfrom
mrobinson:relatedTarget
Apr 4, 2026
Merged

script: Add an initial implementation of relatedTarget forfocus/blur events#43926
mrobinson merged 1 commit into
servo:mainfrom
mrobinson:relatedTarget

Conversation

@mrobinson
Copy link
Copy Markdown
Member

This is an initial implementation for relatedTarget of focus and
blur events. As the code doesn't yet follow the specification this is
a bit tricky to associate with specification text, but this should be
correct. A later change will adapt the code to the "focusing steps" part
of the specification.

In addition, a duplicated call to Element::set_focus_state is removed.

Testing: This gets one more WPT test passing.

…blur` events

This is an initial implementation for `relatedTarget` of `focus` and
`blur` events. As the code doesn't yet follow the specification this is
a bit tricky to associate with specification text, but this should be
correct. A later change will adapt the code to the "focusing steps" part
of the specification.

In addition, a duplicated call to `Element::set_focus_state` is removed.

Signed-off-by: Martin Robinson <[email protected]>
@mrobinson mrobinson requested a review from gterzian as a code owner April 4, 2026 09:11
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Apr 4, 2026
@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Apr 4, 2026
@TimvdLippe TimvdLippe enabled auto-merge April 4, 2026 09:20
@TimvdLippe TimvdLippe added this pull request to the merge queue Apr 4, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Apr 4, 2026
@mrobinson mrobinson changed the title script: Add an initial implementaiton of relatedTarget forfocus/blur events script: Add an initial implementation of relatedTarget forfocus/blur events Apr 4, 2026
@mrobinson mrobinson removed this pull request from the merge queue due to a manual request Apr 4, 2026
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Apr 4, 2026
@mrobinson mrobinson added this pull request to the merge queue Apr 4, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Apr 4, 2026
Merged via the queue into servo:main with commit 953206e Apr 4, 2026
37 checks passed
@mrobinson mrobinson deleted the relatedTarget branch April 4, 2026 12:16
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Apr 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants