From 1350fc38f4cc0f1c5d37a7b9ff1181a888c697f7 Mon Sep 17 00:00:00 2001 From: Ian Clelland Date: Wed, 6 Nov 2024 05:31:33 +0000 Subject: [PATCH] Bug 1929364 [wpt PR 48982] - Don't update LCP for video elements switching from poster., a=testonly Automatic update from web-platform-tests Don't update LCP for video elements switching from poster. A video element whose rendered contents are a poster image will have a different MediaTiming than when it's contents are the video itself. However, that different object will cause the MediaRecordId to be different, and so the same element can create two distinct LCP candidate records. This change forces the MediaRecordId to not consider the MediaTiming object when calculating the hash for a video element. Bug: 330202431 Change-Id: I56b8c8d54c1a3d64138f8de529fe15695b1df952 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5970217 Reviewed-by: Hao Liu Commit-Queue: Ian Clelland Cr-Commit-Position: refs/heads/main@{#1378586} -- wpt-commits: 5fe6c1e7f9ee16db7756262fd2a71232bc9b4d1d wpt-pr: 48982 --- .../video-play-after-poster.html | 53 +++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 testing/web-platform/tests/largest-contentful-paint/video-play-after-poster.html diff --git a/testing/web-platform/tests/largest-contentful-paint/video-play-after-poster.html b/testing/web-platform/tests/largest-contentful-paint/video-play-after-poster.html new file mode 100644 index 0000000000000..1a0ee7dba54a5 --- /dev/null +++ b/testing/web-platform/tests/largest-contentful-paint/video-play-after-poster.html @@ -0,0 +1,53 @@ + + +This test verifies a video element only triggers a single LCP entry + + + + + + + + +