Map the width and height attribute of images to aspect-ratio
Categories
(Core :: Layout: Images, Video, and HTML Frames, enhancement, P3)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox69 | --- | fixed |
People
(Reporter: emilio, Assigned: emilio)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
This is fantasai's and Jenn's proposal in:
https://github.com/mozilla/standards-positions/issues/129#issuecomment-472635914
I think it's worth trying it, at least on Nightly / Beta, and maybe also collect telemetry for when it changes layout on release.
| Assignee | ||
Comment 1•4 years ago
|
||
| Assignee | ||
Comment 2•4 years ago
|
||
Depends on D29037
| Assignee | ||
Comment 3•4 years ago
|
||
It works!
Depends on D29038
| Assignee | ||
Comment 4•4 years ago
|
||
Have some patches, the last one of which is a complete hack. Should do a bit more cleanup before sending them for review, but I uploaded them regardless. I didn't have power so I didn't want to touch many headers, thus the hacky approach.
May finish it up next week. I'll also push to try to see if there's something obviously broken.
Updated•4 years ago
|
Updated•4 years ago
|
Updated•4 years ago
|
Updated•4 years ago
|
Updated•4 years ago
|
Updated•4 years ago
|
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e7fd34a8c655 Add an internal aspect-ratio CSS property. r=dholbert https://hg.mozilla.org/integration/autoland/rev/e314c697fe89 Map width and height on image-ish elements to aspect-ratio. r=dholbert https://hg.mozilla.org/integration/autoland/rev/fd9cb42cee29 Make mapped aspect-ratio get reflected in images. r=dholbert
Comment 6•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/e7fd34a8c655
https://hg.mozilla.org/mozilla-central/rev/e314c697fe89
https://hg.mozilla.org/mozilla-central/rev/fd9cb42cee29
Comment 7•4 years ago
|
||
So this affects embed, iframe, marquee, object, table, and video, in addition to actual images (img and input type="image"). Is that expected?
| Assignee | ||
Comment 8•4 years ago
|
||
Replied on IRC, but yes, we only look at the property in nsImageFrame so it's not an issue (it does affect <img>, <input type="image">, <object> with an image, ...).
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/17709 for changes under testing/web-platform/tests
Upstream PR merged
Updated•4 years ago
|
Comment 11•4 years ago
|
||
Is there a bug tracking flipping the pref in release?
| Assignee | ||
Comment 12•4 years ago
|
||
I think this should be fine to turn on on release, though I wanted to get the spec situation sorted out, see https://github.com/WICG/intrinsicsize-attribute/issues/16#issuecomment-515035191 and following.
Description
•