image-min-max-content-intrinsic-size-change-007.html (949B)
1 <!doctype html> 2 <html class="reftest-wait"> 3 <title>CSS Test: Image size is not altered when it loads when min/max-size depends on the transferred intrinsic sizes, not natural sizes</title> 4 <link rel="author" href="mailto:emilio@crisal.io" title="Emilio Cobos Álvarez"> 5 <link rel="author" href="https://mozilla.org" title="Mozilla"> 6 <link rel="help" href="https://drafts.csswg.org/css-sizing/#sizing-values"> 7 <link rel="help" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1546739"> 8 <link rel="match" href="image-min-max-content-intrinsic-size-change-003-ref.html"> 9 <style> 10 img { 11 border: 1px solid black; 12 height: 80px; 13 width: 70px; 14 max-height: min-content; 15 writing-mode: vertical-lr; 16 } 17 </style> 18 <img> 19 <script> 20 let img = document.querySelector("img"); 21 img.offsetWidth; // Ensure the image is laid out. 22 img.onload = () => document.documentElement.className = ""; 23 img.src = "/css/support/60x60-green.png"; 24 </script>