Bug 226380 - Hit-testing does not account for clip-path on <iframe>
Summary: Hit-testing does not account for clip-path on <iframe>
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Antoine Quint
URL:
Keywords: InRadar
Depends on:
Blocks: 226499
  Show dependency treegraph
 
Reported: 2021-05-28 09:43 PDT by Antoine Quint
Modified: 2021-06-02 01:28 PDT (History)
11 users (show)

See Also:


Attachments
Patch (13.43 KB, patch)
2021-05-28 09:47 PDT, Antoine Quint
no flags Details | Formatted Diff | Diff
Patch (13.42 KB, patch)
2021-05-29 10:51 PDT, Antoine Quint
no flags Details | Formatted Diff | Diff
Patch (13.43 KB, patch)
2021-06-01 02:14 PDT, Antoine Quint
koivisto: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antoine Quint 2021-05-28 09:43:09 PDT
Hit-testing does not account for clip-path on <iframe>
Comment 1 Radar WebKit Bug Importer 2021-05-28 09:43:47 PDT
<rdar://problem/78621486>
Comment 2 Antoine Quint 2021-05-28 09:47:20 PDT
Created attachment 430021 [details]
Patch
Comment 3 Antoine Quint 2021-05-28 09:47:26 PDT
<rdar://problem/78621486>
Comment 4 Antoine Quint 2021-05-29 10:51:06 PDT
Created attachment 430097 [details]
Patch
Comment 5 Antoine Quint 2021-06-01 02:14:58 PDT
Created attachment 430241 [details]
Patch
Comment 6 Antti Koivisto 2021-06-01 08:46:36 PDT
Comment on attachment 430241 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=430241&action=review

> LayoutTests/css3/masking/clip-path-iframe.html:9
> +    if (window.eventSender)
> +        eventSender.mouseMoveTo(50, 50);

This won't work on iOS. It would be better if the test was constructed so that all platforms are covered (and nothing happens case wouldn't pass). You can exercise hit testing code directly in platform independent manner by using Document.elementFromPoint.
Comment 7 Antti Koivisto 2021-06-01 08:50:48 PDT
Comment on attachment 430241 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=430241&action=review

> LayoutTests/css3/masking/clip-path-iframe.html:15
> +iframe {

I think this also affects replaced elements like <img>. It would be good to have a test for them too.
Comment 8 Antoine Quint 2021-06-02 01:28:50 PDT
Committed r278343 (238375@main): <https://commits.webkit.org/238375@main>