@tscircuit/core 0.0.195 → 0.0.197

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 +5 -5
  2. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -4621,7 +4621,7 @@ var Chip = class extends NormalComponent {
4621
4621
  supplier_part_numbers: props.supplierPartNumbers
4622
4622
  });
4623
4623
  const dimensions = this._getSchematicBoxDimensions();
4624
- const hasOnlyLeftAndRightPins = props.schPortArrangement?.topSide !== void 0 && props.schPortArrangement?.bottomSide !== void 0;
4624
+ const hasTopOrBottomPins = props.schPortArrangement?.topSide !== void 0 || props.schPortArrangement?.bottomSide !== void 0;
4625
4625
  const schematic_box_width = dimensions?.getSize().width;
4626
4626
  const schematic_box_height = dimensions?.getSize().height;
4627
4627
  const manufacturer_part_number_text = db.schematic_text.insert({
@@ -4630,8 +4630,8 @@ var Chip = class extends NormalComponent {
4630
4630
  anchor: "left",
4631
4631
  rotation: 0,
4632
4632
  position: {
4633
- x: hasOnlyLeftAndRightPins ? (props.schX ?? 0) + (schematic_box_width ?? 0) / 2 : (props.schX ?? 0) - (schematic_box_width ?? 0) / 2,
4634
- y: hasOnlyLeftAndRightPins ? (props.schY ?? 0) + (schematic_box_height ?? 0) / 2 + 0.55 : (props.schY ?? 0) - (schematic_box_height ?? 0) / 2 - 0.13
4633
+ x: hasTopOrBottomPins ? (props.schX ?? 0) + (schematic_box_width ?? 0) / 2 + 0.1 : (props.schX ?? 0) - (schematic_box_width ?? 0) / 2,
4634
+ y: hasTopOrBottomPins ? (props.schY ?? 0) + (schematic_box_height ?? 0) / 2 + 0.35 : (props.schY ?? 0) - (schematic_box_height ?? 0) / 2 - 0.13
4635
4635
  },
4636
4636
  color: "#006464"
4637
4637
  });
@@ -4641,8 +4641,8 @@ var Chip = class extends NormalComponent {
4641
4641
  anchor: "left",
4642
4642
  rotation: 0,
4643
4643
  position: {
4644
- x: hasOnlyLeftAndRightPins ? (props.schX ?? 0) + (schematic_box_width ?? 0) / 2 : (props.schX ?? 0) - (schematic_box_width ?? 0) / 2,
4645
- y: hasOnlyLeftAndRightPins ? (props.schY ?? 0) + (schematic_box_height ?? 0) / 2 + 0.35 : (props.schY ?? 0) + (schematic_box_height ?? 0) / 2 + 0.13
4644
+ x: hasTopOrBottomPins ? (props.schX ?? 0) + (schematic_box_width ?? 0) / 2 + 0.1 : (props.schX ?? 0) - (schematic_box_width ?? 0) / 2,
4645
+ y: hasTopOrBottomPins ? (props.schY ?? 0) + (schematic_box_height ?? 0) / 2 + 0.55 : (props.schY ?? 0) + (schematic_box_height ?? 0) / 2 + 0.13
4646
4646
  },
4647
4647
  color: "#006464"
4648
4648
  });
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tscircuit/core",
3
3
  "type": "module",
4
- "version": "0.0.195",
4
+ "version": "0.0.197",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",
@@ -26,6 +26,7 @@
26
26
  "@types/react": "^18.3.3",
27
27
  "@types/react-reconciler": "^0.28.8",
28
28
  "bun-match-svg": "0.0.2",
29
+ "circuit-to-svg": "^0.0.84",
29
30
  "debug": "^4.3.6",
30
31
  "howfat": "^0.3.8",
31
32
  "looks-same": "^9.0.1",
@@ -45,7 +46,6 @@
45
46
  "@tscircuit/soup-util": "^0.0.40",
46
47
  "circuit-json": "^0.0.104",
47
48
  "circuit-json-to-connectivity-map": "^0.0.17",
48
- "circuit-to-svg": "^0.0.82",
49
49
  "format-si-unit": "^0.0.2",
50
50
  "nanoid": "^5.0.7",
51
51
  "performance-now": "^2.1.0",