testing/web-platform/tests/css/css-values/calc-size/calc-size-aspect-ratio-003.html
author Sotaro Ikeda <sotaro.ikeda.g@gmail.com>
Thu, 10 Jul 2025 00:10:09 +0000 (6 hours ago)
changeset 795941 23763b72c35abeead04f63e4503c28abc73d065d
parent 750338 ecf7bc076831dd819524be20f7a5279db292608a
permissions -rw-r--r--
Bug 1976135 - Remove nightly only limitation of pref gfx.webrender.layer-compositor r=gfx-reviewers,gw Differential Revision: https://phabricator.services.mozilla.com/D256379
<!DOCTYPE html>
<link rel="help" href="https://drafts.csswg.org/css-values-5/#calc-size">
<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#aspect-ratio">
<link rel="match" href="../../reference/ref-filled-green-100px-square-only.html">
<p>Test passes if there is a filled green square.</p>
<!-- The auto height is 50px, the auto min-size is 150px, which passing through the calc-size() yields 100px. -->
<div style="aspect-ratio: 2/1; width: 100px; min-height: calc-size(auto, size - 50px); background: green;">
  <div style="height: 150px;"></div>
</div>