Repository navigation
Conversation
5 tasks done
noamr
force-pushed
the
noamr/untent-sizes-2d
branch
from
November 4, 2026 12:06
20554e7 to
08a4a52
Compare
noamr
force-pushed
the
noamr/untent-sizes-2d
branch
from
November 5, 2026 16:03
08a4a52 to
61669a0
Compare
…n select-an-image-source-2d
… picture fallback
…lbacks in select-an-image-source-2d
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tests for two-dimensional
sizes(cover/contain),srcsethdescriptors, and normative 2D image source selection, for whatwg/html#13053. Un-tentatives the tests from https://issues.chromium.org/issues/572724710 and folds in the normative selection tests that were previously in #64736.sizesparsing and concrete width (html/semantics/embedded-content/the-img-element/sizes/):sizes-2d.tentative.htmltosizes-2d.htmland include the dimension attribute aspect ratio coverage from https://crrev.com/c/8563321.sizes-auto-2d.html(un-tentatived from https://crrev.com/c/8563320 and https://crrev.com/c/8563321).COVER/Cover/Contain, zero lengths,min()/max()/clamp(), negativecalc()clamped to0px, andemunits ignoring the element'sfont-size.<source-size-value>s (negative second length, unitless non-zero numbers, percentages, missing/duplicate/misplaced fit keywords,var()), and a non-firstautobeing ignored.hbeforew(1h 50w), and candidates where only some specifyh(aspect ratio computed per candidate).<source>with onlyheightnot falling back to<img>;<link rel=preload>width/heightignored;<source>outside<picture>or after<img>ignored.width/heightmutation and removal on<img>and<source>(without also mutatingsrcset), content-box changes on auto-sized<img>withobject-fit, and retaining/resetting the 2Dlast auto-sizes size., 1px) where needed, so browsers without 2D support can't pass by falling back to100vw.Normative 2D source selection (
srcset/select-an-image-source-2d.html):>= devicePixelRatio(and the highest when all are below it) using 2D-normalized densities, for<img>,<picture><source>, and<link rel=preload imagesrcset imagesizes>.worder; deduplicating candidates (includingxvs.w+h) that normalize to the same density; zero concrete width givingInfinitydensity.<img>and<source>width/height, inheritance and override, per-candidatehtogether with the fallback aspect ratio,<picture>falling back from<source>to<img>,removeAttribute('height')re-selection, and a null default aspect ratio for<link rel=preload>.zoomon elements vs. iframes (including fractional zoom), andsizes="auto"withobject-fit.Optional cache preference (
srcset/select-an-image-source-2d-cached.optional.html): preferring already-loaded (ordata:/ preloaded) higher-density candidates, keeping a loaded candidate whencoverchanges tocontain,sizes="auto"withobject-fit: contain, and re-selection when iframe zoom changes. Fallback sizes and candidates are chosen so browsers that only do 1D selection can't pass.Linkheaders (preload/link-header-preload-imagesrcset-2d.html+.headers):rel=preload; as=imagewithhdescriptors andcover/contain/ media-conditioned 2Dimagesizes, plus aw-only group (null default aspect ratio).