|
1267 | 1267 |
|
1268 | 1268 |
|
1269 | 1269 | </style> |
| 1270 | + |
| 1271 | +<script src="code.js"></script> |
1270 | 1272 | </head> |
1271 | 1273 |
|
1272 | 1274 |
|
@@ -1397,63 +1399,6 @@ <h3>Show built-in style tests</h3> |
1397 | 1399 | <dialog id="copyNotice">Copied !</dialog> |
1398 | 1400 |
|
1399 | 1401 |
|
1400 | | -<!--style> |
1401 | | -@counter-style counter { |
1402 | | -system: extends decimal; |
1403 | | -suffix: " "; |
1404 | | -} |
1405 | | -</style--> |
1406 | | - |
1407 | | - |
1408 | | - |
1409 | | -<script> |
1410 | | - |
1411 | | -function addExamples (styleName, lang, dir, type) { |
1412 | | - // draws the "Output in your browser" boxes. |
1413 | | - // type is one of 'vshort' (stops after 22), or short (stops after 44) |
1414 | | - if (typeof type === 'undefined') type = 'full' |
1415 | | - |
1416 | | - var out = '' |
1417 | | - out += `<p class="browser_output_title">Output in your browser:<a style="float:right" href="https://developer.mozilla.org/en-US/docs/Web/CSS/list-style-type#browser_compatibility" target="_blank"><img src="compat.svg" alt="Check for built-in browser support." title="Check for built-in browser support."></a></p>` |
1418 | | - out += `<div class="template_container" style="display:flex; flex-direction:row; justify-content:space-between;"` |
1419 | | - if (dir === 'rtl') out += ` dir="rtl">` |
1420 | | - else out += `>` |
1421 | | - |
1422 | | - out += ` |
1423 | | - <ol lang="${ lang }" style="list-style-type: ${ styleName }; display:block;"><li>one</li><li>two</li><li>three</li><li>four</li><li>five</li></ol> |
1424 | | - <ol start="6" lang="${ lang }" style="list-style-type: ${ styleName }; display:block;"><li>six</li><li>seven</li><li>eight</li><li>nine</li><li>ten</li></ol> |
1425 | | - <div> |
1426 | | - <ol start="11" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>11</li></ol> |
1427 | | - <ol start="22" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>22</li></ol>` |
1428 | | - if (type !== 'vshort') out += ` |
1429 | | - <ol start="33" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>33</li></ol> |
1430 | | - <ol start="44" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>44</li></ol>` |
1431 | | - out += `</div>` |
1432 | | - |
1433 | | - if (type === 'full') { |
1434 | | - out += `<div> |
1435 | | - <ol start="111" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>111</li></ol> |
1436 | | - <ol start="222" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>222</li></ol> |
1437 | | - <ol start="333" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>333</li></ol> |
1438 | | - <ol start="444" class='high' lang="${ lang }" style="list-style-type: ${ styleName };"><li>444</li></ol>` |
1439 | | - } |
1440 | | - |
1441 | | - out += `</div> |
1442 | | - ` |
1443 | | - out += `</div>` |
1444 | | - |
1445 | | - document.getElementById('out_'+styleName).innerHTML = out |
1446 | | - } |
1447 | | - |
1448 | | -function copyTemplate (id) { |
1449 | | - navigator.clipboard.writeText(document.getElementById(id).parentNode.querySelector('.counterstyle').textContent) |
1450 | | - document.getElementById('copyNotice').style.display = 'block' |
1451 | | - setTimeout(() => { document.getElementById('copyNotice').style.display = 'none' }, '500') |
1452 | | - } |
1453 | | -</script> |
1454 | | - |
1455 | | - |
1456 | | - |
1457 | 1402 |
|
1458 | 1403 |
|
1459 | 1404 |
|
|
0 commit comments