repro(svg): Elk Pi polygon cutout is painted over copper - #132
Closed
KrishnaX12 wants to merge 1 commit into
Closed
Conversation
|
@KrishnaX12 is attempting to deploy a commit to the tscircuit Team on Vercel. A member of the Team first needs to authorize it. |
KrishnaX12
force-pushed
the
repro/board-and-polygon-cutout-clipping
branch
from
September 4, 2026 16:00
2f929c6 to
11d57ac
Compare
Contributor
Author
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
PCB polygon and board cutouts are rendered as board-colored shapes painted over copper instead of being subtracted from copper geometry.
This makes the result look correct only while the overlay remains visible. The underlying copper pour is still continuous across the forbidden area, so layer visibility, opacity, ordering, and downstream SVG use expose solid copper where a real opening should exist.
Real-board reproduction
This PR strengthens the existing Elk Pi real-board regression in:
references/elk-pi.PcbDoctests/svg/elk-pi-polygon-cutout-detail.test.tstests/svg/__snapshots__/elk-pi-polygon-cutout-detail.snap.svgThe selected crop naturally contains filled top-copper pour regions overlapping a multilayer
POLYGON_CUTOUT.The test and snapshot record the current broken behavior:
fill="#123d32"board-colored path.The existing snapshot is included in this PR with reproduction-specific SVG title and accessibility metadata. No synthetic board, new fixture, or duplicate snapshot is added.
Expected behavior
Board cutouts, polygon cutouts, and relevant keepout geometry should be subtracted from copper pours. The resulting copper path should contain a genuine hole, normally represented by combined path geometry with an appropriate fill rule, instead of relying on a board-colored patch.
Testing
schematic-component-value-reference.test.ts.