Files
sousa-gecko/testing/web-platform/tests/html/rendering/replaced-elements/embedded-content/video-controls-stacking.html
T
jj a8911b543e Bug 2021539 [wpt PR 58304] - Treat static video controls as replaced normal-flow stacking, a=testonly
Automatic update from web-platform-tests
Treat static video controls as replaced normal-flow stacking

Static video controls create stacked paint layers, which paint after
inline siblings, causing positioned elements (e.g. buttons) placed on
top of the video to be painted over by the controls.

Fix this by treating static <video controls> as a replaced normal-flow
stacking element.

The hit-test and paint child-skip in PaintLayer is narrowed from
IsReplacedNormalFlowStacking() to IsSVGForeignObject(), since the skip
logic relies on SVG-specific coordinate transforms that don't apply to
video.

Fixed: 40591804
Change-Id: Ib0489f88fc1452ceb8a34e3925809eb0ca73b70e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7617187
Reviewed-by: Xianzhu Wang <wangxianzhu@chromium.org>
Commit-Queue: jj <jj@chromium.org>
Reviewed-by: Mason Freed <masonf@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1595707}

--

wpt-commits: 64cf9ac1042fb993ffd857f398fdd996f50db4c1
wpt-pr: 58304
2026-03-12 15:58:17 +00:00

16 lines
562 B
HTML

<!DOCTYPE HTML>
<link rel="author" title="jj" href="mailto:jj@imput.net">
<link rel="help" href="https://issues.chromium.org/issues/40591804">
<link rel="match" href="video-controls-stacking-ref.html">
<style>
div { position: fixed; background: green }
video { background: red }
video, div { width: 100px; height: 100px }
</style>
<p>Test passes if there is a filled green square with nothing overlaid on top.</p>
<div></div>
<video controls>
<source src="/media/white.webm" type="video/webm">
<source src="/media/white.mp4" type="video/mp4">
</video>