| <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> |
| <html> |
| <head> |
| <title>CSS Test: Counter-increment tests</title> |
| <link rel="author" title="Microsoft" href="http://www.microsoft.com/"> |
| <link rel="help" href="http://www.w3.org/TR/CSS21/generate.html#counters"> |
| <script src="../../../resources/js-test.js"></script> |
| <script> |
| jsTestIsAsync = true; |
| |
| function run() |
| { |
| // Some extra WebKit testing for counter-increment inherit |
| shouldBe("window.internals.counterValue(document.getElementById('wrapper90'))", "'5'"); |
| shouldBe("window.internals.counterValue(document.getElementById('test90'))", "'10'"); |
| shouldBe("window.internals.counterValue(document.getElementById('test90a'))", "'15'"); |
| shouldBe("window.internals.counterValue(document.getElementById('wrapper91'))", "'10'"); |
| shouldBe("window.internals.counterValue(document.getElementById('test91'))", "'20'"); |
| shouldBe("window.internals.counterValue(document.getElementById('test91a'))", "'30'"); |
| finishJSTest(); |
| } |
| </script> |
| <style type="text/css"> |
| #wrapper90 /*test 90*/ |
| { |
| counter-increment: ident90 5; |
| } |
| #wrapper90:before |
| { |
| content: counter(ident90); |
| } |
| #test90 |
| { |
| counter-increment: inherit; |
| } |
| #test90:before |
| { |
| content: counter(ident90); |
| } |
| #test90a |
| { |
| counter-increment: inherit; |
| } |
| #test90a:before |
| { |
| content: counter(ident90); |
| } |
| |
| #wrapper91 /*test 91*/ |
| { |
| counter-increment: ident91 5 ident91 5; |
| } |
| #wrapper91:before |
| { |
| content: counter(ident91); |
| } |
| #test91 |
| { |
| counter-increment: inherit; |
| } |
| #test91:before |
| { |
| content: counter(ident91); |
| } |
| #test91a |
| { |
| counter-increment: inherit; |
| } |
| #test91a:before |
| { |
| content: counter(ident91); |
| } |
| |
| </style> |
| </head> |
| <body onload="setTimeout('run()', 0);"> |
| <div id="wrapper90"> |
| <div id="test90"> |
| <div id="test90a"></div> |
| </div> |
| </div> |
| <div id="wrapper91"> |
| <div id="test91"> |
| <div id="test91a"></div> |
| </div> |
| </div> |
| </body> |
| </html> |