Skip to content

Comments

feat(blog): complete blog redesign and shared nav/footer components#7544

Open
AmanVarshney01 wants to merge 3 commits intomainfrom
aman/blog-overhaul
Open

feat(blog): complete blog redesign and shared nav/footer components#7544
AmanVarshney01 wants to merge 3 commits intomainfrom
aman/blog-overhaul

Conversation

@AmanVarshney01
Copy link
Member

@AmanVarshney01 AmanVarshney01 commented Feb 21, 2026

What this PR does

1) Rebuilds the blog experience (landing/list/post)

  • Adds the blog UI component system under apps/blog/src/components/blog
  • Reworks blog layout, hero, filters/search, featured card, list rows, compact rows, post header, and post TOC
  • Reworks list/page controller logic in apps/blog/src/components/BlogGrid.tsx
  • Rebuilds blog post page layout with TOC support

2) Adds blog data normalization/filtering utilities

  • Adds apps/blog/src/lib/blog-data.ts with post normalization, type inference, filter, featured, and pagination helpers
  • Extends blog collection schema in apps/blog/source.config.ts with optional taxonomy fields

3) Updates blog styling and shell assets

  • Moves blog styling to the newer Tailwind/token-driven approach in apps/blog/src/app/global.css
  • Updates app layout behavior in apps/blog/src/app/layout.tsx
  • Adds Prisma logo assets used by blog shell in apps/blog/public/img/

4) Extracts reusable website shell components to packages/ui

  • Adds shared components:
    • packages/ui/src/components/prisma-site-nav.tsx
    • packages/ui/src/components/prisma-site-footer.tsx
  • Blog now consumes these shared components via thin wrappers:
    • apps/blog/src/components/blog/blog-nav.tsx
    • apps/blog/src/components/blog/blog-footer.tsx

5) Aligns Eclipse navigation primitives and shared icon usage

  • Adds/exports NavigationMenu* from Eclipse components API
  • Updates Eclipse nav-menu implementation and package dependency wiring
  • Moves/uses shared Discord icon in packages/ui/src/components/discord.tsx and updates docs references

6) Cleanup

  • Removes empty unused apps/blog/src/components/CompaniesUsingPrisma.tsx

@vercel
Copy link

vercel bot commented Feb 21, 2026

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

Project Deployment Actions Updated (UTC)
blog Ready Ready Preview, Comment Feb 21, 2026 11:10pm
docs Ready Ready Preview, Comment Feb 21, 2026 11:10pm

Request Review

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 21, 2026

Walkthrough

This pull request comprehensively refactors the blog app by introducing a centralized data layer for post management, creating fifteen new blog-specific UI components for navigation, post display, and discovery, restructuring blog pages and layouts to use these components, and updating global styling with Tailwind base layers. Related enhancements to shared UI packages and Eclipse components support the new blog structure.

Changes

Cohort / File(s) Summary
Blog Configuration & Data Layer
apps/blog/source.config.ts, apps/blog/src/lib/blog-data.ts
New frontmatter fields added (type, tags, featured). Comprehensive blog data utilities introduced: types (BlogPostType, BlogPostItem), constants (BLOG_TYPE_ORDER, BLOG_TYPE_LABELS), and functions for normalization, filtering, pagination, and featured post selection.
Blog Pages & Layouts
apps/blog/src/app/(blog)/page.tsx, apps/blog/src/app/(blog)/[slug]/page.tsx, apps/blog/src/app/(blog)/layout.tsx, apps/blog/src/app/layout.tsx, apps/blog/src/app/global.css
Main blog page simplified to use getBlogPosts() via new data layer. Post detail page restructured with BlogPostHeader and BlogPostTOC components in two-column layout. Blog layout now renders BlogShell instead of HomeLayout. Root layout extended with dark mode and background styling. Global CSS adds Tailwind base layer for typography and layout defaults.
Blog Shell & Navigation Components
apps/blog/src/components/blog/blog-shell.tsx, apps/blog/src/components/blog/blog-nav.tsx, apps/blog/src/components/blog/blog-footer.tsx, apps/blog/src/components/blog/blog-hero.tsx
New structural components for site wrapper (BlogShell), header navigation (BlogNav), footer (BlogFooter), and blog section hero (BlogHero) using Prisma site primitives.
Blog Post Display Components
apps/blog/src/components/blog/blog-post-header.tsx, apps/blog/src/components/blog/blog-post-toc.tsx, apps/blog/src/components/blog/blog-list-item.tsx, apps/blog/src/components/blog/blog-compact-item.tsx, apps/blog/src/components/blog/blog-featured-card.tsx
Components for rendering post metadata and content: header with author/date/tags, sticky table of contents with scroll tracking, standard and compact post list items, and featured post card with image fallbacks.
Blog Discovery Components
apps/blog/src/components/blog/blog-search.tsx, apps/blog/src/components/blog/blog-filters.tsx, apps/blog/src/components/BlogGrid.tsx
Search input (BlogSearch), type filter buttons (BlogFilters), and comprehensive grid component (BlogGrid) with filtering, searching, pagination, view toggle (cards/compact), featured post handling, and URL parameter synchronization.
Shared UI Components
packages/ui/src/components/prisma-site-nav.tsx, packages/ui/src/components/prisma-site-footer.tsx, packages/ui/src/components/discord.tsx
New PrismaSiteNav with dropdowns for Products/Resources and logo support. New PrismaSiteFooter with multi-column layout and configurable branding. DiscordIcon updated to accept SVGProps for dynamic styling.
Eclipse Navigation Menu
packages/eclipse/src/components/navigation-menu.tsx, packages/eclipse/src/components/index.ts, packages/eclipse/package.json
New Radix UI NavigationMenu wrapper components with consistent styling. Added radix-ui dependency. Exports extended with NavigationMenu primitives and trigger style helper.
Dependencies & Docs Updates
packages/ui/package.json, apps/docs/src/app/(docs)/v6/layout.tsx, apps/docs/src/lib/layout.shared.tsx, apps/docs/src/components/ai-chat-sidebar.tsx
Added eclipse package dependency to UI. Updated DiscordIcon imports to use new UI package location. Minor layout styling adjustments in docs (width constraint, formatting).

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~50 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main objective: moving blog navbar and footer implementations into shared UI components (PrismaSiteNav and PrismaSiteFooter). It clearly summarizes the primary architectural change.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Contributor

🍈 Lychee Link Check Report

3666 links: ✅ 2992 OK | 🚫 8 errors | 🔀 0 redirects | 👻 664 excluded

❌ Errors

./apps/docs/content/docs.v6/(index)/prisma-orm/add-to-existing-project/mongodb.mdx

./apps/docs/content/docs.v6/(index)/prisma-orm/quickstart/mongodb.mdx

./apps/docs/content/docs.v6/guides/vercel-app-deployment.mdx

./apps/docs/content/docs.v6/orm/more/dev-environment/editor-setup.mdx

  • [503] https://fig.io/ | Rejected status code (this depends on your "accept" configuration): Service Unavailable

./apps/docs/content/docs/(index)/prisma-orm/add-to-existing-project/mongodb.mdx

./apps/docs/content/docs/(index)/prisma-orm/quickstart/mongodb.mdx

./apps/docs/content/docs/guides/integrations/vercel-deployment.mdx

./apps/docs/content/docs/orm/more/dev-environment/editor-setup.mdx

  • [503] https://fig.io/ | Rejected status code (this depends on your "accept" configuration): Service Unavailable

Full Statistics Table
Status Count
✅ Successful 2992
🔀 Redirected 0
👻 Excluded 664
🚫 Errors 8
⛔ Unsupported 2
⏳ Timeouts 0
❓ Unknown 0

@AmanVarshney01 AmanVarshney01 changed the title feat(blog): move prisma site nav/footer to shared UI feat(blog): rebuild blog UI and extract shared Prisma site shell Feb 21, 2026
@AmanVarshney01 AmanVarshney01 changed the title feat(blog): rebuild blog UI and extract shared Prisma site shell feat(blog): complete blog redesign and shared nav/footer components Feb 21, 2026
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
apps/blog/src/app/layout.tsx (1)

16-16: ⚠️ Potential issue | 🔴 Critical

Remove undefined LayoutProps<'/> type annotation—it doesn't exist and will cause a compilation error.

LayoutProps is not defined anywhere in the codebase and is not imported. With strict: true enabled in tsconfig, this will fail to compile. Use the standard React pattern instead:

export default function Layout({ children }: { children: React.ReactNode }) {

This affects both apps/blog/src/app/layout.tsx (line 16) and apps/eclipse/src/app/layout.tsx (line 17).

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/app/layout.tsx` at line 16, The function signature export
default function Layout({ children }: LayoutProps<'/'>) uses an undefined type
LayoutProps<'/'>; replace that with the standard React children type by changing
the signature to export default function Layout({ children }: { children:
React.ReactNode }) — remove LayoutProps<'/'> from the Layout function
declaration (the same change should be applied to the other Layout function that
used LayoutProps).
🧹 Nitpick comments (8)
apps/blog/src/components/blog/blog-compact-item.tsx (1)

30-37: Consider extracting getInitials to a shared helper.
This helper is duplicated across multiple blog components, which risks drift over time.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/components/blog/blog-compact-item.tsx` around lines 30 - 37,
The getInitials function is duplicated; extract it into a shared utility (e.g.,
export a function named getInitials from a shared helper module) and replace the
local implementation in BlogCompactItem (function getInitials) with an import
from that shared helper, ensuring the exported helper preserves the exact
behavior (split on whitespace, take up to two parts, uppercase first letters,
fallback to 'PT'); update other blog components to import the same helper so all
usages share one implementation and remove the local duplicates.
apps/blog/src/lib/blog-data.ts (1)

3-10: Type order inconsistency with source.config.ts.

The order here differs from blogPostTypes in apps/blog/source.config.ts:

  • Here: release, user-story, community, tutorial, postgres, changelog
  • There: release, user-story, tutorial, community, postgres, changelog

This could cause confusion if the order is meaningful (e.g., for filter button rendering or priority). Consider extracting a single source of truth, or confirm the ordering difference is intentional.

Also applies to: 16-24

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/lib/blog-data.ts` around lines 3 - 10, The BLOG_TYPE_ORDER
constant in this file has a different ordering than blogPostTypes in
apps/blog/source.config.ts which can cause UI/logic inconsistencies; unify them
by choosing one canonical order and updating the other to match (or extract a
single exported constant used by both), e.g., align BLOG_TYPE_ORDER to match
blogPostTypes or refactor both to import a shared BLOG_TYPES_ORDER array so
functions/components that rely on BLOG_TYPE_ORDER (and blogPostTypes) use the
same source of truth.
apps/blog/source.config.ts (1)

16-23: Type order differs from blog-data.ts.

As noted in apps/blog/src/lib/blog-data.ts, the order here (tutorial before community) differs from BLOG_TYPE_ORDER (community before tutorial). If you want a single source of truth, consider importing from a shared location or aligning the order.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/source.config.ts` around lines 16 - 23, The blogPostTypes array
order conflicts with BLOG_TYPE_ORDER; align them by making blogPostTypes use the
same ordering as BLOG_TYPE_ORDER (put 'community' before 'tutorial') or, better,
export/import a single shared constant so both the blogPostTypes array and
BLOG_TYPE_ORDER reference the same source (update the declaration named
blogPostTypes and remove the duplicated order to prevent future drift).
apps/blog/src/app/(blog)/[slug]/page.tsx (1)

32-32: Consider typing the TOC items instead of as any[].

The as any[] cast on page.data.toc works but loses type safety. If fumadocs provides a TOC item type, consider using it. If not, defining a minimal interface (e.g., { title: string; url: string; depth: number }) would improve maintainability.

Also applies to: 43-46

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/app/`(blog)/[slug]/page.tsx at line 32, Replace the unsafe cast
"as any[]" on page.data.toc used when rendering BlogPostTOC with a proper TOC
item type: either import the TOC type from fumadocs (if available) and use
BlogPostTOC items={page.data.toc as FumaDocsTocItem[]}, or define a minimal
local interface (e.g., TocItem with title, url, depth) and cast to TocItem[];
update all occurrences (the one at BlogPostTOC and the similar usage at lines
43-46) to use that type so the prop signature for BlogPostTOC receives a
strongly typed array instead of any[].
apps/blog/src/app/global.css (1)

8-16: Body styles duplicated in layout.tsx.

The bg-background text-foreground min-h-screen styles are also applied in apps/blog/src/app/layout.tsx line 24. While CSS will handle this gracefully (they're identical), you could consolidate in one location for maintainability—either here in the base layer or in the layout's className.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/app/global.css` around lines 8 - 16, Duplicate application of
body styles: remove the duplication by keeping the shared styles in a single
place—either delete the body-related utilities (bg-background text-foreground
min-h-screen) from apps/blog/src/app/global.css's `@layer` base body rule or
remove them from the className on the root <body> wrapper in layout.tsx; locate
the body selector in global.css and the root element's className in layout.tsx
and ensure only one source defines bg-background, text-foreground, and
min-h-screen for maintainability.
apps/blog/src/app/layout.tsx (1)

20-20: Hardcoded dark mode.

The dark class is hardcoded, which means users cannot toggle to light mode. If dark-mode-only is intentional for the blog, this is fine. Otherwise, consider using a theme provider or system preference detection.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/app/layout.tsx` at line 20, The layout currently hardcodes the
"dark" CSS class in the className string (the template `${inter.variable}
${barlow.variable} dark`), preventing light-mode toggling; remove the literal
"dark" and instead apply the class conditionally using a theme value (e.g., from
a ThemeProvider/next-themes or system-media query) so className becomes
`${inter.variable} ${barlow.variable} ${theme === "dark" ? "dark" : ""}` (or
derived from a provider hook) and wire the provider/hook into the RootLayout
component so users can toggle or respect system preference.
apps/blog/src/components/BlogGrid.tsx (1)

89-105: Counts initialization is coupled to hardcoded type keys.

If BlogPostType is extended with a new type (or one is renamed/removed), this object won't reflect that change, and nextCounts[post.type] += 1 will silently produce NaN for unknown types. Consider deriving this from BLOG_TYPE_ORDER or a similar source of truth.

♻️ Derive counts from BLOG_TYPE_ORDER
+import { BLOG_TYPE_ORDER } from '@/lib/blog-data';

 const counts = useMemo(() => {
-  const nextCounts: Record<BlogPostFilterType, number> = {
-    all: filteredByQuery.length,
-    release: 0,
-    'user-story': 0,
-    community: 0,
-    tutorial: 0,
-    postgres: 0,
-    changelog: 0,
-  };
+  const nextCounts = Object.fromEntries([
+    ['all', filteredByQuery.length],
+    ...BLOG_TYPE_ORDER.map((type) => [type, 0]),
+  ]) as Record<BlogPostFilterType, number>;

   filteredByQuery.forEach((post) => {
     nextCounts[post.type] += 1;
   });

   return nextCounts;
 }, [filteredByQuery]);
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/blog/src/components/BlogGrid.tsx` around lines 89 - 105, counts useMemo
currently initializes nextCounts with hardcoded keys which will break if
BlogPostFilterType changes; instead derive the initial nextCounts from the
canonical BLOG_TYPE_ORDER (or the source-of-truth list) and then increment
safely by checking existence for each post.type. Update the useMemo to build
nextCounts by iterating BLOG_TYPE_ORDER (or Object.values(BlogPostFilterType))
to set zeros, then loop filteredByQuery and do nextCounts[post.type] =
(nextCounts[post.type] ?? 0) + 1 so unknown/renamed types don't produce NaN;
reference the counts/useMemo block, filteredByQuery, post.type, and
BLOG_TYPE_ORDER to locate and change the code.
packages/ui/src/components/prisma-site-nav.tsx (1)

104-107: Hardcoded GitHub star count will become stale.

The "41.8K" stars value is static and will drift from reality over time. Consider fetching this dynamically or accepting it as a prop so consumers can update it without modifying this shared component.

💡 Optional: Accept stars as a prop
 type PrismaSiteNavProps = {
   className?: string;
   activeHref?: string;
   logoHref?: string;
   logoSrc?: string;
   dataTestId?: string;
+  githubStars?: string;
 };

Then use githubStars ?? "41.8K" as the display value.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/ui/src/components/prisma-site-nav.tsx` around lines 104 - 107, The
GitHub star count is hardcoded in the PrismaSiteNav component (the <span>
containing "41.8K") and will become stale; update PrismaSiteNav to accept an
optional prop (e.g., githubStars?: string) and render the span using githubStars
?? "41.8K" so consumers can pass an updated value, or alternatively implement a
dynamic fetch for the repo star count and use that value in the same span as the
fallback.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/ui/src/components/prisma-site-footer.tsx`:
- Around line 44-48: The Blog link in the links array inside the
PrismaSiteFooter component currently points to "/" which will route to the host
root; change the Blog href to the canonical blog URL (e.g.,
"https://www.prisma.io/blog") in the links array in
packages/ui/src/components/prisma-site-footer.tsx (or alternatively add a
prop/default like blogUrl to PrismaSiteFooter to make the blog link
configurable) so the shared footer always points to the Prisma blog rather than
the app root.

In `@packages/ui/src/components/prisma-site-nav.tsx`:
- Around line 61-95: The primary nav in prisma-site-nav.tsx is hidden on mobile
via the "hidden md:flex" nav and needs a mobile drawer toggle; add a hamburger
button (visible on small screens) that toggles the existing Drawer component
(from drawer.tsx) and move or duplicate the Products (TopDropdown/productLinks),
Resources (TopDropdown/resourceLinks) and navLinks mappings into the Drawer
content so mobile users can access them; ensure the same link rendering logic is
reused (respecting isExternal for rel/target, using activeHref for styling) and
wire the button to open/close the Drawer state.

---

Outside diff comments:
In `@apps/blog/src/app/layout.tsx`:
- Line 16: The function signature export default function Layout({ children }:
LayoutProps<'/'>) uses an undefined type LayoutProps<'/'>; replace that with the
standard React children type by changing the signature to export default
function Layout({ children }: { children: React.ReactNode }) — remove
LayoutProps<'/'> from the Layout function declaration (the same change should be
applied to the other Layout function that used LayoutProps).

---

Nitpick comments:
In `@apps/blog/source.config.ts`:
- Around line 16-23: The blogPostTypes array order conflicts with
BLOG_TYPE_ORDER; align them by making blogPostTypes use the same ordering as
BLOG_TYPE_ORDER (put 'community' before 'tutorial') or, better, export/import a
single shared constant so both the blogPostTypes array and BLOG_TYPE_ORDER
reference the same source (update the declaration named blogPostTypes and remove
the duplicated order to prevent future drift).

In `@apps/blog/src/app/`(blog)/[slug]/page.tsx:
- Line 32: Replace the unsafe cast "as any[]" on page.data.toc used when
rendering BlogPostTOC with a proper TOC item type: either import the TOC type
from fumadocs (if available) and use BlogPostTOC items={page.data.toc as
FumaDocsTocItem[]}, or define a minimal local interface (e.g., TocItem with
title, url, depth) and cast to TocItem[]; update all occurrences (the one at
BlogPostTOC and the similar usage at lines 43-46) to use that type so the prop
signature for BlogPostTOC receives a strongly typed array instead of any[].

In `@apps/blog/src/app/global.css`:
- Around line 8-16: Duplicate application of body styles: remove the duplication
by keeping the shared styles in a single place—either delete the body-related
utilities (bg-background text-foreground min-h-screen) from
apps/blog/src/app/global.css's `@layer` base body rule or remove them from the
className on the root <body> wrapper in layout.tsx; locate the body selector in
global.css and the root element's className in layout.tsx and ensure only one
source defines bg-background, text-foreground, and min-h-screen for
maintainability.

In `@apps/blog/src/app/layout.tsx`:
- Line 20: The layout currently hardcodes the "dark" CSS class in the className
string (the template `${inter.variable} ${barlow.variable} dark`), preventing
light-mode toggling; remove the literal "dark" and instead apply the class
conditionally using a theme value (e.g., from a ThemeProvider/next-themes or
system-media query) so className becomes `${inter.variable} ${barlow.variable}
${theme === "dark" ? "dark" : ""}` (or derived from a provider hook) and wire
the provider/hook into the RootLayout component so users can toggle or respect
system preference.

In `@apps/blog/src/components/blog/blog-compact-item.tsx`:
- Around line 30-37: The getInitials function is duplicated; extract it into a
shared utility (e.g., export a function named getInitials from a shared helper
module) and replace the local implementation in BlogCompactItem (function
getInitials) with an import from that shared helper, ensuring the exported
helper preserves the exact behavior (split on whitespace, take up to two parts,
uppercase first letters, fallback to 'PT'); update other blog components to
import the same helper so all usages share one implementation and remove the
local duplicates.

In `@apps/blog/src/components/BlogGrid.tsx`:
- Around line 89-105: counts useMemo currently initializes nextCounts with
hardcoded keys which will break if BlogPostFilterType changes; instead derive
the initial nextCounts from the canonical BLOG_TYPE_ORDER (or the
source-of-truth list) and then increment safely by checking existence for each
post.type. Update the useMemo to build nextCounts by iterating BLOG_TYPE_ORDER
(or Object.values(BlogPostFilterType)) to set zeros, then loop filteredByQuery
and do nextCounts[post.type] = (nextCounts[post.type] ?? 0) + 1 so
unknown/renamed types don't produce NaN; reference the counts/useMemo block,
filteredByQuery, post.type, and BLOG_TYPE_ORDER to locate and change the code.

In `@apps/blog/src/lib/blog-data.ts`:
- Around line 3-10: The BLOG_TYPE_ORDER constant in this file has a different
ordering than blogPostTypes in apps/blog/source.config.ts which can cause
UI/logic inconsistencies; unify them by choosing one canonical order and
updating the other to match (or extract a single exported constant used by
both), e.g., align BLOG_TYPE_ORDER to match blogPostTypes or refactor both to
import a shared BLOG_TYPES_ORDER array so functions/components that rely on
BLOG_TYPE_ORDER (and blogPostTypes) use the same source of truth.

In `@packages/ui/src/components/prisma-site-nav.tsx`:
- Around line 104-107: The GitHub star count is hardcoded in the PrismaSiteNav
component (the <span> containing "41.8K") and will become stale; update
PrismaSiteNav to accept an optional prop (e.g., githubStars?: string) and render
the span using githubStars ?? "41.8K" so consumers can pass an updated value, or
alternatively implement a dynamic fetch for the repo star count and use that
value in the same span as the fallback.

Comment on lines +44 to +48
title: "Company",
links: [
{ label: "About", href: "https://www.prisma.io/about" },
{ label: "Blog", href: "/" },
{ label: "Data DX", href: "https://www.prisma.io/datadx" },
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Fix the Blog link — "/" will be wrong outside the blog app.
As a shared footer, this should point to the Prisma blog directly (or be configurable), otherwise it routes to the host root.

Suggested fix
-      { label: "Blog", href: "/" },
+      { label: "Blog", href: "https://www.prisma.io/blog" },
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
title: "Company",
links: [
{ label: "About", href: "https://www.prisma.io/about" },
{ label: "Blog", href: "/" },
{ label: "Data DX", href: "https://www.prisma.io/datadx" },
title: "Company",
links: [
{ label: "About", href: "https://www.prisma.io/about" },
{ label: "Blog", href: "https://www.prisma.io/blog" },
{ label: "Data DX", href: "https://www.prisma.io/datadx" },
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/ui/src/components/prisma-site-footer.tsx` around lines 44 - 48, The
Blog link in the links array inside the PrismaSiteFooter component currently
points to "/" which will route to the host root; change the Blog href to the
canonical blog URL (e.g., "https://www.prisma.io/blog") in the links array in
packages/ui/src/components/prisma-site-footer.tsx (or alternatively add a
prop/default like blogUrl to PrismaSiteFooter to make the blog link
configurable) so the shared footer always points to the Prisma blog rather than
the app root.

Comment on lines +61 to +95
<nav aria-label="Primary" className="hidden items-center gap-4 md:flex">
<TopDropdown label="Products" links={productLinks} />

{navLinks.slice(0, 1).map((link) => (
<a
key={link.label}
className={cn(
"inline-flex h-8 items-center rounded-md bg-transparent px-1.5 py-1 text-sm font-semibold text-foreground/90 transition-colors hover:text-foreground focus:text-foreground",
activeHref === link.href && "text-foreground",
)}
href={link.href}
rel={isExternal(link.href) ? "noreferrer" : undefined}
target={isExternal(link.href) ? "_blank" : undefined}
>
{link.label}
</a>
))}

<TopDropdown label="Resources" links={resourceLinks} />

{navLinks.slice(1).map((link) => (
<a
key={link.label}
className={cn(
"inline-flex h-8 items-center rounded-md bg-transparent px-1.5 py-1 text-sm font-semibold text-foreground/90 transition-colors hover:text-foreground focus:text-foreground",
activeHref === link.href && "text-foreground",
)}
href={link.href}
rel={isExternal(link.href) ? "noreferrer" : undefined}
target={isExternal(link.href) ? "_blank" : undefined}
>
{link.label}
</a>
))}
</nav>
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check if there's a mobile nav component or hamburger menu elsewhere
rg -n -C3 "hamburger|mobile.*nav|drawer|menu.*toggle" --type=tsx --type=ts packages/ui apps/blog

Repository: prisma/web

Length of output: 81


🏁 Script executed:

#!/bin/bash
# Check if there's a mobile nav component or hamburger menu elsewhere
rg -n -C3 "hamburger|mobile.*nav|drawer|menu.*toggle" packages/ui apps/blog

Repository: prisma/web

Length of output: 50367


🏁 Script executed:

#!/bin/bash
# More targeted search for mobile navigation in packages/ui
rg -n "mobile|hamburger|drawer|sheet|menu.*toggle" packages/ui/src --max-count=20

Repository: prisma/web

Length of output: 2784


🏁 Script executed:

#!/bin/bash
# Read the full prisma-site-nav.tsx file
wc -l packages/ui/src/components/prisma-site-nav.tsx && cat -n packages/ui/src/components/prisma-site-nav.tsx

Repository: prisma/web

Length of output: 7956


Implement mobile navigation for primary links.

The primary navigation is completely hidden on mobile with hidden md:flex, leaving mobile users without access to Products, Pricing, Partners, Resources, and Blog links. Add a hamburger menu or mobile drawer to display these links on screens below the md breakpoint. A drawer component already exists in the codebase (packages/ui/src/components/drawer.tsx) and can be reused here.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/ui/src/components/prisma-site-nav.tsx` around lines 61 - 95, The
primary nav in prisma-site-nav.tsx is hidden on mobile via the "hidden md:flex"
nav and needs a mobile drawer toggle; add a hamburger button (visible on small
screens) that toggles the existing Drawer component (from drawer.tsx) and move
or duplicate the Products (TopDropdown/productLinks), Resources
(TopDropdown/resourceLinks) and navLinks mappings into the Drawer content so
mobile users can access them; ensure the same link rendering logic is reused
(respecting isExternal for rel/target, using activeHref for styling) and wire
the button to open/close the Drawer state.

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