tomhodgins / element-queries-spec

A spec for a Container-Style Element Query Syntax
https://tomhodgins.github.io/element-queries-spec/element-queries.html
367 stars 14 forks source link

Will Element/container query would work inside nested feature query? #11

Open IamManchanda opened 6 years ago

tomhodgins commented 6 years ago

Hi! If you're talking about the @supports at-rule, presently as far as I'm aware there are no plugins that support this since they all rely on JavaScript, so any feature detection relating to polyfills for this functionality presently happens in JavaScript.

The way this spec was written (and the way EQCSS work) currently, an @supports query inside of an @element query group body rule that applies to the document would be 'seen' by the browser, but the plugins used to implement element queries right now don't read @supports, so nesting an @element query inside of @supports doesn't work anywhere today.

This functionality is undergoing a standardization effort under the WICG though, so if functionality like this is added to CSS it would make sense that you could nest the syntax we come up with inside of @supports and the browser would know what to do. But we haven't gotten that far in our new specification effort to decide stuff like how it will interact :D

The new effort is taking place here: https://github.com/WICG/container-queries