Skip to content

improvement(landing): scope navbar/footer to (shell) route group, align scoped 404s with root#4246

Merged
waleedlatif1 merged 2 commits intostagingfrom
waleedlatif1/moab-v2
Apr 21, 2026
Merged

improvement(landing): scope navbar/footer to (shell) route group, align scoped 404s with root#4246
waleedlatif1 merged 2 commits intostagingfrom
waleedlatif1/moab-v2

Conversation

@waleedlatif1
Copy link
Copy Markdown
Collaborator

@waleedlatif1 waleedlatif1 commented Apr 21, 2026

Summary

  • Move integrations and models page routes into a (shell) route group so the Navbar+Footer layout wraps pages but not not-found.tsx. Route URLs are unchanged — route groups are URL-transparent.
  • Extract a shared <NotFoundView> component (Navbar + <AuthBackground> + centered "Page not found" + return-home link) used by the root app/not-found.tsx and the scoped (landing)/integrations/not-found.tsx and (landing)/models/not-found.tsx.
  • Net effect: /models/foo/bar/baz and /integrations/xyz now render the same 404 treatment as /rand (root). Previously they sat inside the landing CTA footer with no decorative background.

Why

Before this, scoped 404s rendered through IntegrationsLayout / ModelsLayout, which include the landing <Footer> ("What should we get done?" CTA). That made invalid routes under /integrations/* and /models/* look visually inconsistent with /rand and any other top-level 404.

The Next.js-idiomatic fix is to scope the Navbar+Footer shell to the actual pages via a (shell) route group, leaving not-found.tsx to render under just the minimal (landing)/layout.tsx — free to wrap itself in the same <AuthBackground> + Navbar treatment as the root.

Test plan

  • Visit /integrations/xyz-not-real and /models/anthropic/not-real — expect the same look as /rand (Navbar + grid background + centered "Page not found" + Return to Home, no footer)
  • Visit /integrations, /integrations/[valid-slug], /models, /models/[provider], /models/[provider]/[model] — expect Navbar + Footer shell still present, content unchanged
  • Verify URLs are unchanged (route groups are URL-transparent)
  • Verify og-images still resolve at /models/opengraph-image, /models/[provider]/opengraph-image, /models/[provider]/[model]/opengraph-image

…p, align scoped 404s with root

Move integrations and models page routes into a `(shell)` route group so the Navbar+Footer layout wraps pages but not `not-found.tsx`. This lets scoped 404s render the same `<AuthBackground>` + Navbar treatment as the root `/` 404, instead of appearing inside the landing CTA footer.

Extract the shared 404 markup into `<NotFoundView>` so root, integrations, and models 404s share a single source of truth. Route URLs are unchanged — route groups are URL-transparent.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 21, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
docs Skipped Skipped Apr 21, 2026 8:46pm

Request Review

@cursor
Copy link
Copy Markdown

cursor Bot commented Apr 21, 2026

PR Summary

Medium Risk
Medium risk because it restructures Next.js App Router route groups/layout boundaries for /integrations and /models, which can subtly affect rendering, metadata, and 404 handling despite unchanged URLs.

Overview
Extracts a shared async NotFoundView (with AuthBackground + Navbar and a return-home CTA) and switches the root, /integrations, and /models not-found.tsx handlers to reuse it for consistent full-viewport 404 styling.

Moves the integrations index/detail pages under an (shell) route group and updates imports accordingly, so the Navbar/Footer shell applies to normal pages while scoped 404s render outside that shell (matching the root 404 treatment).

Reviewed by Cursor Bugbot for commit 4bbf211. Configure here.

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Apr 21, 2026

Greptile Summary

This PR restructures the landing-surface routing by moving /integrations and /models pages into a (shell) route group so the Navbar+Footer layout applies only to valid pages, while scoped not-found.tsx files remain outside (shell) and therefore render the root 404 treatment. A new shared NotFoundView server component consolidates the duplicated 404 markup (Navbar + AuthBackground + centered message) across the root, integrations, and models 404 pages. All import paths in moved files are correctly updated to absolute @/ aliases.

Confidence Score: 5/5

Safe to merge — structural rename with no logic changes, correct import path updates, and clean deduplication.

All changed files are either pure renames (100% similarity) or trivial delegations to the new NotFoundView component. Import paths are correctly updated to @/ aliases after the move. No P0/P1 findings exist.

No files require special attention.

Important Files Changed

Filename Overview
apps/sim/app/(landing)/components/not-found-view.tsx New shared async server component that consolidates the full 404 UI (Navbar + AuthBackground + centered message) previously duplicated across root and scoped not-found files.
apps/sim/app/not-found.tsx Root 404 page simplified from async to sync component delegating entirely to NotFoundView; metadata and robots directives preserved.
apps/sim/app/(landing)/integrations/(shell)/layout.tsx Renamed from integrations/layout.tsx into (shell) route group; no content changes — Navbar+Footer shell now correctly excludes the sibling not-found.tsx.
apps/sim/app/(landing)/integrations/(shell)/page.tsx Moved into (shell); relative imports correctly converted to absolute @/ aliases since shared components/data remain in the parent integrations/ directory.
apps/sim/app/(landing)/integrations/not-found.tsx Replaced inline 404 markup with NotFoundView; now renders with Navbar + AuthBackground instead of the landing footer shell.
apps/sim/app/(landing)/models/not-found.tsx Same as integrations not-found: replaced inline markup with NotFoundView for consistent 404 treatment.
apps/sim/app/(landing)/integrations/(shell)/[slug]/page.tsx Moved into (shell)/[slug]/; intra-group component imports updated to include the (shell) path segment, which is correct since those component files also moved.
apps/sim/app/(landing)/models/(shell)/layout.tsx Renamed from models/layout.tsx into (shell) route group; no content changes — same scoping benefit as integrations.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A["(landing)/layout.tsx\nminimal wrapper"] --> B["integrations/"]
    A --> C["models/"]

    B --> B1["(shell)/layout.tsx\nNavbar + Footer"]
    B --> B2["not-found.tsx\nNotFoundView"]

    B1 --> B3["(shell)/page.tsx\n/integrations"]
    B1 --> B4["(shell)/[slug]/page.tsx\n/integrations/:slug"]

    C --> C1["(shell)/layout.tsx\nNavbar + Footer"]
    C --> C2["not-found.tsx\nNotFoundView"]

    C1 --> C3["(shell)/page.tsx\n/models"]
    C1 --> C4["(shell)/[provider]/page.tsx\n/models/:provider"]
    C1 --> C5["(shell)/[provider]/[model]/page.tsx\n/models/:p/:m"]

    NF["app/not-found.tsx\nNotFoundView"] --> NFC["NotFoundView\nNavbar + AuthBackground\nno Footer"]
    B2 --> NFC
    C2 --> NFC

    style NFC fill:#1a1a2e,color:#fff
    style B2 fill:#162032,color:#fff
    style C2 fill:#162032,color:#fff
    style NF fill:#162032,color:#fff
Loading

Reviews (2): Last reviewed commit: "fix(landing): convert relative imports t..." | Re-trigger Greptile

…hell) page

Build failed because the move into the (shell) route group invalidated relative `./components/...` and `./data/...` imports. CLAUDE.md mandates absolute imports throughout — switching these resolves the Turbopack build errors.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@waleedlatif1
Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1
Copy link
Copy Markdown
Collaborator Author

@cursor review

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 4bbf211. Configure here.

@waleedlatif1 waleedlatif1 merged commit d185953 into staging Apr 21, 2026
14 checks passed
@waleedlatif1 waleedlatif1 deleted the waleedlatif1/moab-v2 branch April 21, 2026 21:03
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