This gist is a proposal for the Element Query API of the Atomic Layout library.
Element queries (also known as "container queries") is an experimental media query declaration pattern, where the next set of CSS properties is applied to an element based on its own properties, as opposed to conventional viewport properties (min-width
of a viewport).
I believe that first class Element Query support in Atomic Layout would bring a true element-centered layout development upfront, and encourage developers to think of a UI unit as a singleton that may evolve on its own.
As much as I want to design a versatile API, it's necessary to acknowledge the distribution context of such API. In this case it's the Atomic Layout library. Therefore, the API suggested should work well with surrounding API, meaning it shouldn't contradict the established principles of the library and React.
The following information may be of your interest to understand the proposal better: