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

Side by Side Diff: LayoutTests/fast/css/variables/computed-style.html

Issue 14987004: Switching CSS Variables over to RuntimeEnabledFeatures (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 7 months 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 <script>
2 internals.settings.setCSSVariablesEnabled(true);
3 </script>
4 <style> 1 <style>
5 body { 2 body {
6 -webkit-var-a: bold; 3 -webkit-var-a: bold;
7 font-weight: normal; 4 font-weight: normal;
8 font-weight: -webkit-var(a); 5 font-weight: -webkit-var(a);
9 } 6 }
10 </style> 7 </style>
11 <body> 8 <body>
12 Test failed - JS did not run 9 Test failed - JS did not run
13 </body> 10 </body>
14 <script> 11 <script>
15 var element = document.body; 12 var element = document.body;
16 var weight = window.getComputedStyle(element, null).getPropertyValue("font-weigh t"); 13 var weight = window.getComputedStyle(element, null).getPropertyValue("font-weigh t");
17 if (weight == "bold") 14 if (weight == "bold")
18 element.innerHTML = "Test passed - computed font weight is bold"; 15 element.innerHTML = "Test passed - computed font weight is bold";
19 else 16 else
20 element.innerHTML = "Test failed - computed color is " + weight; 17 element.innerHTML = "Test failed - computed color is " + weight;
21 </script> 18 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698