From 9d9eb4f5fc932df701017601e0e910dcdc3f9b16 Mon Sep 17 00:00:00 2001 From: Ian Clelland Date: Tue, 21 Nov 2023 14:49:24 -0500 Subject: [PATCH] Use "exposed for paint timing" --- index.bs | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/index.bs b/index.bs index a86d309..a5c2c4b 100644 --- a/index.bs +++ b/index.bs @@ -148,32 +148,36 @@ interface LargestContentfulPaint : PerformanceEntry { Each {{LargestContentfulPaint}} object has these associated concepts: -* A renderTime, initially set to 0. -* A size, initially set to 0. -* A loadTime, initially set to 0. -* An id, initially set to the empty string. -* A url, initially set to the empty string. -* An element containing the associated {{Element}}, initially set to null. +* A renderTime, initially set to 0. +* A size, initially set to 0. +* A loadTime, initially set to 0. +* An id, initially set to the empty string. +* A url, initially set to the empty string. +* An element containing the associated {{Element}}, initially set to null. The {{PerformanceEntry/entryType}} attribute's getter must return the {{DOMString}} "largest-contentful-paint". The {{PerformanceEntry/name}} attribute's getter must return the empty string. -The {{PerformanceEntry/startTime}} attribute's getter must return the value of this's renderTime if it is not 0, and the value of this's loadTime otherwise. +The {{PerformanceEntry/startTime}} attribute's getter must return the value of [=this=]'s renderTime if it is not 0, and the value of [=this=]'s [=LargestContentfulPaint/loadTime=] otherwise. The {{PerformanceEntry/duration}} attribute's getter must return 0. -The {{LargestContentfulPaint/renderTime}} attribute must return the value of this's renderTime. +The {{LargestContentfulPaint/renderTime}} attribute must return the value of [=this=]'s [=LargestContentfulPaint/renderTime=]. -The {{LargestContentfulPaint/loadTime}} attribute must return the value of this's loadTime. +The {{LargestContentfulPaint/loadTime}} attribute must return the value of [=this=]'s [=LargestContentfulPaint/loadTime=]. -The {{LargestContentfulPaint/size}} attribute must return the value of this's size. +The {{LargestContentfulPaint/size}} attribute must return the value of [=this=]'s [=LargestContentfulPaint/size=]. -The {{LargestContentfulPaint/id}} attribute must return the value of this's id. +The {{LargestContentfulPaint/id}} attribute must return the value of [=this=]'s [=LargestContentfulPaint/id=]. -The {{LargestContentfulPaint/url}} attribute must return the value of this's url. +The {{LargestContentfulPaint/url}} attribute must return the value of [=this=]'s [=LargestContentfulPaint/url=]. -The {{LargestContentfulPaint/element}} attribute's getter must return the value returned by running the get an element algorithm with [=/element=] and null as inputs. +The {{LargestContentfulPaint/element}} attribute's getter must perform the following steps: +
+ 1. If [=this=]'s [=LargestContentfulPaint/element=] is not [=exposed for paint timing=] given null, return null. + 1. Return [=this=]'s [=LargestContentfulPaint/element=]. +
Note: The above algorithm defines that an element that is no longer a [=tree/descendant=] of the {{Document}} will no longer be returned by {{LargestContentfulPaint/element}}'s attribute getter, including elements that are inside a shadow DOM.