tor-browser

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

cssom-name-setter-invalid.html (1035B)


      1 <!DOCTYPE html>
      2 <title>CSSCounterStyleRule name setter with invalid values</title>
      3 <link rel="help" href="https://www.w3.org/TR/css-counter-styles-3/#the-csscounterstylerule-interface">
      4 <link rel="author" href="mailto:xiaochengh@chromium.org">
      5 <link rel="match" href="cssom-name-setter-ref.html">
      6 <style id="sheet">
      7 @counter-style foo {
      8  system: fixed;
      9  symbols: A B C;
     10 }
     11 
     12 @counter-style bar {
     13  system: fixed;
     14  symbols: X Y Z;
     15 }
     16 </style>
     17 
     18 <ol style="list-style-type: foo; list-style-position: inside">
     19  <li></li>
     20  <li></li>
     21  <li></li>
     22 </ol>
     23 
     24 <ol style="list-style-type: bar; list-style-position: inside">
     25  <li></li>
     26  <li></li>
     27  <li></li>
     28 </ol>
     29 
     30 <script>
     31 // Force layout update before changing the rule
     32 document.body.offsetWidth;
     33 
     34 const sheet = document.getElementById('sheet');
     35 const rule = sheet.sheet.rules[0];
     36 
     37 // Invalid values should be ignored
     38 rule.name = '';
     39 rule.name = '123';
     40 rule.name = 'initial';
     41 rule.name = 'inherit';
     42 rule.name = 'unset';
     43 rule.name = 'none';
     44 rule.name = 'disc';
     45 rule.name = 'decimal';
     46 </script>