Skip to content

Conversation

@anmolsinghbhatia
Copy link
Collaborator

@anmolsinghbhatia anmolsinghbhatia commented Dec 4, 2025

Description

This PR includes enhancements for app rail.

Type of Change

  • Improvement
  • Code refactoring

Summary by CodeRabbit

  • New Features

    • Toggle to dock/undock the App Rail from the context menu.
    • "Preferences" added to the user settings menu.
  • Behavior

    • App Rail visibility can be toggled and is persisted per workspace.
    • App Rail may be conditionally rendered based on workspace settings.
  • Style

    • Adjusted help icon and workspace logo rounding; increased Projects dock icon size.
    • Updated plane and wiki icon artwork.
  • Localization

    • Two English navigation labels clarified.

✏️ Tip: You can customize this high-level summary in your review settings.

@anmolsinghbhatia anmolsinghbhatia self-assigned this Dec 4, 2025
Copilot AI review requested due to automatic review settings December 4, 2025 09:56
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 4, 2025

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Walkthrough

Adds an app-rail visibility system: new types, context, and provider persisting per-workspace collapsed state; CE/EE re-exports and a CE wrapper provider; layout and content integrate the provider and conditionally render/toggle the app rail; assorted UI and icon/translation tweaks.

Changes

Cohort / File(s) Summary
Core App Rail Library
apps/web/core/lib/app-rail/types.ts, apps/web/core/lib/app-rail/context.tsx, apps/web/core/lib/app-rail/provider.tsx, apps/web/core/lib/app-rail/index.ts
New IAppRailVisibilityContext type, AppRailVisibilityContext + useAppRailVisibility hook, and AppRailVisibilityProvider that derives workspaceSlug, persists per-workspace collapsed state to localStorage, computes shouldRenderAppRail, and exposes toggleAppRail; added barrel exports.
CE Hook & Wrapper
apps/web/ce/hooks/app-rail/provider.tsx, apps/web/ce/hooks/app-rail/index.ts
New CE-level AppRailVisibilityProvider that wraps core provider with isEnabled={false} (observer) and added re-export barrel.
EE Hook Re-export
apps/web/ee/hooks/app-rail/index.ts
EE barrel re-exports CE app-rail exports via export * from "ce/hooks/app-rail".
Layout & Content Integration
apps/web/app/(all)/[workspaceSlug]/layout.tsx, apps/web/ce/components/workspace/content-wrapper.tsx
Layout now wraps workspace with AppRailVisibilityProvider; WorkspaceContentWrapper consumes visibility to conditionally render AppRailRoot and toggle padding classes based on shouldRenderAppRail.
App Rail Root Controls
apps/web/core/components/navigation/app-rail-root.tsx
AppRailRoot consumes useAppRailVisibility, exposes a context-menu separator and a toggle item that calls toggleAppRail, labeled "Dock App Rail" / "Undock App Rail" based on isCollapsed.
Sidebar & User Menu UI
apps/web/core/components/workspace/sidebar/user-menu-root.tsx, apps/web/core/components/workspace/sidebar/help-section/root.tsx, apps/web/core/components/workspace/sidebar/workspace-menu-root.tsx
Added "Preferences" menu item (Settings2 icon) and adjusted gap (gap-2.5 → gap-2); increased HelpCircle icon size (4 → 5); added rounded-md class to WorkspaceLogo.
Translations
packages/i18n/src/locales/en/translations.ts
Updated English translations: accordion_navigation_control → "Accordion sidebar navigation"; horizontal_navigation_bar → "Tabbed Navigation".
Icons (Propel)
packages/propel/src/icons/sub-brand/plane-icon.tsx, packages/propel/src/icons/sub-brand/wiki-icon.tsx
Removed clipPathId / useId usage and simplified IconWrapper props; replaced SVG path data for both icons.
App Rail Dock Item
apps/web/ce/components/app-rail/app-rail-hoc.tsx
Increased Projects dock item icon size (4 → 5).
sequenceDiagram
    participant User
    participant UserMenu as User Menu
    participant AppRailRoot as AppRailRoot
    participant Hook as useAppRailVisibility
    participant Provider as AppRailVisibilityProvider
    participant Storage as localStorage
    participant Content as WorkspaceContentWrapper

    User->>UserMenu: Click toggle item
    UserMenu->>Hook: toggleAppRail()
    Hook->>Provider: update isCollapsed
    Provider->>Storage: persist per-workspace collapsed state
    Provider->>Hook: update shouldRenderAppRail
    Hook->>Content: re-render with new shouldRenderAppRail
    alt shouldRenderAppRail true
        Content->>AppRailRoot: render rail (add padding-left)
    else shouldRenderAppRail false
        Content->>AppRailRoot: skip render (remove padding-left)
    end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

  • Pay extra attention to:
    • apps/web/core/lib/app-rail/provider.tsx: localStorage key derivation, workspaceSlug handling, memoization, and observer usage.
    • apps/web/core/lib/app-rail/context.tsx: correct error handling when hook used outside provider.
    • apps/web/ce/components/workspace/content-wrapper.tsx and apps/web/app/(all)/[workspaceSlug]/layout.tsx: correct provider placement and conditional rendering/class toggling.
    • apps/web/core/components/navigation/app-rail-root.tsx and apps/web/core/components/workspace/sidebar/user-menu-root.tsx: correct wiring and translation/label usage.

Poem

🐰 I hop where rails quietly sleep,
Keys tucked per workspace, soft and deep.
Toggle the dock, let paddings play,
Icons shimmer, translations sway.
A rabbit cheers: "Render — yay!"

Pre-merge checks and finishing touches

❌ Failed checks (2 warnings)
Check name Status Explanation Resolution
Description check ⚠️ Warning The description is significantly incomplete, missing critical sections like detailed description of changes, test scenarios, and references to related issues that are required by the repository template. Add a comprehensive description explaining the app rail enhancements, include test scenarios demonstrating the changes, and link to related issues using the provided template format.
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 (1 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change as 'app rail enhancements' with a ticket reference, accurately reflecting the core modifications across multiple app rail-related files.
✨ 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 refactor-app-rail-enhancements

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3f3243e and 13af6d2.

📒 Files selected for processing (2)
  • apps/web/core/lib/app-rail/types.ts (1 hunks)
  • apps/web/ee/hooks/app-rail/index.ts (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • apps/web/ee/hooks/app-rail/index.ts
  • apps/web/core/lib/app-rail/types.ts
⏰ 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). (2)
  • GitHub Check: Build and lint web apps
  • GitHub Check: Analyze (javascript)

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

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR introduces an app rail visibility management system that enables conditional rendering of the app rail navigation component based on workspace-level configuration and user preferences. It implements a clean separation between Community Edition (CE) and Enterprise Edition (EE) using the repository's established architectural pattern.

Key changes:

  • Implements a React Context-based visibility system with localStorage persistence for app rail collapse state
  • Establishes CE/EE separation where CE has the feature disabled by default and EE can override with custom logic
  • Integrates toggle functionality into the user menu and conditionally renders the app rail in the workspace content wrapper

Reviewed changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
apps/web/core/lib/app-rail/types.ts Defines TypeScript interfaces for app rail visibility context including enabled state, collapse state, and toggle functionality
apps/web/core/lib/app-rail/context.tsx Creates React Context and custom hook for consuming app rail visibility state with proper error handling
apps/web/core/lib/app-rail/provider.tsx Implements the core provider component that manages app rail state using localStorage and workspace scope
apps/web/core/lib/app-rail/index.ts Barrel export for the app rail library components
apps/web/ce/hooks/app-rail/provider.tsx CE-specific wrapper that hardcodes isEnabled={false} to disable the app rail feature in Community Edition
apps/web/ce/hooks/app-rail/index.ts Barrel export for CE app rail hooks
apps/web/ee/hooks/app-rail/index.ts EE re-export pattern that delegates to CE implementation, allowing EE-specific overrides in the build
apps/web/ce/components/workspace/content-wrapper.tsx Conditionally renders AppRailRoot based on visibility context and adjusts content padding accordingly
apps/web/app/(all)/[workspaceSlug]/layout.tsx Wraps workspace layout with AppRailVisibilityProvider to provide context to child components
apps/web/core/components/workspace/sidebar/user-menu-root.tsx Adds toggle menu item to user menu for showing/hiding the app rail when feature is enabled
apps/web/core/components/workspace/sidebar/workspace-menu-root.tsx Adds rounded corners to workspace logo border styling for visual consistency
apps/web/core/components/workspace/sidebar/help-section/root.tsx Increases help icon size from 4 to 5 for better visual balance

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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

🧹 Nitpick comments (2)
apps/web/ce/hooks/app-rail/provider.tsx (1)

15-17: Unnecessary observer wrapper.

This component doesn't access any MobX observables directly—it only passes children through with a hardcoded isEnabled={false}. The CoreProvider is already wrapped with observer, so wrapping this thin wrapper is redundant and adds unnecessary overhead.

-export const AppRailVisibilityProvider = observer(({ children }: AppRailVisibilityProviderProps) => (
+export const AppRailVisibilityProvider = ({ children }: AppRailVisibilityProviderProps) => (
   <CoreProvider isEnabled={false}>{children}</CoreProvider>
-));
+);

If you remove observer, you can also remove the mobx-react import on line 4.

apps/web/core/lib/app-rail/provider.tsx (1)

28-30: Stale closure in toggleAppRail callback.

The callback references isCollapsed directly, which captures the value at the time of memoization. If the user toggles rapidly or if there's any async behavior, this could lead to stale state.

Use a functional update pattern to ensure you're always working with the latest value:

 const toggleAppRail = useCallback(() => {
-  setIsCollapsed(!isCollapsed);
-}, [isCollapsed, setIsCollapsed]);
+  setIsCollapsed((prev) => !prev);
+}, [setIsCollapsed]);

This removes the dependency on isCollapsed and guarantees the toggle always flips the current state correctly.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 739b1bf and 099668f.

📒 Files selected for processing (12)
  • apps/web/app/(all)/[workspaceSlug]/layout.tsx (1 hunks)
  • apps/web/ce/components/workspace/content-wrapper.tsx (1 hunks)
  • apps/web/ce/hooks/app-rail/index.ts (1 hunks)
  • apps/web/ce/hooks/app-rail/provider.tsx (1 hunks)
  • apps/web/core/components/workspace/sidebar/help-section/root.tsx (1 hunks)
  • apps/web/core/components/workspace/sidebar/user-menu-root.tsx (4 hunks)
  • apps/web/core/components/workspace/sidebar/workspace-menu-root.tsx (1 hunks)
  • apps/web/core/lib/app-rail/context.tsx (1 hunks)
  • apps/web/core/lib/app-rail/index.ts (1 hunks)
  • apps/web/core/lib/app-rail/provider.tsx (1 hunks)
  • apps/web/core/lib/app-rail/types.ts (1 hunks)
  • apps/web/ee/hooks/app-rail/index.ts (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{ts,tsx,mts,cts}

📄 CodeRabbit inference engine (.github/instructions/typescript.instructions.md)

**/*.{ts,tsx,mts,cts}: Use const type parameters for more precise literal inference in TypeScript 5.0+
Use the satisfies operator to validate types without widening them
Leverage inferred type predicates to reduce the need for explicit is return types in filter/check functions
Use NoInfer<T> utility to block inference for specific type arguments when they should be determined by other arguments
Utilize narrowing in switch(true) blocks for control flow analysis (TypeScript 5.3+)
Rely on narrowing from direct boolean comparisons for type guards
Trust preserved narrowing in closures when variables aren't modified after the check (TypeScript 5.4+)
Use constant indices to narrow object/array properties (TypeScript 5.5+)
Use standard ECMAScript decorators (Stage 3) instead of legacy experimentalDecorators
Use using declarations for explicit resource management with Disposable pattern instead of manual cleanup (TypeScript 5.2+)
Use with { type: "json" } for import attributes; avoid deprecated assert syntax (TypeScript 5.3/5.8+)
Use import type explicitly when importing types to ensure they are erased during compilation, respecting verbatimModuleSyntax flag
Use .ts, .mts, .cts extensions in import type statements (TypeScript 5.2+)
Use import type { Type } from "mod" with { "resolution-mode": "import" } for specific module resolution contexts (TypeScript 5.3+)
Use new iterator methods (map, filter, etc.) if targeting modern environments (TypeScript 5.6+)
Utilize new Set methods like union, intersection, etc., when available (TypeScript 5.5+)
Use Object.groupBy / Map.groupBy standard methods for grouping instead of external libraries (TypeScript 5.4+)
Use Promise.withResolvers() for creating promises with exposed resolve/reject functions (TypeScript 5.7+)
Use copying array methods (toSorted, toSpliced, with) for immutable array operations (TypeScript 5.2+)
Avoid accessing instance fields via super in classes (TypeScript 5....

Files:

  • apps/web/core/lib/app-rail/types.ts
  • apps/web/core/components/workspace/sidebar/help-section/root.tsx
  • apps/web/ce/hooks/app-rail/provider.tsx
  • apps/web/core/lib/app-rail/context.tsx
  • apps/web/core/lib/app-rail/provider.tsx
  • apps/web/ce/hooks/app-rail/index.ts
  • apps/web/app/(all)/[workspaceSlug]/layout.tsx
  • apps/web/ce/components/workspace/content-wrapper.tsx
  • apps/web/core/components/workspace/sidebar/user-menu-root.tsx
  • apps/web/ee/hooks/app-rail/index.ts
  • apps/web/core/lib/app-rail/index.ts
  • apps/web/core/components/workspace/sidebar/workspace-menu-root.tsx
🧠 Learnings (5)
📚 Learning: 2025-10-09T20:42:31.843Z
Learnt from: lifeiscontent
Repo: makeplane/plane PR: 7922
File: apps/admin/app/(all)/(dashboard)/ai/form.tsx:19-19
Timestamp: 2025-10-09T20:42:31.843Z
Learning: In the makeplane/plane repository, React types are globally available through TypeScript configuration. Type annotations like React.FC, React.ReactNode, etc. can be used without explicitly importing the React namespace. The codebase uses the modern JSX transform, so React imports are not required for JSX or type references.

Applied to files:

  • apps/web/core/lib/app-rail/context.tsx
  • apps/web/ce/components/workspace/content-wrapper.tsx
📚 Learning: 2025-09-02T08:14:49.260Z
Learnt from: sriramveeraghanta
Repo: makeplane/plane PR: 7697
File: apps/web/app/(all)/[workspaceSlug]/(projects)/header.tsx:12-13
Timestamp: 2025-09-02T08:14:49.260Z
Learning: The star-us-link.tsx file in apps/web/app/(all)/[workspaceSlug]/(projects)/ already has "use client" directive at the top, making it a proper Client Component for hook usage.

Applied to files:

  • apps/web/core/lib/app-rail/context.tsx
  • apps/web/core/lib/app-rail/provider.tsx
📚 Learning: 2025-10-09T22:12:26.424Z
Learnt from: lifeiscontent
Repo: makeplane/plane PR: 7922
File: apps/admin/app/(all)/(dashboard)/ai/form.tsx:19-19
Timestamp: 2025-10-09T22:12:26.424Z
Learning: When `types/react` is installed in a TypeScript project (which is standard for React + TypeScript codebases), React types (React.FC, React.ReactNode, React.ComponentProps, etc.) are globally available by design. These type annotations can and should be used without explicitly importing the React namespace. This is a TypeScript/DefinitelyTyped feature, not codebase-specific configuration.

Applied to files:

  • apps/web/core/lib/app-rail/context.tsx
📚 Learning: 2025-10-21T17:22:05.204Z
Learnt from: lifeiscontent
Repo: makeplane/plane PR: 7989
File: apps/web/app/(all)/[workspaceSlug]/(projects)/projects/(detail)/[projectId]/pages/(detail)/[pageId]/page.tsx:45-46
Timestamp: 2025-10-21T17:22:05.204Z
Learning: In the makeplane/plane repository, the refactor from useParams() to params prop is specifically scoped to page.tsx and layout.tsx files in apps/web/app (Next.js App Router pattern). Other components (hooks, regular client components, utilities) should continue using the useParams() hook as that is the correct pattern for non-route components.

Applied to files:

  • apps/web/core/lib/app-rail/context.tsx
  • apps/web/core/lib/app-rail/provider.tsx
  • apps/web/app/(all)/[workspaceSlug]/layout.tsx
  • apps/web/ce/components/workspace/content-wrapper.tsx
  • apps/web/core/components/workspace/sidebar/user-menu-root.tsx
📚 Learning: 2025-11-25T10:18:05.172Z
Learnt from: CR
Repo: makeplane/plane PR: 0
File: .github/instructions/typescript.instructions.md:0-0
Timestamp: 2025-11-25T10:18:05.172Z
Learning: Applies to **/*.{ts,tsx,mts,cts} : Use `import type { Type } from "mod" with { "resolution-mode": "import" }` for specific module resolution contexts (TypeScript 5.3+)

Applied to files:

  • apps/web/core/lib/app-rail/index.ts
🧬 Code graph analysis (5)
apps/web/ce/hooks/app-rail/provider.tsx (1)
apps/web/core/lib/app-rail/provider.tsx (1)
  • AppRailVisibilityProvider (19-46)
apps/web/core/lib/app-rail/context.tsx (1)
apps/web/core/lib/app-rail/types.ts (1)
  • IAppRailVisibilityContext (5-26)
apps/web/app/(all)/[workspaceSlug]/layout.tsx (5)
apps/web/core/lib/wrappers/authentication-wrapper.tsx (1)
  • AuthenticationWrapper (26-138)
apps/web/core/layouts/auth-layout/workspace-wrapper.tsx (1)
  • WorkspaceAuthWrapper (42-230)
apps/web/ce/hooks/app-rail/provider.tsx (1)
  • AppRailVisibilityProvider (15-17)
apps/web/core/lib/app-rail/provider.tsx (1)
  • AppRailVisibilityProvider (19-46)
apps/web/ce/components/workspace/content-wrapper.tsx (1)
  • WorkspaceContentWrapper (10-37)
apps/web/ce/components/workspace/content-wrapper.tsx (2)
apps/web/core/lib/app-rail/context.tsx (1)
  • useAppRailVisibility (19-25)
apps/web/core/components/navigation/app-rail-root.tsx (1)
  • AppRailRoot (16-78)
apps/web/core/components/workspace/sidebar/user-menu-root.tsx (1)
apps/web/core/lib/app-rail/context.tsx (1)
  • useAppRailVisibility (19-25)
⏰ 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). (4)
  • GitHub Check: Agent
  • GitHub Check: CodeQL analysis (javascript-typescript)
  • GitHub Check: Analyze (javascript)
  • GitHub Check: Build and lint web apps
🔇 Additional comments (11)
apps/web/core/components/workspace/sidebar/help-section/root.tsx (1)

35-35: Help icon size change is safe and consistent

The bump to size-5 is a straightforward visual adjustment with no impact on behavior; looks good as part of the sidebar button item.

apps/web/core/components/workspace/sidebar/workspace-menu-root.tsx (1)

118-122: Workspace logo styling tweak looks consistent

The updated WorkspaceLogo classNames (border + rounded + size-7) align with the rest of the sidebar/top-nav styling; nothing functionally risky here.

apps/web/core/lib/app-rail/types.ts (1)

1-27: App rail visibility context type is well-defined

IAppRailVisibilityContext matches the provider value shape (enabled + collapsed + computed visibility + toggle) and is clearly documented; good foundation for the new context.

apps/web/ee/hooks/app-rail/index.ts (1)

1-1: EE barrel re-export for app rail is straightforward

Re-exporting from "ce/hooks/app-rail" cleanly surfaces the CE app-rail hooks under the EE path; no issues as long as the ce alias is correctly configured (which matches existing patterns in this repo).

apps/web/ce/hooks/app-rail/index.ts (1)

1-1: CE app rail hook barrel is clean

export * from "./provider"; is a minimal, clear barrel layer that matches how other hook modules are exposed.

apps/web/app/(all)/[workspaceSlug]/layout.tsx (1)

4-16: Placing AppRailVisibilityProvider at workspace layout level is appropriate

Wrapping WorkspaceContentWrapper (and thus the entire workspace UI, including sidebar and content) with AppRailVisibilityProvider is the right integration point for a per‑workspace visibility context and matches how other global wrappers are structured here.

apps/web/core/lib/app-rail/index.ts (1)

1-3: App rail core barrel cleanly exposes the public API

Re-exporting ./context, ./provider, and ./types from a single index keeps consumers’ import paths simple and matches existing module organization.

apps/web/ce/components/workspace/content-wrapper.tsx (1)

6-7: App rail visibility integration into workspace layout looks correct

  • useAppRailVisibility is used to read shouldRenderAppRail, and
  • <AppRailRoot /> is rendered only when shouldRenderAppRail is true, while the main content’s pl-2 padding is also toggled accordingly.

This cleanly wires the new visibility context into the layout without changing the component’s external API.

One thing to confirm: every usage of WorkspaceContentWrapper should now be within an AppRailVisibilityProvider (as in [workspaceSlug]/layout.tsx), otherwise the hook will throw at runtime.

Also applies to: 15-17, 22-29

apps/web/core/components/workspace/sidebar/user-menu-root.tsx (1)

6-7: Localize label strings in the app rail toggle menu item

The app rail toggle functionality is correctly wired and the provider is properly placed in the workspace layout, covering all usage of UserMenuRoot. However, the menu item labels are hard-coded:

<span>{isCollapsed ? "Show app rail" : "Hide app rail"}</span>

These strings should be moved to the i18n catalog for consistency with the rest of the menu, which uses t(...). Update the strings to:

<span>{isCollapsed ? t("app_rail.show") : t("app_rail.hide")}</span>

Then add the corresponding keys to the i18n catalog.

Also applies to: 17-18, 30-31, 89-100

⛔ Skipped due to learnings
Learnt from: lifeiscontent
Repo: makeplane/plane PR: 7922
File: apps/admin/app/(all)/(dashboard)/ai/form.tsx:19-19
Timestamp: 2025-10-09T20:42:31.843Z
Learning: In the makeplane/plane repository, React types are globally available through TypeScript configuration. Type annotations like React.FC, React.ReactNode, etc. can be used without explicitly importing the React namespace. The codebase uses the modern JSX transform, so React imports are not required for JSX or type references.
apps/web/core/lib/app-rail/context.tsx (1)

1-25: Well-structured context implementation.

The context and hook follow React best practices:

  • Proper import type for type-only imports (aligns with verbatimModuleSyntax guidelines)
  • Correct undefined default with runtime guard in the hook
  • Clear error message for debugging misuse
apps/web/core/lib/app-rail/provider.tsx (1)

19-19: Verify observer is necessary here.

The component uses observer from MobX but doesn't appear to access any MobX observables directly. If there's no intention to observe store changes in this provider, the wrapper can be removed to reduce overhead.

If the intent is to support future observable access or if useParams returns observable values in this codebase, please disregard. Otherwise, consider removing the observer wrapper.

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/i18n/src/locales/en/translations.ts (1)

2702-2703: Navigation labels update looks good; consider casing consistency (optional).

The revised phrases are clear and better aligned with the navigation UI. If you have copy guidelines around title vs sentence case, you may optionally adjust "Tabbed Navigation" to match nearby labels (e.g., "Tabbed navigation") or vice versa for consistency across this section.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 099668f and 3f3243e.

📒 Files selected for processing (6)
  • apps/web/ce/components/app-rail/app-rail-hoc.tsx (1 hunks)
  • apps/web/core/components/navigation/app-rail-root.tsx (3 hunks)
  • apps/web/core/components/workspace/sidebar/user-menu-root.tsx (3 hunks)
  • packages/i18n/src/locales/en/translations.ts (1 hunks)
  • packages/propel/src/icons/sub-brand/plane-icon.tsx (1 hunks)
  • packages/propel/src/icons/sub-brand/wiki-icon.tsx (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • apps/web/core/components/workspace/sidebar/user-menu-root.tsx
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{ts,tsx,mts,cts}

📄 CodeRabbit inference engine (.github/instructions/typescript.instructions.md)

**/*.{ts,tsx,mts,cts}: Use const type parameters for more precise literal inference in TypeScript 5.0+
Use the satisfies operator to validate types without widening them
Leverage inferred type predicates to reduce the need for explicit is return types in filter/check functions
Use NoInfer<T> utility to block inference for specific type arguments when they should be determined by other arguments
Utilize narrowing in switch(true) blocks for control flow analysis (TypeScript 5.3+)
Rely on narrowing from direct boolean comparisons for type guards
Trust preserved narrowing in closures when variables aren't modified after the check (TypeScript 5.4+)
Use constant indices to narrow object/array properties (TypeScript 5.5+)
Use standard ECMAScript decorators (Stage 3) instead of legacy experimentalDecorators
Use using declarations for explicit resource management with Disposable pattern instead of manual cleanup (TypeScript 5.2+)
Use with { type: "json" } for import attributes; avoid deprecated assert syntax (TypeScript 5.3/5.8+)
Use import type explicitly when importing types to ensure they are erased during compilation, respecting verbatimModuleSyntax flag
Use .ts, .mts, .cts extensions in import type statements (TypeScript 5.2+)
Use import type { Type } from "mod" with { "resolution-mode": "import" } for specific module resolution contexts (TypeScript 5.3+)
Use new iterator methods (map, filter, etc.) if targeting modern environments (TypeScript 5.6+)
Utilize new Set methods like union, intersection, etc., when available (TypeScript 5.5+)
Use Object.groupBy / Map.groupBy standard methods for grouping instead of external libraries (TypeScript 5.4+)
Use Promise.withResolvers() for creating promises with exposed resolve/reject functions (TypeScript 5.7+)
Use copying array methods (toSorted, toSpliced, with) for immutable array operations (TypeScript 5.2+)
Avoid accessing instance fields via super in classes (TypeScript 5....

Files:

  • packages/propel/src/icons/sub-brand/plane-icon.tsx
  • packages/propel/src/icons/sub-brand/wiki-icon.tsx
  • apps/web/core/components/navigation/app-rail-root.tsx
  • apps/web/ce/components/app-rail/app-rail-hoc.tsx
  • packages/i18n/src/locales/en/translations.ts
🧠 Learnings (3)
📚 Learning: 2025-10-01T15:30:17.605Z
Learnt from: lifeiscontent
Repo: makeplane/plane PR: 7888
File: packages/propel/src/avatar/avatar.stories.tsx:2-3
Timestamp: 2025-10-01T15:30:17.605Z
Learning: In the makeplane/plane repository, avoid suggesting inline type imports (e.g., `import { Avatar, type TAvatarSize }`) due to bundler compatibility issues. Keep type imports and value imports as separate statements.

Applied to files:

  • packages/propel/src/icons/sub-brand/plane-icon.tsx
📚 Learning: 2025-10-21T17:22:05.204Z
Learnt from: lifeiscontent
Repo: makeplane/plane PR: 7989
File: apps/web/app/(all)/[workspaceSlug]/(projects)/projects/(detail)/[projectId]/pages/(detail)/[pageId]/page.tsx:45-46
Timestamp: 2025-10-21T17:22:05.204Z
Learning: In the makeplane/plane repository, the refactor from useParams() to params prop is specifically scoped to page.tsx and layout.tsx files in apps/web/app (Next.js App Router pattern). Other components (hooks, regular client components, utilities) should continue using the useParams() hook as that is the correct pattern for non-route components.

Applied to files:

  • packages/propel/src/icons/sub-brand/plane-icon.tsx
  • apps/web/core/components/navigation/app-rail-root.tsx
📚 Learning: 2025-09-02T08:14:49.260Z
Learnt from: sriramveeraghanta
Repo: makeplane/plane PR: 7697
File: apps/web/app/(all)/[workspaceSlug]/(projects)/header.tsx:12-13
Timestamp: 2025-09-02T08:14:49.260Z
Learning: The star-us-link.tsx file in apps/web/app/(all)/[workspaceSlug]/(projects)/ already has "use client" directive at the top, making it a proper Client Component for hook usage.

Applied to files:

  • apps/web/core/components/navigation/app-rail-root.tsx
🧬 Code graph analysis (4)
packages/propel/src/icons/sub-brand/plane-icon.tsx (1)
packages/propel/src/icons/icon-wrapper.tsx (1)
  • IconWrapper (11-44)
packages/propel/src/icons/sub-brand/wiki-icon.tsx (1)
packages/propel/src/icons/icon-wrapper.tsx (1)
  • IconWrapper (11-44)
apps/web/core/components/navigation/app-rail-root.tsx (1)
apps/web/core/lib/app-rail/context.tsx (1)
  • useAppRailVisibility (19-25)
apps/web/ce/components/app-rail/app-rail-hoc.tsx (1)
packages/propel/src/icons/sub-brand/plane-icon.tsx (1)
  • PlaneNewIcon (6-19)
⏰ 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). (2)
  • GitHub Check: Build and lint web apps
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (4)
packages/propel/src/icons/sub-brand/plane-icon.tsx (1)

8-17: LGTM! Good simplification with visual updates.

The removal of clipPathId simplifies the component—IconWrapper now renders the SVG paths directly without the clipPath wrapper. The updated path data changes the icon's appearance, which appears intentional for the app rail enhancements.

Ensure the new icon visuals render correctly in the app rail context and match the design specifications.

packages/propel/src/icons/sub-brand/wiki-icon.tsx (1)

8-13: LGTM! Consistent refactoring pattern.

This follows the same simplification as PlaneNewIcon—removing the unnecessary clipPathId and updating the SVG path data for the new visual design. The changes are consistent and correct.

apps/web/ce/components/app-rail/app-rail-hoc.tsx (1)

20-27: Projects dock icon size change looks fine

The switch to className="size-5" on PlaneNewIcon is safe and keeps the HOC typings intact. As long as this size matches your design for other app-rail icons, there’s nothing blocking here.

apps/web/core/components/navigation/app-rail-root.tsx (1)

11-12: App-rail visibility hook and dock/undock menu wiring look correct; ensure provider wrapping

Importing useAppRailVisibility, destructuring { isCollapsed, toggleAppRail }, and wiring toggleAppRail into the new context-menu item is a clean integration. The conditional label ("Dock App Rail" vs "Undock App Rail") reads well and reflects the intended action given the isCollapsed flag.

The only thing to double‑check is that every render path for AppRailRoot is wrapped in AppRailVisibilityProvider; otherwise useAppRailVisibility will throw if the context is missing. Using useParams in this client component is consistent with the repo’s pattern of reserving route params props for page.tsx/layout.tsx only. Based on learnings.

Also applies to: 23-24, 75-78

@sriramveeraghanta sriramveeraghanta merged commit 1090b3e into preview Dec 4, 2025
5 of 6 checks passed
@sriramveeraghanta sriramveeraghanta deleted the refactor-app-rail-enhancements branch December 4, 2025 12:45
ClarenceChen0627 pushed a commit to ClarenceChen0627/plane that referenced this pull request Dec 5, 2025
* chore: app rail context added

* chore: dock/undock app rail implementation

* chore: refactor

* chore: code refactor

* chore: code refactor
ClarenceChen0627 pushed a commit to ClarenceChen0627/plane that referenced this pull request Dec 5, 2025
* chore: app rail context added

* chore: dock/undock app rail implementation

* chore: refactor

* chore: code refactor

* chore: code refactor
ClarenceChen0627 pushed a commit to ClarenceChen0627/plane that referenced this pull request Dec 5, 2025
* chore: app rail context added

* chore: dock/undock app rail implementation

* chore: refactor

* chore: code refactor

* chore: code refactor
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.

5 participants