@tscircuit/core 0.0.828 → 0.0.829

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 +63 -52
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -86,7 +86,7 @@ __export(components_exports, {
86
86
  // lib/components/base-components/NormalComponent/NormalComponent.ts
87
87
  import { fp } from "@tscircuit/footprinter";
88
88
  import {
89
- distance as distance4,
89
+ distance as distance5,
90
90
  pcb_manual_edit_conflict_warning,
91
91
  pcb_component_invalid_layer_error,
92
92
  point3 as point32,
@@ -1844,7 +1844,10 @@ var createNetsFromProps = (component, props) => {
1844
1844
 
1845
1845
  // lib/components/primitive-components/SmtPad.ts
1846
1846
  import { smtPadProps } from "@tscircuit/props";
1847
- import { decomposeTSR } from "transformation-matrix";
1847
+ import {
1848
+ distance
1849
+ } from "circuit-json";
1850
+ import { applyToPoint as applyToPoint2, decomposeTSR } from "transformation-matrix";
1848
1851
  var SmtPad = class extends PrimitiveComponent2 {
1849
1852
  pcb_smtpad_id = null;
1850
1853
  matchedPort = null;
@@ -1913,6 +1916,7 @@ var SmtPad = class extends PrimitiveComponent2 {
1913
1916
  if (!props.portHints) return;
1914
1917
  const subcircuit = this.getSubcircuit();
1915
1918
  const position = this._getGlobalPcbPositionBeforeLayout();
1919
+ const globalTransform = this._computePcbGlobalTransformBeforeLayout();
1916
1920
  const decomposedTransform = decomposeTSR(
1917
1921
  this._computePcbGlobalTransformBeforeLayout()
1918
1922
  );
@@ -2056,16 +2060,23 @@ var SmtPad = class extends PrimitiveComponent2 {
2056
2060
  pcb_group_id: this.getGroup()?.pcb_group_id ?? void 0
2057
2061
  });
2058
2062
  } else if (props.shape === "polygon") {
2063
+ const transformedPoints = props.points.map((point) => {
2064
+ const transformed = applyToPoint2(globalTransform, {
2065
+ x: distance.parse(point.x),
2066
+ y: distance.parse(point.y)
2067
+ });
2068
+ return {
2069
+ x: transformed.x,
2070
+ y: transformed.y
2071
+ };
2072
+ });
2059
2073
  pcb_smtpad = db.pcb_smtpad.insert({
2060
2074
  pcb_component_id,
2061
2075
  pcb_port_id: this.matchedPort?.pcb_port_id,
2062
2076
  // port likely isn't matched
2063
2077
  layer: maybeFlipLayer(props.layer ?? "top"),
2064
2078
  shape: "polygon",
2065
- points: props.points.map((p) => ({
2066
- x: p.x + position.x,
2067
- y: p.y + position.y
2068
- })),
2079
+ points: transformedPoints,
2069
2080
  port_hints: props.portHints.map((ph) => ph.toString()),
2070
2081
  is_covered_with_solder_mask: isCoveredWithSolderMask,
2071
2082
  subcircuit_id: subcircuit?.subcircuit_id ?? void 0,
@@ -2207,7 +2218,7 @@ var SmtPad = class extends PrimitiveComponent2 {
2207
2218
 
2208
2219
  // lib/components/primitive-components/SilkscreenPath.ts
2209
2220
  import { silkscreenPathProps } from "@tscircuit/props";
2210
- import { applyToPoint as applyToPoint2 } from "transformation-matrix";
2221
+ import { applyToPoint as applyToPoint3 } from "transformation-matrix";
2211
2222
  var SilkscreenPath = class extends PrimitiveComponent2 {
2212
2223
  pcb_silkscreen_path_id = null;
2213
2224
  isPcbPrimitive = true;
@@ -2235,7 +2246,7 @@ var SilkscreenPath = class extends PrimitiveComponent2 {
2235
2246
  pcb_component_id,
2236
2247
  layer,
2237
2248
  route: props.route.map((p) => {
2238
- const transformedPosition = applyToPoint2(transform, {
2249
+ const transformedPosition = applyToPoint3(transform, {
2239
2250
  x: p.x,
2240
2251
  y: p.y
2241
2252
  });
@@ -2297,7 +2308,7 @@ var SilkscreenPath = class extends PrimitiveComponent2 {
2297
2308
  // lib/components/primitive-components/PcbTrace.ts
2298
2309
  import { z as z5 } from "zod";
2299
2310
  import { pcb_trace_route_point } from "circuit-json";
2300
- import { applyToPoint as applyToPoint3 } from "transformation-matrix";
2311
+ import { applyToPoint as applyToPoint4 } from "transformation-matrix";
2301
2312
  var pcbTraceProps = z5.object({
2302
2313
  route: z5.array(pcb_trace_route_point),
2303
2314
  // If this primitive PcbTrace needs to be associated with a source_trace_id
@@ -2323,7 +2334,7 @@ var PcbTrace = class extends PrimitiveComponent2 {
2323
2334
  const parentTransform = this._computePcbGlobalTransformBeforeLayout();
2324
2335
  const transformedRoute = props.route.map((point) => {
2325
2336
  const { x, y, ...restOfPoint } = point;
2326
- const transformedPoint = applyToPoint3(parentTransform, { x, y });
2337
+ const transformedPoint = applyToPoint4(parentTransform, { x, y });
2327
2338
  if (point.route_type === "wire" && point.layer) {
2328
2339
  return {
2329
2340
  ...transformedPoint,
@@ -2810,7 +2821,7 @@ var SilkscreenText = class extends PrimitiveComponent2 {
2810
2821
  };
2811
2822
 
2812
2823
  // lib/components/primitive-components/Cutout.ts
2813
- import { applyToPoint as applyToPoint4 } from "transformation-matrix";
2824
+ import { applyToPoint as applyToPoint5 } from "transformation-matrix";
2814
2825
  import { cutoutProps } from "@tscircuit/props";
2815
2826
  var Cutout = class extends PrimitiveComponent2 {
2816
2827
  pcb_cutout_id = null;
@@ -2855,7 +2866,7 @@ var Cutout = class extends PrimitiveComponent2 {
2855
2866
  } else if (props.shape === "polygon") {
2856
2867
  const transform = this._computePcbGlobalTransformBeforeLayout();
2857
2868
  const transformedPoints = props.points.map(
2858
- (p) => applyToPoint4(transform, p)
2869
+ (p) => applyToPoint5(transform, p)
2859
2870
  );
2860
2871
  const polygonData = {
2861
2872
  shape: "polygon",
@@ -3411,7 +3422,7 @@ function getRelativeDirection(pointA, pointB) {
3411
3422
 
3412
3423
  // lib/components/primitive-components/Port/Port.ts
3413
3424
  import "schematic-symbols";
3414
- import { applyToPoint as applyToPoint5, compose as compose3, translate as translate3 } from "transformation-matrix";
3425
+ import { applyToPoint as applyToPoint6, compose as compose3, translate as translate3 } from "transformation-matrix";
3415
3426
  import { z as z6 } from "zod";
3416
3427
 
3417
3428
  // lib/components/primitive-components/Port/areAllPcbPrimitivesOverlapping.ts
@@ -3610,7 +3621,7 @@ var Port = class extends PrimitiveComponent2 {
3610
3621
  parentNormalComponent.computeSchematicGlobalTransform(),
3611
3622
  translate3(-symbol.center.x, -symbol.center.y)
3612
3623
  );
3613
- return applyToPoint5(transform, schematicSymbolPortDef);
3624
+ return applyToPoint6(transform, schematicSymbolPortDef);
3614
3625
  }
3615
3626
  const parentBoxDim = parentNormalComponent?._getSchematicBoxDimensions();
3616
3627
  if (parentBoxDim && this.props.pinNumber !== void 0) {
@@ -3622,7 +3633,7 @@ var Port = class extends PrimitiveComponent2 {
3622
3633
  `Couldn't find position for schematic_port for port ${this.getString()} inside of the schematic box`
3623
3634
  );
3624
3635
  }
3625
- return applyToPoint5(
3636
+ return applyToPoint6(
3626
3637
  parentNormalComponent.computeSchematicGlobalTransform(),
3627
3638
  localPortPosition
3628
3639
  );
@@ -4450,7 +4461,7 @@ var Footprint = class extends PrimitiveComponent2 {
4450
4461
  // lib/components/primitive-components/CadModel.ts
4451
4462
  import { cadmodelProps, point3 } from "@tscircuit/props";
4452
4463
  import { z as z7 } from "zod";
4453
- import { distance } from "circuit-json";
4464
+ import { distance as distance2 } from "circuit-json";
4454
4465
  import { decomposeTSR as decomposeTSR4 } from "transformation-matrix";
4455
4466
 
4456
4467
  // lib/components/base-components/NormalComponent/utils/getFileExtension.ts
@@ -4527,7 +4538,7 @@ var CadModel = class extends PrimitiveComponent2 {
4527
4538
  z: props.pcbZ ?? 0,
4528
4539
  ...typeof props.positionOffset === "object" ? props.positionOffset : {}
4529
4540
  });
4530
- const zOffsetFromSurface = props.zOffsetFromSurface !== void 0 ? distance.parse(props.zOffsetFromSurface) : 0;
4541
+ const zOffsetFromSurface = props.zOffsetFromSurface !== void 0 ? distance2.parse(props.zOffsetFromSurface) : 0;
4531
4542
  const layer = parent.props.layer === "bottom" ? "bottom" : "top";
4532
4543
  const ext = props.modelUrl ? getFileExtension(props.modelUrl) : void 0;
4533
4544
  const urlProps = {};
@@ -4840,7 +4851,7 @@ var getEnteringEdgeFromDirection = (direction) => {
4840
4851
  };
4841
4852
 
4842
4853
  // lib/utils/schematic/getStubEdges.ts
4843
- import { distance as distance2 } from "@tscircuit/math-utils";
4854
+ import { distance as distance3 } from "@tscircuit/math-utils";
4844
4855
  var getStubEdges = ({
4845
4856
  firstEdge,
4846
4857
  firstEdgePort,
@@ -4887,7 +4898,7 @@ var getStubEdges = ({
4887
4898
  });
4888
4899
  }
4889
4900
  }
4890
- edges = edges.filter((e) => distance2(e.from, e.to) > 0.01);
4901
+ edges = edges.filter((e) => distance3(e.from, e.to) > 0.01);
4891
4902
  return edges;
4892
4903
  };
4893
4904
 
@@ -5390,7 +5401,7 @@ import { calculateElbow } from "calculate-elbow";
5390
5401
  import { doesLineIntersectLine as doesLineIntersectLine3 } from "@tscircuit/math-utils";
5391
5402
 
5392
5403
  // lib/components/primitive-components/Trace/trace-utils/create-schematic-trace-crossing-segments.ts
5393
- import { distance as distance3, doesLineIntersectLine } from "@tscircuit/math-utils";
5404
+ import { distance as distance4, doesLineIntersectLine } from "@tscircuit/math-utils";
5394
5405
 
5395
5406
  // lib/components/primitive-components/Trace/trace-utils/get-other-schematic-traces.ts
5396
5407
  var getOtherSchematicTraces = ({
@@ -5457,7 +5468,7 @@ var createSchematicTraceCrossingSegments = ({
5457
5468
  otherEdgesIntersections.push({
5458
5469
  otherEdge,
5459
5470
  crossingPoint: crossingPoint2,
5460
- distanceFromEdgeFrom: distance3(edge.from, crossingPoint2)
5471
+ distanceFromEdgeFrom: distance4(edge.from, crossingPoint2)
5461
5472
  });
5462
5473
  }
5463
5474
  }
@@ -5482,7 +5493,7 @@ var createSchematicTraceCrossingSegments = ({
5482
5493
  x: crossingPoint.x + crossingUnitVec.x * crossingSegmentLength / 2,
5483
5494
  y: crossingPoint.y + crossingUnitVec.y * crossingSegmentLength / 2
5484
5495
  };
5485
- const overshot = distance3(afterCrossing, edge.to) < crossingSegmentLength;
5496
+ const overshot = distance4(afterCrossing, edge.to) < crossingSegmentLength;
5486
5497
  const newEdges = [
5487
5498
  { from: edge.from, to: beforeCrossing },
5488
5499
  { from: beforeCrossing, to: afterCrossing, is_crossing: true },
@@ -6411,7 +6422,7 @@ function Trace_doInitialPcbTraceRender(trace) {
6411
6422
  }
6412
6423
 
6413
6424
  // lib/components/primitive-components/Trace/Trace_doInitialPcbManualTraceRender.ts
6414
- import { applyToPoint as applyToPoint6, identity as identity3 } from "transformation-matrix";
6425
+ import { applyToPoint as applyToPoint7, identity as identity3 } from "transformation-matrix";
6415
6426
  function Trace_doInitialPcbManualTraceRender(trace) {
6416
6427
  if (trace.root?.pcbDisabled) return;
6417
6428
  const { db } = trace.root;
@@ -6489,7 +6500,7 @@ function Trace_doInitialPcbManualTraceRender(trace) {
6489
6500
  coordinates = { x: pt.x, y: pt.y };
6490
6501
  isGlobalPosition = false;
6491
6502
  }
6492
- const finalCoordinates = isGlobalPosition ? coordinates : applyToPoint6(transform, coordinates);
6503
+ const finalCoordinates = isGlobalPosition ? coordinates : applyToPoint7(transform, coordinates);
6493
6504
  route.push({
6494
6505
  route_type: "wire",
6495
6506
  x: finalCoordinates.x,
@@ -8447,7 +8458,7 @@ var NormalComponent3 = class extends PrimitiveComponent2 {
8447
8458
  z: 0,
8448
8459
  ...typeof cadModel?.positionOffset === "object" ? cadModel.positionOffset : {}
8449
8460
  });
8450
- const zOffsetFromSurface = cadModel && typeof cadModel === "object" && "zOffsetFromSurface" in cadModel ? cadModel.zOffsetFromSurface !== void 0 ? distance4.parse(
8461
+ const zOffsetFromSurface = cadModel && typeof cadModel === "object" && "zOffsetFromSurface" in cadModel ? cadModel.zOffsetFromSurface !== void 0 ? distance5.parse(
8451
8462
  cadModel.zOffsetFromSurface
8452
8463
  ) : 0 : 0;
8453
8464
  const computedLayer = this.props.layer === "bottom" ? "bottom" : "top";
@@ -8861,14 +8872,14 @@ var CapacityMeshAutorouter = class {
8861
8872
 
8862
8873
  // lib/components/primitive-components/Group/Group.ts
8863
8874
  import {
8864
- distance as distance5
8875
+ distance as distance6
8865
8876
  } from "circuit-json";
8866
8877
  import Debug13 from "debug";
8867
8878
  import "zod";
8868
8879
 
8869
8880
  // lib/components/primitive-components/TraceHint.ts
8870
8881
  import { traceHintProps } from "@tscircuit/props";
8871
- import { applyToPoint as applyToPoint7 } from "transformation-matrix";
8882
+ import { applyToPoint as applyToPoint8 } from "transformation-matrix";
8872
8883
  var TraceHint = class extends PrimitiveComponent2 {
8873
8884
  matchedPort = null;
8874
8885
  get config() {
@@ -8908,7 +8919,7 @@ var TraceHint = class extends PrimitiveComponent2 {
8908
8919
  const globalTransform = this._computePcbGlobalTransformBeforeLayout();
8909
8920
  return offsets.map(
8910
8921
  (offset) => ({
8911
- ...applyToPoint7(globalTransform, offset),
8922
+ ...applyToPoint8(globalTransform, offset),
8912
8923
  via: offset.via,
8913
8924
  to_layer: offset.to_layer,
8914
8925
  trace_width: offset.trace_width
@@ -12793,8 +12804,8 @@ var Group6 = class extends NormalComponent3 {
12793
12804
  const groupProps2 = props;
12794
12805
  const hasOutline = groupProps2.outline && groupProps2.outline.length > 0;
12795
12806
  const numericOutline = hasOutline ? groupProps2.outline.map((point) => ({
12796
- x: distance5.parse(point.x),
12797
- y: distance5.parse(point.y)
12807
+ x: distance6.parse(point.x),
12808
+ y: distance6.parse(point.y)
12798
12809
  })) : void 0;
12799
12810
  const pcb_group = db.pcb_group.insert({
12800
12811
  is_subcircuit: this.isSubcircuit,
@@ -12824,8 +12835,8 @@ var Group6 = class extends NormalComponent3 {
12824
12835
  const hasExplicitPositioning = this._parsedProps.pcbX !== void 0 || this._parsedProps.pcbY !== void 0;
12825
12836
  if (hasOutline) {
12826
12837
  const numericOutline = props.outline.map((point) => ({
12827
- x: distance5.parse(point.x),
12828
- y: distance5.parse(point.y)
12838
+ x: distance6.parse(point.x),
12839
+ y: distance6.parse(point.y)
12829
12840
  }));
12830
12841
  const outlineBounds = getBoundsFromPoints3(numericOutline);
12831
12842
  if (!outlineBounds) return;
@@ -14895,7 +14906,7 @@ var FabricationNoteRect = class extends PrimitiveComponent2 {
14895
14906
 
14896
14907
  // lib/components/primitive-components/FabricationNotePath.ts
14897
14908
  import { fabricationNotePathProps } from "@tscircuit/props";
14898
- import { applyToPoint as applyToPoint9 } from "transformation-matrix";
14909
+ import { applyToPoint as applyToPoint10 } from "transformation-matrix";
14899
14910
  var FabricationNotePath = class extends PrimitiveComponent2 {
14900
14911
  fabrication_note_path_id = null;
14901
14912
  get config() {
@@ -14922,7 +14933,7 @@ var FabricationNotePath = class extends PrimitiveComponent2 {
14922
14933
  layer,
14923
14934
  color: props.color,
14924
14935
  route: props.route.map((p) => {
14925
- const transformedPosition = applyToPoint9(transform, {
14936
+ const transformedPosition = applyToPoint10(transform, {
14926
14937
  x: p.x,
14927
14938
  y: p.y
14928
14939
  });
@@ -14974,7 +14985,7 @@ var FabricationNoteText = class extends PrimitiveComponent2 {
14974
14985
 
14975
14986
  // lib/components/primitive-components/FabricationNoteDimension.ts
14976
14987
  import { fabricationNoteDimensionProps } from "@tscircuit/props";
14977
- import { applyToPoint as applyToPoint10 } from "transformation-matrix";
14988
+ import { applyToPoint as applyToPoint11 } from "transformation-matrix";
14978
14989
  var FabricationNoteDimension = class extends PrimitiveComponent2 {
14979
14990
  fabrication_note_dimension_id = null;
14980
14991
  isPcbPrimitive = true;
@@ -14993,13 +15004,13 @@ var FabricationNoteDimension = class extends PrimitiveComponent2 {
14993
15004
  this.renderError(
14994
15005
  `FabricationNoteDimension could not find selector "${input}"`
14995
15006
  );
14996
- return applyToPoint10(transform, { x: 0, y: 0 });
15007
+ return applyToPoint11(transform, { x: 0, y: 0 });
14997
15008
  }
14998
15009
  return target._getGlobalPcbPositionBeforeLayout();
14999
15010
  }
15000
15011
  const numericX = typeof input.x === "string" ? parseFloat(input.x) : input.x;
15001
15012
  const numericY = typeof input.y === "string" ? parseFloat(input.y) : input.y;
15002
- return applyToPoint10(transform, { x: numericX, y: numericY });
15013
+ return applyToPoint11(transform, { x: numericX, y: numericY });
15003
15014
  }
15004
15015
  doInitialPcbPrimitiveRender() {
15005
15016
  if (this.root?.pcbDisabled) return;
@@ -15068,7 +15079,7 @@ var FabricationNoteDimension = class extends PrimitiveComponent2 {
15068
15079
 
15069
15080
  // lib/components/primitive-components/PcbNoteLine.ts
15070
15081
  import { pcbNoteLineProps } from "@tscircuit/props";
15071
- import { applyToPoint as applyToPoint11 } from "transformation-matrix";
15082
+ import { applyToPoint as applyToPoint12 } from "transformation-matrix";
15072
15083
  var PcbNoteLine = class extends PrimitiveComponent2 {
15073
15084
  pcb_note_line_id = null;
15074
15085
  isPcbPrimitive = true;
@@ -15085,8 +15096,8 @@ var PcbNoteLine = class extends PrimitiveComponent2 {
15085
15096
  const subcircuit = this.getSubcircuit();
15086
15097
  const group = this.getGroup();
15087
15098
  const transform = this._computePcbGlobalTransformBeforeLayout();
15088
- const start = applyToPoint11(transform, { x: props.x1, y: props.y1 });
15089
- const end = applyToPoint11(transform, { x: props.x2, y: props.y2 });
15099
+ const start = applyToPoint12(transform, { x: props.x1, y: props.y1 });
15100
+ const end = applyToPoint12(transform, { x: props.x2, y: props.y2 });
15090
15101
  const pcb_component_id = this.parent?.pcb_component_id ?? this.getPrimitiveContainer()?.pcb_component_id ?? void 0;
15091
15102
  const pcb_note_line = db.pcb_note_line.insert({
15092
15103
  pcb_component_id,
@@ -15113,7 +15124,7 @@ var PcbNoteLine = class extends PrimitiveComponent2 {
15113
15124
 
15114
15125
  // lib/components/primitive-components/PcbNoteRect.ts
15115
15126
  import { pcbNoteRectProps } from "@tscircuit/props";
15116
- import { applyToPoint as applyToPoint12 } from "transformation-matrix";
15127
+ import { applyToPoint as applyToPoint13 } from "transformation-matrix";
15117
15128
  var PcbNoteRect = class extends PrimitiveComponent2 {
15118
15129
  pcb_note_rect_id = null;
15119
15130
  isPcbPrimitive = true;
@@ -15128,7 +15139,7 @@ var PcbNoteRect = class extends PrimitiveComponent2 {
15128
15139
  const { db } = this.root;
15129
15140
  const { _parsedProps: props } = this;
15130
15141
  const transform = this._computePcbGlobalTransformBeforeLayout();
15131
- const center = applyToPoint12(transform, { x: 0, y: 0 });
15142
+ const center = applyToPoint13(transform, { x: 0, y: 0 });
15132
15143
  const subcircuit = this.getSubcircuit();
15133
15144
  const group = this.getGroup();
15134
15145
  const pcb_component_id = this.parent?.pcb_component_id ?? this.getPrimitiveContainer()?.pcb_component_id ?? void 0;
@@ -15157,7 +15168,7 @@ var PcbNoteRect = class extends PrimitiveComponent2 {
15157
15168
 
15158
15169
  // lib/components/primitive-components/PcbNoteText.ts
15159
15170
  import { pcbNoteTextProps } from "@tscircuit/props";
15160
- import { applyToPoint as applyToPoint13 } from "transformation-matrix";
15171
+ import { applyToPoint as applyToPoint14 } from "transformation-matrix";
15161
15172
  var PcbNoteText = class extends PrimitiveComponent2 {
15162
15173
  pcb_note_text_id = null;
15163
15174
  isPcbPrimitive = true;
@@ -15172,7 +15183,7 @@ var PcbNoteText = class extends PrimitiveComponent2 {
15172
15183
  const { db } = this.root;
15173
15184
  const { _parsedProps: props } = this;
15174
15185
  const transform = this._computePcbGlobalTransformBeforeLayout();
15175
- const anchorPosition = applyToPoint13(transform, { x: 0, y: 0 });
15186
+ const anchorPosition = applyToPoint14(transform, { x: 0, y: 0 });
15176
15187
  const subcircuit = this.getSubcircuit();
15177
15188
  const group = this.getGroup();
15178
15189
  const pcb_component_id = this.parent?.pcb_component_id ?? this.getPrimitiveContainer()?.pcb_component_id ?? void 0;
@@ -15201,7 +15212,7 @@ var PcbNoteText = class extends PrimitiveComponent2 {
15201
15212
 
15202
15213
  // lib/components/primitive-components/PcbNotePath.ts
15203
15214
  import { pcbNotePathProps } from "@tscircuit/props";
15204
- import { applyToPoint as applyToPoint14 } from "transformation-matrix";
15215
+ import { applyToPoint as applyToPoint15 } from "transformation-matrix";
15205
15216
  var PcbNotePath = class extends PrimitiveComponent2 {
15206
15217
  pcb_note_path_id = null;
15207
15218
  isPcbPrimitive = true;
@@ -15223,7 +15234,7 @@ var PcbNotePath = class extends PrimitiveComponent2 {
15223
15234
  const { x, y, ...rest } = point;
15224
15235
  const numericX = typeof x === "string" ? parseFloat(x) : x;
15225
15236
  const numericY = typeof y === "string" ? parseFloat(y) : y;
15226
- const transformed = applyToPoint14(transform, { x: numericX, y: numericY });
15237
+ const transformed = applyToPoint15(transform, { x: numericX, y: numericY });
15227
15238
  return { ...rest, x: transformed.x, y: transformed.y };
15228
15239
  });
15229
15240
  const pcb_note_path = db.pcb_note_path.insert({
@@ -15255,7 +15266,7 @@ var PcbNotePath = class extends PrimitiveComponent2 {
15255
15266
 
15256
15267
  // lib/components/primitive-components/PcbNoteDimension.ts
15257
15268
  import { pcbNoteDimensionProps } from "@tscircuit/props";
15258
- import { applyToPoint as applyToPoint15 } from "transformation-matrix";
15269
+ import { applyToPoint as applyToPoint16 } from "transformation-matrix";
15259
15270
  var PcbNoteDimension = class extends PrimitiveComponent2 {
15260
15271
  pcb_note_dimension_id = null;
15261
15272
  isPcbPrimitive = true;
@@ -15272,13 +15283,13 @@ var PcbNoteDimension = class extends PrimitiveComponent2 {
15272
15283
  );
15273
15284
  if (!target) {
15274
15285
  this.renderError(`PcbNoteDimension could not find selector "${input}"`);
15275
- return applyToPoint15(transform, { x: 0, y: 0 });
15286
+ return applyToPoint16(transform, { x: 0, y: 0 });
15276
15287
  }
15277
15288
  return target._getGlobalPcbPositionBeforeLayout();
15278
15289
  }
15279
15290
  const numericX = typeof input.x === "string" ? parseFloat(input.x) : input.x;
15280
15291
  const numericY = typeof input.y === "string" ? parseFloat(input.y) : input.y;
15281
- return applyToPoint15(transform, { x: numericX, y: numericY });
15292
+ return applyToPoint16(transform, { x: numericX, y: numericY });
15282
15293
  }
15283
15294
  doInitialPcbPrimitiveRender() {
15284
15295
  if (this.root?.pcbDisabled) return;
@@ -15458,7 +15469,7 @@ var BreakoutPoint = class extends PrimitiveComponent2 {
15458
15469
  // lib/components/primitive-components/NetLabel.ts
15459
15470
  import { netLabelProps } from "@tscircuit/props";
15460
15471
  import {
15461
- applyToPoint as applyToPoint16,
15472
+ applyToPoint as applyToPoint17,
15462
15473
  identity as identity5,
15463
15474
  translate as translate6
15464
15475
  } from "transformation-matrix";
@@ -15509,7 +15520,7 @@ var NetLabel = class extends PrimitiveComponent2 {
15509
15520
  const connectedPorts = this._getConnectedPorts();
15510
15521
  if (connectedPorts.length > 0) {
15511
15522
  const portPos = connectedPorts[0]._getGlobalSchematicPositionBeforeLayout();
15512
- const parentCenter = applyToPoint16(
15523
+ const parentCenter = applyToPoint17(
15513
15524
  this.parent?.computeSchematicGlobalTransform?.() ?? identity5(),
15514
15525
  { x: 0, y: 0 }
15515
15526
  );
@@ -17354,7 +17365,7 @@ import { identity as identity6 } from "transformation-matrix";
17354
17365
  var package_default = {
17355
17366
  name: "@tscircuit/core",
17356
17367
  type: "module",
17357
- version: "0.0.827",
17368
+ version: "0.0.828",
17358
17369
  types: "dist/index.d.ts",
17359
17370
  main: "dist/index.js",
17360
17371
  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.828",
4
+ "version": "0.0.829",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",