Repository navigation
layout: Consider Text as LCP candidate - #47212
Conversation
|
🤖 Opened new upstream WPT pull request (web-platform-tests/wpt#61911) with upstreamable changes. |
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
Adding a struct `PendingImageRecord`. Add complimentary `W3C` spec steps. Pre-requisite for servo#47212 Testing: WPT Unchanged. Fixes: Part of servo#42000 --------- Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com> Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
|
✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#61911) title and body. |
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
|
✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#61911) title and body. |
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com>
Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com>
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
| // Width of at least 100 px. | ||
| // TODO: find a good way to bound text width. | ||
| assert_greater_than_equal(entry.size, 1200); | ||
| assert_equals(entry.loadTime, 0); |
There was a problem hiding this comment.
Still Fails because of loadTime. It will be fixed in follow-up
|
✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#61911) title and body. |
| @@ -0,0 +1,3 @@ | |||
| [transparent-text.html] | |||
There was a problem hiding this comment.
as earlier text was not considered so it passed.
Now, text is considered but transparent is not checked.
This will be fixed soon.
| @@ -1,4 +1,4 @@ | |||
| [larger-text.html] | |||
| expected: TIMEOUT | |||
| expected: ERROR | |||
There was a problem hiding this comment.
Can you wrap the forEach callback at
in a t.step_func to make this test behave better when it fails?There was a problem hiding this comment.
Quite Insightful suggestion :)
| @@ -1,4 +1,4 @@ | |||
| [text-fragment-union.html] | |||
| expected: TIMEOUT | |||
| expected: ERROR | |||
There was a problem hiding this comment.
Same here for a t.step_func:
|
|
||
| // PaintTimingMixin | ||
| assert_greater_than_equal(entry.paintTime, beforeRender, 'paintTime should represent the time when the UA started painting'); | ||
| if ("paintTime" in entry && entry.paintTime !== null) { |
There was a problem hiding this comment.
This change isn't great, because it silently ignores a feature if it's not supported. We should either accept that the test will fail until we implement this feature, or we should split it out into a separate test that we will fail.
There was a problem hiding this comment.
It is same for presentationTime below.
paintTime and presentationTime are in same interface and treated together under PaintTimingMixin IIRC.
That's why I did this. WDYS?
There was a problem hiding this comment.
Huh. Ok, no objection if there's prior art in the same test file, I guess!
There was a problem hiding this comment.
web-platform-tests/wpt@20ded9e and web-platform-tests/wpt@35cc694 is the original justification.
jdm
left a comment
There was a problem hiding this comment.
These changes look good to me, but I'd like someone more experienced with layout to verify the logic for the new containing_element_tag.
|
✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#61911) title and body. |
Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com>
Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com>
Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com>
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
1 similar comment
|
📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#61911). |
|
✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#61911) title and body. |
|
Yayyyyy! Thanks |
|
@servo-highfive monthly update |
|
Someone thinks this change could be added to the monthly blog post! To help with this, we need someone to answer the following questions: 😄
If this change is part of a broader feature/project please make sure the PR description contains a Please add Thanks for helping us prepare the monthly blog post! ❤️ |
|
@servo-highfive monthly update answer
|
Adding a struct `PendingImageRecord`. Add complimentary `W3C` spec steps. Pre-requisite for servo#47212 Testing: WPT Unchanged. Fixes: Part of servo#42000 --------- Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com> Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
Since the spec says, for text nodes we need to do union of border box per element. - Adding `containing_element_tag` for making this union. - Adding `TextRecord` to store `TextNodes` related to an `Element`. > Note: Please view using `Hide whitespace` option. Testing: More WPT Passed - Added a specific test to verify union logic of rect - size calculation is correct in WPT - `tests/wpt/tests/largest-contentful-paint/text-fragment-union.html`- web-platform-tests/wpt#61873 - (_TODO: set loadTime to zero for text, other failing tests will also pass #47315_) Fixes: Part of servo#42000 --------- Signed-off-by: Shubham Gupta <shubhamg13.work@gmail.com>
Since the spec says, for text nodes we need to do union of border box per element.
containing_element_tagfor making this union.TextRecordto storeTextNodesrelated to anElement.Testing: More WPT Passed
tests/wpt/tests/largest-contentful-paint/text-fragment-union.html- Added a test for LCP text fragment union. web-platform-tests/wpt#61873Fixes: Part of #42000