Skip to content

feat(docs): split the Card page into an overview and a page per layer - #58

Merged
alexgrozav merged 1 commit into
component-sub-pages-uxf-421from
card-sub-pages-uxf-425
Oct 22, 2026
Merged

alexgrozav merged 1 commit into
component-sub-pages-uxf-421from
card-sub-pages-uxf-425

Conversation

@alexgrozav

Copy link
Copy Markdown
Contributor

What changed

The Card's page becomes content/docs/3.components/card/, shaped like the Button's: an Overview in index.md, then a page per layer, User Interface (UI), User Experience (UX), Developer Experience (DX) and Agentic Experience (AX), and a .navigation.yml that names the group and keeps the page's icon. It doesn't change what the standard says, so it isn't a guideline change for any one layer.

The Overview keeps the intro, At a glance, the Checklist's intro, the reference implementation and the sources. Four cards link the layer pages in place of the intro's list of layers, each with its page's new one-line description. At a glance now starts before the paragraph on how the examples work, then the paragraph on what a card is, the playground and the table. Each layer page has its sections a level higher, then its rules under "UI Checklist" and so on, then its questions. Links to the page's own sections go to the layer page that now has them, like /docs/components/card/ux#every-state. No other text changed.

The FAQ's questions went to the layer each one answers:

  • User Interface: "Can a card have a shadow?"
  • User Experience: "Card or something else?", "Why not wrap the whole card in a link?", "Can people select the text in a card that's a link?" and "Should a card's link open in a new tab?"
  • Developer Experience: "Does the Card work before JavaScript loads?"
  • Agentic Experience: none

The live examples are on the Overview (the playground), User Interface (three) and User Experience (two). Developer Experience and Agentic Experience have none, like the Button's.

Agents still read one page. /raw/docs/components/card.md has the same headings in the same order as before, with the same rules, and /raw/docs/components/card.yaml is the same contract apart from link targets.

Checklist

  • The title follows Conventional Commits, as in feat(docs): add the focus guideline.
  • pnpm check-types passes.
  • Docs changes: the pages read well on pnpm dev. (Checked on the built site through wrangler dev instead: the sidebar, the header's menu, the previous and next links, every live example, the Framework select and the links from before the split.)
  • Homepage changes: pnpm build, then pnpm lighthouse, still scores 100 in every category. (No homepage changes.)

The Card's page becomes a folder shaped like the Button's: an Overview, a
page for each layer, and its own group in the sidebar. The text moved as
it was, apart from link targets, the cards in place of the intro's list
of layers, At a glance starting before the paragraph on examples, and the
list of the four checklists.

Co-authored-by: multica-agent <github@multica.ai>
@cloudflare-workers-and-pages

Copy link
Copy Markdown

🚀 Deploying Preview to Cloudflare 🚀

Preview URL: https://card-sub-pages-uxf-425-opencomponents.blue-water-0397.workers.dev (commit cf03222)

This URL reflects your latest Preview deployment

Preview Deployments by commit

Status Deployment URL Commit Updated (UTC) See this deployment's details
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://d0ec2697-opencomponents.blue-water-0397.workers.dev cf03222 2026-10-22T12:49:55.542Z Visit the dashboard ↗

@alexgrozav
alexgrozav merged commit 377feb4 into component-sub-pages-uxf-421 Oct 22, 2026
5 checks passed
@alexgrozav
alexgrozav deleted the card-sub-pages-uxf-425 branch October 22, 2026 13:04
alexgrozav added a commit that referenced this pull request Oct 23, 2026
… layer (#69)

## What changed

The other ten component pages now have the shape the Button's got in
#54: the Card, Checkbox, Checkbox Group, Dialog, Input, Radio Group,
Spinner, Switch, Textarea and Tooltip each become a folder in
`content/docs/3.components/`. Each folder holds an Overview and a page
per layer: User Interface (UI), User Experience (UX), Developer
Experience (DX) and Agentic Experience (AX). The text moves as it is.
The only changes are the ones the Button's split made: the cards in
place of the intro's list of layers, At a glance starting before the
paragraph on examples, the four Checklist links, each part's rules under
"UI Checklist" and so on, its questions under its own FAQ, and link
targets.

Once the Checkbox was a folder, Nuxt Content would have listed Checkbox
Group before it, since it sorts by file path and `-` comes before `/`.
`app/lib/navigation.ts` keeps the component pages in name order in the
sidebar, the header's menu and the links to the previous and next pages.
`app/components/UContentSurround.vue` replaces Nuxt UI's to read that
order. The tests that covered the Button's split, and the Button-only
checks in `scripts/check-mcp.mjs`, now run once for every split
component. Links between components go straight to the section's new
page. Links from before the split, like `/docs/components/input#sizes`,
still land on the right page through the redirect map.

In the sidebar and the header's menu, a component's name opens and
closes the list of its pages, the Overview and its layers, without
navigating, so you pick the page you want. The group still opens on any
of its pages and closes once you leave them.

Agents see no difference. `/raw/docs/components/<component>.md` and
`.yaml`, and the MCP server, serve each component as one page with the
outline and contract it has on `main`. The FAQ comes back grouped by
layer. A changelog entry announces the change, and `AGENTS.md` and
`.github/CONTRIBUTING.md` now say every component page is split like the
Button's.

It collects these PRs, each reviewed on its own: #56 (component order),
#57 (split tests), #58 to #67 (one per component), #68 (links between
components, changelog, guides) and #70 (the name opens the group,
without navigating).

To try it, run `pnpm dev` and open `/docs/components/checkbox`.

## Checklist

- [x] The title follows [Conventional
Commits](https://www.conventionalcommits.org), as in `feat(docs): add
the focus guideline`.
- [x] `pnpm check-types` passes.
- [x] Docs changes: the pages read well on `pnpm dev`. (Checked on a
`pnpm build` served with `wrangler dev`.)
- [x] Homepage changes: `pnpm build`, then `pnpm lighthouse`, still
scores 100 in every category. (No homepage changes, but the redirect map
now covers eleven components and loads on every page, so it ran: 100 in
every category on all three runs.)

---------

Co-authored-by: multica-agent <github@multica.ai>
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