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

Side by Side Diff: LayoutTests/fast/css/dynamic-class-pseudo-elements.html

Issue 672953002: Convert first letter into a pseudo element. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <script src="../../resources/js-test.js"></script> 2 <script src="../../resources/js-test.js"></script>
3 <style> 3 <style>
4 .a1 .b1::before { background-color: green; content: "X" } 4 .a1 .b1::before { background-color: green; content: "X" }
5 .a2 .b2::after { background-color: green; content: "X" } 5 .a2 .b2::after { background-color: green; content: "X" }
6 .a3 .b3::first-line { background-color: green } 6 .a3 .b3::first-line { background-color: green }
7 .a4 .b4::first-letter { background-color: green } 7 .a4 .b4::first-letter { background-color: green }
8 8
9 /* workaround for issue 351322 */ 9 /* workaround for issue 351322 */
10 .b3::first-line { background-color: transparent } 10 .b3::first-line { background-color: transparent }
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 shouldBe("getComputedStyle(r3, '::first-line').backgroundColor", "green"); 74 shouldBe("getComputedStyle(r3, '::first-line').backgroundColor", "green");
75 75
76 var t4 = document.getElementById("t4"); 76 var t4 = document.getElementById("t4");
77 var r4 = document.getElementById("r4"); 77 var r4 = document.getElementById("r4");
78 shouldBe("getComputedStyle(r4, '::first-letter').backgroundColor", "transparent" ); 78 shouldBe("getComputedStyle(r4, '::first-letter').backgroundColor", "transparent" );
79 79
80 forceLayout(); 80 forceLayout();
81 t4.className = "a4"; 81 t4.className = "a4";
82 82
83 if (window.internals) 83 if (window.internals)
84 shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "8"); 84 shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "10");
85 85
86 document.body.offsetLeft; // workaround for issue 351308 86 document.body.offsetLeft; // workaround for issue 351308
87 shouldBe("getComputedStyle(r4, '::first-letter').backgroundColor", "green"); 87 shouldBe("getComputedStyle(r4, '::first-letter').backgroundColor", "green");
88 </script> 88 </script>
OLDNEW
« no previous file with comments | « LayoutTests/TestExpectations ('k') | LayoutTests/fast/css/dynamic-class-pseudo-elements-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698