Skip to content

Conversation

@ameer2468
Copy link
Contributor

@ameer2468 ameer2468 commented Sep 16, 2025

This PR:

  • Bottom mobile tabs for navigating with org selector.
  • Fixed navbar on desktop sizing so it scrolls with you.
Screenshot 2025-09-16 at 11 57 16

Summary by CodeRabbit

  • New Features
    • Introduced a MobileTab bottom navigation on mobile with organization selector and quick links.
  • Style
    • Fixed, top-aligned navbar with refined spacing and layering for consistent positioning.
    • Updated layout for smoother scrolling and better use of screen space across breakpoints.
    • Desktop sidebar now displays only on large screens; mobile layout optimized.
    • Repositioned Intercom launcher on mobile to sit above the bottom nav.
    • Tweaked mobile header padding and removed the mobile menu open button.
  • Bug Fixes
    • Improved list rendering keys to avoid potential UI inconsistencies.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 16, 2025

Warning

Rate limit exceeded

@ameer2468 has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 6 minutes and 53 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between fceaee4 and 695b033.

📒 Files selected for processing (1)
  • apps/web/app/(org)/dashboard/_components/MobileTab.tsx (1 hunks)

Walkthrough

Introduces a new MobileTab component with an org selector and quick links, integrates it into the dashboard layout, restructures DashboardInner layout and nav positioning, tweaks mobile navbar padding/removal of open button, and adds a mobile CSS rule to offset the Intercom launcher.

Changes

Cohort / File(s) Summary
Dashboard layout and structure
apps/web/app/(org)/dashboard/layout.tsx, apps/web/app/(org)/dashboard/_components/DashboardInner.tsx
Integrated MobileTab into the grid; adjusted DesktopNav visibility to lg-only; reflowed main content spans; removed outer overflow-y; refactored DashboardInner container classes, fixed NavBar to top, updated content/children wrappers, and stringified React list keys.
New mobile bottom tab
apps/web/app/(org)/dashboard/_components/MobileTab.tsx
Added MobileTab with Orgs pill/menu, animated dropdown, quick links, and routing. Uses dashboard context, updateActiveOrganization, click-away handling, and responsive visibility (mobile-only).
Mobile navbar tweaks
apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx
Removed Menu icon/open button; added horizontal padding to header items; retained close/overlay behavior.
Global CSS tweak
apps/web/app/globals.css
Added mobile @media rule setting .intercom-lightweight-app-launcher { bottom: 90px !important; } for max-width 768px.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor U as User
  participant MT as MobileTab
  participant OM as OrgsMenu
  participant DC as DashboardContext
  participant SA as updateActiveOrganization (server)
  participant R as Router

  U->>MT: Tap Orgs pill
  MT->>OM: Toggle menu (open)
  U->>OM: Select organization
  OM->>DC: setActiveOrganization(id)
  DC->>SA: Invoke server action with org id
  SA-->>DC: Confirm active org updated
  OM->>MT: Close menu
  MT->>R: navigate("/dashboard/caps")
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

A rabbit taps the mobile bar with glee,
New tabs below, the navbar set free.
Orgs drop down, then hop to caps—
CSS cushions Intercom’s laps.
Keys now string, the layout sings;
Quick little hops make smoother things. 🐇✨

Pre-merge checks and finishing touches

❌ 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%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ 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 "improvement: mobile experience" accurately identifies the primary focus of this changeset — mobile UI/UX changes such as adding a bottom MobileTab, mobile nav adjustments, and mobile-specific CSS — and is concise and relevant to the PR objectives and file-level changes. While a bit general, it does summarize the main intent rather than describing unrelated work.

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

@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

🧹 Nitpick comments (4)
apps/web/app/(org)/dashboard/_components/DashboardInner.tsx (2)

83-89: Review the fixed navbar positioning strategy.

The navbar is now fixed on mobile (using fixed class with top-0) but relative on larger screens (md:relative). This dual positioning approach combined with the margin offset (mt-[126px] on the parent and mt-[60px] on the navbar) creates a complex layout that may be fragile and harder to maintain.

Consider using CSS custom properties or a single positioning strategy to manage the layout more consistently.


176-182: Remove placeholder CSS class.

The custom-scroll class is referenced on Line 177 but doesn't appear to be defined in the provided CSS. This seems to be a placeholder that should either be implemented or removed.

Apply this diff to remove the unused class:

-					"flex overscroll-contain flex-col flex-1 flex-grow p-5 h-full border border-b-0 custom-scroll bg-gray-2 border-gray-3 lg:rounded-tl-2xl lg:p-8"
+					"flex overscroll-contain flex-col flex-1 flex-grow p-5 h-full border border-b-0 bg-gray-2 border-gray-3 lg:rounded-tl-2xl lg:p-8"
apps/web/app/(org)/dashboard/_components/MobileTab.tsx (2)

126-129: Consider UX improvement for organization switching.

When switching organizations, the user is automatically redirected to /dashboard/caps. This might be disruptive if the user was on a different page and just wanted to switch context. Consider preserving the current route or making the redirect optional.

Would you like me to implement a solution that preserves the user's current location within the dashboard when switching organizations?


33-43: Consider adding active state indicators to navigation icons.

The navigation icons (spaces, caps, settings) don't show which section is currently active. Adding visual indicators would improve user orientation.

Would you like me to implement active state styling for the navigation icons based on the current route?

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 61308b5 and fceaee4.

📒 Files selected for processing (5)
  • apps/web/app/(org)/dashboard/_components/DashboardInner.tsx (3 hunks)
  • apps/web/app/(org)/dashboard/_components/MobileTab.tsx (1 hunks)
  • apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx (2 hunks)
  • apps/web/app/(org)/dashboard/layout.tsx (2 hunks)
  • apps/web/app/globals.css (1 hunks)
🧰 Additional context used
📓 Path-based instructions (4)
apps/web/**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

apps/web/**/*.{ts,tsx}: Use TanStack Query v5 for client-side server state and data fetching in the web app
Mutations should call Server Actions and perform precise cache updates with setQueryData/setQueriesData, avoiding broad invalidations
Prefer Server Components for initial data and pass initialData to client components for React Query hydration

Files:

  • apps/web/app/(org)/dashboard/_components/MobileTab.tsx
  • apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx
  • apps/web/app/(org)/dashboard/layout.tsx
  • apps/web/app/(org)/dashboard/_components/DashboardInner.tsx
{apps/web,packages/ui}/**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

{apps/web,packages/ui}/**/*.{ts,tsx}: Use Tailwind CSS exclusively for styling in the web app and shared React UI components
Component naming: React components in PascalCase; hooks in camelCase starting with 'use'

Files:

  • apps/web/app/(org)/dashboard/_components/MobileTab.tsx
  • apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx
  • apps/web/app/(org)/dashboard/layout.tsx
  • apps/web/app/(org)/dashboard/_components/DashboardInner.tsx
**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

Use strict TypeScript and avoid any; prefer shared types from packages

**/*.{ts,tsx}: Use Biome to format/lint TypeScript with a 2-space indent
TypeScript file names should be kebab-case (e.g., user-menu.tsx)

Files:

  • apps/web/app/(org)/dashboard/_components/MobileTab.tsx
  • apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx
  • apps/web/app/(org)/dashboard/layout.tsx
  • apps/web/app/(org)/dashboard/_components/DashboardInner.tsx
**/*.{tsx,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

React/Solid components should be named using PascalCase

Files:

  • apps/web/app/(org)/dashboard/_components/MobileTab.tsx
  • apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx
  • apps/web/app/(org)/dashboard/layout.tsx
  • apps/web/app/(org)/dashboard/_components/DashboardInner.tsx
🧬 Code graph analysis (2)
apps/web/app/(org)/dashboard/_components/MobileTab.tsx (3)
apps/web/app/(org)/dashboard/_components/AnimatedIcons/index.ts (3)
  • LayersIcon (19-19)
  • CapIcon (14-14)
  • CogIcon (16-16)
apps/web/app/(org)/dashboard/Contexts.tsx (1)
  • useDashboardContext (42-42)
apps/web/app/(org)/dashboard/_components/Navbar/server.ts (1)
  • updateActiveOrganization (15-39)
apps/web/app/(org)/dashboard/layout.tsx (2)
apps/web/app/(org)/dashboard/_components/Navbar/Desktop.tsx (1)
  • DesktopNav (13-90)
apps/web/app/(org)/dashboard/_components/DashboardInner.tsx (1)
  • DashboardInner (51-194)
🪛 GitHub Check: Typecheck
apps/web/app/(org)/dashboard/_components/MobileTab.tsx

[failure] 109-109:
Type 'MutableRefObject' is not assignable to type 'LegacyRef | undefined'.


[failure] 60-60:
Parameter 'p' implicitly has an 'any' type.


[failure] 60-60:
Argument of type '(p: any) => boolean' is not assignable to parameter of type 'boolean'.

⏰ 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). (3)
  • GitHub Check: Build Desktop (aarch64-apple-darwin, macos-latest)
  • GitHub Check: Build Desktop (x86_64-pc-windows-msvc, windows-latest)
  • GitHub Check: Analyze (rust)
🔇 Additional comments (5)
apps/web/app/globals.css (1)

863-867: LGTM! Proper Intercom launcher repositioning for mobile navigation.

The media query correctly adjusts the Intercom launcher position to avoid overlap with the new mobile bottom navigation (90px from bottom instead of default). The use of !important is justified here to override third-party inline styles.

apps/web/app/(org)/dashboard/_components/Navbar/Mobile.tsx (1)

57-57: LGTM! Consistent mobile header padding.

The addition of horizontal padding (px-4) to the right-side items container creates visual balance with the left-side logo container, improving the mobile header appearance.

apps/web/app/(org)/dashboard/_components/DashboardInner.tsx (1)

307-307: Good fix for React list key warnings.

Converting numeric indices to strings for the key prop is the correct approach. This prevents React warnings about non-string keys in production builds.

apps/web/app/(org)/dashboard/layout.tsx (1)

82-91: Solid responsive grid layout implementation.

The grid structure with responsive column spans (col-span-2 on mobile, md:col-span-1 on desktop) properly handles the show/hide behavior of the desktop navigation. The addition of MobileTab as a separate grid item ensures clean separation of concerns.

apps/web/app/(org)/dashboard/_components/MobileTab.tsx (1)

28-44: Well-structured mobile navigation component.

The component provides good mobile UX with:

  • Sticky bottom positioning for thumb-friendly navigation
  • Clear visual hierarchy with the organization selector
  • Quick access to commonly used features
  • Proper z-index layering (z-50) to stay above content

The animation and click-away behavior for the organization dropdown are properly implemented.

@ameer2468 ameer2468 merged commit 88b644c into main Sep 16, 2025
14 of 15 checks passed
@ameer2468 ameer2468 deleted the improve-mobile-experience branch September 16, 2025 09:22
@coderabbitai coderabbitai bot mentioned this pull request Nov 3, 2025
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