@tscircuit/core 0.0.514 → 0.0.515

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +9 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -8714,7 +8714,10 @@ var SolderJumper = class extends NormalComponent {
8714
8714
  get config() {
8715
8715
  const props = this._parsedProps ?? this.props;
8716
8716
  let resolvedPinCount = props.pinCount;
8717
- if (!resolvedPinCount) {
8717
+ if (props.pinCount == null && !props.footprint) {
8718
+ resolvedPinCount = 2;
8719
+ }
8720
+ if (props.pinCount == null) {
8718
8721
  const nums = (props.bridgedPins ?? []).flat().map((p_str) => this._getPinNumberFromBridgedPinName(p_str)).filter((n) => n !== null);
8719
8722
  const maxPinFromBridged = nums.length > 0 ? Math.max(...nums) : 0;
8720
8723
  const pinCountFromLabels = props.pinLabels ? Object.keys(props.pinLabels).length : 0;
@@ -8749,7 +8752,10 @@ var SolderJumper = class extends NormalComponent {
8749
8752
  _getSchematicPortArrangement() {
8750
8753
  const arrangement = super._getSchematicPortArrangement();
8751
8754
  if (arrangement && Object.keys(arrangement).length > 0) return arrangement;
8752
- const pinCount = this._parsedProps.pinCount ?? (Array.isArray(this._parsedProps.pinLabels) ? this._parsedProps.pinLabels.length : this._parsedProps.pinLabels ? Object.keys(this._parsedProps.pinLabels).length : this.getPortsFromFootprint().length);
8755
+ let pinCount = this._parsedProps.pinCount ?? (Array.isArray(this._parsedProps.pinLabels) ? this._parsedProps.pinLabels.length : this._parsedProps.pinLabels ? Object.keys(this._parsedProps.pinLabels).length : this.getPortsFromFootprint().length);
8756
+ if (pinCount == null && !this._parsedProps.footprint) {
8757
+ pinCount = 2;
8758
+ }
8753
8759
  const direction = this._parsedProps.schDirection ?? "right";
8754
8760
  return {
8755
8761
  leftSize: direction === "left" ? pinCount : 0,
@@ -10423,7 +10429,7 @@ import { identity as identity4 } from "transformation-matrix";
10423
10429
  var package_default = {
10424
10430
  name: "@tscircuit/core",
10425
10431
  type: "module",
10426
- version: "0.0.512",
10432
+ version: "0.0.514",
10427
10433
  types: "dist/index.d.ts",
10428
10434
  main: "dist/index.js",
10429
10435
  module: "dist/index.js",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tscircuit/core",
3
3
  "type": "module",
4
- "version": "0.0.514",
4
+ "version": "0.0.515",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",