Skip to content

feat: specialized linear layout and voltage alignment for decoupling capacitors (#15)#111

Open
Dhuijax wants to merge 1 commit into
tscircuit:mainfrom
Dhuijax:main
Open

feat: specialized linear layout and voltage alignment for decoupling capacitors (#15)#111
Dhuijax wants to merge 1 commit into
tscircuit:mainfrom
Dhuijax:main

Conversation

@Dhuijax
Copy link
Copy Markdown

@Dhuijax Dhuijax commented May 25, 2026

Summary

This PR implements a specialized layout and rotation alignment strategy for decoupling capacitors in partitions of type decoupling_caps (resolving #15).

Changes

  • Specialized Decoupling Capacitor Layout:
    • Bypassed the generic PackSolver2 for decoupling_caps partitions.
    • Arranged capacitors in a horizontally aligned, centered single row around the origin.
    • Used decouplingCapsGap (falling back to chipGap) to control spacing.
  • Voltage Alignment Optimization:
    • Dynamically resolved each capacitor's positive-voltage connection pin.
    • Aligned cap rotations (0° or 180°) so all VCC/positive-voltage connection pins consistently face the same side (y+ by default, or optimized by majority vote of the natural orientation).
  • Test Suite & Tooling Integration:
    • Added new comprehensive unit tests under tests/PackInnerPartitionsSolver/DecouplingCapsLayout.test.ts.
    • Resolved IdentifyDecouplingCapsSolver06.test.ts dynamic import & mock issues for the browser/UI schematic dependency.
    • Added bun-types configuration to tsconfig.json for compilation compatibility.

Verification Results

Ran standard bun test and verified all 21 test cases passed perfectly. Master checklist validated successfully with no security, lint, or UX warnings.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 25, 2026

@Dhuijax is attempting to deploy a commit to the tscircuit Team on Vercel.

A member of the Team first needs to authorize it.

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