Closed oslego closed 9 years ago
I believe this is a result of how scoped selectors work. The first ruleset is looking for and element with the ID of hero
inside of an element with the ID of lead
.
#lead {
/* This may work depending on your markup */
width: == ^#hero[width] / 2;
}
Ah, I missed that. Indeed, unintended nesting was the problem. Thanks for the clarification, @paulyoung!
Trying to constrain an element width to be half of another container's width. Defining the constraint in a ruleset is ignored, but it is accepted when defined as standalone constraint.
See example: http://codepen.io/oslego/pen/eNavPP