Skip to content

fix: restore same-net schematic trace hover grouping#212

Open
AlissonBecker1 wants to merge 1 commit into
tscircuit:mainfrom
AlissonBecker1:fix-trace-hover-connectivity-keys
Open

fix: restore same-net schematic trace hover grouping#212
AlissonBecker1 wants to merge 1 commit into
tscircuit:mainfrom
AlissonBecker1:fix-trace-hover-connectivity-keys

Conversation

@AlissonBecker1
Copy link
Copy Markdown

@AlissonBecker1 AlissonBecker1 commented May 22, 2026

Summary

  • derive schematic trace hover groups from trace geometry plus source/schematic port connectivity keys
  • add subcircuit_connectivity_map_key to schematic traces before SVG conversion so the existing circuit-to-svg same-net hover CSS can apply
  • add focused coverage for rendered traces, chained segments, disconnected same-net segments, and geometric fallback grouping
  • add a small fixture for quick manual hover verification

Fixes tscircuit/tscircuit#1130

Verification

  • bun test tests/connected-schematic-trace-groups.test.tsx
  • bunx tsc --noEmit
  • bun run build
  • bunx biome check lib/components/SchematicViewer.tsx lib/utils/getConnectedSchematicTraceGroups.ts tests/connected-schematic-trace-groups.test.tsx examples/example21-connected-trace-hover.fixture.tsx
  • git diff --check

@vercel
Copy link
Copy Markdown

vercel Bot commented May 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
schematic-viewer Ready Ready Preview, Comment May 22, 2026 8:16pm

Request Review

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.

Change of color on hover for traces are missing

1 participant