circuit-json 0.0.193 → 0.0.195

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
@@ -817,27 +817,40 @@ var schematic_error = z46.object({
817
817
  }).describe("Defines a schematic error on the schematic");
818
818
  expectTypesMatch(true);
819
819
 
820
- // src/schematic/schematic_debug_object.ts
820
+ // src/schematic/schematic_layout_error.ts
821
821
  import { z as z47 } from "zod";
822
- var schematic_debug_object_base = z47.object({
823
- type: z47.literal("schematic_debug_object"),
824
- label: z47.string().optional()
822
+ var schematic_layout_error = z47.object({
823
+ type: z47.literal("schematic_layout_error"),
824
+ schematic_layout_error_id: getZodPrefixedIdWithDefault(
825
+ "schematic_layout_error"
826
+ ),
827
+ message: z47.string(),
828
+ source_group_id: z47.string(),
829
+ schematic_group_id: z47.string()
830
+ }).describe("Error emitted when schematic layout fails for a group");
831
+ expectTypesMatch(true);
832
+
833
+ // src/schematic/schematic_debug_object.ts
834
+ import { z as z48 } from "zod";
835
+ var schematic_debug_object_base = z48.object({
836
+ type: z48.literal("schematic_debug_object"),
837
+ label: z48.string().optional()
825
838
  });
826
839
  var schematic_debug_rect = schematic_debug_object_base.extend({
827
- shape: z47.literal("rect"),
840
+ shape: z48.literal("rect"),
828
841
  center: point,
829
842
  size
830
843
  });
831
844
  var schematic_debug_line = schematic_debug_object_base.extend({
832
- shape: z47.literal("line"),
845
+ shape: z48.literal("line"),
833
846
  start: point,
834
847
  end: point
835
848
  });
836
849
  var schematic_debug_point = schematic_debug_object_base.extend({
837
- shape: z47.literal("point"),
850
+ shape: z48.literal("point"),
838
851
  center: point
839
852
  });
840
- var schematic_debug_object = z47.discriminatedUnion("shape", [
853
+ var schematic_debug_object = z48.discriminatedUnion("shape", [
841
854
  schematic_debug_rect,
842
855
  schematic_debug_line,
843
856
  schematic_debug_point
@@ -845,52 +858,52 @@ var schematic_debug_object = z47.discriminatedUnion("shape", [
845
858
  expectTypesMatch(true);
846
859
 
847
860
  // src/schematic/schematic_voltage_probe.ts
848
- import { z as z48 } from "zod";
849
- var schematic_voltage_probe = z48.object({
850
- type: z48.literal("schematic_voltage_probe"),
851
- schematic_voltage_probe_id: z48.string(),
861
+ import { z as z49 } from "zod";
862
+ var schematic_voltage_probe = z49.object({
863
+ type: z49.literal("schematic_voltage_probe"),
864
+ schematic_voltage_probe_id: z49.string(),
852
865
  position: point,
853
- schematic_trace_id: z48.string(),
866
+ schematic_trace_id: z49.string(),
854
867
  voltage: voltage.optional()
855
868
  }).describe("Defines a voltage probe measurement point on a schematic trace");
856
869
  expectTypesMatch(true);
857
870
 
858
871
  // src/schematic/schematic_manual_edit_conflict_warning.ts
859
- import { z as z49 } from "zod";
860
- var schematic_manual_edit_conflict_warning = z49.object({
861
- type: z49.literal("schematic_manual_edit_conflict_warning"),
872
+ import { z as z50 } from "zod";
873
+ var schematic_manual_edit_conflict_warning = z50.object({
874
+ type: z50.literal("schematic_manual_edit_conflict_warning"),
862
875
  schematic_manual_edit_conflict_warning_id: getZodPrefixedIdWithDefault(
863
876
  "schematic_manual_edit_conflict_warning"
864
877
  ),
865
- message: z49.string(),
866
- schematic_component_id: z49.string(),
867
- schematic_group_id: z49.string().optional(),
868
- subcircuit_id: z49.string().optional(),
869
- source_component_id: z49.string()
878
+ message: z50.string(),
879
+ schematic_component_id: z50.string(),
880
+ schematic_group_id: z50.string().optional(),
881
+ subcircuit_id: z50.string().optional(),
882
+ source_component_id: z50.string()
870
883
  }).describe(
871
884
  "Warning emitted when a component has both manual placement and explicit schX/schY coordinates"
872
885
  );
873
886
  expectTypesMatch(true);
874
887
 
875
888
  // src/schematic/schematic_group.ts
876
- import { z as z50 } from "zod";
877
- var schematic_group = z50.object({
878
- type: z50.literal("schematic_group"),
889
+ import { z as z51 } from "zod";
890
+ var schematic_group = z51.object({
891
+ type: z51.literal("schematic_group"),
879
892
  schematic_group_id: getZodPrefixedIdWithDefault("schematic_group"),
880
- source_group_id: z50.string(),
881
- is_subcircuit: z50.boolean().optional(),
882
- subcircuit_id: z50.string().optional(),
893
+ source_group_id: z51.string(),
894
+ is_subcircuit: z51.boolean().optional(),
895
+ subcircuit_id: z51.string().optional(),
883
896
  width: length,
884
897
  height: length,
885
898
  center: point,
886
- schematic_component_ids: z50.array(z50.string()),
887
- name: z50.string().optional(),
888
- description: z50.string().optional()
899
+ schematic_component_ids: z51.array(z51.string()),
900
+ name: z51.string().optional(),
901
+ description: z51.string().optional()
889
902
  }).describe("Defines a group of components on the schematic");
890
903
  expectTypesMatch(true);
891
904
 
892
905
  // src/pcb/properties/layer_ref.ts
893
- import { z as z51 } from "zod";
906
+ import { z as z52 } from "zod";
894
907
  var all_layers = [
895
908
  "top",
896
909
  "bottom",
@@ -901,9 +914,9 @@ var all_layers = [
901
914
  "inner5",
902
915
  "inner6"
903
916
  ];
904
- var layer_string = z51.enum(all_layers);
917
+ var layer_string = z52.enum(all_layers);
905
918
  var layer_ref = layer_string.or(
906
- z51.object({
919
+ z52.object({
907
920
  name: layer_string
908
921
  })
909
922
  ).transform((layer) => {
@@ -912,53 +925,53 @@ var layer_ref = layer_string.or(
912
925
  }
913
926
  return layer.name;
914
927
  });
915
- var visible_layer = z51.enum(["top", "bottom"]);
928
+ var visible_layer = z52.enum(["top", "bottom"]);
916
929
 
917
930
  // src/pcb/properties/pcb_route_hints.ts
918
- import { z as z52 } from "zod";
919
- var pcb_route_hint = z52.object({
931
+ import { z as z53 } from "zod";
932
+ var pcb_route_hint = z53.object({
920
933
  x: distance,
921
934
  y: distance,
922
- via: z52.boolean().optional(),
935
+ via: z53.boolean().optional(),
923
936
  via_to_layer: layer_ref.optional()
924
937
  });
925
- var pcb_route_hints = z52.array(pcb_route_hint);
938
+ var pcb_route_hints = z53.array(pcb_route_hint);
926
939
 
927
940
  // src/pcb/properties/route_hint_point.ts
928
- import { z as z53 } from "zod";
929
- var route_hint_point = z53.object({
941
+ import { z as z54 } from "zod";
942
+ var route_hint_point = z54.object({
930
943
  x: distance,
931
944
  y: distance,
932
- via: z53.boolean().optional(),
945
+ via: z54.boolean().optional(),
933
946
  to_layer: layer_ref.optional(),
934
947
  trace_width: distance.optional()
935
948
  });
936
949
 
937
950
  // src/pcb/pcb_component.ts
938
- import { z as z54 } from "zod";
939
- var pcb_component = z54.object({
940
- type: z54.literal("pcb_component"),
951
+ import { z as z55 } from "zod";
952
+ var pcb_component = z55.object({
953
+ type: z55.literal("pcb_component"),
941
954
  pcb_component_id: getZodPrefixedIdWithDefault("pcb_component"),
942
- source_component_id: z54.string(),
955
+ source_component_id: z55.string(),
943
956
  center: point,
944
957
  layer: layer_ref,
945
958
  rotation,
946
959
  width: length,
947
960
  height: length,
948
- subcircuit_id: z54.string().optional(),
949
- pcb_group_id: z54.string().optional()
961
+ subcircuit_id: z55.string().optional(),
962
+ pcb_group_id: z55.string().optional()
950
963
  }).describe("Defines a component on the PCB");
951
964
  expectTypesMatch(true);
952
965
 
953
966
  // src/pcb/pcb_hole.ts
954
- import { z as z55 } from "zod";
955
- var pcb_hole_circle_or_square = z55.object({
956
- type: z55.literal("pcb_hole"),
967
+ import { z as z56 } from "zod";
968
+ var pcb_hole_circle_or_square = z56.object({
969
+ type: z56.literal("pcb_hole"),
957
970
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
958
- pcb_group_id: z55.string().optional(),
959
- subcircuit_id: z55.string().optional(),
960
- hole_shape: z55.enum(["circle", "square"]),
961
- hole_diameter: z55.number(),
971
+ pcb_group_id: z56.string().optional(),
972
+ subcircuit_id: z56.string().optional(),
973
+ hole_shape: z56.enum(["circle", "square"]),
974
+ hole_diameter: z56.number(),
962
975
  x: distance,
963
976
  y: distance
964
977
  });
@@ -966,14 +979,14 @@ var pcb_hole_circle_or_square_shape = pcb_hole_circle_or_square.describe(
966
979
  "Defines a circular or square hole on the PCB"
967
980
  );
968
981
  expectTypesMatch(true);
969
- var pcb_hole_oval = z55.object({
970
- type: z55.literal("pcb_hole"),
982
+ var pcb_hole_oval = z56.object({
983
+ type: z56.literal("pcb_hole"),
971
984
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
972
- pcb_group_id: z55.string().optional(),
973
- subcircuit_id: z55.string().optional(),
974
- hole_shape: z55.literal("oval"),
975
- hole_width: z55.number(),
976
- hole_height: z55.number(),
985
+ pcb_group_id: z56.string().optional(),
986
+ subcircuit_id: z56.string().optional(),
987
+ hole_shape: z56.literal("oval"),
988
+ hole_width: z56.number(),
989
+ hole_height: z56.number(),
977
990
  x: distance,
978
991
  y: distance
979
992
  });
@@ -984,77 +997,77 @@ expectTypesMatch(true);
984
997
  var pcb_hole = pcb_hole_circle_or_square.or(pcb_hole_oval);
985
998
 
986
999
  // src/pcb/pcb_plated_hole.ts
987
- import { z as z56 } from "zod";
988
- var pcb_plated_hole_circle = z56.object({
989
- type: z56.literal("pcb_plated_hole"),
990
- shape: z56.literal("circle"),
991
- pcb_group_id: z56.string().optional(),
992
- subcircuit_id: z56.string().optional(),
993
- outer_diameter: z56.number(),
994
- hole_diameter: z56.number(),
1000
+ import { z as z57 } from "zod";
1001
+ var pcb_plated_hole_circle = z57.object({
1002
+ type: z57.literal("pcb_plated_hole"),
1003
+ shape: z57.literal("circle"),
1004
+ pcb_group_id: z57.string().optional(),
1005
+ subcircuit_id: z57.string().optional(),
1006
+ outer_diameter: z57.number(),
1007
+ hole_diameter: z57.number(),
995
1008
  x: distance,
996
1009
  y: distance,
997
- layers: z56.array(layer_ref),
998
- port_hints: z56.array(z56.string()).optional(),
999
- pcb_component_id: z56.string().optional(),
1000
- pcb_port_id: z56.string().optional(),
1010
+ layers: z57.array(layer_ref),
1011
+ port_hints: z57.array(z57.string()).optional(),
1012
+ pcb_component_id: z57.string().optional(),
1013
+ pcb_port_id: z57.string().optional(),
1001
1014
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole")
1002
1015
  });
1003
- var pcb_plated_hole_oval = z56.object({
1004
- type: z56.literal("pcb_plated_hole"),
1005
- shape: z56.enum(["oval", "pill"]),
1006
- pcb_group_id: z56.string().optional(),
1007
- subcircuit_id: z56.string().optional(),
1008
- outer_width: z56.number(),
1009
- outer_height: z56.number(),
1010
- hole_width: z56.number(),
1011
- hole_height: z56.number(),
1016
+ var pcb_plated_hole_oval = z57.object({
1017
+ type: z57.literal("pcb_plated_hole"),
1018
+ shape: z57.enum(["oval", "pill"]),
1019
+ pcb_group_id: z57.string().optional(),
1020
+ subcircuit_id: z57.string().optional(),
1021
+ outer_width: z57.number(),
1022
+ outer_height: z57.number(),
1023
+ hole_width: z57.number(),
1024
+ hole_height: z57.number(),
1012
1025
  x: distance,
1013
1026
  y: distance,
1014
- layers: z56.array(layer_ref),
1015
- port_hints: z56.array(z56.string()).optional(),
1016
- pcb_component_id: z56.string().optional(),
1017
- pcb_port_id: z56.string().optional(),
1027
+ layers: z57.array(layer_ref),
1028
+ port_hints: z57.array(z57.string()).optional(),
1029
+ pcb_component_id: z57.string().optional(),
1030
+ pcb_port_id: z57.string().optional(),
1018
1031
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole")
1019
1032
  });
1020
- var pcb_circular_hole_with_rect_pad = z56.object({
1021
- type: z56.literal("pcb_plated_hole"),
1022
- shape: z56.literal("circular_hole_with_rect_pad"),
1023
- pcb_group_id: z56.string().optional(),
1024
- subcircuit_id: z56.string().optional(),
1025
- hole_shape: z56.literal("circle"),
1026
- pad_shape: z56.literal("rect"),
1027
- hole_diameter: z56.number(),
1028
- rect_pad_width: z56.number(),
1029
- rect_pad_height: z56.number(),
1033
+ var pcb_circular_hole_with_rect_pad = z57.object({
1034
+ type: z57.literal("pcb_plated_hole"),
1035
+ shape: z57.literal("circular_hole_with_rect_pad"),
1036
+ pcb_group_id: z57.string().optional(),
1037
+ subcircuit_id: z57.string().optional(),
1038
+ hole_shape: z57.literal("circle"),
1039
+ pad_shape: z57.literal("rect"),
1040
+ hole_diameter: z57.number(),
1041
+ rect_pad_width: z57.number(),
1042
+ rect_pad_height: z57.number(),
1030
1043
  x: distance,
1031
1044
  y: distance,
1032
- layers: z56.array(layer_ref),
1033
- port_hints: z56.array(z56.string()).optional(),
1034
- pcb_component_id: z56.string().optional(),
1035
- pcb_port_id: z56.string().optional(),
1045
+ layers: z57.array(layer_ref),
1046
+ port_hints: z57.array(z57.string()).optional(),
1047
+ pcb_component_id: z57.string().optional(),
1048
+ pcb_port_id: z57.string().optional(),
1036
1049
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole")
1037
1050
  });
1038
- var pcb_pill_hole_with_rect_pad = z56.object({
1039
- type: z56.literal("pcb_plated_hole"),
1040
- shape: z56.literal("pill_hole_with_rect_pad"),
1041
- pcb_group_id: z56.string().optional(),
1042
- subcircuit_id: z56.string().optional(),
1043
- hole_shape: z56.literal("pill"),
1044
- pad_shape: z56.literal("rect"),
1045
- hole_width: z56.number(),
1046
- hole_height: z56.number(),
1047
- rect_pad_width: z56.number(),
1048
- rect_pad_height: z56.number(),
1051
+ var pcb_pill_hole_with_rect_pad = z57.object({
1052
+ type: z57.literal("pcb_plated_hole"),
1053
+ shape: z57.literal("pill_hole_with_rect_pad"),
1054
+ pcb_group_id: z57.string().optional(),
1055
+ subcircuit_id: z57.string().optional(),
1056
+ hole_shape: z57.literal("pill"),
1057
+ pad_shape: z57.literal("rect"),
1058
+ hole_width: z57.number(),
1059
+ hole_height: z57.number(),
1060
+ rect_pad_width: z57.number(),
1061
+ rect_pad_height: z57.number(),
1049
1062
  x: distance,
1050
1063
  y: distance,
1051
- layers: z56.array(layer_ref),
1052
- port_hints: z56.array(z56.string()).optional(),
1053
- pcb_component_id: z56.string().optional(),
1054
- pcb_port_id: z56.string().optional(),
1064
+ layers: z57.array(layer_ref),
1065
+ port_hints: z57.array(z57.string()).optional(),
1066
+ pcb_component_id: z57.string().optional(),
1067
+ pcb_port_id: z57.string().optional(),
1055
1068
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole")
1056
1069
  });
1057
- var pcb_plated_hole = z56.union([
1070
+ var pcb_plated_hole = z57.union([
1058
1071
  pcb_plated_hole_circle,
1059
1072
  pcb_plated_hole_oval,
1060
1073
  pcb_circular_hole_with_rect_pad,
@@ -1068,168 +1081,182 @@ expectTypesMatch(true);
1068
1081
  expectTypesMatch(true);
1069
1082
 
1070
1083
  // src/pcb/pcb_port.ts
1071
- import { z as z57 } from "zod";
1072
- var pcb_port = z57.object({
1073
- type: z57.literal("pcb_port"),
1084
+ import { z as z58 } from "zod";
1085
+ var pcb_port = z58.object({
1086
+ type: z58.literal("pcb_port"),
1074
1087
  pcb_port_id: getZodPrefixedIdWithDefault("pcb_port"),
1075
- pcb_group_id: z57.string().optional(),
1076
- subcircuit_id: z57.string().optional(),
1077
- source_port_id: z57.string(),
1078
- pcb_component_id: z57.string(),
1088
+ pcb_group_id: z58.string().optional(),
1089
+ subcircuit_id: z58.string().optional(),
1090
+ source_port_id: z58.string(),
1091
+ pcb_component_id: z58.string(),
1079
1092
  x: distance,
1080
1093
  y: distance,
1081
- layers: z57.array(layer_ref)
1094
+ layers: z58.array(layer_ref)
1082
1095
  }).describe("Defines a port on the PCB");
1083
1096
  expectTypesMatch(true);
1084
1097
 
1085
1098
  // src/pcb/pcb_smtpad.ts
1086
- import { z as z58 } from "zod";
1087
- var pcb_smtpad_circle = z58.object({
1088
- type: z58.literal("pcb_smtpad"),
1089
- shape: z58.literal("circle"),
1099
+ import { z as z59 } from "zod";
1100
+ var pcb_smtpad_circle = z59.object({
1101
+ type: z59.literal("pcb_smtpad"),
1102
+ shape: z59.literal("circle"),
1090
1103
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
1091
- pcb_group_id: z58.string().optional(),
1092
- subcircuit_id: z58.string().optional(),
1104
+ pcb_group_id: z59.string().optional(),
1105
+ subcircuit_id: z59.string().optional(),
1093
1106
  x: distance,
1094
1107
  y: distance,
1095
- radius: z58.number(),
1108
+ radius: z59.number(),
1096
1109
  layer: layer_ref,
1097
- port_hints: z58.array(z58.string()).optional(),
1098
- pcb_component_id: z58.string().optional(),
1099
- pcb_port_id: z58.string().optional()
1110
+ port_hints: z59.array(z59.string()).optional(),
1111
+ pcb_component_id: z59.string().optional(),
1112
+ pcb_port_id: z59.string().optional()
1100
1113
  });
1101
- var pcb_smtpad_rect = z58.object({
1102
- type: z58.literal("pcb_smtpad"),
1103
- shape: z58.literal("rect"),
1114
+ var pcb_smtpad_rect = z59.object({
1115
+ type: z59.literal("pcb_smtpad"),
1116
+ shape: z59.literal("rect"),
1104
1117
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
1105
- pcb_group_id: z58.string().optional(),
1106
- subcircuit_id: z58.string().optional(),
1118
+ pcb_group_id: z59.string().optional(),
1119
+ subcircuit_id: z59.string().optional(),
1107
1120
  x: distance,
1108
1121
  y: distance,
1109
- width: z58.number(),
1110
- height: z58.number(),
1122
+ width: z59.number(),
1123
+ height: z59.number(),
1111
1124
  layer: layer_ref,
1112
- port_hints: z58.array(z58.string()).optional(),
1113
- pcb_component_id: z58.string().optional(),
1114
- pcb_port_id: z58.string().optional()
1125
+ port_hints: z59.array(z59.string()).optional(),
1126
+ pcb_component_id: z59.string().optional(),
1127
+ pcb_port_id: z59.string().optional()
1115
1128
  });
1116
- var pcb_smtpad_rotated_rect = z58.object({
1117
- type: z58.literal("pcb_smtpad"),
1118
- shape: z58.literal("rotated_rect"),
1129
+ var pcb_smtpad_rotated_rect = z59.object({
1130
+ type: z59.literal("pcb_smtpad"),
1131
+ shape: z59.literal("rotated_rect"),
1119
1132
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
1120
- pcb_group_id: z58.string().optional(),
1121
- subcircuit_id: z58.string().optional(),
1133
+ pcb_group_id: z59.string().optional(),
1134
+ subcircuit_id: z59.string().optional(),
1122
1135
  x: distance,
1123
1136
  y: distance,
1124
- width: z58.number(),
1125
- height: z58.number(),
1137
+ width: z59.number(),
1138
+ height: z59.number(),
1126
1139
  ccw_rotation: rotation,
1127
1140
  layer: layer_ref,
1128
- port_hints: z58.array(z58.string()).optional(),
1129
- pcb_component_id: z58.string().optional(),
1130
- pcb_port_id: z58.string().optional()
1141
+ port_hints: z59.array(z59.string()).optional(),
1142
+ pcb_component_id: z59.string().optional(),
1143
+ pcb_port_id: z59.string().optional()
1131
1144
  });
1132
- var pcb_smtpad_pill = z58.object({
1133
- type: z58.literal("pcb_smtpad"),
1134
- shape: z58.literal("pill"),
1145
+ var pcb_smtpad_pill = z59.object({
1146
+ type: z59.literal("pcb_smtpad"),
1147
+ shape: z59.literal("pill"),
1135
1148
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
1136
- pcb_group_id: z58.string().optional(),
1137
- subcircuit_id: z58.string().optional(),
1149
+ pcb_group_id: z59.string().optional(),
1150
+ subcircuit_id: z59.string().optional(),
1138
1151
  x: distance,
1139
1152
  y: distance,
1140
- width: z58.number(),
1141
- height: z58.number(),
1142
- radius: z58.number(),
1153
+ width: z59.number(),
1154
+ height: z59.number(),
1155
+ radius: z59.number(),
1143
1156
  layer: layer_ref,
1144
- port_hints: z58.array(z58.string()).optional(),
1145
- pcb_component_id: z58.string().optional(),
1146
- pcb_port_id: z58.string().optional()
1157
+ port_hints: z59.array(z59.string()).optional(),
1158
+ pcb_component_id: z59.string().optional(),
1159
+ pcb_port_id: z59.string().optional()
1160
+ });
1161
+ var pcb_smtpad_polygon = z59.object({
1162
+ type: z59.literal("pcb_smtpad"),
1163
+ shape: z59.literal("polygon"),
1164
+ pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
1165
+ pcb_group_id: z59.string().optional(),
1166
+ subcircuit_id: z59.string().optional(),
1167
+ points: z59.array(point),
1168
+ layer: layer_ref,
1169
+ port_hints: z59.array(z59.string()).optional(),
1170
+ pcb_component_id: z59.string().optional(),
1171
+ pcb_port_id: z59.string().optional()
1147
1172
  });
1148
- var pcb_smtpad = z58.union([
1173
+ var pcb_smtpad = z59.union([
1149
1174
  pcb_smtpad_circle,
1150
1175
  pcb_smtpad_rect,
1151
1176
  pcb_smtpad_rotated_rect,
1152
- pcb_smtpad_pill
1177
+ pcb_smtpad_pill,
1178
+ pcb_smtpad_polygon
1153
1179
  ]).describe("Defines an SMT pad on the PCB");
1154
1180
  expectTypesMatch(true);
1155
1181
  expectTypesMatch(true);
1156
1182
  expectTypesMatch(true);
1157
1183
  expectTypesMatch(true);
1184
+ expectTypesMatch(true);
1158
1185
 
1159
1186
  // src/pcb/pcb_solder_paste.ts
1160
- import { z as z59 } from "zod";
1161
- var pcb_solder_paste_circle = z59.object({
1162
- type: z59.literal("pcb_solder_paste"),
1163
- shape: z59.literal("circle"),
1187
+ import { z as z60 } from "zod";
1188
+ var pcb_solder_paste_circle = z60.object({
1189
+ type: z60.literal("pcb_solder_paste"),
1190
+ shape: z60.literal("circle"),
1164
1191
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
1165
- pcb_group_id: z59.string().optional(),
1166
- subcircuit_id: z59.string().optional(),
1192
+ pcb_group_id: z60.string().optional(),
1193
+ subcircuit_id: z60.string().optional(),
1167
1194
  x: distance,
1168
1195
  y: distance,
1169
- radius: z59.number(),
1196
+ radius: z60.number(),
1170
1197
  layer: layer_ref,
1171
- pcb_component_id: z59.string().optional(),
1172
- pcb_smtpad_id: z59.string().optional()
1198
+ pcb_component_id: z60.string().optional(),
1199
+ pcb_smtpad_id: z60.string().optional()
1173
1200
  });
1174
- var pcb_solder_paste_rect = z59.object({
1175
- type: z59.literal("pcb_solder_paste"),
1176
- shape: z59.literal("rect"),
1201
+ var pcb_solder_paste_rect = z60.object({
1202
+ type: z60.literal("pcb_solder_paste"),
1203
+ shape: z60.literal("rect"),
1177
1204
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
1178
- pcb_group_id: z59.string().optional(),
1179
- subcircuit_id: z59.string().optional(),
1205
+ pcb_group_id: z60.string().optional(),
1206
+ subcircuit_id: z60.string().optional(),
1180
1207
  x: distance,
1181
1208
  y: distance,
1182
- width: z59.number(),
1183
- height: z59.number(),
1209
+ width: z60.number(),
1210
+ height: z60.number(),
1184
1211
  layer: layer_ref,
1185
- pcb_component_id: z59.string().optional(),
1186
- pcb_smtpad_id: z59.string().optional()
1212
+ pcb_component_id: z60.string().optional(),
1213
+ pcb_smtpad_id: z60.string().optional()
1187
1214
  });
1188
- var pcb_solder_paste_pill = z59.object({
1189
- type: z59.literal("pcb_solder_paste"),
1190
- shape: z59.literal("pill"),
1215
+ var pcb_solder_paste_pill = z60.object({
1216
+ type: z60.literal("pcb_solder_paste"),
1217
+ shape: z60.literal("pill"),
1191
1218
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
1192
- pcb_group_id: z59.string().optional(),
1193
- subcircuit_id: z59.string().optional(),
1219
+ pcb_group_id: z60.string().optional(),
1220
+ subcircuit_id: z60.string().optional(),
1194
1221
  x: distance,
1195
1222
  y: distance,
1196
- width: z59.number(),
1197
- height: z59.number(),
1198
- radius: z59.number(),
1223
+ width: z60.number(),
1224
+ height: z60.number(),
1225
+ radius: z60.number(),
1199
1226
  layer: layer_ref,
1200
- pcb_component_id: z59.string().optional(),
1201
- pcb_smtpad_id: z59.string().optional()
1227
+ pcb_component_id: z60.string().optional(),
1228
+ pcb_smtpad_id: z60.string().optional()
1202
1229
  });
1203
- var pcb_solder_paste_rotated_rect = z59.object({
1204
- type: z59.literal("pcb_solder_paste"),
1205
- shape: z59.literal("rotated_rect"),
1230
+ var pcb_solder_paste_rotated_rect = z60.object({
1231
+ type: z60.literal("pcb_solder_paste"),
1232
+ shape: z60.literal("rotated_rect"),
1206
1233
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
1207
- pcb_group_id: z59.string().optional(),
1208
- subcircuit_id: z59.string().optional(),
1234
+ pcb_group_id: z60.string().optional(),
1235
+ subcircuit_id: z60.string().optional(),
1209
1236
  x: distance,
1210
1237
  y: distance,
1211
- width: z59.number(),
1212
- height: z59.number(),
1238
+ width: z60.number(),
1239
+ height: z60.number(),
1213
1240
  ccw_rotation: distance,
1214
1241
  layer: layer_ref,
1215
- pcb_component_id: z59.string().optional(),
1216
- pcb_smtpad_id: z59.string().optional()
1242
+ pcb_component_id: z60.string().optional(),
1243
+ pcb_smtpad_id: z60.string().optional()
1217
1244
  });
1218
- var pcb_solder_paste_oval = z59.object({
1219
- type: z59.literal("pcb_solder_paste"),
1220
- shape: z59.literal("oval"),
1245
+ var pcb_solder_paste_oval = z60.object({
1246
+ type: z60.literal("pcb_solder_paste"),
1247
+ shape: z60.literal("oval"),
1221
1248
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
1222
- pcb_group_id: z59.string().optional(),
1223
- subcircuit_id: z59.string().optional(),
1249
+ pcb_group_id: z60.string().optional(),
1250
+ subcircuit_id: z60.string().optional(),
1224
1251
  x: distance,
1225
1252
  y: distance,
1226
- width: z59.number(),
1227
- height: z59.number(),
1253
+ width: z60.number(),
1254
+ height: z60.number(),
1228
1255
  layer: layer_ref,
1229
- pcb_component_id: z59.string().optional(),
1230
- pcb_smtpad_id: z59.string().optional()
1256
+ pcb_component_id: z60.string().optional(),
1257
+ pcb_smtpad_id: z60.string().optional()
1231
1258
  });
1232
- var pcb_solder_paste = z59.union([
1259
+ var pcb_solder_paste = z60.union([
1233
1260
  pcb_solder_paste_circle,
1234
1261
  pcb_solder_paste_rect,
1235
1262
  pcb_solder_paste_pill,
@@ -1245,95 +1272,95 @@ expectTypesMatch(
1245
1272
  expectTypesMatch(true);
1246
1273
 
1247
1274
  // src/pcb/pcb_text.ts
1248
- import { z as z60 } from "zod";
1249
- var pcb_text = z60.object({
1250
- type: z60.literal("pcb_text"),
1275
+ import { z as z61 } from "zod";
1276
+ var pcb_text = z61.object({
1277
+ type: z61.literal("pcb_text"),
1251
1278
  pcb_text_id: getZodPrefixedIdWithDefault("pcb_text"),
1252
- pcb_group_id: z60.string().optional(),
1253
- subcircuit_id: z60.string().optional(),
1254
- text: z60.string(),
1279
+ pcb_group_id: z61.string().optional(),
1280
+ subcircuit_id: z61.string().optional(),
1281
+ text: z61.string(),
1255
1282
  center: point,
1256
1283
  layer: layer_ref,
1257
1284
  width: length,
1258
1285
  height: length,
1259
- lines: z60.number(),
1286
+ lines: z61.number(),
1260
1287
  // @ts-ignore
1261
- align: z60.enum(["bottom-left"])
1288
+ align: z61.enum(["bottom-left"])
1262
1289
  }).describe("Defines text on the PCB");
1263
1290
  expectTypesMatch(true);
1264
1291
 
1265
1292
  // src/pcb/pcb_trace.ts
1266
- import { z as z61 } from "zod";
1267
- var pcb_trace_route_point_wire = z61.object({
1268
- route_type: z61.literal("wire"),
1293
+ import { z as z62 } from "zod";
1294
+ var pcb_trace_route_point_wire = z62.object({
1295
+ route_type: z62.literal("wire"),
1269
1296
  x: distance,
1270
1297
  y: distance,
1271
1298
  width: distance,
1272
- start_pcb_port_id: z61.string().optional(),
1273
- end_pcb_port_id: z61.string().optional(),
1299
+ start_pcb_port_id: z62.string().optional(),
1300
+ end_pcb_port_id: z62.string().optional(),
1274
1301
  layer: layer_ref
1275
1302
  });
1276
- var pcb_trace_route_point_via = z61.object({
1277
- route_type: z61.literal("via"),
1303
+ var pcb_trace_route_point_via = z62.object({
1304
+ route_type: z62.literal("via"),
1278
1305
  x: distance,
1279
1306
  y: distance,
1280
1307
  hole_diameter: distance.optional(),
1281
1308
  outer_diameter: distance.optional(),
1282
- from_layer: z61.string(),
1283
- to_layer: z61.string()
1309
+ from_layer: z62.string(),
1310
+ to_layer: z62.string()
1284
1311
  });
1285
- var pcb_trace_route_point = z61.union([
1312
+ var pcb_trace_route_point = z62.union([
1286
1313
  pcb_trace_route_point_wire,
1287
1314
  pcb_trace_route_point_via
1288
1315
  ]);
1289
- var pcb_trace = z61.object({
1290
- type: z61.literal("pcb_trace"),
1291
- source_trace_id: z61.string().optional(),
1292
- pcb_component_id: z61.string().optional(),
1316
+ var pcb_trace = z62.object({
1317
+ type: z62.literal("pcb_trace"),
1318
+ source_trace_id: z62.string().optional(),
1319
+ pcb_component_id: z62.string().optional(),
1293
1320
  pcb_trace_id: getZodPrefixedIdWithDefault("pcb_trace"),
1294
- pcb_group_id: z61.string().optional(),
1295
- subcircuit_id: z61.string().optional(),
1296
- route_thickness_mode: z61.enum(["constant", "interpolated"]).default("constant").optional(),
1297
- route_order_index: z61.number().optional(),
1298
- should_round_corners: z61.boolean().optional(),
1299
- trace_length: z61.number().optional(),
1300
- route: z61.array(pcb_trace_route_point)
1321
+ pcb_group_id: z62.string().optional(),
1322
+ subcircuit_id: z62.string().optional(),
1323
+ route_thickness_mode: z62.enum(["constant", "interpolated"]).default("constant").optional(),
1324
+ route_order_index: z62.number().optional(),
1325
+ should_round_corners: z62.boolean().optional(),
1326
+ trace_length: z62.number().optional(),
1327
+ route: z62.array(pcb_trace_route_point)
1301
1328
  }).describe("Defines a trace on the PCB");
1302
1329
  expectTypesMatch(true);
1303
1330
  expectTypesMatch(true);
1304
1331
 
1305
1332
  // src/pcb/pcb_trace_error.ts
1306
- import { z as z62 } from "zod";
1307
- var pcb_trace_error = z62.object({
1308
- type: z62.literal("pcb_trace_error"),
1333
+ import { z as z63 } from "zod";
1334
+ var pcb_trace_error = z63.object({
1335
+ type: z63.literal("pcb_trace_error"),
1309
1336
  pcb_trace_error_id: getZodPrefixedIdWithDefault("pcb_trace_error"),
1310
- error_type: z62.literal("pcb_trace_error"),
1311
- message: z62.string(),
1337
+ error_type: z63.literal("pcb_trace_error"),
1338
+ message: z63.string(),
1312
1339
  center: point.optional(),
1313
- pcb_trace_id: z62.string(),
1314
- source_trace_id: z62.string(),
1315
- pcb_component_ids: z62.array(z62.string()),
1316
- pcb_port_ids: z62.array(z62.string())
1340
+ pcb_trace_id: z63.string(),
1341
+ source_trace_id: z63.string(),
1342
+ pcb_component_ids: z63.array(z63.string()),
1343
+ pcb_port_ids: z63.array(z63.string())
1317
1344
  }).describe("Defines a trace error on the PCB");
1318
1345
  expectTypesMatch(true);
1319
1346
 
1320
1347
  // src/pcb/pcb_port_not_matched_error.ts
1321
- import { z as z63 } from "zod";
1322
- var pcb_port_not_matched_error = z63.object({
1323
- type: z63.literal("pcb_port_not_matched_error"),
1348
+ import { z as z64 } from "zod";
1349
+ var pcb_port_not_matched_error = z64.object({
1350
+ type: z64.literal("pcb_port_not_matched_error"),
1324
1351
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
1325
- message: z63.string(),
1326
- pcb_component_ids: z63.array(z63.string())
1352
+ message: z64.string(),
1353
+ pcb_component_ids: z64.array(z64.string())
1327
1354
  }).describe("Defines a trace error on the PCB where a port is not matched");
1328
1355
  expectTypesMatch(true);
1329
1356
 
1330
1357
  // src/pcb/pcb_via.ts
1331
- import { z as z64 } from "zod";
1332
- var pcb_via = z64.object({
1333
- type: z64.literal("pcb_via"),
1358
+ import { z as z65 } from "zod";
1359
+ var pcb_via = z65.object({
1360
+ type: z65.literal("pcb_via"),
1334
1361
  pcb_via_id: getZodPrefixedIdWithDefault("pcb_via"),
1335
- pcb_group_id: z64.string().optional(),
1336
- subcircuit_id: z64.string().optional(),
1362
+ pcb_group_id: z65.string().optional(),
1363
+ subcircuit_id: z65.string().optional(),
1337
1364
  x: distance,
1338
1365
  y: distance,
1339
1366
  outer_diameter: distance.default("0.6mm"),
@@ -1342,56 +1369,56 @@ var pcb_via = z64.object({
1342
1369
  from_layer: layer_ref.optional(),
1343
1370
  /** @deprecated */
1344
1371
  to_layer: layer_ref.optional(),
1345
- layers: z64.array(layer_ref),
1346
- pcb_trace_id: z64.string().optional()
1372
+ layers: z65.array(layer_ref),
1373
+ pcb_trace_id: z65.string().optional()
1347
1374
  }).describe("Defines a via on the PCB");
1348
1375
  expectTypesMatch(true);
1349
1376
 
1350
1377
  // src/pcb/pcb_board.ts
1351
- import { z as z65 } from "zod";
1352
- var pcb_board = z65.object({
1353
- type: z65.literal("pcb_board"),
1378
+ import { z as z66 } from "zod";
1379
+ var pcb_board = z66.object({
1380
+ type: z66.literal("pcb_board"),
1354
1381
  pcb_board_id: getZodPrefixedIdWithDefault("pcb_board"),
1355
- is_subcircuit: z65.boolean().optional(),
1356
- subcircuit_id: z65.string().optional(),
1382
+ is_subcircuit: z66.boolean().optional(),
1383
+ subcircuit_id: z66.string().optional(),
1357
1384
  width: length,
1358
1385
  height: length,
1359
1386
  center: point,
1360
1387
  thickness: length.optional().default(1.4),
1361
- num_layers: z65.number().optional().default(4),
1362
- outline: z65.array(point).optional(),
1363
- material: z65.enum(["fr4", "fr1"]).default("fr4")
1388
+ num_layers: z66.number().optional().default(4),
1389
+ outline: z66.array(point).optional(),
1390
+ material: z66.enum(["fr4", "fr1"]).default("fr4")
1364
1391
  }).describe("Defines the board outline of the PCB");
1365
1392
  expectTypesMatch(true);
1366
1393
 
1367
1394
  // src/pcb/pcb_placement_error.ts
1368
- import { z as z66 } from "zod";
1369
- var pcb_placement_error = z66.object({
1370
- type: z66.literal("pcb_placement_error"),
1395
+ import { z as z67 } from "zod";
1396
+ var pcb_placement_error = z67.object({
1397
+ type: z67.literal("pcb_placement_error"),
1371
1398
  pcb_placement_error_id: getZodPrefixedIdWithDefault("pcb_placement_error"),
1372
- message: z66.string()
1399
+ message: z67.string()
1373
1400
  }).describe("Defines a placement error on the PCB");
1374
1401
  expectTypesMatch(true);
1375
1402
 
1376
1403
  // src/pcb/pcb_trace_hint.ts
1377
- import { z as z67 } from "zod";
1378
- var pcb_trace_hint = z67.object({
1379
- type: z67.literal("pcb_trace_hint"),
1404
+ import { z as z68 } from "zod";
1405
+ var pcb_trace_hint = z68.object({
1406
+ type: z68.literal("pcb_trace_hint"),
1380
1407
  pcb_trace_hint_id: getZodPrefixedIdWithDefault("pcb_trace_hint"),
1381
- pcb_port_id: z67.string(),
1382
- pcb_component_id: z67.string(),
1383
- route: z67.array(route_hint_point)
1408
+ pcb_port_id: z68.string(),
1409
+ pcb_component_id: z68.string(),
1410
+ route: z68.array(route_hint_point)
1384
1411
  }).describe("A hint that can be used during generation of a PCB trace");
1385
1412
  expectTypesMatch(true);
1386
1413
 
1387
1414
  // src/pcb/pcb_silkscreen_line.ts
1388
- import { z as z68 } from "zod";
1389
- var pcb_silkscreen_line = z68.object({
1390
- type: z68.literal("pcb_silkscreen_line"),
1415
+ import { z as z69 } from "zod";
1416
+ var pcb_silkscreen_line = z69.object({
1417
+ type: z69.literal("pcb_silkscreen_line"),
1391
1418
  pcb_silkscreen_line_id: getZodPrefixedIdWithDefault("pcb_silkscreen_line"),
1392
- pcb_component_id: z68.string(),
1393
- pcb_group_id: z68.string().optional(),
1394
- subcircuit_id: z68.string().optional(),
1419
+ pcb_component_id: z69.string(),
1420
+ pcb_group_id: z69.string().optional(),
1421
+ subcircuit_id: z69.string().optional(),
1395
1422
  stroke_width: distance.default("0.1mm"),
1396
1423
  x1: distance,
1397
1424
  y1: distance,
@@ -1402,67 +1429,67 @@ var pcb_silkscreen_line = z68.object({
1402
1429
  expectTypesMatch(true);
1403
1430
 
1404
1431
  // src/pcb/pcb_silkscreen_path.ts
1405
- import { z as z69 } from "zod";
1406
- var pcb_silkscreen_path = z69.object({
1407
- type: z69.literal("pcb_silkscreen_path"),
1432
+ import { z as z70 } from "zod";
1433
+ var pcb_silkscreen_path = z70.object({
1434
+ type: z70.literal("pcb_silkscreen_path"),
1408
1435
  pcb_silkscreen_path_id: getZodPrefixedIdWithDefault("pcb_silkscreen_path"),
1409
- pcb_component_id: z69.string(),
1410
- pcb_group_id: z69.string().optional(),
1411
- subcircuit_id: z69.string().optional(),
1436
+ pcb_component_id: z70.string(),
1437
+ pcb_group_id: z70.string().optional(),
1438
+ subcircuit_id: z70.string().optional(),
1412
1439
  layer: visible_layer,
1413
- route: z69.array(point),
1440
+ route: z70.array(point),
1414
1441
  stroke_width: length
1415
1442
  }).describe("Defines a silkscreen path on the PCB");
1416
1443
  expectTypesMatch(true);
1417
1444
 
1418
1445
  // src/pcb/pcb_silkscreen_text.ts
1419
- import { z as z70 } from "zod";
1420
- var pcb_silkscreen_text = z70.object({
1421
- type: z70.literal("pcb_silkscreen_text"),
1446
+ import { z as z71 } from "zod";
1447
+ var pcb_silkscreen_text = z71.object({
1448
+ type: z71.literal("pcb_silkscreen_text"),
1422
1449
  pcb_silkscreen_text_id: getZodPrefixedIdWithDefault("pcb_silkscreen_text"),
1423
- pcb_group_id: z70.string().optional(),
1424
- subcircuit_id: z70.string().optional(),
1425
- font: z70.literal("tscircuit2024").default("tscircuit2024"),
1450
+ pcb_group_id: z71.string().optional(),
1451
+ subcircuit_id: z71.string().optional(),
1452
+ font: z71.literal("tscircuit2024").default("tscircuit2024"),
1426
1453
  font_size: distance.default("0.2mm"),
1427
- pcb_component_id: z70.string(),
1428
- text: z70.string(),
1429
- ccw_rotation: z70.number().optional(),
1454
+ pcb_component_id: z71.string(),
1455
+ text: z71.string(),
1456
+ ccw_rotation: z71.number().optional(),
1430
1457
  layer: layer_ref,
1431
- is_mirrored: z70.boolean().default(false).optional(),
1458
+ is_mirrored: z71.boolean().default(false).optional(),
1432
1459
  anchor_position: point.default({ x: 0, y: 0 }),
1433
1460
  anchor_alignment: ninePointAnchor.default("center")
1434
1461
  }).describe("Defines silkscreen text on the PCB");
1435
1462
  expectTypesMatch(true);
1436
1463
 
1437
1464
  // src/pcb/pcb_silkscreen_rect.ts
1438
- import { z as z71 } from "zod";
1439
- var pcb_silkscreen_rect = z71.object({
1440
- type: z71.literal("pcb_silkscreen_rect"),
1465
+ import { z as z72 } from "zod";
1466
+ var pcb_silkscreen_rect = z72.object({
1467
+ type: z72.literal("pcb_silkscreen_rect"),
1441
1468
  pcb_silkscreen_rect_id: getZodPrefixedIdWithDefault("pcb_silkscreen_rect"),
1442
- pcb_component_id: z71.string(),
1443
- pcb_group_id: z71.string().optional(),
1444
- subcircuit_id: z71.string().optional(),
1469
+ pcb_component_id: z72.string(),
1470
+ pcb_group_id: z72.string().optional(),
1471
+ subcircuit_id: z72.string().optional(),
1445
1472
  center: point,
1446
1473
  width: length,
1447
1474
  height: length,
1448
1475
  layer: layer_ref,
1449
1476
  stroke_width: length.default("1mm"),
1450
- is_filled: z71.boolean().default(true).optional(),
1451
- has_stroke: z71.boolean().optional(),
1452
- is_stroke_dashed: z71.boolean().optional()
1477
+ is_filled: z72.boolean().default(true).optional(),
1478
+ has_stroke: z72.boolean().optional(),
1479
+ is_stroke_dashed: z72.boolean().optional()
1453
1480
  }).describe("Defines a silkscreen rect on the PCB");
1454
1481
  expectTypesMatch(true);
1455
1482
 
1456
1483
  // src/pcb/pcb_silkscreen_circle.ts
1457
- import { z as z72 } from "zod";
1458
- var pcb_silkscreen_circle = z72.object({
1459
- type: z72.literal("pcb_silkscreen_circle"),
1484
+ import { z as z73 } from "zod";
1485
+ var pcb_silkscreen_circle = z73.object({
1486
+ type: z73.literal("pcb_silkscreen_circle"),
1460
1487
  pcb_silkscreen_circle_id: getZodPrefixedIdWithDefault(
1461
1488
  "pcb_silkscreen_circle"
1462
1489
  ),
1463
- pcb_component_id: z72.string(),
1464
- pcb_group_id: z72.string().optional(),
1465
- subcircuit_id: z72.string().optional(),
1490
+ pcb_component_id: z73.string(),
1491
+ pcb_group_id: z73.string().optional(),
1492
+ subcircuit_id: z73.string().optional(),
1466
1493
  center: point,
1467
1494
  radius: length,
1468
1495
  layer: visible_layer,
@@ -1471,13 +1498,13 @@ var pcb_silkscreen_circle = z72.object({
1471
1498
  expectTypesMatch(true);
1472
1499
 
1473
1500
  // src/pcb/pcb_silkscreen_oval.ts
1474
- import { z as z73 } from "zod";
1475
- var pcb_silkscreen_oval = z73.object({
1476
- type: z73.literal("pcb_silkscreen_oval"),
1501
+ import { z as z74 } from "zod";
1502
+ var pcb_silkscreen_oval = z74.object({
1503
+ type: z74.literal("pcb_silkscreen_oval"),
1477
1504
  pcb_silkscreen_oval_id: getZodPrefixedIdWithDefault("pcb_silkscreen_oval"),
1478
- pcb_component_id: z73.string(),
1479
- pcb_group_id: z73.string().optional(),
1480
- subcircuit_id: z73.string().optional(),
1505
+ pcb_component_id: z74.string(),
1506
+ pcb_group_id: z74.string().optional(),
1507
+ subcircuit_id: z74.string().optional(),
1481
1508
  center: point,
1482
1509
  radius_x: distance,
1483
1510
  radius_y: distance,
@@ -1486,86 +1513,86 @@ var pcb_silkscreen_oval = z73.object({
1486
1513
  expectTypesMatch(true);
1487
1514
 
1488
1515
  // src/pcb/pcb_fabrication_note_text.ts
1489
- import { z as z74 } from "zod";
1490
- var pcb_fabrication_note_text = z74.object({
1491
- type: z74.literal("pcb_fabrication_note_text"),
1516
+ import { z as z75 } from "zod";
1517
+ var pcb_fabrication_note_text = z75.object({
1518
+ type: z75.literal("pcb_fabrication_note_text"),
1492
1519
  pcb_fabrication_note_text_id: getZodPrefixedIdWithDefault(
1493
1520
  "pcb_fabrication_note_text"
1494
1521
  ),
1495
- subcircuit_id: z74.string().optional(),
1496
- pcb_group_id: z74.string().optional(),
1497
- font: z74.literal("tscircuit2024").default("tscircuit2024"),
1522
+ subcircuit_id: z75.string().optional(),
1523
+ pcb_group_id: z75.string().optional(),
1524
+ font: z75.literal("tscircuit2024").default("tscircuit2024"),
1498
1525
  font_size: distance.default("1mm"),
1499
- pcb_component_id: z74.string(),
1500
- text: z74.string(),
1526
+ pcb_component_id: z75.string(),
1527
+ text: z75.string(),
1501
1528
  layer: visible_layer,
1502
1529
  anchor_position: point.default({ x: 0, y: 0 }),
1503
- anchor_alignment: z74.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
1504
- color: z74.string().optional()
1530
+ anchor_alignment: z75.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
1531
+ color: z75.string().optional()
1505
1532
  }).describe(
1506
1533
  "Defines a fabrication note in text on the PCB, useful for leaving notes for assemblers or fabricators"
1507
1534
  );
1508
1535
  expectTypesMatch(true);
1509
1536
 
1510
1537
  // src/pcb/pcb_fabrication_note_path.ts
1511
- import { z as z75 } from "zod";
1512
- var pcb_fabrication_note_path = z75.object({
1513
- type: z75.literal("pcb_fabrication_note_path"),
1538
+ import { z as z76 } from "zod";
1539
+ var pcb_fabrication_note_path = z76.object({
1540
+ type: z76.literal("pcb_fabrication_note_path"),
1514
1541
  pcb_fabrication_note_path_id: getZodPrefixedIdWithDefault(
1515
1542
  "pcb_fabrication_note_path"
1516
1543
  ),
1517
- pcb_component_id: z75.string(),
1518
- subcircuit_id: z75.string().optional(),
1544
+ pcb_component_id: z76.string(),
1545
+ subcircuit_id: z76.string().optional(),
1519
1546
  layer: layer_ref,
1520
- route: z75.array(point),
1547
+ route: z76.array(point),
1521
1548
  stroke_width: length,
1522
- color: z75.string().optional()
1549
+ color: z76.string().optional()
1523
1550
  }).describe(
1524
1551
  "Defines a fabrication path on the PCB for fabricators or assemblers"
1525
1552
  );
1526
1553
  expectTypesMatch(true);
1527
1554
 
1528
1555
  // src/pcb/pcb_keepout.ts
1529
- import { z as z76 } from "zod";
1530
- var pcb_keepout = z76.object({
1531
- type: z76.literal("pcb_keepout"),
1532
- shape: z76.literal("rect"),
1533
- pcb_group_id: z76.string().optional(),
1534
- subcircuit_id: z76.string().optional(),
1556
+ import { z as z77 } from "zod";
1557
+ var pcb_keepout = z77.object({
1558
+ type: z77.literal("pcb_keepout"),
1559
+ shape: z77.literal("rect"),
1560
+ pcb_group_id: z77.string().optional(),
1561
+ subcircuit_id: z77.string().optional(),
1535
1562
  center: point,
1536
1563
  width: distance,
1537
1564
  height: distance,
1538
- pcb_keepout_id: z76.string(),
1539
- layers: z76.array(z76.string()),
1565
+ pcb_keepout_id: z77.string(),
1566
+ layers: z77.array(z77.string()),
1540
1567
  // Specify layers where the keepout applies
1541
- description: z76.string().optional()
1568
+ description: z77.string().optional()
1542
1569
  // Optional description of the keepout
1543
1570
  }).or(
1544
- z76.object({
1545
- type: z76.literal("pcb_keepout"),
1546
- shape: z76.literal("circle"),
1547
- pcb_group_id: z76.string().optional(),
1548
- subcircuit_id: z76.string().optional(),
1571
+ z77.object({
1572
+ type: z77.literal("pcb_keepout"),
1573
+ shape: z77.literal("circle"),
1574
+ pcb_group_id: z77.string().optional(),
1575
+ subcircuit_id: z77.string().optional(),
1549
1576
  center: point,
1550
1577
  radius: distance,
1551
- pcb_keepout_id: z76.string(),
1552
- layers: z76.array(z76.string()),
1578
+ pcb_keepout_id: z77.string(),
1579
+ layers: z77.array(z77.string()),
1553
1580
  // Specify layers where the keepout applies
1554
- description: z76.string().optional()
1581
+ description: z77.string().optional()
1555
1582
  // Optional description of the keepout
1556
1583
  })
1557
1584
  );
1558
1585
 
1559
1586
  // src/pcb/pcb_cutout.ts
1560
- import { z as z77 } from "zod";
1561
- var pcb_cutout_base = z77.object({
1562
- type: z77.literal("pcb_cutout"),
1587
+ import { z as z78 } from "zod";
1588
+ var pcb_cutout_base = z78.object({
1589
+ type: z78.literal("pcb_cutout"),
1563
1590
  pcb_cutout_id: getZodPrefixedIdWithDefault("pcb_cutout"),
1564
- pcb_group_id: z77.string().optional(),
1565
- subcircuit_id: z77.string().optional()
1591
+ pcb_group_id: z78.string().optional(),
1592
+ subcircuit_id: z78.string().optional()
1566
1593
  });
1567
1594
  var pcb_cutout_rect = pcb_cutout_base.extend({
1568
- shape: z77.literal("rect"),
1595
+ shape: z78.literal("rect"),
1569
1596
  center: point,
1570
1597
  width: length,
1571
1598
  height: length,
@@ -1573,17 +1600,17 @@ var pcb_cutout_rect = pcb_cutout_base.extend({
1573
1600
  });
1574
1601
  expectTypesMatch(true);
1575
1602
  var pcb_cutout_circle = pcb_cutout_base.extend({
1576
- shape: z77.literal("circle"),
1603
+ shape: z78.literal("circle"),
1577
1604
  center: point,
1578
1605
  radius: length
1579
1606
  });
1580
1607
  expectTypesMatch(true);
1581
1608
  var pcb_cutout_polygon = pcb_cutout_base.extend({
1582
- shape: z77.literal("polygon"),
1583
- points: z77.array(point)
1609
+ shape: z78.literal("polygon"),
1610
+ points: z78.array(point)
1584
1611
  });
1585
1612
  expectTypesMatch(true);
1586
- var pcb_cutout = z77.discriminatedUnion("shape", [
1613
+ var pcb_cutout = z78.discriminatedUnion("shape", [
1587
1614
  pcb_cutout_rect,
1588
1615
  pcb_cutout_circle,
1589
1616
  pcb_cutout_polygon
@@ -1591,87 +1618,87 @@ var pcb_cutout = z77.discriminatedUnion("shape", [
1591
1618
  expectTypesMatch(true);
1592
1619
 
1593
1620
  // src/pcb/pcb_missing_footprint_error.ts
1594
- import { z as z78 } from "zod";
1595
- var pcb_missing_footprint_error = z78.object({
1596
- type: z78.literal("pcb_missing_footprint_error"),
1621
+ import { z as z79 } from "zod";
1622
+ var pcb_missing_footprint_error = z79.object({
1623
+ type: z79.literal("pcb_missing_footprint_error"),
1597
1624
  pcb_missing_footprint_error_id: getZodPrefixedIdWithDefault(
1598
1625
  "pcb_missing_footprint_error"
1599
1626
  ),
1600
- pcb_group_id: z78.string().optional(),
1601
- subcircuit_id: z78.string().optional(),
1602
- error_type: z78.literal("pcb_missing_footprint_error"),
1603
- source_component_id: z78.string(),
1604
- message: z78.string()
1627
+ pcb_group_id: z79.string().optional(),
1628
+ subcircuit_id: z79.string().optional(),
1629
+ error_type: z79.literal("pcb_missing_footprint_error"),
1630
+ source_component_id: z79.string(),
1631
+ message: z79.string()
1605
1632
  }).describe("Defines a missing footprint error on the PCB");
1606
1633
  expectTypesMatch(
1607
1634
  true
1608
1635
  );
1609
1636
 
1610
1637
  // src/pcb/pcb_group.ts
1611
- import { z as z79 } from "zod";
1612
- var pcb_group = z79.object({
1613
- type: z79.literal("pcb_group"),
1638
+ import { z as z80 } from "zod";
1639
+ var pcb_group = z80.object({
1640
+ type: z80.literal("pcb_group"),
1614
1641
  pcb_group_id: getZodPrefixedIdWithDefault("pcb_group"),
1615
- source_group_id: z79.string(),
1616
- is_subcircuit: z79.boolean().optional(),
1617
- subcircuit_id: z79.string().optional(),
1642
+ source_group_id: z80.string(),
1643
+ is_subcircuit: z80.boolean().optional(),
1644
+ subcircuit_id: z80.string().optional(),
1618
1645
  width: length,
1619
1646
  height: length,
1620
1647
  center: point,
1621
- pcb_component_ids: z79.array(z79.string()),
1622
- name: z79.string().optional(),
1623
- description: z79.string().optional()
1648
+ pcb_component_ids: z80.array(z80.string()),
1649
+ name: z80.string().optional(),
1650
+ description: z80.string().optional()
1624
1651
  }).describe("Defines a group of components on the PCB");
1625
1652
  expectTypesMatch(true);
1626
1653
 
1627
1654
  // src/pcb/pcb_autorouting_error.ts
1628
- import { z as z80 } from "zod";
1629
- var pcb_autorouting_error = z80.object({
1630
- type: z80.literal("pcb_autorouting_error"),
1655
+ import { z as z81 } from "zod";
1656
+ var pcb_autorouting_error = z81.object({
1657
+ type: z81.literal("pcb_autorouting_error"),
1631
1658
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_autorouting_error"),
1632
- message: z80.string()
1659
+ message: z81.string()
1633
1660
  }).describe("The autorouting has failed to route a portion of the board");
1634
1661
  expectTypesMatch(true);
1635
1662
 
1636
1663
  // src/pcb/pcb_manual_edit_conflict_warning.ts
1637
- import { z as z81 } from "zod";
1638
- var pcb_manual_edit_conflict_warning = z81.object({
1639
- type: z81.literal("pcb_manual_edit_conflict_warning"),
1664
+ import { z as z82 } from "zod";
1665
+ var pcb_manual_edit_conflict_warning = z82.object({
1666
+ type: z82.literal("pcb_manual_edit_conflict_warning"),
1640
1667
  pcb_manual_edit_conflict_warning_id: getZodPrefixedIdWithDefault(
1641
1668
  "pcb_manual_edit_conflict_warning"
1642
1669
  ),
1643
- message: z81.string(),
1644
- pcb_component_id: z81.string(),
1645
- pcb_group_id: z81.string().optional(),
1646
- subcircuit_id: z81.string().optional(),
1647
- source_component_id: z81.string()
1670
+ message: z82.string(),
1671
+ pcb_component_id: z82.string(),
1672
+ pcb_group_id: z82.string().optional(),
1673
+ subcircuit_id: z82.string().optional(),
1674
+ source_component_id: z82.string()
1648
1675
  }).describe(
1649
1676
  "Warning emitted when a component has both manual placement and explicit pcbX/pcbY coordinates"
1650
1677
  );
1651
1678
  expectTypesMatch(true);
1652
1679
 
1653
1680
  // src/cad/cad_component.ts
1654
- import { z as z82 } from "zod";
1655
- var cad_component = z82.object({
1656
- type: z82.literal("cad_component"),
1657
- cad_component_id: z82.string(),
1658
- pcb_component_id: z82.string(),
1659
- source_component_id: z82.string(),
1681
+ import { z as z83 } from "zod";
1682
+ var cad_component = z83.object({
1683
+ type: z83.literal("cad_component"),
1684
+ cad_component_id: z83.string(),
1685
+ pcb_component_id: z83.string(),
1686
+ source_component_id: z83.string(),
1660
1687
  position: point3,
1661
1688
  rotation: point3.optional(),
1662
1689
  size: point3.optional(),
1663
1690
  layer: layer_ref.optional(),
1664
1691
  // These are all ways to generate/load the 3d model
1665
- footprinter_string: z82.string().optional(),
1666
- model_obj_url: z82.string().optional(),
1667
- model_stl_url: z82.string().optional(),
1668
- model_3mf_url: z82.string().optional(),
1669
- model_jscad: z82.any().optional()
1692
+ footprinter_string: z83.string().optional(),
1693
+ model_obj_url: z83.string().optional(),
1694
+ model_stl_url: z83.string().optional(),
1695
+ model_3mf_url: z83.string().optional(),
1696
+ model_jscad: z83.any().optional()
1670
1697
  }).describe("Defines a component on the PCB");
1671
1698
 
1672
1699
  // src/any_circuit_element.ts
1673
- import { z as z83 } from "zod";
1674
- var any_circuit_element = z83.union([
1700
+ import { z as z84 } from "zod";
1701
+ var any_circuit_element = z84.union([
1675
1702
  source_trace,
1676
1703
  source_port,
1677
1704
  any_source_component,
@@ -1731,6 +1758,7 @@ var any_circuit_element = z83.union([
1731
1758
  schematic_trace,
1732
1759
  schematic_path,
1733
1760
  schematic_error,
1761
+ schematic_layout_error,
1734
1762
  schematic_net_label,
1735
1763
  schematic_debug_object,
1736
1764
  schematic_voltage_probe,
@@ -1815,6 +1843,7 @@ export {
1815
1843
  schematic_debug_rect,
1816
1844
  schematic_error,
1817
1845
  schematic_group,
1846
+ schematic_layout_error,
1818
1847
  schematic_line,
1819
1848
  schematic_manual_edit_conflict_warning,
1820
1849
  schematic_net_label,