tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

textarea-break-spaces-002.html (1409B)


      1 <!DOCTYPE html>
      2 <meta charset="utf-8">
      3 <title>CSS Text level 3 Test: single preserved white space at the end of with white-space:break-spaces in a textarea</title>
      4 <link rel="author" title="Florian Rivoal" href="http://florian.rivoal.net/">
      5 <link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-phase-2">
      6 <link rel="help" href="https://drafts.csswg.org/css-text-3/#valdef-white-space-break-spaces">
      7 <link rel="match" href="reference/textarea-pre-wrap-001-ref.html">
      8 <meta name="assert" content="a single preserved white space at the end of the line is not wrapped when the white-space property is set to pre-wrap and overflow-wrap is break-spaces in a textarea.">
      9 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
     10 <style>
     11 textarea {
     12  word-wrap: initial; /*deprecated alias*/
     13  overflow-wrap: initial;
     14  line-break: initial;
     15  word-break: initial;
     16  margin: 0;
     17  padding: 0;
     18  border: none;
     19  outline: none;
     20  resize: none;
     21  overflow: hidden; /* I don't want scrollbars, and overflow:visible isn't typically supported on textarea */
     22 
     23  font-size: 20px;
     24  font-family: Ahem;
     25  line-height: 1em;
     26  white-space: break-spaces;
     27  color: green;
     28 
     29  background: linear-gradient(red, red) 0 0/2ch 2ch no-repeat;
     30 
     31  width: 2ch;
     32 }
     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  <textarea>XX XX</textarea>
     38 </body>