Skip to content

Fix registry 404 and docs preview rendering#10222

Open
manthansubhash01 wants to merge 2 commits intoshadcn-ui:mainfrom
manthansubhash01:fix/docs-registry-404-combobox
Open

Fix registry 404 and docs preview rendering#10222
manthansubhash01 wants to merge 2 commits intoshadcn-ui:mainfrom
manthansubhash01:fix/docs-registry-404-combobox

Conversation

@manthansubhash01
Copy link
Copy Markdown

Fix legacy registry 404 and docs preview reliability

Summary

This PR fixes a docs/registry regression in the v4 app where legacy registry style URLs returned 404 for some components (notably combobox), and docs previews could appear blank for lazy-loaded examples.

Problem

  • Legacy registry URL requests like /r/styles/new-york/combobox.json failed.
  • Radix combobox docs referenced a mismatched style key.
  • Lazy demo previews in docs did not always render reliably.

Root Cause

  • Registry JSON for impacted components exists under new-york-v4, but some consumers still request new-york (or default).
  • The combobox docs page referenced base-nova instead of radix-nova.
  • Preview tabs rendered lazy content without a suspense boundary.

What Changed

1) Backward-compatible registry rewrites

Updated Next.js rewrites to map legacy style paths to canonical v4 style paths:

  • /r/styles/new-york/:path* -> /r/styles/new-york-v4/:path*
  • /r/styles/default/:path* -> /r/styles/new-york-v4/:path*

File changed:

  • apps/v4/next.config.mjs

2) Corrected combobox docs style references

Replaced combobox docs style references with the correct radix style key.

File changed:

  • apps/v4/content/docs/components/radix/combobox.mdx

3) Improved preview rendering resilience

Wrapped preview component rendering in React.Suspense (with fallback) for both LTR and RTL branches.

File changed:

  • apps/v4/components/component-preview-tabs.tsx

Impact

  • Legacy registry URLs now resolve to existing canonical assets.
  • Combobox docs examples and source sections point to correct style assets.
  • Docs example previews are more reliable for lazy-loaded examples.

Validation

  • Confirmed canonical registry artifacts exist for affected components:
    • public/r/styles/new-york-v4/combobox.json
    • public/r/styles/new-york-v4/popover.json
    • public/r/styles/new-york-v4/tooltip.json
  • Confirmed docs style references in combobox page now use radix-nova.
  • Confirmed suspense wrappers exist in preview tabs for both render branches.

@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Mar 28, 2026

@manthansubhash01 is attempting to deploy a commit to the shadcn-pro Team on Vercel.

A member of the Team first needs to authorize it.

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