Skip to content

fix(dashboard): prune dead #quotes/#images evidence nav anchors#228

Merged
BigSimmo merged 2 commits into
mainfrom
claude/prune-dead-evidence-nav
Jul 3, 2026
Merged

fix(dashboard): prune dead #quotes/#images evidence nav anchors#228
BigSimmo merged 2 commits into
mainfrom
claude/prune-dead-evidence-nav

Conversation

@BigSimmo

@BigSimmo BigSimmo commented Jul 3, 2026

Copy link
Copy Markdown
Owner

What

The section-jump nav in ClinicalDashboard had two dead anchors: #quotes and #images. Clicking them was a no-op and they polluted the scroll-spy.

Why

The evidence UI was redesigned into UnifiedEvidenceDrawerContent — a drawer with its own in-panel pill nav (aria-label="Evidence sections"). That redesign dropped the #quotes / #images section ids, but the top nav never caught up:

  • navigationHashes, the scroll-spy sections list, and the Quotes/Images nav items still referenced #quotes / #images
  • The nav scrolls via document.getElementById(hash)?.scrollIntoView(...) → those ids no longer exist → silent no-op
  • Only #sources still resolves to a real anchor

Discovered during a repo-wide DOM/accessibility audit. (The audit's other output — 10 unlabeled form-control aria-labels — was already fixed on main via #215, so this PR is only the nav cleanup.)

Changes

  • Drop #quotes / #images from navigationHashes and the scroll-spy sections list
  • Remove the now-dead Quotes and Images nav items (Search + Sources remain)
  • Remove the orphaned visualEvidence memo (only the Images item consumed it)
  • Strip the leftover id="images" from VisualEvidenceStrip's two non-embedded return branches — never rendered (all call sites pass embedded) but a latent duplicate-id hazard

Net: +4 / −25, one file.

Testing

  • tsc --noEmit — clean (the navigationHashes as const union narrowed from 4→2 members with no downstream breakage)
  • eslint on the file — 0 errors, no new warnings
  • No Playwright/unit test references #quotes / #images or the removed nav labels

Clinical governance

UI-only navigation cleanup. Does not touch ingestion, answer generation, search/ranking, source rendering, document access, privacy, or clinical output — governance preflight N/A.

🤖 Generated with Claude Code

BigSimmo and others added 2 commits July 3, 2026 16:20
The evidence UI was redesigned into UnifiedEvidenceDrawerContent (a drawer
with its own in-panel pill nav), which dropped the #quotes and #images
section ids. The top section-jump nav (navigationHashes), its scroll-spy,
and the Quotes/Images nav items still referenced those hashes, so both were
dead jump targets: getElementById returns null and the scroll is a no-op.

- Drop #quotes/#images from navigationHashes and the scroll-spy section list
- Remove the now-dead Quotes/Images nav items (Search + Sources remain)
- Remove the orphaned visualEvidence memo (only the Images item consumed it)
- Strip the leftover id="images" from VisualEvidenceStrip's two non-embedded
  return branches (never rendered since all call sites pass embedded, but a
  latent duplicate-id hazard)

typecheck + eslint clean; no new warnings.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Removing id="images" shortened the VisualEvidenceStrip default-branch
<section> enough for prettier to collapse it onto one line. Fixes the
format:check verify gate.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@BigSimmo
BigSimmo merged commit a2c30af into main Jul 3, 2026
4 checks passed
@BigSimmo
BigSimmo deleted the claude/prune-dead-evidence-nav branch July 3, 2026 08:43
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.

1 participant