grid-lanes-intrinsic-sizing-rows-004-fr.html (2574B)
1 <!DOCTYPE HTML> 2 <!-- 3 Any copyright is dedicated to the Public Domain. 4 http://creativecommons.org/publicdomain/zero/1.0/ 5 --> 6 <html> 7 <meta charset="utf-8"> 8 <title>CSS Grid Test: Grid Lanes layout column sizing - max-content</title> 9 <link rel="author" title="Mats Palmgren" href="mailto:mats@mozilla.com"> 10 <link rel="help" href="https://drafts.csswg.org/css-grid-3"> 11 <link rel="match" href="grid-lanes-intrinsic-sizing-rows-004-fr-ref.html"> 12 <style> 13 14 @import "support/grid-lanes-intrinsic-sizing-visual.css"; 15 16 grid { 17 display: inline-grid-lanes; 18 grid-lanes-direction: row; 19 gap: 1px 2px; 20 grid-template-rows: 1fr 2fr 1fr 1fr; 21 border: 1px solid; 22 padding: 1px 0 2px 0; 23 vertical-align: top; 24 height: max-content; 25 } 26 27 item { 28 /* allow for differing min-content and max-content sizes */ 29 writing-mode: vertical-rl; 30 text-orientation: sideways; 31 } 32 </style> 33 34 <body> 35 36 <section> 37 <grid title="Wider 1st item 2ch"> 38 <item style="height:2ch">1</item> 39 <item>2 2</item> 40 <item>3 3</item> 41 <item>4</item> 42 <item>5 5</item> 43 </grid> 44 45 <grid title="Wrapped 5th item 2ch"> 46 <item>1</item> 47 <item>2 2</item> 48 <item>3 3</item> 49 <item>4</item> 50 <item style="height:2ch">5 5</item> 51 </grid> 52 53 <grid title="Wrapped 5th item 2ch in col 2"> 54 <item>1</item> 55 <item>2 2</item> 56 <item>3 3</item> 57 <item>4</item> 58 <item style="height:2ch; grid-row:2">5 5</item> 59 </grid> 60 61 <grid title="5th item 4ch in col 2-3"> 62 <item>1</item> 63 <item>2 2</item> 64 <item>3 3</item> 65 <item>4</item> 66 <item style="height:4ch; grid-row:2/span 2">5 5</item> 67 </grid> 68 69 <grid title="5th item in col 2-3, 6th item 5ch in col 1-3"> 70 <item>1</item> 71 <item>2 2</item> 72 <item>3 3</item> 73 <item>4</item> 74 <item style="grid-row:2/span 2">5 5</item> 75 <item style="height:5ch; grid-row:span 3/4">6</item> 76 </grid> 77 78 <grid title="5th item 3ch in col 2-3, 6th item 5ch in col 1-3"> 79 <item>1</item> 80 <item>2 2</item> 81 <item>3 3</item> 82 <item>4</item> 83 <item style="height:3ch; grid-row:span 2/4">5</item> 84 <item style="height:5ch; grid-row:1/span 3">6</item> 85 </grid> 86 87 <grid title="5th item span 4"> 88 <item>1</item> 89 <item>2 2</item> 90 <item>3 3</item> 91 <item>4</item> 92 <item style="grid-row:span 4">5 5</item> 93 </grid> 94 95 <grid title="5th item 6ch span 4"> 96 <item>1</item> 97 <item>2 2</item> 98 <item>3 3</item> 99 <item>4</item> 100 <item style="height:6ch; grid-row:span 4">5 5</item> 101 </grid> 102 103 <grid title="5th item 6ch span 3"> 104 <item>1</item> 105 <item>2 2</item> 106 <item>3 3</item> 107 <item>4</item> 108 <item style="height:6ch; grid-row:span 3">5 5</item> 109 </grid> 110 </section> 111 </body>