circuit-json 0.0.293 → 0.0.295

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
@@ -664,7 +664,8 @@ var source_port = z36.object({
664
664
  port_hints: z36.array(z36.string()).optional(),
665
665
  name: z36.string(),
666
666
  source_port_id: z36.string(),
667
- source_component_id: z36.string(),
667
+ source_component_id: z36.string().optional(),
668
+ source_group_id: z36.string().optional(),
668
669
  subcircuit_id: z36.string().optional(),
669
670
  subcircuit_connectivity_map_key: z36.string().optional()
670
671
  });
@@ -1453,7 +1454,7 @@ var pcb_port = z71.object({
1453
1454
  pcb_group_id: z71.string().optional(),
1454
1455
  subcircuit_id: z71.string().optional(),
1455
1456
  source_port_id: z71.string(),
1456
- pcb_component_id: z71.string(),
1457
+ pcb_component_id: z71.string().optional(),
1457
1458
  x: distance,
1458
1459
  y: distance,
1459
1460
  layers: z71.array(layer_ref),
@@ -1933,35 +1934,66 @@ var pcb_silkscreen_text = z88.object({
1933
1934
  }).describe("Defines silkscreen text on the PCB");
1934
1935
  expectTypesMatch(true);
1935
1936
 
1936
- // src/pcb/pcb_silkscreen_rect.ts
1937
+ // src/pcb/pcb_copper_text.ts
1937
1938
  import { z as z89 } from "zod";
1938
- var pcb_silkscreen_rect = z89.object({
1939
- type: z89.literal("pcb_silkscreen_rect"),
1940
- pcb_silkscreen_rect_id: getZodPrefixedIdWithDefault("pcb_silkscreen_rect"),
1941
- pcb_component_id: z89.string(),
1939
+ var pcb_copper_text = z89.object({
1940
+ type: z89.literal("pcb_copper_text"),
1941
+ pcb_copper_text_id: getZodPrefixedIdWithDefault("pcb_copper_text"),
1942
1942
  pcb_group_id: z89.string().optional(),
1943
1943
  subcircuit_id: z89.string().optional(),
1944
+ font: z89.literal("tscircuit2024").default("tscircuit2024"),
1945
+ font_size: distance.default("0.2mm"),
1946
+ pcb_component_id: z89.string(),
1947
+ text: z89.string(),
1948
+ is_knockout: z89.boolean().default(false).optional(),
1949
+ knockout_padding: z89.object({
1950
+ left: length,
1951
+ top: length,
1952
+ bottom: length,
1953
+ right: length
1954
+ }).default({
1955
+ left: "0.2mm",
1956
+ top: "0.2mm",
1957
+ bottom: "0.2mm",
1958
+ right: "0.2mm"
1959
+ }).optional(),
1960
+ ccw_rotation: z89.number().optional(),
1961
+ layer: layer_ref,
1962
+ is_mirrored: z89.boolean().default(false).optional(),
1963
+ anchor_position: point.default({ x: 0, y: 0 }),
1964
+ anchor_alignment: ninePointAnchor.default("center")
1965
+ }).describe("Defines copper text on the PCB");
1966
+ expectTypesMatch(true);
1967
+
1968
+ // src/pcb/pcb_silkscreen_rect.ts
1969
+ import { z as z90 } from "zod";
1970
+ var pcb_silkscreen_rect = z90.object({
1971
+ type: z90.literal("pcb_silkscreen_rect"),
1972
+ pcb_silkscreen_rect_id: getZodPrefixedIdWithDefault("pcb_silkscreen_rect"),
1973
+ pcb_component_id: z90.string(),
1974
+ pcb_group_id: z90.string().optional(),
1975
+ subcircuit_id: z90.string().optional(),
1944
1976
  center: point,
1945
1977
  width: length,
1946
1978
  height: length,
1947
1979
  layer: layer_ref,
1948
1980
  stroke_width: length.default("1mm"),
1949
- is_filled: z89.boolean().default(true).optional(),
1950
- has_stroke: z89.boolean().optional(),
1951
- is_stroke_dashed: z89.boolean().optional()
1981
+ is_filled: z90.boolean().default(true).optional(),
1982
+ has_stroke: z90.boolean().optional(),
1983
+ is_stroke_dashed: z90.boolean().optional()
1952
1984
  }).describe("Defines a silkscreen rect on the PCB");
1953
1985
  expectTypesMatch(true);
1954
1986
 
1955
1987
  // src/pcb/pcb_silkscreen_circle.ts
1956
- import { z as z90 } from "zod";
1957
- var pcb_silkscreen_circle = z90.object({
1958
- type: z90.literal("pcb_silkscreen_circle"),
1988
+ import { z as z91 } from "zod";
1989
+ var pcb_silkscreen_circle = z91.object({
1990
+ type: z91.literal("pcb_silkscreen_circle"),
1959
1991
  pcb_silkscreen_circle_id: getZodPrefixedIdWithDefault(
1960
1992
  "pcb_silkscreen_circle"
1961
1993
  ),
1962
- pcb_component_id: z90.string(),
1963
- pcb_group_id: z90.string().optional(),
1964
- subcircuit_id: z90.string().optional(),
1994
+ pcb_component_id: z91.string(),
1995
+ pcb_group_id: z91.string().optional(),
1996
+ subcircuit_id: z91.string().optional(),
1965
1997
  center: point,
1966
1998
  radius: length,
1967
1999
  layer: visible_layer,
@@ -1970,13 +2002,13 @@ var pcb_silkscreen_circle = z90.object({
1970
2002
  expectTypesMatch(true);
1971
2003
 
1972
2004
  // src/pcb/pcb_silkscreen_oval.ts
1973
- import { z as z91 } from "zod";
1974
- var pcb_silkscreen_oval = z91.object({
1975
- type: z91.literal("pcb_silkscreen_oval"),
2005
+ import { z as z92 } from "zod";
2006
+ var pcb_silkscreen_oval = z92.object({
2007
+ type: z92.literal("pcb_silkscreen_oval"),
1976
2008
  pcb_silkscreen_oval_id: getZodPrefixedIdWithDefault("pcb_silkscreen_oval"),
1977
- pcb_component_id: z91.string(),
1978
- pcb_group_id: z91.string().optional(),
1979
- subcircuit_id: z91.string().optional(),
2009
+ pcb_component_id: z92.string(),
2010
+ pcb_group_id: z92.string().optional(),
2011
+ subcircuit_id: z92.string().optional(),
1980
2012
  center: point,
1981
2013
  radius_x: distance,
1982
2014
  radius_y: distance,
@@ -1985,253 +2017,253 @@ var pcb_silkscreen_oval = z91.object({
1985
2017
  expectTypesMatch(true);
1986
2018
 
1987
2019
  // src/pcb/pcb_fabrication_note_text.ts
1988
- import { z as z92 } from "zod";
1989
- var pcb_fabrication_note_text = z92.object({
1990
- type: z92.literal("pcb_fabrication_note_text"),
2020
+ import { z as z93 } from "zod";
2021
+ var pcb_fabrication_note_text = z93.object({
2022
+ type: z93.literal("pcb_fabrication_note_text"),
1991
2023
  pcb_fabrication_note_text_id: getZodPrefixedIdWithDefault(
1992
2024
  "pcb_fabrication_note_text"
1993
2025
  ),
1994
- subcircuit_id: z92.string().optional(),
1995
- pcb_group_id: z92.string().optional(),
1996
- font: z92.literal("tscircuit2024").default("tscircuit2024"),
2026
+ subcircuit_id: z93.string().optional(),
2027
+ pcb_group_id: z93.string().optional(),
2028
+ font: z93.literal("tscircuit2024").default("tscircuit2024"),
1997
2029
  font_size: distance.default("1mm"),
1998
- pcb_component_id: z92.string(),
1999
- text: z92.string(),
2030
+ pcb_component_id: z93.string(),
2031
+ text: z93.string(),
2000
2032
  layer: visible_layer,
2001
2033
  anchor_position: point.default({ x: 0, y: 0 }),
2002
- anchor_alignment: z92.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2003
- color: z92.string().optional()
2034
+ anchor_alignment: z93.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2035
+ color: z93.string().optional()
2004
2036
  }).describe(
2005
2037
  "Defines a fabrication note in text on the PCB, useful for leaving notes for assemblers or fabricators"
2006
2038
  );
2007
2039
  expectTypesMatch(true);
2008
2040
 
2009
2041
  // src/pcb/pcb_fabrication_note_path.ts
2010
- import { z as z93 } from "zod";
2011
- var pcb_fabrication_note_path = z93.object({
2012
- type: z93.literal("pcb_fabrication_note_path"),
2042
+ import { z as z94 } from "zod";
2043
+ var pcb_fabrication_note_path = z94.object({
2044
+ type: z94.literal("pcb_fabrication_note_path"),
2013
2045
  pcb_fabrication_note_path_id: getZodPrefixedIdWithDefault(
2014
2046
  "pcb_fabrication_note_path"
2015
2047
  ),
2016
- pcb_component_id: z93.string(),
2017
- subcircuit_id: z93.string().optional(),
2048
+ pcb_component_id: z94.string(),
2049
+ subcircuit_id: z94.string().optional(),
2018
2050
  layer: layer_ref,
2019
- route: z93.array(point),
2051
+ route: z94.array(point),
2020
2052
  stroke_width: length,
2021
- color: z93.string().optional()
2053
+ color: z94.string().optional()
2022
2054
  }).describe(
2023
2055
  "Defines a fabrication path on the PCB for fabricators or assemblers"
2024
2056
  );
2025
2057
  expectTypesMatch(true);
2026
2058
 
2027
2059
  // src/pcb/pcb_fabrication_note_rect.ts
2028
- import { z as z94 } from "zod";
2029
- var pcb_fabrication_note_rect = z94.object({
2030
- type: z94.literal("pcb_fabrication_note_rect"),
2060
+ import { z as z95 } from "zod";
2061
+ var pcb_fabrication_note_rect = z95.object({
2062
+ type: z95.literal("pcb_fabrication_note_rect"),
2031
2063
  pcb_fabrication_note_rect_id: getZodPrefixedIdWithDefault(
2032
2064
  "pcb_fabrication_note_rect"
2033
2065
  ),
2034
- pcb_component_id: z94.string(),
2035
- pcb_group_id: z94.string().optional(),
2036
- subcircuit_id: z94.string().optional(),
2066
+ pcb_component_id: z95.string(),
2067
+ pcb_group_id: z95.string().optional(),
2068
+ subcircuit_id: z95.string().optional(),
2037
2069
  center: point,
2038
2070
  width: length,
2039
2071
  height: length,
2040
2072
  layer: visible_layer,
2041
2073
  stroke_width: length.default("0.1mm"),
2042
- is_filled: z94.boolean().optional(),
2043
- has_stroke: z94.boolean().optional(),
2044
- is_stroke_dashed: z94.boolean().optional(),
2045
- color: z94.string().optional()
2074
+ is_filled: z95.boolean().optional(),
2075
+ has_stroke: z95.boolean().optional(),
2076
+ is_stroke_dashed: z95.boolean().optional(),
2077
+ color: z95.string().optional()
2046
2078
  }).describe("Defines a fabrication note rectangle on the PCB");
2047
2079
  expectTypesMatch(true);
2048
2080
 
2049
2081
  // src/pcb/pcb_fabrication_note_dimension.ts
2050
- import { z as z95 } from "zod";
2051
- var pcb_fabrication_note_dimension = z95.object({
2052
- type: z95.literal("pcb_fabrication_note_dimension"),
2082
+ import { z as z96 } from "zod";
2083
+ var pcb_fabrication_note_dimension = z96.object({
2084
+ type: z96.literal("pcb_fabrication_note_dimension"),
2053
2085
  pcb_fabrication_note_dimension_id: getZodPrefixedIdWithDefault(
2054
2086
  "pcb_fabrication_note_dimension"
2055
2087
  ),
2056
- pcb_component_id: z95.string(),
2057
- pcb_group_id: z95.string().optional(),
2058
- subcircuit_id: z95.string().optional(),
2088
+ pcb_component_id: z96.string(),
2089
+ pcb_group_id: z96.string().optional(),
2090
+ subcircuit_id: z96.string().optional(),
2059
2091
  layer: visible_layer,
2060
2092
  from: point,
2061
2093
  to: point,
2062
- text: z95.string().optional(),
2063
- text_ccw_rotation: z95.number().optional(),
2094
+ text: z96.string().optional(),
2095
+ text_ccw_rotation: z96.number().optional(),
2064
2096
  offset: length.optional(),
2065
2097
  offset_distance: length.optional(),
2066
- offset_direction: z95.object({
2067
- x: z95.number(),
2068
- y: z95.number()
2098
+ offset_direction: z96.object({
2099
+ x: z96.number(),
2100
+ y: z96.number()
2069
2101
  }).optional(),
2070
- font: z95.literal("tscircuit2024").default("tscircuit2024"),
2102
+ font: z96.literal("tscircuit2024").default("tscircuit2024"),
2071
2103
  font_size: length.default("1mm"),
2072
- color: z95.string().optional(),
2104
+ color: z96.string().optional(),
2073
2105
  arrow_size: length.default("1mm")
2074
2106
  }).describe("Defines a measurement annotation within PCB fabrication notes");
2075
2107
  expectTypesMatch(true);
2076
2108
 
2077
2109
  // src/pcb/pcb_note_text.ts
2078
- import { z as z96 } from "zod";
2079
- var pcb_note_text = z96.object({
2080
- type: z96.literal("pcb_note_text"),
2081
- pcb_note_text_id: getZodPrefixedIdWithDefault("pcb_note_text"),
2082
- pcb_component_id: z96.string().optional(),
2083
- pcb_group_id: z96.string().optional(),
2084
- subcircuit_id: z96.string().optional(),
2085
- name: z96.string().optional(),
2086
- font: z96.literal("tscircuit2024").default("tscircuit2024"),
2087
- font_size: distance.default("1mm"),
2088
- text: z96.string().optional(),
2089
- anchor_position: point.default({ x: 0, y: 0 }),
2090
- anchor_alignment: z96.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2091
- color: z96.string().optional()
2092
- }).describe("Defines a documentation note in text on the PCB");
2093
- expectTypesMatch(true);
2094
-
2095
- // src/pcb/pcb_note_rect.ts
2096
2110
  import { z as z97 } from "zod";
2097
- var pcb_note_rect = z97.object({
2098
- type: z97.literal("pcb_note_rect"),
2099
- pcb_note_rect_id: getZodPrefixedIdWithDefault("pcb_note_rect"),
2111
+ var pcb_note_text = z97.object({
2112
+ type: z97.literal("pcb_note_text"),
2113
+ pcb_note_text_id: getZodPrefixedIdWithDefault("pcb_note_text"),
2100
2114
  pcb_component_id: z97.string().optional(),
2101
2115
  pcb_group_id: z97.string().optional(),
2102
2116
  subcircuit_id: z97.string().optional(),
2103
2117
  name: z97.string().optional(),
2118
+ font: z97.literal("tscircuit2024").default("tscircuit2024"),
2119
+ font_size: distance.default("1mm"),
2104
2120
  text: z97.string().optional(),
2105
- center: point,
2106
- width: length,
2107
- height: length,
2108
- stroke_width: length.default("0.1mm"),
2109
- is_filled: z97.boolean().optional(),
2110
- has_stroke: z97.boolean().optional(),
2111
- is_stroke_dashed: z97.boolean().optional(),
2121
+ anchor_position: point.default({ x: 0, y: 0 }),
2122
+ anchor_alignment: z97.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2112
2123
  color: z97.string().optional()
2113
- }).describe("Defines a rectangular documentation note on the PCB");
2124
+ }).describe("Defines a documentation note in text on the PCB");
2114
2125
  expectTypesMatch(true);
2115
2126
 
2116
- // src/pcb/pcb_note_path.ts
2127
+ // src/pcb/pcb_note_rect.ts
2117
2128
  import { z as z98 } from "zod";
2118
- var pcb_note_path = z98.object({
2119
- type: z98.literal("pcb_note_path"),
2120
- pcb_note_path_id: getZodPrefixedIdWithDefault("pcb_note_path"),
2129
+ var pcb_note_rect = z98.object({
2130
+ type: z98.literal("pcb_note_rect"),
2131
+ pcb_note_rect_id: getZodPrefixedIdWithDefault("pcb_note_rect"),
2121
2132
  pcb_component_id: z98.string().optional(),
2122
2133
  pcb_group_id: z98.string().optional(),
2123
2134
  subcircuit_id: z98.string().optional(),
2124
2135
  name: z98.string().optional(),
2125
2136
  text: z98.string().optional(),
2126
- route: z98.array(point),
2137
+ center: point,
2138
+ width: length,
2139
+ height: length,
2127
2140
  stroke_width: length.default("0.1mm"),
2141
+ is_filled: z98.boolean().optional(),
2142
+ has_stroke: z98.boolean().optional(),
2143
+ is_stroke_dashed: z98.boolean().optional(),
2128
2144
  color: z98.string().optional()
2129
- }).describe("Defines a polyline documentation note on the PCB");
2145
+ }).describe("Defines a rectangular documentation note on the PCB");
2130
2146
  expectTypesMatch(true);
2131
2147
 
2132
- // src/pcb/pcb_note_line.ts
2148
+ // src/pcb/pcb_note_path.ts
2133
2149
  import { z as z99 } from "zod";
2134
- var pcb_note_line = z99.object({
2135
- type: z99.literal("pcb_note_line"),
2136
- pcb_note_line_id: getZodPrefixedIdWithDefault("pcb_note_line"),
2150
+ var pcb_note_path = z99.object({
2151
+ type: z99.literal("pcb_note_path"),
2152
+ pcb_note_path_id: getZodPrefixedIdWithDefault("pcb_note_path"),
2137
2153
  pcb_component_id: z99.string().optional(),
2138
2154
  pcb_group_id: z99.string().optional(),
2139
2155
  subcircuit_id: z99.string().optional(),
2140
2156
  name: z99.string().optional(),
2141
2157
  text: z99.string().optional(),
2158
+ route: z99.array(point),
2159
+ stroke_width: length.default("0.1mm"),
2160
+ color: z99.string().optional()
2161
+ }).describe("Defines a polyline documentation note on the PCB");
2162
+ expectTypesMatch(true);
2163
+
2164
+ // src/pcb/pcb_note_line.ts
2165
+ import { z as z100 } from "zod";
2166
+ var pcb_note_line = z100.object({
2167
+ type: z100.literal("pcb_note_line"),
2168
+ pcb_note_line_id: getZodPrefixedIdWithDefault("pcb_note_line"),
2169
+ pcb_component_id: z100.string().optional(),
2170
+ pcb_group_id: z100.string().optional(),
2171
+ subcircuit_id: z100.string().optional(),
2172
+ name: z100.string().optional(),
2173
+ text: z100.string().optional(),
2142
2174
  x1: distance,
2143
2175
  y1: distance,
2144
2176
  x2: distance,
2145
2177
  y2: distance,
2146
2178
  stroke_width: distance.default("0.1mm"),
2147
- color: z99.string().optional(),
2148
- is_dashed: z99.boolean().optional()
2179
+ color: z100.string().optional(),
2180
+ is_dashed: z100.boolean().optional()
2149
2181
  }).describe("Defines a straight documentation note line on the PCB");
2150
2182
  expectTypesMatch(true);
2151
2183
 
2152
2184
  // src/pcb/pcb_note_dimension.ts
2153
- import { z as z100 } from "zod";
2154
- var pcb_note_dimension = z100.object({
2155
- type: z100.literal("pcb_note_dimension"),
2185
+ import { z as z101 } from "zod";
2186
+ var pcb_note_dimension = z101.object({
2187
+ type: z101.literal("pcb_note_dimension"),
2156
2188
  pcb_note_dimension_id: getZodPrefixedIdWithDefault("pcb_note_dimension"),
2157
- pcb_component_id: z100.string().optional(),
2158
- pcb_group_id: z100.string().optional(),
2159
- subcircuit_id: z100.string().optional(),
2160
- name: z100.string().optional(),
2189
+ pcb_component_id: z101.string().optional(),
2190
+ pcb_group_id: z101.string().optional(),
2191
+ subcircuit_id: z101.string().optional(),
2192
+ name: z101.string().optional(),
2161
2193
  from: point,
2162
2194
  to: point,
2163
- text: z100.string().optional(),
2164
- text_ccw_rotation: z100.number().optional(),
2195
+ text: z101.string().optional(),
2196
+ text_ccw_rotation: z101.number().optional(),
2165
2197
  offset_distance: length.optional(),
2166
- offset_direction: z100.object({
2167
- x: z100.number(),
2168
- y: z100.number()
2198
+ offset_direction: z101.object({
2199
+ x: z101.number(),
2200
+ y: z101.number()
2169
2201
  }).optional(),
2170
- font: z100.literal("tscircuit2024").default("tscircuit2024"),
2202
+ font: z101.literal("tscircuit2024").default("tscircuit2024"),
2171
2203
  font_size: length.default("1mm"),
2172
- color: z100.string().optional(),
2204
+ color: z101.string().optional(),
2173
2205
  arrow_size: length.default("1mm")
2174
2206
  }).describe("Defines a measurement annotation within PCB documentation notes");
2175
2207
  expectTypesMatch(true);
2176
2208
 
2177
2209
  // src/pcb/pcb_footprint_overlap_error.ts
2178
- import { z as z101 } from "zod";
2179
- var pcb_footprint_overlap_error = z101.object({
2180
- type: z101.literal("pcb_footprint_overlap_error"),
2210
+ import { z as z102 } from "zod";
2211
+ var pcb_footprint_overlap_error = z102.object({
2212
+ type: z102.literal("pcb_footprint_overlap_error"),
2181
2213
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
2182
- error_type: z101.literal("pcb_footprint_overlap_error").default("pcb_footprint_overlap_error"),
2183
- message: z101.string(),
2184
- pcb_smtpad_ids: z101.array(z101.string()).optional(),
2185
- pcb_plated_hole_ids: z101.array(z101.string()).optional(),
2186
- pcb_hole_ids: z101.array(z101.string()).optional(),
2187
- pcb_keepout_ids: z101.array(z101.string()).optional()
2214
+ error_type: z102.literal("pcb_footprint_overlap_error").default("pcb_footprint_overlap_error"),
2215
+ message: z102.string(),
2216
+ pcb_smtpad_ids: z102.array(z102.string()).optional(),
2217
+ pcb_plated_hole_ids: z102.array(z102.string()).optional(),
2218
+ pcb_hole_ids: z102.array(z102.string()).optional(),
2219
+ pcb_keepout_ids: z102.array(z102.string()).optional()
2188
2220
  }).describe("Error emitted when a pcb footprint overlaps with another element");
2189
2221
  expectTypesMatch(
2190
2222
  true
2191
2223
  );
2192
2224
 
2193
2225
  // src/pcb/pcb_keepout.ts
2194
- import { z as z102 } from "zod";
2195
- var pcb_keepout = z102.object({
2196
- type: z102.literal("pcb_keepout"),
2197
- shape: z102.literal("rect"),
2198
- pcb_group_id: z102.string().optional(),
2199
- subcircuit_id: z102.string().optional(),
2226
+ import { z as z103 } from "zod";
2227
+ var pcb_keepout = z103.object({
2228
+ type: z103.literal("pcb_keepout"),
2229
+ shape: z103.literal("rect"),
2230
+ pcb_group_id: z103.string().optional(),
2231
+ subcircuit_id: z103.string().optional(),
2200
2232
  center: point,
2201
2233
  width: distance,
2202
2234
  height: distance,
2203
- pcb_keepout_id: z102.string(),
2204
- layers: z102.array(z102.string()),
2235
+ pcb_keepout_id: z103.string(),
2236
+ layers: z103.array(z103.string()),
2205
2237
  // Specify layers where the keepout applies
2206
- description: z102.string().optional()
2238
+ description: z103.string().optional()
2207
2239
  // Optional description of the keepout
2208
2240
  }).or(
2209
- z102.object({
2210
- type: z102.literal("pcb_keepout"),
2211
- shape: z102.literal("circle"),
2212
- pcb_group_id: z102.string().optional(),
2213
- subcircuit_id: z102.string().optional(),
2241
+ z103.object({
2242
+ type: z103.literal("pcb_keepout"),
2243
+ shape: z103.literal("circle"),
2244
+ pcb_group_id: z103.string().optional(),
2245
+ subcircuit_id: z103.string().optional(),
2214
2246
  center: point,
2215
2247
  radius: distance,
2216
- pcb_keepout_id: z102.string(),
2217
- layers: z102.array(z102.string()),
2248
+ pcb_keepout_id: z103.string(),
2249
+ layers: z103.array(z103.string()),
2218
2250
  // Specify layers where the keepout applies
2219
- description: z102.string().optional()
2251
+ description: z103.string().optional()
2220
2252
  // Optional description of the keepout
2221
2253
  })
2222
2254
  );
2223
2255
  expectTypesMatch(true);
2224
2256
 
2225
2257
  // src/pcb/pcb_cutout.ts
2226
- import { z as z103 } from "zod";
2227
- var pcb_cutout_base = z103.object({
2228
- type: z103.literal("pcb_cutout"),
2258
+ import { z as z104 } from "zod";
2259
+ var pcb_cutout_base = z104.object({
2260
+ type: z104.literal("pcb_cutout"),
2229
2261
  pcb_cutout_id: getZodPrefixedIdWithDefault("pcb_cutout"),
2230
- pcb_group_id: z103.string().optional(),
2231
- subcircuit_id: z103.string().optional()
2262
+ pcb_group_id: z104.string().optional(),
2263
+ subcircuit_id: z104.string().optional()
2232
2264
  });
2233
2265
  var pcb_cutout_rect = pcb_cutout_base.extend({
2234
- shape: z103.literal("rect"),
2266
+ shape: z104.literal("rect"),
2235
2267
  center: point,
2236
2268
  width: length,
2237
2269
  height: length,
@@ -2239,17 +2271,17 @@ var pcb_cutout_rect = pcb_cutout_base.extend({
2239
2271
  });
2240
2272
  expectTypesMatch(true);
2241
2273
  var pcb_cutout_circle = pcb_cutout_base.extend({
2242
- shape: z103.literal("circle"),
2274
+ shape: z104.literal("circle"),
2243
2275
  center: point,
2244
2276
  radius: length
2245
2277
  });
2246
2278
  expectTypesMatch(true);
2247
2279
  var pcb_cutout_polygon = pcb_cutout_base.extend({
2248
- shape: z103.literal("polygon"),
2249
- points: z103.array(point)
2280
+ shape: z104.literal("polygon"),
2281
+ points: z104.array(point)
2250
2282
  });
2251
2283
  expectTypesMatch(true);
2252
- var pcb_cutout = z103.discriminatedUnion("shape", [
2284
+ var pcb_cutout = z104.discriminatedUnion("shape", [
2253
2285
  pcb_cutout_rect,
2254
2286
  pcb_cutout_circle,
2255
2287
  pcb_cutout_polygon
@@ -2257,120 +2289,120 @@ var pcb_cutout = z103.discriminatedUnion("shape", [
2257
2289
  expectTypesMatch(true);
2258
2290
 
2259
2291
  // src/pcb/pcb_missing_footprint_error.ts
2260
- import { z as z104 } from "zod";
2261
- var pcb_missing_footprint_error = z104.object({
2262
- type: z104.literal("pcb_missing_footprint_error"),
2292
+ import { z as z105 } from "zod";
2293
+ var pcb_missing_footprint_error = z105.object({
2294
+ type: z105.literal("pcb_missing_footprint_error"),
2263
2295
  pcb_missing_footprint_error_id: getZodPrefixedIdWithDefault(
2264
2296
  "pcb_missing_footprint_error"
2265
2297
  ),
2266
- pcb_group_id: z104.string().optional(),
2267
- subcircuit_id: z104.string().optional(),
2268
- error_type: z104.literal("pcb_missing_footprint_error").default("pcb_missing_footprint_error"),
2269
- source_component_id: z104.string(),
2270
- message: z104.string()
2298
+ pcb_group_id: z105.string().optional(),
2299
+ subcircuit_id: z105.string().optional(),
2300
+ error_type: z105.literal("pcb_missing_footprint_error").default("pcb_missing_footprint_error"),
2301
+ source_component_id: z105.string(),
2302
+ message: z105.string()
2271
2303
  }).describe("Defines a missing footprint error on the PCB");
2272
2304
  expectTypesMatch(
2273
2305
  true
2274
2306
  );
2275
2307
 
2276
2308
  // src/pcb/external_footprint_load_error.ts
2277
- import { z as z105 } from "zod";
2278
- var external_footprint_load_error = z105.object({
2279
- type: z105.literal("external_footprint_load_error"),
2309
+ import { z as z106 } from "zod";
2310
+ var external_footprint_load_error = z106.object({
2311
+ type: z106.literal("external_footprint_load_error"),
2280
2312
  external_footprint_load_error_id: getZodPrefixedIdWithDefault(
2281
2313
  "external_footprint_load_error"
2282
2314
  ),
2283
- pcb_component_id: z105.string(),
2284
- source_component_id: z105.string(),
2285
- pcb_group_id: z105.string().optional(),
2286
- subcircuit_id: z105.string().optional(),
2287
- footprinter_string: z105.string().optional(),
2288
- error_type: z105.literal("external_footprint_load_error").default("external_footprint_load_error"),
2289
- message: z105.string()
2315
+ pcb_component_id: z106.string(),
2316
+ source_component_id: z106.string(),
2317
+ pcb_group_id: z106.string().optional(),
2318
+ subcircuit_id: z106.string().optional(),
2319
+ footprinter_string: z106.string().optional(),
2320
+ error_type: z106.literal("external_footprint_load_error").default("external_footprint_load_error"),
2321
+ message: z106.string()
2290
2322
  }).describe("Defines an error when an external footprint fails to load");
2291
2323
  expectTypesMatch(true);
2292
2324
 
2293
2325
  // src/pcb/circuit_json_footprint_load_error.ts
2294
- import { z as z106 } from "zod";
2295
- var circuit_json_footprint_load_error = z106.object({
2296
- type: z106.literal("circuit_json_footprint_load_error"),
2326
+ import { z as z107 } from "zod";
2327
+ var circuit_json_footprint_load_error = z107.object({
2328
+ type: z107.literal("circuit_json_footprint_load_error"),
2297
2329
  circuit_json_footprint_load_error_id: getZodPrefixedIdWithDefault(
2298
2330
  "circuit_json_footprint_load_error"
2299
2331
  ),
2300
- pcb_component_id: z106.string(),
2301
- source_component_id: z106.string(),
2302
- pcb_group_id: z106.string().optional(),
2303
- subcircuit_id: z106.string().optional(),
2304
- error_type: z106.literal("circuit_json_footprint_load_error").default("circuit_json_footprint_load_error"),
2305
- message: z106.string(),
2306
- circuit_json: z106.array(z106.any()).optional()
2332
+ pcb_component_id: z107.string(),
2333
+ source_component_id: z107.string(),
2334
+ pcb_group_id: z107.string().optional(),
2335
+ subcircuit_id: z107.string().optional(),
2336
+ error_type: z107.literal("circuit_json_footprint_load_error").default("circuit_json_footprint_load_error"),
2337
+ message: z107.string(),
2338
+ circuit_json: z107.array(z107.any()).optional()
2307
2339
  }).describe("Defines an error when a circuit JSON footprint fails to load");
2308
2340
  expectTypesMatch(true);
2309
2341
 
2310
2342
  // src/pcb/pcb_group.ts
2311
- import { z as z107 } from "zod";
2312
- var pcb_group = z107.object({
2313
- type: z107.literal("pcb_group"),
2343
+ import { z as z108 } from "zod";
2344
+ var pcb_group = z108.object({
2345
+ type: z108.literal("pcb_group"),
2314
2346
  pcb_group_id: getZodPrefixedIdWithDefault("pcb_group"),
2315
- source_group_id: z107.string(),
2316
- is_subcircuit: z107.boolean().optional(),
2317
- subcircuit_id: z107.string().optional(),
2347
+ source_group_id: z108.string(),
2348
+ is_subcircuit: z108.boolean().optional(),
2349
+ subcircuit_id: z108.string().optional(),
2318
2350
  width: length.optional(),
2319
2351
  height: length.optional(),
2320
2352
  center: point,
2321
- outline: z107.array(point).optional(),
2353
+ outline: z108.array(point).optional(),
2322
2354
  anchor_position: point.optional(),
2323
- anchor_alignment: z107.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).optional(),
2324
- pcb_component_ids: z107.array(z107.string()),
2325
- name: z107.string().optional(),
2326
- description: z107.string().optional(),
2327
- layout_mode: z107.string().optional(),
2328
- autorouter_configuration: z107.object({
2355
+ anchor_alignment: z108.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).optional(),
2356
+ pcb_component_ids: z108.array(z108.string()),
2357
+ name: z108.string().optional(),
2358
+ description: z108.string().optional(),
2359
+ layout_mode: z108.string().optional(),
2360
+ autorouter_configuration: z108.object({
2329
2361
  trace_clearance: length
2330
2362
  }).optional(),
2331
- autorouter_used_string: z107.string().optional()
2363
+ autorouter_used_string: z108.string().optional()
2332
2364
  }).describe("Defines a group of components on the PCB");
2333
2365
  expectTypesMatch(true);
2334
2366
 
2335
2367
  // src/pcb/pcb_autorouting_error.ts
2336
- import { z as z108 } from "zod";
2337
- var pcb_autorouting_error = z108.object({
2338
- type: z108.literal("pcb_autorouting_error"),
2368
+ import { z as z109 } from "zod";
2369
+ var pcb_autorouting_error = z109.object({
2370
+ type: z109.literal("pcb_autorouting_error"),
2339
2371
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_autorouting_error"),
2340
- error_type: z108.literal("pcb_autorouting_error").default("pcb_autorouting_error"),
2341
- message: z108.string(),
2342
- subcircuit_id: z108.string().optional()
2372
+ error_type: z109.literal("pcb_autorouting_error").default("pcb_autorouting_error"),
2373
+ message: z109.string(),
2374
+ subcircuit_id: z109.string().optional()
2343
2375
  }).describe("The autorouting has failed to route a portion of the board");
2344
2376
  expectTypesMatch(true);
2345
2377
 
2346
2378
  // src/pcb/pcb_manual_edit_conflict_warning.ts
2347
- import { z as z109 } from "zod";
2348
- var pcb_manual_edit_conflict_warning = z109.object({
2349
- type: z109.literal("pcb_manual_edit_conflict_warning"),
2379
+ import { z as z110 } from "zod";
2380
+ var pcb_manual_edit_conflict_warning = z110.object({
2381
+ type: z110.literal("pcb_manual_edit_conflict_warning"),
2350
2382
  pcb_manual_edit_conflict_warning_id: getZodPrefixedIdWithDefault(
2351
2383
  "pcb_manual_edit_conflict_warning"
2352
2384
  ),
2353
- warning_type: z109.literal("pcb_manual_edit_conflict_warning").default("pcb_manual_edit_conflict_warning"),
2354
- message: z109.string(),
2355
- pcb_component_id: z109.string(),
2356
- pcb_group_id: z109.string().optional(),
2357
- subcircuit_id: z109.string().optional(),
2358
- source_component_id: z109.string()
2385
+ warning_type: z110.literal("pcb_manual_edit_conflict_warning").default("pcb_manual_edit_conflict_warning"),
2386
+ message: z110.string(),
2387
+ pcb_component_id: z110.string(),
2388
+ pcb_group_id: z110.string().optional(),
2389
+ subcircuit_id: z110.string().optional(),
2390
+ source_component_id: z110.string()
2359
2391
  }).describe(
2360
2392
  "Warning emitted when a component has both manual placement and explicit pcbX/pcbY coordinates"
2361
2393
  );
2362
2394
  expectTypesMatch(true);
2363
2395
 
2364
2396
  // src/pcb/pcb_breakout_point.ts
2365
- import { z as z110 } from "zod";
2366
- var pcb_breakout_point = z110.object({
2367
- type: z110.literal("pcb_breakout_point"),
2397
+ import { z as z111 } from "zod";
2398
+ var pcb_breakout_point = z111.object({
2399
+ type: z111.literal("pcb_breakout_point"),
2368
2400
  pcb_breakout_point_id: getZodPrefixedIdWithDefault("pcb_breakout_point"),
2369
- pcb_group_id: z110.string(),
2370
- subcircuit_id: z110.string().optional(),
2371
- source_trace_id: z110.string().optional(),
2372
- source_port_id: z110.string().optional(),
2373
- source_net_id: z110.string().optional(),
2401
+ pcb_group_id: z111.string(),
2402
+ subcircuit_id: z111.string().optional(),
2403
+ source_trace_id: z111.string().optional(),
2404
+ source_port_id: z111.string().optional(),
2405
+ source_net_id: z111.string().optional(),
2374
2406
  x: distance,
2375
2407
  y: distance
2376
2408
  }).describe(
@@ -2379,60 +2411,60 @@ var pcb_breakout_point = z110.object({
2379
2411
  expectTypesMatch(true);
2380
2412
 
2381
2413
  // src/pcb/pcb_ground_plane.ts
2382
- import { z as z111 } from "zod";
2383
- var pcb_ground_plane = z111.object({
2384
- type: z111.literal("pcb_ground_plane"),
2414
+ import { z as z112 } from "zod";
2415
+ var pcb_ground_plane = z112.object({
2416
+ type: z112.literal("pcb_ground_plane"),
2385
2417
  pcb_ground_plane_id: getZodPrefixedIdWithDefault("pcb_ground_plane"),
2386
- source_pcb_ground_plane_id: z111.string(),
2387
- source_net_id: z111.string(),
2388
- pcb_group_id: z111.string().optional(),
2389
- subcircuit_id: z111.string().optional()
2418
+ source_pcb_ground_plane_id: z112.string(),
2419
+ source_net_id: z112.string(),
2420
+ pcb_group_id: z112.string().optional(),
2421
+ subcircuit_id: z112.string().optional()
2390
2422
  }).describe("Defines a ground plane on the PCB");
2391
2423
  expectTypesMatch(true);
2392
2424
 
2393
2425
  // src/pcb/pcb_ground_plane_region.ts
2394
- import { z as z112 } from "zod";
2395
- var pcb_ground_plane_region = z112.object({
2396
- type: z112.literal("pcb_ground_plane_region"),
2426
+ import { z as z113 } from "zod";
2427
+ var pcb_ground_plane_region = z113.object({
2428
+ type: z113.literal("pcb_ground_plane_region"),
2397
2429
  pcb_ground_plane_region_id: getZodPrefixedIdWithDefault(
2398
2430
  "pcb_ground_plane_region"
2399
2431
  ),
2400
- pcb_ground_plane_id: z112.string(),
2401
- pcb_group_id: z112.string().optional(),
2402
- subcircuit_id: z112.string().optional(),
2432
+ pcb_ground_plane_id: z113.string(),
2433
+ pcb_group_id: z113.string().optional(),
2434
+ subcircuit_id: z113.string().optional(),
2403
2435
  layer: layer_ref,
2404
- points: z112.array(point)
2436
+ points: z113.array(point)
2405
2437
  }).describe("Defines a polygon region of a ground plane");
2406
2438
  expectTypesMatch(true);
2407
2439
 
2408
2440
  // src/pcb/pcb_thermal_spoke.ts
2409
- import { z as z113 } from "zod";
2410
- var pcb_thermal_spoke = z113.object({
2411
- type: z113.literal("pcb_thermal_spoke"),
2441
+ import { z as z114 } from "zod";
2442
+ var pcb_thermal_spoke = z114.object({
2443
+ type: z114.literal("pcb_thermal_spoke"),
2412
2444
  pcb_thermal_spoke_id: getZodPrefixedIdWithDefault("pcb_thermal_spoke"),
2413
- pcb_ground_plane_id: z113.string(),
2414
- shape: z113.string(),
2415
- spoke_count: z113.number(),
2445
+ pcb_ground_plane_id: z114.string(),
2446
+ shape: z114.string(),
2447
+ spoke_count: z114.number(),
2416
2448
  spoke_thickness: distance,
2417
2449
  spoke_inner_diameter: distance,
2418
2450
  spoke_outer_diameter: distance,
2419
- pcb_plated_hole_id: z113.string().optional(),
2420
- subcircuit_id: z113.string().optional()
2451
+ pcb_plated_hole_id: z114.string().optional(),
2452
+ subcircuit_id: z114.string().optional()
2421
2453
  }).describe("Pattern for connecting a ground plane to a plated hole");
2422
2454
  expectTypesMatch(true);
2423
2455
 
2424
2456
  // src/pcb/pcb_copper_pour.ts
2425
- import { z as z114 } from "zod";
2426
- var pcb_copper_pour_base = z114.object({
2427
- type: z114.literal("pcb_copper_pour"),
2457
+ import { z as z115 } from "zod";
2458
+ var pcb_copper_pour_base = z115.object({
2459
+ type: z115.literal("pcb_copper_pour"),
2428
2460
  pcb_copper_pour_id: getZodPrefixedIdWithDefault("pcb_copper_pour"),
2429
- pcb_group_id: z114.string().optional(),
2430
- subcircuit_id: z114.string().optional(),
2461
+ pcb_group_id: z115.string().optional(),
2462
+ subcircuit_id: z115.string().optional(),
2431
2463
  layer: layer_ref,
2432
- source_net_id: z114.string().optional()
2464
+ source_net_id: z115.string().optional()
2433
2465
  });
2434
2466
  var pcb_copper_pour_rect = pcb_copper_pour_base.extend({
2435
- shape: z114.literal("rect"),
2467
+ shape: z115.literal("rect"),
2436
2468
  center: point,
2437
2469
  width: length,
2438
2470
  height: length,
@@ -2440,16 +2472,16 @@ var pcb_copper_pour_rect = pcb_copper_pour_base.extend({
2440
2472
  });
2441
2473
  expectTypesMatch(true);
2442
2474
  var pcb_copper_pour_brep = pcb_copper_pour_base.extend({
2443
- shape: z114.literal("brep"),
2475
+ shape: z115.literal("brep"),
2444
2476
  brep_shape
2445
2477
  });
2446
2478
  expectTypesMatch(true);
2447
2479
  var pcb_copper_pour_polygon = pcb_copper_pour_base.extend({
2448
- shape: z114.literal("polygon"),
2449
- points: z114.array(point)
2480
+ shape: z115.literal("polygon"),
2481
+ points: z115.array(point)
2450
2482
  });
2451
2483
  expectTypesMatch(true);
2452
- var pcb_copper_pour = z114.discriminatedUnion("shape", [
2484
+ var pcb_copper_pour = z115.discriminatedUnion("shape", [
2453
2485
  pcb_copper_pour_rect,
2454
2486
  pcb_copper_pour_brep,
2455
2487
  pcb_copper_pour_polygon
@@ -2457,147 +2489,147 @@ var pcb_copper_pour = z114.discriminatedUnion("shape", [
2457
2489
  expectTypesMatch(true);
2458
2490
 
2459
2491
  // src/pcb/pcb_component_outside_board_error.ts
2460
- import { z as z115 } from "zod";
2461
- var pcb_component_outside_board_error = z115.object({
2462
- type: z115.literal("pcb_component_outside_board_error"),
2492
+ import { z as z116 } from "zod";
2493
+ var pcb_component_outside_board_error = z116.object({
2494
+ type: z116.literal("pcb_component_outside_board_error"),
2463
2495
  pcb_component_outside_board_error_id: getZodPrefixedIdWithDefault(
2464
2496
  "pcb_component_outside_board_error"
2465
2497
  ),
2466
- error_type: z115.literal("pcb_component_outside_board_error").default("pcb_component_outside_board_error"),
2467
- message: z115.string(),
2468
- pcb_component_id: z115.string(),
2469
- pcb_board_id: z115.string(),
2498
+ error_type: z116.literal("pcb_component_outside_board_error").default("pcb_component_outside_board_error"),
2499
+ message: z116.string(),
2500
+ pcb_component_id: z116.string(),
2501
+ pcb_board_id: z116.string(),
2470
2502
  component_center: point,
2471
- component_bounds: z115.object({
2472
- min_x: z115.number(),
2473
- max_x: z115.number(),
2474
- min_y: z115.number(),
2475
- max_y: z115.number()
2503
+ component_bounds: z116.object({
2504
+ min_x: z116.number(),
2505
+ max_x: z116.number(),
2506
+ min_y: z116.number(),
2507
+ max_y: z116.number()
2476
2508
  }),
2477
- subcircuit_id: z115.string().optional(),
2478
- source_component_id: z115.string().optional()
2509
+ subcircuit_id: z116.string().optional(),
2510
+ source_component_id: z116.string().optional()
2479
2511
  }).describe(
2480
2512
  "Error emitted when a PCB component is placed outside the board boundaries"
2481
2513
  );
2482
2514
  expectTypesMatch(true);
2483
2515
 
2484
2516
  // src/pcb/pcb_component_invalid_layer_error.ts
2485
- import { z as z116 } from "zod";
2486
- var pcb_component_invalid_layer_error = z116.object({
2487
- type: z116.literal("pcb_component_invalid_layer_error"),
2517
+ import { z as z117 } from "zod";
2518
+ var pcb_component_invalid_layer_error = z117.object({
2519
+ type: z117.literal("pcb_component_invalid_layer_error"),
2488
2520
  pcb_component_invalid_layer_error_id: getZodPrefixedIdWithDefault(
2489
2521
  "pcb_component_invalid_layer_error"
2490
2522
  ),
2491
- error_type: z116.literal("pcb_component_invalid_layer_error").default("pcb_component_invalid_layer_error"),
2492
- message: z116.string(),
2493
- pcb_component_id: z116.string().optional(),
2494
- source_component_id: z116.string(),
2523
+ error_type: z117.literal("pcb_component_invalid_layer_error").default("pcb_component_invalid_layer_error"),
2524
+ message: z117.string(),
2525
+ pcb_component_id: z117.string().optional(),
2526
+ source_component_id: z117.string(),
2495
2527
  layer: layer_ref,
2496
- subcircuit_id: z116.string().optional()
2528
+ subcircuit_id: z117.string().optional()
2497
2529
  }).describe(
2498
2530
  "Error emitted when a component is placed on an invalid layer (components can only be on 'top' or 'bottom' layers)"
2499
2531
  );
2500
2532
  expectTypesMatch(true);
2501
2533
 
2502
2534
  // src/pcb/pcb_via_clearance_error.ts
2503
- import { z as z117 } from "zod";
2504
- var pcb_via_clearance_error = z117.object({
2505
- type: z117.literal("pcb_via_clearance_error"),
2535
+ import { z as z118 } from "zod";
2536
+ var pcb_via_clearance_error = z118.object({
2537
+ type: z118.literal("pcb_via_clearance_error"),
2506
2538
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
2507
- error_type: z117.literal("pcb_via_clearance_error").default("pcb_via_clearance_error"),
2508
- message: z117.string(),
2509
- pcb_via_ids: z117.array(z117.string()).min(2),
2539
+ error_type: z118.literal("pcb_via_clearance_error").default("pcb_via_clearance_error"),
2540
+ message: z118.string(),
2541
+ pcb_via_ids: z118.array(z118.string()).min(2),
2510
2542
  minimum_clearance: distance.optional(),
2511
2543
  actual_clearance: distance.optional(),
2512
- pcb_center: z117.object({
2513
- x: z117.number().optional(),
2514
- y: z117.number().optional()
2544
+ pcb_center: z118.object({
2545
+ x: z118.number().optional(),
2546
+ y: z118.number().optional()
2515
2547
  }).optional(),
2516
- subcircuit_id: z117.string().optional()
2548
+ subcircuit_id: z118.string().optional()
2517
2549
  }).describe("Error emitted when vias are closer than the allowed clearance");
2518
2550
  expectTypesMatch(true);
2519
2551
 
2520
2552
  // src/pcb/pcb_courtyard_rect.ts
2521
- import { z as z118 } from "zod";
2522
- var pcb_courtyard_rect = z118.object({
2523
- type: z118.literal("pcb_courtyard_rect"),
2553
+ import { z as z119 } from "zod";
2554
+ var pcb_courtyard_rect = z119.object({
2555
+ type: z119.literal("pcb_courtyard_rect"),
2524
2556
  pcb_courtyard_rect_id: getZodPrefixedIdWithDefault("pcb_courtyard_rect"),
2525
- pcb_component_id: z118.string(),
2526
- pcb_group_id: z118.string().optional(),
2527
- subcircuit_id: z118.string().optional(),
2557
+ pcb_component_id: z119.string(),
2558
+ pcb_group_id: z119.string().optional(),
2559
+ subcircuit_id: z119.string().optional(),
2528
2560
  center: point,
2529
2561
  width: length,
2530
2562
  height: length,
2531
2563
  layer: visible_layer,
2532
- color: z118.string().optional()
2564
+ color: z119.string().optional()
2533
2565
  }).describe("Defines a courtyard rectangle on the PCB");
2534
2566
  expectTypesMatch(true);
2535
2567
 
2536
2568
  // src/pcb/pcb_courtyard_outline.ts
2537
- import { z as z119 } from "zod";
2538
- var pcb_courtyard_outline = z119.object({
2539
- type: z119.literal("pcb_courtyard_outline"),
2569
+ import { z as z120 } from "zod";
2570
+ var pcb_courtyard_outline = z120.object({
2571
+ type: z120.literal("pcb_courtyard_outline"),
2540
2572
  pcb_courtyard_outline_id: getZodPrefixedIdWithDefault(
2541
2573
  "pcb_courtyard_outline"
2542
2574
  ),
2543
- pcb_component_id: z119.string(),
2544
- pcb_group_id: z119.string().optional(),
2545
- subcircuit_id: z119.string().optional(),
2575
+ pcb_component_id: z120.string(),
2576
+ pcb_group_id: z120.string().optional(),
2577
+ subcircuit_id: z120.string().optional(),
2546
2578
  layer: visible_layer,
2547
- outline: z119.array(point).min(2),
2579
+ outline: z120.array(point).min(2),
2548
2580
  stroke_width: length.default("0.1mm"),
2549
- is_closed: z119.boolean().optional(),
2550
- is_stroke_dashed: z119.boolean().optional(),
2551
- color: z119.string().optional()
2581
+ is_closed: z120.boolean().optional(),
2582
+ is_stroke_dashed: z120.boolean().optional(),
2583
+ color: z120.string().optional()
2552
2584
  }).describe("Defines a courtyard outline on the PCB");
2553
2585
  expectTypesMatch(true);
2554
2586
 
2555
2587
  // src/pcb/pcb_courtyard_polygon.ts
2556
- import { z as z120 } from "zod";
2557
- var pcb_courtyard_polygon = z120.object({
2558
- type: z120.literal("pcb_courtyard_polygon"),
2588
+ import { z as z121 } from "zod";
2589
+ var pcb_courtyard_polygon = z121.object({
2590
+ type: z121.literal("pcb_courtyard_polygon"),
2559
2591
  pcb_courtyard_polygon_id: getZodPrefixedIdWithDefault(
2560
2592
  "pcb_courtyard_polygon"
2561
2593
  ),
2562
- pcb_component_id: z120.string(),
2563
- pcb_group_id: z120.string().optional(),
2564
- subcircuit_id: z120.string().optional(),
2594
+ pcb_component_id: z121.string(),
2595
+ pcb_group_id: z121.string().optional(),
2596
+ subcircuit_id: z121.string().optional(),
2565
2597
  layer: visible_layer,
2566
- points: z120.array(point).min(3),
2567
- color: z120.string().optional()
2598
+ points: z121.array(point).min(3),
2599
+ color: z121.string().optional()
2568
2600
  }).describe("Defines a courtyard polygon on the PCB");
2569
2601
  expectTypesMatch(true);
2570
2602
 
2571
2603
  // src/cad/cad_component.ts
2572
- import { z as z121 } from "zod";
2573
- var cad_component = z121.object({
2574
- type: z121.literal("cad_component"),
2575
- cad_component_id: z121.string(),
2576
- pcb_component_id: z121.string(),
2577
- source_component_id: z121.string(),
2604
+ import { z as z122 } from "zod";
2605
+ var cad_component = z122.object({
2606
+ type: z122.literal("cad_component"),
2607
+ cad_component_id: z122.string(),
2608
+ pcb_component_id: z122.string(),
2609
+ source_component_id: z122.string(),
2578
2610
  position: point3,
2579
2611
  rotation: point3.optional(),
2580
2612
  size: point3.optional(),
2581
2613
  layer: layer_ref.optional(),
2582
- subcircuit_id: z121.string().optional(),
2614
+ subcircuit_id: z122.string().optional(),
2583
2615
  // These are all ways to generate/load the 3d model
2584
- footprinter_string: z121.string().optional(),
2585
- model_obj_url: z121.string().optional(),
2586
- model_stl_url: z121.string().optional(),
2587
- model_3mf_url: z121.string().optional(),
2588
- model_gltf_url: z121.string().optional(),
2589
- model_glb_url: z121.string().optional(),
2590
- model_step_url: z121.string().optional(),
2591
- model_wrl_url: z121.string().optional(),
2592
- model_unit_to_mm_scale_factor: z121.number().optional(),
2593
- model_jscad: z121.any().optional()
2616
+ footprinter_string: z122.string().optional(),
2617
+ model_obj_url: z122.string().optional(),
2618
+ model_stl_url: z122.string().optional(),
2619
+ model_3mf_url: z122.string().optional(),
2620
+ model_gltf_url: z122.string().optional(),
2621
+ model_glb_url: z122.string().optional(),
2622
+ model_step_url: z122.string().optional(),
2623
+ model_wrl_url: z122.string().optional(),
2624
+ model_unit_to_mm_scale_factor: z122.number().optional(),
2625
+ model_jscad: z122.any().optional()
2594
2626
  }).describe("Defines a component on the PCB");
2595
2627
  expectTypesMatch(true);
2596
2628
 
2597
2629
  // src/simulation/simulation_voltage_source.ts
2598
- import { z as z122 } from "zod";
2599
- var wave_shape = z122.enum(["sinewave", "square", "triangle", "sawtooth"]);
2600
- var percentage = z122.union([z122.string(), z122.number()]).transform((val) => {
2630
+ import { z as z123 } from "zod";
2631
+ var wave_shape = z123.enum(["sinewave", "square", "triangle", "sawtooth"]);
2632
+ var percentage = z123.union([z123.string(), z123.number()]).transform((val) => {
2601
2633
  if (typeof val === "string") {
2602
2634
  if (val.endsWith("%")) {
2603
2635
  return parseFloat(val.slice(0, -1)) / 100;
@@ -2606,30 +2638,30 @@ var percentage = z122.union([z122.string(), z122.number()]).transform((val) => {
2606
2638
  }
2607
2639
  return val;
2608
2640
  }).pipe(
2609
- z122.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
2641
+ z123.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
2610
2642
  );
2611
- var simulation_dc_voltage_source = z122.object({
2612
- type: z122.literal("simulation_voltage_source"),
2643
+ var simulation_dc_voltage_source = z123.object({
2644
+ type: z123.literal("simulation_voltage_source"),
2613
2645
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
2614
2646
  "simulation_voltage_source"
2615
2647
  ),
2616
- is_dc_source: z122.literal(true).optional().default(true),
2617
- positive_source_port_id: z122.string().optional(),
2618
- negative_source_port_id: z122.string().optional(),
2619
- positive_source_net_id: z122.string().optional(),
2620
- negative_source_net_id: z122.string().optional(),
2648
+ is_dc_source: z123.literal(true).optional().default(true),
2649
+ positive_source_port_id: z123.string().optional(),
2650
+ negative_source_port_id: z123.string().optional(),
2651
+ positive_source_net_id: z123.string().optional(),
2652
+ negative_source_net_id: z123.string().optional(),
2621
2653
  voltage
2622
2654
  }).describe("Defines a DC voltage source for simulation");
2623
- var simulation_ac_voltage_source = z122.object({
2624
- type: z122.literal("simulation_voltage_source"),
2655
+ var simulation_ac_voltage_source = z123.object({
2656
+ type: z123.literal("simulation_voltage_source"),
2625
2657
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
2626
2658
  "simulation_voltage_source"
2627
2659
  ),
2628
- is_dc_source: z122.literal(false),
2629
- terminal1_source_port_id: z122.string().optional(),
2630
- terminal2_source_port_id: z122.string().optional(),
2631
- terminal1_source_net_id: z122.string().optional(),
2632
- terminal2_source_net_id: z122.string().optional(),
2660
+ is_dc_source: z123.literal(false),
2661
+ terminal1_source_port_id: z123.string().optional(),
2662
+ terminal2_source_port_id: z123.string().optional(),
2663
+ terminal1_source_net_id: z123.string().optional(),
2664
+ terminal2_source_net_id: z123.string().optional(),
2633
2665
  voltage: voltage.optional(),
2634
2666
  frequency: frequency.optional(),
2635
2667
  peak_to_peak_voltage: voltage.optional(),
@@ -2637,25 +2669,25 @@ var simulation_ac_voltage_source = z122.object({
2637
2669
  phase: rotation.optional(),
2638
2670
  duty_cycle: percentage.optional()
2639
2671
  }).describe("Defines an AC voltage source for simulation");
2640
- var simulation_voltage_source = z122.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
2672
+ var simulation_voltage_source = z123.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
2641
2673
  expectTypesMatch(true);
2642
2674
  expectTypesMatch(true);
2643
2675
  expectTypesMatch(true);
2644
2676
 
2645
2677
  // src/simulation/simulation_experiment.ts
2646
- import { z as z123 } from "zod";
2647
- var experiment_type = z123.union([
2648
- z123.literal("spice_dc_sweep"),
2649
- z123.literal("spice_dc_operating_point"),
2650
- z123.literal("spice_transient_analysis"),
2651
- z123.literal("spice_ac_analysis")
2678
+ import { z as z124 } from "zod";
2679
+ var experiment_type = z124.union([
2680
+ z124.literal("spice_dc_sweep"),
2681
+ z124.literal("spice_dc_operating_point"),
2682
+ z124.literal("spice_transient_analysis"),
2683
+ z124.literal("spice_ac_analysis")
2652
2684
  ]);
2653
- var simulation_experiment = z123.object({
2654
- type: z123.literal("simulation_experiment"),
2685
+ var simulation_experiment = z124.object({
2686
+ type: z124.literal("simulation_experiment"),
2655
2687
  simulation_experiment_id: getZodPrefixedIdWithDefault(
2656
2688
  "simulation_experiment"
2657
2689
  ),
2658
- name: z123.string(),
2690
+ name: z124.string(),
2659
2691
  experiment_type,
2660
2692
  time_per_step: duration_ms.optional(),
2661
2693
  start_time_ms: ms.optional(),
@@ -2664,49 +2696,49 @@ var simulation_experiment = z123.object({
2664
2696
  expectTypesMatch(true);
2665
2697
 
2666
2698
  // src/simulation/simulation_transient_voltage_graph.ts
2667
- import { z as z124 } from "zod";
2668
- var simulation_transient_voltage_graph = z124.object({
2669
- type: z124.literal("simulation_transient_voltage_graph"),
2699
+ import { z as z125 } from "zod";
2700
+ var simulation_transient_voltage_graph = z125.object({
2701
+ type: z125.literal("simulation_transient_voltage_graph"),
2670
2702
  simulation_transient_voltage_graph_id: getZodPrefixedIdWithDefault(
2671
2703
  "simulation_transient_voltage_graph"
2672
2704
  ),
2673
- simulation_experiment_id: z124.string(),
2674
- timestamps_ms: z124.array(z124.number()).optional(),
2675
- voltage_levels: z124.array(z124.number()),
2676
- schematic_voltage_probe_id: z124.string().optional(),
2677
- simulation_voltage_probe_id: z124.string().optional(),
2678
- subcircuit_connectivity_map_key: z124.string().optional(),
2705
+ simulation_experiment_id: z125.string(),
2706
+ timestamps_ms: z125.array(z125.number()).optional(),
2707
+ voltage_levels: z125.array(z125.number()),
2708
+ schematic_voltage_probe_id: z125.string().optional(),
2709
+ simulation_voltage_probe_id: z125.string().optional(),
2710
+ subcircuit_connectivity_map_key: z125.string().optional(),
2679
2711
  time_per_step: duration_ms,
2680
2712
  start_time_ms: ms,
2681
2713
  end_time_ms: ms,
2682
- name: z124.string().optional()
2714
+ name: z125.string().optional()
2683
2715
  }).describe("Stores voltage measurements over time for a simulation");
2684
2716
  expectTypesMatch(true);
2685
2717
 
2686
2718
  // src/simulation/simulation_switch.ts
2687
- import { z as z125 } from "zod";
2688
- var simulation_switch = z125.object({
2689
- type: z125.literal("simulation_switch"),
2719
+ import { z as z126 } from "zod";
2720
+ var simulation_switch = z126.object({
2721
+ type: z126.literal("simulation_switch"),
2690
2722
  simulation_switch_id: getZodPrefixedIdWithDefault("simulation_switch"),
2691
- source_component_id: z125.string().optional(),
2723
+ source_component_id: z126.string().optional(),
2692
2724
  closes_at: ms.optional(),
2693
2725
  opens_at: ms.optional(),
2694
- starts_closed: z125.boolean().optional(),
2726
+ starts_closed: z126.boolean().optional(),
2695
2727
  switching_frequency: frequency.optional()
2696
2728
  }).describe("Defines a switch for simulation timing control");
2697
2729
  expectTypesMatch(true);
2698
2730
 
2699
2731
  // src/simulation/simulation_voltage_probe.ts
2700
- import { z as z126 } from "zod";
2701
- var simulation_voltage_probe = z126.object({
2702
- type: z126.literal("simulation_voltage_probe"),
2732
+ import { z as z127 } from "zod";
2733
+ var simulation_voltage_probe = z127.object({
2734
+ type: z127.literal("simulation_voltage_probe"),
2703
2735
  simulation_voltage_probe_id: getZodPrefixedIdWithDefault(
2704
2736
  "simulation_voltage_probe"
2705
2737
  ),
2706
- source_port_id: z126.string().optional(),
2707
- source_net_id: z126.string().optional(),
2708
- name: z126.string().optional(),
2709
- subcircuit_id: z126.string().optional()
2738
+ source_port_id: z127.string().optional(),
2739
+ source_net_id: z127.string().optional(),
2740
+ name: z127.string().optional(),
2741
+ subcircuit_id: z127.string().optional()
2710
2742
  }).describe(
2711
2743
  "Defines a voltage probe for simulation, connected to a port or a net"
2712
2744
  ).refine(
@@ -2718,8 +2750,8 @@ var simulation_voltage_probe = z126.object({
2718
2750
  expectTypesMatch(true);
2719
2751
 
2720
2752
  // src/any_circuit_element.ts
2721
- import { z as z127 } from "zod";
2722
- var any_circuit_element = z127.union([
2753
+ import { z as z128 } from "zod";
2754
+ var any_circuit_element = z128.union([
2723
2755
  source_trace,
2724
2756
  source_port,
2725
2757
  any_source_component,
@@ -2771,6 +2803,7 @@ var any_circuit_element = z127.union([
2771
2803
  pcb_silkscreen_line,
2772
2804
  pcb_silkscreen_path,
2773
2805
  pcb_silkscreen_text,
2806
+ pcb_copper_text,
2774
2807
  pcb_silkscreen_rect,
2775
2808
  pcb_silkscreen_circle,
2776
2809
  pcb_silkscreen_oval,
@@ -2864,6 +2897,7 @@ export {
2864
2897
  pcb_copper_pour_brep,
2865
2898
  pcb_copper_pour_polygon,
2866
2899
  pcb_copper_pour_rect,
2900
+ pcb_copper_text,
2867
2901
  pcb_courtyard_outline,
2868
2902
  pcb_courtyard_polygon,
2869
2903
  pcb_courtyard_rect,