Re: [csswg-drafts] Proposal: fix page load speed vs. image quality trade-off, allow gradually higher resolution images and browser understanding of low bandwidth situation via CSS media query (#11691)

I just found out this won't fully work with the `picture` element even if the CSS selector was added. A lower res `source` won't be scaled up to the same dimensions of the full image. And a `style` can't be used on a `source`.

So there will either need to be some stretch setting so a `source` will be scaled up:
```
<picture>
   <source media="(bandwidth: low)" srcset="desktop_lowres.png" stretch=1/>
   <img src="desktop_highres.png" alt="A photo of London by night"/>
</picture>
```
And/or there should be a simple way to do this via an `img` element:
```
<img src="desktop_highres.png" srcsmall="desktop_lowres.png"
 alt="A photo of London by night"/>
```
The latter would solve how clunky and confusing `picture` elements must seem to beginners.

-- 
GitHub Notification of comment by ell1e
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/11691#issuecomment-3165607762 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 7 August 2025 20:27:36 UTC