Re: [csswg-drafts] [css-values-4] inherit() function: like var() for parent value, for any property (#2864)

> Am I right to assume that this is also equally feasible as long as it's a specific ancestor (e.g. 3 levels up) and not a search

@LeaVerou We should not do that. A specific ancestor is not much better than a search. It would mean that a change in _any_ property on an element (also non-inherited ones) has the potential to invalidate the styles of _all_ elements in that subtree. This is much worse than explicit inheritance (which only directly affects the immediate children), and I only like this feature if it's _not_ significantly worse than explicit inheritance. :-)

Can you share a 3-levels-up use-case?

-- 
GitHub Notification of comment by andruud
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2864#issuecomment-816590349 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Friday, 9 April 2021 10:35:03 UTC