blob: 01a55c64461e4b939f4b54ffe0d3c74646ced2eb [file] [log] [blame]
<!doctype html>
<script src="../../../resources/testharness.js"></script>
<script src="../../../resources/testharnessreport.js"></script>
<style>
div {
width: 100px;
height: 100px;
--foo: {
background-color: green;
}
}
</style>
<div id=e1 style="@apply --foo"></div>
<div id=e2 style="@apply --foo; height: 100px"></div>
<script>
test(function(){
assert_equals(getComputedStyle(e1).backgroundColor, "rgb(0, 128, 0)");
assert_equals(getComputedStyle(e2).backgroundColor, "rgb(0, 128, 0)");
assert_equals(getComputedStyle(e2).height, "100px");
}, "@apply should work when specified inside inline styles");
</script>