Intent to Ship: Auto Sizes for Lazy Loaded Images with Srcset

2,112 views
Skip to first unread message

Traian Captan

unread,
Dec 1, 2023, 2:08:14 AM12/1/23
to blink-dev

Contact emails

tca...@chromium.org

Explainer

https://github.com/whatwg/html/issues/4654

Specification

https://html.spec.whatwg.org/#sizes-attributes

Summary

Auto Sizes allows developers to set the sizes attribute to auto (sizes=auto) for lazy loaded image elements with srcset. For this use case the image's width and height should be provided. The browser will use the layout width of the image in order to select the source url from the srcset.



Blink component

Blink>Image

Search tags

sizessizes=autoautosizessrcset

TAG review



TAG review status

Not applicable

Risks



Interoperability and Compatibility

None since all major browsers (Chrome, Safari and Firefox) indicate that they would be willing to implement it.



Gecko: Positive (https://github.com/mozilla/standards-positions/issues/650)

WebKit: Positive (https://github.com/WebKit/standards-positions/issues/9)

Web developers: No signals

Other signals:

WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?



Debuggability



Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?

Yes

Is this feature fully tested by web-platform-tests?

Yes

PR for current tests pending merge: https://github.com/web-platform-tests/wpt/pull/34427 Rendering wpt.fyi tests will be included with the prototype CL.



Flag name on chrome://flags

AutoSizeLazyLoadedImages

Finch feature name

None

Non-finch justification

None

Requires code in //chrome?

False

Tracking bug

https://bugs.chromium.org/p/chromium/issues/detail?id=1359051

Estimated milestones

DevTrial on desktop122
DevTrial on Android122


Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).



Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5191555708616704

Links to previous Intent discussions

Intent to prototype: https://groups.google.com/a/chromium.org/g/blink-dev/c/AYoqvNluyeA

This intent message was generated by Chrome Platform Status.

Rick Byers

unread,
Dec 5, 2023, 2:33:43 PM12/5/23
to Traian Captan, blink-dev
Nice! LGTM1

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAFxahvuCb7xXip6nqDAykaRGXy5uX3%2BXZsuPY62s9ntV03PDqw%40mail.gmail.com.

Mike Taylor

unread,
Dec 5, 2023, 2:49:56 PM12/5/23
to Rick Byers, Traian Captan, blink-dev

Yoav Weiss

unread,
Dec 6, 2023, 11:07:49 AM12/6/23
to blink-dev, Mike Taylor, blink-dev, Rick Byers, Traian Captan
LGTM3!! Thanks for pushing this through! :)

Nice! LGTM1

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
Reply all
Reply to author
Forward
0 new messages