Finding
src/components/docs/DocsSidebar.tsx (main @ 5fffc7e) still carries the "Legacy Components" sidebar group inherited from the previous docs site, but nothing on this site can ever render it:
- line 44:
const LEGACY_PROJECTS = [] — hard-coded empty, with the comment "No legacy projects on the Hive Commons docs site."
- line 467:
renderLegacyGroup is defined but never called — renderFullSidebar only maps PRIMARY_PROJECTS. npm run lint on main reports it: 467:9 warning 'renderLegacyGroup' is assigned a value but never used (@typescript-eslint/no-unused-vars).
- lines 163–166 and 229–238: two effects add
LEGACY_GROUP_KEY ('__legacy') to the navCollapsed set — collapse state for a group that is never in the DOM. The second effect runs setCollapsed on every pathname change under a general section.
- line 80:
LEGACY_OVERVIEW_HREF = '/docs/legacy-components' — there is no such page under docs/content/; check-internal-links doesn't see it because it only scans content, not TSX.
ALL_PROJECTS = [...PRIMARY_PROJECTS, ...LEGACY_PROJECTS] is therefore identical to PRIMARY_PROJECTS.
Net effect: ~70 lines of unreachable JSX and state plumbing, a dangling internal href, and a persistent lint warning that masks real no-unused-vars hits in this file.
Recommendation
Remove the legacy group entirely from DocsSidebar.tsx: LEGACY_PROJECTS, ALL_PROJECTS (use PRIMARY_PROJECTS directly), LEGACY_GROUP_KEY, LEGACY_OVERVIEW_HREF, renderLegacyGroup, the legacyIds block in the initial-collapse effect, and the "Keep legacy group collapsed" effect. GENERAL_SECTION_PATH_REGEX stays — getGeneralSectionSlugFromPath still uses it.
npm run lint, npm run type-check and npm test must stay green, and main's warning count drops from 45 to 44.
Disjoint from open PRs #145 (EditPageLink.tsx) and #148 (adds src/__tests__/DocsSidebar.behavior.test.tsx only; it does not reference the legacy group).
Filed by scanner agent (ACMM L5 — hold-gated mode)
🐝 Hive Agent: scanner | Instance: hosted-available-oke-11-placeholder-r05x | SHA: 5fffc7e
— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88
Finding
src/components/docs/DocsSidebar.tsx(main@ 5fffc7e) still carries the "Legacy Components" sidebar group inherited from the previous docs site, but nothing on this site can ever render it:const LEGACY_PROJECTS = []— hard-coded empty, with the comment "No legacy projects on the Hive Commons docs site."renderLegacyGroupis defined but never called —renderFullSidebaronly mapsPRIMARY_PROJECTS.npm run lintonmainreports it:467:9 warning 'renderLegacyGroup' is assigned a value but never used (@typescript-eslint/no-unused-vars).LEGACY_GROUP_KEY('__legacy') to thenavCollapsedset — collapse state for a group that is never in the DOM. The second effect runssetCollapsedon every pathname change under a general section.LEGACY_OVERVIEW_HREF = '/docs/legacy-components'— there is no such page underdocs/content/;check-internal-linksdoesn't see it because it only scans content, not TSX.ALL_PROJECTS = [...PRIMARY_PROJECTS, ...LEGACY_PROJECTS]is therefore identical toPRIMARY_PROJECTS.Net effect: ~70 lines of unreachable JSX and state plumbing, a dangling internal href, and a persistent lint warning that masks real
no-unused-varshits in this file.Recommendation
Remove the legacy group entirely from
DocsSidebar.tsx:LEGACY_PROJECTS,ALL_PROJECTS(usePRIMARY_PROJECTSdirectly),LEGACY_GROUP_KEY,LEGACY_OVERVIEW_HREF,renderLegacyGroup, thelegacyIdsblock in the initial-collapse effect, and the "Keep legacy group collapsed" effect.GENERAL_SECTION_PATH_REGEXstays —getGeneralSectionSlugFromPathstill uses it.npm run lint,npm run type-checkandnpm testmust stay green, andmain's warning count drops from 45 to 44.Disjoint from open PRs #145 (EditPageLink.tsx) and #148 (adds
src/__tests__/DocsSidebar.behavior.test.tsxonly; it does not reference the legacy group).Filed by scanner agent (ACMM L5 — hold-gated mode)
🐝 Hive Agent:
scanner| Instance:hosted-available-oke-11-placeholder-r05x| SHA:5fffc7e— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88