Skip to content

fix(web): add back navigation to project settings

MacroscopeApp / Macroscope - UI Consistency failed Aug 15, 2026 in 2m 33s

UI Consistency: 1 issue found

  • apps/web/src/components/sidebar/SidebarChrome.tsx: extending currentFooterPage to /projects/* renders the shared footer Back button, but handleBackClick hard-navigates to /, diverging from the back contract used by ProjectSettingsPage's Escape handler and SettingsSidebarNav (useCanGoBack() → window.history.back(), fallback /). On the project settings page, Back and Escape now go to different destinations and Back discards the originating thread.

Suggested fix: adopt the existing useCanGoBack()/history.back() contract in SidebarChromeFooter's back handler.

Details

Note

Your check run agent prompt is: .macroscope/check-run-agents/ui-consistency.md
More information about how Check Run Agents work can be found in our Help Center.

Scope reviewed: the single changed line in apps/web/src/components/sidebar/SidebarChrome.tsx plus directly affected consumers — apps/web/src/routes/projects.$projectKey.tsx, apps/web/src/components/settings/ProjectSettingsPanel.tsx (ProjectSettingsPage), apps/web/src/components/settings/SettingsSidebarNav.tsx, apps/web/src/routes/settings.tsx, and apps/web/src/components/AppSidebarLayout.tsx.

No findings on the shared-primitive or Tailwind/CSS-ownership rules: the diff adds no markup, classes, or CSS, and the footer continues to use SidebarMenu/SidebarMenuButton primitives with existing sizing and tooltip semantics. /projects/ is the only project route family (projects.$projectKey), so the prefix match does not capture non-settings routes. One inline comment was posted on the changed lines.


🔍 Agent activity — 1 tool call

💭 I need to examine the file to see what's being changed. The PR is about fixing back navigation for project settings, but the route pattern /projects/ would catch all project pages, not just settings. This means the Back button footer would show on project views and other pages too, potentially replacing the normal sidebar footer with icons — which could be unintended behavior depending on what those routes actually contain. The back button behavior is inconsistent across footer pages — they all navigate to "/" but project settings might need different handling since it's typically accessed from within a project context rather than as a standalone page. I should check if there are other places in the codebase where these pathname checks appear, like in the titlebar or sidebar components, to ensure the footer back navigation aligns with how the rest of the UI handles these routes. I'm noticing a potential navigation inconsistency—the Back button in project settings returns to the home threads page, but project settings is usually accessed from within a thread or the settings area itself. I should trace where the ProjectSettingsPage links are being generated to understand the expected navigation flow. I'm noticing a potential UI inconsistency where the project settings page at /projects/$projectKey displays the thread sidebar instead of a settings navigation, which means the footer would show a "Back" button rather than the settings/PR/usage icons. This seems intentional since project settings is meant to be a full-page view, but I need to check whether the /projects route actually renders as a complete page with its own sidebar. I'm checking whether this is actually a UI consistency issue or just a routing change—the currentFooterPage value seems fine on its own, but I need to verify if ProjectSettingsPage already has its own back button in the header, which could create duplicate navigation affordances. Let me also confirm whether the project settings route is being handled correctly elsewhere. I'm noticing some inconsistency in how back navigation works across different pages. The project settings page uses navigateBackWithinApp, which tries to go back in history if possible, otherwise falls back to the home route. But the new sidebar footer back button always navigates to "/" directly. For pages like usage and pull-requests, this "/" destination makes sense, but for project settings which is typically accessed from a thread view in the sidebar, the behavior might differ from what users expect. I'm wondering if this is actually a UI consistency issue worth flagging, or if it falls outside the scope of the rules which mostly focus on component primitives and CSS. Let me check how the sidebar is actually rendered on the project settings page — I need to look at AppSidebarLayout to see if the chrome footer even appears there or if it's replaced by a different navigation component. I'm noticing a navigation inconsistency where the thread sidebar footer now shows a "Back" button pointing to "/" on the project settings page, but this breaks the expected behavior since the page has its own back handler using history.back(). Navigating away to "/" while a thread is open would lose the thread context. Let me check whether the usage and pull-requests pages have their own in-page back buttons, or if the footer back-to-"/" is the only navigation affordance there. I should look at the ProjectSettingsPanel header to see if there's a back button defined there that would create this conflicting behavior. I'm noticing an inconsistency in the navigation behavior—the new sidebar footer Back button always goes to "/" while pressing Escape uses the history-based navigation to return to the previous route. This is different from how the settings route handles it, where it has the same back navigation logic but doesn't display the chrome footer at all. I should check how /usage and /pull-requests handle this to understand the pattern better. Looking at whether this change introduces a reportable UI consistency issue—the diff doesn't modify any raw controls, CSS, or Tailwind classes, so the main question is whether the behavioral change (the footer "Back" button replacing something) violates the shared component system constraints. The route prefix /projects/ is broader than just the single project settings route, which could be a concern if future routes are added, but that's speculative. The real issue I'm seeing is that the Back button navigates to "/" directly while the page's own Escape handler uses history.back() when available—these are divergent back semantics on the same screen, which is an interaction inconsistency introduced by this change and arguably falls under preserving accessibility and interaction semantics. However, this is somewhat borderline since the usage and pull-requests footer also navigate back to "/" in the same way, and the check defaults to failure with instructions to report only concrete violations. There's also a conflict between the instruction to respond with "All clear" when there are no findings versus the requirement to output JSON matching the schema—the schema takes precedence, so I need to output JSON that reflects the findings appropriately. Let me dig deeper into whether this back-button inconsistency is actually a reportable violation by checking if there's test coverage for the footer behavior and examining the git history to understand the original intent behind the handleBackClick implementation. Looking at the sidebar footer implementation across different commits to understand how it behaves on the project settings page — it renders consistently regardless of route. The Back button styling matches the standard menu item usage, so there's no size mismatch to worry about. The real question is whether there's an actual UI regression: on mobile, removing the Settings icon means users can't navigate to settings from the sidebar while viewing a project settings page, but that's consistent with how usage and pull-requests pages work. The more interesting divergence is that the footer Back button always goes to "/" while Escape handlers elsewhere use history.back() — but I need to check if that's a pre-existing pattern in the usage and pull-requests pages before concluding it's a new issue. I'm noticing an inconsistency in how the back navigation works across settings pages. The established pattern uses history.back() when possible, falling back to "/" otherwise — that's what the Escape handler and sidebar back button do. But the new footer back button for project settings is hardcoding "/" directly, which breaks that consistency and diverges from the sidebar's own back affordance. The fix would be to align the footer back with the existing convention by checking if we can go back in history first, then falling back to "/" — either globally in handleBackClick or scoped to project settings. I should be careful about changing handleBackClick broadly since it's used for usage and pull-requests pages too, so the safest approach is to match what SettingsSidebarNav already does. I'm debating whether this is a consistency issue serious enough to fail the check — it's moderate, not a hard regression, but given the check defaults to failure and there's a clear finding, I'm leaning toward flagging it. I'll write a focused inline comment on the divergent back destination and describe the fix without a full diff since it spans multiple changes.

1. modify_pr — One finding: the footer Back added for project settings uses a different back destination than the project settings surface's own back behavior.


Agent Credits: 90 credits