Open emilio opened 7 months ago
I don't think we made a conscious choice here, but the width/height of the container in CSS pixels as seen by the container just follows from the implementation.
I agree, that feels best aligned to how we resolve relative units on the container.
The CSS Working Group just discussed [css-viewport] [css-contain] Zoom and container queries
, and agreed to the following:
RESOLVED: use chrome/firefox behavior
It is unclear to me what specific spec changes need to be made on css-conditional-5 as a result of this resolution.
It is unclear to me what specific spec changes need to be made on css-conditional-5 as a result of this resolution.
I think the spec change needed there is to say that the principle box's bounds are unscaled.
Also: I added a testcase.
How should CSS zoom be handled (if at all) in a
@container
query?A container query like
@container (width > 100px) { }
is rather weird wrt CSS zoom. Should it use pixels:Safari disagrees with Chrome / Firefox on this test-case:
Same for container query relative units, I suspect that the best behavior involves some gymnastics with the container and child effective zoom values. Not sure what browsers implement there (Firefox doesn't zoom them at all so they use the coordinate space of the container).
cc @chrishtr @lilles @andruud @nt1m @mirisuzanne @tabatkins