diff options
author | Yuri Kobets <[email protected]> | 2024-01-31 03:48:44 +0300 |
---|---|---|
committer | GitHub <[email protected]> | 2024-01-31 03:48:44 +0300 |
commit | 6ca1ab0419e770e6d35a1ef690238773a1dafcee (patch) | |
tree | 16df635edd594dc1d1b9d0044993e2ae4d0e0200 /test/render/flex/-flexbox-min-width-auto-006.htm | |
parent | 8c320007878795fe629de7fe1eaef9328ac9c719 (diff) | |
parent | d85ebec101e77825e5708e58df0e2508ec4fd389 (diff) |
Flex layout
Diffstat (limited to 'test/render/flex/-flexbox-min-width-auto-006.htm')
-rw-r--r-- | test/render/flex/-flexbox-min-width-auto-006.htm | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/test/render/flex/-flexbox-min-width-auto-006.htm b/test/render/flex/-flexbox-min-width-auto-006.htm new file mode 100644 index 00000000..66254378 --- /dev/null +++ b/test/render/flex/-flexbox-min-width-auto-006.htm @@ -0,0 +1,45 @@ +<!DOCTYPE html> +<html><head><title>CSS Flexible Box Test: Aspect ratio handling of images</title> +<link href="mailto:[email protected]" rel="author" title="Sergio Villar Senin"> +<link href="https://drafts.csswg.org/css-flexbox-1/#min-size-auto" rel="help"> +<link href="reference/flexbox-min-width-auto-006-ref.htm" rel="match"> +<meta content="Test that min-width:auto does not incorrectly stretch items with aspect ratio" name="assert"> + +<style> +#reference-overlapped-red { + position: relative; + background-color: red; + width: 10px; + height: 10px; + top: 40px; + z-index: -1; +} +.constrained-width-flex { + width: 100px; + display: flex; + border: 1px solid black; +} +.constrained-height-flex { + display: flex; + height: 100px; +} +</style> + +</head><body><p>Test passes if there are a (vertically centered) 20x20 and a 60x100 green boxes enclosed on each 100x100 square.</p> + +<div class="constrained-width-flex"> + <div class="constrained-height-flex"> + <img src="data:image/svg+xml, + <svg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'> + <rect width='100%' height='100%' fill='green'/> + </svg>"> + </div> +</div> + +<br> + +<div class="constrained-width-flex"> + <div class="constrained-height-flex"> + <img src="support/60x60-green.png"> + </div> +</div></body></html>
\ No newline at end of file |