Skip to content

docs(foundations): add a page on CSS container queries#61

Draft
jdevalk wants to merge 1 commit into
mainfrom
standards-scan/container-queries-2026-06-27
Draft

docs(foundations): add a page on CSS container queries#61
jdevalk wants to merge 1 commit into
mainfrom
standards-scan/container-queries-2026-06-27

Conversation

@jdevalk

@jdevalk jdevalk commented Jun 27, 2026

Copy link
Copy Markdown
Owner

What

Adds a new spec page: CSS container queries under foundations.

Covers both halves of the feature:

  • Size queriescontainer-type / container-name + @container (min-width: …), so a component responds to the space its container gives it rather than the viewport.
  • Style queries@container style(--custom-prop: …), testing a container's computed custom properties.

Also:

  • Wires relatedSlugs both ways on three adjacent pages (anchor-positioning, css-containment, dynamic-viewport-units).
  • Adds the added changelog entry.
  • Regenerates the OG image for the page plus the four count-driven images (og-default, og/checklist, og/spec, og/spec/foundations).

Why now

Container queries are a notable gap in an otherwise comprehensive modern-CSS set (we already cover anchor positioning, scroll-driven animations, text-wrap, css-containment, dynamic viewport units). Style queries reached Baseline (newly available) in May 2026, which prompted the audit — and surfaced that size queries (Baseline widely available since February 2023) were never documented either.

Primary sources

Status

recommended — a modern, component-based site should style by container, not viewport, but the platform contract does not break without it. Not required.

Checks

  • npm run build passes; page renders and appears at the HTML route, the .md endpoint, and in /llms.txt.
  • npm run lint (0 errors; 1 pre-existing warning in an untouched file) and npm run format:check pass.

Opened as a draft for maintainer review per the daily standards-scan routine — not for auto-merge.

🤖 Generated with Claude Code

Documents container-type/@container size queries (CSS Containment
Module Level 3) and the newer style queries (CSS Conditional Rules
Module Level 5). Status: recommended — a modern site should style
components by their container, but the platform works without it.

Size container queries have been Baseline widely available since
February 2023; style queries reached Baseline newly available in
May 2026. Wires relatedSlugs on anchor-positioning, css-containment,
and dynamic-viewport-units; adds the changelog entry and OG images.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying specification-website with  Cloudflare Pages  Cloudflare Pages

Latest commit: 06c2e1f
Status: ✅  Deploy successful!
Preview URL: https://f0c677f5.specification-website.pages.dev
Branch Preview URL: https://standards-scan-container-que.specification-website.pages.dev

View logs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant