word-break-break-all-011.html (1272B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS Text Test: word-break: break-all</title> 4 <link rel="author" title="Javier Fernandez Garcia-Boente" href="mailto:jfernandez@igalia.com"> 5 <link rel="help" href="https://drafts.csswg.org/css-text-3/#valdef-word-break-break-all"> 6 <link rel="help" href="https://drafts.csswg.org/css-text-3/#valdef-white-space-pre-wrap"> 7 <meta name="flags" content="ahem"> 8 <link rel="match" href="reference/word-break-break-all-010-ref.html"> 9 <meta name="assert" content="A single leading white-space should account as soft breaking opportunity, honoring the 'white-space: pre-wrap', on top to the ones provided by 'word-break: break-all'."> 10 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" /> 11 <style> 12 div { 13 position: relative; 14 font-size: 20px; 15 font-family: Ahem; 16 line-height: 1em; 17 } 18 .red { 19 position: absolute; 20 background: green; 21 color: red; 22 width: 100px; 23 height: 100px; 24 z-index: -1; 25 white-space: pre; 26 } 27 span { color: green; } 28 .test { 29 color: green; 30 width: 1ch; 31 white-space: pre-wrap; 32 word-break: break-all; 33 } 34 </style> 35 <body> 36 <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> 37 <div class="red"> <br>X<br>X</div> 38 <div class="test"> XX</div> 39 </body>