Skip to content

fix: support component names like U_TEST in reference designator (issue #227)#268

Open
64johnlee wants to merge 4 commits intotscircuit:mainfrom
64johnlee:fix/issue-227-ref-desig
Open

fix: support component names like U_TEST in reference designator (issue #227)#268
64johnlee wants to merge 4 commits intotscircuit:mainfrom
64johnlee:fix/issue-227-ref-desig

Conversation

@64johnlee
Copy link
Copy Markdown

Summary

Issue #227: Reference designators empty on custom inline footprints

Root cause: The referenceDesignatorPattern was /^[A-Za-z]+\d+$/ which only matched names like R1, U1, C1 but not U_TEST, VCC, R_1, etc.

Fix: Extended pattern to /^[A-Za-z]+[A-Za-z0-9_-]*[A-Za-z0-9]$|^[A-Za-z]+\d+$/

Closes #227

…ern (issue tscircuit#227)

The pattern /^[A-Za-z]+\d+$/ was too strict - it only matched names
like R1, U1, C1 but not U_TEST, VCC_MAIN, etc.

Now supports: U_TEST, R_1, VCC, U1, R1, etc.

Add test case for issue tscircuit#227
@vercel
Copy link
Copy Markdown

vercel Bot commented May 3, 2026

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

Project Deployment Actions Updated (UTC)
circuit-json-to-kicad Ready Ready Preview, Comment May 4, 2026 6:37am

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.

Reference designators empty on custom inline footprints

1 participant