feat: scope Build file browser to selected app, rename Apps → Build

- Sidebar "Apps" section renamed to "Build"
- Each app now links to /build?app=<name>&root=<path> so the browser
  opens scoped to that app's subdirectory only
- Build page shows an empty-state prompt when no app is selected
- File tree header shows the selected app name, breadcrumb shows
  relative path within the app (strips the root prefix)
- Wraps useSearchParams in Suspense for Next.js static rendering

Made-with: Cursor
This commit is contained in:
2026-03-06 13:51:01 -08:00
parent e08fcf674b
commit 812645cae8
2 changed files with 176 additions and 180 deletions

View File

@@ -312,15 +312,15 @@ export function VIBNSidebar({ workspace }: VIBNSidebarProps) {
</div>
)}
{/* ── Apps ── */}
<SectionHeading label="Apps" collapsed={collapsed} />
{/* ── Build ── */}
<SectionHeading label="Build" collapsed={collapsed} />
{apps.length > 0 ? (
apps.map(app => (
<SectionRow
key={app.name}
icon="▢"
label={app.name}
href={`${base}/build`}
href={`${base}/build?app=${encodeURIComponent(app.name)}&root=${encodeURIComponent(app.path)}`}
collapsed={collapsed}
/>
))