<!DOCTYPE html><title>CSS Values and Units Test: attr() in container style queries</title><linkrel="help"href="https://drafts.csswg.org/css-conditional-5/#container-queries"><scriptsrc="/resources/testharness.js"></script><scriptsrc="/resources/testharnessreport.js"></script><style>#container{--foo:bar;}@containerstyle(--foo:attr(data-footype(<custom-ident>))){#target{color:green;}}</style><divid="container"data-foo="bar"><divid="target">Should be green</div></div><script>test(()=>{assert_equals(getComputedStyle(target).color,"rgb(0, 128, 0)");},"style query should implement to true");</script>