fission hit testing incorrect with clip-path on top.
Categories
(Core :: Web Painting, defect, P2)
Tracking
()
People
(Reporter: emilio, Unassigned)
References
(Blocks 1 open bug)
Details
(Keywords: webcompat:platform-bug)
Attachments
(2 files)
Test-case would be in bug 1911251 comment 5. Here's with an added background and no opacity just to confirm the clip-path clips everything:
data:text/html,<div style="position: absolute;left: 0px;top: 0px;width: 100%; height: 100%; z-index: 100; clip-path: polygon(0px 0px, 100% 0px, 100% 0%, 0px 0%); background-color: red;"></div><iframe src="http://techno-barje.fr/fission/input"></iframe>
It seems we're not dealing with clip-path polygon regions at all in APZ? This case is even more egregious because everything ends up clipped, so the absolute-positioned element shouldn't be hittable at all.
As for why was that page doing something like that... I don't know?
Reporter | ||
Updated•27 days ago
|
Reporter | ||
Comment 1•27 days ago
|
||
Same test-case with same-origin frame (works):
data:text/html,<div style="position: absolute;left: 0px;top: 0px;width: 100%; height: 100%; z-index: 100; clip-path: polygon(0px 0px, 100% 0px, 100% 0%, 0px 0%); background-color: red;"></div><iframe srcdoc="<input type=text>"></iframe>
Reporter | ||
Comment 2•27 days ago
|
||
Oh, actually test-case in comment 0 works, so the opacity: 0
is needed after all. Maybe we're optimizing out the opacity: 0
incorrectly somehow?
Actual test-cases. Fission:
data:text/html,<div style="position: absolute;left: 0px;top: 0px;width: 100%; height: 100%; z-index: 100; clip-path: polygon(0px 0px, 100% 0px, 100% 0%, 0px 0%); opacity: 0;"></div><iframe src="http://techno-barje.fr/fission/input"></iframe>
Non-fission:
data:text/html,<div style="position: absolute;left: 0px;top: 0px;width: 100%; height: 100%; z-index: 100; clip-path: polygon(0px 0px, 100% 0px, 100% 0%, 0px 0%); opacity: 0;"></div><iframe srcdoc="<input type=text>"></iframe>
Comment 3•12 days ago
|
||
The severity field is not set for this bug.
:botond, could you have a look please?
For more information, please visit BugBot documentation.
Comment 4•5 days ago
|
||
Marking as S2 because this blocks an S2.
Comment 5•2 hours ago
|
||
(In reply to Emilio Cobos Álvarez (:emilio) from comment #2)
Oh, actually test-case in comment 0 works, so the
opacity: 0
is needed after all. Maybe we're optimizing out theopacity: 0
incorrectly somehow?
Interestingly, if I remove the background-color: red;
from the test case in comment 0, such that there is neither a background color nor an opacity, the bug still reproduces.
Comment 6•2 hours ago
|
||
Comment 7•2 hours ago
|
||
Attached some display list dumps. The main difference seems to be that in the working case (with background-color), the WebRender display list contains more detailed information related to the clip-path, which allows accurate hit testing to happen in the compositor.
Updated•2 hours ago
|
Comment 8•2 hours ago
|
||
(In reply to Botond Ballo [:botond] from comment #7)
in the working case (with background-color), the WebRender display list contains more detailed information related to the clip-path, which allows accurate hit testing to happen in the compositor.
Specifically, in the working case we get an ImageMaskClip
WebRender display item created here. In the broken case we don't get there because we early exit here.
Description
•