Skip to content

[docs][dashboard][stack-shared] Update docs to new apps #996

Merged
madster456 merged 16 commits intodevfrom
docs/apps-section
Nov 12, 2025
Merged

[docs][dashboard][stack-shared] Update docs to new apps #996
madster456 merged 16 commits intodevfrom
docs/apps-section

Conversation

@madster456
Copy link
Collaborator

@madster456 madster456 commented Nov 3, 2025

image image

Summary by CodeRabbit

  • Documentation

    • New "Apps" section with dedicated pages for API Keys, Emails, OAuth, Permissions (RBAC), Orgs & Teams, Auth Providers, and Webhooks; API Keys content moved into this section.
    • New API Keys guide and updated overview content including an Apps grid and app tiles.
    • Added redirects from old concept pages to new Apps pages.
  • Style

    • Sidebar now shows icons for docs links; improved hover animations and tile styling across docs.
  • New Features

    • App tile/card components added for displaying apps in docs.

Note

Introduces a new “Apps” docs section (API Keys, Emails, OAuth, RBAC, Orgs & Teams, Webhooks), adds reusable app UI components, updates navigation, and removes the old API Keys concept doc.

  • Docs:
    • Apps section: Add docs/content/docs/(guides)/apps/* (API Keys, Emails, OAuth, RBAC Permissions, Orgs & Teams, Webhooks) with icons and examples; remove concepts/api-keys.mdx and update related links (e.g., JWT).
    • Overview & Nav: Insert AppGrid on overview, add “Apps” pages to meta.json, add “Welcome” nav item, and refine “Guides” active-state logic.
    • Code examples: Wire docs/code-examples/index.ts to load apps/api-keys examples.
  • UI/Components:
    • Add AppCard/AppGrid in docs/src/components/mdx/app-card.tsx and register in mdx-components.
    • Tweak homepage hover card styles (iconHover.tsx) and sidebar links to support icons.
  • Shared:
    • Add packages/stack-shared/src/apps/apps-ui.tsx with AppIcon and sizing constants; note UI export guidance in stack-shared index.ts.
  • Styling/Infra:
    • Add Tailwind @source in global CSS; minor layout/link icon plumbing.

Written by Cursor Bugbot for commit 2487b87. This will update automatically on new commits. Configure here.

@vercel
Copy link

vercel bot commented Nov 3, 2025

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

Project Deployment Preview Comments Updated (UTC)
stack-backend Ready Ready Preview Comment Nov 12, 2025 9:19pm
stack-dashboard Ready Ready Preview Comment Nov 12, 2025 9:19pm
stack-demo Ready Ready Preview Comment Nov 12, 2025 9:19pm
stack-docs Ready Ready Preview Comment Nov 12, 2025 9:19pm

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 3, 2025

Walkthrough

Replaces dashboard-local app icon rendering with a SharedAppIcon from stack-shared, adds a new AppIcon and sizing constants in packages/stack-shared, moves API Keys docs from concepts to an apps section (new examples and MDX), adds AppCard/AppGrid MDX components and navigation/icon metadata, and adds redirects from moved concept pages to apps paths.

Changes

Cohort / File(s) Summary
Shared App Icon & sizing
packages/stack-shared/src/apps/apps-ui.tsx, packages/stack-shared/src/index.ts
New AppIcon (SharedAppIcon) component, AppIconProps type, and exported sizing expressions appSquareWidthExpression and appSquarePaddingExpression; added explanatory comments to index.
Dashboard AppSquare refactor
apps/dashboard/src/components/app-square.tsx
Replaced inline SVG/gradient/stage decoration logic by delegating rendering to SharedAppIcon; imports sizing expressions from stack-shared.
API Keys docs & examples
docs/content/docs/(guides)/apps/api-keys.mdx, docs/code-examples/api-keys.ts, docs/code-examples/index.ts, docs/content/docs/(guides)/concepts/api-keys.mdx
Added new apps/api-keys guide and a large data file apiKeysExamples; removed legacy concepts API Keys page content; wired examples into index.
Docs MDX components & app tiles
docs/src/components/mdx/app-card.tsx, docs/src/mdx-components.tsx
New AppCard and AppGrid components (registered for MDX) with APP_ICONS mapping and URL overrides; MDX registry updated to include AppCard/AppGrid/DocsSelector.
Documentation navigation & overview
docs/src/lib/navigation-utils.ts, docs/src/components/layouts/docs.tsx, docs/src/components/layouts/shared-header.tsx, docs/content/docs/(guides)/meta.json, docs/content/docs/(guides)/overview.mdx
Added Welcome nav link (Home icon), supported icon prop on sidebar links, updated active-state rules, added "Apps" section to guides meta and rendered AppGrid on overview.
Docs metadata & frontmatter tweaks
docs/content/docs/(guides)/apps/{emails,oauth,orgs-and-teams,permissions,webhooks}.mdx, docs/content/docs/(guides)/concepts/auth-providers/{index.mdx,meta.json}, docs/content/docs/(guides)/permissions.mdx
Added icon frontmatter to multiple pages; renamed Permissions title to "RBAC Permissions".
Redirects for moved pages
docs/src/middleware.ts
Added redirect logic: requests under /docs/concepts/{page} for listed pages now issue 301 to /docs/apps/{page} before existing middleware handling.
Homepage & styles refinements
docs/src/components/homepage/iconHover.tsx, docs/src/app/global.css
Adjusted hover animations, sizing, truncation; added @source directive referencing stack-shared.

Sequence Diagram(s)

sequenceDiagram
    participant User as User
    participant Overview as Docs Overview
    participant NavUtils as Navigation Utils
    participant Sidebar as DocsSidebarLink
    participant AppGrid as AppGrid/AppCard
    participant SharedIcon as SharedAppIcon (stack-shared)
    User->>Overview: GET /docs/overview
    Overview->>NavUtils: build navigation
    NavUtils-->>Sidebar: include Welcome (Home icon)
    Overview->>AppGrid: render AppGrid
    AppGrid->>AppCard: create tile for appId
    AppCard->>SharedIcon: request icon (IconComponent/LogoComponent)
    SharedIcon-->>AppCard: rendered SVG or LogoComponent
    AppCard-->>User: clickable tile shown
    User->>Sidebar: click Welcome or app link
    Sidebar-->>User: navigate (active state reflects overview)
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

  • Attention areas:
    • Gradient/stroke and stage-badge logic in packages/stack-shared/src/apps/apps-ui.tsx.
    • Dashboard AppSquare integration with the new SharedAppIcon and imported sizing expressions.
    • MDX registration and AppCard URL resolution in docs/src/components/mdx/app-card.tsx.
    • Middleware redirect list correctness to avoid accidental redirects.
    • Sidebar/active-state logic changes to ensure correct highlighting for Overview/Guides.

Possibly related PRs

Suggested reviewers

  • N2D4

Poem

🐰 Hoppity-hop, the apps take flight,

Icons shared and docs made bright,
Tiles that sparkle, links that steer,
Redirects guide the reader near,
A rabbit cheers—this change feels right! 🥕

Pre-merge checks and finishing touches

❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
Title check ❓ Inconclusive The title '[docs][dashboard][stack-shared] Update docs to new apps' is vague and generic, using a non-descriptive term 'Update docs to new apps' that doesn't clearly convey the primary change or scope of the changeset. Revise the title to be more specific and descriptive, such as 'Introduce new Apps documentation section with AppIcon components and navigation updates' to better communicate the main change.
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The PR description is comprehensive and well-structured, containing detailed sections for Docs, UI/Components, Shared, and Styling/Infra changes with clear explanations of what was added, removed, and modified.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch docs/apps-section

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

Greptile Overview

Greptile Summary

This PR refactors app icon rendering logic into a shared component (AppIcon in stack-shared) and creates new documentation for Stack Auth's app ecosystem. The main changes include:

  • Code Reuse: Extracted AppIcon component from dashboard to packages/stack-shared/src/apps/apps-ui.tsx, eliminating ~70 lines of duplicated code
  • Documentation Enhancement: Added comprehensive app documentation under docs/content/docs/(guides)/apps/ with new API Keys guide
  • Navigation Updates: Restructured docs navigation to include a dedicated "Apps" section
  • New Components: Created AppCard and AppGrid MDX components for displaying app icons in documentation
  • UI Polish: Minor CSS improvements to homepage icon hover component

The refactoring follows good software engineering practices by centralizing shared UI logic while maintaining consistent styling across dashboard and documentation.

Confidence Score: 5/5

  • This PR is safe to merge with no identified issues
  • This is a well-executed refactoring and documentation enhancement PR. The code extracts shared UI logic into a reusable component, reducing duplication. All icon mappings are complete and type-safe, documentation follows existing patterns, and no security concerns were identified. The changes are primarily additive (new docs) and refactoring (shared components) with no breaking changes or risky logic modifications.
  • No files require special attention

Important Files Changed

File Analysis

Filename Score Overview
packages/stack-shared/src/apps/apps-ui.tsx 5/5 New shared UI component for rendering app icons with gradients and badges, extracted from dashboard for reuse in docs
apps/dashboard/src/components/app-square.tsx 5/5 Refactored to use shared AppIcon component from stack-shared, reducing code duplication by ~70 lines
docs/src/components/mdx/app-card.tsx 5/5 New docs component using shared AppIcon for displaying app cards with icons and links in documentation
docs/content/docs/(guides)/apps/api-keys.mdx 5/5 New comprehensive API Keys app documentation with examples and UI component references
docs/content/docs/(guides)/meta.json 5/5 Added new Apps section to navigation with links to individual app documentation pages

Sequence Diagram

sequenceDiagram
    participant Docs as Docs (MDX)
    participant AppCard as AppCard Component
    participant SharedAppIcon as AppIcon (stack-shared)
    participant Dashboard as Dashboard AppSquare
    
    Note over Docs,Dashboard: Component Refactoring Flow
    
    Docs->>AppCard: Render <AppGrid appIds={[...]} />
    AppCard->>AppCard: Map appIds to AppCard components
    AppCard->>AppCard: Get IconComponent from APP_ICONS mapping
    AppCard->>SharedAppIcon: Render AppIcon with props
    SharedAppIcon->>SharedAppIcon: Render gradient SVG definitions
    SharedAppIcon->>SharedAppIcon: Apply gradient based on app.tags
    SharedAppIcon->>SharedAppIcon: Render stage badge if not stable
    SharedAppIcon-->>AppCard: Return rendered icon
    AppCard-->>Docs: Display app grid with icons
    
    Dashboard->>Dashboard: Render AppSquare component
    Dashboard->>SharedAppIcon: Use shared AppIcon component
    SharedAppIcon->>SharedAppIcon: Apply same gradient logic
    SharedAppIcon-->>Dashboard: Return rendered icon
    
    Note over SharedAppIcon: Shared logic eliminates ~70 lines of duplication
Loading

25 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

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: 3

Caution

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

⚠️ Outside diff range comments (1)
docs/src/lib/navigation-utils.ts (1)

9-26: Fix incorrect path: Guides should use /docs/guides, not /docs/overview.

Both DOCS_OVERVIEW_PATH (line 9) and DOCS_GUIDES_PATH (line 10) are set to '/docs/overview'. The guides content is located at docs/content/docs/(guides)/overview.mdx, which in Fumadocs routes to /docs/guides. To match the filesystem structure and maintain consistency with other paths (e.g., DOCS_SDK_PATH = '/docs/sdk' for docs/content/docs/sdk/), update line 10 to:

const DOCS_GUIDES_PATH = '/docs/guides';

This same issue also appears in docs/src/components/homepage/iconHover.tsx line 25 and should be corrected there as well.

🧹 Nitpick comments (3)
docs/code-examples/api-keys.ts (1)

75-104: Document placeholder variables in Python examples.

The Python examples reference undefined variables like stack_project_id, stack_publishable_client_key, and stack_secret_server_key (lines 87-88) without defining them. While this is likely intentional to keep examples concise, it could confuse users copying the code.

Consider adding a comment at the top of Python examples or showing how to load these from environment variables:

 def create_user_api_key(request):
+    # Configure Stack Auth credentials from environment
+    stack_project_id = os.getenv('STACK_PROJECT_ID')
+    stack_publishable_client_key = os.getenv('STACK_PUBLISHABLE_CLIENT_KEY')
+    stack_secret_server_key = os.getenv('STACK_SECRET_SERVER_KEY')
+    
     # Get the current user's access token from session/cookie
     access_token = request.COOKIES.get('stack-access-token')

Note: This same issue appears throughout all Python examples in this file (Django, Flask, FastAPI variants).

docs/src/components/mdx/app-card.tsx (1)

42-61: Minor: createSvgIcon return type could be more specific.

The createSvgIcon function returns (props: React.SVGProps<SVGSVGElement>) => React.ReactNode but React functional components should return React.ReactElement | null for better type safety.

Consider updating the return type:

-function createSvgIcon(ChildrenComponent: () => React.ReactNode): (props: React.SVGProps<SVGSVGElement>) => React.ReactNode {
-  const Result = (props: React.SVGProps<SVGSVGElement>) => (
+function createSvgIcon(ChildrenComponent: () => React.ReactNode): React.FunctionComponent<React.SVGProps<SVGSVGElement>> {
+  const Result: React.FunctionComponent<React.SVGProps<SVGSVGElement>> = (props) => (
     <svg

This aligns with the type used in APP_ICONS mapping (line 16: React.FunctionComponent<React.SVGProps<SVGSVGElement>>).

packages/stack-shared/src/apps/apps-ui.tsx (1)

7-24: Consider making the cn prop optional with a default.

The AppIconProps type requires consumers to always provide a cn utility function (line 23). This creates coupling and makes the component less reusable in contexts where a cn utility might not be available or needed.

Consider making it optional with a default implementation:

 export type AppIconProps = {
   appId: AppId,
   IconComponent: React.FunctionComponent<React.SVGProps<SVGSVGElement>>,
   LogoComponent?: React.FunctionComponent<{}>,
   className?: string,
   disabled?: boolean,
   style?: React.CSSProperties,
-  cn: (...inputs: any[]) => string,
+  cn?: (...inputs: any[]) => string,
 };

Then in the component:

export function AppIcon({
  appId,
  IconComponent,
  LogoComponent,
  className,
  disabled,
  style,
  cn = (...inputs) => inputs.filter(Boolean).join(' '),
}: AppIconProps) {
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3538638 and b6a11c0.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (25)
  • apps/dashboard/src/components/app-square.tsx (1 hunks)
  • docs/code-examples/api-keys.ts (1 hunks)
  • docs/code-examples/index.ts (1 hunks)
  • docs/content/docs/(guides)/apps/api-keys.mdx (1 hunks)
  • docs/content/docs/(guides)/apps/emails.mdx (1 hunks)
  • docs/content/docs/(guides)/apps/oauth.mdx (1 hunks)
  • docs/content/docs/(guides)/apps/orgs-and-teams.mdx (1 hunks)
  • docs/content/docs/(guides)/apps/permissions.mdx (1 hunks)
  • docs/content/docs/(guides)/apps/webhooks.mdx (1 hunks)
  • docs/content/docs/(guides)/concepts/api-keys.mdx (0 hunks)
  • docs/content/docs/(guides)/concepts/auth-providers/index.mdx (1 hunks)
  • docs/content/docs/(guides)/concepts/auth-providers/meta.json (1 hunks)
  • docs/content/docs/(guides)/meta.json (1 hunks)
  • docs/content/docs/(guides)/overview.mdx (1 hunks)
  • docs/src/app/global.css (1 hunks)
  • docs/src/components/homepage/iconHover.tsx (2 hunks)
  • docs/src/components/layouts/docs.tsx (3 hunks)
  • docs/src/components/layouts/page.tsx (1 hunks)
  • docs/src/components/layouts/shared-header.tsx (2 hunks)
  • docs/src/components/mdx/app-card.tsx (1 hunks)
  • docs/src/lib/navigation-utils.ts (1 hunks)
  • docs/src/mdx-components.tsx (2 hunks)
  • docs/tailwind.config.ts (1 hunks)
  • packages/stack-shared/src/apps/apps-ui.tsx (1 hunks)
  • packages/stack-shared/src/index.ts (1 hunks)
💤 Files with no reviewable changes (1)
  • docs/content/docs/(guides)/concepts/api-keys.mdx
🧰 Additional context used
🧬 Code graph analysis (5)
docs/src/components/mdx/app-card.tsx (2)
packages/stack-shared/src/apps/apps-config.ts (2)
  • AppId (48-48)
  • ALL_APPS (50-141)
packages/stack-shared/src/apps/apps-ui.tsx (3)
  • appSquarePaddingExpression (5-5)
  • AppIcon (26-117)
  • appSquareWidthExpression (4-4)
packages/stack-shared/src/apps/apps-ui.tsx (3)
apps/dashboard/src/components/app-square.tsx (1)
  • AppIcon (11-30)
packages/stack-shared/src/apps/apps-config.ts (2)
  • AppId (48-48)
  • ALL_APPS (50-141)
packages/stack-shared/src/utils/arrays.tsx (1)
  • typedIncludes (3-5)
docs/code-examples/index.ts (2)
docs/lib/code-examples.ts (1)
  • CodeExample (15-22)
docs/code-examples/api-keys.ts (1)
  • apiKeysExamples (3-1351)
docs/code-examples/api-keys.ts (1)
docs/lib/code-examples.ts (1)
  • CodeExample (15-22)
apps/dashboard/src/components/app-square.tsx (3)
packages/stack-shared/src/apps/apps-ui.tsx (1)
  • AppIcon (26-117)
packages/stack-shared/src/apps/apps-config.ts (1)
  • AppId (48-48)
apps/dashboard/src/lib/apps-frontend.tsx (1)
  • AppFrontend (27-36)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (12)
  • GitHub Check: all-good
  • GitHub Check: Vercel Agent Review
  • GitHub Check: docker
  • GitHub Check: restart-dev-and-test
  • GitHub Check: build (22.x)
  • GitHub Check: check_prisma_migrations (22.x)
  • GitHub Check: setup-tests
  • GitHub Check: restart-dev-and-test-with-custom-base-port
  • GitHub Check: build (22.x)
  • GitHub Check: lint_and_build (latest)
  • GitHub Check: build (22.x)
  • GitHub Check: Security Check
🔇 Additional comments (25)
docs/src/components/layouts/page.tsx (1)

3-4: LGTM! Import path update aligns with fumadocs module structure.

The migration from fumadocs-core/server to fumadocs-core/toc is a clean refactor that updates the import source for table-of-contents types and providers.

docs/src/components/layouts/shared-header.tsx (2)

53-55: LGTM! Welcome navigation active state correctly implemented.

The new condition ensures the Welcome link is highlighted on the overview page.


66-66: LGTM! Guides exclusion prevents navigation conflicts.

The updated condition correctly excludes /docs/overview to prevent simultaneous activation of both Welcome and Guides links.

docs/src/components/homepage/iconHover.tsx (1)

91-131: LGTM! Hover transition polish improves UX.

The styling refinements add smooth transitions and improve visual feedback. Changes include explicit transition-transform, adjusted icon sizing, and tighter spacing for a more polished hover experience.

docs/content/docs/(guides)/apps/emails.mdx (1)

4-4: LGTM! Icon metadata addition.

The Mail icon metadata aligns with the PR's standardized icon-driven documentation approach.

docs/content/docs/(guides)/apps/oauth.mdx (1)

4-4: LGTM! Icon metadata addition.

The Shield icon metadata aligns with the PR's standardized icon-driven documentation approach.

docs/code-examples/index.ts (1)

2-7: LGTM! API keys examples integration follows established pattern.

The new apps section and apiKeysExamples import integrate cleanly with the existing example organization structure.

docs/content/docs/(guides)/concepts/auth-providers/meta.json (1)

3-3: LGTM! Icon metadata addition.

The Plug icon metadata aligns with the PR's standardized icon-driven documentation approach.

docs/content/docs/(guides)/concepts/auth-providers/index.mdx (1)

3-3: Verify the icon name is recognized by the system.

Ensure that "Plug" is a valid icon name that's defined in your icon registry.

Since this is part of the same icon metadata pattern, the previous verification script for the icon registry will also validate this icon name.

docs/content/docs/(guides)/apps/orgs-and-teams.mdx (1)

4-4: Icon metadata addition looks good.

The "UsersRound" icon name is appropriate for the Orgs and Teams page. Ensure it's defined in the icon registry (covered by the verification script in the webhooks.mdx review).

docs/src/mdx-components.tsx (3)

97-100: Component registration looks correct.

The new MDX components (AppCard, AppGrid, DocsSelector) are properly registered in the getMDXComponents function, making them available for use in MDX files.


33-33: AppCard and AppGrid components are properly implemented and exported.

Verification confirms that both AppCard (line 66) and AppGrid (line 107) are correctly exported from docs/src/components/mdx/app-card.tsx. The import statement in docs/src/mdx-components.tsx is valid and will resolve without issues.


32-32: The import path is correct and verified.

The verification confirms that DocsSelector is properly exported as a default export (line 142) from docs/src/components/homepage/iconHover.tsx. The import path is accurate, and there are no typos or broken references. While the filename and component name use different conventions, this is a valid styling choice and presents no functional issues.

packages/stack-shared/src/index.ts (1)

1-3: No issues found—all exports from apps-ui module are verified.

The verification confirms that packages/stack-shared/src/apps/apps-ui.tsx exists and properly exports all four items (AppIcon, appSquarePaddingExpression, appSquareWidthExpression, and AppIconProps). The exports are explicit and intentional, making them suitable for public API inclusion.

docs/content/docs/(guides)/apps/permissions.mdx (1)

2-3: No issues found with title change and icon addition.

The file path remains unchanged (apps/permissions.mdx), so all existing links and routing references continue to work. Search results show no hardcoded references to the old page title that would break, and the updated title is used for display purposes only.

docs/src/app/global.css (1)

2-3: @source directive is properly configured.

Verification confirms:

  • Path ../../../packages/stack-shared/src correctly resolves from docs/src/app/global.css to the stack-shared package source directory
  • Tailwind CSS v4.1.7 (installed in docs) supports the @source directive for including external source paths
  • The stack-shared package source directory exists with proper TypeScript/component files

The @source directive placement in global.css is correct and follows Tailwind v4 conventions.

docs/content/docs/(guides)/apps/api-keys.mdx (1)

1-150: LGTM! Comprehensive API Keys documentation.

The documentation is well-structured with:

  • Clear overview with a Mermaid sequence diagram
  • Separate sections for User and Team API keys
  • Step-by-step enablement instructions
  • Prebuilt UI component documentation
  • Working with API keys (CRUD operations)
  • Authentication validation examples
  • Best practices

The consistent use of PlatformCodeblock components with the document="apps/api-keys" property ensures code examples are properly sourced from the centralized examples file.

docs/src/components/layouts/docs.tsx (2)

125-152: LGTM! Clean icon support for sidebar links.

The addition of the optional icon prop to DocsSidebarLink is well-implemented:

  • Properly typed as icon?: ReactNode (line 134)
  • Conditionally rendered with appropriate styling (line 149)
  • Icon size constraint using [&_svg]:size-3.5 ensures consistency

311-311: LGTM! Icon properly propagated from page tree.

The PageTreeItem correctly passes item.icon to DocsSidebarLink, completing the icon rendering pipeline from page metadata to UI.

apps/dashboard/src/components/app-square.tsx (1)

11-30: LGTM! Clean refactoring to shared component.

The refactoring successfully delegates app icon rendering to SharedAppIcon from the shared package. This:

  • Eliminates code duplication
  • Ensures consistent icon rendering across dashboard and docs
  • Maintains the same public API for AppIcon
  • Properly passes through all required props including cn utility

The re-export of layout constants (line 9) maintains backward compatibility for any existing imports.

docs/src/components/mdx/app-card.tsx (2)

66-102: LGTM! Well-structured AppCard component.

The AppCard component is cleanly implemented with:

  • Proper URL resolution through overrides and defaults
  • Consistent styling using shared layout expressions
  • Proper icon rendering with AppIcon from shared package
  • Good responsive design with truncation for long app names

107-118: LGTM! Simple and effective AppGrid component.

The AppGrid component provides a clean wrapper for displaying multiple app cards with proper responsive gap spacing.

packages/stack-shared/src/apps/apps-ui.tsx (2)

4-5: LGTM! Well-defined layout constants.

The responsive CSS calc expressions provide appropriate min/max bounds for app icon sizing across different viewport sizes.


26-117: LGTM! Robust icon rendering with proper gradient support.

The AppIcon component is well-implemented with:

  • Unique gradient IDs to avoid conflicts
  • Proper conditional rendering for LogoComponent vs IconComponent
  • Tag-based gradient selection (expert, integration, default)
  • Correct stage badge positioning and styling
  • Appropriate disabled state handling
docs/content/docs/(guides)/meta.json (1)

14-35: The review comment is incorrect—no actual duplication exists in the file system.

The review comment assumes that references in meta.json to pages like concepts/api-keys, concepts/emails, concepts/oauth, etc., correspond to actual .mdx files in the concepts directory. However, the file listing shows these concept pages do not exist:

  • docs/content/docs/(guides)/concepts/api-keys.mdxdoes not exist
  • docs/content/docs/(guides)/concepts/emails.mdxdoes not exist
  • docs/content/docs/(guides)/concepts/oauth.mdxdoes not exist
  • docs/content/docs/(guides)/concepts/orgs-and-teams.mdxdoes not exist
  • docs/content/docs/(guides)/concepts/permissions.mdxdoes not exist
  • docs/content/docs/(guides)/concepts/webhooks.mdxdoes not exist

The concepts directory contains only these files: backend-integration.mdx, custom-user-data.mdx, jwt.mdx, stack-app.mdx, team-selection.mdx, user-onboarding.mdx, plus an auth-providers/ subdirectory.

The meta.json file may reference these paths as navigation structure, but there is no content duplication to maintain or consolidate. The review comment conflated text references in a configuration file with actual file duplicates.

Likely an incorrect or invalid review comment.

Copy link

@vercel vercel bot left a comment

Choose a reason for hiding this comment

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

Additional Suggestion:

The meta.json file references documentation files that have been moved or deleted (e.g., concepts/api-keys, concepts/emails, concepts/oauth, etc.), but these files no longer exist at those paths - they've been moved to the apps/ directory or deleted entirely.

View Details
📝 Patch Details
diff --git a/docs/content/docs/(guides)/meta.json b/docs/content/docs/(guides)/meta.json
index 1d0f481a..623bed5f 100644
--- a/docs/content/docs/(guides)/meta.json
+++ b/docs/content/docs/(guides)/meta.json
@@ -20,19 +20,13 @@
     "apps/permissions",
     "apps/webhooks",
     "---Concepts---",
-    "concepts/api-keys",
     "concepts/backend-integration",
     "concepts/custom-user-data",
-    "concepts/emails",
     "concepts/jwt",
-    "concepts/oauth",
     "concepts/auth-providers",
-    "concepts/orgs-and-teams",
-    "concepts/permissions",
     "concepts/stack-app",
     "concepts/team-selection",
     "concepts/user-onboarding",
-    "concepts/webhooks",
     "---Customization---",
     "customization/custom-pages",
     "customization/custom-styles",

Analysis

Broken navigation references in docs meta.json cause duplicate/dead links

What fails: Documentation navigation in docs/content/docs/(guides)/meta.json references non-existent files in concepts/ directory, creating broken navigation links alongside working duplicates in apps/ section

How to reproduce:

  1. Check navigation for concepts section in documentation
  2. Files concepts/api-keys, concepts/emails, concepts/oauth, concepts/orgs-and-teams, concepts/permissions, and concepts/webhooks don't exist
  3. Navigation shows broken links for these missing files

Result: Documentation navigation displays broken links for 6 concept files that were moved to the apps/ directory but old references remained

Expected: Navigation should only reference existing files - these 6 files should be removed from the concepts section since they now exist in the apps section

Fixed: Removed the 6 broken file references from meta.json concepts section, keeping only the working versions in the apps section

Copy link
Contributor

@N2D4 N2D4 left a comment

Choose a reason for hiding this comment

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

looks good!

can we have the following follow-up PR: Instead of apps-ui.tsx, can we move apps-square entirely over to stack-shared, and the same for apps-frontend.tsx? Then, we can share the same logic for dashboard and docs. then, could you make it so that the list of apps that have docs is somewhere central? optimally we only have to add new docs for an app in two places — the mdx file and then this central place to add new apps. later, once we've documented every app, we should make it so that typescript requires all apps to be documented so we don't accidentally forget one when we create one.

you can alr merge this before that though^^

Copy link

@vercel vercel bot left a comment

Choose a reason for hiding this comment

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

Additional Suggestion:

The jwt.mdx documentation contains a link to the API Keys documentation at its old path. The link should be updated to point to the new location in the apps section.

View Details
📝 Patch Details
diff --git a/docs/content/docs/(guides)/concepts/jwt.mdx b/docs/content/docs/(guides)/concepts/jwt.mdx
index 3cfec2e8..c2beceb8 100644
--- a/docs/content/docs/(guides)/concepts/jwt.mdx
+++ b/docs/content/docs/(guides)/concepts/jwt.mdx
@@ -218,7 +218,7 @@ Use the JWT viewer above to inspect tokens and verify their contents. Pay specia
 
 ## Related Concepts
 
-- [API Keys](/docs/concepts/api-keys) - Alternative authentication method for server-to-server communication
+- [API Keys](/docs/apps/api-keys) - Alternative authentication method for server-to-server communication
 - [Backend Integration](/docs/concepts/backend-integration) - How to verify JWTs in your backend
 - [Permissions](/docs/concepts/permissions) - Understanding user permissions (not included in JWTs)
 - [Teams](/docs/concepts/teams) - Understanding team context in JWTs

Analysis

Broken documentation link in JWT guide

What fails: Link [API Keys](/docs/concepts/api-keys) in docs/content/docs/(guides)/concepts/jwt.mdx line 221 points to non-existent documentation file

How to reproduce:

  1. Navigate to JWT documentation at /docs/concepts/jwt
  2. Click the "API Keys" link in the "Related Concepts" section
  3. Results in 404 - page not found

Result: 404 error - no file exists at docs/content/docs/(guides)/concepts/api-keys.mdx

Expected: Should link to existing API Keys documentation at /docs/apps/api-keys (file exists at docs/content/docs/(guides)/apps/api-keys.mdx)

Fix: Updated link from /docs/concepts/api-keys to /docs/apps/api-keys to match actual file location in Next.js/Fumadocs file-based routing structure

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: 0

🧹 Nitpick comments (1)
packages/stack-shared/src/index.ts (1)

1-3: Consider clarifying the UI component export path notation.

The comment helps explain the architectural decision to separate UI components, which is good practice. However, the path notation ./dist/apps/apps-ui could be clearer. Consider one of these alternatives:

  • dist/apps/apps-ui (package-relative path consumers would use)
  • @stackframe/stack-shared/dist/apps/apps-ui (full import path)
  • ./apps/apps-ui.tsx (compiled to dist/apps/apps-ui) (source reference)

Apply this diff to use a clearer path notation:

-// Note: UI components (AppIcon, etc.) are exported via ./dist/apps/apps-ui
+// Note: UI components (AppIcon, etc.) are exported via dist/apps/apps-ui
 // They are not re-exported here to avoid requiring React for non-UI consumers
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b6a11c0 and 45db75e.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (1)
  • packages/stack-shared/src/index.ts (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (11)
  • GitHub Check: Vercel Agent Review
  • GitHub Check: build (22.x)
  • GitHub Check: all-good
  • GitHub Check: restart-dev-and-test-with-custom-base-port
  • GitHub Check: lint_and_build (latest)
  • GitHub Check: setup-tests
  • GitHub Check: build (22.x)
  • GitHub Check: docker
  • GitHub Check: restart-dev-and-test
  • GitHub Check: check_prisma_migrations (22.x)
  • GitHub Check: build (22.x)

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: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 887c367 and 4f33374.

📒 Files selected for processing (1)
  • docs/src/middleware.ts (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (11)
  • GitHub Check: restart-dev-and-test
  • GitHub Check: Vercel Agent Review
  • GitHub Check: lint_and_build (latest)
  • GitHub Check: docker
  • GitHub Check: build (22.x)
  • GitHub Check: restart-dev-and-test-with-custom-base-port
  • GitHub Check: check_prisma_migrations (22.x)
  • GitHub Check: setup-tests
  • GitHub Check: build (22.x)
  • GitHub Check: all-good
  • GitHub Check: build (22.x)

@madster456 madster456 merged commit 8fa56f8 into dev Nov 12, 2025
25 checks passed
@madster456 madster456 deleted the docs/apps-section branch November 12, 2025 21:45
@coderabbitai coderabbitai bot mentioned this pull request Jan 27, 2026
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.

2 participants