Skip to content

Commit bda94e1

Browse files
refactor(docs): add support for multi-base registry with styles subdirectory structure (#259)
* chore: cleanup playground * refactor(registry): migrate to multi-base architecture - Restructure registry from default/ to bases/radix/ and bases/base/ - Update all component imports to @/registry/bases/radix/ - Remove backward compatibility (non-prefixed JSON files) - Add base-specific JSON output (radix-*.json, base-*.json) - Fix Zod 3/4 version incompatibility in type definitions - Update build scripts for multi-base generation Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: migrate to unified radix-ui package - Replace @radix-ui/react-* imports with radix-ui - Use namespace patterns: SlotPrimitive.Slot, DirectionPrimitive.useDirection - Update registry dependencies from individual packages to radix-ui Co-authored-by: Cursor <cursoragent@cursor.com> * style: format code Co-authored-by: Cursor <cursoragent@cursor.com> * fix: update MDX paths to new registry structure Co-authored-by: Cursor <cursoragent@cursor.com> * feat: restructure docs for multi-base component support Co-authored-by: Cursor <cursoragent@cursor.com> * fix: remove separator from components meta.json Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: simplify component redirects with regex pattern Co-authored-by: Cursor <cursoragent@cursor.com> * perf: optimize repo for reduced CPU/RAM usage Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: flatten component sidebar and streamline navigation Flatten component structure by extracting radix and base items directly into the Components section, removing nested folders from the sidebar. Remove redundant Docs link from docs layout navbar while keeping it in home layout for navigation. Co-authored-by: Cursor <cursoragent@cursor.com> * feat: add preview badges and optimize utility components - Add preview badge support for sidebar components with useSyncExternalStore approach - Flatten component sidebar structure (extract radix/base items directly) - Remove Docs link from docs layout navbar - Optimize ClientOnly and Portal components with useSyncExternalStore - Set preview to false for all radix components - Delete base index.mdx - Rebuild registry with updated components Co-authored-by: Cursor <cursoragent@cursor.com> * feat: add components and changelog pages with dynamic content - Add Components listing page at /docs/components - Add Changelog page with dynamic entry loading - Create changelog folder structure with 2026-02 entry - Update root meta.json for proper page ordering - Rename ComponentList to Components and ChangelogList to Changelogs - Update doc actions to use ButtonGroup for better UX - Add date field support with coercion in schema Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: improve doc actions button group styling - Remove Open text from dropdown trigger, show only chevron icon - Change dropdown trigger to icon button with proper sizing - Add ButtonGroupSeparator between copy and dropdown buttons Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: align dropdown menu to the right Change popover align from start to end for better visual alignment with the button group Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: add spacing to button group separator Add vertical margin to prevent separator from extending to edges Co-authored-by: Cursor <cursoragent@cursor.com> * chore: cleanup stuffs * style: add vertical padding to button group separator Add my-1 to prevent separator from extending to full height Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: render changelog entries as inline list with custom ToC Co-authored-by: Cursor <cursoragent@cursor.com> * docs: rewrite changelog entry and add separator between entries Co-authored-by: Cursor <cursoragent@cursor.com> * docs: replace em dashes with commas in changelog Co-authored-by: Cursor <cursoragent@cursor.com> * style: increase changelog title size to text-2xl Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: extract changelog logic to lib/changelog.ts Co-authored-by: Cursor <cursoragent@cursor.com> * chore: cleanup changelog * chore: cleanup registry * refactor: restructure registry output to styles/ subdirectories Adopt shadcn style-based registry structure. Output to public/r/styles/{base}-{style}/ instead of flat public/r/. Generate public/r/index.json and public/r/styles/index.json. Add redirect /r/:name.json to /r/styles/radix-default/:name.json. Update cleanup, validate, and test scripts for new structure. Co-authored-by: Cursor <cursoragent@cursor.com> * chore: add shadcn/ui attribution via @see TSDoc annotations Co-authored-by: Cursor <cursoragent@cursor.com> * chore: add biome-ignore explanation for React import in styles Co-authored-by: Cursor <cursoragent@cursor.com> * fix: pin radix-ui to ^1.4.3 and fix broken doc links Co-authored-by: Cursor <cursoragent@cursor.com> * refactor: derive components list from registry instead of hardcoding Co-authored-by: Cursor <cursoragent@cursor.com> * chore: update lockfile for radix-ui version pin Co-authored-by: Cursor <cursoragent@cursor.com> * chore: sync * refactor: use-mounted * ci: increase Node.js memory limit to fix build OOM errors The docs build was failing in CI after 8m 42s due to memory exhaustion when generating 131 static pages. Allocated 6GB to Node.js and added a 15-minute timeout for the build job. Co-authored-by: Cursor <cursoragent@cursor.com> * fix: disable noUnknownPseudoElement rule for webkit scrollbar pseudo-elements Co-authored-by: Cursor <cursoragent@cursor.com> * ci: exclude docs from CI build following shadcn pattern Docs are resource-intensive (240+ TSX files, 131 static pages) and already validated by Vercel deployments. CI now only builds/tests the component packages, matching shadcn/ui's approach. Co-authored-by: Cursor <cursoragent@cursor.com> * chore: cleanup * ci: remove unnecessary memory limits and timeout Packages build quickly without docs. Memory limits and extended timeout were only needed for the docs build. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 0f4d223 commit bda94e1

File tree

2,081 files changed

+84874
-18197
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,081 files changed

+84874
-18197
lines changed

.github/workflows/main.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ jobs:
4242
version: 10.22.0
4343
- uses: ./.github/setup
4444

45-
- run: pnpm turbo build
45+
- name: Build packages (excluding docs)
46+
run: pnpm turbo build --filter=!docs
4647

4748
lint:
4849
runs-on: ubuntu-latest
@@ -68,7 +69,8 @@ jobs:
6869
version: 10.22.0
6970
- uses: ./.github/setup
7071

71-
- run: pnpm turbo test
72+
- name: Test packages (excluding docs)
73+
run: pnpm turbo test --filter=!docs
7274

7375
typecheck:
7476
runs-on: ubuntu-latest
@@ -81,4 +83,5 @@ jobs:
8183
version: 10.22.0
8284
- uses: ./.github/setup
8385

84-
- run: pnpm turbo typecheck
86+
- name: Typecheck packages (excluding docs)
87+
run: pnpm turbo typecheck --filter=!docs

.vscode/settings.json

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,34 @@
1414
["clsx\\(([^)]*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]"]
1515
],
1616
"typescript.tsdk": "node_modules/typescript/lib",
17-
"typescript.enablePromptUseWorkspaceTsdk": true
17+
"typescript.enablePromptUseWorkspaceTsdk": true,
18+
"files.watcherExclude": {
19+
"**/.git/objects/**": true,
20+
"**/.git/subtree-cache/**": true,
21+
"**/node_modules/**": true,
22+
"**/.next/**": true,
23+
"**/.turbo/**": true,
24+
"**/dist/**": true,
25+
"**/build/**": true,
26+
"**/*.mp4": true,
27+
"**/*.mp3": true,
28+
"**/*.avi": true,
29+
"**/*.mov": true,
30+
"**/*.webm": true
31+
},
32+
"search.exclude": {
33+
"**/.git": true,
34+
"**/.next": true,
35+
"**/.turbo": true,
36+
"**/node_modules": true,
37+
"**/dist": true,
38+
"**/build": true,
39+
"**/*.mp4": true,
40+
"**/*.mp3": true,
41+
"pnpm-lock.yaml": true
42+
},
43+
"files.exclude": {
44+
"**/.git": false,
45+
"**/.turbo": true
46+
}
1847
}

biome.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://biomejs.dev/schemas/2.3.10/schema.json",
2+
"$schema": "https://biomejs.dev/schemas/2.4.0/schema.json",
33
"assist": {
44
"actions": {
55
"source": {
@@ -38,7 +38,8 @@
3838
"noUnusedImports": "off",
3939
"noUnusedVariables": "warn",
4040
"useExhaustiveDependencies": "warn",
41-
"useHookAtTopLevel": "warn"
41+
"useHookAtTopLevel": "warn",
42+
"noUnknownPseudoElement": "off"
4243
},
4344
"complexity": {
4445
"noBannedTypes": "off"

0 commit comments

Comments
 (0)