docs(storybook): file 43 orphaned docs pages under their real sections - #1289
Merged
Conversation
43 `.docs.mdx` files had no `<Meta>` at all, so Storybook fell back to
deriving their title from the file path. That produced a stray lowercase
`components` root section in the sidebar that mirrored the source tree
(`components/content/Alert/Alert.docs`), with `.docs` suffixes on every
name — alongside a lone `Components/CollectionItem` from the one file that
did set a title, just not to a real section.
Where the component has a stories file, attach the doc to it with
`<Meta of={XStories} />`, matching what every already-correct doc in the
repo does. That also collapses the duplicate: these components previously
had both an autodocs "Docs" page and an orphaned hand-written one.
Where there is no stories file, set an explicit `<Meta title>`:
Actions ButtonGroup, MenuTrigger, SubMenuTrigger
Content Content, Divider, Footer, Header, Title, StatsCard
Layout Flex, Flow, Grid, GridProvider, Panel, Prefix, Space, Suffix
Navigation FileTabs
Overlays TooltipProvider, TooltipTrigger
Getting Started Root, CollectionItem
The `organisms/` folder had no matching section, so FileTabs goes to
Navigation (next to Tabs) and StatsCard to Content (it extends Card).
Root and CollectionItem are cross-cutting rather than per-component, so
they sit in Getting Started and are slotted into the storySort order.
Rename `portal.stories.tsx` to `Portal.stories.tsx` — the only lowercase
stories file in the repo, and the casing kept Storybook from letting the
attached MDX replace its autodocs page, leaving Helpers/Portal with two
docs entries.
Verified against a fresh index: 0 entries left under `components/*`, no
title with more than one Docs entry, and every moved page renders.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
tenphi
had a problem deploying
to
Chromatic staging
August 7, 2026 17:43 — with
GitHub Actions
Error
🦋 Changeset detectedLatest commit: adfc646 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
📦 NPM canary releaseDeployed canary version 0.0.0-canary-616b8f5. |
Contributor
🧪 Storybook is successfully deployed!
|
Contributor
🏋️ Size limit report
Click here if you want to find out what is changed in this build |
tenphi
had a problem deploying
to
Chromatic staging
August 7, 2026 20:41 — with
GitHub Actions
Error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
43
.docs.mdxfiles had no<Meta>at all, so Storybook derived their title from the file path. That produced a stray lowercasecomponentsroot section in the sidebar mirroring the source tree —components/content/Alert/Alert.docs— with.docssuffixes on every name, plus a loneComponents/CollectionItemfrom the one file that did set a title, just not to a real section.Where the component has a stories file (21 files) — attach with
<Meta of={XStories} />, matching what every already-correct doc in this repo does (Tooltip,Menu,Tabs,Layout, …). This also collapses a duplicate: those components previously had both an autodocs "Docs" page and an orphaned hand-written one.Where there is no stories file (22 files) — set an explicit
<Meta title>:Judgment calls worth a look
organisms/folder has no matching sidebar section. FileTabs → Navigation (next to Tabs; it is a tab bar) and StatsCard → Content (it extendsCard).Base Properties/Field Properties, and are slotted into thestorySortorder rather than falling to the end.'Components'entry fromstorySort.Also
portal.stories.tsx→Portal.stories.tsx. It was the only lowercase stories file in the repo, and that casing stopped Storybook from letting the attached MDX replace its autodocs page —Helpers/Portalended up with two docs entries. Renaming fixed it. Nothing imported it by path.Verification
Against a freshly indexed Storybook on this branch:
components/*(was 43)import * as XStoriespath resolves on disk, and spot-checked pages render (Content/Alert,Helpers/Portal,Layout/Flex,Getting Started/Root,Content/StatsCard,Navigation/FileTabs)Sections after: Forms 421, Content 302, Actions 114, Overlays 68, Getting Started 54, Navigation 39, Layout 38, Helpers 22, Status 10, Other 6.
Docs-only;
.docs.mdxis not part of the published package, hence the empty changeset..docs.mdxis also outside the repo's Prettier/lint-staged globs, so the files are left formatted as they were apart from the added header.🤖 Generated with Claude Code
Note
Medium Risk
Removing
FileTabsis a breaking public API change for any consumer still importing it; Storybook-only doc moves are low risk.Overview
Storybook docs — Forty-three
.docs.mdxfiles that lacked<Meta>(or used wrong titles) now sit under real sidebar sections instead of a straycomponents/*tree. Pages with stories use<Meta of={Stories} />; the rest get explicit titles (e.g. Getting Started forRootandCollectionItem, Layout for grid primitives).storySortdrops the dead'Components'entry and adds Root and CollectionItem under Getting Started.Breaking API —
FileTabs,FileTabs.TabPane, andCubeFileTabPropsare removed from@cube-dev/ui-kit(minor changeset). Migration: useTabswithonDeletefor close buttons; put dirty indicators in tabtitleoractions. Implementation, docs, eslint default registry, and fixtures are cleaned up accordingly.Tooling — ESLint defaults coverage ratchet lowered from 72 → 71 after dropping the
FileTabsfixture.Reviewed by Cursor Bugbot for commit adfc646. Bugbot is set up for automated code reviews on this repo. Configure here.