Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(509)

Side by Side Diff: third_party/WebKit/LayoutTests/fast/css/invalidation/range-pseudo.html

Issue 1469183003: Use invalidation sets for :in-range and :out-of-range. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed review issue and expected results Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/fast/css/invalidation/range-pseudo-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script src="../../../resources/js-test.js"></script>
3 <style>
4 :out-of-range {
5 background-color: red
6 }
7
8 :in-range, :in-range + div #descendant {
9 background-color: green
10 }
11
12 </style>
13 <input id="input" type="number" min="1" max="10" value="17"></input>
14 <div>
15 <div></div>
16 <div id="descendant"></div>
17 <div></div>
18 </div>
19
20 <script>
21 description("Use descendant invalidation sets for :in-range and :out-of-range ps eudo classes.")
22
23 var transparent = "rgba(0, 0, 0, 0)";
24 var red = "rgb(255, 0, 0)";
25 var green = "rgb(0, 128, 0)";
26
27 shouldBe("getComputedStyle(input).backgroundColor", "red");
28 shouldBe("getComputedStyle(descendant).backgroundColor", "transparent");
29
30 document.body.offsetTop; // Force recalc.
31 input.value = "5";
32
33 if (window.internals)
34 shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "2");
35 shouldBe("getComputedStyle(input).backgroundColor", "green");
36 shouldBe("getComputedStyle(descendant).backgroundColor", "green");
37
38 </script>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/fast/css/invalidation/range-pseudo-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698