circuit-json 0.0.468 → 0.0.469

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/dist/index.mjs CHANGED
@@ -890,6 +890,7 @@ var source_trace = z57.object({
890
890
  subcircuit_id: z57.string().optional(),
891
891
  subcircuit_connectivity_map_key: z57.string().optional(),
892
892
  max_length: z57.number().optional(),
893
+ max_via_count: z57.number().int().nonnegative().optional(),
893
894
  name: z57.string().optional(),
894
895
  min_trace_thickness: z57.number().optional(),
895
896
  display_name: z57.string().optional()
@@ -2491,84 +2492,104 @@ var pcb_trace_too_long_warning = z112.object({
2491
2492
  );
2492
2493
  expectTypesMatch(true);
2493
2494
 
2494
- // src/pcb/pcb_trace_error.ts
2495
+ // src/pcb/pcb_trace_too_many_vias_warning.ts
2495
2496
  import { z as z113 } from "zod";
2497
+ var pcb_trace_too_many_vias_warning = z113.object({
2498
+ type: z113.literal("pcb_trace_too_many_vias_warning"),
2499
+ pcb_trace_too_many_vias_warning_id: getZodPrefixedIdWithDefault(
2500
+ "pcb_trace_too_many_vias_warning"
2501
+ ),
2502
+ warning_type: z113.literal("pcb_trace_too_many_vias_warning").default("pcb_trace_too_many_vias_warning"),
2503
+ message: z113.string(),
2504
+ pcb_trace_id: z113.string(),
2505
+ source_net_id: z113.string().optional(),
2506
+ source_trace_id: z113.string().optional(),
2507
+ actual_via_count: z113.number().int().nonnegative(),
2508
+ maximum_via_count: z113.number().int().nonnegative(),
2509
+ subcircuit_id: z113.string().optional()
2510
+ }).describe(
2511
+ "Warning emitted when a PCB trace has more vias than its maximum allowed count"
2512
+ );
2513
+ expectTypesMatch(true);
2514
+
2515
+ // src/pcb/pcb_trace_error.ts
2516
+ import { z as z114 } from "zod";
2496
2517
  var pcb_trace_error = base_circuit_json_error.extend({
2497
- type: z113.literal("pcb_trace_error"),
2518
+ type: z114.literal("pcb_trace_error"),
2498
2519
  pcb_trace_error_id: getZodPrefixedIdWithDefault("pcb_trace_error"),
2499
- error_type: z113.literal("pcb_trace_error").default("pcb_trace_error"),
2520
+ error_type: z114.literal("pcb_trace_error").default("pcb_trace_error"),
2500
2521
  center: point.optional(),
2501
- pcb_trace_id: z113.string(),
2502
- source_trace_id: z113.string(),
2503
- pcb_component_ids: z113.array(z113.string()),
2504
- pcb_port_ids: z113.array(z113.string()),
2505
- subcircuit_id: z113.string().optional()
2522
+ pcb_trace_id: z114.string(),
2523
+ source_trace_id: z114.string(),
2524
+ pcb_component_ids: z114.array(z114.string()),
2525
+ pcb_port_ids: z114.array(z114.string()),
2526
+ subcircuit_id: z114.string().optional()
2506
2527
  }).describe("Defines a trace error on the PCB");
2507
2528
  expectTypesMatch(true);
2508
2529
 
2509
2530
  // src/pcb/pcb_trace_missing_error.ts
2510
- import { z as z114 } from "zod";
2531
+ import { z as z115 } from "zod";
2511
2532
  var pcb_trace_missing_error = base_circuit_json_error.extend({
2512
- type: z114.literal("pcb_trace_missing_error"),
2533
+ type: z115.literal("pcb_trace_missing_error"),
2513
2534
  pcb_trace_missing_error_id: getZodPrefixedIdWithDefault(
2514
2535
  "pcb_trace_missing_error"
2515
2536
  ),
2516
- error_type: z114.literal("pcb_trace_missing_error").default("pcb_trace_missing_error"),
2537
+ error_type: z115.literal("pcb_trace_missing_error").default("pcb_trace_missing_error"),
2517
2538
  center: point.optional(),
2518
- source_trace_id: z114.string(),
2519
- pcb_component_ids: z114.array(z114.string()),
2520
- pcb_port_ids: z114.array(z114.string()),
2521
- subcircuit_id: z114.string().optional()
2539
+ source_trace_id: z115.string(),
2540
+ pcb_component_ids: z115.array(z115.string()),
2541
+ pcb_port_ids: z115.array(z115.string()),
2542
+ subcircuit_id: z115.string().optional()
2522
2543
  }).describe(
2523
2544
  "Defines an error when a source trace has no corresponding PCB trace"
2524
2545
  );
2525
2546
  expectTypesMatch(true);
2526
2547
 
2527
2548
  // src/pcb/pcb_port_not_matched_error.ts
2528
- import { z as z115 } from "zod";
2549
+ import { z as z116 } from "zod";
2529
2550
  var pcb_port_not_matched_error = base_circuit_json_error.extend({
2530
- type: z115.literal("pcb_port_not_matched_error"),
2551
+ type: z116.literal("pcb_port_not_matched_error"),
2531
2552
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
2532
- error_type: z115.literal("pcb_port_not_matched_error").default("pcb_port_not_matched_error"),
2533
- pcb_component_ids: z115.array(z115.string()),
2534
- subcircuit_id: z115.string().optional()
2553
+ error_type: z116.literal("pcb_port_not_matched_error").default("pcb_port_not_matched_error"),
2554
+ pcb_component_ids: z116.array(z116.string()),
2555
+ subcircuit_id: z116.string().optional()
2535
2556
  }).describe("Defines a trace error on the PCB where a port is not matched");
2536
2557
  expectTypesMatch(true);
2537
2558
 
2538
2559
  // src/pcb/pcb_port_not_connected_error.ts
2539
- import { z as z116 } from "zod";
2560
+ import { z as z117 } from "zod";
2540
2561
  var pcb_port_not_connected_error = base_circuit_json_error.extend({
2541
- type: z116.literal("pcb_port_not_connected_error"),
2562
+ type: z117.literal("pcb_port_not_connected_error"),
2542
2563
  pcb_port_not_connected_error_id: getZodPrefixedIdWithDefault(
2543
2564
  "pcb_port_not_connected_error"
2544
2565
  ),
2545
- error_type: z116.literal("pcb_port_not_connected_error").default("pcb_port_not_connected_error"),
2546
- pcb_port_ids: z116.array(z116.string()),
2547
- pcb_component_ids: z116.array(z116.string()),
2548
- subcircuit_id: z116.string().optional()
2566
+ error_type: z117.literal("pcb_port_not_connected_error").default("pcb_port_not_connected_error"),
2567
+ pcb_port_ids: z117.array(z117.string()),
2568
+ pcb_component_ids: z117.array(z117.string()),
2569
+ subcircuit_id: z117.string().optional()
2549
2570
  }).describe("Defines an error when a pcb port is not connected to any trace");
2550
2571
  expectTypesMatch(
2551
2572
  true
2552
2573
  );
2553
2574
 
2554
2575
  // src/pcb/pcb_net.ts
2555
- import { z as z117 } from "zod";
2556
- var pcb_net = z117.object({
2557
- type: z117.literal("pcb_net"),
2576
+ import { z as z118 } from "zod";
2577
+ var pcb_net = z118.object({
2578
+ type: z118.literal("pcb_net"),
2558
2579
  pcb_net_id: getZodPrefixedIdWithDefault("pcb_net"),
2559
- source_net_id: z117.string().optional(),
2560
- highlight_color: z117.string().optional()
2580
+ source_net_id: z118.string().optional(),
2581
+ highlight_color: z118.string().optional()
2561
2582
  }).describe("Defines a net on the PCB");
2562
2583
  expectTypesMatch(true);
2563
2584
 
2564
2585
  // src/pcb/pcb_via.ts
2565
- import { z as z118 } from "zod";
2566
- var pcb_via = z118.object({
2567
- type: z118.literal("pcb_via"),
2586
+ import { z as z119 } from "zod";
2587
+ var pcb_via = z119.object({
2588
+ type: z119.literal("pcb_via"),
2568
2589
  pcb_via_id: getZodPrefixedIdWithDefault("pcb_via"),
2569
- pcb_group_id: z118.string().optional(),
2570
- subcircuit_id: z118.string().optional(),
2571
- subcircuit_connectivity_map_key: z118.string().optional(),
2590
+ pcb_group_id: z119.string().optional(),
2591
+ subcircuit_id: z119.string().optional(),
2592
+ subcircuit_connectivity_map_key: z119.string().optional(),
2572
2593
  x: distance,
2573
2594
  y: distance,
2574
2595
  outer_diameter: distance.default("0.6mm"),
@@ -2577,117 +2598,117 @@ var pcb_via = z118.object({
2577
2598
  from_layer: layer_ref.optional(),
2578
2599
  /** @deprecated */
2579
2600
  to_layer: layer_ref.optional(),
2580
- layers: z118.array(layer_ref),
2581
- pcb_trace_id: z118.string().optional(),
2582
- source_trace_id: z118.string().optional(),
2583
- source_net_id: z118.string().min(1).optional(),
2584
- net_is_assignable: z118.boolean().optional(),
2585
- net_assigned: z118.boolean().optional(),
2586
- is_tented: z118.boolean().optional()
2601
+ layers: z119.array(layer_ref),
2602
+ pcb_trace_id: z119.string().optional(),
2603
+ source_trace_id: z119.string().optional(),
2604
+ source_net_id: z119.string().min(1).optional(),
2605
+ net_is_assignable: z119.boolean().optional(),
2606
+ net_assigned: z119.boolean().optional(),
2607
+ is_tented: z119.boolean().optional()
2587
2608
  }).describe("Defines a via on the PCB");
2588
2609
  expectTypesMatch(true);
2589
2610
 
2590
2611
  // src/pcb/pcb_board.ts
2591
- import { z as z119 } from "zod";
2592
- var pcb_board = z119.object({
2593
- type: z119.literal("pcb_board"),
2612
+ import { z as z120 } from "zod";
2613
+ var pcb_board = z120.object({
2614
+ type: z120.literal("pcb_board"),
2594
2615
  pcb_board_id: getZodPrefixedIdWithDefault("pcb_board"),
2595
- pcb_panel_id: z119.string().optional(),
2596
- carrier_pcb_board_id: z119.string().optional(),
2597
- is_subcircuit: z119.boolean().optional(),
2598
- subcircuit_id: z119.string().optional(),
2599
- is_mounted_to_carrier_board: z119.boolean().optional(),
2600
- is_via_in_pad_allowed: z119.boolean().optional(),
2616
+ pcb_panel_id: z120.string().optional(),
2617
+ carrier_pcb_board_id: z120.string().optional(),
2618
+ is_subcircuit: z120.boolean().optional(),
2619
+ subcircuit_id: z120.string().optional(),
2620
+ is_mounted_to_carrier_board: z120.boolean().optional(),
2621
+ is_via_in_pad_allowed: z120.boolean().optional(),
2601
2622
  width: length.optional(),
2602
2623
  height: length.optional(),
2603
2624
  center: point,
2604
- display_offset_x: z119.string().optional().describe(
2625
+ display_offset_x: z120.string().optional().describe(
2605
2626
  "How to display the x offset for this board, usually corresponding with how the user specified it"
2606
2627
  ),
2607
- display_offset_y: z119.string().optional().describe(
2628
+ display_offset_y: z120.string().optional().describe(
2608
2629
  "How to display the y offset for this board, usually corresponding with how the user specified it"
2609
2630
  ),
2610
2631
  thickness: length.optional().default(1.4),
2611
- num_layers: z119.number().optional().default(4),
2612
- outline: z119.array(point).optional(),
2613
- shape: z119.enum(["rect", "polygon"]).optional(),
2614
- material: z119.enum(["fr4", "fr1"]).default("fr4"),
2615
- solder_mask_color: z119.string().optional(),
2616
- silkscreen_color: z119.string().optional(),
2632
+ num_layers: z120.number().optional().default(4),
2633
+ outline: z120.array(point).optional(),
2634
+ shape: z120.enum(["rect", "polygon"]).optional(),
2635
+ material: z120.enum(["fr4", "fr1"]).default("fr4"),
2636
+ solder_mask_color: z120.string().optional(),
2637
+ silkscreen_color: z120.string().optional(),
2617
2638
  anchor_position: point.optional(),
2618
2639
  anchor_alignment: ninePointAnchor.optional(),
2619
- position_mode: z119.enum(["relative_to_panel_anchor", "none"]).optional()
2640
+ position_mode: z120.enum(["relative_to_panel_anchor", "none"]).optional()
2620
2641
  }).merge(manufacturing_drc_properties).describe("Defines the board outline of the PCB");
2621
2642
  expectTypesMatch(true);
2622
2643
 
2623
2644
  // src/pcb/pcb_panel.ts
2624
- import { z as z120 } from "zod";
2625
- var pcb_panel = z120.object({
2626
- type: z120.literal("pcb_panel"),
2645
+ import { z as z121 } from "zod";
2646
+ var pcb_panel = z121.object({
2647
+ type: z121.literal("pcb_panel"),
2627
2648
  pcb_panel_id: getZodPrefixedIdWithDefault("pcb_panel"),
2628
2649
  width: length,
2629
2650
  height: length,
2630
2651
  center: point,
2631
2652
  thickness: length.optional().default(1.4),
2632
- covered_with_solder_mask: z120.boolean().optional().default(true)
2653
+ covered_with_solder_mask: z121.boolean().optional().default(true)
2633
2654
  }).describe("Defines a PCB panel that can contain multiple boards");
2634
2655
  expectTypesMatch(true);
2635
2656
 
2636
2657
  // src/pcb/pcb_placement_error.ts
2637
- import { z as z121 } from "zod";
2658
+ import { z as z122 } from "zod";
2638
2659
  var pcb_placement_error = base_circuit_json_error.extend({
2639
- type: z121.literal("pcb_placement_error"),
2660
+ type: z122.literal("pcb_placement_error"),
2640
2661
  pcb_placement_error_id: getZodPrefixedIdWithDefault("pcb_placement_error"),
2641
- error_type: z121.literal("pcb_placement_error").default("pcb_placement_error"),
2642
- subcircuit_id: z121.string().optional()
2662
+ error_type: z122.literal("pcb_placement_error").default("pcb_placement_error"),
2663
+ subcircuit_id: z122.string().optional()
2643
2664
  }).describe("Defines a placement error on the PCB");
2644
2665
  expectTypesMatch(true);
2645
2666
 
2646
2667
  // src/pcb/pcb_packing_error.ts
2647
- import { z as z122 } from "zod";
2668
+ import { z as z123 } from "zod";
2648
2669
  var pcb_packing_error = base_circuit_json_error.extend({
2649
- type: z122.literal("pcb_packing_error"),
2670
+ type: z123.literal("pcb_packing_error"),
2650
2671
  pcb_packing_error_id: getZodPrefixedIdWithDefault("pcb_packing_error"),
2651
- error_type: z122.literal("pcb_packing_error").default("pcb_packing_error"),
2652
- pcb_group_id: z122.string().optional(),
2653
- subcircuit_id: z122.string().optional()
2672
+ error_type: z123.literal("pcb_packing_error").default("pcb_packing_error"),
2673
+ pcb_group_id: z123.string().optional(),
2674
+ subcircuit_id: z123.string().optional()
2654
2675
  }).describe("Defines a failure to pack PCB components within layout bounds");
2655
2676
  expectTypesMatch(true);
2656
2677
 
2657
2678
  // src/pcb/pcb_panelization_placement_error.ts
2658
- import { z as z123 } from "zod";
2679
+ import { z as z124 } from "zod";
2659
2680
  var pcb_panelization_placement_error = base_circuit_json_error.extend({
2660
- type: z123.literal("pcb_panelization_placement_error"),
2681
+ type: z124.literal("pcb_panelization_placement_error"),
2661
2682
  pcb_panelization_placement_error_id: getZodPrefixedIdWithDefault(
2662
2683
  "pcb_panelization_placement_error"
2663
2684
  ),
2664
- error_type: z123.literal("pcb_panelization_placement_error").default("pcb_panelization_placement_error"),
2665
- pcb_panel_id: z123.string().optional(),
2666
- pcb_board_id: z123.string().optional(),
2667
- subcircuit_id: z123.string().optional()
2685
+ error_type: z124.literal("pcb_panelization_placement_error").default("pcb_panelization_placement_error"),
2686
+ pcb_panel_id: z124.string().optional(),
2687
+ pcb_board_id: z124.string().optional(),
2688
+ subcircuit_id: z124.string().optional()
2668
2689
  }).describe("Defines a panelization placement error on the PCB");
2669
2690
  expectTypesMatch(true);
2670
2691
 
2671
2692
  // src/pcb/pcb_trace_hint.ts
2672
- import { z as z124 } from "zod";
2673
- var pcb_trace_hint = z124.object({
2674
- type: z124.literal("pcb_trace_hint"),
2693
+ import { z as z125 } from "zod";
2694
+ var pcb_trace_hint = z125.object({
2695
+ type: z125.literal("pcb_trace_hint"),
2675
2696
  pcb_trace_hint_id: getZodPrefixedIdWithDefault("pcb_trace_hint"),
2676
- pcb_port_id: z124.string(),
2677
- pcb_component_id: z124.string(),
2678
- route: z124.array(route_hint_point),
2679
- subcircuit_id: z124.string().optional()
2697
+ pcb_port_id: z125.string(),
2698
+ pcb_component_id: z125.string(),
2699
+ route: z125.array(route_hint_point),
2700
+ subcircuit_id: z125.string().optional()
2680
2701
  }).describe("A hint that can be used during generation of a PCB trace");
2681
2702
  expectTypesMatch(true);
2682
2703
 
2683
2704
  // src/pcb/pcb_silkscreen_line.ts
2684
- import { z as z125 } from "zod";
2685
- var pcb_silkscreen_line = z125.object({
2686
- type: z125.literal("pcb_silkscreen_line"),
2705
+ import { z as z126 } from "zod";
2706
+ var pcb_silkscreen_line = z126.object({
2707
+ type: z126.literal("pcb_silkscreen_line"),
2687
2708
  pcb_silkscreen_line_id: getZodPrefixedIdWithDefault("pcb_silkscreen_line"),
2688
- pcb_component_id: z125.string(),
2689
- pcb_group_id: z125.string().optional(),
2690
- subcircuit_id: z125.string().optional(),
2709
+ pcb_component_id: z126.string(),
2710
+ pcb_group_id: z126.string().optional(),
2711
+ subcircuit_id: z126.string().optional(),
2691
2712
  stroke_width: distance.default("0.1mm"),
2692
2713
  x1: distance,
2693
2714
  y1: distance,
@@ -2698,32 +2719,32 @@ var pcb_silkscreen_line = z125.object({
2698
2719
  expectTypesMatch(true);
2699
2720
 
2700
2721
  // src/pcb/pcb_silkscreen_path.ts
2701
- import { z as z126 } from "zod";
2702
- var pcb_silkscreen_path = z126.object({
2703
- type: z126.literal("pcb_silkscreen_path"),
2722
+ import { z as z127 } from "zod";
2723
+ var pcb_silkscreen_path = z127.object({
2724
+ type: z127.literal("pcb_silkscreen_path"),
2704
2725
  pcb_silkscreen_path_id: getZodPrefixedIdWithDefault("pcb_silkscreen_path"),
2705
- pcb_component_id: z126.string(),
2706
- pcb_group_id: z126.string().optional(),
2707
- subcircuit_id: z126.string().optional(),
2726
+ pcb_component_id: z127.string(),
2727
+ pcb_group_id: z127.string().optional(),
2728
+ subcircuit_id: z127.string().optional(),
2708
2729
  layer: visible_layer,
2709
- route: z126.array(point),
2730
+ route: z127.array(point),
2710
2731
  stroke_width: length
2711
2732
  }).describe("Defines a silkscreen path on the PCB");
2712
2733
  expectTypesMatch(true);
2713
2734
 
2714
2735
  // src/pcb/pcb_silkscreen_text.ts
2715
- import { z as z127 } from "zod";
2716
- var pcb_silkscreen_text = z127.object({
2717
- type: z127.literal("pcb_silkscreen_text"),
2736
+ import { z as z128 } from "zod";
2737
+ var pcb_silkscreen_text = z128.object({
2738
+ type: z128.literal("pcb_silkscreen_text"),
2718
2739
  pcb_silkscreen_text_id: getZodPrefixedIdWithDefault("pcb_silkscreen_text"),
2719
- pcb_group_id: z127.string().optional(),
2720
- subcircuit_id: z127.string().optional(),
2721
- font: z127.literal("tscircuit2024").default("tscircuit2024"),
2740
+ pcb_group_id: z128.string().optional(),
2741
+ subcircuit_id: z128.string().optional(),
2742
+ font: z128.literal("tscircuit2024").default("tscircuit2024"),
2722
2743
  font_size: distance.default("0.2mm"),
2723
- pcb_component_id: z127.string(),
2724
- text: z127.string(),
2725
- is_knockout: z127.boolean().default(false).optional(),
2726
- knockout_padding: z127.object({
2744
+ pcb_component_id: z128.string(),
2745
+ text: z128.string(),
2746
+ is_knockout: z128.boolean().default(false).optional(),
2747
+ knockout_padding: z128.object({
2727
2748
  left: length,
2728
2749
  top: length,
2729
2750
  bottom: length,
@@ -2734,27 +2755,27 @@ var pcb_silkscreen_text = z127.object({
2734
2755
  bottom: "0.2mm",
2735
2756
  right: "0.2mm"
2736
2757
  }).optional(),
2737
- ccw_rotation: z127.number().optional(),
2758
+ ccw_rotation: z128.number().optional(),
2738
2759
  layer: layer_ref,
2739
- is_mirrored: z127.boolean().default(false).optional(),
2760
+ is_mirrored: z128.boolean().default(false).optional(),
2740
2761
  anchor_position: point.default({ x: 0, y: 0 }),
2741
2762
  anchor_alignment: ninePointAnchor.default("center")
2742
2763
  }).describe("Defines silkscreen text on the PCB");
2743
2764
  expectTypesMatch(true);
2744
2765
 
2745
2766
  // src/pcb/pcb_copper_text.ts
2746
- import { z as z128 } from "zod";
2747
- var pcb_copper_text = z128.object({
2748
- type: z128.literal("pcb_copper_text"),
2767
+ import { z as z129 } from "zod";
2768
+ var pcb_copper_text = z129.object({
2769
+ type: z129.literal("pcb_copper_text"),
2749
2770
  pcb_copper_text_id: getZodPrefixedIdWithDefault("pcb_copper_text"),
2750
- pcb_group_id: z128.string().optional(),
2751
- subcircuit_id: z128.string().optional(),
2752
- font: z128.literal("tscircuit2024").default("tscircuit2024"),
2771
+ pcb_group_id: z129.string().optional(),
2772
+ subcircuit_id: z129.string().optional(),
2773
+ font: z129.literal("tscircuit2024").default("tscircuit2024"),
2753
2774
  font_size: distance.default("0.2mm"),
2754
- pcb_component_id: z128.string(),
2755
- text: z128.string(),
2756
- is_knockout: z128.boolean().default(false).optional(),
2757
- knockout_padding: z128.object({
2775
+ pcb_component_id: z129.string(),
2776
+ text: z129.string(),
2777
+ is_knockout: z129.boolean().default(false).optional(),
2778
+ knockout_padding: z129.object({
2758
2779
  left: length,
2759
2780
  top: length,
2760
2781
  bottom: length,
@@ -2765,61 +2786,61 @@ var pcb_copper_text = z128.object({
2765
2786
  bottom: "0.2mm",
2766
2787
  right: "0.2mm"
2767
2788
  }).optional(),
2768
- ccw_rotation: z128.number().optional(),
2789
+ ccw_rotation: z129.number().optional(),
2769
2790
  layer: layer_ref,
2770
- is_mirrored: z128.boolean().default(false).optional(),
2791
+ is_mirrored: z129.boolean().default(false).optional(),
2771
2792
  anchor_position: point.default({ x: 0, y: 0 }),
2772
2793
  anchor_alignment: ninePointAnchor.default("center")
2773
2794
  }).describe("Defines copper text on the PCB");
2774
2795
  expectTypesMatch(true);
2775
2796
 
2776
2797
  // src/pcb/pcb_silkscreen_rect.ts
2777
- import { z as z129 } from "zod";
2778
- var pcb_silkscreen_rect = z129.object({
2779
- type: z129.literal("pcb_silkscreen_rect"),
2798
+ import { z as z130 } from "zod";
2799
+ var pcb_silkscreen_rect = z130.object({
2800
+ type: z130.literal("pcb_silkscreen_rect"),
2780
2801
  pcb_silkscreen_rect_id: getZodPrefixedIdWithDefault("pcb_silkscreen_rect"),
2781
- pcb_component_id: z129.string(),
2782
- pcb_group_id: z129.string().optional(),
2783
- subcircuit_id: z129.string().optional(),
2802
+ pcb_component_id: z130.string(),
2803
+ pcb_group_id: z130.string().optional(),
2804
+ subcircuit_id: z130.string().optional(),
2784
2805
  center: point,
2785
2806
  width: length,
2786
2807
  height: length,
2787
2808
  layer: layer_ref,
2788
2809
  stroke_width: length.default("1mm"),
2789
2810
  corner_radius: length.optional(),
2790
- is_filled: z129.boolean().default(true).optional(),
2791
- has_stroke: z129.boolean().optional(),
2792
- is_stroke_dashed: z129.boolean().optional(),
2793
- ccw_rotation: z129.number().optional()
2811
+ is_filled: z130.boolean().default(true).optional(),
2812
+ has_stroke: z130.boolean().optional(),
2813
+ is_stroke_dashed: z130.boolean().optional(),
2814
+ ccw_rotation: z130.number().optional()
2794
2815
  }).describe("Defines a silkscreen rect on the PCB");
2795
2816
  expectTypesMatch(true);
2796
2817
 
2797
2818
  // src/pcb/pcb_silkscreen_circle.ts
2798
- import { z as z130 } from "zod";
2799
- var pcb_silkscreen_circle = z130.object({
2800
- type: z130.literal("pcb_silkscreen_circle"),
2819
+ import { z as z131 } from "zod";
2820
+ var pcb_silkscreen_circle = z131.object({
2821
+ type: z131.literal("pcb_silkscreen_circle"),
2801
2822
  pcb_silkscreen_circle_id: getZodPrefixedIdWithDefault(
2802
2823
  "pcb_silkscreen_circle"
2803
2824
  ),
2804
- pcb_component_id: z130.string(),
2805
- pcb_group_id: z130.string().optional(),
2806
- subcircuit_id: z130.string().optional(),
2825
+ pcb_component_id: z131.string(),
2826
+ pcb_group_id: z131.string().optional(),
2827
+ subcircuit_id: z131.string().optional(),
2807
2828
  center: point,
2808
2829
  radius: length,
2809
2830
  layer: visible_layer,
2810
2831
  stroke_width: length.default("1mm"),
2811
- is_filled: z130.boolean().optional()
2832
+ is_filled: z131.boolean().optional()
2812
2833
  }).describe("Defines a silkscreen circle on the PCB");
2813
2834
  expectTypesMatch(true);
2814
2835
 
2815
2836
  // src/pcb/pcb_silkscreen_oval.ts
2816
- import { z as z131 } from "zod";
2817
- var pcb_silkscreen_oval = z131.object({
2818
- type: z131.literal("pcb_silkscreen_oval"),
2837
+ import { z as z132 } from "zod";
2838
+ var pcb_silkscreen_oval = z132.object({
2839
+ type: z132.literal("pcb_silkscreen_oval"),
2819
2840
  pcb_silkscreen_oval_id: getZodPrefixedIdWithDefault("pcb_silkscreen_oval"),
2820
- pcb_component_id: z131.string(),
2821
- pcb_group_id: z131.string().optional(),
2822
- subcircuit_id: z131.string().optional(),
2841
+ pcb_component_id: z132.string(),
2842
+ pcb_group_id: z132.string().optional(),
2843
+ subcircuit_id: z132.string().optional(),
2823
2844
  center: point,
2824
2845
  radius_x: distance,
2825
2846
  radius_y: distance,
@@ -2829,265 +2850,265 @@ var pcb_silkscreen_oval = z131.object({
2829
2850
  expectTypesMatch(true);
2830
2851
 
2831
2852
  // src/pcb/pcb_silkscreen_graphic.ts
2832
- import { z as z132 } from "zod";
2833
- var pcb_silkscreen_graphic_base = z132.object({
2834
- type: z132.literal("pcb_silkscreen_graphic"),
2853
+ import { z as z133 } from "zod";
2854
+ var pcb_silkscreen_graphic_base = z133.object({
2855
+ type: z133.literal("pcb_silkscreen_graphic"),
2835
2856
  pcb_silkscreen_graphic_id: getZodPrefixedIdWithDefault(
2836
2857
  "pcb_silkscreen_graphic"
2837
2858
  ),
2838
- pcb_component_id: z132.string(),
2839
- pcb_group_id: z132.string().optional(),
2840
- subcircuit_id: z132.string().optional(),
2859
+ pcb_component_id: z133.string(),
2860
+ pcb_group_id: z133.string().optional(),
2861
+ subcircuit_id: z133.string().optional(),
2841
2862
  layer: visible_layer,
2842
2863
  image_asset: asset.optional()
2843
2864
  });
2844
2865
  var pcb_silkscreen_graphic_brep = pcb_silkscreen_graphic_base.extend({
2845
- shape: z132.literal("brep"),
2866
+ shape: z133.literal("brep"),
2846
2867
  brep_shape
2847
2868
  }).describe("Defines a BRep silkscreen graphic on the PCB");
2848
2869
  expectTypesMatch(
2849
2870
  true
2850
2871
  );
2851
- var pcb_silkscreen_graphic = z132.discriminatedUnion("shape", [pcb_silkscreen_graphic_brep]).describe("Defines a silkscreen graphic on the PCB");
2872
+ var pcb_silkscreen_graphic = z133.discriminatedUnion("shape", [pcb_silkscreen_graphic_brep]).describe("Defines a silkscreen graphic on the PCB");
2852
2873
  expectTypesMatch(true);
2853
2874
 
2854
2875
  // src/pcb/pcb_silkscreen_pill.ts
2855
- import { z as z133 } from "zod";
2856
- var pcb_silkscreen_pill = z133.object({
2857
- type: z133.literal("pcb_silkscreen_pill"),
2876
+ import { z as z134 } from "zod";
2877
+ var pcb_silkscreen_pill = z134.object({
2878
+ type: z134.literal("pcb_silkscreen_pill"),
2858
2879
  pcb_silkscreen_pill_id: getZodPrefixedIdWithDefault("pcb_silkscreen_pill"),
2859
- pcb_component_id: z133.string(),
2860
- pcb_group_id: z133.string().optional(),
2861
- subcircuit_id: z133.string().optional(),
2880
+ pcb_component_id: z134.string(),
2881
+ pcb_group_id: z134.string().optional(),
2882
+ subcircuit_id: z134.string().optional(),
2862
2883
  center: point,
2863
2884
  width: length,
2864
2885
  height: length,
2865
2886
  layer: layer_ref,
2866
- ccw_rotation: z133.number().optional()
2887
+ ccw_rotation: z134.number().optional()
2867
2888
  }).describe("Defines a silkscreen pill on the PCB");
2868
2889
  expectTypesMatch(true);
2869
2890
 
2870
2891
  // src/pcb/pcb_fabrication_note_text.ts
2871
- import { z as z134 } from "zod";
2872
- var pcb_fabrication_note_text = z134.object({
2873
- type: z134.literal("pcb_fabrication_note_text"),
2892
+ import { z as z135 } from "zod";
2893
+ var pcb_fabrication_note_text = z135.object({
2894
+ type: z135.literal("pcb_fabrication_note_text"),
2874
2895
  pcb_fabrication_note_text_id: getZodPrefixedIdWithDefault(
2875
2896
  "pcb_fabrication_note_text"
2876
2897
  ),
2877
- subcircuit_id: z134.string().optional(),
2878
- pcb_group_id: z134.string().optional(),
2879
- font: z134.literal("tscircuit2024").default("tscircuit2024"),
2898
+ subcircuit_id: z135.string().optional(),
2899
+ pcb_group_id: z135.string().optional(),
2900
+ font: z135.literal("tscircuit2024").default("tscircuit2024"),
2880
2901
  font_size: distance.default("1mm"),
2881
- pcb_component_id: z134.string(),
2882
- text: z134.string(),
2883
- ccw_rotation: z134.number().optional(),
2902
+ pcb_component_id: z135.string(),
2903
+ text: z135.string(),
2904
+ ccw_rotation: z135.number().optional(),
2884
2905
  layer: visible_layer,
2885
2906
  anchor_position: point.default({ x: 0, y: 0 }),
2886
- anchor_alignment: z134.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2887
- color: z134.string().optional()
2907
+ anchor_alignment: z135.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2908
+ color: z135.string().optional()
2888
2909
  }).describe(
2889
2910
  "Defines a fabrication note in text on the PCB, useful for leaving notes for assemblers or fabricators"
2890
2911
  );
2891
2912
  expectTypesMatch(true);
2892
2913
 
2893
2914
  // src/pcb/pcb_fabrication_note_path.ts
2894
- import { z as z135 } from "zod";
2895
- var pcb_fabrication_note_path = z135.object({
2896
- type: z135.literal("pcb_fabrication_note_path"),
2915
+ import { z as z136 } from "zod";
2916
+ var pcb_fabrication_note_path = z136.object({
2917
+ type: z136.literal("pcb_fabrication_note_path"),
2897
2918
  pcb_fabrication_note_path_id: getZodPrefixedIdWithDefault(
2898
2919
  "pcb_fabrication_note_path"
2899
2920
  ),
2900
- pcb_component_id: z135.string(),
2901
- subcircuit_id: z135.string().optional(),
2921
+ pcb_component_id: z136.string(),
2922
+ subcircuit_id: z136.string().optional(),
2902
2923
  layer: layer_ref,
2903
- route: z135.array(point),
2924
+ route: z136.array(point),
2904
2925
  stroke_width: length,
2905
- color: z135.string().optional()
2926
+ color: z136.string().optional()
2906
2927
  }).describe(
2907
2928
  "Defines a fabrication path on the PCB for fabricators or assemblers"
2908
2929
  );
2909
2930
  expectTypesMatch(true);
2910
2931
 
2911
2932
  // src/pcb/pcb_fabrication_note_rect.ts
2912
- import { z as z136 } from "zod";
2913
- var pcb_fabrication_note_rect = z136.object({
2914
- type: z136.literal("pcb_fabrication_note_rect"),
2933
+ import { z as z137 } from "zod";
2934
+ var pcb_fabrication_note_rect = z137.object({
2935
+ type: z137.literal("pcb_fabrication_note_rect"),
2915
2936
  pcb_fabrication_note_rect_id: getZodPrefixedIdWithDefault(
2916
2937
  "pcb_fabrication_note_rect"
2917
2938
  ),
2918
- pcb_component_id: z136.string(),
2919
- pcb_group_id: z136.string().optional(),
2920
- subcircuit_id: z136.string().optional(),
2939
+ pcb_component_id: z137.string(),
2940
+ pcb_group_id: z137.string().optional(),
2941
+ subcircuit_id: z137.string().optional(),
2921
2942
  center: point,
2922
2943
  width: length,
2923
2944
  height: length,
2924
2945
  layer: visible_layer,
2925
2946
  stroke_width: length.default("0.1mm"),
2926
2947
  corner_radius: length.optional(),
2927
- is_filled: z136.boolean().optional(),
2928
- has_stroke: z136.boolean().optional(),
2929
- is_stroke_dashed: z136.boolean().optional(),
2930
- color: z136.string().optional()
2948
+ is_filled: z137.boolean().optional(),
2949
+ has_stroke: z137.boolean().optional(),
2950
+ is_stroke_dashed: z137.boolean().optional(),
2951
+ color: z137.string().optional()
2931
2952
  }).describe("Defines a fabrication note rectangle on the PCB");
2932
2953
  expectTypesMatch(true);
2933
2954
 
2934
2955
  // src/pcb/pcb_fabrication_note_dimension.ts
2935
- import { z as z137 } from "zod";
2936
- var pcb_fabrication_note_dimension = z137.object({
2937
- type: z137.literal("pcb_fabrication_note_dimension"),
2956
+ import { z as z138 } from "zod";
2957
+ var pcb_fabrication_note_dimension = z138.object({
2958
+ type: z138.literal("pcb_fabrication_note_dimension"),
2938
2959
  pcb_fabrication_note_dimension_id: getZodPrefixedIdWithDefault(
2939
2960
  "pcb_fabrication_note_dimension"
2940
2961
  ),
2941
- pcb_component_id: z137.string(),
2942
- pcb_group_id: z137.string().optional(),
2943
- subcircuit_id: z137.string().optional(),
2962
+ pcb_component_id: z138.string(),
2963
+ pcb_group_id: z138.string().optional(),
2964
+ subcircuit_id: z138.string().optional(),
2944
2965
  layer: visible_layer,
2945
2966
  from: point,
2946
2967
  to: point,
2947
- text: z137.string().optional(),
2948
- text_ccw_rotation: z137.number().optional(),
2968
+ text: z138.string().optional(),
2969
+ text_ccw_rotation: z138.number().optional(),
2949
2970
  offset: length.optional(),
2950
2971
  offset_distance: length.optional(),
2951
- offset_direction: z137.object({
2952
- x: z137.number(),
2953
- y: z137.number()
2972
+ offset_direction: z138.object({
2973
+ x: z138.number(),
2974
+ y: z138.number()
2954
2975
  }).optional(),
2955
- font: z137.literal("tscircuit2024").default("tscircuit2024"),
2976
+ font: z138.literal("tscircuit2024").default("tscircuit2024"),
2956
2977
  font_size: length.default("1mm"),
2957
- color: z137.string().optional(),
2978
+ color: z138.string().optional(),
2958
2979
  arrow_size: length.default("1mm")
2959
2980
  }).describe("Defines a measurement annotation within PCB fabrication notes");
2960
2981
  expectTypesMatch(true);
2961
2982
 
2962
2983
  // src/pcb/pcb_note_text.ts
2963
- import { z as z138 } from "zod";
2964
- var pcb_note_text = z138.object({
2965
- type: z138.literal("pcb_note_text"),
2966
- pcb_note_text_id: getZodPrefixedIdWithDefault("pcb_note_text"),
2967
- pcb_component_id: z138.string().optional(),
2968
- pcb_group_id: z138.string().optional(),
2969
- subcircuit_id: z138.string().optional(),
2970
- name: z138.string().optional(),
2971
- font: z138.literal("tscircuit2024").default("tscircuit2024"),
2972
- font_size: distance.default("1mm"),
2973
- text: z138.string().optional(),
2974
- anchor_position: point.default({ x: 0, y: 0 }),
2975
- anchor_alignment: z138.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2976
- layer: visible_layer.default("top"),
2977
- is_mirrored_from_top_view: z138.boolean().optional(),
2978
- color: z138.string().optional()
2979
- }).describe("Defines a documentation note in text on the PCB");
2980
- expectTypesMatch(true);
2981
-
2982
- // src/pcb/pcb_note_rect.ts
2983
2984
  import { z as z139 } from "zod";
2984
- var pcb_note_rect = z139.object({
2985
- type: z139.literal("pcb_note_rect"),
2986
- pcb_note_rect_id: getZodPrefixedIdWithDefault("pcb_note_rect"),
2985
+ var pcb_note_text = z139.object({
2986
+ type: z139.literal("pcb_note_text"),
2987
+ pcb_note_text_id: getZodPrefixedIdWithDefault("pcb_note_text"),
2987
2988
  pcb_component_id: z139.string().optional(),
2988
2989
  pcb_group_id: z139.string().optional(),
2989
2990
  subcircuit_id: z139.string().optional(),
2990
2991
  name: z139.string().optional(),
2992
+ font: z139.literal("tscircuit2024").default("tscircuit2024"),
2993
+ font_size: distance.default("1mm"),
2991
2994
  text: z139.string().optional(),
2992
- center: point,
2993
- width: length,
2994
- height: length,
2995
+ anchor_position: point.default({ x: 0, y: 0 }),
2996
+ anchor_alignment: z139.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2995
2997
  layer: visible_layer.default("top"),
2996
- stroke_width: length.default("0.1mm"),
2997
- corner_radius: length.optional(),
2998
- is_filled: z139.boolean().optional(),
2999
- has_stroke: z139.boolean().optional(),
3000
- is_stroke_dashed: z139.boolean().optional(),
2998
+ is_mirrored_from_top_view: z139.boolean().optional(),
3001
2999
  color: z139.string().optional()
3002
- }).describe("Defines a rectangular documentation note on the PCB");
3000
+ }).describe("Defines a documentation note in text on the PCB");
3003
3001
  expectTypesMatch(true);
3004
3002
 
3005
- // src/pcb/pcb_note_path.ts
3003
+ // src/pcb/pcb_note_rect.ts
3006
3004
  import { z as z140 } from "zod";
3007
- var pcb_note_path = z140.object({
3008
- type: z140.literal("pcb_note_path"),
3009
- pcb_note_path_id: getZodPrefixedIdWithDefault("pcb_note_path"),
3005
+ var pcb_note_rect = z140.object({
3006
+ type: z140.literal("pcb_note_rect"),
3007
+ pcb_note_rect_id: getZodPrefixedIdWithDefault("pcb_note_rect"),
3010
3008
  pcb_component_id: z140.string().optional(),
3011
3009
  pcb_group_id: z140.string().optional(),
3012
3010
  subcircuit_id: z140.string().optional(),
3013
3011
  name: z140.string().optional(),
3014
3012
  text: z140.string().optional(),
3015
- route: z140.array(point),
3013
+ center: point,
3014
+ width: length,
3015
+ height: length,
3016
3016
  layer: visible_layer.default("top"),
3017
3017
  stroke_width: length.default("0.1mm"),
3018
+ corner_radius: length.optional(),
3019
+ is_filled: z140.boolean().optional(),
3020
+ has_stroke: z140.boolean().optional(),
3021
+ is_stroke_dashed: z140.boolean().optional(),
3018
3022
  color: z140.string().optional()
3019
- }).describe("Defines a polyline documentation note on the PCB");
3023
+ }).describe("Defines a rectangular documentation note on the PCB");
3020
3024
  expectTypesMatch(true);
3021
3025
 
3022
- // src/pcb/pcb_note_line.ts
3026
+ // src/pcb/pcb_note_path.ts
3023
3027
  import { z as z141 } from "zod";
3024
- var pcb_note_line = z141.object({
3025
- type: z141.literal("pcb_note_line"),
3026
- pcb_note_line_id: getZodPrefixedIdWithDefault("pcb_note_line"),
3028
+ var pcb_note_path = z141.object({
3029
+ type: z141.literal("pcb_note_path"),
3030
+ pcb_note_path_id: getZodPrefixedIdWithDefault("pcb_note_path"),
3027
3031
  pcb_component_id: z141.string().optional(),
3028
3032
  pcb_group_id: z141.string().optional(),
3029
3033
  subcircuit_id: z141.string().optional(),
3030
3034
  name: z141.string().optional(),
3031
3035
  text: z141.string().optional(),
3036
+ route: z141.array(point),
3037
+ layer: visible_layer.default("top"),
3038
+ stroke_width: length.default("0.1mm"),
3039
+ color: z141.string().optional()
3040
+ }).describe("Defines a polyline documentation note on the PCB");
3041
+ expectTypesMatch(true);
3042
+
3043
+ // src/pcb/pcb_note_line.ts
3044
+ import { z as z142 } from "zod";
3045
+ var pcb_note_line = z142.object({
3046
+ type: z142.literal("pcb_note_line"),
3047
+ pcb_note_line_id: getZodPrefixedIdWithDefault("pcb_note_line"),
3048
+ pcb_component_id: z142.string().optional(),
3049
+ pcb_group_id: z142.string().optional(),
3050
+ subcircuit_id: z142.string().optional(),
3051
+ name: z142.string().optional(),
3052
+ text: z142.string().optional(),
3032
3053
  x1: distance,
3033
3054
  y1: distance,
3034
3055
  x2: distance,
3035
3056
  y2: distance,
3036
3057
  layer: visible_layer.default("top"),
3037
3058
  stroke_width: distance.default("0.1mm"),
3038
- color: z141.string().optional(),
3039
- is_dashed: z141.boolean().optional()
3059
+ color: z142.string().optional(),
3060
+ is_dashed: z142.boolean().optional()
3040
3061
  }).describe("Defines a straight documentation note line on the PCB");
3041
3062
  expectTypesMatch(true);
3042
3063
 
3043
3064
  // src/pcb/pcb_note_dimension.ts
3044
- import { z as z142 } from "zod";
3045
- var pcb_note_dimension = z142.object({
3046
- type: z142.literal("pcb_note_dimension"),
3065
+ import { z as z143 } from "zod";
3066
+ var pcb_note_dimension = z143.object({
3067
+ type: z143.literal("pcb_note_dimension"),
3047
3068
  pcb_note_dimension_id: getZodPrefixedIdWithDefault("pcb_note_dimension"),
3048
- pcb_component_id: z142.string().optional(),
3049
- pcb_group_id: z142.string().optional(),
3050
- subcircuit_id: z142.string().optional(),
3051
- name: z142.string().optional(),
3069
+ pcb_component_id: z143.string().optional(),
3070
+ pcb_group_id: z143.string().optional(),
3071
+ subcircuit_id: z143.string().optional(),
3072
+ name: z143.string().optional(),
3052
3073
  from: point,
3053
3074
  to: point,
3054
- text: z142.string().optional(),
3055
- text_ccw_rotation: z142.number().optional(),
3075
+ text: z143.string().optional(),
3076
+ text_ccw_rotation: z143.number().optional(),
3056
3077
  offset_distance: length.optional(),
3057
- offset_direction: z142.object({
3058
- x: z142.number(),
3059
- y: z142.number()
3078
+ offset_direction: z143.object({
3079
+ x: z143.number(),
3080
+ y: z143.number()
3060
3081
  }).optional(),
3061
- font: z142.literal("tscircuit2024").default("tscircuit2024"),
3082
+ font: z143.literal("tscircuit2024").default("tscircuit2024"),
3062
3083
  font_size: length.default("1mm"),
3063
3084
  layer: visible_layer.default("top"),
3064
- color: z142.string().optional(),
3085
+ color: z143.string().optional(),
3065
3086
  arrow_size: length.default("1mm")
3066
3087
  }).describe("Defines a measurement annotation within PCB documentation notes");
3067
3088
  expectTypesMatch(true);
3068
3089
 
3069
3090
  // src/pcb/pcb_footprint_overlap_error.ts
3070
- import { z as z143 } from "zod";
3091
+ import { z as z144 } from "zod";
3071
3092
  var pcb_footprint_overlap_error = base_circuit_json_error.extend({
3072
- type: z143.literal("pcb_footprint_overlap_error"),
3093
+ type: z144.literal("pcb_footprint_overlap_error"),
3073
3094
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
3074
- error_type: z143.literal("pcb_footprint_overlap_error").default("pcb_footprint_overlap_error"),
3075
- pcb_smtpad_ids: z143.array(z143.string()).optional(),
3076
- pcb_plated_hole_ids: z143.array(z143.string()).optional(),
3077
- pcb_hole_ids: z143.array(z143.string()).optional(),
3078
- pcb_keepout_ids: z143.array(z143.string()).optional()
3095
+ error_type: z144.literal("pcb_footprint_overlap_error").default("pcb_footprint_overlap_error"),
3096
+ pcb_smtpad_ids: z144.array(z144.string()).optional(),
3097
+ pcb_plated_hole_ids: z144.array(z144.string()).optional(),
3098
+ pcb_hole_ids: z144.array(z144.string()).optional(),
3099
+ pcb_keepout_ids: z144.array(z144.string()).optional()
3079
3100
  }).describe("Error emitted when a pcb footprint overlaps with another element");
3080
3101
  expectTypesMatch(
3081
3102
  true
3082
3103
  );
3083
3104
 
3084
3105
  // src/pcb/pcb_courtyard_overlap_error.ts
3085
- import { z as z144 } from "zod";
3106
+ import { z as z145 } from "zod";
3086
3107
  var pcb_courtyard_overlap_error = base_circuit_json_error.extend({
3087
- type: z144.literal("pcb_courtyard_overlap_error"),
3108
+ type: z145.literal("pcb_courtyard_overlap_error"),
3088
3109
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
3089
- error_type: z144.literal("pcb_courtyard_overlap_error").default("pcb_courtyard_overlap_error"),
3090
- pcb_component_ids: z144.tuple([z144.string(), z144.string()])
3110
+ error_type: z145.literal("pcb_courtyard_overlap_error").default("pcb_courtyard_overlap_error"),
3111
+ pcb_component_ids: z145.tuple([z145.string(), z145.string()])
3091
3112
  }).describe(
3092
3113
  "Error emitted when the courtyard (CrtYd) of one PCB component overlaps with the courtyard of another"
3093
3114
  );
@@ -3096,51 +3117,51 @@ expectTypesMatch(
3096
3117
  );
3097
3118
 
3098
3119
  // src/pcb/pcb_keepout.ts
3099
- import { z as z145 } from "zod";
3100
- var pcb_keepout = z145.object({
3101
- type: z145.literal("pcb_keepout"),
3102
- shape: z145.literal("rect"),
3103
- pcb_group_id: z145.string().optional(),
3104
- subcircuit_id: z145.string().optional(),
3120
+ import { z as z146 } from "zod";
3121
+ var pcb_keepout = z146.object({
3122
+ type: z146.literal("pcb_keepout"),
3123
+ shape: z146.literal("rect"),
3124
+ pcb_group_id: z146.string().optional(),
3125
+ subcircuit_id: z146.string().optional(),
3105
3126
  center: point,
3106
3127
  width: distance,
3107
3128
  height: distance,
3108
- pcb_keepout_id: z145.string(),
3109
- layers: z145.array(z145.string()),
3129
+ pcb_keepout_id: z146.string(),
3130
+ layers: z146.array(z146.string()),
3110
3131
  // Specify layers where the keepout applies
3111
- description: z145.string().optional(),
3132
+ description: z146.string().optional(),
3112
3133
  // Optional description of the keepout
3113
- excluded_pcb_component_ids: z145.array(z145.string()).optional()
3134
+ excluded_pcb_component_ids: z146.array(z146.string()).optional()
3114
3135
  }).or(
3115
- z145.object({
3116
- type: z145.literal("pcb_keepout"),
3117
- shape: z145.literal("circle"),
3118
- pcb_group_id: z145.string().optional(),
3119
- subcircuit_id: z145.string().optional(),
3136
+ z146.object({
3137
+ type: z146.literal("pcb_keepout"),
3138
+ shape: z146.literal("circle"),
3139
+ pcb_group_id: z146.string().optional(),
3140
+ subcircuit_id: z146.string().optional(),
3120
3141
  center: point,
3121
3142
  radius: distance,
3122
- pcb_keepout_id: z145.string(),
3123
- layers: z145.array(z145.string()),
3143
+ pcb_keepout_id: z146.string(),
3144
+ layers: z146.array(z146.string()),
3124
3145
  // Specify layers where the keepout applies
3125
- description: z145.string().optional(),
3146
+ description: z146.string().optional(),
3126
3147
  // Optional description of the keepout
3127
- excluded_pcb_component_ids: z145.array(z145.string()).optional()
3148
+ excluded_pcb_component_ids: z146.array(z146.string()).optional()
3128
3149
  })
3129
3150
  );
3130
3151
  expectTypesMatch(true);
3131
3152
 
3132
3153
  // src/pcb/pcb_cutout.ts
3133
- import { z as z146 } from "zod";
3134
- var pcb_cutout_base = z146.object({
3135
- type: z146.literal("pcb_cutout"),
3154
+ import { z as z147 } from "zod";
3155
+ var pcb_cutout_base = z147.object({
3156
+ type: z147.literal("pcb_cutout"),
3136
3157
  pcb_cutout_id: getZodPrefixedIdWithDefault("pcb_cutout"),
3137
- pcb_group_id: z146.string().optional(),
3138
- subcircuit_id: z146.string().optional(),
3139
- pcb_board_id: z146.string().optional(),
3140
- pcb_panel_id: z146.string().optional()
3158
+ pcb_group_id: z147.string().optional(),
3159
+ subcircuit_id: z147.string().optional(),
3160
+ pcb_board_id: z147.string().optional(),
3161
+ pcb_panel_id: z147.string().optional()
3141
3162
  });
3142
3163
  var pcb_cutout_rect = pcb_cutout_base.extend({
3143
- shape: z146.literal("rect"),
3164
+ shape: z147.literal("rect"),
3144
3165
  center: point,
3145
3166
  width: length,
3146
3167
  height: length,
@@ -3149,26 +3170,26 @@ var pcb_cutout_rect = pcb_cutout_base.extend({
3149
3170
  });
3150
3171
  expectTypesMatch(true);
3151
3172
  var pcb_cutout_circle = pcb_cutout_base.extend({
3152
- shape: z146.literal("circle"),
3173
+ shape: z147.literal("circle"),
3153
3174
  center: point,
3154
3175
  radius: length
3155
3176
  });
3156
3177
  expectTypesMatch(true);
3157
3178
  var pcb_cutout_polygon = pcb_cutout_base.extend({
3158
- shape: z146.literal("polygon"),
3159
- points: z146.array(point)
3179
+ shape: z147.literal("polygon"),
3180
+ points: z147.array(point)
3160
3181
  });
3161
3182
  expectTypesMatch(true);
3162
3183
  var pcb_cutout_path = pcb_cutout_base.extend({
3163
- shape: z146.literal("path"),
3164
- route: z146.array(point),
3184
+ shape: z147.literal("path"),
3185
+ route: z147.array(point),
3165
3186
  slot_width: length,
3166
3187
  slot_length: length.optional(),
3167
3188
  space_between_slots: length.optional(),
3168
3189
  slot_corner_radius: length.optional()
3169
3190
  });
3170
3191
  expectTypesMatch(true);
3171
- var pcb_cutout = z146.discriminatedUnion("shape", [
3192
+ var pcb_cutout = z147.discriminatedUnion("shape", [
3172
3193
  pcb_cutout_rect,
3173
3194
  pcb_cutout_circle,
3174
3195
  pcb_cutout_polygon,
@@ -3177,169 +3198,169 @@ var pcb_cutout = z146.discriminatedUnion("shape", [
3177
3198
  expectTypesMatch(true);
3178
3199
 
3179
3200
  // src/pcb/pcb_missing_footprint_error.ts
3180
- import { z as z147 } from "zod";
3201
+ import { z as z148 } from "zod";
3181
3202
  var pcb_missing_footprint_error = base_circuit_json_error.extend({
3182
- type: z147.literal("pcb_missing_footprint_error"),
3203
+ type: z148.literal("pcb_missing_footprint_error"),
3183
3204
  pcb_missing_footprint_error_id: getZodPrefixedIdWithDefault(
3184
3205
  "pcb_missing_footprint_error"
3185
3206
  ),
3186
- pcb_group_id: z147.string().optional(),
3187
- subcircuit_id: z147.string().optional(),
3188
- error_type: z147.literal("pcb_missing_footprint_error").default("pcb_missing_footprint_error"),
3189
- source_component_id: z147.string()
3207
+ pcb_group_id: z148.string().optional(),
3208
+ subcircuit_id: z148.string().optional(),
3209
+ error_type: z148.literal("pcb_missing_footprint_error").default("pcb_missing_footprint_error"),
3210
+ source_component_id: z148.string()
3190
3211
  }).describe("Defines a missing footprint error on the PCB");
3191
3212
  expectTypesMatch(
3192
3213
  true
3193
3214
  );
3194
3215
 
3195
3216
  // src/pcb/external_footprint_load_error.ts
3196
- import { z as z148 } from "zod";
3217
+ import { z as z149 } from "zod";
3197
3218
  var external_footprint_load_error = base_circuit_json_error.extend({
3198
- type: z148.literal("external_footprint_load_error"),
3219
+ type: z149.literal("external_footprint_load_error"),
3199
3220
  external_footprint_load_error_id: getZodPrefixedIdWithDefault(
3200
3221
  "external_footprint_load_error"
3201
3222
  ),
3202
- pcb_component_id: z148.string(),
3203
- source_component_id: z148.string(),
3204
- pcb_group_id: z148.string().optional(),
3205
- subcircuit_id: z148.string().optional(),
3206
- footprinter_string: z148.string().optional(),
3207
- error_type: z148.literal("external_footprint_load_error").default("external_footprint_load_error")
3223
+ pcb_component_id: z149.string(),
3224
+ source_component_id: z149.string(),
3225
+ pcb_group_id: z149.string().optional(),
3226
+ subcircuit_id: z149.string().optional(),
3227
+ footprinter_string: z149.string().optional(),
3228
+ error_type: z149.literal("external_footprint_load_error").default("external_footprint_load_error")
3208
3229
  }).describe("Defines an error when an external footprint fails to load");
3209
3230
  expectTypesMatch(true);
3210
3231
 
3211
3232
  // src/pcb/circuit_json_footprint_load_error.ts
3212
- import { z as z149 } from "zod";
3233
+ import { z as z150 } from "zod";
3213
3234
  var circuit_json_footprint_load_error = base_circuit_json_error.extend({
3214
- type: z149.literal("circuit_json_footprint_load_error"),
3235
+ type: z150.literal("circuit_json_footprint_load_error"),
3215
3236
  circuit_json_footprint_load_error_id: getZodPrefixedIdWithDefault(
3216
3237
  "circuit_json_footprint_load_error"
3217
3238
  ),
3218
- pcb_component_id: z149.string(),
3219
- source_component_id: z149.string(),
3220
- pcb_group_id: z149.string().optional(),
3221
- subcircuit_id: z149.string().optional(),
3222
- error_type: z149.literal("circuit_json_footprint_load_error").default("circuit_json_footprint_load_error"),
3223
- circuit_json: z149.array(z149.any()).optional()
3239
+ pcb_component_id: z150.string(),
3240
+ source_component_id: z150.string(),
3241
+ pcb_group_id: z150.string().optional(),
3242
+ subcircuit_id: z150.string().optional(),
3243
+ error_type: z150.literal("circuit_json_footprint_load_error").default("circuit_json_footprint_load_error"),
3244
+ circuit_json: z150.array(z150.any()).optional()
3224
3245
  }).describe("Defines an error when a circuit JSON footprint fails to load");
3225
3246
  expectTypesMatch(true);
3226
3247
 
3227
3248
  // src/pcb/pcb_group.ts
3228
- import { z as z150 } from "zod";
3229
- var pcb_group = z150.object({
3230
- type: z150.literal("pcb_group"),
3249
+ import { z as z151 } from "zod";
3250
+ var pcb_group = z151.object({
3251
+ type: z151.literal("pcb_group"),
3231
3252
  pcb_group_id: getZodPrefixedIdWithDefault("pcb_group"),
3232
- source_group_id: z150.string(),
3233
- is_subcircuit: z150.boolean().optional(),
3234
- subcircuit_id: z150.string().optional(),
3253
+ source_group_id: z151.string(),
3254
+ is_subcircuit: z151.boolean().optional(),
3255
+ subcircuit_id: z151.string().optional(),
3235
3256
  width: length.optional(),
3236
3257
  height: length.optional(),
3237
3258
  center: point,
3238
- display_offset_x: z150.string().optional().describe(
3259
+ display_offset_x: z151.string().optional().describe(
3239
3260
  "How to display the x offset for this group, usually corresponding with how the user specified it"
3240
3261
  ),
3241
- display_offset_y: z150.string().optional().describe(
3262
+ display_offset_y: z151.string().optional().describe(
3242
3263
  "How to display the y offset for this group, usually corresponding with how the user specified it"
3243
3264
  ),
3244
- outline: z150.array(point).optional(),
3265
+ outline: z151.array(point).optional(),
3245
3266
  anchor_position: point.optional(),
3246
3267
  anchor_alignment: ninePointAnchor.default("center"),
3247
- position_mode: z150.enum(["packed", "relative_to_group_anchor", "none"]).optional(),
3248
- positioned_relative_to_pcb_group_id: z150.string().optional(),
3249
- positioned_relative_to_pcb_board_id: z150.string().optional(),
3250
- pcb_component_ids: z150.array(z150.string()),
3251
- child_layout_mode: z150.enum(["packed", "none"]).optional(),
3252
- name: z150.string().optional(),
3253
- description: z150.string().optional(),
3254
- layout_mode: z150.string().optional(),
3255
- autorouter_configuration: z150.object({
3268
+ position_mode: z151.enum(["packed", "relative_to_group_anchor", "none"]).optional(),
3269
+ positioned_relative_to_pcb_group_id: z151.string().optional(),
3270
+ positioned_relative_to_pcb_board_id: z151.string().optional(),
3271
+ pcb_component_ids: z151.array(z151.string()),
3272
+ child_layout_mode: z151.enum(["packed", "none"]).optional(),
3273
+ name: z151.string().optional(),
3274
+ description: z151.string().optional(),
3275
+ layout_mode: z151.string().optional(),
3276
+ autorouter_configuration: z151.object({
3256
3277
  trace_clearance: length
3257
3278
  }).optional(),
3258
- autorouter_used_string: z150.string().optional()
3279
+ autorouter_used_string: z151.string().optional()
3259
3280
  }).describe("Defines a group of components on the PCB");
3260
3281
  expectTypesMatch(true);
3261
3282
 
3262
3283
  // src/pcb/pcb_autorouting_error.ts
3263
- import { z as z151 } from "zod";
3284
+ import { z as z152 } from "zod";
3264
3285
  var pcb_autorouting_error = base_circuit_json_error.extend({
3265
- type: z151.literal("pcb_autorouting_error"),
3286
+ type: z152.literal("pcb_autorouting_error"),
3266
3287
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_autorouting_error"),
3267
- error_type: z151.literal("pcb_autorouting_error").default("pcb_autorouting_error"),
3268
- subcircuit_id: z151.string().optional()
3288
+ error_type: z152.literal("pcb_autorouting_error").default("pcb_autorouting_error"),
3289
+ subcircuit_id: z152.string().optional()
3269
3290
  }).describe("The autorouting has failed to route a portion of the board");
3270
3291
  expectTypesMatch(true);
3271
3292
 
3272
3293
  // src/pcb/pcb_manual_edit_conflict_warning.ts
3273
- import { z as z152 } from "zod";
3274
- var pcb_manual_edit_conflict_warning = z152.object({
3275
- type: z152.literal("pcb_manual_edit_conflict_warning"),
3294
+ import { z as z153 } from "zod";
3295
+ var pcb_manual_edit_conflict_warning = z153.object({
3296
+ type: z153.literal("pcb_manual_edit_conflict_warning"),
3276
3297
  pcb_manual_edit_conflict_warning_id: getZodPrefixedIdWithDefault(
3277
3298
  "pcb_manual_edit_conflict_warning"
3278
3299
  ),
3279
- warning_type: z152.literal("pcb_manual_edit_conflict_warning").default("pcb_manual_edit_conflict_warning"),
3280
- message: z152.string(),
3281
- pcb_component_id: z152.string(),
3282
- pcb_group_id: z152.string().optional(),
3283
- subcircuit_id: z152.string().optional(),
3284
- source_component_id: z152.string()
3300
+ warning_type: z153.literal("pcb_manual_edit_conflict_warning").default("pcb_manual_edit_conflict_warning"),
3301
+ message: z153.string(),
3302
+ pcb_component_id: z153.string(),
3303
+ pcb_group_id: z153.string().optional(),
3304
+ subcircuit_id: z153.string().optional(),
3305
+ source_component_id: z153.string()
3285
3306
  }).describe(
3286
3307
  "Warning emitted when a component has both manual placement and explicit pcbX/pcbY coordinates"
3287
3308
  );
3288
3309
  expectTypesMatch(true);
3289
3310
 
3290
3311
  // src/pcb/pcb_connector_not_in_accessible_orientation_warning.ts
3291
- import { z as z153 } from "zod";
3292
- var connectorOrientationDirection = z153.enum(["x-", "x+", "y+", "y-"]);
3293
- var pcb_connector_not_in_accessible_orientation_warning = z153.object({
3294
- type: z153.literal("pcb_connector_not_in_accessible_orientation_warning"),
3312
+ import { z as z154 } from "zod";
3313
+ var connectorOrientationDirection = z154.enum(["x-", "x+", "y+", "y-"]);
3314
+ var pcb_connector_not_in_accessible_orientation_warning = z154.object({
3315
+ type: z154.literal("pcb_connector_not_in_accessible_orientation_warning"),
3295
3316
  pcb_connector_not_in_accessible_orientation_warning_id: getZodPrefixedIdWithDefault(
3296
3317
  "pcb_connector_not_in_accessible_orientation_warning"
3297
3318
  ),
3298
- warning_type: z153.literal("pcb_connector_not_in_accessible_orientation_warning").default("pcb_connector_not_in_accessible_orientation_warning"),
3299
- message: z153.string(),
3300
- pcb_component_id: z153.string(),
3301
- source_component_id: z153.string().optional(),
3302
- pcb_board_id: z153.string().optional(),
3319
+ warning_type: z154.literal("pcb_connector_not_in_accessible_orientation_warning").default("pcb_connector_not_in_accessible_orientation_warning"),
3320
+ message: z154.string(),
3321
+ pcb_component_id: z154.string(),
3322
+ source_component_id: z154.string().optional(),
3323
+ pcb_board_id: z154.string().optional(),
3303
3324
  facing_direction: connectorOrientationDirection,
3304
3325
  recommended_facing_direction: connectorOrientationDirection,
3305
- subcircuit_id: z153.string().optional()
3326
+ subcircuit_id: z154.string().optional()
3306
3327
  }).describe(
3307
3328
  "Warning emitted when a connector PCB component is facing inward toward the board and should be reoriented to an outward-facing direction"
3308
3329
  );
3309
3330
  expectTypesMatch(true);
3310
3331
 
3311
3332
  // src/pcb/supplier_footprint_mismatch_warning.ts
3312
- import { z as z154 } from "zod";
3313
- var supplier_footprint_mismatch_warning = z154.object({
3314
- type: z154.literal("supplier_footprint_mismatch_warning"),
3333
+ import { z as z155 } from "zod";
3334
+ var supplier_footprint_mismatch_warning = z155.object({
3335
+ type: z155.literal("supplier_footprint_mismatch_warning"),
3315
3336
  supplier_footprint_mismatch_warning_id: getZodPrefixedIdWithDefault(
3316
3337
  "supplier_footprint_mismatch_warning"
3317
3338
  ),
3318
- warning_type: z154.literal("supplier_footprint_mismatch_warning").default("supplier_footprint_mismatch_warning"),
3319
- message: z154.string(),
3320
- source_component_id: z154.string(),
3321
- pcb_component_id: z154.string().optional(),
3322
- pcb_group_id: z154.string().optional(),
3323
- subcircuit_id: z154.string().optional(),
3339
+ warning_type: z155.literal("supplier_footprint_mismatch_warning").default("supplier_footprint_mismatch_warning"),
3340
+ message: z155.string(),
3341
+ source_component_id: z155.string(),
3342
+ pcb_component_id: z155.string().optional(),
3343
+ pcb_group_id: z155.string().optional(),
3344
+ subcircuit_id: z155.string().optional(),
3324
3345
  supplier_name: supplier_name.optional(),
3325
- supplier_part_number: z154.string().optional(),
3326
- supplier_footprint_url: z154.string().optional(),
3327
- footprint_copper_intersection_over_union: z154.number()
3346
+ supplier_part_number: z155.string().optional(),
3347
+ supplier_footprint_url: z155.string().optional(),
3348
+ footprint_copper_intersection_over_union: z155.number()
3328
3349
  }).describe(
3329
3350
  "Warning emitted when a supplier part footprint does not match the expected footprint"
3330
3351
  );
3331
3352
  expectTypesMatch(true);
3332
3353
 
3333
3354
  // src/pcb/pcb_breakout_point.ts
3334
- import { z as z155 } from "zod";
3335
- var pcb_breakout_point = z155.object({
3336
- type: z155.literal("pcb_breakout_point"),
3355
+ import { z as z156 } from "zod";
3356
+ var pcb_breakout_point = z156.object({
3357
+ type: z156.literal("pcb_breakout_point"),
3337
3358
  pcb_breakout_point_id: getZodPrefixedIdWithDefault("pcb_breakout_point"),
3338
- pcb_group_id: z155.string(),
3339
- subcircuit_id: z155.string().optional(),
3340
- source_trace_id: z155.string().optional(),
3341
- source_port_id: z155.string().optional(),
3342
- source_net_id: z155.string().optional(),
3359
+ pcb_group_id: z156.string(),
3360
+ subcircuit_id: z156.string().optional(),
3361
+ source_trace_id: z156.string().optional(),
3362
+ source_port_id: z156.string().optional(),
3363
+ source_net_id: z156.string().optional(),
3343
3364
  x: distance,
3344
3365
  y: distance
3345
3366
  }).describe(
@@ -3348,61 +3369,61 @@ var pcb_breakout_point = z155.object({
3348
3369
  expectTypesMatch(true);
3349
3370
 
3350
3371
  // src/pcb/pcb_ground_plane.ts
3351
- import { z as z156 } from "zod";
3352
- var pcb_ground_plane = z156.object({
3353
- type: z156.literal("pcb_ground_plane"),
3372
+ import { z as z157 } from "zod";
3373
+ var pcb_ground_plane = z157.object({
3374
+ type: z157.literal("pcb_ground_plane"),
3354
3375
  pcb_ground_plane_id: getZodPrefixedIdWithDefault("pcb_ground_plane"),
3355
- source_pcb_ground_plane_id: z156.string(),
3356
- source_net_id: z156.string(),
3357
- pcb_group_id: z156.string().optional(),
3358
- subcircuit_id: z156.string().optional()
3376
+ source_pcb_ground_plane_id: z157.string(),
3377
+ source_net_id: z157.string(),
3378
+ pcb_group_id: z157.string().optional(),
3379
+ subcircuit_id: z157.string().optional()
3359
3380
  }).describe("Defines a ground plane on the PCB");
3360
3381
  expectTypesMatch(true);
3361
3382
 
3362
3383
  // src/pcb/pcb_ground_plane_region.ts
3363
- import { z as z157 } from "zod";
3364
- var pcb_ground_plane_region = z157.object({
3365
- type: z157.literal("pcb_ground_plane_region"),
3384
+ import { z as z158 } from "zod";
3385
+ var pcb_ground_plane_region = z158.object({
3386
+ type: z158.literal("pcb_ground_plane_region"),
3366
3387
  pcb_ground_plane_region_id: getZodPrefixedIdWithDefault(
3367
3388
  "pcb_ground_plane_region"
3368
3389
  ),
3369
- pcb_ground_plane_id: z157.string(),
3370
- pcb_group_id: z157.string().optional(),
3371
- subcircuit_id: z157.string().optional(),
3390
+ pcb_ground_plane_id: z158.string(),
3391
+ pcb_group_id: z158.string().optional(),
3392
+ subcircuit_id: z158.string().optional(),
3372
3393
  layer: layer_ref,
3373
- points: z157.array(point)
3394
+ points: z158.array(point)
3374
3395
  }).describe("Defines a polygon region of a ground plane");
3375
3396
  expectTypesMatch(true);
3376
3397
 
3377
3398
  // src/pcb/pcb_thermal_spoke.ts
3378
- import { z as z158 } from "zod";
3379
- var pcb_thermal_spoke = z158.object({
3380
- type: z158.literal("pcb_thermal_spoke"),
3399
+ import { z as z159 } from "zod";
3400
+ var pcb_thermal_spoke = z159.object({
3401
+ type: z159.literal("pcb_thermal_spoke"),
3381
3402
  pcb_thermal_spoke_id: getZodPrefixedIdWithDefault("pcb_thermal_spoke"),
3382
- pcb_ground_plane_id: z158.string(),
3383
- shape: z158.string(),
3384
- spoke_count: z158.number(),
3403
+ pcb_ground_plane_id: z159.string(),
3404
+ shape: z159.string(),
3405
+ spoke_count: z159.number(),
3385
3406
  spoke_thickness: distance,
3386
3407
  spoke_inner_diameter: distance,
3387
3408
  spoke_outer_diameter: distance,
3388
- pcb_plated_hole_id: z158.string().optional(),
3389
- subcircuit_id: z158.string().optional()
3409
+ pcb_plated_hole_id: z159.string().optional(),
3410
+ subcircuit_id: z159.string().optional()
3390
3411
  }).describe("Pattern for connecting a ground plane to a plated hole");
3391
3412
  expectTypesMatch(true);
3392
3413
 
3393
3414
  // src/pcb/pcb_copper_pour.ts
3394
- import { z as z159 } from "zod";
3395
- var pcb_copper_pour_base = z159.object({
3396
- type: z159.literal("pcb_copper_pour"),
3415
+ import { z as z160 } from "zod";
3416
+ var pcb_copper_pour_base = z160.object({
3417
+ type: z160.literal("pcb_copper_pour"),
3397
3418
  pcb_copper_pour_id: getZodPrefixedIdWithDefault("pcb_copper_pour"),
3398
- pcb_group_id: z159.string().optional(),
3399
- subcircuit_id: z159.string().optional(),
3419
+ pcb_group_id: z160.string().optional(),
3420
+ subcircuit_id: z160.string().optional(),
3400
3421
  layer: layer_ref,
3401
- source_net_id: z159.string().optional(),
3402
- covered_with_solder_mask: z159.boolean().optional().default(true)
3422
+ source_net_id: z160.string().optional(),
3423
+ covered_with_solder_mask: z160.boolean().optional().default(true)
3403
3424
  });
3404
3425
  var pcb_copper_pour_rect = pcb_copper_pour_base.extend({
3405
- shape: z159.literal("rect"),
3426
+ shape: z160.literal("rect"),
3406
3427
  center: point,
3407
3428
  width: length,
3408
3429
  height: length,
@@ -3410,16 +3431,16 @@ var pcb_copper_pour_rect = pcb_copper_pour_base.extend({
3410
3431
  });
3411
3432
  expectTypesMatch(true);
3412
3433
  var pcb_copper_pour_brep = pcb_copper_pour_base.extend({
3413
- shape: z159.literal("brep"),
3434
+ shape: z160.literal("brep"),
3414
3435
  brep_shape
3415
3436
  });
3416
3437
  expectTypesMatch(true);
3417
3438
  var pcb_copper_pour_polygon = pcb_copper_pour_base.extend({
3418
- shape: z159.literal("polygon"),
3419
- points: z159.array(point)
3439
+ shape: z160.literal("polygon"),
3440
+ points: z160.array(point)
3420
3441
  });
3421
3442
  expectTypesMatch(true);
3422
- var pcb_copper_pour = z159.discriminatedUnion("shape", [
3443
+ var pcb_copper_pour = z160.discriminatedUnion("shape", [
3423
3444
  pcb_copper_pour_rect,
3424
3445
  pcb_copper_pour_brep,
3425
3446
  pcb_copper_pour_polygon
@@ -3427,99 +3448,99 @@ var pcb_copper_pour = z159.discriminatedUnion("shape", [
3427
3448
  expectTypesMatch(true);
3428
3449
 
3429
3450
  // src/pcb/pcb_component_outside_board_error.ts
3430
- import { z as z160 } from "zod";
3451
+ import { z as z161 } from "zod";
3431
3452
  var pcb_component_outside_board_error = base_circuit_json_error.extend({
3432
- type: z160.literal("pcb_component_outside_board_error"),
3453
+ type: z161.literal("pcb_component_outside_board_error"),
3433
3454
  pcb_component_outside_board_error_id: getZodPrefixedIdWithDefault(
3434
3455
  "pcb_component_outside_board_error"
3435
3456
  ),
3436
- error_type: z160.literal("pcb_component_outside_board_error").default("pcb_component_outside_board_error"),
3437
- pcb_component_id: z160.string(),
3438
- pcb_board_id: z160.string(),
3457
+ error_type: z161.literal("pcb_component_outside_board_error").default("pcb_component_outside_board_error"),
3458
+ pcb_component_id: z161.string(),
3459
+ pcb_board_id: z161.string(),
3439
3460
  component_center: point,
3440
- component_bounds: z160.object({
3441
- min_x: z160.number(),
3442
- max_x: z160.number(),
3443
- min_y: z160.number(),
3444
- max_y: z160.number()
3461
+ component_bounds: z161.object({
3462
+ min_x: z161.number(),
3463
+ max_x: z161.number(),
3464
+ min_y: z161.number(),
3465
+ max_y: z161.number()
3445
3466
  }),
3446
- subcircuit_id: z160.string().optional(),
3447
- source_component_id: z160.string().optional()
3467
+ subcircuit_id: z161.string().optional(),
3468
+ source_component_id: z161.string().optional()
3448
3469
  }).describe(
3449
3470
  "Error emitted when a PCB component is placed outside the board boundaries"
3450
3471
  );
3451
3472
  expectTypesMatch(true);
3452
3473
 
3453
3474
  // src/pcb/pcb_component_not_on_board_edge_error.ts
3454
- import { z as z161 } from "zod";
3475
+ import { z as z162 } from "zod";
3455
3476
  var pcb_component_not_on_board_edge_error = base_circuit_json_error.extend({
3456
- type: z161.literal("pcb_component_not_on_board_edge_error"),
3477
+ type: z162.literal("pcb_component_not_on_board_edge_error"),
3457
3478
  pcb_component_not_on_board_edge_error_id: getZodPrefixedIdWithDefault(
3458
3479
  "pcb_component_not_on_board_edge_error"
3459
3480
  ),
3460
- error_type: z161.literal("pcb_component_not_on_board_edge_error").default("pcb_component_not_on_board_edge_error"),
3461
- pcb_component_id: z161.string(),
3462
- pcb_board_id: z161.string(),
3481
+ error_type: z162.literal("pcb_component_not_on_board_edge_error").default("pcb_component_not_on_board_edge_error"),
3482
+ pcb_component_id: z162.string(),
3483
+ pcb_board_id: z162.string(),
3463
3484
  component_center: point,
3464
- pad_to_nearest_board_edge_distance: z161.number(),
3465
- source_component_id: z161.string().optional(),
3466
- subcircuit_id: z161.string().optional()
3485
+ pad_to_nearest_board_edge_distance: z162.number(),
3486
+ source_component_id: z162.string().optional(),
3487
+ subcircuit_id: z162.string().optional()
3467
3488
  }).describe(
3468
3489
  "Error emitted when a component that must be placed on the board edge is centered away from the edge"
3469
3490
  );
3470
3491
  expectTypesMatch(true);
3471
3492
 
3472
3493
  // src/pcb/pcb_component_invalid_layer_error.ts
3473
- import { z as z162 } from "zod";
3494
+ import { z as z163 } from "zod";
3474
3495
  var pcb_component_invalid_layer_error = base_circuit_json_error.extend({
3475
- type: z162.literal("pcb_component_invalid_layer_error"),
3496
+ type: z163.literal("pcb_component_invalid_layer_error"),
3476
3497
  pcb_component_invalid_layer_error_id: getZodPrefixedIdWithDefault(
3477
3498
  "pcb_component_invalid_layer_error"
3478
3499
  ),
3479
- error_type: z162.literal("pcb_component_invalid_layer_error").default("pcb_component_invalid_layer_error"),
3480
- pcb_component_id: z162.string().optional(),
3481
- source_component_id: z162.string(),
3500
+ error_type: z163.literal("pcb_component_invalid_layer_error").default("pcb_component_invalid_layer_error"),
3501
+ pcb_component_id: z163.string().optional(),
3502
+ source_component_id: z163.string(),
3482
3503
  layer: layer_ref,
3483
- subcircuit_id: z162.string().optional()
3504
+ subcircuit_id: z163.string().optional()
3484
3505
  }).describe(
3485
3506
  "Error emitted when a component is placed on an invalid layer (components can only be on 'top' or 'bottom' layers)"
3486
3507
  );
3487
3508
  expectTypesMatch(true);
3488
3509
 
3489
3510
  // src/pcb/pcb_via_clearance_error.ts
3490
- import { z as z163 } from "zod";
3511
+ import { z as z164 } from "zod";
3491
3512
  var pcb_via_clearance_error = base_circuit_json_error.extend({
3492
- type: z163.literal("pcb_via_clearance_error"),
3513
+ type: z164.literal("pcb_via_clearance_error"),
3493
3514
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
3494
- error_type: z163.literal("pcb_via_clearance_error").default("pcb_via_clearance_error"),
3495
- pcb_via_ids: z163.array(z163.string()).min(2),
3515
+ error_type: z164.literal("pcb_via_clearance_error").default("pcb_via_clearance_error"),
3516
+ pcb_via_ids: z164.array(z164.string()).min(2),
3496
3517
  minimum_clearance: distance.optional(),
3497
3518
  actual_clearance: distance.optional(),
3498
- pcb_center: z163.object({
3499
- x: z163.number().optional(),
3500
- y: z163.number().optional()
3519
+ pcb_center: z164.object({
3520
+ x: z164.number().optional(),
3521
+ y: z164.number().optional()
3501
3522
  }).optional(),
3502
- subcircuit_id: z163.string().optional()
3523
+ subcircuit_id: z164.string().optional()
3503
3524
  }).describe("Error emitted when vias are closer than the allowed clearance");
3504
3525
  expectTypesMatch(true);
3505
3526
 
3506
3527
  // src/pcb/pcb_via_trace_clearance_error.ts
3507
- import { z as z164 } from "zod";
3528
+ import { z as z165 } from "zod";
3508
3529
  var pcb_via_trace_clearance_error = base_circuit_json_error.extend({
3509
- type: z164.literal("pcb_via_trace_clearance_error"),
3530
+ type: z165.literal("pcb_via_trace_clearance_error"),
3510
3531
  pcb_via_trace_clearance_error_id: getZodPrefixedIdWithDefault(
3511
3532
  "pcb_via_trace_clearance_error"
3512
3533
  ),
3513
- error_type: z164.literal("pcb_via_trace_clearance_error").default("pcb_via_trace_clearance_error"),
3514
- pcb_via_id: z164.string(),
3515
- pcb_trace_id: z164.string(),
3534
+ error_type: z165.literal("pcb_via_trace_clearance_error").default("pcb_via_trace_clearance_error"),
3535
+ pcb_via_id: z165.string(),
3536
+ pcb_trace_id: z165.string(),
3516
3537
  minimum_clearance: distance.optional(),
3517
3538
  actual_clearance: distance.optional(),
3518
- center: z164.object({
3519
- x: z164.number().optional(),
3520
- y: z164.number().optional()
3539
+ center: z165.object({
3540
+ x: z165.number().optional(),
3541
+ y: z165.number().optional()
3521
3542
  }).optional(),
3522
- subcircuit_id: z164.string().optional()
3543
+ subcircuit_id: z165.string().optional()
3523
3544
  }).describe(
3524
3545
  "Error emitted when a via and trace are closer than the allowed clearance"
3525
3546
  );
@@ -3528,41 +3549,41 @@ expectTypesMatch(
3528
3549
  );
3529
3550
 
3530
3551
  // src/pcb/pcb_pad_pad_clearance_error.ts
3531
- import { z as z165 } from "zod";
3552
+ import { z as z166 } from "zod";
3532
3553
  var pcb_pad_pad_clearance_error = base_circuit_json_error.extend({
3533
- type: z165.literal("pcb_pad_pad_clearance_error"),
3554
+ type: z166.literal("pcb_pad_pad_clearance_error"),
3534
3555
  pcb_pad_pad_clearance_error_id: getZodPrefixedIdWithDefault(
3535
3556
  "pcb_pad_pad_clearance_error"
3536
3557
  ),
3537
- error_type: z165.literal("pcb_pad_pad_clearance_error").default("pcb_pad_pad_clearance_error"),
3538
- pcb_pad_ids: z165.array(z165.string()).min(2),
3558
+ error_type: z166.literal("pcb_pad_pad_clearance_error").default("pcb_pad_pad_clearance_error"),
3559
+ pcb_pad_ids: z166.array(z166.string()).min(2),
3539
3560
  minimum_clearance: distance.optional(),
3540
3561
  actual_clearance: distance.optional(),
3541
- center: z165.object({
3542
- x: z165.number().optional(),
3543
- y: z165.number().optional()
3562
+ center: z166.object({
3563
+ x: z166.number().optional(),
3564
+ y: z166.number().optional()
3544
3565
  }).optional(),
3545
- subcircuit_id: z165.string().optional()
3566
+ subcircuit_id: z166.string().optional()
3546
3567
  }).describe("Error emitted when pads are closer than the allowed clearance");
3547
3568
  expectTypesMatch(true);
3548
3569
 
3549
3570
  // src/pcb/pcb_pad_trace_clearance_error.ts
3550
- import { z as z166 } from "zod";
3571
+ import { z as z167 } from "zod";
3551
3572
  var pcb_pad_trace_clearance_error = base_circuit_json_error.extend({
3552
- type: z166.literal("pcb_pad_trace_clearance_error"),
3573
+ type: z167.literal("pcb_pad_trace_clearance_error"),
3553
3574
  pcb_pad_trace_clearance_error_id: getZodPrefixedIdWithDefault(
3554
3575
  "pcb_pad_trace_clearance_error"
3555
3576
  ),
3556
- error_type: z166.literal("pcb_pad_trace_clearance_error").default("pcb_pad_trace_clearance_error"),
3557
- pcb_pad_id: z166.string(),
3558
- pcb_trace_id: z166.string(),
3577
+ error_type: z167.literal("pcb_pad_trace_clearance_error").default("pcb_pad_trace_clearance_error"),
3578
+ pcb_pad_id: z167.string(),
3579
+ pcb_trace_id: z167.string(),
3559
3580
  minimum_clearance: distance.optional(),
3560
3581
  actual_clearance: distance.optional(),
3561
- center: z166.object({
3562
- x: z166.number().optional(),
3563
- y: z166.number().optional()
3582
+ center: z167.object({
3583
+ x: z167.number().optional(),
3584
+ y: z167.number().optional()
3564
3585
  }).optional(),
3565
- subcircuit_id: z166.string().optional()
3586
+ subcircuit_id: z167.string().optional()
3566
3587
  }).describe(
3567
3588
  "Error emitted when a pad and trace are closer than allowed clearance"
3568
3589
  );
@@ -3571,89 +3592,89 @@ expectTypesMatch(
3571
3592
  );
3572
3593
 
3573
3594
  // src/pcb/pcb_courtyard_rect.ts
3574
- import { z as z167 } from "zod";
3575
- var pcb_courtyard_rect = z167.object({
3576
- type: z167.literal("pcb_courtyard_rect"),
3595
+ import { z as z168 } from "zod";
3596
+ var pcb_courtyard_rect = z168.object({
3597
+ type: z168.literal("pcb_courtyard_rect"),
3577
3598
  pcb_courtyard_rect_id: getZodPrefixedIdWithDefault("pcb_courtyard_rect"),
3578
- pcb_component_id: z167.string(),
3579
- pcb_group_id: z167.string().optional(),
3580
- subcircuit_id: z167.string().optional(),
3599
+ pcb_component_id: z168.string(),
3600
+ pcb_group_id: z168.string().optional(),
3601
+ subcircuit_id: z168.string().optional(),
3581
3602
  center: point,
3582
3603
  width: length,
3583
3604
  height: length,
3584
3605
  layer: visible_layer,
3585
3606
  ccw_rotation: rotation.optional(),
3586
- color: z167.string().optional()
3607
+ color: z168.string().optional()
3587
3608
  }).describe("Defines a courtyard rectangle on the PCB");
3588
3609
  expectTypesMatch(true);
3589
3610
 
3590
3611
  // src/pcb/pcb_courtyard_outline.ts
3591
- import { z as z168 } from "zod";
3592
- var pcb_courtyard_outline = z168.object({
3593
- type: z168.literal("pcb_courtyard_outline"),
3612
+ import { z as z169 } from "zod";
3613
+ var pcb_courtyard_outline = z169.object({
3614
+ type: z169.literal("pcb_courtyard_outline"),
3594
3615
  pcb_courtyard_outline_id: getZodPrefixedIdWithDefault(
3595
3616
  "pcb_courtyard_outline"
3596
3617
  ),
3597
- pcb_component_id: z168.string(),
3598
- pcb_group_id: z168.string().optional(),
3599
- subcircuit_id: z168.string().optional(),
3618
+ pcb_component_id: z169.string(),
3619
+ pcb_group_id: z169.string().optional(),
3620
+ subcircuit_id: z169.string().optional(),
3600
3621
  layer: visible_layer,
3601
- outline: z168.array(point).min(2)
3622
+ outline: z169.array(point).min(2)
3602
3623
  }).describe("Defines a courtyard outline on the PCB");
3603
3624
  expectTypesMatch(true);
3604
3625
 
3605
3626
  // src/pcb/pcb_courtyard_polygon.ts
3606
- import { z as z169 } from "zod";
3607
- var pcb_courtyard_polygon = z169.object({
3608
- type: z169.literal("pcb_courtyard_polygon"),
3627
+ import { z as z170 } from "zod";
3628
+ var pcb_courtyard_polygon = z170.object({
3629
+ type: z170.literal("pcb_courtyard_polygon"),
3609
3630
  pcb_courtyard_polygon_id: getZodPrefixedIdWithDefault(
3610
3631
  "pcb_courtyard_polygon"
3611
3632
  ),
3612
- pcb_component_id: z169.string(),
3613
- pcb_group_id: z169.string().optional(),
3614
- subcircuit_id: z169.string().optional(),
3633
+ pcb_component_id: z170.string(),
3634
+ pcb_group_id: z170.string().optional(),
3635
+ subcircuit_id: z170.string().optional(),
3615
3636
  layer: visible_layer,
3616
- points: z169.array(point).min(3),
3617
- color: z169.string().optional()
3637
+ points: z170.array(point).min(3),
3638
+ color: z170.string().optional()
3618
3639
  }).describe("Defines a courtyard polygon on the PCB");
3619
3640
  expectTypesMatch(true);
3620
3641
 
3621
3642
  // src/pcb/pcb_courtyard_circle.ts
3622
- import { z as z170 } from "zod";
3623
- var pcb_courtyard_circle = z170.object({
3624
- type: z170.literal("pcb_courtyard_circle"),
3643
+ import { z as z171 } from "zod";
3644
+ var pcb_courtyard_circle = z171.object({
3645
+ type: z171.literal("pcb_courtyard_circle"),
3625
3646
  pcb_courtyard_circle_id: getZodPrefixedIdWithDefault(
3626
3647
  "pcb_courtyard_circle"
3627
3648
  ),
3628
- pcb_component_id: z170.string(),
3629
- pcb_group_id: z170.string().optional(),
3630
- subcircuit_id: z170.string().optional(),
3649
+ pcb_component_id: z171.string(),
3650
+ pcb_group_id: z171.string().optional(),
3651
+ subcircuit_id: z171.string().optional(),
3631
3652
  center: point,
3632
3653
  radius: length,
3633
3654
  layer: visible_layer,
3634
- color: z170.string().optional()
3655
+ color: z171.string().optional()
3635
3656
  }).describe("Defines a courtyard circle on the PCB");
3636
3657
  expectTypesMatch(true);
3637
3658
 
3638
3659
  // src/pcb/pcb_courtyard_pill.ts
3639
- import { z as z171 } from "zod";
3640
- var pcb_courtyard_pill = z171.object({
3641
- type: z171.literal("pcb_courtyard_pill"),
3660
+ import { z as z172 } from "zod";
3661
+ var pcb_courtyard_pill = z172.object({
3662
+ type: z172.literal("pcb_courtyard_pill"),
3642
3663
  pcb_courtyard_pill_id: getZodPrefixedIdWithDefault("pcb_courtyard_pill"),
3643
- pcb_component_id: z171.string(),
3644
- pcb_group_id: z171.string().optional(),
3645
- subcircuit_id: z171.string().optional(),
3664
+ pcb_component_id: z172.string(),
3665
+ pcb_group_id: z172.string().optional(),
3666
+ subcircuit_id: z172.string().optional(),
3646
3667
  center: point,
3647
3668
  width: length,
3648
3669
  height: length,
3649
3670
  radius: length,
3650
3671
  layer: visible_layer,
3651
- color: z171.string().optional()
3672
+ color: z172.string().optional()
3652
3673
  }).describe("Defines a courtyard pill on the PCB");
3653
3674
  expectTypesMatch(true);
3654
3675
 
3655
3676
  // src/cad/cad_component.ts
3656
- import { z as z172 } from "zod";
3677
+ import { z as z173 } from "zod";
3657
3678
 
3658
3679
  // src/cad/cad_model_conventions.ts
3659
3680
  var cad_model_formats = [
@@ -3684,50 +3705,50 @@ var cadModelDefaultDirectionMap = {
3684
3705
  };
3685
3706
 
3686
3707
  // src/cad/cad_component.ts
3687
- var cad_component = z172.object({
3688
- type: z172.literal("cad_component"),
3689
- cad_component_id: z172.string(),
3690
- pcb_component_id: z172.string(),
3691
- source_component_id: z172.string(),
3708
+ var cad_component = z173.object({
3709
+ type: z173.literal("cad_component"),
3710
+ cad_component_id: z173.string(),
3711
+ pcb_component_id: z173.string(),
3712
+ source_component_id: z173.string(),
3692
3713
  position: point3,
3693
3714
  rotation: point3.optional(),
3694
3715
  size: point3.optional(),
3695
3716
  layer: layer_ref.optional(),
3696
- subcircuit_id: z172.string().optional(),
3717
+ subcircuit_id: z173.string().optional(),
3697
3718
  // These are all ways to generate/load the 3d model
3698
- footprinter_string: z172.string().optional(),
3699
- model_obj_url: z172.string().optional(),
3700
- model_stl_url: z172.string().optional(),
3701
- model_3mf_url: z172.string().optional(),
3702
- model_gltf_url: z172.string().optional(),
3703
- model_glb_url: z172.string().optional(),
3704
- model_step_url: z172.string().optional(),
3705
- model_wrl_url: z172.string().optional(),
3719
+ footprinter_string: z173.string().optional(),
3720
+ model_obj_url: z173.string().optional(),
3721
+ model_stl_url: z173.string().optional(),
3722
+ model_3mf_url: z173.string().optional(),
3723
+ model_gltf_url: z173.string().optional(),
3724
+ model_glb_url: z173.string().optional(),
3725
+ model_step_url: z173.string().optional(),
3726
+ model_wrl_url: z173.string().optional(),
3706
3727
  model_asset: asset.optional(),
3707
- model_unit_to_mm_scale_factor: z172.number().optional(),
3708
- model_board_normal_direction: z172.enum(cad_model_axis_directions).optional().describe(
3728
+ model_unit_to_mm_scale_factor: z173.number().optional(),
3729
+ model_board_normal_direction: z173.enum(cad_model_axis_directions).optional().describe(
3709
3730
  `The direction in the model's coordinate space that is considered "up" or "coming out of the board surface"`
3710
3731
  ),
3711
3732
  model_origin_position: point3.optional(),
3712
- model_origin_alignment: z172.enum([
3733
+ model_origin_alignment: z173.enum([
3713
3734
  "unknown",
3714
3735
  "center",
3715
3736
  "center_of_component_on_board_surface",
3716
3737
  "bottom_center_of_component"
3717
3738
  ]).optional(),
3718
- model_object_fit: z172.enum(["contain_within_bounds", "fill_bounds"]).optional().default("contain_within_bounds"),
3719
- model_jscad: z172.any().optional(),
3720
- show_as_translucent_model: z172.boolean().optional(),
3721
- show_as_bounding_box: z172.boolean().optional(),
3722
- show_hidden_edges: z172.boolean().optional(),
3723
- anchor_alignment: z172.enum(["center", "center_of_component_on_board_surface"]).optional().default("center")
3739
+ model_object_fit: z173.enum(["contain_within_bounds", "fill_bounds"]).optional().default("contain_within_bounds"),
3740
+ model_jscad: z173.any().optional(),
3741
+ show_as_translucent_model: z173.boolean().optional(),
3742
+ show_as_bounding_box: z173.boolean().optional(),
3743
+ show_hidden_edges: z173.boolean().optional(),
3744
+ anchor_alignment: z173.enum(["center", "center_of_component_on_board_surface"]).optional().default("center")
3724
3745
  }).describe("Defines a component on the PCB");
3725
3746
  expectTypesMatch(true);
3726
3747
 
3727
3748
  // src/simulation/simulation_voltage_source.ts
3728
- import { z as z173 } from "zod";
3729
- var wave_shape = z173.enum(["sinewave", "square", "triangle", "sawtooth"]);
3730
- var percentage = z173.union([z173.string(), z173.number()]).transform((val) => {
3749
+ import { z as z174 } from "zod";
3750
+ var wave_shape = z174.enum(["sinewave", "square", "triangle", "sawtooth"]);
3751
+ var percentage = z174.union([z174.string(), z174.number()]).transform((val) => {
3731
3752
  if (typeof val === "string") {
3732
3753
  if (val.endsWith("%")) {
3733
3754
  return parseFloat(val.slice(0, -1)) / 100;
@@ -3736,32 +3757,32 @@ var percentage = z173.union([z173.string(), z173.number()]).transform((val) => {
3736
3757
  }
3737
3758
  return val;
3738
3759
  }).pipe(
3739
- z173.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3760
+ z174.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3740
3761
  );
3741
- var simulation_dc_voltage_source = z173.object({
3742
- type: z173.literal("simulation_voltage_source"),
3762
+ var simulation_dc_voltage_source = z174.object({
3763
+ type: z174.literal("simulation_voltage_source"),
3743
3764
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
3744
3765
  "simulation_voltage_source"
3745
3766
  ),
3746
- is_dc_source: z173.literal(true).optional().default(true),
3747
- positive_source_port_id: z173.string().optional(),
3748
- negative_source_port_id: z173.string().optional(),
3749
- positive_source_net_id: z173.string().optional(),
3750
- negative_source_net_id: z173.string().optional(),
3767
+ is_dc_source: z174.literal(true).optional().default(true),
3768
+ positive_source_port_id: z174.string().optional(),
3769
+ negative_source_port_id: z174.string().optional(),
3770
+ positive_source_net_id: z174.string().optional(),
3771
+ negative_source_net_id: z174.string().optional(),
3751
3772
  voltage,
3752
3773
  ac_magnitude: voltage.optional(),
3753
3774
  ac_phase: rotation.optional()
3754
3775
  }).describe("Defines a DC voltage source for simulation");
3755
- var simulation_ac_voltage_source = z173.object({
3756
- type: z173.literal("simulation_voltage_source"),
3776
+ var simulation_ac_voltage_source = z174.object({
3777
+ type: z174.literal("simulation_voltage_source"),
3757
3778
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
3758
3779
  "simulation_voltage_source"
3759
3780
  ),
3760
- is_dc_source: z173.literal(false),
3761
- terminal1_source_port_id: z173.string().optional(),
3762
- terminal2_source_port_id: z173.string().optional(),
3763
- terminal1_source_net_id: z173.string().optional(),
3764
- terminal2_source_net_id: z173.string().optional(),
3781
+ is_dc_source: z174.literal(false),
3782
+ terminal1_source_port_id: z174.string().optional(),
3783
+ terminal2_source_port_id: z174.string().optional(),
3784
+ terminal1_source_net_id: z174.string().optional(),
3785
+ terminal2_source_net_id: z174.string().optional(),
3765
3786
  voltage: voltage.optional(),
3766
3787
  frequency: frequency.optional(),
3767
3788
  peak_to_peak_voltage: voltage.optional(),
@@ -3776,14 +3797,14 @@ var simulation_ac_voltage_source = z173.object({
3776
3797
  ac_magnitude: voltage.optional(),
3777
3798
  ac_phase: rotation.optional()
3778
3799
  }).describe("Defines an AC voltage source for simulation");
3779
- var simulation_voltage_source = z173.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
3800
+ var simulation_voltage_source = z174.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
3780
3801
  expectTypesMatch(true);
3781
3802
  expectTypesMatch(true);
3782
3803
  expectTypesMatch(true);
3783
3804
 
3784
3805
  // src/simulation/simulation_current_source.ts
3785
- import { z as z174 } from "zod";
3786
- var percentage2 = z174.union([z174.string(), z174.number()]).transform((val) => {
3806
+ import { z as z175 } from "zod";
3807
+ var percentage2 = z175.union([z175.string(), z175.number()]).transform((val) => {
3787
3808
  if (typeof val === "string") {
3788
3809
  if (val.endsWith("%")) {
3789
3810
  return parseFloat(val.slice(0, -1)) / 100;
@@ -3792,32 +3813,32 @@ var percentage2 = z174.union([z174.string(), z174.number()]).transform((val) =>
3792
3813
  }
3793
3814
  return val;
3794
3815
  }).pipe(
3795
- z174.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3816
+ z175.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3796
3817
  );
3797
- var simulation_dc_current_source = z174.object({
3798
- type: z174.literal("simulation_current_source"),
3818
+ var simulation_dc_current_source = z175.object({
3819
+ type: z175.literal("simulation_current_source"),
3799
3820
  simulation_current_source_id: getZodPrefixedIdWithDefault(
3800
3821
  "simulation_current_source"
3801
3822
  ),
3802
- is_dc_source: z174.literal(true).optional().default(true),
3803
- positive_source_port_id: z174.string().optional(),
3804
- negative_source_port_id: z174.string().optional(),
3805
- positive_source_net_id: z174.string().optional(),
3806
- negative_source_net_id: z174.string().optional(),
3823
+ is_dc_source: z175.literal(true).optional().default(true),
3824
+ positive_source_port_id: z175.string().optional(),
3825
+ negative_source_port_id: z175.string().optional(),
3826
+ positive_source_net_id: z175.string().optional(),
3827
+ negative_source_net_id: z175.string().optional(),
3807
3828
  current,
3808
3829
  ac_magnitude: current.optional(),
3809
3830
  ac_phase: rotation.optional()
3810
3831
  }).describe("Defines a DC current source for simulation");
3811
- var simulation_ac_current_source = z174.object({
3812
- type: z174.literal("simulation_current_source"),
3832
+ var simulation_ac_current_source = z175.object({
3833
+ type: z175.literal("simulation_current_source"),
3813
3834
  simulation_current_source_id: getZodPrefixedIdWithDefault(
3814
3835
  "simulation_current_source"
3815
3836
  ),
3816
- is_dc_source: z174.literal(false),
3817
- terminal1_source_port_id: z174.string().optional(),
3818
- terminal2_source_port_id: z174.string().optional(),
3819
- terminal1_source_net_id: z174.string().optional(),
3820
- terminal2_source_net_id: z174.string().optional(),
3837
+ is_dc_source: z175.literal(false),
3838
+ terminal1_source_port_id: z175.string().optional(),
3839
+ terminal2_source_port_id: z175.string().optional(),
3840
+ terminal1_source_net_id: z175.string().optional(),
3841
+ terminal2_source_net_id: z175.string().optional(),
3821
3842
  current: current.optional(),
3822
3843
  frequency: frequency.optional(),
3823
3844
  peak_to_peak_current: current.optional(),
@@ -3827,58 +3848,58 @@ var simulation_ac_current_source = z174.object({
3827
3848
  ac_magnitude: current.optional(),
3828
3849
  ac_phase: rotation.optional()
3829
3850
  }).describe("Defines an AC current source for simulation");
3830
- var simulation_current_source = z174.union([simulation_dc_current_source, simulation_ac_current_source]).describe("Defines a current source for simulation");
3851
+ var simulation_current_source = z175.union([simulation_dc_current_source, simulation_ac_current_source]).describe("Defines a current source for simulation");
3831
3852
  expectTypesMatch(true);
3832
3853
  expectTypesMatch(true);
3833
3854
  expectTypesMatch(true);
3834
3855
 
3835
3856
  // src/simulation/simulation_experiment.ts
3836
- import { z as z176 } from "zod";
3857
+ import { z as z177 } from "zod";
3837
3858
 
3838
3859
  // src/simulation/simulation_units.ts
3839
- import { z as z175 } from "zod";
3840
- var simulation_dc_sweep_unit = z175.custom(
3860
+ import { z as z176 } from "zod";
3861
+ var simulation_dc_sweep_unit = z176.custom(
3841
3862
  (dcSweepUnit) => dcSweepUnit === "V" || dcSweepUnit === "A"
3842
3863
  );
3843
- var simulation_parameter_unit = z175.custom(
3864
+ var simulation_parameter_unit = z176.custom(
3844
3865
  (parameterUnit) => parameterUnit === "\u03A9" || parameterUnit === "F" || parameterUnit === "H" || parameterUnit === "V" || parameterUnit === "A"
3845
3866
  );
3846
3867
 
3847
3868
  // src/simulation/simulation_experiment.ts
3848
- var experiment_type = z176.union([
3849
- z176.literal("spice_dc_sweep"),
3850
- z176.literal("spice_dc_operating_point"),
3851
- z176.literal("spice_transient_analysis"),
3852
- z176.literal("spice_ac_analysis")
3869
+ var experiment_type = z177.union([
3870
+ z177.literal("spice_dc_sweep"),
3871
+ z177.literal("spice_dc_operating_point"),
3872
+ z177.literal("spice_transient_analysis"),
3873
+ z177.literal("spice_ac_analysis")
3853
3874
  ]);
3854
- var spice_simulation_options = z176.object({
3855
- method: z176.enum(["trap", "gear"]).optional(),
3856
- reltol: z176.union([z176.number(), z176.string()]).optional(),
3857
- abstol: z176.union([z176.number(), z176.string()]).optional(),
3858
- vntol: z176.union([z176.number(), z176.string()]).optional()
3875
+ var spice_simulation_options = z177.object({
3876
+ method: z177.enum(["trap", "gear"]).optional(),
3877
+ reltol: z177.union([z177.number(), z177.string()]).optional(),
3878
+ abstol: z177.union([z177.number(), z177.string()]).optional(),
3879
+ vntol: z177.union([z177.number(), z177.string()]).optional()
3859
3880
  }).describe("SPICE solver options for a simulation experiment");
3860
- var simulation_experiment = z176.object({
3861
- type: z176.literal("simulation_experiment"),
3881
+ var simulation_experiment = z177.object({
3882
+ type: z177.literal("simulation_experiment"),
3862
3883
  simulation_experiment_id: getZodPrefixedIdWithDefault(
3863
3884
  "simulation_experiment"
3864
3885
  ),
3865
- name: z176.string(),
3886
+ name: z177.string(),
3866
3887
  experiment_type,
3867
3888
  time_per_step: duration_ms.optional(),
3868
3889
  start_time_ms: ms.optional(),
3869
3890
  end_time_ms: ms.optional(),
3870
3891
  spice_options: spice_simulation_options.optional(),
3871
- dc_sweep_voltage_source_id: z176.string().optional(),
3872
- dc_sweep_current_source_id: z176.string().optional(),
3873
- dc_sweep_start: z176.number().optional(),
3874
- dc_sweep_stop: z176.number().optional(),
3875
- dc_sweep_step: z176.number().refine((dcSweepStep) => dcSweepStep !== 0).optional(),
3892
+ dc_sweep_voltage_source_id: z177.string().optional(),
3893
+ dc_sweep_current_source_id: z177.string().optional(),
3894
+ dc_sweep_start: z177.number().optional(),
3895
+ dc_sweep_stop: z177.number().optional(),
3896
+ dc_sweep_step: z177.number().refine((dcSweepStep) => dcSweepStep !== 0).optional(),
3876
3897
  dc_sweep_unit: simulation_dc_sweep_unit.optional(),
3877
- ac_sweep_type: z176.enum(["linear", "decade", "octave"]).optional(),
3878
- ac_samples_per_interval: z176.number().int().positive().optional(),
3879
- ac_sample_count: z176.number().int().positive().optional(),
3880
- ac_start_frequency_hz: z176.number().positive().optional(),
3881
- ac_stop_frequency_hz: z176.number().positive().optional()
3898
+ ac_sweep_type: z177.enum(["linear", "decade", "octave"]).optional(),
3899
+ ac_samples_per_interval: z177.number().int().positive().optional(),
3900
+ ac_sample_count: z177.number().int().positive().optional(),
3901
+ ac_start_frequency_hz: z177.number().positive().optional(),
3902
+ ac_stop_frequency_hz: z177.number().positive().optional()
3882
3903
  }).superRefine((experiment, context) => {
3883
3904
  if (experiment.experiment_type === "spice_dc_sweep") {
3884
3905
  const requiredFields = [
@@ -3890,7 +3911,7 @@ var simulation_experiment = z176.object({
3890
3911
  for (const field of requiredFields) {
3891
3912
  if (experiment[field] === void 0) {
3892
3913
  context.addIssue({
3893
- code: z176.ZodIssueCode.custom,
3914
+ code: z177.ZodIssueCode.custom,
3894
3915
  path: [field],
3895
3916
  message: `${field} is required for a DC sweep`
3896
3917
  });
@@ -3900,7 +3921,7 @@ var simulation_experiment = z176.object({
3900
3921
  const hasCurrentSource = experiment.dc_sweep_current_source_id !== void 0;
3901
3922
  if (hasVoltageSource === hasCurrentSource) {
3902
3923
  context.addIssue({
3903
- code: z176.ZodIssueCode.custom,
3924
+ code: z177.ZodIssueCode.custom,
3904
3925
  path: ["dc_sweep_voltage_source_id"],
3905
3926
  message: "Exactly one DC sweep voltage or current source ID is required"
3906
3927
  });
@@ -3909,35 +3930,35 @@ var simulation_experiment = z176.object({
3909
3930
  if (experiment.experiment_type === "spice_ac_analysis") {
3910
3931
  if (experiment.ac_sweep_type === void 0) {
3911
3932
  context.addIssue({
3912
- code: z176.ZodIssueCode.custom,
3933
+ code: z177.ZodIssueCode.custom,
3913
3934
  path: ["ac_sweep_type"],
3914
3935
  message: "ac_sweep_type is required for an AC analysis"
3915
3936
  });
3916
3937
  }
3917
3938
  if (experiment.ac_start_frequency_hz === void 0) {
3918
3939
  context.addIssue({
3919
- code: z176.ZodIssueCode.custom,
3940
+ code: z177.ZodIssueCode.custom,
3920
3941
  path: ["ac_start_frequency_hz"],
3921
3942
  message: "ac_start_frequency_hz is required for an AC analysis"
3922
3943
  });
3923
3944
  }
3924
3945
  if (experiment.ac_stop_frequency_hz === void 0) {
3925
3946
  context.addIssue({
3926
- code: z176.ZodIssueCode.custom,
3947
+ code: z177.ZodIssueCode.custom,
3927
3948
  path: ["ac_stop_frequency_hz"],
3928
3949
  message: "ac_stop_frequency_hz is required for an AC analysis"
3929
3950
  });
3930
3951
  }
3931
3952
  if (experiment.ac_sweep_type === "linear" && experiment.ac_sample_count === void 0) {
3932
3953
  context.addIssue({
3933
- code: z176.ZodIssueCode.custom,
3954
+ code: z177.ZodIssueCode.custom,
3934
3955
  path: ["ac_sample_count"],
3935
3956
  message: "ac_sample_count is required for a linear AC analysis"
3936
3957
  });
3937
3958
  }
3938
3959
  if ((experiment.ac_sweep_type === "decade" || experiment.ac_sweep_type === "octave") && experiment.ac_samples_per_interval === void 0) {
3939
3960
  context.addIssue({
3940
- code: z176.ZodIssueCode.custom,
3961
+ code: z177.ZodIssueCode.custom,
3941
3962
  path: ["ac_samples_per_interval"],
3942
3963
  message: "ac_samples_per_interval is required for decade and octave AC analyses"
3943
3964
  });
@@ -3947,87 +3968,87 @@ var simulation_experiment = z176.object({
3947
3968
  expectTypesMatch(true);
3948
3969
 
3949
3970
  // src/simulation/simulation_transient_voltage_graph.ts
3950
- import { z as z178 } from "zod";
3971
+ import { z as z179 } from "zod";
3951
3972
 
3952
3973
  // src/simulation/simulation_parameter_sweep_coordinate.ts
3953
- import { z as z177 } from "zod";
3954
- var simulation_parameter_sweep_coordinate = z177.object({
3955
- simulation_parameter_sweep_id: z177.string(),
3956
- sweep_index: z177.number().int().nonnegative(),
3957
- parameter_value: z177.number(),
3974
+ import { z as z178 } from "zod";
3975
+ var simulation_parameter_sweep_coordinate = z178.object({
3976
+ simulation_parameter_sweep_id: z178.string(),
3977
+ sweep_index: z178.number().int().nonnegative(),
3978
+ parameter_value: z178.number(),
3958
3979
  parameter_unit: simulation_parameter_unit
3959
3980
  });
3960
3981
  expectTypesMatch(true);
3961
3982
 
3962
3983
  // src/simulation/simulation_transient_voltage_graph.ts
3963
- var simulation_transient_voltage_graph = z178.object({
3964
- type: z178.literal("simulation_transient_voltage_graph"),
3984
+ var simulation_transient_voltage_graph = z179.object({
3985
+ type: z179.literal("simulation_transient_voltage_graph"),
3965
3986
  simulation_transient_voltage_graph_id: getZodPrefixedIdWithDefault(
3966
3987
  "simulation_transient_voltage_graph"
3967
3988
  ),
3968
- simulation_experiment_id: z178.string(),
3989
+ simulation_experiment_id: z179.string(),
3969
3990
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
3970
- timestamps_ms: z178.array(z178.number()).optional(),
3971
- voltage_levels: z178.array(z178.number()),
3972
- source_component_id: z178.string().optional(),
3973
- subcircuit_connectivity_map_key: z178.string().optional(),
3991
+ timestamps_ms: z179.array(z179.number()).optional(),
3992
+ voltage_levels: z179.array(z179.number()),
3993
+ source_component_id: z179.string().optional(),
3994
+ subcircuit_connectivity_map_key: z179.string().optional(),
3974
3995
  time_per_step: duration_ms,
3975
3996
  start_time_ms: ms,
3976
3997
  end_time_ms: ms,
3977
- name: z178.string().optional(),
3978
- color: z178.string().optional()
3998
+ name: z179.string().optional(),
3999
+ color: z179.string().optional()
3979
4000
  }).describe("Stores voltage measurements over time for a simulation");
3980
4001
  expectTypesMatch(true);
3981
4002
 
3982
4003
  // src/simulation/simulation_transient_current_graph.ts
3983
- import { z as z179 } from "zod";
3984
- var simulation_transient_current_graph = z179.object({
3985
- type: z179.literal("simulation_transient_current_graph"),
4004
+ import { z as z180 } from "zod";
4005
+ var simulation_transient_current_graph = z180.object({
4006
+ type: z180.literal("simulation_transient_current_graph"),
3986
4007
  simulation_transient_current_graph_id: getZodPrefixedIdWithDefault(
3987
4008
  "simulation_transient_current_graph"
3988
4009
  ),
3989
- simulation_experiment_id: z179.string(),
4010
+ simulation_experiment_id: z180.string(),
3990
4011
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
3991
- timestamps_ms: z179.array(z179.number()).optional(),
3992
- current_levels: z179.array(z179.number()),
3993
- source_component_id: z179.string().optional(),
3994
- subcircuit_connectivity_map_key: z179.string().optional(),
4012
+ timestamps_ms: z180.array(z180.number()).optional(),
4013
+ current_levels: z180.array(z180.number()),
4014
+ source_component_id: z180.string().optional(),
4015
+ subcircuit_connectivity_map_key: z180.string().optional(),
3995
4016
  time_per_step: duration_ms,
3996
4017
  start_time_ms: ms,
3997
4018
  end_time_ms: ms,
3998
- name: z179.string().optional(),
3999
- color: z179.string().optional()
4019
+ name: z180.string().optional(),
4020
+ color: z180.string().optional()
4000
4021
  }).describe("Stores current measurements over time for a simulation");
4001
4022
  expectTypesMatch(true);
4002
4023
 
4003
4024
  // src/simulation/simulation_switch.ts
4004
- import { z as z180 } from "zod";
4005
- var simulation_switch = z180.object({
4006
- type: z180.literal("simulation_switch"),
4025
+ import { z as z181 } from "zod";
4026
+ var simulation_switch = z181.object({
4027
+ type: z181.literal("simulation_switch"),
4007
4028
  simulation_switch_id: getZodPrefixedIdWithDefault("simulation_switch"),
4008
- source_component_id: z180.string().optional(),
4029
+ source_component_id: z181.string().optional(),
4009
4030
  closes_at: ms.optional(),
4010
4031
  opens_at: ms.optional(),
4011
- starts_closed: z180.boolean().optional(),
4032
+ starts_closed: z181.boolean().optional(),
4012
4033
  switching_frequency: frequency.optional()
4013
4034
  }).describe("Defines a switch for simulation timing control");
4014
4035
  expectTypesMatch(true);
4015
4036
 
4016
4037
  // src/simulation/simulation_voltage_probe.ts
4017
- import { z as z181 } from "zod";
4018
- var simulation_voltage_probe = z181.object({
4019
- type: z181.literal("simulation_voltage_probe"),
4038
+ import { z as z182 } from "zod";
4039
+ var simulation_voltage_probe = z182.object({
4040
+ type: z182.literal("simulation_voltage_probe"),
4020
4041
  simulation_voltage_probe_id: getZodPrefixedIdWithDefault(
4021
4042
  "simulation_voltage_probe"
4022
4043
  ),
4023
- source_component_id: z181.string().optional(),
4024
- name: z181.string().optional(),
4025
- signal_input_source_port_id: z181.string().optional(),
4026
- signal_input_source_net_id: z181.string().optional(),
4027
- reference_input_source_port_id: z181.string().optional(),
4028
- reference_input_source_net_id: z181.string().optional(),
4029
- subcircuit_id: z181.string().optional(),
4030
- color: z181.string().optional()
4044
+ source_component_id: z182.string().optional(),
4045
+ name: z182.string().optional(),
4046
+ signal_input_source_port_id: z182.string().optional(),
4047
+ signal_input_source_net_id: z182.string().optional(),
4048
+ reference_input_source_port_id: z182.string().optional(),
4049
+ reference_input_source_net_id: z182.string().optional(),
4050
+ subcircuit_id: z182.string().optional(),
4051
+ color: z182.string().optional()
4031
4052
  }).describe(
4032
4053
  "Defines a voltage probe for simulation. If a reference input is not provided, it measures against ground. If a reference input is provided, it measures the differential voltage between two points."
4033
4054
  ).superRefine((data, ctx) => {
@@ -4037,20 +4058,20 @@ var simulation_voltage_probe = z181.object({
4037
4058
  const has_nets = !!data.signal_input_source_net_id || !!data.reference_input_source_net_id;
4038
4059
  if (has_ports && has_nets) {
4039
4060
  ctx.addIssue({
4040
- code: z181.ZodIssueCode.custom,
4061
+ code: z182.ZodIssueCode.custom,
4041
4062
  message: "Cannot mix port and net connections in a differential probe."
4042
4063
  });
4043
4064
  } else if (has_ports) {
4044
4065
  if (!data.signal_input_source_port_id || !data.reference_input_source_port_id) {
4045
4066
  ctx.addIssue({
4046
- code: z181.ZodIssueCode.custom,
4067
+ code: z182.ZodIssueCode.custom,
4047
4068
  message: "Differential port probe requires both signal_input_source_port_id and reference_input_source_port_id."
4048
4069
  });
4049
4070
  }
4050
4071
  } else if (has_nets) {
4051
4072
  if (!data.signal_input_source_net_id || !data.reference_input_source_net_id) {
4052
4073
  ctx.addIssue({
4053
- code: z181.ZodIssueCode.custom,
4074
+ code: z182.ZodIssueCode.custom,
4054
4075
  message: "Differential net probe requires both signal_input_source_net_id and reference_input_source_net_id."
4055
4076
  });
4056
4077
  }
@@ -4058,7 +4079,7 @@ var simulation_voltage_probe = z181.object({
4058
4079
  } else {
4059
4080
  if (!!data.signal_input_source_port_id === !!data.signal_input_source_net_id) {
4060
4081
  ctx.addIssue({
4061
- code: z181.ZodIssueCode.custom,
4082
+ code: z182.ZodIssueCode.custom,
4062
4083
  message: "A voltage probe must have exactly one of signal_input_source_port_id or signal_input_source_net_id."
4063
4084
  });
4064
4085
  }
@@ -4067,20 +4088,20 @@ var simulation_voltage_probe = z181.object({
4067
4088
  expectTypesMatch(true);
4068
4089
 
4069
4090
  // src/simulation/simulation_current_probe.ts
4070
- import { z as z182 } from "zod";
4071
- var simulation_current_probe = z182.object({
4072
- type: z182.literal("simulation_current_probe"),
4091
+ import { z as z183 } from "zod";
4092
+ var simulation_current_probe = z183.object({
4093
+ type: z183.literal("simulation_current_probe"),
4073
4094
  simulation_current_probe_id: getZodPrefixedIdWithDefault(
4074
4095
  "simulation_current_probe"
4075
4096
  ),
4076
- source_component_id: z182.string().optional(),
4077
- name: z182.string().optional(),
4078
- positive_source_port_id: z182.string().optional(),
4079
- negative_source_port_id: z182.string().optional(),
4080
- positive_source_net_id: z182.string().optional(),
4081
- negative_source_net_id: z182.string().optional(),
4082
- subcircuit_id: z182.string().optional(),
4083
- color: z182.string().optional()
4097
+ source_component_id: z183.string().optional(),
4098
+ name: z183.string().optional(),
4099
+ positive_source_port_id: z183.string().optional(),
4100
+ negative_source_port_id: z183.string().optional(),
4101
+ positive_source_net_id: z183.string().optional(),
4102
+ negative_source_net_id: z183.string().optional(),
4103
+ subcircuit_id: z183.string().optional(),
4104
+ color: z183.string().optional()
4084
4105
  }).describe(
4085
4106
  "Defines a current probe for simulation. It measures current flowing from the positive endpoint to the negative endpoint."
4086
4107
  ).superRefine((data, ctx) => {
@@ -4092,7 +4113,7 @@ var simulation_current_probe = z182.object({
4092
4113
  const hasNets = hasPositiveNet || hasNegativeNet;
4093
4114
  if (hasPorts && hasNets) {
4094
4115
  ctx.addIssue({
4095
- code: z182.ZodIssueCode.custom,
4116
+ code: z183.ZodIssueCode.custom,
4096
4117
  message: "Cannot mix port and net connections in a current probe."
4097
4118
  });
4098
4119
  return;
@@ -4100,7 +4121,7 @@ var simulation_current_probe = z182.object({
4100
4121
  if (hasPorts) {
4101
4122
  if (!hasPositivePort || !hasNegativePort) {
4102
4123
  ctx.addIssue({
4103
- code: z182.ZodIssueCode.custom,
4124
+ code: z183.ZodIssueCode.custom,
4104
4125
  message: "Current probe using source ports requires both positive_source_port_id and negative_source_port_id."
4105
4126
  });
4106
4127
  }
@@ -4109,71 +4130,71 @@ var simulation_current_probe = z182.object({
4109
4130
  if (hasNets) {
4110
4131
  if (!hasPositiveNet || !hasNegativeNet) {
4111
4132
  ctx.addIssue({
4112
- code: z182.ZodIssueCode.custom,
4133
+ code: z183.ZodIssueCode.custom,
4113
4134
  message: "Current probe using source nets requires both positive_source_net_id and negative_source_net_id."
4114
4135
  });
4115
4136
  }
4116
4137
  return;
4117
4138
  }
4118
4139
  ctx.addIssue({
4119
- code: z182.ZodIssueCode.custom,
4140
+ code: z183.ZodIssueCode.custom,
4120
4141
  message: "A current probe must have either positive/negative source port ids or positive/negative source net ids."
4121
4142
  });
4122
4143
  });
4123
4144
  expectTypesMatch(true);
4124
4145
 
4125
4146
  // src/simulation/simulation_unknown_experiment_error.ts
4126
- import { z as z183 } from "zod";
4147
+ import { z as z184 } from "zod";
4127
4148
  var simulation_unknown_experiment_error = base_circuit_json_error.extend({
4128
- type: z183.literal("simulation_unknown_experiment_error"),
4149
+ type: z184.literal("simulation_unknown_experiment_error"),
4129
4150
  simulation_unknown_experiment_error_id: getZodPrefixedIdWithDefault(
4130
4151
  "simulation_unknown_experiment_error"
4131
4152
  ),
4132
- error_type: z183.literal("simulation_unknown_experiment_error").default("simulation_unknown_experiment_error"),
4133
- simulation_experiment_id: z183.string().optional(),
4134
- subcircuit_id: z183.string().optional()
4153
+ error_type: z184.literal("simulation_unknown_experiment_error").default("simulation_unknown_experiment_error"),
4154
+ simulation_experiment_id: z184.string().optional(),
4155
+ subcircuit_id: z184.string().optional()
4135
4156
  }).describe("An unknown error occurred during the simulation experiment.");
4136
4157
  expectTypesMatch(true);
4137
4158
 
4138
4159
  // src/simulation/simulation_parameter_sweep.ts
4139
- import { z as z184 } from "zod";
4140
- var simulation_parameter_type = z184.enum([
4160
+ import { z as z185 } from "zod";
4161
+ var simulation_parameter_type = z185.enum([
4141
4162
  "resistance",
4142
4163
  "capacitance",
4143
4164
  "inductance",
4144
4165
  "voltage",
4145
4166
  "current"
4146
4167
  ]);
4147
- var simulation_parameter_sweep_base = z184.object({
4148
- type: z184.literal("simulation_parameter_sweep"),
4168
+ var simulation_parameter_sweep_base = z185.object({
4169
+ type: z185.literal("simulation_parameter_sweep"),
4149
4170
  simulation_parameter_sweep_id: getZodPrefixedIdWithDefault(
4150
4171
  "simulation_parameter_sweep"
4151
4172
  ),
4152
- simulation_experiment_id: z184.string(),
4153
- name: z184.string().optional(),
4154
- parameter_values: z184.array(z184.number()).min(1),
4173
+ simulation_experiment_id: z185.string(),
4174
+ name: z185.string().optional(),
4175
+ parameter_values: z185.array(z185.number()).min(1),
4155
4176
  parameter_unit: simulation_parameter_unit
4156
4177
  });
4157
- var simulation_parameter_sweep = z184.discriminatedUnion("parameter_type", [
4178
+ var simulation_parameter_sweep = z185.discriminatedUnion("parameter_type", [
4158
4179
  simulation_parameter_sweep_base.extend({
4159
- parameter_type: z184.literal("resistance"),
4160
- resistor_source_component_id: z184.string()
4180
+ parameter_type: z185.literal("resistance"),
4181
+ resistor_source_component_id: z185.string()
4161
4182
  }),
4162
4183
  simulation_parameter_sweep_base.extend({
4163
- parameter_type: z184.literal("capacitance"),
4164
- capacitor_source_component_id: z184.string()
4184
+ parameter_type: z185.literal("capacitance"),
4185
+ capacitor_source_component_id: z185.string()
4165
4186
  }),
4166
4187
  simulation_parameter_sweep_base.extend({
4167
- parameter_type: z184.literal("inductance"),
4168
- inductor_source_component_id: z184.string()
4188
+ parameter_type: z185.literal("inductance"),
4189
+ inductor_source_component_id: z185.string()
4169
4190
  }),
4170
4191
  simulation_parameter_sweep_base.extend({
4171
- parameter_type: z184.literal("voltage"),
4172
- source_net_id: z184.string()
4192
+ parameter_type: z185.literal("voltage"),
4193
+ source_net_id: z185.string()
4173
4194
  }),
4174
4195
  simulation_parameter_sweep_base.extend({
4175
- parameter_type: z184.literal("current"),
4176
- current_source_component_id: z184.string()
4196
+ parameter_type: z185.literal("current"),
4197
+ current_source_component_id: z185.string()
4177
4198
  })
4178
4199
  ]).describe("Repeats a simulation experiment over component parameter values");
4179
4200
  expectTypesMatch(
@@ -4181,52 +4202,52 @@ expectTypesMatch(
4181
4202
  );
4182
4203
 
4183
4204
  // src/simulation/simulation_dc_operating_point_voltage.ts
4184
- import { z as z185 } from "zod";
4185
- var simulation_dc_operating_point_voltage = z185.object({
4186
- type: z185.literal("simulation_dc_operating_point_voltage"),
4205
+ import { z as z186 } from "zod";
4206
+ var simulation_dc_operating_point_voltage = z186.object({
4207
+ type: z186.literal("simulation_dc_operating_point_voltage"),
4187
4208
  simulation_dc_operating_point_voltage_id: getZodPrefixedIdWithDefault(
4188
4209
  "simulation_dc_operating_point_voltage"
4189
4210
  ),
4190
- simulation_experiment_id: z185.string(),
4211
+ simulation_experiment_id: z186.string(),
4191
4212
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4192
- simulation_voltage_probe_id: z185.string(),
4193
- voltage: z185.number(),
4194
- name: z185.string().optional(),
4195
- color: z185.string().optional()
4213
+ simulation_voltage_probe_id: z186.string(),
4214
+ voltage: z186.number(),
4215
+ name: z186.string().optional(),
4216
+ color: z186.string().optional()
4196
4217
  });
4197
4218
  expectTypesMatch(true);
4198
4219
 
4199
4220
  // src/simulation/simulation_dc_operating_point_current.ts
4200
- import { z as z186 } from "zod";
4201
- var simulation_dc_operating_point_current = z186.object({
4202
- type: z186.literal("simulation_dc_operating_point_current"),
4221
+ import { z as z187 } from "zod";
4222
+ var simulation_dc_operating_point_current = z187.object({
4223
+ type: z187.literal("simulation_dc_operating_point_current"),
4203
4224
  simulation_dc_operating_point_current_id: getZodPrefixedIdWithDefault(
4204
4225
  "simulation_dc_operating_point_current"
4205
4226
  ),
4206
- simulation_experiment_id: z186.string(),
4227
+ simulation_experiment_id: z187.string(),
4207
4228
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4208
- simulation_current_probe_id: z186.string(),
4209
- current: z186.number(),
4210
- name: z186.string().optional(),
4211
- color: z186.string().optional()
4229
+ simulation_current_probe_id: z187.string(),
4230
+ current: z187.number(),
4231
+ name: z187.string().optional(),
4232
+ color: z187.string().optional()
4212
4233
  });
4213
4234
  expectTypesMatch(true);
4214
4235
 
4215
4236
  // src/simulation/simulation_dc_sweep_voltage_graph.ts
4216
- import { z as z187 } from "zod";
4217
- var simulation_dc_sweep_voltage_graph = z187.object({
4218
- type: z187.literal("simulation_dc_sweep_voltage_graph"),
4237
+ import { z as z188 } from "zod";
4238
+ var simulation_dc_sweep_voltage_graph = z188.object({
4239
+ type: z188.literal("simulation_dc_sweep_voltage_graph"),
4219
4240
  simulation_dc_sweep_voltage_graph_id: getZodPrefixedIdWithDefault(
4220
4241
  "simulation_dc_sweep_voltage_graph"
4221
4242
  ),
4222
- simulation_experiment_id: z187.string(),
4243
+ simulation_experiment_id: z188.string(),
4223
4244
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4224
- simulation_voltage_probe_id: z187.string(),
4225
- sweep_values: z187.array(z187.number()),
4245
+ simulation_voltage_probe_id: z188.string(),
4246
+ sweep_values: z188.array(z188.number()),
4226
4247
  sweep_unit: simulation_dc_sweep_unit,
4227
- voltage_levels: z187.array(z187.number()),
4228
- name: z187.string().optional(),
4229
- color: z187.string().optional()
4248
+ voltage_levels: z188.array(z188.number()),
4249
+ name: z188.string().optional(),
4250
+ color: z188.string().optional()
4230
4251
  }).refine(
4231
4252
  (graph) => graph.sweep_values.length === graph.voltage_levels.length,
4232
4253
  {
@@ -4236,20 +4257,20 @@ var simulation_dc_sweep_voltage_graph = z187.object({
4236
4257
  expectTypesMatch(true);
4237
4258
 
4238
4259
  // src/simulation/simulation_dc_sweep_current_graph.ts
4239
- import { z as z188 } from "zod";
4240
- var simulation_dc_sweep_current_graph = z188.object({
4241
- type: z188.literal("simulation_dc_sweep_current_graph"),
4260
+ import { z as z189 } from "zod";
4261
+ var simulation_dc_sweep_current_graph = z189.object({
4262
+ type: z189.literal("simulation_dc_sweep_current_graph"),
4242
4263
  simulation_dc_sweep_current_graph_id: getZodPrefixedIdWithDefault(
4243
4264
  "simulation_dc_sweep_current_graph"
4244
4265
  ),
4245
- simulation_experiment_id: z188.string(),
4266
+ simulation_experiment_id: z189.string(),
4246
4267
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4247
- simulation_current_probe_id: z188.string(),
4248
- sweep_values: z188.array(z188.number()),
4268
+ simulation_current_probe_id: z189.string(),
4269
+ sweep_values: z189.array(z189.number()),
4249
4270
  sweep_unit: simulation_dc_sweep_unit,
4250
- current_levels: z188.array(z188.number()),
4251
- name: z188.string().optional(),
4252
- color: z188.string().optional()
4271
+ current_levels: z189.array(z189.number()),
4272
+ name: z189.string().optional(),
4273
+ color: z189.string().optional()
4253
4274
  }).refine(
4254
4275
  (graph) => graph.sweep_values.length === graph.current_levels.length,
4255
4276
  {
@@ -4259,29 +4280,29 @@ var simulation_dc_sweep_current_graph = z188.object({
4259
4280
  expectTypesMatch(true);
4260
4281
 
4261
4282
  // src/simulation/simulation_ac_sweep_voltage_graph.ts
4262
- import { z as z190 } from "zod";
4283
+ import { z as z191 } from "zod";
4263
4284
 
4264
4285
  // src/simulation/simulation_complex_sample.ts
4265
- import { z as z189 } from "zod";
4266
- var simulation_complex_sample = z189.object({
4267
- re: z189.number(),
4268
- im: z189.number()
4286
+ import { z as z190 } from "zod";
4287
+ var simulation_complex_sample = z190.object({
4288
+ re: z190.number(),
4289
+ im: z190.number()
4269
4290
  });
4270
4291
  expectTypesMatch(true);
4271
4292
 
4272
4293
  // src/simulation/simulation_ac_sweep_voltage_graph.ts
4273
- var simulation_ac_sweep_voltage_graph = z190.object({
4274
- type: z190.literal("simulation_ac_sweep_voltage_graph"),
4294
+ var simulation_ac_sweep_voltage_graph = z191.object({
4295
+ type: z191.literal("simulation_ac_sweep_voltage_graph"),
4275
4296
  simulation_ac_sweep_voltage_graph_id: getZodPrefixedIdWithDefault(
4276
4297
  "simulation_ac_sweep_voltage_graph"
4277
4298
  ),
4278
- simulation_experiment_id: z190.string(),
4299
+ simulation_experiment_id: z191.string(),
4279
4300
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4280
- simulation_voltage_probe_id: z190.string(),
4281
- frequencies_hz: z190.array(z190.number()),
4282
- complex_voltages: z190.array(simulation_complex_sample),
4283
- name: z190.string().optional(),
4284
- color: z190.string().optional()
4301
+ simulation_voltage_probe_id: z191.string(),
4302
+ frequencies_hz: z191.array(z191.number()),
4303
+ complex_voltages: z191.array(simulation_complex_sample),
4304
+ name: z191.string().optional(),
4305
+ color: z191.string().optional()
4285
4306
  }).refine(
4286
4307
  (graph) => graph.frequencies_hz.length === graph.complex_voltages.length,
4287
4308
  {
@@ -4291,19 +4312,19 @@ var simulation_ac_sweep_voltage_graph = z190.object({
4291
4312
  expectTypesMatch(true);
4292
4313
 
4293
4314
  // src/simulation/simulation_ac_sweep_current_graph.ts
4294
- import { z as z191 } from "zod";
4295
- var simulation_ac_sweep_current_graph = z191.object({
4296
- type: z191.literal("simulation_ac_sweep_current_graph"),
4315
+ import { z as z192 } from "zod";
4316
+ var simulation_ac_sweep_current_graph = z192.object({
4317
+ type: z192.literal("simulation_ac_sweep_current_graph"),
4297
4318
  simulation_ac_sweep_current_graph_id: getZodPrefixedIdWithDefault(
4298
4319
  "simulation_ac_sweep_current_graph"
4299
4320
  ),
4300
- simulation_experiment_id: z191.string(),
4321
+ simulation_experiment_id: z192.string(),
4301
4322
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4302
- simulation_current_probe_id: z191.string(),
4303
- frequencies_hz: z191.array(z191.number()),
4304
- complex_currents: z191.array(simulation_complex_sample),
4305
- name: z191.string().optional(),
4306
- color: z191.string().optional()
4323
+ simulation_current_probe_id: z192.string(),
4324
+ frequencies_hz: z192.array(z192.number()),
4325
+ complex_currents: z192.array(simulation_complex_sample),
4326
+ name: z192.string().optional(),
4327
+ color: z192.string().optional()
4307
4328
  }).refine(
4308
4329
  (graph) => graph.frequencies_hz.length === graph.complex_currents.length,
4309
4330
  {
@@ -4313,52 +4334,52 @@ var simulation_ac_sweep_current_graph = z191.object({
4313
4334
  expectTypesMatch(true);
4314
4335
 
4315
4336
  // src/simulation/simulation_op_amp.ts
4316
- import { z as z192 } from "zod";
4317
- var simulation_op_amp = z192.object({
4318
- type: z192.literal("simulation_op_amp"),
4337
+ import { z as z193 } from "zod";
4338
+ var simulation_op_amp = z193.object({
4339
+ type: z193.literal("simulation_op_amp"),
4319
4340
  simulation_op_amp_id: getZodPrefixedIdWithDefault("simulation_op_amp"),
4320
- source_component_id: z192.string().optional(),
4321
- inverting_input_source_port_id: z192.string(),
4322
- non_inverting_input_source_port_id: z192.string(),
4323
- output_source_port_id: z192.string(),
4324
- positive_supply_source_port_id: z192.string(),
4325
- negative_supply_source_port_id: z192.string()
4341
+ source_component_id: z193.string().optional(),
4342
+ inverting_input_source_port_id: z193.string(),
4343
+ non_inverting_input_source_port_id: z193.string(),
4344
+ output_source_port_id: z193.string(),
4345
+ positive_supply_source_port_id: z193.string(),
4346
+ negative_supply_source_port_id: z193.string()
4326
4347
  }).describe("Defines a simple ideal operational amplifier for simulation");
4327
4348
  expectTypesMatch(true);
4328
4349
 
4329
4350
  // src/simulation/simulation_spice_subcircuit.ts
4330
- import { z as z193 } from "zod";
4331
- var simulation_spice_subcircuit = z193.object({
4332
- type: z193.literal("simulation_spice_subcircuit"),
4351
+ import { z as z194 } from "zod";
4352
+ var simulation_spice_subcircuit = z194.object({
4353
+ type: z194.literal("simulation_spice_subcircuit"),
4333
4354
  simulation_spice_subcircuit_id: getZodPrefixedIdWithDefault(
4334
4355
  "simulation_spice_subcircuit"
4335
4356
  ),
4336
- source_component_id: z193.string(),
4337
- spice_pin_to_source_port_map: z193.record(z193.string(), z193.string()),
4338
- subcircuit_source: z193.string()
4357
+ source_component_id: z194.string(),
4358
+ spice_pin_to_source_port_map: z194.record(z194.string(), z194.string()),
4359
+ subcircuit_source: z194.string()
4339
4360
  }).describe("Defines a custom SPICE subcircuit model for simulation");
4340
4361
  expectTypesMatch(
4341
4362
  true
4342
4363
  );
4343
4364
 
4344
4365
  // src/simulation/simulation_oscilloscope_trace.ts
4345
- import { z as z194 } from "zod";
4366
+ import { z as z195 } from "zod";
4346
4367
  var hasValue = (value) => value !== void 0;
4347
- var simulation_oscilloscope_trace = z194.object({
4348
- type: z194.literal("simulation_oscilloscope_trace"),
4368
+ var simulation_oscilloscope_trace = z195.object({
4369
+ type: z195.literal("simulation_oscilloscope_trace"),
4349
4370
  simulation_oscilloscope_trace_id: getZodPrefixedIdWithDefault(
4350
4371
  "simulation_oscilloscope_trace"
4351
4372
  ),
4352
- simulation_transient_voltage_graph_id: z194.string().optional(),
4353
- simulation_transient_current_graph_id: z194.string().optional(),
4354
- simulation_voltage_probe_id: z194.string().optional(),
4355
- simulation_current_probe_id: z194.string().optional(),
4356
- display_name: z194.string().optional(),
4357
- color: z194.string().optional(),
4358
- display_center_value: z194.number().optional(),
4359
- display_center_offset_divs: z194.number().optional(),
4360
- volts_per_div: z194.number().positive().optional(),
4361
- amps_per_div: z194.number().positive().optional()
4373
+ simulation_transient_voltage_graph_id: z195.string().optional(),
4374
+ simulation_transient_current_graph_id: z195.string().optional(),
4375
+ simulation_voltage_probe_id: z195.string().optional(),
4376
+ simulation_current_probe_id: z195.string().optional(),
4377
+ display_name: z195.string().optional(),
4378
+ color: z195.string().optional(),
4379
+ display_center_value: z195.number().optional(),
4380
+ display_center_offset_divs: z195.number().optional(),
4381
+ volts_per_div: z195.number().positive().optional(),
4382
+ amps_per_div: z195.number().positive().optional()
4362
4383
  }).describe(
4363
4384
  "Defines how a simulation measurement is rendered as an oscilloscope-style trace."
4364
4385
  ).superRefine((data, ctx) => {
@@ -4372,19 +4393,19 @@ var simulation_oscilloscope_trace = z194.object({
4372
4393
  ].filter(hasValue).length;
4373
4394
  if (voltageReferences + currentReferences !== 1) {
4374
4395
  ctx.addIssue({
4375
- code: z194.ZodIssueCode.custom,
4396
+ code: z195.ZodIssueCode.custom,
4376
4397
  message: "An oscilloscope trace must reference exactly one voltage graph, current graph, voltage probe, or current probe."
4377
4398
  });
4378
4399
  }
4379
4400
  if (voltageReferences > 0 && data.amps_per_div !== void 0) {
4380
4401
  ctx.addIssue({
4381
- code: z194.ZodIssueCode.custom,
4402
+ code: z195.ZodIssueCode.custom,
4382
4403
  message: "Voltage oscilloscope traces must use volts_per_div, not amps_per_div."
4383
4404
  });
4384
4405
  }
4385
4406
  if (currentReferences > 0 && data.volts_per_div !== void 0) {
4386
4407
  ctx.addIssue({
4387
- code: z194.ZodIssueCode.custom,
4408
+ code: z195.ZodIssueCode.custom,
4388
4409
  message: "Current oscilloscope traces must use amps_per_div, not volts_per_div."
4389
4410
  });
4390
4411
  }
@@ -4392,8 +4413,8 @@ var simulation_oscilloscope_trace = z194.object({
4392
4413
  expectTypesMatch(true);
4393
4414
 
4394
4415
  // src/any_circuit_element.ts
4395
- import { z as z195 } from "zod";
4396
- var any_circuit_element = z195.union([
4416
+ import { z as z196 } from "zod";
4417
+ var any_circuit_element = z196.union([
4397
4418
  source_trace,
4398
4419
  source_port,
4399
4420
  source_component_internal_connection,
@@ -4453,6 +4474,7 @@ var any_circuit_element = z195.union([
4453
4474
  pcb_trace,
4454
4475
  pcb_trace_warning,
4455
4476
  pcb_trace_too_long_warning,
4477
+ pcb_trace_too_many_vias_warning,
4456
4478
  pcb_via,
4457
4479
  pcb_smtpad,
4458
4480
  pcb_solder_paste,
@@ -4688,6 +4710,7 @@ export {
4688
4710
  pcb_trace_route_point_via,
4689
4711
  pcb_trace_route_point_wire,
4690
4712
  pcb_trace_too_long_warning,
4713
+ pcb_trace_too_many_vias_warning,
4691
4714
  pcb_trace_warning,
4692
4715
  pcb_via,
4693
4716
  pcb_via_clearance_error,