Re: [csswg-drafts] [css-contain-3] What container features can be queried? (#5989)

In the container query polyfill I created a while ago, querying other properties is possible too ([demo](https://ausi.github.io/cq-prolyfill/demo/)).

From what I learned, the number of useful properties to query against seems to be quite limited.

> If they are possible, would these queries require the same size/layout/style containment that we need for dimensional queries?

I think containment is only required for properties relating to layout/dimensions. But which parent should get selected as the “container” should be defined on a per property basis. For `background-color` the first ancestor that has a non-transparent background should probably be the “container”. Inherited properties can use the direct parent as the “container”.

I also think it would make sense to limit it to layout at first. Or at least to a limited set of properties that are supported like `background-color`, `color`, `font-size` and `text-align`.

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


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

Received on Saturday, 13 February 2021 10:24:20 UTC