mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-21 17:25:36 +00:00
27a84a9c29
MozReview-Commit-ID: AQhUS2JNlYZ --HG-- extra : rebase_source : 9c88668ff91b5aa9ebc419aab922497e52ee0cf7
17 lines
446 B
HTML
17 lines
446 B
HTML
<!DOCTYPE html>
|
|
<style>
|
|
div { color: green; }
|
|
.red > span { color: red; }
|
|
</style>
|
|
<div id="first"><span></span></div>
|
|
<div id="second"><span>This text should be green.</span></div>
|
|
<script>
|
|
getComputedStyle(second.firstChild).color;
|
|
getComputedStyle(first.firstChild).color;
|
|
second.className = "red";
|
|
getComputedStyle(second.firstChild).color;
|
|
first.className = "red";
|
|
second.className = "";
|
|
getComputedStyle(second.firstChild).color;
|
|
</script>
|