circuit-json 0.0.287 → 0.0.289

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.
package/README.md CHANGED
@@ -91,6 +91,7 @@ https://github.com/user-attachments/assets/2f28b7ba-689e-4d80-85b2-5bdef84b41f8
91
91
  - [PcbComponentOutsideBoardError](#pcbcomponentoutsideboarderror)
92
92
  - [PcbCopperPour](#pcbcopperpour)
93
93
  - [PcbCourtyardOutline](#pcbcourtyardoutline)
94
+ - [PcbCourtyardPolygon](#pcbcourtyardpolygon)
94
95
  - [PcbCourtyardRect](#pcbcourtyardrect)
95
96
  - [PcbCutout](#pcbcutout)
96
97
  - [PcbFabricationNoteDimension](#pcbfabricationnotedimension)
@@ -991,6 +992,26 @@ interface PcbCourtyardOutline {
991
992
  }
992
993
  ```
993
994
 
995
+ ### PcbCourtyardPolygon
996
+
997
+ [Source](https://github.com/tscircuit/circuit-json/blob/main/src/pcb/pcb_courtyard_polygon.ts)
998
+
999
+ Defines a courtyard polygon on the PCB
1000
+
1001
+ ```typescript
1002
+ /** Defines a courtyard polygon on the PCB */
1003
+ interface PcbCourtyardPolygon {
1004
+ type: "pcb_courtyard_polygon"
1005
+ pcb_courtyard_polygon_id: string
1006
+ pcb_component_id: string
1007
+ pcb_group_id?: string
1008
+ subcircuit_id?: string
1009
+ layer: VisibleLayer
1010
+ points: Point[]
1011
+ color?: string
1012
+ }
1013
+ ```
1014
+
994
1015
  ### PcbCourtyardRect
995
1016
 
996
1017
  [Source](https://github.com/tscircuit/circuit-json/blob/main/src/pcb/pcb_courtyard_rect.ts)
@@ -2463,6 +2484,7 @@ interface SimulationExperiment {
2463
2484
  interface SimulationSwitch {
2464
2485
  type: "simulation_switch"
2465
2486
  simulation_switch_id: string
2487
+ source_component_id?: string
2466
2488
  closes_at?: number
2467
2489
  opens_at?: number
2468
2490
  starts_closed?: boolean
package/dist/index.d.mts CHANGED
@@ -6372,7 +6372,69 @@ interface PcbCourtyardOutline {
6372
6372
  */
6373
6373
  type PCBCourtyardOutline = PcbCourtyardOutline;
6374
6374
 
6375
- type PcbCircuitElement = PcbComponent | PcbHole | PcbPlatedHole | PcbPort | PcbSmtPad | PcbSolderPaste | PcbText | PcbTrace | PcbTraceError | PcbTraceMissingError | PcbMissingFootprintError | ExternalFootprintLoadError | CircuitJsonFootprintLoadError | PcbManualEditConflictWarning | PcbPortNotMatchedError | PcbPortNotConnectedError | PcbVia | PcbNet | PcbBoard | PcbPanel | PcbPlacementError | PcbTraceHint | PcbSilkscreenLine | PcbSilkscreenPath | PcbSilkscreenText | PcbSilkscreenRect | PcbSilkscreenCircle | PcbFabricationNoteRect | PcbFabricationNoteDimension | PcbNoteText | PcbNoteRect | PcbNotePath | PcbNoteLine | PcbNoteDimension | PcbAutoroutingError | PcbFootprintOverlapError | PcbCutout | PcbBreakoutPoint | PcbGroundPlane | PcbGroundPlaneRegion | PcbThermalSpoke | PcbCopperPour | PcbComponentOutsideBoardError | PcbComponentInvalidLayerError | PcbViaClearanceError | PcbCourtyardRect | PcbCourtyardOutline;
6375
+ declare const pcb_courtyard_polygon: z.ZodObject<{
6376
+ type: z.ZodLiteral<"pcb_courtyard_polygon">;
6377
+ pcb_courtyard_polygon_id: z.ZodDefault<z.ZodOptional<z.ZodString>>;
6378
+ pcb_component_id: z.ZodString;
6379
+ pcb_group_id: z.ZodOptional<z.ZodString>;
6380
+ subcircuit_id: z.ZodOptional<z.ZodString>;
6381
+ layer: z.ZodEnum<["top", "bottom"]>;
6382
+ points: z.ZodArray<z.ZodObject<{
6383
+ x: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
6384
+ y: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
6385
+ }, "strip", z.ZodTypeAny, {
6386
+ x: number;
6387
+ y: number;
6388
+ }, {
6389
+ x: string | number;
6390
+ y: string | number;
6391
+ }>, "many">;
6392
+ color: z.ZodOptional<z.ZodString>;
6393
+ }, "strip", z.ZodTypeAny, {
6394
+ type: "pcb_courtyard_polygon";
6395
+ pcb_component_id: string;
6396
+ layer: "top" | "bottom";
6397
+ points: {
6398
+ x: number;
6399
+ y: number;
6400
+ }[];
6401
+ pcb_courtyard_polygon_id: string;
6402
+ subcircuit_id?: string | undefined;
6403
+ pcb_group_id?: string | undefined;
6404
+ color?: string | undefined;
6405
+ }, {
6406
+ type: "pcb_courtyard_polygon";
6407
+ pcb_component_id: string;
6408
+ layer: "top" | "bottom";
6409
+ points: {
6410
+ x: string | number;
6411
+ y: string | number;
6412
+ }[];
6413
+ subcircuit_id?: string | undefined;
6414
+ pcb_group_id?: string | undefined;
6415
+ color?: string | undefined;
6416
+ pcb_courtyard_polygon_id?: string | undefined;
6417
+ }>;
6418
+ type PcbCourtyardPolygonInput = z.input<typeof pcb_courtyard_polygon>;
6419
+ /**
6420
+ * Defines a courtyard polygon on the PCB
6421
+ */
6422
+ interface PcbCourtyardPolygon {
6423
+ type: "pcb_courtyard_polygon";
6424
+ pcb_courtyard_polygon_id: string;
6425
+ pcb_component_id: string;
6426
+ pcb_group_id?: string;
6427
+ subcircuit_id?: string;
6428
+ layer: VisibleLayer;
6429
+ points: Point[];
6430
+ color?: string;
6431
+ }
6432
+ /**
6433
+ * @deprecated use PcbCourtyardPolygon
6434
+ */
6435
+ type PCBCourtyardPolygon = PcbCourtyardPolygon;
6436
+
6437
+ type PcbCircuitElement = PcbComponent | PcbHole | PcbPlatedHole | PcbPort | PcbSmtPad | PcbSolderPaste | PcbText | PcbTrace | PcbTraceError | PcbTraceMissingError | PcbMissingFootprintError | ExternalFootprintLoadError | CircuitJsonFootprintLoadError | PcbManualEditConflictWarning | PcbPortNotMatchedError | PcbPortNotConnectedError | PcbVia | PcbNet | PcbBoard | PcbPanel | PcbPlacementError | PcbTraceHint | PcbSilkscreenLine | PcbSilkscreenPath | PcbSilkscreenText | PcbSilkscreenRect | PcbSilkscreenCircle | PcbFabricationNoteRect | PcbFabricationNoteDimension | PcbNoteText | PcbNoteRect | PcbNotePath | PcbNoteLine | PcbNoteDimension | PcbAutoroutingError | PcbFootprintOverlapError | PcbCutout | PcbBreakoutPoint | PcbGroundPlane | PcbGroundPlaneRegion | PcbThermalSpoke | PcbCopperPour | PcbComponentOutsideBoardError | PcbComponentInvalidLayerError | PcbViaClearanceError | PcbCourtyardRect | PcbCourtyardOutline | PcbCourtyardPolygon;
6376
6438
 
6377
6439
  interface SchematicBox {
6378
6440
  type: "schematic_box";
@@ -11359,6 +11421,7 @@ type SimulationTransientVoltageGraphInput = z.input<typeof simulation_transient_
11359
11421
  declare const simulation_switch: z.ZodObject<{
11360
11422
  type: z.ZodLiteral<"simulation_switch">;
11361
11423
  simulation_switch_id: z.ZodDefault<z.ZodOptional<z.ZodString>>;
11424
+ source_component_id: z.ZodOptional<z.ZodString>;
11362
11425
  closes_at: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
11363
11426
  opens_at: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
11364
11427
  starts_closed: z.ZodOptional<z.ZodBoolean>;
@@ -11366,12 +11429,14 @@ declare const simulation_switch: z.ZodObject<{
11366
11429
  }, "strip", z.ZodTypeAny, {
11367
11430
  type: "simulation_switch";
11368
11431
  simulation_switch_id: string;
11432
+ source_component_id?: string | undefined;
11369
11433
  closes_at?: number | undefined;
11370
11434
  opens_at?: number | undefined;
11371
11435
  starts_closed?: boolean | undefined;
11372
11436
  switching_frequency?: number | undefined;
11373
11437
  }, {
11374
11438
  type: "simulation_switch";
11439
+ source_component_id?: string | undefined;
11375
11440
  simulation_switch_id?: string | undefined;
11376
11441
  closes_at?: string | number | undefined;
11377
11442
  opens_at?: string | number | undefined;
@@ -11382,6 +11447,7 @@ type SimulationSwitchInput = z.input<typeof simulation_switch>;
11382
11447
  interface SimulationSwitch {
11383
11448
  type: "simulation_switch";
11384
11449
  simulation_switch_id: string;
11450
+ source_component_id?: string;
11385
11451
  closes_at?: number;
11386
11452
  opens_at?: number;
11387
11453
  starts_closed?: boolean;
@@ -17129,6 +17195,48 @@ declare const any_circuit_element: z.ZodUnion<[z.ZodObject<{
17129
17195
  color?: string | undefined;
17130
17196
  pcb_courtyard_outline_id?: string | undefined;
17131
17197
  is_closed?: boolean | undefined;
17198
+ }>, z.ZodObject<{
17199
+ type: z.ZodLiteral<"pcb_courtyard_polygon">;
17200
+ pcb_courtyard_polygon_id: z.ZodDefault<z.ZodOptional<z.ZodString>>;
17201
+ pcb_component_id: z.ZodString;
17202
+ pcb_group_id: z.ZodOptional<z.ZodString>;
17203
+ subcircuit_id: z.ZodOptional<z.ZodString>;
17204
+ layer: z.ZodEnum<["top", "bottom"]>;
17205
+ points: z.ZodArray<z.ZodObject<{
17206
+ x: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
17207
+ y: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
17208
+ }, "strip", z.ZodTypeAny, {
17209
+ x: number;
17210
+ y: number;
17211
+ }, {
17212
+ x: string | number;
17213
+ y: string | number;
17214
+ }>, "many">;
17215
+ color: z.ZodOptional<z.ZodString>;
17216
+ }, "strip", z.ZodTypeAny, {
17217
+ type: "pcb_courtyard_polygon";
17218
+ pcb_component_id: string;
17219
+ layer: "top" | "bottom";
17220
+ points: {
17221
+ x: number;
17222
+ y: number;
17223
+ }[];
17224
+ pcb_courtyard_polygon_id: string;
17225
+ subcircuit_id?: string | undefined;
17226
+ pcb_group_id?: string | undefined;
17227
+ color?: string | undefined;
17228
+ }, {
17229
+ type: "pcb_courtyard_polygon";
17230
+ pcb_component_id: string;
17231
+ layer: "top" | "bottom";
17232
+ points: {
17233
+ x: string | number;
17234
+ y: string | number;
17235
+ }[];
17236
+ subcircuit_id?: string | undefined;
17237
+ pcb_group_id?: string | undefined;
17238
+ color?: string | undefined;
17239
+ pcb_courtyard_polygon_id?: string | undefined;
17132
17240
  }>, z.ZodObject<{
17133
17241
  type: z.ZodLiteral<"schematic_box">;
17134
17242
  schematic_component_id: z.ZodOptional<z.ZodString>;
@@ -18597,6 +18705,7 @@ declare const any_circuit_element: z.ZodUnion<[z.ZodObject<{
18597
18705
  }>, z.ZodObject<{
18598
18706
  type: z.ZodLiteral<"simulation_switch">;
18599
18707
  simulation_switch_id: z.ZodDefault<z.ZodOptional<z.ZodString>>;
18708
+ source_component_id: z.ZodOptional<z.ZodString>;
18600
18709
  closes_at: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
18601
18710
  opens_at: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
18602
18711
  starts_closed: z.ZodOptional<z.ZodBoolean>;
@@ -18604,12 +18713,14 @@ declare const any_circuit_element: z.ZodUnion<[z.ZodObject<{
18604
18713
  }, "strip", z.ZodTypeAny, {
18605
18714
  type: "simulation_switch";
18606
18715
  simulation_switch_id: string;
18716
+ source_component_id?: string | undefined;
18607
18717
  closes_at?: number | undefined;
18608
18718
  opens_at?: number | undefined;
18609
18719
  starts_closed?: boolean | undefined;
18610
18720
  switching_frequency?: number | undefined;
18611
18721
  }, {
18612
18722
  type: "simulation_switch";
18723
+ source_component_id?: string | undefined;
18613
18724
  simulation_switch_id?: string | undefined;
18614
18725
  closes_at?: string | number | undefined;
18615
18726
  opens_at?: string | number | undefined;
@@ -24346,6 +24457,48 @@ declare const any_soup_element: z.ZodUnion<[z.ZodObject<{
24346
24457
  color?: string | undefined;
24347
24458
  pcb_courtyard_outline_id?: string | undefined;
24348
24459
  is_closed?: boolean | undefined;
24460
+ }>, z.ZodObject<{
24461
+ type: z.ZodLiteral<"pcb_courtyard_polygon">;
24462
+ pcb_courtyard_polygon_id: z.ZodDefault<z.ZodOptional<z.ZodString>>;
24463
+ pcb_component_id: z.ZodString;
24464
+ pcb_group_id: z.ZodOptional<z.ZodString>;
24465
+ subcircuit_id: z.ZodOptional<z.ZodString>;
24466
+ layer: z.ZodEnum<["top", "bottom"]>;
24467
+ points: z.ZodArray<z.ZodObject<{
24468
+ x: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
24469
+ y: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
24470
+ }, "strip", z.ZodTypeAny, {
24471
+ x: number;
24472
+ y: number;
24473
+ }, {
24474
+ x: string | number;
24475
+ y: string | number;
24476
+ }>, "many">;
24477
+ color: z.ZodOptional<z.ZodString>;
24478
+ }, "strip", z.ZodTypeAny, {
24479
+ type: "pcb_courtyard_polygon";
24480
+ pcb_component_id: string;
24481
+ layer: "top" | "bottom";
24482
+ points: {
24483
+ x: number;
24484
+ y: number;
24485
+ }[];
24486
+ pcb_courtyard_polygon_id: string;
24487
+ subcircuit_id?: string | undefined;
24488
+ pcb_group_id?: string | undefined;
24489
+ color?: string | undefined;
24490
+ }, {
24491
+ type: "pcb_courtyard_polygon";
24492
+ pcb_component_id: string;
24493
+ layer: "top" | "bottom";
24494
+ points: {
24495
+ x: string | number;
24496
+ y: string | number;
24497
+ }[];
24498
+ subcircuit_id?: string | undefined;
24499
+ pcb_group_id?: string | undefined;
24500
+ color?: string | undefined;
24501
+ pcb_courtyard_polygon_id?: string | undefined;
24349
24502
  }>, z.ZodObject<{
24350
24503
  type: z.ZodLiteral<"schematic_box">;
24351
24504
  schematic_component_id: z.ZodOptional<z.ZodString>;
@@ -25814,6 +25967,7 @@ declare const any_soup_element: z.ZodUnion<[z.ZodObject<{
25814
25967
  }>, z.ZodObject<{
25815
25968
  type: z.ZodLiteral<"simulation_switch">;
25816
25969
  simulation_switch_id: z.ZodDefault<z.ZodOptional<z.ZodString>>;
25970
+ source_component_id: z.ZodOptional<z.ZodString>;
25817
25971
  closes_at: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
25818
25972
  opens_at: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
25819
25973
  starts_closed: z.ZodOptional<z.ZodBoolean>;
@@ -25821,12 +25975,14 @@ declare const any_soup_element: z.ZodUnion<[z.ZodObject<{
25821
25975
  }, "strip", z.ZodTypeAny, {
25822
25976
  type: "simulation_switch";
25823
25977
  simulation_switch_id: string;
25978
+ source_component_id?: string | undefined;
25824
25979
  closes_at?: number | undefined;
25825
25980
  opens_at?: number | undefined;
25826
25981
  starts_closed?: boolean | undefined;
25827
25982
  switching_frequency?: number | undefined;
25828
25983
  }, {
25829
25984
  type: "simulation_switch";
25985
+ source_component_id?: string | undefined;
25830
25986
  simulation_switch_id?: string | undefined;
25831
25987
  closes_at?: string | number | undefined;
25832
25988
  opens_at?: string | number | undefined;
@@ -25884,4 +26040,4 @@ type AnySoupElementInput = AnyCircuitElementInput;
25884
26040
  */
25885
26041
  type CircuitJson = AnyCircuitElement[];
25886
26042
 
25887
- export { type AnyCircuitElement, type AnyCircuitElementInput, type AnySoupElement, type AnySoupElementInput, type AnySourceComponent, type AnySourceElement, type BRepShape, type CadComponent, type CadComponentInput, type CircuitJson, type CircuitJsonError, type CircuitJsonFootprintLoadError, type CircuitJsonFootprintLoadErrorInput, type Distance, type ExperimentType, type ExternalFootprintLoadError, type ExternalFootprintLoadErrorInput, type InferredProjectMetadata, type InferredSchematicNetLabel, type InputPoint, type InputPosition, type InputRotation, type LayerRef, type LayerRefInput, type Length, type NinePointAnchor, type PCBBoard, type PCBComponent, type PCBCourtyardOutline, type PCBCourtyardRect, type PCBFabricationNoteDimension, type PCBFabricationNotePath, type PCBFabricationNoteRect, type PCBFabricationNoteText, type PCBHole, type PCBHoleInput, type PCBKeepout, type PCBKeepoutCircle, type PCBKeepoutInput, type PCBKeepoutRect, type PCBMissingFootprintError, type PCBPanel, type PCBPlacementError, type PCBPlatedHole, type PCBPlatedHoleInput, type PCBPort, type PCBPortInput, type PCBPortNotMatchedError, type PCBSMTPad, type PCBSMTPadInput, type PCBSilkscreenLine, type PCBSilkscreenText, type PCBSolderPasteInput, type PCBText, type PCBTrace, type PCBTraceError, type PCBTraceHint, type PCBTraceInput, type PCBTraceMissingError, type PCBVia, type PcbAutoroutingError, type PcbAutoroutingErrorInput, type PcbAutoroutingErrorInterface, type PcbBoard, type PcbBoardInput, type PcbBreakoutPoint, type PcbBreakoutPointInput, type PcbCircuitElement, type PcbComponent, type PcbComponentInput, type PcbComponentInvalidLayerError, type PcbComponentInvalidLayerErrorInput, type PcbComponentOutsideBoardError, type PcbComponentOutsideBoardErrorInput, type PcbCopperPour, type PcbCopperPourBRep, type PcbCopperPourBRepInput, type PcbCopperPourInput, type PcbCopperPourPolygon, type PcbCopperPourPolygonInput, type PcbCopperPourRect, type PcbCopperPourRectInput, type PcbCourtyardOutline, type PcbCourtyardOutlineInput, type PcbCourtyardRect, type PcbCourtyardRectInput, type PcbCutout, type PcbCutoutCircle, type PcbCutoutCircleInput, type PcbCutoutInput, type PcbCutoutPolygon, type PcbCutoutPolygonInput, type PcbCutoutRect, type PcbCutoutRectInput, type PcbFabricationNoteDimension, type PcbFabricationNoteDimensionInput, type PcbFabricationNotePath, type PcbFabricationNotePathInput, type PcbFabricationNoteRect, type PcbFabricationNoteRectInput, type PcbFabricationNoteText, type PcbFabricationNoteTextInput, type PcbFootprintOverlapError, type PcbFootprintOverlapErrorInput, type PcbGroundPlane, type PcbGroundPlaneInput, type PcbGroundPlaneRegion, type PcbGroundPlaneRegionInput, type PcbGroup, type PcbGroupInput, type PcbHole, type PcbHoleCircleOrSquare, type PcbHoleCircleOrSquareInput, type PcbHoleCircularWithRectPad, type PcbHoleOval, type PcbHoleOvalInput, type PcbHolePill, type PcbHolePillInput, type PcbHolePillWithRectPad, type PcbHoleRotatedPill, type PcbHoleRotatedPillInput, type PcbHoleRotatedPillWithRectPad, type PcbManualEditConflictWarning, type PcbManualEditConflictWarningInput, type PcbMissingFootprintError, type PcbMissingFootprintErrorInput, type PcbNet, type PcbNetInput, type PcbNoteDimension, type PcbNoteDimensionInput, type PcbNoteLine, type PcbNoteLineInput, type PcbNotePath, type PcbNotePathInput, type PcbNoteRect, type PcbNoteRectInput, type PcbNoteText, type PcbNoteTextInput, type PcbPanel, type PcbPanelInput, type PcbPlacementError, type PcbPlacementErrorInput, type PcbPlatedHole, type PcbPlatedHoleCircle, type PcbPlatedHoleInput, type PcbPlatedHoleOval, type PcbPort, type PcbPortInput, type PcbPortNotConnectedError, type PcbPortNotConnectedErrorInput, type PcbPortNotMatchedError, type PcbPortNotMatchedErrorInput, type PcbRouteHint, type PcbRouteHintInput, type PcbRouteHints, type PcbRouteHintsInput, type PcbSilkscreenCircle, type PcbSilkscreenCircleInput, type PcbSilkscreenLine, type PcbSilkscreenLineInput, type PcbSilkscreenOval, type PcbSilkscreenOvalDeprecated, type PcbSilkscreenOvalInput, type PcbSilkscreenPath, type PcbSilkscreenPathDeprecated, type PcbSilkscreenPathInput, type PcbSilkscreenRect, type PcbSilkscreenRectInput, type PcbSilkscreenRectOld, type PcbSilkscreenText, type PcbSilkscreenTextInput, type PcbSmtPad, type PcbSmtPadCircle, type PcbSmtPadPill, type PcbSmtPadPolygon, type PcbSmtPadRect, type PcbSmtPadRotatedPill, type PcbSmtPadRotatedRect, type PcbSolderPaste, type PcbSolderPasteCircle, type PcbSolderPasteOval, type PcbSolderPastePill, type PcbSolderPasteRect, type PcbSolderPasteRotatedRect, type PcbText, type PcbTextInput, type PcbThermalSpoke, type PcbThermalSpokeInput, type PcbTrace, type PcbTraceError, type PcbTraceErrorInput, type PcbTraceHint, type PcbTraceHintInput, type PcbTraceInput, type PcbTraceMissingError, type PcbTraceMissingErrorInput, type PcbTraceRoutePoint, type PcbTraceRoutePointVia, type PcbTraceRoutePointWire, type PcbVia, type PcbViaClearanceError, type PcbViaClearanceErrorInput, type PcbViaInput, type Point, type Point3, type PointWithBulge, type Position, type Ring, type Rotation, type RouteHintPoint, type RouteHintPointInput, type SchematicArc, type SchematicArcInput, type SchematicBox, type SchematicBoxInput, type SchematicCircle, type SchematicCircleInput, type SchematicComponent, type SchematicComponentInput, type SchematicDebugLine, type SchematicDebugObject, type SchematicDebugObjectInput, type SchematicDebugPoint, type SchematicDebugRect, type SchematicError, type SchematicErrorInput, type SchematicGroup, type SchematicGroupInput, type SchematicLayoutError, type SchematicLayoutErrorInput, type SchematicLine, type SchematicLineInput, type SchematicManualEditConflictWarning, type SchematicManualEditConflictWarningInput, type SchematicNetLabel, type SchematicNetLabelInput, type SchematicPath, type SchematicPathInput, type SchematicPort, type SchematicPortArrangement, type SchematicPortArrangementBySides, type SchematicPortArrangementBySize, type SchematicPortInput, type SchematicRect, type SchematicRectInput, type SchematicTable, type SchematicTableCell, type SchematicTableCellInput, type SchematicTableInput, type SchematicText, type SchematicTextInput, type SchematicTrace, type SchematicTraceEdge, type SchematicTraceInput, type SchematicVoltageProbe, type SchematicVoltageProbeInput, type SimulationAcVoltageSource, type SimulationAcVoltageSourceInput, type SimulationDcVoltageSource, type SimulationExperiment, type SimulationExperimentInput, type SimulationSwitch, type SimulationSwitchInput, type SimulationTransientVoltageGraph, type SimulationTransientVoltageGraphInput, type SimulationVoltageProbe, type SimulationVoltageProbeInput, type SimulationVoltageSource, type SimulationVoltageSourceInput, type Size, type SizeInput, type SourceBoard, type SourceBoardInput, type SourceComponentBase, type SourceFailedToCreateComponentError, type SourceFailedToCreateComponentErrorInput, type SourceGroup, type SourceGroupInput, type SourceManuallyPlacedVia, type SourceManuallyPlacedViaInput, type SourceMissingPropertyError, type SourceMissingPropertyErrorInput, type SourceNet, type SourceNetInput, type SourcePcbGroundPlane, type SourcePcbGroundPlaneInput, type SourcePinMissingTraceWarning, type SourcePinMissingTraceWarningInput, type SourcePort, type SourcePortInput, type SourceProjectMetadata, type SourcePropertyIgnoredWarning, type SourcePropertyIgnoredWarningInput, type SourceSimpleBattery, type SourceSimpleBatteryInput, type SourceSimpleCapacitor, type SourceSimpleCapacitorInput, type SourceSimpleChip, type SourceSimpleChipInput, type SourceSimpleCrystal, type SourceSimpleCrystalInput, type SourceSimpleDiode, type SourceSimpleDiodeInput, type SourceSimpleGround, type SourceSimpleGroundInput, type SourceSimpleInductor, type SourceSimpleInductorInput, type SourceSimpleLed, type SourceSimpleLedInput, type SourceSimpleMosfet, type SourceSimpleMosfetInput, type SourceSimplePinHeader, type SourceSimplePinHeaderInput, type SourceSimplePinout, type SourceSimplePinoutInput, type SourceSimplePotentiometer, type SourceSimplePotentiometerInput, type SourceSimplePowerSource, type SourceSimplePowerSourceInput, type SourceSimplePushButton, type SourceSimplePushButtonInput, type SourceSimpleResistor, type SourceSimpleResistorInput, type SourceSimpleResonator, type SourceSimpleResonatorInput, type SourceSimpleSwitch, type SourceSimpleSwitchInput, type SourceSimpleTestPoint, type SourceSimpleTestPointInput, type SourceSimpleTransistor, type SourceSimpleTransistorInput, type SourceTrace, type SourceTraceNotConnectedError, type SourceTraceNotConnectedErrorInput, type SupplierName, type VisibleLayer, type VisibleLayerRef, type WaveShape, all_layers, any_circuit_element, any_soup_element, any_source_component, battery_capacity, brep_shape, cad_component, capacitance, circuit_json_footprint_load_error, current, distance, duration_ms, experiment_type, external_footprint_load_error, frequency, getZodPrefixedIdWithDefault, inductance, layer_ref, layer_string, length, ms, ninePointAnchor, pcb_autorouting_error, pcb_board, pcb_breakout_point, pcb_component, pcb_component_invalid_layer_error, pcb_component_outside_board_error, pcb_copper_pour, pcb_copper_pour_brep, pcb_copper_pour_polygon, pcb_copper_pour_rect, pcb_courtyard_outline, pcb_courtyard_rect, pcb_cutout, pcb_cutout_circle, pcb_cutout_polygon, pcb_cutout_rect, pcb_fabrication_note_dimension, pcb_fabrication_note_path, pcb_fabrication_note_rect, pcb_fabrication_note_text, pcb_footprint_overlap_error, pcb_ground_plane, pcb_ground_plane_region, pcb_group, pcb_hole, pcb_hole_circle_or_square_shape, pcb_hole_oval_shape, pcb_hole_pill_shape, pcb_hole_rotated_pill_shape, pcb_keepout, pcb_manual_edit_conflict_warning, pcb_missing_footprint_error, pcb_net, pcb_note_dimension, pcb_note_line, pcb_note_path, pcb_note_rect, pcb_note_text, pcb_panel, pcb_placement_error, pcb_plated_hole, pcb_port, pcb_port_not_connected_error, pcb_port_not_matched_error, pcb_route_hint, pcb_route_hints, pcb_silkscreen_circle, pcb_silkscreen_line, pcb_silkscreen_oval, pcb_silkscreen_path, pcb_silkscreen_rect, pcb_silkscreen_text, pcb_smtpad, pcb_smtpad_pill, pcb_solder_paste, pcb_text, pcb_thermal_spoke, pcb_trace, pcb_trace_error, pcb_trace_hint, pcb_trace_missing_error, pcb_trace_route_point, pcb_trace_route_point_via, pcb_trace_route_point_wire, pcb_via, pcb_via_clearance_error, point, point3, point_with_bulge, port_arrangement, position, position3, resistance, ring, rotation, route_hint_point, schematic_arc, schematic_box, schematic_circle, schematic_component, schematic_component_port_arrangement_by_sides, schematic_component_port_arrangement_by_size, schematic_debug_line, schematic_debug_object, schematic_debug_object_base, schematic_debug_point, schematic_debug_rect, schematic_error, schematic_group, schematic_layout_error, schematic_line, schematic_manual_edit_conflict_warning, schematic_net_label, schematic_path, schematic_pin_styles, schematic_port, schematic_rect, schematic_table, schematic_table_cell, schematic_text, schematic_trace, schematic_voltage_probe, simulation_ac_voltage_source, simulation_dc_voltage_source, simulation_experiment, simulation_switch, simulation_transient_voltage_graph, simulation_voltage_probe, simulation_voltage_source, size, source_board, source_component_base, source_failed_to_create_component_error, source_group, source_manually_placed_via, source_missing_property_error, source_net, source_pcb_ground_plane, source_pin_missing_trace_warning, source_port, source_project_metadata, source_property_ignored_warning, source_simple_battery, source_simple_capacitor, source_simple_chip, source_simple_crystal, source_simple_diode, source_simple_ground, source_simple_inductor, source_simple_led, source_simple_mosfet, source_simple_pin_header, source_simple_pinout, source_simple_potentiometer, source_simple_power_source, source_simple_push_button, source_simple_resistor, source_simple_resonator, source_simple_switch, source_simple_test_point, source_simple_transistor, source_trace, source_trace_not_connected_error, supplier_name, time, timestamp, visible_layer, voltage, wave_shape };
26043
+ export { type AnyCircuitElement, type AnyCircuitElementInput, type AnySoupElement, type AnySoupElementInput, type AnySourceComponent, type AnySourceElement, type BRepShape, type CadComponent, type CadComponentInput, type CircuitJson, type CircuitJsonError, type CircuitJsonFootprintLoadError, type CircuitJsonFootprintLoadErrorInput, type Distance, type ExperimentType, type ExternalFootprintLoadError, type ExternalFootprintLoadErrorInput, type InferredProjectMetadata, type InferredSchematicNetLabel, type InputPoint, type InputPosition, type InputRotation, type LayerRef, type LayerRefInput, type Length, type NinePointAnchor, type PCBBoard, type PCBComponent, type PCBCourtyardOutline, type PCBCourtyardPolygon, type PCBCourtyardRect, type PCBFabricationNoteDimension, type PCBFabricationNotePath, type PCBFabricationNoteRect, type PCBFabricationNoteText, type PCBHole, type PCBHoleInput, type PCBKeepout, type PCBKeepoutCircle, type PCBKeepoutInput, type PCBKeepoutRect, type PCBMissingFootprintError, type PCBPanel, type PCBPlacementError, type PCBPlatedHole, type PCBPlatedHoleInput, type PCBPort, type PCBPortInput, type PCBPortNotMatchedError, type PCBSMTPad, type PCBSMTPadInput, type PCBSilkscreenLine, type PCBSilkscreenText, type PCBSolderPasteInput, type PCBText, type PCBTrace, type PCBTraceError, type PCBTraceHint, type PCBTraceInput, type PCBTraceMissingError, type PCBVia, type PcbAutoroutingError, type PcbAutoroutingErrorInput, type PcbAutoroutingErrorInterface, type PcbBoard, type PcbBoardInput, type PcbBreakoutPoint, type PcbBreakoutPointInput, type PcbCircuitElement, type PcbComponent, type PcbComponentInput, type PcbComponentInvalidLayerError, type PcbComponentInvalidLayerErrorInput, type PcbComponentOutsideBoardError, type PcbComponentOutsideBoardErrorInput, type PcbCopperPour, type PcbCopperPourBRep, type PcbCopperPourBRepInput, type PcbCopperPourInput, type PcbCopperPourPolygon, type PcbCopperPourPolygonInput, type PcbCopperPourRect, type PcbCopperPourRectInput, type PcbCourtyardOutline, type PcbCourtyardOutlineInput, type PcbCourtyardPolygon, type PcbCourtyardPolygonInput, type PcbCourtyardRect, type PcbCourtyardRectInput, type PcbCutout, type PcbCutoutCircle, type PcbCutoutCircleInput, type PcbCutoutInput, type PcbCutoutPolygon, type PcbCutoutPolygonInput, type PcbCutoutRect, type PcbCutoutRectInput, type PcbFabricationNoteDimension, type PcbFabricationNoteDimensionInput, type PcbFabricationNotePath, type PcbFabricationNotePathInput, type PcbFabricationNoteRect, type PcbFabricationNoteRectInput, type PcbFabricationNoteText, type PcbFabricationNoteTextInput, type PcbFootprintOverlapError, type PcbFootprintOverlapErrorInput, type PcbGroundPlane, type PcbGroundPlaneInput, type PcbGroundPlaneRegion, type PcbGroundPlaneRegionInput, type PcbGroup, type PcbGroupInput, type PcbHole, type PcbHoleCircleOrSquare, type PcbHoleCircleOrSquareInput, type PcbHoleCircularWithRectPad, type PcbHoleOval, type PcbHoleOvalInput, type PcbHolePill, type PcbHolePillInput, type PcbHolePillWithRectPad, type PcbHoleRotatedPill, type PcbHoleRotatedPillInput, type PcbHoleRotatedPillWithRectPad, type PcbManualEditConflictWarning, type PcbManualEditConflictWarningInput, type PcbMissingFootprintError, type PcbMissingFootprintErrorInput, type PcbNet, type PcbNetInput, type PcbNoteDimension, type PcbNoteDimensionInput, type PcbNoteLine, type PcbNoteLineInput, type PcbNotePath, type PcbNotePathInput, type PcbNoteRect, type PcbNoteRectInput, type PcbNoteText, type PcbNoteTextInput, type PcbPanel, type PcbPanelInput, type PcbPlacementError, type PcbPlacementErrorInput, type PcbPlatedHole, type PcbPlatedHoleCircle, type PcbPlatedHoleInput, type PcbPlatedHoleOval, type PcbPort, type PcbPortInput, type PcbPortNotConnectedError, type PcbPortNotConnectedErrorInput, type PcbPortNotMatchedError, type PcbPortNotMatchedErrorInput, type PcbRouteHint, type PcbRouteHintInput, type PcbRouteHints, type PcbRouteHintsInput, type PcbSilkscreenCircle, type PcbSilkscreenCircleInput, type PcbSilkscreenLine, type PcbSilkscreenLineInput, type PcbSilkscreenOval, type PcbSilkscreenOvalDeprecated, type PcbSilkscreenOvalInput, type PcbSilkscreenPath, type PcbSilkscreenPathDeprecated, type PcbSilkscreenPathInput, type PcbSilkscreenRect, type PcbSilkscreenRectInput, type PcbSilkscreenRectOld, type PcbSilkscreenText, type PcbSilkscreenTextInput, type PcbSmtPad, type PcbSmtPadCircle, type PcbSmtPadPill, type PcbSmtPadPolygon, type PcbSmtPadRect, type PcbSmtPadRotatedPill, type PcbSmtPadRotatedRect, type PcbSolderPaste, type PcbSolderPasteCircle, type PcbSolderPasteOval, type PcbSolderPastePill, type PcbSolderPasteRect, type PcbSolderPasteRotatedRect, type PcbText, type PcbTextInput, type PcbThermalSpoke, type PcbThermalSpokeInput, type PcbTrace, type PcbTraceError, type PcbTraceErrorInput, type PcbTraceHint, type PcbTraceHintInput, type PcbTraceInput, type PcbTraceMissingError, type PcbTraceMissingErrorInput, type PcbTraceRoutePoint, type PcbTraceRoutePointVia, type PcbTraceRoutePointWire, type PcbVia, type PcbViaClearanceError, type PcbViaClearanceErrorInput, type PcbViaInput, type Point, type Point3, type PointWithBulge, type Position, type Ring, type Rotation, type RouteHintPoint, type RouteHintPointInput, type SchematicArc, type SchematicArcInput, type SchematicBox, type SchematicBoxInput, type SchematicCircle, type SchematicCircleInput, type SchematicComponent, type SchematicComponentInput, type SchematicDebugLine, type SchematicDebugObject, type SchematicDebugObjectInput, type SchematicDebugPoint, type SchematicDebugRect, type SchematicError, type SchematicErrorInput, type SchematicGroup, type SchematicGroupInput, type SchematicLayoutError, type SchematicLayoutErrorInput, type SchematicLine, type SchematicLineInput, type SchematicManualEditConflictWarning, type SchematicManualEditConflictWarningInput, type SchematicNetLabel, type SchematicNetLabelInput, type SchematicPath, type SchematicPathInput, type SchematicPort, type SchematicPortArrangement, type SchematicPortArrangementBySides, type SchematicPortArrangementBySize, type SchematicPortInput, type SchematicRect, type SchematicRectInput, type SchematicTable, type SchematicTableCell, type SchematicTableCellInput, type SchematicTableInput, type SchematicText, type SchematicTextInput, type SchematicTrace, type SchematicTraceEdge, type SchematicTraceInput, type SchematicVoltageProbe, type SchematicVoltageProbeInput, type SimulationAcVoltageSource, type SimulationAcVoltageSourceInput, type SimulationDcVoltageSource, type SimulationExperiment, type SimulationExperimentInput, type SimulationSwitch, type SimulationSwitchInput, type SimulationTransientVoltageGraph, type SimulationTransientVoltageGraphInput, type SimulationVoltageProbe, type SimulationVoltageProbeInput, type SimulationVoltageSource, type SimulationVoltageSourceInput, type Size, type SizeInput, type SourceBoard, type SourceBoardInput, type SourceComponentBase, type SourceFailedToCreateComponentError, type SourceFailedToCreateComponentErrorInput, type SourceGroup, type SourceGroupInput, type SourceManuallyPlacedVia, type SourceManuallyPlacedViaInput, type SourceMissingPropertyError, type SourceMissingPropertyErrorInput, type SourceNet, type SourceNetInput, type SourcePcbGroundPlane, type SourcePcbGroundPlaneInput, type SourcePinMissingTraceWarning, type SourcePinMissingTraceWarningInput, type SourcePort, type SourcePortInput, type SourceProjectMetadata, type SourcePropertyIgnoredWarning, type SourcePropertyIgnoredWarningInput, type SourceSimpleBattery, type SourceSimpleBatteryInput, type SourceSimpleCapacitor, type SourceSimpleCapacitorInput, type SourceSimpleChip, type SourceSimpleChipInput, type SourceSimpleCrystal, type SourceSimpleCrystalInput, type SourceSimpleDiode, type SourceSimpleDiodeInput, type SourceSimpleGround, type SourceSimpleGroundInput, type SourceSimpleInductor, type SourceSimpleInductorInput, type SourceSimpleLed, type SourceSimpleLedInput, type SourceSimpleMosfet, type SourceSimpleMosfetInput, type SourceSimplePinHeader, type SourceSimplePinHeaderInput, type SourceSimplePinout, type SourceSimplePinoutInput, type SourceSimplePotentiometer, type SourceSimplePotentiometerInput, type SourceSimplePowerSource, type SourceSimplePowerSourceInput, type SourceSimplePushButton, type SourceSimplePushButtonInput, type SourceSimpleResistor, type SourceSimpleResistorInput, type SourceSimpleResonator, type SourceSimpleResonatorInput, type SourceSimpleSwitch, type SourceSimpleSwitchInput, type SourceSimpleTestPoint, type SourceSimpleTestPointInput, type SourceSimpleTransistor, type SourceSimpleTransistorInput, type SourceTrace, type SourceTraceNotConnectedError, type SourceTraceNotConnectedErrorInput, type SupplierName, type VisibleLayer, type VisibleLayerRef, type WaveShape, all_layers, any_circuit_element, any_soup_element, any_source_component, battery_capacity, brep_shape, cad_component, capacitance, circuit_json_footprint_load_error, current, distance, duration_ms, experiment_type, external_footprint_load_error, frequency, getZodPrefixedIdWithDefault, inductance, layer_ref, layer_string, length, ms, ninePointAnchor, pcb_autorouting_error, pcb_board, pcb_breakout_point, pcb_component, pcb_component_invalid_layer_error, pcb_component_outside_board_error, pcb_copper_pour, pcb_copper_pour_brep, pcb_copper_pour_polygon, pcb_copper_pour_rect, pcb_courtyard_outline, pcb_courtyard_polygon, pcb_courtyard_rect, pcb_cutout, pcb_cutout_circle, pcb_cutout_polygon, pcb_cutout_rect, pcb_fabrication_note_dimension, pcb_fabrication_note_path, pcb_fabrication_note_rect, pcb_fabrication_note_text, pcb_footprint_overlap_error, pcb_ground_plane, pcb_ground_plane_region, pcb_group, pcb_hole, pcb_hole_circle_or_square_shape, pcb_hole_oval_shape, pcb_hole_pill_shape, pcb_hole_rotated_pill_shape, pcb_keepout, pcb_manual_edit_conflict_warning, pcb_missing_footprint_error, pcb_net, pcb_note_dimension, pcb_note_line, pcb_note_path, pcb_note_rect, pcb_note_text, pcb_panel, pcb_placement_error, pcb_plated_hole, pcb_port, pcb_port_not_connected_error, pcb_port_not_matched_error, pcb_route_hint, pcb_route_hints, pcb_silkscreen_circle, pcb_silkscreen_line, pcb_silkscreen_oval, pcb_silkscreen_path, pcb_silkscreen_rect, pcb_silkscreen_text, pcb_smtpad, pcb_smtpad_pill, pcb_solder_paste, pcb_text, pcb_thermal_spoke, pcb_trace, pcb_trace_error, pcb_trace_hint, pcb_trace_missing_error, pcb_trace_route_point, pcb_trace_route_point_via, pcb_trace_route_point_wire, pcb_via, pcb_via_clearance_error, point, point3, point_with_bulge, port_arrangement, position, position3, resistance, ring, rotation, route_hint_point, schematic_arc, schematic_box, schematic_circle, schematic_component, schematic_component_port_arrangement_by_sides, schematic_component_port_arrangement_by_size, schematic_debug_line, schematic_debug_object, schematic_debug_object_base, schematic_debug_point, schematic_debug_rect, schematic_error, schematic_group, schematic_layout_error, schematic_line, schematic_manual_edit_conflict_warning, schematic_net_label, schematic_path, schematic_pin_styles, schematic_port, schematic_rect, schematic_table, schematic_table_cell, schematic_text, schematic_trace, schematic_voltage_probe, simulation_ac_voltage_source, simulation_dc_voltage_source, simulation_experiment, simulation_switch, simulation_transient_voltage_graph, simulation_voltage_probe, simulation_voltage_source, size, source_board, source_component_base, source_failed_to_create_component_error, source_group, source_manually_placed_via, source_missing_property_error, source_net, source_pcb_ground_plane, source_pin_missing_trace_warning, source_port, source_project_metadata, source_property_ignored_warning, source_simple_battery, source_simple_capacitor, source_simple_chip, source_simple_crystal, source_simple_diode, source_simple_ground, source_simple_inductor, source_simple_led, source_simple_mosfet, source_simple_pin_header, source_simple_pinout, source_simple_potentiometer, source_simple_power_source, source_simple_push_button, source_simple_resistor, source_simple_resonator, source_simple_switch, source_simple_test_point, source_simple_transistor, source_trace, source_trace_not_connected_error, supplier_name, time, timestamp, visible_layer, voltage, wave_shape };
package/dist/index.mjs CHANGED
@@ -2516,36 +2516,52 @@ var pcb_courtyard_outline = z118.object({
2516
2516
  }).describe("Defines a courtyard outline on the PCB");
2517
2517
  expectTypesMatch(true);
2518
2518
 
2519
- // src/cad/cad_component.ts
2519
+ // src/pcb/pcb_courtyard_polygon.ts
2520
2520
  import { z as z119 } from "zod";
2521
- var cad_component = z119.object({
2522
- type: z119.literal("cad_component"),
2523
- cad_component_id: z119.string(),
2521
+ var pcb_courtyard_polygon = z119.object({
2522
+ type: z119.literal("pcb_courtyard_polygon"),
2523
+ pcb_courtyard_polygon_id: getZodPrefixedIdWithDefault(
2524
+ "pcb_courtyard_polygon"
2525
+ ),
2524
2526
  pcb_component_id: z119.string(),
2525
- source_component_id: z119.string(),
2527
+ pcb_group_id: z119.string().optional(),
2528
+ subcircuit_id: z119.string().optional(),
2529
+ layer: visible_layer,
2530
+ points: z119.array(point).min(3),
2531
+ color: z119.string().optional()
2532
+ }).describe("Defines a courtyard polygon on the PCB");
2533
+ expectTypesMatch(true);
2534
+
2535
+ // src/cad/cad_component.ts
2536
+ import { z as z120 } from "zod";
2537
+ var cad_component = z120.object({
2538
+ type: z120.literal("cad_component"),
2539
+ cad_component_id: z120.string(),
2540
+ pcb_component_id: z120.string(),
2541
+ source_component_id: z120.string(),
2526
2542
  position: point3,
2527
2543
  rotation: point3.optional(),
2528
2544
  size: point3.optional(),
2529
2545
  layer: layer_ref.optional(),
2530
- subcircuit_id: z119.string().optional(),
2546
+ subcircuit_id: z120.string().optional(),
2531
2547
  // These are all ways to generate/load the 3d model
2532
- footprinter_string: z119.string().optional(),
2533
- model_obj_url: z119.string().optional(),
2534
- model_stl_url: z119.string().optional(),
2535
- model_3mf_url: z119.string().optional(),
2536
- model_gltf_url: z119.string().optional(),
2537
- model_glb_url: z119.string().optional(),
2538
- model_step_url: z119.string().optional(),
2539
- model_wrl_url: z119.string().optional(),
2540
- model_unit_to_mm_scale_factor: z119.number().optional(),
2541
- model_jscad: z119.any().optional()
2548
+ footprinter_string: z120.string().optional(),
2549
+ model_obj_url: z120.string().optional(),
2550
+ model_stl_url: z120.string().optional(),
2551
+ model_3mf_url: z120.string().optional(),
2552
+ model_gltf_url: z120.string().optional(),
2553
+ model_glb_url: z120.string().optional(),
2554
+ model_step_url: z120.string().optional(),
2555
+ model_wrl_url: z120.string().optional(),
2556
+ model_unit_to_mm_scale_factor: z120.number().optional(),
2557
+ model_jscad: z120.any().optional()
2542
2558
  }).describe("Defines a component on the PCB");
2543
2559
  expectTypesMatch(true);
2544
2560
 
2545
2561
  // src/simulation/simulation_voltage_source.ts
2546
- import { z as z120 } from "zod";
2547
- var wave_shape = z120.enum(["sinewave", "square", "triangle", "sawtooth"]);
2548
- var percentage = z120.union([z120.string(), z120.number()]).transform((val) => {
2562
+ import { z as z121 } from "zod";
2563
+ var wave_shape = z121.enum(["sinewave", "square", "triangle", "sawtooth"]);
2564
+ var percentage = z121.union([z121.string(), z121.number()]).transform((val) => {
2549
2565
  if (typeof val === "string") {
2550
2566
  if (val.endsWith("%")) {
2551
2567
  return parseFloat(val.slice(0, -1)) / 100;
@@ -2554,30 +2570,30 @@ var percentage = z120.union([z120.string(), z120.number()]).transform((val) => {
2554
2570
  }
2555
2571
  return val;
2556
2572
  }).pipe(
2557
- z120.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
2573
+ z121.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
2558
2574
  );
2559
- var simulation_dc_voltage_source = z120.object({
2560
- type: z120.literal("simulation_voltage_source"),
2575
+ var simulation_dc_voltage_source = z121.object({
2576
+ type: z121.literal("simulation_voltage_source"),
2561
2577
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
2562
2578
  "simulation_voltage_source"
2563
2579
  ),
2564
- is_dc_source: z120.literal(true).optional().default(true),
2565
- positive_source_port_id: z120.string().optional(),
2566
- negative_source_port_id: z120.string().optional(),
2567
- positive_source_net_id: z120.string().optional(),
2568
- negative_source_net_id: z120.string().optional(),
2580
+ is_dc_source: z121.literal(true).optional().default(true),
2581
+ positive_source_port_id: z121.string().optional(),
2582
+ negative_source_port_id: z121.string().optional(),
2583
+ positive_source_net_id: z121.string().optional(),
2584
+ negative_source_net_id: z121.string().optional(),
2569
2585
  voltage
2570
2586
  }).describe("Defines a DC voltage source for simulation");
2571
- var simulation_ac_voltage_source = z120.object({
2572
- type: z120.literal("simulation_voltage_source"),
2587
+ var simulation_ac_voltage_source = z121.object({
2588
+ type: z121.literal("simulation_voltage_source"),
2573
2589
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
2574
2590
  "simulation_voltage_source"
2575
2591
  ),
2576
- is_dc_source: z120.literal(false),
2577
- terminal1_source_port_id: z120.string().optional(),
2578
- terminal2_source_port_id: z120.string().optional(),
2579
- terminal1_source_net_id: z120.string().optional(),
2580
- terminal2_source_net_id: z120.string().optional(),
2592
+ is_dc_source: z121.literal(false),
2593
+ terminal1_source_port_id: z121.string().optional(),
2594
+ terminal2_source_port_id: z121.string().optional(),
2595
+ terminal1_source_net_id: z121.string().optional(),
2596
+ terminal2_source_net_id: z121.string().optional(),
2581
2597
  voltage: voltage.optional(),
2582
2598
  frequency: frequency.optional(),
2583
2599
  peak_to_peak_voltage: voltage.optional(),
@@ -2585,25 +2601,25 @@ var simulation_ac_voltage_source = z120.object({
2585
2601
  phase: rotation.optional(),
2586
2602
  duty_cycle: percentage.optional()
2587
2603
  }).describe("Defines an AC voltage source for simulation");
2588
- var simulation_voltage_source = z120.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
2604
+ var simulation_voltage_source = z121.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
2589
2605
  expectTypesMatch(true);
2590
2606
  expectTypesMatch(true);
2591
2607
  expectTypesMatch(true);
2592
2608
 
2593
2609
  // src/simulation/simulation_experiment.ts
2594
- import { z as z121 } from "zod";
2595
- var experiment_type = z121.union([
2596
- z121.literal("spice_dc_sweep"),
2597
- z121.literal("spice_dc_operating_point"),
2598
- z121.literal("spice_transient_analysis"),
2599
- z121.literal("spice_ac_analysis")
2610
+ import { z as z122 } from "zod";
2611
+ var experiment_type = z122.union([
2612
+ z122.literal("spice_dc_sweep"),
2613
+ z122.literal("spice_dc_operating_point"),
2614
+ z122.literal("spice_transient_analysis"),
2615
+ z122.literal("spice_ac_analysis")
2600
2616
  ]);
2601
- var simulation_experiment = z121.object({
2602
- type: z121.literal("simulation_experiment"),
2617
+ var simulation_experiment = z122.object({
2618
+ type: z122.literal("simulation_experiment"),
2603
2619
  simulation_experiment_id: getZodPrefixedIdWithDefault(
2604
2620
  "simulation_experiment"
2605
2621
  ),
2606
- name: z121.string(),
2622
+ name: z122.string(),
2607
2623
  experiment_type,
2608
2624
  time_per_step: duration_ms.optional(),
2609
2625
  start_time_ms: ms.optional(),
@@ -2612,48 +2628,49 @@ var simulation_experiment = z121.object({
2612
2628
  expectTypesMatch(true);
2613
2629
 
2614
2630
  // src/simulation/simulation_transient_voltage_graph.ts
2615
- import { z as z122 } from "zod";
2616
- var simulation_transient_voltage_graph = z122.object({
2617
- type: z122.literal("simulation_transient_voltage_graph"),
2631
+ import { z as z123 } from "zod";
2632
+ var simulation_transient_voltage_graph = z123.object({
2633
+ type: z123.literal("simulation_transient_voltage_graph"),
2618
2634
  simulation_transient_voltage_graph_id: getZodPrefixedIdWithDefault(
2619
2635
  "simulation_transient_voltage_graph"
2620
2636
  ),
2621
- simulation_experiment_id: z122.string(),
2622
- timestamps_ms: z122.array(z122.number()).optional(),
2623
- voltage_levels: z122.array(z122.number()),
2624
- schematic_voltage_probe_id: z122.string().optional(),
2625
- simulation_voltage_probe_id: z122.string().optional(),
2626
- subcircuit_connectivity_map_key: z122.string().optional(),
2637
+ simulation_experiment_id: z123.string(),
2638
+ timestamps_ms: z123.array(z123.number()).optional(),
2639
+ voltage_levels: z123.array(z123.number()),
2640
+ schematic_voltage_probe_id: z123.string().optional(),
2641
+ simulation_voltage_probe_id: z123.string().optional(),
2642
+ subcircuit_connectivity_map_key: z123.string().optional(),
2627
2643
  time_per_step: duration_ms,
2628
2644
  start_time_ms: ms,
2629
2645
  end_time_ms: ms,
2630
- name: z122.string().optional()
2646
+ name: z123.string().optional()
2631
2647
  }).describe("Stores voltage measurements over time for a simulation");
2632
2648
  expectTypesMatch(true);
2633
2649
 
2634
2650
  // src/simulation/simulation_switch.ts
2635
- import { z as z123 } from "zod";
2636
- var simulation_switch = z123.object({
2637
- type: z123.literal("simulation_switch"),
2651
+ import { z as z124 } from "zod";
2652
+ var simulation_switch = z124.object({
2653
+ type: z124.literal("simulation_switch"),
2638
2654
  simulation_switch_id: getZodPrefixedIdWithDefault("simulation_switch"),
2655
+ source_component_id: z124.string().optional(),
2639
2656
  closes_at: ms.optional(),
2640
2657
  opens_at: ms.optional(),
2641
- starts_closed: z123.boolean().optional(),
2658
+ starts_closed: z124.boolean().optional(),
2642
2659
  switching_frequency: frequency.optional()
2643
2660
  }).describe("Defines a switch for simulation timing control");
2644
2661
  expectTypesMatch(true);
2645
2662
 
2646
2663
  // src/simulation/simulation_voltage_probe.ts
2647
- import { z as z124 } from "zod";
2648
- var simulation_voltage_probe = z124.object({
2649
- type: z124.literal("simulation_voltage_probe"),
2664
+ import { z as z125 } from "zod";
2665
+ var simulation_voltage_probe = z125.object({
2666
+ type: z125.literal("simulation_voltage_probe"),
2650
2667
  simulation_voltage_probe_id: getZodPrefixedIdWithDefault(
2651
2668
  "simulation_voltage_probe"
2652
2669
  ),
2653
- source_port_id: z124.string().optional(),
2654
- source_net_id: z124.string().optional(),
2655
- name: z124.string().optional(),
2656
- subcircuit_id: z124.string().optional()
2670
+ source_port_id: z125.string().optional(),
2671
+ source_net_id: z125.string().optional(),
2672
+ name: z125.string().optional(),
2673
+ subcircuit_id: z125.string().optional()
2657
2674
  }).describe(
2658
2675
  "Defines a voltage probe for simulation, connected to a port or a net"
2659
2676
  ).refine(
@@ -2665,8 +2682,8 @@ var simulation_voltage_probe = z124.object({
2665
2682
  expectTypesMatch(true);
2666
2683
 
2667
2684
  // src/any_circuit_element.ts
2668
- import { z as z125 } from "zod";
2669
- var any_circuit_element = z125.union([
2685
+ import { z as z126 } from "zod";
2686
+ var any_circuit_element = z126.union([
2670
2687
  source_trace,
2671
2688
  source_port,
2672
2689
  any_source_component,
@@ -2747,6 +2764,7 @@ var any_circuit_element = z125.union([
2747
2764
  pcb_component_invalid_layer_error,
2748
2765
  pcb_courtyard_rect,
2749
2766
  pcb_courtyard_outline,
2767
+ pcb_courtyard_polygon,
2750
2768
  schematic_box,
2751
2769
  schematic_text,
2752
2770
  schematic_line,
@@ -2810,6 +2828,7 @@ export {
2810
2828
  pcb_copper_pour_polygon,
2811
2829
  pcb_copper_pour_rect,
2812
2830
  pcb_courtyard_outline,
2831
+ pcb_courtyard_polygon,
2813
2832
  pcb_courtyard_rect,
2814
2833
  pcb_cutout,
2815
2834
  pcb_cutout_circle,