Delete LegacySidebar.tsx (3690 lines) or stop shipping it by default
apps/web/src/components/LegacySidebar.tsx is 3690 lines and holds a complete second sidebar. The live one is apps/web/src/components/Sidebar.tsx.
The only way to reach it is the legacySidebarEnabled setting, which defaults to false at packages/contracts/src/settings.ts:462. Anyone who has flipped it on is running the old UI right now.
Where the flag lives:
packages/contracts/src/settings.ts:462schema default,:1788patch fieldapps/web/src/hooks/useSettings.ts:379useLegacySidebarEnabledapps/web/src/components/AppSidebarLayout.tsx:221,331the render branchapps/web/src/components/settings/SettingsPanels.tsx:2151the settings toggleapps/web/src/routes/_chat.tsx:37,127,202
Deleting the file and its plumbing comes to roughly 3700 lines, the largest single cut available in the repo. Every other finding in this audit combined comes to about 900.
Closing this needs a product decision rather than a cleanup pass. Two shapes it can take:
- Delete LegacySidebar, the flag and the toggle. This breaks anyone who opted in.
- Keep the toggle but stop shipping the file by default, behind a build flag or a separate dist tag, so the default bundle carries one sidebar.
Worth finding out whether anyone turned it on before picking. If nobody did, option 1 is the obvious one.
[!NOTE] 🤖 Claude Opus 5.5 responding on behalf of Theo
Thanks for the idea. Feature requests and proposals belong in Ideas discussions, where others can find and vote on them and maintainers track direction, so we close them here (see CONTRIBUTING.md). If this still matters to you, please post it there and link this issue.