circuit-json 0.0.478 → 0.0.480

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
@@ -1584,104 +1584,127 @@ var schematic_element_outside_sheet_warning = z92.object({
1584
1584
  );
1585
1585
  expectTypesMatch(true);
1586
1586
 
1587
- // src/schematic/schematic_group.ts
1587
+ // src/schematic/schematic_graphic.ts
1588
1588
  import { z as z93 } from "zod";
1589
- var schematic_group = z93.object({
1590
- type: z93.literal("schematic_group"),
1591
- schematic_group_id: getZodPrefixedIdWithDefault("schematic_group"),
1589
+ var positiveFiniteDistance = distance.pipe(z93.number().positive().finite());
1590
+ var schematic_graphic = z93.object({
1591
+ type: z93.literal("schematic_graphic"),
1592
+ schematic_graphic_id: getZodPrefixedIdWithDefault("schematic_graphic"),
1592
1593
  schematic_sheet_id: z93.string().optional(),
1593
- source_group_id: z93.string(),
1594
- is_subcircuit: z93.boolean().optional(),
1595
- subcircuit_id: z93.string().optional(),
1594
+ asset: asset.optional(),
1595
+ svg_content: z93.string().optional(),
1596
+ width: positiveFiniteDistance.optional(),
1597
+ height: positiveFiniteDistance.optional()
1598
+ }).describe(
1599
+ "References a graphic asset or inline SVG content with optional centered layout bounds on a schematic sheet"
1600
+ ).superRefine(({ asset: asset2, svg_content }, ctx) => {
1601
+ if (asset2 === void 0 && svg_content === void 0) {
1602
+ ctx.addIssue({
1603
+ code: z93.ZodIssueCode.custom,
1604
+ message: "At least one of asset or svg_content is required"
1605
+ });
1606
+ }
1607
+ });
1608
+ expectTypesMatch(true);
1609
+
1610
+ // src/schematic/schematic_group.ts
1611
+ import { z as z94 } from "zod";
1612
+ var schematic_group = z94.object({
1613
+ type: z94.literal("schematic_group"),
1614
+ schematic_group_id: getZodPrefixedIdWithDefault("schematic_group"),
1615
+ schematic_sheet_id: z94.string().optional(),
1616
+ source_group_id: z94.string(),
1617
+ is_subcircuit: z94.boolean().optional(),
1618
+ subcircuit_id: z94.string().optional(),
1596
1619
  width: length,
1597
1620
  height: length,
1598
1621
  center: point,
1599
- schematic_component_ids: z93.array(z93.string()),
1600
- show_as_schematic_box: z93.boolean().optional(),
1601
- name: z93.string().optional(),
1602
- description: z93.string().optional()
1622
+ schematic_component_ids: z94.array(z94.string()),
1623
+ show_as_schematic_box: z94.boolean().optional(),
1624
+ name: z94.string().optional(),
1625
+ description: z94.string().optional()
1603
1626
  }).describe("Defines a group of components on the schematic");
1604
1627
  expectTypesMatch(true);
1605
1628
 
1606
1629
  // src/schematic/schematic_table.ts
1607
- import { z as z94 } from "zod";
1608
- var schematic_table = z94.object({
1609
- type: z94.literal("schematic_table"),
1630
+ import { z as z95 } from "zod";
1631
+ var schematic_table = z95.object({
1632
+ type: z95.literal("schematic_table"),
1610
1633
  schematic_table_id: getZodPrefixedIdWithDefault("schematic_table"),
1611
- schematic_sheet_id: z94.string().optional(),
1634
+ schematic_sheet_id: z95.string().optional(),
1612
1635
  anchor_position: point,
1613
- column_widths: z94.array(distance),
1614
- row_heights: z94.array(distance),
1636
+ column_widths: z95.array(distance),
1637
+ row_heights: z95.array(distance),
1615
1638
  cell_padding: distance.optional(),
1616
1639
  border_width: distance.optional(),
1617
- subcircuit_id: z94.string().optional(),
1618
- schematic_component_id: z94.string().optional(),
1640
+ subcircuit_id: z95.string().optional(),
1641
+ schematic_component_id: z95.string().optional(),
1619
1642
  anchor: ninePointAnchor.optional()
1620
1643
  }).describe("Defines a table on the schematic");
1621
1644
  expectTypesMatch(true);
1622
1645
 
1623
1646
  // src/schematic/schematic_table_cell.ts
1624
- import { z as z95 } from "zod";
1625
- var schematic_table_cell = z95.object({
1626
- type: z95.literal("schematic_table_cell"),
1647
+ import { z as z96 } from "zod";
1648
+ var schematic_table_cell = z96.object({
1649
+ type: z96.literal("schematic_table_cell"),
1627
1650
  schematic_table_cell_id: getZodPrefixedIdWithDefault(
1628
1651
  "schematic_table_cell"
1629
1652
  ),
1630
- schematic_sheet_id: z95.string().optional(),
1631
- schematic_table_id: z95.string(),
1632
- start_row_index: z95.number(),
1633
- end_row_index: z95.number(),
1634
- start_column_index: z95.number(),
1635
- end_column_index: z95.number(),
1636
- text: z95.string().optional(),
1653
+ schematic_sheet_id: z96.string().optional(),
1654
+ schematic_table_id: z96.string(),
1655
+ start_row_index: z96.number(),
1656
+ end_row_index: z96.number(),
1657
+ start_column_index: z96.number(),
1658
+ end_column_index: z96.number(),
1659
+ text: z96.string().optional(),
1637
1660
  center: point,
1638
1661
  width: distance,
1639
1662
  height: distance,
1640
- horizontal_align: z95.enum(["left", "center", "right"]).optional(),
1641
- vertical_align: z95.enum(["top", "middle", "bottom"]).optional(),
1663
+ horizontal_align: z96.enum(["left", "center", "right"]).optional(),
1664
+ vertical_align: z96.enum(["top", "middle", "bottom"]).optional(),
1642
1665
  font_size: distance.optional(),
1643
- subcircuit_id: z95.string().optional()
1666
+ subcircuit_id: z96.string().optional()
1644
1667
  }).describe("Defines a cell within a schematic_table");
1645
1668
  expectTypesMatch(true);
1646
1669
 
1647
1670
  // src/schematic/schematic_sheet.ts
1648
- import { z as z96 } from "zod";
1649
- var schematic_sheet_size = z96.enum(["a4", "ansi_b"]);
1650
- var schematic_sheet = z96.object({
1651
- type: z96.literal("schematic_sheet"),
1671
+ import { z as z97 } from "zod";
1672
+ var schematic_sheet_size = z97.enum(["a4", "ansi_b"]);
1673
+ var schematic_sheet = z97.object({
1674
+ type: z97.literal("schematic_sheet"),
1652
1675
  schematic_sheet_id: getZodPrefixedIdWithDefault("schematic_sheet"),
1653
- name: z96.string().optional(),
1654
- sheet_index: z96.number().optional(),
1676
+ name: z97.string().optional(),
1677
+ sheet_index: z97.number().optional(),
1655
1678
  sheet_size: schematic_sheet_size.optional(),
1656
- sheet_width: z96.number().positive().optional(),
1657
- sheet_height: z96.number().positive().optional(),
1658
- subcircuit_id: z96.string().optional(),
1659
- outline_color: z96.string().optional()
1679
+ sheet_width: z97.number().positive().optional(),
1680
+ sheet_height: z97.number().positive().optional(),
1681
+ subcircuit_id: z97.string().optional(),
1682
+ outline_color: z97.string().optional()
1660
1683
  }).describe(
1661
1684
  "Defines a schematic sheet or page that components can be placed on"
1662
1685
  );
1663
1686
  expectTypesMatch(true);
1664
1687
 
1665
1688
  // src/pcb/properties/brep.ts
1666
- import { z as z97 } from "zod";
1667
- var point_with_bulge = z97.object({
1689
+ import { z as z98 } from "zod";
1690
+ var point_with_bulge = z98.object({
1668
1691
  x: distance,
1669
1692
  y: distance,
1670
- bulge: z97.number().optional()
1693
+ bulge: z98.number().optional()
1671
1694
  });
1672
1695
  expectTypesMatch(true);
1673
- var ring = z97.object({
1674
- vertices: z97.array(point_with_bulge)
1696
+ var ring = z98.object({
1697
+ vertices: z98.array(point_with_bulge)
1675
1698
  });
1676
1699
  expectTypesMatch(true);
1677
- var brep_shape = z97.object({
1700
+ var brep_shape = z98.object({
1678
1701
  outer_ring: ring,
1679
- inner_rings: z97.array(ring).default([])
1702
+ inner_rings: z98.array(ring).default([])
1680
1703
  });
1681
1704
  expectTypesMatch(true);
1682
1705
 
1683
1706
  // src/pcb/properties/insertion_direction.ts
1684
- import { z as z98 } from "zod";
1707
+ import { z as z99 } from "zod";
1685
1708
  var insertionDirectionToCanonical = {
1686
1709
  from_left: "from_left",
1687
1710
  from_right: "from_right",
@@ -1708,7 +1731,7 @@ var insertionDirectionToVector = {
1708
1731
  from_above: { x: 0, y: 0, z: 1 },
1709
1732
  from_below: { x: 0, y: 0, z: -1 }
1710
1733
  };
1711
- var insertion_direction = z98.enum([
1734
+ var insertion_direction = z99.enum([
1712
1735
  "from_left",
1713
1736
  "from_right",
1714
1737
  "from_top",
@@ -1733,8 +1756,8 @@ expectTypesMatch(
1733
1756
  );
1734
1757
 
1735
1758
  // src/pcb/properties/pcb_pin1_location.ts
1736
- import { z as z99 } from "zod";
1737
- var pcb_pin1_location = z99.enum([
1759
+ import { z as z100 } from "zod";
1760
+ var pcb_pin1_location = z100.enum([
1738
1761
  "leftside_top",
1739
1762
  "leftside_bottom",
1740
1763
  "rightside_top",
@@ -1771,31 +1794,31 @@ var getRotationBetweenPcbPin1Locations = (from, to) => {
1771
1794
  };
1772
1795
 
1773
1796
  // src/pcb/properties/pcb_route_hints.ts
1774
- import { z as z100 } from "zod";
1775
- var pcb_route_hint = z100.object({
1797
+ import { z as z101 } from "zod";
1798
+ var pcb_route_hint = z101.object({
1776
1799
  x: distance,
1777
1800
  y: distance,
1778
- via: z100.boolean().optional(),
1801
+ via: z101.boolean().optional(),
1779
1802
  via_to_layer: layer_ref.optional()
1780
1803
  });
1781
- var pcb_route_hints = z100.array(pcb_route_hint);
1804
+ var pcb_route_hints = z101.array(pcb_route_hint);
1782
1805
  expectTypesMatch(true);
1783
1806
  expectTypesMatch(true);
1784
1807
 
1785
1808
  // src/pcb/properties/route_hint_point.ts
1786
- import { z as z101 } from "zod";
1787
- var route_hint_point = z101.object({
1809
+ import { z as z102 } from "zod";
1810
+ var route_hint_point = z102.object({
1788
1811
  x: distance,
1789
1812
  y: distance,
1790
- via: z101.boolean().optional(),
1813
+ via: z102.boolean().optional(),
1791
1814
  to_layer: layer_ref.optional(),
1792
1815
  trace_width: distance.optional()
1793
1816
  });
1794
1817
  expectTypesMatch(true);
1795
1818
 
1796
1819
  // src/pcb/properties/manufacturing_drc_properties.ts
1797
- import { z as z102 } from "zod";
1798
- var manufacturing_drc_properties = z102.object({
1820
+ import { z as z103 } from "zod";
1821
+ var manufacturing_drc_properties = z103.object({
1799
1822
  min_trace_width: length.optional(),
1800
1823
  min_board_edge_clearance: length.optional(),
1801
1824
  min_via_hole_edge_to_via_hole_edge_clearance: length.optional(),
@@ -1810,27 +1833,27 @@ var manufacturing_drc_properties = z102.object({
1810
1833
  });
1811
1834
 
1812
1835
  // src/pcb/pcb_component.ts
1813
- import { z as z103 } from "zod";
1814
- var pcb_component = z103.object({
1815
- type: z103.literal("pcb_component"),
1836
+ import { z as z104 } from "zod";
1837
+ var pcb_component = z104.object({
1838
+ type: z104.literal("pcb_component"),
1816
1839
  pcb_component_id: getZodPrefixedIdWithDefault("pcb_component"),
1817
- source_component_id: z103.string(),
1840
+ source_component_id: z104.string(),
1818
1841
  center: point,
1819
1842
  layer: layer_ref,
1820
1843
  rotation,
1821
- display_offset_x: z103.string().optional().describe(
1844
+ display_offset_x: z104.string().optional().describe(
1822
1845
  "How to display the x offset for this part, usually corresponding with how the user specified it"
1823
1846
  ),
1824
- display_offset_y: z103.string().optional().describe(
1847
+ display_offset_y: z104.string().optional().describe(
1825
1848
  "How to display the y offset for this part, usually corresponding with how the user specified it"
1826
1849
  ),
1827
1850
  width: length,
1828
1851
  height: length,
1829
- do_not_place: z103.boolean().optional(),
1830
- is_allowed_to_be_off_board: z103.boolean().optional(),
1831
- subcircuit_id: z103.string().optional(),
1832
- pcb_group_id: z103.string().optional(),
1833
- position_mode: z103.enum([
1852
+ do_not_place: z104.boolean().optional(),
1853
+ is_allowed_to_be_off_board: z104.boolean().optional(),
1854
+ subcircuit_id: z104.string().optional(),
1855
+ pcb_group_id: z104.string().optional(),
1856
+ position_mode: z104.enum([
1834
1857
  "packed",
1835
1858
  "relative_to_group_anchor",
1836
1859
  "relative_to_another_component",
@@ -1838,48 +1861,48 @@ var pcb_component = z103.object({
1838
1861
  ]).optional(),
1839
1862
  anchor_position: point.optional(),
1840
1863
  anchor_alignment: ninePointAnchor.optional(),
1841
- positioned_relative_to_pcb_group_id: z103.string().optional(),
1842
- positioned_relative_to_pcb_board_id: z103.string().optional(),
1864
+ positioned_relative_to_pcb_group_id: z104.string().optional(),
1865
+ positioned_relative_to_pcb_board_id: z104.string().optional(),
1843
1866
  cable_insertion_center: point.optional(),
1844
1867
  insertion_direction: insertion_direction.optional(),
1845
1868
  pin1_location: pcb_pin1_location.optional().describe(
1846
1869
  "Location of pin 1 on the unrotated, top-view component footprint"
1847
1870
  ),
1848
- supplier_pin1_location_map: z103.record(supplier_name, pcb_pin1_location).optional().describe(
1871
+ supplier_pin1_location_map: z104.record(supplier_name, pcb_pin1_location).optional().describe(
1849
1872
  "Pin 1 location for each supplier's unrotated, top-view footprint"
1850
1873
  ),
1851
- metadata: z103.object({
1874
+ metadata: z104.object({
1852
1875
  kicad_footprint: kicadFootprintMetadata.optional()
1853
1876
  }).optional(),
1854
- obstructs_within_bounds: z103.boolean().default(true).describe(
1877
+ obstructs_within_bounds: z104.boolean().default(true).describe(
1855
1878
  "Does this component take up all the space within its bounds on a layer. This is generally true except for when separated pin headers are being represented by a single component (in which case, chips can be placed between the pin headers) or for tall modules where chips fit underneath"
1856
1879
  )
1857
1880
  }).describe("Defines a component on the PCB");
1858
1881
  expectTypesMatch(true);
1859
1882
 
1860
1883
  // src/pcb/pcb_debug_object.ts
1861
- import { z as z104 } from "zod";
1862
- var pcb_debug_object_base = z104.object({
1863
- type: z104.literal("pcb_debug_object"),
1884
+ import { z as z105 } from "zod";
1885
+ var pcb_debug_object_base = z105.object({
1886
+ type: z105.literal("pcb_debug_object"),
1864
1887
  pcb_debug_object_id: getZodPrefixedIdWithDefault("pcb_debug_object"),
1865
- label: z104.string().optional(),
1866
- subcircuit_id: z104.string().optional()
1888
+ label: z105.string().optional(),
1889
+ subcircuit_id: z105.string().optional()
1867
1890
  });
1868
1891
  var pcb_debug_rect = pcb_debug_object_base.extend({
1869
- shape: z104.literal("rect"),
1892
+ shape: z105.literal("rect"),
1870
1893
  center: point,
1871
1894
  size
1872
1895
  });
1873
1896
  var pcb_debug_line = pcb_debug_object_base.extend({
1874
- shape: z104.literal("line"),
1897
+ shape: z105.literal("line"),
1875
1898
  start: point,
1876
1899
  end: point
1877
1900
  });
1878
1901
  var pcb_debug_point = pcb_debug_object_base.extend({
1879
- shape: z104.literal("point"),
1902
+ shape: z105.literal("point"),
1880
1903
  center: point
1881
1904
  });
1882
- var pcb_debug_object = z104.discriminatedUnion("shape", [
1905
+ var pcb_debug_object = z105.discriminatedUnion("shape", [
1883
1906
  pcb_debug_rect,
1884
1907
  pcb_debug_line,
1885
1908
  pcb_debug_point
@@ -1887,109 +1910,109 @@ var pcb_debug_object = z104.discriminatedUnion("shape", [
1887
1910
  expectTypesMatch(true);
1888
1911
 
1889
1912
  // src/pcb/pcb_hole.ts
1890
- import { z as z105 } from "zod";
1891
- var pcb_hole_circle = z105.object({
1892
- type: z105.literal("pcb_hole"),
1913
+ import { z as z106 } from "zod";
1914
+ var pcb_hole_circle = z106.object({
1915
+ type: z106.literal("pcb_hole"),
1893
1916
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
1894
- pcb_group_id: z105.string().optional(),
1895
- subcircuit_id: z105.string().optional(),
1896
- pcb_component_id: z105.string().optional(),
1897
- hole_shape: z105.literal("circle"),
1898
- hole_diameter: z105.number(),
1917
+ pcb_group_id: z106.string().optional(),
1918
+ subcircuit_id: z106.string().optional(),
1919
+ pcb_component_id: z106.string().optional(),
1920
+ hole_shape: z106.literal("circle"),
1921
+ hole_diameter: z106.number(),
1899
1922
  x: distance,
1900
1923
  y: distance,
1901
- is_covered_with_solder_mask: z105.boolean().optional(),
1902
- soldermask_margin: z105.number().optional()
1924
+ is_covered_with_solder_mask: z106.boolean().optional(),
1925
+ soldermask_margin: z106.number().optional()
1903
1926
  });
1904
1927
  var pcb_hole_circle_shape = pcb_hole_circle.describe(
1905
1928
  "Defines a circular hole on the PCB"
1906
1929
  );
1907
1930
  expectTypesMatch(true);
1908
- var pcb_hole_rect = z105.object({
1909
- type: z105.literal("pcb_hole"),
1931
+ var pcb_hole_rect = z106.object({
1932
+ type: z106.literal("pcb_hole"),
1910
1933
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
1911
- pcb_group_id: z105.string().optional(),
1912
- subcircuit_id: z105.string().optional(),
1913
- pcb_component_id: z105.string().optional(),
1914
- hole_shape: z105.literal("rect"),
1915
- hole_width: z105.number(),
1916
- hole_height: z105.number(),
1934
+ pcb_group_id: z106.string().optional(),
1935
+ subcircuit_id: z106.string().optional(),
1936
+ pcb_component_id: z106.string().optional(),
1937
+ hole_shape: z106.literal("rect"),
1938
+ hole_width: z106.number(),
1939
+ hole_height: z106.number(),
1917
1940
  x: distance,
1918
1941
  y: distance,
1919
- is_covered_with_solder_mask: z105.boolean().optional(),
1920
- soldermask_margin: z105.number().optional()
1942
+ is_covered_with_solder_mask: z106.boolean().optional(),
1943
+ soldermask_margin: z106.number().optional()
1921
1944
  });
1922
1945
  var pcb_hole_rect_shape = pcb_hole_rect.describe(
1923
1946
  "Defines a rectangular (square-capable) hole on the PCB. Use equal width/height for square."
1924
1947
  );
1925
1948
  expectTypesMatch(true);
1926
- var pcb_hole_circle_or_square = z105.object({
1927
- type: z105.literal("pcb_hole"),
1949
+ var pcb_hole_circle_or_square = z106.object({
1950
+ type: z106.literal("pcb_hole"),
1928
1951
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
1929
- pcb_group_id: z105.string().optional(),
1930
- subcircuit_id: z105.string().optional(),
1931
- pcb_component_id: z105.string().optional(),
1932
- hole_shape: z105.enum(["circle", "square"]),
1933
- hole_diameter: z105.number(),
1952
+ pcb_group_id: z106.string().optional(),
1953
+ subcircuit_id: z106.string().optional(),
1954
+ pcb_component_id: z106.string().optional(),
1955
+ hole_shape: z106.enum(["circle", "square"]),
1956
+ hole_diameter: z106.number(),
1934
1957
  x: distance,
1935
1958
  y: distance,
1936
- is_covered_with_solder_mask: z105.boolean().optional(),
1937
- soldermask_margin: z105.number().optional()
1959
+ is_covered_with_solder_mask: z106.boolean().optional(),
1960
+ soldermask_margin: z106.number().optional()
1938
1961
  });
1939
1962
  var pcb_hole_circle_or_square_shape = pcb_hole_circle_or_square.describe(
1940
1963
  "Defines a circular or square hole on the PCB"
1941
1964
  );
1942
1965
  expectTypesMatch(true);
1943
- var pcb_hole_oval = z105.object({
1944
- type: z105.literal("pcb_hole"),
1966
+ var pcb_hole_oval = z106.object({
1967
+ type: z106.literal("pcb_hole"),
1945
1968
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
1946
- pcb_group_id: z105.string().optional(),
1947
- subcircuit_id: z105.string().optional(),
1948
- pcb_component_id: z105.string().optional(),
1949
- hole_shape: z105.literal("oval"),
1950
- hole_width: z105.number(),
1951
- hole_height: z105.number(),
1969
+ pcb_group_id: z106.string().optional(),
1970
+ subcircuit_id: z106.string().optional(),
1971
+ pcb_component_id: z106.string().optional(),
1972
+ hole_shape: z106.literal("oval"),
1973
+ hole_width: z106.number(),
1974
+ hole_height: z106.number(),
1952
1975
  x: distance,
1953
1976
  y: distance,
1954
- is_covered_with_solder_mask: z105.boolean().optional(),
1955
- soldermask_margin: z105.number().optional()
1977
+ is_covered_with_solder_mask: z106.boolean().optional(),
1978
+ soldermask_margin: z106.number().optional()
1956
1979
  });
1957
1980
  var pcb_hole_oval_shape = pcb_hole_oval.describe(
1958
1981
  "Defines an oval hole on the PCB"
1959
1982
  );
1960
1983
  expectTypesMatch(true);
1961
- var pcb_hole_pill = z105.object({
1962
- type: z105.literal("pcb_hole"),
1984
+ var pcb_hole_pill = z106.object({
1985
+ type: z106.literal("pcb_hole"),
1963
1986
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
1964
- pcb_group_id: z105.string().optional(),
1965
- subcircuit_id: z105.string().optional(),
1966
- pcb_component_id: z105.string().optional(),
1967
- hole_shape: z105.literal("pill"),
1968
- hole_width: z105.number(),
1969
- hole_height: z105.number(),
1987
+ pcb_group_id: z106.string().optional(),
1988
+ subcircuit_id: z106.string().optional(),
1989
+ pcb_component_id: z106.string().optional(),
1990
+ hole_shape: z106.literal("pill"),
1991
+ hole_width: z106.number(),
1992
+ hole_height: z106.number(),
1970
1993
  x: distance,
1971
1994
  y: distance,
1972
- is_covered_with_solder_mask: z105.boolean().optional(),
1973
- soldermask_margin: z105.number().optional()
1995
+ is_covered_with_solder_mask: z106.boolean().optional(),
1996
+ soldermask_margin: z106.number().optional()
1974
1997
  });
1975
1998
  var pcb_hole_pill_shape = pcb_hole_pill.describe(
1976
1999
  "Defines a pill-shaped hole on the PCB"
1977
2000
  );
1978
2001
  expectTypesMatch(true);
1979
- var pcb_hole_rotated_pill = z105.object({
1980
- type: z105.literal("pcb_hole"),
2002
+ var pcb_hole_rotated_pill = z106.object({
2003
+ type: z106.literal("pcb_hole"),
1981
2004
  pcb_hole_id: getZodPrefixedIdWithDefault("pcb_hole"),
1982
- pcb_group_id: z105.string().optional(),
1983
- subcircuit_id: z105.string().optional(),
1984
- pcb_component_id: z105.string().optional(),
1985
- hole_shape: z105.literal("rotated_pill"),
1986
- hole_width: z105.number(),
1987
- hole_height: z105.number(),
2005
+ pcb_group_id: z106.string().optional(),
2006
+ subcircuit_id: z106.string().optional(),
2007
+ pcb_component_id: z106.string().optional(),
2008
+ hole_shape: z106.literal("rotated_pill"),
2009
+ hole_width: z106.number(),
2010
+ hole_height: z106.number(),
1988
2011
  x: distance,
1989
2012
  y: distance,
1990
2013
  ccw_rotation: rotation,
1991
- is_covered_with_solder_mask: z105.boolean().optional(),
1992
- soldermask_margin: z105.number().optional()
2014
+ is_covered_with_solder_mask: z106.boolean().optional(),
2015
+ soldermask_margin: z106.number().optional()
1993
2016
  });
1994
2017
  var pcb_hole_rotated_pill_shape = pcb_hole_rotated_pill.describe(
1995
2018
  "Defines a rotated pill-shaped hole on the PCB"
@@ -1998,147 +2021,147 @@ expectTypesMatch(true);
1998
2021
  var pcb_hole = pcb_hole_circle_or_square.or(pcb_hole_oval).or(pcb_hole_pill).or(pcb_hole_rotated_pill).or(pcb_hole_circle).or(pcb_hole_rect);
1999
2022
 
2000
2023
  // src/pcb/pcb_plated_hole.ts
2001
- import { z as z106 } from "zod";
2002
- var pcb_plated_hole_circle = z106.object({
2003
- type: z106.literal("pcb_plated_hole"),
2004
- shape: z106.literal("circle"),
2005
- pcb_group_id: z106.string().optional(),
2006
- subcircuit_id: z106.string().optional(),
2007
- outer_diameter: z106.number(),
2008
- hole_diameter: z106.number(),
2009
- is_covered_with_solder_mask: z106.boolean().optional(),
2024
+ import { z as z107 } from "zod";
2025
+ var pcb_plated_hole_circle = z107.object({
2026
+ type: z107.literal("pcb_plated_hole"),
2027
+ shape: z107.literal("circle"),
2028
+ pcb_group_id: z107.string().optional(),
2029
+ subcircuit_id: z107.string().optional(),
2030
+ outer_diameter: z107.number(),
2031
+ hole_diameter: z107.number(),
2032
+ is_covered_with_solder_mask: z107.boolean().optional(),
2010
2033
  x: distance,
2011
2034
  y: distance,
2012
- layers: z106.array(layer_ref),
2013
- port_hints: z106.array(z106.string()).optional(),
2014
- pcb_component_id: z106.string().optional(),
2015
- pcb_port_id: z106.string().optional(),
2035
+ layers: z107.array(layer_ref),
2036
+ port_hints: z107.array(z107.string()).optional(),
2037
+ pcb_component_id: z107.string().optional(),
2038
+ pcb_port_id: z107.string().optional(),
2016
2039
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole"),
2017
- soldermask_margin: z106.number().optional()
2040
+ soldermask_margin: z107.number().optional()
2018
2041
  });
2019
- var pcb_plated_hole_oval = z106.object({
2020
- type: z106.literal("pcb_plated_hole"),
2021
- shape: z106.enum(["oval", "pill"]),
2022
- pcb_group_id: z106.string().optional(),
2023
- subcircuit_id: z106.string().optional(),
2024
- outer_width: z106.number(),
2025
- outer_height: z106.number(),
2026
- hole_width: z106.number(),
2027
- hole_height: z106.number(),
2028
- is_covered_with_solder_mask: z106.boolean().optional(),
2042
+ var pcb_plated_hole_oval = z107.object({
2043
+ type: z107.literal("pcb_plated_hole"),
2044
+ shape: z107.enum(["oval", "pill"]),
2045
+ pcb_group_id: z107.string().optional(),
2046
+ subcircuit_id: z107.string().optional(),
2047
+ outer_width: z107.number(),
2048
+ outer_height: z107.number(),
2049
+ hole_width: z107.number(),
2050
+ hole_height: z107.number(),
2051
+ is_covered_with_solder_mask: z107.boolean().optional(),
2029
2052
  x: distance,
2030
2053
  y: distance,
2031
2054
  ccw_rotation: rotation,
2032
- layers: z106.array(layer_ref),
2033
- port_hints: z106.array(z106.string()).optional(),
2034
- pcb_component_id: z106.string().optional(),
2035
- pcb_port_id: z106.string().optional(),
2055
+ layers: z107.array(layer_ref),
2056
+ port_hints: z107.array(z107.string()).optional(),
2057
+ pcb_component_id: z107.string().optional(),
2058
+ pcb_port_id: z107.string().optional(),
2036
2059
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole"),
2037
- soldermask_margin: z106.number().optional()
2060
+ soldermask_margin: z107.number().optional()
2038
2061
  });
2039
- var pcb_circular_hole_with_rect_pad = z106.object({
2040
- type: z106.literal("pcb_plated_hole"),
2041
- shape: z106.literal("circular_hole_with_rect_pad"),
2042
- pcb_group_id: z106.string().optional(),
2043
- subcircuit_id: z106.string().optional(),
2044
- hole_shape: z106.literal("circle"),
2045
- pad_shape: z106.literal("rect"),
2046
- hole_diameter: z106.number(),
2047
- rect_pad_width: z106.number(),
2048
- rect_pad_height: z106.number(),
2049
- rect_border_radius: z106.number().optional(),
2062
+ var pcb_circular_hole_with_rect_pad = z107.object({
2063
+ type: z107.literal("pcb_plated_hole"),
2064
+ shape: z107.literal("circular_hole_with_rect_pad"),
2065
+ pcb_group_id: z107.string().optional(),
2066
+ subcircuit_id: z107.string().optional(),
2067
+ hole_shape: z107.literal("circle"),
2068
+ pad_shape: z107.literal("rect"),
2069
+ hole_diameter: z107.number(),
2070
+ rect_pad_width: z107.number(),
2071
+ rect_pad_height: z107.number(),
2072
+ rect_border_radius: z107.number().optional(),
2050
2073
  hole_offset_x: distance.default(0),
2051
2074
  hole_offset_y: distance.default(0),
2052
- is_covered_with_solder_mask: z106.boolean().optional(),
2075
+ is_covered_with_solder_mask: z107.boolean().optional(),
2053
2076
  x: distance,
2054
2077
  y: distance,
2055
- layers: z106.array(layer_ref),
2056
- port_hints: z106.array(z106.string()).optional(),
2057
- pcb_component_id: z106.string().optional(),
2058
- pcb_port_id: z106.string().optional(),
2078
+ layers: z107.array(layer_ref),
2079
+ port_hints: z107.array(z107.string()).optional(),
2080
+ pcb_component_id: z107.string().optional(),
2081
+ pcb_port_id: z107.string().optional(),
2059
2082
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole"),
2060
- soldermask_margin: z106.number().optional(),
2083
+ soldermask_margin: z107.number().optional(),
2061
2084
  rect_ccw_rotation: rotation.optional()
2062
2085
  });
2063
- var pcb_pill_hole_with_rect_pad = z106.object({
2064
- type: z106.literal("pcb_plated_hole"),
2065
- shape: z106.literal("pill_hole_with_rect_pad"),
2066
- pcb_group_id: z106.string().optional(),
2067
- subcircuit_id: z106.string().optional(),
2068
- hole_shape: z106.literal("pill"),
2069
- pad_shape: z106.literal("rect"),
2070
- hole_width: z106.number(),
2071
- hole_height: z106.number(),
2072
- rect_pad_width: z106.number(),
2073
- rect_pad_height: z106.number(),
2074
- rect_border_radius: z106.number().optional(),
2086
+ var pcb_pill_hole_with_rect_pad = z107.object({
2087
+ type: z107.literal("pcb_plated_hole"),
2088
+ shape: z107.literal("pill_hole_with_rect_pad"),
2089
+ pcb_group_id: z107.string().optional(),
2090
+ subcircuit_id: z107.string().optional(),
2091
+ hole_shape: z107.literal("pill"),
2092
+ pad_shape: z107.literal("rect"),
2093
+ hole_width: z107.number(),
2094
+ hole_height: z107.number(),
2095
+ rect_pad_width: z107.number(),
2096
+ rect_pad_height: z107.number(),
2097
+ rect_border_radius: z107.number().optional(),
2075
2098
  hole_offset_x: distance.default(0),
2076
2099
  hole_offset_y: distance.default(0),
2077
- is_covered_with_solder_mask: z106.boolean().optional(),
2100
+ is_covered_with_solder_mask: z107.boolean().optional(),
2078
2101
  x: distance,
2079
2102
  y: distance,
2080
- layers: z106.array(layer_ref),
2081
- port_hints: z106.array(z106.string()).optional(),
2082
- pcb_component_id: z106.string().optional(),
2083
- pcb_port_id: z106.string().optional(),
2103
+ layers: z107.array(layer_ref),
2104
+ port_hints: z107.array(z107.string()).optional(),
2105
+ pcb_component_id: z107.string().optional(),
2106
+ pcb_port_id: z107.string().optional(),
2084
2107
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole"),
2085
- soldermask_margin: z106.number().optional()
2108
+ soldermask_margin: z107.number().optional()
2086
2109
  });
2087
- var pcb_rotated_pill_hole_with_rect_pad = z106.object({
2088
- type: z106.literal("pcb_plated_hole"),
2089
- shape: z106.literal("rotated_pill_hole_with_rect_pad"),
2090
- pcb_group_id: z106.string().optional(),
2091
- subcircuit_id: z106.string().optional(),
2092
- hole_shape: z106.literal("rotated_pill"),
2093
- pad_shape: z106.literal("rect"),
2094
- hole_width: z106.number(),
2095
- hole_height: z106.number(),
2110
+ var pcb_rotated_pill_hole_with_rect_pad = z107.object({
2111
+ type: z107.literal("pcb_plated_hole"),
2112
+ shape: z107.literal("rotated_pill_hole_with_rect_pad"),
2113
+ pcb_group_id: z107.string().optional(),
2114
+ subcircuit_id: z107.string().optional(),
2115
+ hole_shape: z107.literal("rotated_pill"),
2116
+ pad_shape: z107.literal("rect"),
2117
+ hole_width: z107.number(),
2118
+ hole_height: z107.number(),
2096
2119
  hole_ccw_rotation: rotation,
2097
- rect_pad_width: z106.number(),
2098
- rect_pad_height: z106.number(),
2099
- rect_border_radius: z106.number().optional(),
2120
+ rect_pad_width: z107.number(),
2121
+ rect_pad_height: z107.number(),
2122
+ rect_border_radius: z107.number().optional(),
2100
2123
  rect_ccw_rotation: rotation,
2101
2124
  hole_offset_x: distance.default(0),
2102
2125
  hole_offset_y: distance.default(0),
2103
- is_covered_with_solder_mask: z106.boolean().optional(),
2126
+ is_covered_with_solder_mask: z107.boolean().optional(),
2104
2127
  x: distance,
2105
2128
  y: distance,
2106
- layers: z106.array(layer_ref),
2107
- port_hints: z106.array(z106.string()).optional(),
2108
- pcb_component_id: z106.string().optional(),
2109
- pcb_port_id: z106.string().optional(),
2129
+ layers: z107.array(layer_ref),
2130
+ port_hints: z107.array(z107.string()).optional(),
2131
+ pcb_component_id: z107.string().optional(),
2132
+ pcb_port_id: z107.string().optional(),
2110
2133
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole"),
2111
- soldermask_margin: z106.number().optional()
2134
+ soldermask_margin: z107.number().optional()
2112
2135
  });
2113
- var pcb_hole_with_polygon_pad = z106.object({
2114
- type: z106.literal("pcb_plated_hole"),
2115
- shape: z106.literal("hole_with_polygon_pad"),
2116
- pcb_group_id: z106.string().optional(),
2117
- subcircuit_id: z106.string().optional(),
2118
- hole_shape: z106.enum(["circle", "oval", "pill", "rotated_pill"]),
2119
- hole_diameter: z106.number().optional(),
2120
- hole_width: z106.number().optional(),
2121
- hole_height: z106.number().optional(),
2122
- pad_outline: z106.array(
2123
- z106.object({
2136
+ var pcb_hole_with_polygon_pad = z107.object({
2137
+ type: z107.literal("pcb_plated_hole"),
2138
+ shape: z107.literal("hole_with_polygon_pad"),
2139
+ pcb_group_id: z107.string().optional(),
2140
+ subcircuit_id: z107.string().optional(),
2141
+ hole_shape: z107.enum(["circle", "oval", "pill", "rotated_pill"]),
2142
+ hole_diameter: z107.number().optional(),
2143
+ hole_width: z107.number().optional(),
2144
+ hole_height: z107.number().optional(),
2145
+ pad_outline: z107.array(
2146
+ z107.object({
2124
2147
  x: distance,
2125
2148
  y: distance
2126
2149
  })
2127
2150
  ).min(3),
2128
2151
  hole_offset_x: distance.default(0),
2129
2152
  hole_offset_y: distance.default(0),
2130
- is_covered_with_solder_mask: z106.boolean().optional(),
2153
+ is_covered_with_solder_mask: z107.boolean().optional(),
2131
2154
  x: distance,
2132
2155
  y: distance,
2133
- layers: z106.array(layer_ref),
2134
- port_hints: z106.array(z106.string()).optional(),
2135
- pcb_component_id: z106.string().optional(),
2136
- pcb_port_id: z106.string().optional(),
2156
+ layers: z107.array(layer_ref),
2157
+ port_hints: z107.array(z107.string()).optional(),
2158
+ pcb_component_id: z107.string().optional(),
2159
+ pcb_port_id: z107.string().optional(),
2137
2160
  pcb_plated_hole_id: getZodPrefixedIdWithDefault("pcb_plated_hole"),
2138
- soldermask_margin: z106.number().optional(),
2161
+ soldermask_margin: z107.number().optional(),
2139
2162
  ccw_rotation: rotation.optional()
2140
2163
  });
2141
- var pcb_plated_hole = z106.union([
2164
+ var pcb_plated_hole = z107.union([
2142
2165
  pcb_plated_hole_circle,
2143
2166
  pcb_plated_hole_oval,
2144
2167
  pcb_circular_hole_with_rect_pad,
@@ -2156,144 +2179,144 @@ expectTypesMatch(true);
2156
2179
  expectTypesMatch(true);
2157
2180
 
2158
2181
  // src/pcb/pcb_port.ts
2159
- import { z as z107 } from "zod";
2160
- var pcb_port = z107.object({
2161
- type: z107.literal("pcb_port"),
2182
+ import { z as z108 } from "zod";
2183
+ var pcb_port = z108.object({
2184
+ type: z108.literal("pcb_port"),
2162
2185
  pcb_port_id: getZodPrefixedIdWithDefault("pcb_port"),
2163
- pcb_group_id: z107.string().optional(),
2164
- subcircuit_id: z107.string().optional(),
2165
- source_port_id: z107.string(),
2166
- pcb_component_id: z107.string().optional(),
2186
+ pcb_group_id: z108.string().optional(),
2187
+ subcircuit_id: z108.string().optional(),
2188
+ source_port_id: z108.string(),
2189
+ pcb_component_id: z108.string().optional(),
2167
2190
  x: distance,
2168
2191
  y: distance,
2169
- layers: z107.array(layer_ref),
2170
- is_board_pinout: z107.boolean().optional()
2192
+ layers: z108.array(layer_ref),
2193
+ is_board_pinout: z108.boolean().optional()
2171
2194
  }).describe("Defines a port on the PCB");
2172
2195
  expectTypesMatch(true);
2173
2196
 
2174
2197
  // src/pcb/pcb_smtpad.ts
2175
- import { z as z108 } from "zod";
2176
- var pcb_smtpad_circle = z108.object({
2177
- type: z108.literal("pcb_smtpad"),
2178
- shape: z108.literal("circle"),
2198
+ import { z as z109 } from "zod";
2199
+ var pcb_smtpad_circle = z109.object({
2200
+ type: z109.literal("pcb_smtpad"),
2201
+ shape: z109.literal("circle"),
2179
2202
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
2180
- pcb_group_id: z108.string().optional(),
2181
- subcircuit_id: z108.string().optional(),
2203
+ pcb_group_id: z109.string().optional(),
2204
+ subcircuit_id: z109.string().optional(),
2182
2205
  x: distance,
2183
2206
  y: distance,
2184
- radius: z108.number(),
2207
+ radius: z109.number(),
2185
2208
  layer: layer_ref,
2186
- port_hints: z108.array(z108.string()).optional(),
2187
- pcb_component_id: z108.string().optional(),
2188
- pcb_port_id: z108.string().optional(),
2189
- is_covered_with_solder_mask: z108.boolean().optional(),
2190
- soldermask_margin: z108.number().optional(),
2191
- solderpaste_margin: z108.number().optional()
2209
+ port_hints: z109.array(z109.string()).optional(),
2210
+ pcb_component_id: z109.string().optional(),
2211
+ pcb_port_id: z109.string().optional(),
2212
+ is_covered_with_solder_mask: z109.boolean().optional(),
2213
+ soldermask_margin: z109.number().optional(),
2214
+ solderpaste_margin: z109.number().optional()
2192
2215
  });
2193
- var pcb_smtpad_rect = z108.object({
2194
- type: z108.literal("pcb_smtpad"),
2195
- shape: z108.literal("rect"),
2216
+ var pcb_smtpad_rect = z109.object({
2217
+ type: z109.literal("pcb_smtpad"),
2218
+ shape: z109.literal("rect"),
2196
2219
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
2197
- pcb_group_id: z108.string().optional(),
2198
- subcircuit_id: z108.string().optional(),
2220
+ pcb_group_id: z109.string().optional(),
2221
+ subcircuit_id: z109.string().optional(),
2199
2222
  x: distance,
2200
2223
  y: distance,
2201
- width: z108.number(),
2202
- height: z108.number(),
2203
- rect_border_radius: z108.number().optional(),
2204
- corner_radius: z108.number().optional(),
2224
+ width: z109.number(),
2225
+ height: z109.number(),
2226
+ rect_border_radius: z109.number().optional(),
2227
+ corner_radius: z109.number().optional(),
2205
2228
  layer: layer_ref,
2206
- port_hints: z108.array(z108.string()).optional(),
2207
- pcb_component_id: z108.string().optional(),
2208
- pcb_port_id: z108.string().optional(),
2209
- is_covered_with_solder_mask: z108.boolean().optional(),
2210
- soldermask_margin: z108.number().optional(),
2211
- soldermask_margin_left: z108.number().optional(),
2212
- soldermask_margin_top: z108.number().optional(),
2213
- soldermask_margin_right: z108.number().optional(),
2214
- soldermask_margin_bottom: z108.number().optional(),
2215
- solderpaste_margin: z108.number().optional()
2229
+ port_hints: z109.array(z109.string()).optional(),
2230
+ pcb_component_id: z109.string().optional(),
2231
+ pcb_port_id: z109.string().optional(),
2232
+ is_covered_with_solder_mask: z109.boolean().optional(),
2233
+ soldermask_margin: z109.number().optional(),
2234
+ soldermask_margin_left: z109.number().optional(),
2235
+ soldermask_margin_top: z109.number().optional(),
2236
+ soldermask_margin_right: z109.number().optional(),
2237
+ soldermask_margin_bottom: z109.number().optional(),
2238
+ solderpaste_margin: z109.number().optional()
2216
2239
  });
2217
- var pcb_smtpad_rotated_rect = z108.object({
2218
- type: z108.literal("pcb_smtpad"),
2219
- shape: z108.literal("rotated_rect"),
2240
+ var pcb_smtpad_rotated_rect = z109.object({
2241
+ type: z109.literal("pcb_smtpad"),
2242
+ shape: z109.literal("rotated_rect"),
2220
2243
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
2221
- pcb_group_id: z108.string().optional(),
2222
- subcircuit_id: z108.string().optional(),
2244
+ pcb_group_id: z109.string().optional(),
2245
+ subcircuit_id: z109.string().optional(),
2223
2246
  x: distance,
2224
2247
  y: distance,
2225
- width: z108.number(),
2226
- height: z108.number(),
2227
- rect_border_radius: z108.number().optional(),
2228
- corner_radius: z108.number().optional(),
2248
+ width: z109.number(),
2249
+ height: z109.number(),
2250
+ rect_border_radius: z109.number().optional(),
2251
+ corner_radius: z109.number().optional(),
2229
2252
  ccw_rotation: rotation,
2230
2253
  layer: layer_ref,
2231
- port_hints: z108.array(z108.string()).optional(),
2232
- pcb_component_id: z108.string().optional(),
2233
- pcb_port_id: z108.string().optional(),
2234
- is_covered_with_solder_mask: z108.boolean().optional(),
2235
- soldermask_margin: z108.number().optional(),
2236
- soldermask_margin_left: z108.number().optional(),
2237
- soldermask_margin_top: z108.number().optional(),
2238
- soldermask_margin_right: z108.number().optional(),
2239
- soldermask_margin_bottom: z108.number().optional(),
2240
- solderpaste_margin: z108.number().optional()
2254
+ port_hints: z109.array(z109.string()).optional(),
2255
+ pcb_component_id: z109.string().optional(),
2256
+ pcb_port_id: z109.string().optional(),
2257
+ is_covered_with_solder_mask: z109.boolean().optional(),
2258
+ soldermask_margin: z109.number().optional(),
2259
+ soldermask_margin_left: z109.number().optional(),
2260
+ soldermask_margin_top: z109.number().optional(),
2261
+ soldermask_margin_right: z109.number().optional(),
2262
+ soldermask_margin_bottom: z109.number().optional(),
2263
+ solderpaste_margin: z109.number().optional()
2241
2264
  });
2242
- var pcb_smtpad_pill = z108.object({
2243
- type: z108.literal("pcb_smtpad"),
2244
- shape: z108.literal("pill"),
2265
+ var pcb_smtpad_pill = z109.object({
2266
+ type: z109.literal("pcb_smtpad"),
2267
+ shape: z109.literal("pill"),
2245
2268
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
2246
- pcb_group_id: z108.string().optional(),
2247
- subcircuit_id: z108.string().optional(),
2269
+ pcb_group_id: z109.string().optional(),
2270
+ subcircuit_id: z109.string().optional(),
2248
2271
  x: distance,
2249
2272
  y: distance,
2250
- width: z108.number(),
2251
- height: z108.number(),
2252
- radius: z108.number(),
2273
+ width: z109.number(),
2274
+ height: z109.number(),
2275
+ radius: z109.number(),
2253
2276
  layer: layer_ref,
2254
- port_hints: z108.array(z108.string()).optional(),
2255
- pcb_component_id: z108.string().optional(),
2256
- pcb_port_id: z108.string().optional(),
2257
- is_covered_with_solder_mask: z108.boolean().optional(),
2258
- soldermask_margin: z108.number().optional(),
2259
- solderpaste_margin: z108.number().optional()
2277
+ port_hints: z109.array(z109.string()).optional(),
2278
+ pcb_component_id: z109.string().optional(),
2279
+ pcb_port_id: z109.string().optional(),
2280
+ is_covered_with_solder_mask: z109.boolean().optional(),
2281
+ soldermask_margin: z109.number().optional(),
2282
+ solderpaste_margin: z109.number().optional()
2260
2283
  });
2261
- var pcb_smtpad_rotated_pill = z108.object({
2262
- type: z108.literal("pcb_smtpad"),
2263
- shape: z108.literal("rotated_pill"),
2284
+ var pcb_smtpad_rotated_pill = z109.object({
2285
+ type: z109.literal("pcb_smtpad"),
2286
+ shape: z109.literal("rotated_pill"),
2264
2287
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
2265
- pcb_group_id: z108.string().optional(),
2266
- subcircuit_id: z108.string().optional(),
2288
+ pcb_group_id: z109.string().optional(),
2289
+ subcircuit_id: z109.string().optional(),
2267
2290
  x: distance,
2268
2291
  y: distance,
2269
- width: z108.number(),
2270
- height: z108.number(),
2271
- radius: z108.number(),
2292
+ width: z109.number(),
2293
+ height: z109.number(),
2294
+ radius: z109.number(),
2272
2295
  ccw_rotation: rotation,
2273
2296
  layer: layer_ref,
2274
- port_hints: z108.array(z108.string()).optional(),
2275
- pcb_component_id: z108.string().optional(),
2276
- pcb_port_id: z108.string().optional(),
2277
- is_covered_with_solder_mask: z108.boolean().optional(),
2278
- soldermask_margin: z108.number().optional(),
2279
- solderpaste_margin: z108.number().optional()
2297
+ port_hints: z109.array(z109.string()).optional(),
2298
+ pcb_component_id: z109.string().optional(),
2299
+ pcb_port_id: z109.string().optional(),
2300
+ is_covered_with_solder_mask: z109.boolean().optional(),
2301
+ soldermask_margin: z109.number().optional(),
2302
+ solderpaste_margin: z109.number().optional()
2280
2303
  });
2281
- var pcb_smtpad_polygon = z108.object({
2282
- type: z108.literal("pcb_smtpad"),
2283
- shape: z108.literal("polygon"),
2304
+ var pcb_smtpad_polygon = z109.object({
2305
+ type: z109.literal("pcb_smtpad"),
2306
+ shape: z109.literal("polygon"),
2284
2307
  pcb_smtpad_id: getZodPrefixedIdWithDefault("pcb_smtpad"),
2285
- pcb_group_id: z108.string().optional(),
2286
- subcircuit_id: z108.string().optional(),
2287
- points: z108.array(point),
2308
+ pcb_group_id: z109.string().optional(),
2309
+ subcircuit_id: z109.string().optional(),
2310
+ points: z109.array(point),
2288
2311
  layer: layer_ref,
2289
- port_hints: z108.array(z108.string()).optional(),
2290
- pcb_component_id: z108.string().optional(),
2291
- pcb_port_id: z108.string().optional(),
2292
- is_covered_with_solder_mask: z108.boolean().optional(),
2293
- soldermask_margin: z108.number().optional(),
2294
- solderpaste_margin: z108.number().optional()
2312
+ port_hints: z109.array(z109.string()).optional(),
2313
+ pcb_component_id: z109.string().optional(),
2314
+ pcb_port_id: z109.string().optional(),
2315
+ is_covered_with_solder_mask: z109.boolean().optional(),
2316
+ soldermask_margin: z109.number().optional(),
2317
+ solderpaste_margin: z109.number().optional()
2295
2318
  });
2296
- var pcb_smtpad = z108.discriminatedUnion("shape", [
2319
+ var pcb_smtpad = z109.discriminatedUnion("shape", [
2297
2320
  pcb_smtpad_circle,
2298
2321
  pcb_smtpad_rect,
2299
2322
  pcb_smtpad_rotated_rect,
@@ -2309,95 +2332,95 @@ expectTypesMatch(true);
2309
2332
  expectTypesMatch(true);
2310
2333
 
2311
2334
  // src/pcb/pcb_solder_paste.ts
2312
- import { z as z109 } from "zod";
2313
- var pcb_solder_paste_circle = z109.object({
2314
- type: z109.literal("pcb_solder_paste"),
2315
- shape: z109.literal("circle"),
2335
+ import { z as z110 } from "zod";
2336
+ var pcb_solder_paste_circle = z110.object({
2337
+ type: z110.literal("pcb_solder_paste"),
2338
+ shape: z110.literal("circle"),
2316
2339
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
2317
- pcb_group_id: z109.string().optional(),
2318
- subcircuit_id: z109.string().optional(),
2340
+ pcb_group_id: z110.string().optional(),
2341
+ subcircuit_id: z110.string().optional(),
2319
2342
  x: distance,
2320
2343
  y: distance,
2321
- radius: z109.number(),
2344
+ radius: z110.number(),
2322
2345
  layer: layer_ref,
2323
- pcb_component_id: z109.string().optional(),
2324
- pcb_smtpad_id: z109.string().optional()
2346
+ pcb_component_id: z110.string().optional(),
2347
+ pcb_smtpad_id: z110.string().optional()
2325
2348
  });
2326
- var pcb_solder_paste_rect = z109.object({
2327
- type: z109.literal("pcb_solder_paste"),
2328
- shape: z109.literal("rect"),
2349
+ var pcb_solder_paste_rect = z110.object({
2350
+ type: z110.literal("pcb_solder_paste"),
2351
+ shape: z110.literal("rect"),
2329
2352
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
2330
- pcb_group_id: z109.string().optional(),
2331
- subcircuit_id: z109.string().optional(),
2353
+ pcb_group_id: z110.string().optional(),
2354
+ subcircuit_id: z110.string().optional(),
2332
2355
  x: distance,
2333
2356
  y: distance,
2334
- width: z109.number(),
2335
- height: z109.number(),
2357
+ width: z110.number(),
2358
+ height: z110.number(),
2336
2359
  layer: layer_ref,
2337
- pcb_component_id: z109.string().optional(),
2338
- pcb_smtpad_id: z109.string().optional()
2360
+ pcb_component_id: z110.string().optional(),
2361
+ pcb_smtpad_id: z110.string().optional()
2339
2362
  });
2340
- var pcb_solder_paste_pill = z109.object({
2341
- type: z109.literal("pcb_solder_paste"),
2342
- shape: z109.literal("pill"),
2363
+ var pcb_solder_paste_pill = z110.object({
2364
+ type: z110.literal("pcb_solder_paste"),
2365
+ shape: z110.literal("pill"),
2343
2366
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
2344
- pcb_group_id: z109.string().optional(),
2345
- subcircuit_id: z109.string().optional(),
2367
+ pcb_group_id: z110.string().optional(),
2368
+ subcircuit_id: z110.string().optional(),
2346
2369
  x: distance,
2347
2370
  y: distance,
2348
- width: z109.number(),
2349
- height: z109.number(),
2350
- radius: z109.number(),
2371
+ width: z110.number(),
2372
+ height: z110.number(),
2373
+ radius: z110.number(),
2351
2374
  layer: layer_ref,
2352
- pcb_component_id: z109.string().optional(),
2353
- pcb_smtpad_id: z109.string().optional()
2375
+ pcb_component_id: z110.string().optional(),
2376
+ pcb_smtpad_id: z110.string().optional()
2354
2377
  });
2355
- var pcb_solder_paste_rotated_rect = z109.object({
2356
- type: z109.literal("pcb_solder_paste"),
2357
- shape: z109.literal("rotated_rect"),
2378
+ var pcb_solder_paste_rotated_rect = z110.object({
2379
+ type: z110.literal("pcb_solder_paste"),
2380
+ shape: z110.literal("rotated_rect"),
2358
2381
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
2359
- pcb_group_id: z109.string().optional(),
2360
- subcircuit_id: z109.string().optional(),
2382
+ pcb_group_id: z110.string().optional(),
2383
+ subcircuit_id: z110.string().optional(),
2361
2384
  x: distance,
2362
2385
  y: distance,
2363
- width: z109.number(),
2364
- height: z109.number(),
2386
+ width: z110.number(),
2387
+ height: z110.number(),
2365
2388
  ccw_rotation: distance,
2366
2389
  layer: layer_ref,
2367
- pcb_component_id: z109.string().optional(),
2368
- pcb_smtpad_id: z109.string().optional()
2390
+ pcb_component_id: z110.string().optional(),
2391
+ pcb_smtpad_id: z110.string().optional()
2369
2392
  });
2370
- var pcb_solder_paste_rotated_pill = z109.object({
2371
- type: z109.literal("pcb_solder_paste"),
2372
- shape: z109.literal("rotated_pill"),
2393
+ var pcb_solder_paste_rotated_pill = z110.object({
2394
+ type: z110.literal("pcb_solder_paste"),
2395
+ shape: z110.literal("rotated_pill"),
2373
2396
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
2374
- pcb_group_id: z109.string().optional(),
2375
- subcircuit_id: z109.string().optional(),
2397
+ pcb_group_id: z110.string().optional(),
2398
+ subcircuit_id: z110.string().optional(),
2376
2399
  x: distance,
2377
2400
  y: distance,
2378
- width: z109.number(),
2379
- height: z109.number(),
2380
- radius: z109.number(),
2401
+ width: z110.number(),
2402
+ height: z110.number(),
2403
+ radius: z110.number(),
2381
2404
  ccw_rotation: rotation,
2382
2405
  layer: layer_ref,
2383
- pcb_component_id: z109.string().optional(),
2384
- pcb_smtpad_id: z109.string().optional()
2406
+ pcb_component_id: z110.string().optional(),
2407
+ pcb_smtpad_id: z110.string().optional()
2385
2408
  });
2386
- var pcb_solder_paste_oval = z109.object({
2387
- type: z109.literal("pcb_solder_paste"),
2388
- shape: z109.literal("oval"),
2409
+ var pcb_solder_paste_oval = z110.object({
2410
+ type: z110.literal("pcb_solder_paste"),
2411
+ shape: z110.literal("oval"),
2389
2412
  pcb_solder_paste_id: getZodPrefixedIdWithDefault("pcb_solder_paste"),
2390
- pcb_group_id: z109.string().optional(),
2391
- subcircuit_id: z109.string().optional(),
2413
+ pcb_group_id: z110.string().optional(),
2414
+ subcircuit_id: z110.string().optional(),
2392
2415
  x: distance,
2393
2416
  y: distance,
2394
- width: z109.number(),
2395
- height: z109.number(),
2417
+ width: z110.number(),
2418
+ height: z110.number(),
2396
2419
  layer: layer_ref,
2397
- pcb_component_id: z109.string().optional(),
2398
- pcb_smtpad_id: z109.string().optional()
2420
+ pcb_component_id: z110.string().optional(),
2421
+ pcb_smtpad_id: z110.string().optional()
2399
2422
  });
2400
- var pcb_solder_paste = z109.union([
2423
+ var pcb_solder_paste = z110.union([
2401
2424
  pcb_solder_paste_circle,
2402
2425
  pcb_solder_paste_rect,
2403
2426
  pcb_solder_paste_pill,
@@ -2417,213 +2440,213 @@ expectTypesMatch(
2417
2440
  expectTypesMatch(true);
2418
2441
 
2419
2442
  // src/pcb/pcb_text.ts
2420
- import { z as z110 } from "zod";
2421
- var pcb_text = z110.object({
2422
- type: z110.literal("pcb_text"),
2443
+ import { z as z111 } from "zod";
2444
+ var pcb_text = z111.object({
2445
+ type: z111.literal("pcb_text"),
2423
2446
  pcb_text_id: getZodPrefixedIdWithDefault("pcb_text"),
2424
- pcb_group_id: z110.string().optional(),
2425
- subcircuit_id: z110.string().optional(),
2426
- text: z110.string(),
2447
+ pcb_group_id: z111.string().optional(),
2448
+ subcircuit_id: z111.string().optional(),
2449
+ text: z111.string(),
2427
2450
  center: point,
2428
2451
  layer: layer_ref,
2429
2452
  width: length,
2430
2453
  height: length,
2431
- lines: z110.number(),
2454
+ lines: z111.number(),
2432
2455
  // @ts-ignore
2433
- align: z110.enum(["bottom-left"])
2456
+ align: z111.enum(["bottom-left"])
2434
2457
  }).describe("Defines text on the PCB");
2435
2458
  expectTypesMatch(true);
2436
2459
 
2437
2460
  // src/pcb/pcb_trace.ts
2438
- import { z as z111 } from "zod";
2439
- var pcb_trace_route_point_wire = z111.object({
2440
- route_type: z111.literal("wire"),
2461
+ import { z as z112 } from "zod";
2462
+ var pcb_trace_route_point_wire = z112.object({
2463
+ route_type: z112.literal("wire"),
2441
2464
  x: distance,
2442
2465
  y: distance,
2443
2466
  width: distance,
2444
- copper_pour_id: z111.string().optional(),
2445
- is_inside_copper_pour: z111.boolean().optional(),
2446
- start_pcb_port_id: z111.string().optional(),
2447
- end_pcb_port_id: z111.string().optional(),
2467
+ copper_pour_id: z112.string().optional(),
2468
+ is_inside_copper_pour: z112.boolean().optional(),
2469
+ start_pcb_port_id: z112.string().optional(),
2470
+ end_pcb_port_id: z112.string().optional(),
2448
2471
  layer: layer_ref
2449
2472
  });
2450
- var pcb_trace_route_point_via = z111.object({
2451
- route_type: z111.literal("via"),
2473
+ var pcb_trace_route_point_via = z112.object({
2474
+ route_type: z112.literal("via"),
2452
2475
  x: distance,
2453
2476
  y: distance,
2454
- copper_pour_id: z111.string().optional(),
2455
- is_inside_copper_pour: z111.boolean().optional(),
2477
+ copper_pour_id: z112.string().optional(),
2478
+ is_inside_copper_pour: z112.boolean().optional(),
2456
2479
  hole_diameter: distance.optional(),
2457
2480
  outer_diameter: distance.optional(),
2458
2481
  from_layer: layer_ref,
2459
2482
  to_layer: layer_ref
2460
2483
  });
2461
- var pcb_trace_route_point_through_pad = z111.object({
2462
- route_type: z111.literal("through_pad"),
2484
+ var pcb_trace_route_point_through_pad = z112.object({
2485
+ route_type: z112.literal("through_pad"),
2463
2486
  start: point,
2464
2487
  end: point,
2465
2488
  width: distance,
2466
2489
  start_layer: layer_ref,
2467
2490
  end_layer: layer_ref,
2468
- pcb_smtpad_id: z111.string().optional(),
2469
- pcb_plated_hole_id: z111.string().optional()
2491
+ pcb_smtpad_id: z112.string().optional(),
2492
+ pcb_plated_hole_id: z112.string().optional()
2470
2493
  });
2471
- var pcb_trace_route_point = z111.union([
2494
+ var pcb_trace_route_point = z112.union([
2472
2495
  pcb_trace_route_point_wire,
2473
2496
  pcb_trace_route_point_via,
2474
2497
  pcb_trace_route_point_through_pad
2475
2498
  ]);
2476
- var pcb_trace = z111.object({
2477
- type: z111.literal("pcb_trace"),
2478
- source_trace_id: z111.string().optional(),
2479
- pcb_component_id: z111.string().optional(),
2499
+ var pcb_trace = z112.object({
2500
+ type: z112.literal("pcb_trace"),
2501
+ source_trace_id: z112.string().optional(),
2502
+ pcb_component_id: z112.string().optional(),
2480
2503
  pcb_trace_id: getZodPrefixedIdWithDefault("pcb_trace"),
2481
- pcb_group_id: z111.string().optional(),
2482
- subcircuit_id: z111.string().optional(),
2483
- route_thickness_mode: z111.enum(["constant", "interpolated"]).default("constant").optional(),
2484
- route_order_index: z111.number().optional(),
2485
- should_round_corners: z111.boolean().optional(),
2486
- trace_length: z111.number().optional(),
2487
- highlight_color: z111.string().optional(),
2488
- route: z111.array(pcb_trace_route_point)
2504
+ pcb_group_id: z112.string().optional(),
2505
+ subcircuit_id: z112.string().optional(),
2506
+ route_thickness_mode: z112.enum(["constant", "interpolated"]).default("constant").optional(),
2507
+ route_order_index: z112.number().optional(),
2508
+ should_round_corners: z112.boolean().optional(),
2509
+ trace_length: z112.number().optional(),
2510
+ highlight_color: z112.string().optional(),
2511
+ route: z112.array(pcb_trace_route_point)
2489
2512
  }).describe("Defines a trace on the PCB");
2490
2513
  expectTypesMatch(true);
2491
2514
  expectTypesMatch(true);
2492
2515
 
2493
2516
  // src/pcb/pcb_trace_warning.ts
2494
- import { z as z112 } from "zod";
2495
- var pcb_trace_warning = z112.object({
2496
- type: z112.literal("pcb_trace_warning"),
2517
+ import { z as z113 } from "zod";
2518
+ var pcb_trace_warning = z113.object({
2519
+ type: z113.literal("pcb_trace_warning"),
2497
2520
  pcb_trace_warning_id: getZodPrefixedIdWithDefault("pcb_trace_warning"),
2498
- warning_type: z112.literal("pcb_trace_warning").default("pcb_trace_warning"),
2499
- message: z112.string(),
2521
+ warning_type: z113.literal("pcb_trace_warning").default("pcb_trace_warning"),
2522
+ message: z113.string(),
2500
2523
  center: point.optional(),
2501
- pcb_trace_id: z112.string(),
2502
- source_trace_id: z112.string(),
2503
- pcb_component_ids: z112.array(z112.string()),
2504
- pcb_port_ids: z112.array(z112.string()),
2505
- subcircuit_id: z112.string().optional()
2524
+ pcb_trace_id: z113.string(),
2525
+ source_trace_id: z113.string(),
2526
+ pcb_component_ids: z113.array(z113.string()),
2527
+ pcb_port_ids: z113.array(z113.string()),
2528
+ subcircuit_id: z113.string().optional()
2506
2529
  }).describe("Defines a trace warning on the PCB");
2507
2530
  expectTypesMatch(true);
2508
2531
 
2509
2532
  // src/pcb/pcb_trace_too_long_warning.ts
2510
- import { z as z113 } from "zod";
2511
- var pcb_trace_too_long_warning = z113.object({
2512
- type: z113.literal("pcb_trace_too_long_warning"),
2533
+ import { z as z114 } from "zod";
2534
+ var pcb_trace_too_long_warning = z114.object({
2535
+ type: z114.literal("pcb_trace_too_long_warning"),
2513
2536
  pcb_trace_too_long_warning_id: getZodPrefixedIdWithDefault(
2514
2537
  "pcb_trace_too_long_warning"
2515
2538
  ),
2516
- warning_type: z113.literal("pcb_trace_too_long_warning").default("pcb_trace_too_long_warning"),
2517
- message: z113.string(),
2518
- pcb_trace_id: z113.string(),
2519
- source_net_id: z113.string().optional(),
2520
- source_trace_id: z113.string().optional(),
2539
+ warning_type: z114.literal("pcb_trace_too_long_warning").default("pcb_trace_too_long_warning"),
2540
+ message: z114.string(),
2541
+ pcb_trace_id: z114.string(),
2542
+ source_net_id: z114.string().optional(),
2543
+ source_trace_id: z114.string().optional(),
2521
2544
  actual_trace_length: distance,
2522
2545
  maximum_trace_length: distance,
2523
- subcircuit_id: z113.string().optional()
2546
+ subcircuit_id: z114.string().optional()
2524
2547
  }).describe(
2525
2548
  "Warning emitted when a PCB trace is longer than its maximum allowed length"
2526
2549
  );
2527
2550
  expectTypesMatch(true);
2528
2551
 
2529
2552
  // src/pcb/pcb_trace_too_many_vias_warning.ts
2530
- import { z as z114 } from "zod";
2531
- var pcb_trace_too_many_vias_warning = z114.object({
2532
- type: z114.literal("pcb_trace_too_many_vias_warning"),
2553
+ import { z as z115 } from "zod";
2554
+ var pcb_trace_too_many_vias_warning = z115.object({
2555
+ type: z115.literal("pcb_trace_too_many_vias_warning"),
2533
2556
  pcb_trace_too_many_vias_warning_id: getZodPrefixedIdWithDefault(
2534
2557
  "pcb_trace_too_many_vias_warning"
2535
2558
  ),
2536
- warning_type: z114.literal("pcb_trace_too_many_vias_warning").default("pcb_trace_too_many_vias_warning"),
2537
- message: z114.string(),
2538
- pcb_trace_id: z114.string(),
2539
- source_net_id: z114.string().optional(),
2540
- source_trace_id: z114.string().optional(),
2541
- actual_via_count: z114.number().int().nonnegative(),
2542
- maximum_via_count: z114.number().int().nonnegative(),
2543
- subcircuit_id: z114.string().optional()
2559
+ warning_type: z115.literal("pcb_trace_too_many_vias_warning").default("pcb_trace_too_many_vias_warning"),
2560
+ message: z115.string(),
2561
+ pcb_trace_id: z115.string(),
2562
+ source_net_id: z115.string().optional(),
2563
+ source_trace_id: z115.string().optional(),
2564
+ actual_via_count: z115.number().int().nonnegative(),
2565
+ maximum_via_count: z115.number().int().nonnegative(),
2566
+ subcircuit_id: z115.string().optional()
2544
2567
  }).describe(
2545
2568
  "Warning emitted when a PCB trace has more vias than its maximum allowed count"
2546
2569
  );
2547
2570
  expectTypesMatch(true);
2548
2571
 
2549
2572
  // src/pcb/pcb_trace_error.ts
2550
- import { z as z115 } from "zod";
2573
+ import { z as z116 } from "zod";
2551
2574
  var pcb_trace_error = base_circuit_json_error.extend({
2552
- type: z115.literal("pcb_trace_error"),
2575
+ type: z116.literal("pcb_trace_error"),
2553
2576
  pcb_trace_error_id: getZodPrefixedIdWithDefault("pcb_trace_error"),
2554
- error_type: z115.literal("pcb_trace_error").default("pcb_trace_error"),
2577
+ error_type: z116.literal("pcb_trace_error").default("pcb_trace_error"),
2555
2578
  center: point.optional(),
2556
- pcb_trace_id: z115.string(),
2557
- source_trace_id: z115.string(),
2558
- pcb_component_ids: z115.array(z115.string()),
2559
- pcb_port_ids: z115.array(z115.string()),
2560
- subcircuit_id: z115.string().optional()
2579
+ pcb_trace_id: z116.string(),
2580
+ source_trace_id: z116.string(),
2581
+ pcb_component_ids: z116.array(z116.string()),
2582
+ pcb_port_ids: z116.array(z116.string()),
2583
+ subcircuit_id: z116.string().optional()
2561
2584
  }).describe("Defines a trace error on the PCB");
2562
2585
  expectTypesMatch(true);
2563
2586
 
2564
2587
  // src/pcb/pcb_trace_missing_error.ts
2565
- import { z as z116 } from "zod";
2588
+ import { z as z117 } from "zod";
2566
2589
  var pcb_trace_missing_error = base_circuit_json_error.extend({
2567
- type: z116.literal("pcb_trace_missing_error"),
2590
+ type: z117.literal("pcb_trace_missing_error"),
2568
2591
  pcb_trace_missing_error_id: getZodPrefixedIdWithDefault(
2569
2592
  "pcb_trace_missing_error"
2570
2593
  ),
2571
- error_type: z116.literal("pcb_trace_missing_error").default("pcb_trace_missing_error"),
2594
+ error_type: z117.literal("pcb_trace_missing_error").default("pcb_trace_missing_error"),
2572
2595
  center: point.optional(),
2573
- source_trace_id: z116.string(),
2574
- pcb_component_ids: z116.array(z116.string()),
2575
- pcb_port_ids: z116.array(z116.string()),
2576
- subcircuit_id: z116.string().optional()
2596
+ source_trace_id: z117.string(),
2597
+ pcb_component_ids: z117.array(z117.string()),
2598
+ pcb_port_ids: z117.array(z117.string()),
2599
+ subcircuit_id: z117.string().optional()
2577
2600
  }).describe(
2578
2601
  "Defines an error when a source trace has no corresponding PCB trace"
2579
2602
  );
2580
2603
  expectTypesMatch(true);
2581
2604
 
2582
2605
  // src/pcb/pcb_port_not_matched_error.ts
2583
- import { z as z117 } from "zod";
2606
+ import { z as z118 } from "zod";
2584
2607
  var pcb_port_not_matched_error = base_circuit_json_error.extend({
2585
- type: z117.literal("pcb_port_not_matched_error"),
2608
+ type: z118.literal("pcb_port_not_matched_error"),
2586
2609
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
2587
- error_type: z117.literal("pcb_port_not_matched_error").default("pcb_port_not_matched_error"),
2588
- pcb_component_ids: z117.array(z117.string()),
2589
- subcircuit_id: z117.string().optional()
2610
+ error_type: z118.literal("pcb_port_not_matched_error").default("pcb_port_not_matched_error"),
2611
+ pcb_component_ids: z118.array(z118.string()),
2612
+ subcircuit_id: z118.string().optional()
2590
2613
  }).describe("Defines a trace error on the PCB where a port is not matched");
2591
2614
  expectTypesMatch(true);
2592
2615
 
2593
2616
  // src/pcb/pcb_port_not_connected_error.ts
2594
- import { z as z118 } from "zod";
2617
+ import { z as z119 } from "zod";
2595
2618
  var pcb_port_not_connected_error = base_circuit_json_error.extend({
2596
- type: z118.literal("pcb_port_not_connected_error"),
2619
+ type: z119.literal("pcb_port_not_connected_error"),
2597
2620
  pcb_port_not_connected_error_id: getZodPrefixedIdWithDefault(
2598
2621
  "pcb_port_not_connected_error"
2599
2622
  ),
2600
- error_type: z118.literal("pcb_port_not_connected_error").default("pcb_port_not_connected_error"),
2601
- pcb_port_ids: z118.array(z118.string()),
2602
- pcb_component_ids: z118.array(z118.string()),
2603
- subcircuit_id: z118.string().optional()
2623
+ error_type: z119.literal("pcb_port_not_connected_error").default("pcb_port_not_connected_error"),
2624
+ pcb_port_ids: z119.array(z119.string()),
2625
+ pcb_component_ids: z119.array(z119.string()),
2626
+ subcircuit_id: z119.string().optional()
2604
2627
  }).describe("Defines an error when a pcb port is not connected to any trace");
2605
2628
  expectTypesMatch(
2606
2629
  true
2607
2630
  );
2608
2631
 
2609
2632
  // src/pcb/pcb_net.ts
2610
- import { z as z119 } from "zod";
2611
- var pcb_net = z119.object({
2612
- type: z119.literal("pcb_net"),
2633
+ import { z as z120 } from "zod";
2634
+ var pcb_net = z120.object({
2635
+ type: z120.literal("pcb_net"),
2613
2636
  pcb_net_id: getZodPrefixedIdWithDefault("pcb_net"),
2614
- source_net_id: z119.string().optional(),
2615
- highlight_color: z119.string().optional()
2637
+ source_net_id: z120.string().optional(),
2638
+ highlight_color: z120.string().optional()
2616
2639
  }).describe("Defines a net on the PCB");
2617
2640
  expectTypesMatch(true);
2618
2641
 
2619
2642
  // src/pcb/pcb_via.ts
2620
- import { z as z120 } from "zod";
2621
- var pcb_via = z120.object({
2622
- type: z120.literal("pcb_via"),
2643
+ import { z as z121 } from "zod";
2644
+ var pcb_via = z121.object({
2645
+ type: z121.literal("pcb_via"),
2623
2646
  pcb_via_id: getZodPrefixedIdWithDefault("pcb_via"),
2624
- pcb_group_id: z120.string().optional(),
2625
- subcircuit_id: z120.string().optional(),
2626
- subcircuit_connectivity_map_key: z120.string().optional(),
2647
+ pcb_group_id: z121.string().optional(),
2648
+ subcircuit_id: z121.string().optional(),
2649
+ subcircuit_connectivity_map_key: z121.string().optional(),
2627
2650
  x: distance,
2628
2651
  y: distance,
2629
2652
  outer_diameter: distance.default("0.6mm"),
@@ -2632,120 +2655,120 @@ var pcb_via = z120.object({
2632
2655
  from_layer: layer_ref.optional(),
2633
2656
  /** @deprecated */
2634
2657
  to_layer: layer_ref.optional(),
2635
- layers: z120.array(layer_ref),
2636
- pcb_trace_id: z120.string().optional(),
2637
- source_trace_id: z120.string().optional(),
2638
- source_net_id: z120.string().min(1).optional(),
2639
- net_is_assignable: z120.boolean().optional(),
2640
- net_assigned: z120.boolean().optional(),
2641
- is_tented: z120.boolean().optional()
2658
+ layers: z121.array(layer_ref),
2659
+ pcb_trace_id: z121.string().optional(),
2660
+ source_trace_id: z121.string().optional(),
2661
+ source_net_id: z121.string().min(1).optional(),
2662
+ net_is_assignable: z121.boolean().optional(),
2663
+ net_assigned: z121.boolean().optional(),
2664
+ is_tented: z121.boolean().optional()
2642
2665
  }).describe("Defines a via on the PCB");
2643
2666
  expectTypesMatch(true);
2644
2667
 
2645
2668
  // src/pcb/pcb_board.ts
2646
- import { z as z121 } from "zod";
2647
- var pcb_board = z121.object({
2648
- type: z121.literal("pcb_board"),
2669
+ import { z as z122 } from "zod";
2670
+ var pcb_board = z122.object({
2671
+ type: z122.literal("pcb_board"),
2649
2672
  pcb_board_id: getZodPrefixedIdWithDefault("pcb_board"),
2650
- pcb_panel_id: z121.string().optional(),
2651
- carrier_pcb_board_id: z121.string().optional(),
2652
- is_subcircuit: z121.boolean().optional(),
2653
- subcircuit_id: z121.string().optional(),
2654
- is_mounted_to_carrier_board: z121.boolean().optional(),
2655
- is_via_in_pad_allowed: z121.boolean().optional(),
2673
+ pcb_panel_id: z122.string().optional(),
2674
+ carrier_pcb_board_id: z122.string().optional(),
2675
+ is_subcircuit: z122.boolean().optional(),
2676
+ subcircuit_id: z122.string().optional(),
2677
+ is_mounted_to_carrier_board: z122.boolean().optional(),
2678
+ is_via_in_pad_allowed: z122.boolean().optional(),
2656
2679
  width: length.optional(),
2657
2680
  height: length.optional(),
2658
2681
  center: point,
2659
- display_offset_x: z121.string().optional().describe(
2682
+ display_offset_x: z122.string().optional().describe(
2660
2683
  "How to display the x offset for this board, usually corresponding with how the user specified it"
2661
2684
  ),
2662
- display_offset_y: z121.string().optional().describe(
2685
+ display_offset_y: z122.string().optional().describe(
2663
2686
  "How to display the y offset for this board, usually corresponding with how the user specified it"
2664
2687
  ),
2665
2688
  thickness: length.optional().default(1.4),
2666
- num_layers: z121.number().optional().default(4),
2667
- allow_blind_and_buried_vias: z121.boolean().optional().describe(
2689
+ num_layers: z122.number().optional().default(4),
2690
+ allow_blind_and_buried_vias: z122.boolean().optional().describe(
2668
2691
  "Whether autorouters may generate blind and buried vias. False restricts newly generated vias to the full board stack."
2669
2692
  ),
2670
- outline: z121.array(point).optional(),
2671
- shape: z121.enum(["rect", "polygon"]).optional(),
2672
- material: z121.enum(["fr4", "fr1"]).default("fr4"),
2673
- solder_mask_color: z121.string().optional(),
2674
- silkscreen_color: z121.string().optional(),
2693
+ outline: z122.array(point).optional(),
2694
+ shape: z122.enum(["rect", "polygon"]).optional(),
2695
+ material: z122.enum(["fr4", "fr1"]).default("fr4"),
2696
+ solder_mask_color: z122.string().optional(),
2697
+ silkscreen_color: z122.string().optional(),
2675
2698
  anchor_position: point.optional(),
2676
2699
  anchor_alignment: ninePointAnchor.optional(),
2677
- position_mode: z121.enum(["relative_to_panel_anchor", "none"]).optional()
2700
+ position_mode: z122.enum(["relative_to_panel_anchor", "none"]).optional()
2678
2701
  }).merge(manufacturing_drc_properties).describe("Defines the board outline of the PCB");
2679
2702
  expectTypesMatch(true);
2680
2703
 
2681
2704
  // src/pcb/pcb_panel.ts
2682
- import { z as z122 } from "zod";
2683
- var pcb_panel = z122.object({
2684
- type: z122.literal("pcb_panel"),
2705
+ import { z as z123 } from "zod";
2706
+ var pcb_panel = z123.object({
2707
+ type: z123.literal("pcb_panel"),
2685
2708
  pcb_panel_id: getZodPrefixedIdWithDefault("pcb_panel"),
2686
2709
  width: length,
2687
2710
  height: length,
2688
2711
  center: point,
2689
2712
  thickness: length.optional().default(1.4),
2690
- covered_with_solder_mask: z122.boolean().optional().default(true)
2713
+ covered_with_solder_mask: z123.boolean().optional().default(true)
2691
2714
  }).describe("Defines a PCB panel that can contain multiple boards");
2692
2715
  expectTypesMatch(true);
2693
2716
 
2694
2717
  // src/pcb/pcb_placement_error.ts
2695
- import { z as z123 } from "zod";
2718
+ import { z as z124 } from "zod";
2696
2719
  var pcb_placement_error = base_circuit_json_error.extend({
2697
- type: z123.literal("pcb_placement_error"),
2720
+ type: z124.literal("pcb_placement_error"),
2698
2721
  pcb_placement_error_id: getZodPrefixedIdWithDefault("pcb_placement_error"),
2699
- error_type: z123.literal("pcb_placement_error").default("pcb_placement_error"),
2700
- subcircuit_id: z123.string().optional()
2722
+ error_type: z124.literal("pcb_placement_error").default("pcb_placement_error"),
2723
+ subcircuit_id: z124.string().optional()
2701
2724
  }).describe("Defines a placement error on the PCB");
2702
2725
  expectTypesMatch(true);
2703
2726
 
2704
2727
  // src/pcb/pcb_packing_error.ts
2705
- import { z as z124 } from "zod";
2728
+ import { z as z125 } from "zod";
2706
2729
  var pcb_packing_error = base_circuit_json_error.extend({
2707
- type: z124.literal("pcb_packing_error"),
2730
+ type: z125.literal("pcb_packing_error"),
2708
2731
  pcb_packing_error_id: getZodPrefixedIdWithDefault("pcb_packing_error"),
2709
- error_type: z124.literal("pcb_packing_error").default("pcb_packing_error"),
2710
- pcb_group_id: z124.string().optional(),
2711
- subcircuit_id: z124.string().optional()
2732
+ error_type: z125.literal("pcb_packing_error").default("pcb_packing_error"),
2733
+ pcb_group_id: z125.string().optional(),
2734
+ subcircuit_id: z125.string().optional()
2712
2735
  }).describe("Defines a failure to pack PCB components within layout bounds");
2713
2736
  expectTypesMatch(true);
2714
2737
 
2715
2738
  // src/pcb/pcb_panelization_placement_error.ts
2716
- import { z as z125 } from "zod";
2739
+ import { z as z126 } from "zod";
2717
2740
  var pcb_panelization_placement_error = base_circuit_json_error.extend({
2718
- type: z125.literal("pcb_panelization_placement_error"),
2741
+ type: z126.literal("pcb_panelization_placement_error"),
2719
2742
  pcb_panelization_placement_error_id: getZodPrefixedIdWithDefault(
2720
2743
  "pcb_panelization_placement_error"
2721
2744
  ),
2722
- error_type: z125.literal("pcb_panelization_placement_error").default("pcb_panelization_placement_error"),
2723
- pcb_panel_id: z125.string().optional(),
2724
- pcb_board_id: z125.string().optional(),
2725
- subcircuit_id: z125.string().optional()
2745
+ error_type: z126.literal("pcb_panelization_placement_error").default("pcb_panelization_placement_error"),
2746
+ pcb_panel_id: z126.string().optional(),
2747
+ pcb_board_id: z126.string().optional(),
2748
+ subcircuit_id: z126.string().optional()
2726
2749
  }).describe("Defines a panelization placement error on the PCB");
2727
2750
  expectTypesMatch(true);
2728
2751
 
2729
2752
  // src/pcb/pcb_trace_hint.ts
2730
- import { z as z126 } from "zod";
2731
- var pcb_trace_hint = z126.object({
2732
- type: z126.literal("pcb_trace_hint"),
2753
+ import { z as z127 } from "zod";
2754
+ var pcb_trace_hint = z127.object({
2755
+ type: z127.literal("pcb_trace_hint"),
2733
2756
  pcb_trace_hint_id: getZodPrefixedIdWithDefault("pcb_trace_hint"),
2734
- pcb_port_id: z126.string(),
2735
- pcb_component_id: z126.string(),
2736
- route: z126.array(route_hint_point),
2737
- subcircuit_id: z126.string().optional()
2757
+ pcb_port_id: z127.string(),
2758
+ pcb_component_id: z127.string(),
2759
+ route: z127.array(route_hint_point),
2760
+ subcircuit_id: z127.string().optional()
2738
2761
  }).describe("A hint that can be used during generation of a PCB trace");
2739
2762
  expectTypesMatch(true);
2740
2763
 
2741
2764
  // src/pcb/pcb_silkscreen_line.ts
2742
- import { z as z127 } from "zod";
2743
- var pcb_silkscreen_line = z127.object({
2744
- type: z127.literal("pcb_silkscreen_line"),
2765
+ import { z as z128 } from "zod";
2766
+ var pcb_silkscreen_line = z128.object({
2767
+ type: z128.literal("pcb_silkscreen_line"),
2745
2768
  pcb_silkscreen_line_id: getZodPrefixedIdWithDefault("pcb_silkscreen_line"),
2746
- pcb_component_id: z127.string(),
2747
- pcb_group_id: z127.string().optional(),
2748
- subcircuit_id: z127.string().optional(),
2769
+ pcb_component_id: z128.string(),
2770
+ pcb_group_id: z128.string().optional(),
2771
+ subcircuit_id: z128.string().optional(),
2749
2772
  stroke_width: distance.default("0.1mm"),
2750
2773
  x1: distance,
2751
2774
  y1: distance,
@@ -2756,32 +2779,32 @@ var pcb_silkscreen_line = z127.object({
2756
2779
  expectTypesMatch(true);
2757
2780
 
2758
2781
  // src/pcb/pcb_silkscreen_path.ts
2759
- import { z as z128 } from "zod";
2760
- var pcb_silkscreen_path = z128.object({
2761
- type: z128.literal("pcb_silkscreen_path"),
2782
+ import { z as z129 } from "zod";
2783
+ var pcb_silkscreen_path = z129.object({
2784
+ type: z129.literal("pcb_silkscreen_path"),
2762
2785
  pcb_silkscreen_path_id: getZodPrefixedIdWithDefault("pcb_silkscreen_path"),
2763
- pcb_component_id: z128.string(),
2764
- pcb_group_id: z128.string().optional(),
2765
- subcircuit_id: z128.string().optional(),
2786
+ pcb_component_id: z129.string(),
2787
+ pcb_group_id: z129.string().optional(),
2788
+ subcircuit_id: z129.string().optional(),
2766
2789
  layer: visible_layer,
2767
- route: z128.array(point),
2790
+ route: z129.array(point),
2768
2791
  stroke_width: length
2769
2792
  }).describe("Defines a silkscreen path on the PCB");
2770
2793
  expectTypesMatch(true);
2771
2794
 
2772
2795
  // src/pcb/pcb_silkscreen_text.ts
2773
- import { z as z129 } from "zod";
2774
- var pcb_silkscreen_text = z129.object({
2775
- type: z129.literal("pcb_silkscreen_text"),
2796
+ import { z as z130 } from "zod";
2797
+ var pcb_silkscreen_text = z130.object({
2798
+ type: z130.literal("pcb_silkscreen_text"),
2776
2799
  pcb_silkscreen_text_id: getZodPrefixedIdWithDefault("pcb_silkscreen_text"),
2777
- pcb_group_id: z129.string().optional(),
2778
- subcircuit_id: z129.string().optional(),
2779
- font: z129.literal("tscircuit2024").default("tscircuit2024"),
2800
+ pcb_group_id: z130.string().optional(),
2801
+ subcircuit_id: z130.string().optional(),
2802
+ font: z130.literal("tscircuit2024").default("tscircuit2024"),
2780
2803
  font_size: distance.default("0.2mm"),
2781
- pcb_component_id: z129.string(),
2782
- text: z129.string(),
2783
- is_knockout: z129.boolean().default(false).optional(),
2784
- knockout_padding: z129.object({
2804
+ pcb_component_id: z130.string(),
2805
+ text: z130.string(),
2806
+ is_knockout: z130.boolean().default(false).optional(),
2807
+ knockout_padding: z130.object({
2785
2808
  left: length,
2786
2809
  top: length,
2787
2810
  bottom: length,
@@ -2792,27 +2815,27 @@ var pcb_silkscreen_text = z129.object({
2792
2815
  bottom: "0.2mm",
2793
2816
  right: "0.2mm"
2794
2817
  }).optional(),
2795
- ccw_rotation: z129.number().optional(),
2818
+ ccw_rotation: z130.number().optional(),
2796
2819
  layer: layer_ref,
2797
- is_mirrored: z129.boolean().default(false).optional(),
2820
+ is_mirrored: z130.boolean().default(false).optional(),
2798
2821
  anchor_position: point.default({ x: 0, y: 0 }),
2799
2822
  anchor_alignment: ninePointAnchor.default("center")
2800
2823
  }).describe("Defines silkscreen text on the PCB");
2801
2824
  expectTypesMatch(true);
2802
2825
 
2803
2826
  // src/pcb/pcb_copper_text.ts
2804
- import { z as z130 } from "zod";
2805
- var pcb_copper_text = z130.object({
2806
- type: z130.literal("pcb_copper_text"),
2827
+ import { z as z131 } from "zod";
2828
+ var pcb_copper_text = z131.object({
2829
+ type: z131.literal("pcb_copper_text"),
2807
2830
  pcb_copper_text_id: getZodPrefixedIdWithDefault("pcb_copper_text"),
2808
- pcb_group_id: z130.string().optional(),
2809
- subcircuit_id: z130.string().optional(),
2810
- font: z130.literal("tscircuit2024").default("tscircuit2024"),
2831
+ pcb_group_id: z131.string().optional(),
2832
+ subcircuit_id: z131.string().optional(),
2833
+ font: z131.literal("tscircuit2024").default("tscircuit2024"),
2811
2834
  font_size: distance.default("0.2mm"),
2812
- pcb_component_id: z130.string(),
2813
- text: z130.string(),
2814
- is_knockout: z130.boolean().default(false).optional(),
2815
- knockout_padding: z130.object({
2835
+ pcb_component_id: z131.string(),
2836
+ text: z131.string(),
2837
+ is_knockout: z131.boolean().default(false).optional(),
2838
+ knockout_padding: z131.object({
2816
2839
  left: length,
2817
2840
  top: length,
2818
2841
  bottom: length,
@@ -2823,61 +2846,61 @@ var pcb_copper_text = z130.object({
2823
2846
  bottom: "0.2mm",
2824
2847
  right: "0.2mm"
2825
2848
  }).optional(),
2826
- ccw_rotation: z130.number().optional(),
2849
+ ccw_rotation: z131.number().optional(),
2827
2850
  layer: layer_ref,
2828
- is_mirrored: z130.boolean().default(false).optional(),
2851
+ is_mirrored: z131.boolean().default(false).optional(),
2829
2852
  anchor_position: point.default({ x: 0, y: 0 }),
2830
2853
  anchor_alignment: ninePointAnchor.default("center")
2831
2854
  }).describe("Defines copper text on the PCB");
2832
2855
  expectTypesMatch(true);
2833
2856
 
2834
2857
  // src/pcb/pcb_silkscreen_rect.ts
2835
- import { z as z131 } from "zod";
2836
- var pcb_silkscreen_rect = z131.object({
2837
- type: z131.literal("pcb_silkscreen_rect"),
2858
+ import { z as z132 } from "zod";
2859
+ var pcb_silkscreen_rect = z132.object({
2860
+ type: z132.literal("pcb_silkscreen_rect"),
2838
2861
  pcb_silkscreen_rect_id: getZodPrefixedIdWithDefault("pcb_silkscreen_rect"),
2839
- pcb_component_id: z131.string(),
2840
- pcb_group_id: z131.string().optional(),
2841
- subcircuit_id: z131.string().optional(),
2862
+ pcb_component_id: z132.string(),
2863
+ pcb_group_id: z132.string().optional(),
2864
+ subcircuit_id: z132.string().optional(),
2842
2865
  center: point,
2843
2866
  width: length,
2844
2867
  height: length,
2845
2868
  layer: layer_ref,
2846
2869
  stroke_width: length.default("1mm"),
2847
2870
  corner_radius: length.optional(),
2848
- is_filled: z131.boolean().default(true).optional(),
2849
- has_stroke: z131.boolean().optional(),
2850
- is_stroke_dashed: z131.boolean().optional(),
2851
- ccw_rotation: z131.number().optional()
2871
+ is_filled: z132.boolean().default(true).optional(),
2872
+ has_stroke: z132.boolean().optional(),
2873
+ is_stroke_dashed: z132.boolean().optional(),
2874
+ ccw_rotation: z132.number().optional()
2852
2875
  }).describe("Defines a silkscreen rect on the PCB");
2853
2876
  expectTypesMatch(true);
2854
2877
 
2855
2878
  // src/pcb/pcb_silkscreen_circle.ts
2856
- import { z as z132 } from "zod";
2857
- var pcb_silkscreen_circle = z132.object({
2858
- type: z132.literal("pcb_silkscreen_circle"),
2879
+ import { z as z133 } from "zod";
2880
+ var pcb_silkscreen_circle = z133.object({
2881
+ type: z133.literal("pcb_silkscreen_circle"),
2859
2882
  pcb_silkscreen_circle_id: getZodPrefixedIdWithDefault(
2860
2883
  "pcb_silkscreen_circle"
2861
2884
  ),
2862
- pcb_component_id: z132.string(),
2863
- pcb_group_id: z132.string().optional(),
2864
- subcircuit_id: z132.string().optional(),
2885
+ pcb_component_id: z133.string(),
2886
+ pcb_group_id: z133.string().optional(),
2887
+ subcircuit_id: z133.string().optional(),
2865
2888
  center: point,
2866
2889
  radius: length,
2867
2890
  layer: visible_layer,
2868
2891
  stroke_width: length.default("1mm"),
2869
- is_filled: z132.boolean().optional()
2892
+ is_filled: z133.boolean().optional()
2870
2893
  }).describe("Defines a silkscreen circle on the PCB");
2871
2894
  expectTypesMatch(true);
2872
2895
 
2873
2896
  // src/pcb/pcb_silkscreen_oval.ts
2874
- import { z as z133 } from "zod";
2875
- var pcb_silkscreen_oval = z133.object({
2876
- type: z133.literal("pcb_silkscreen_oval"),
2897
+ import { z as z134 } from "zod";
2898
+ var pcb_silkscreen_oval = z134.object({
2899
+ type: z134.literal("pcb_silkscreen_oval"),
2877
2900
  pcb_silkscreen_oval_id: getZodPrefixedIdWithDefault("pcb_silkscreen_oval"),
2878
- pcb_component_id: z133.string(),
2879
- pcb_group_id: z133.string().optional(),
2880
- subcircuit_id: z133.string().optional(),
2901
+ pcb_component_id: z134.string(),
2902
+ pcb_group_id: z134.string().optional(),
2903
+ subcircuit_id: z134.string().optional(),
2881
2904
  center: point,
2882
2905
  radius_x: distance,
2883
2906
  radius_y: distance,
@@ -2887,265 +2910,265 @@ var pcb_silkscreen_oval = z133.object({
2887
2910
  expectTypesMatch(true);
2888
2911
 
2889
2912
  // src/pcb/pcb_silkscreen_graphic.ts
2890
- import { z as z134 } from "zod";
2891
- var pcb_silkscreen_graphic_base = z134.object({
2892
- type: z134.literal("pcb_silkscreen_graphic"),
2913
+ import { z as z135 } from "zod";
2914
+ var pcb_silkscreen_graphic_base = z135.object({
2915
+ type: z135.literal("pcb_silkscreen_graphic"),
2893
2916
  pcb_silkscreen_graphic_id: getZodPrefixedIdWithDefault(
2894
2917
  "pcb_silkscreen_graphic"
2895
2918
  ),
2896
- pcb_component_id: z134.string(),
2897
- pcb_group_id: z134.string().optional(),
2898
- subcircuit_id: z134.string().optional(),
2919
+ pcb_component_id: z135.string(),
2920
+ pcb_group_id: z135.string().optional(),
2921
+ subcircuit_id: z135.string().optional(),
2899
2922
  layer: visible_layer,
2900
2923
  image_asset: asset.optional()
2901
2924
  });
2902
2925
  var pcb_silkscreen_graphic_brep = pcb_silkscreen_graphic_base.extend({
2903
- shape: z134.literal("brep"),
2926
+ shape: z135.literal("brep"),
2904
2927
  brep_shape
2905
2928
  }).describe("Defines a BRep silkscreen graphic on the PCB");
2906
2929
  expectTypesMatch(
2907
2930
  true
2908
2931
  );
2909
- var pcb_silkscreen_graphic = z134.discriminatedUnion("shape", [pcb_silkscreen_graphic_brep]).describe("Defines a silkscreen graphic on the PCB");
2932
+ var pcb_silkscreen_graphic = z135.discriminatedUnion("shape", [pcb_silkscreen_graphic_brep]).describe("Defines a silkscreen graphic on the PCB");
2910
2933
  expectTypesMatch(true);
2911
2934
 
2912
2935
  // src/pcb/pcb_silkscreen_pill.ts
2913
- import { z as z135 } from "zod";
2914
- var pcb_silkscreen_pill = z135.object({
2915
- type: z135.literal("pcb_silkscreen_pill"),
2936
+ import { z as z136 } from "zod";
2937
+ var pcb_silkscreen_pill = z136.object({
2938
+ type: z136.literal("pcb_silkscreen_pill"),
2916
2939
  pcb_silkscreen_pill_id: getZodPrefixedIdWithDefault("pcb_silkscreen_pill"),
2917
- pcb_component_id: z135.string(),
2918
- pcb_group_id: z135.string().optional(),
2919
- subcircuit_id: z135.string().optional(),
2940
+ pcb_component_id: z136.string(),
2941
+ pcb_group_id: z136.string().optional(),
2942
+ subcircuit_id: z136.string().optional(),
2920
2943
  center: point,
2921
2944
  width: length,
2922
2945
  height: length,
2923
2946
  layer: layer_ref,
2924
- ccw_rotation: z135.number().optional()
2947
+ ccw_rotation: z136.number().optional()
2925
2948
  }).describe("Defines a silkscreen pill on the PCB");
2926
2949
  expectTypesMatch(true);
2927
2950
 
2928
2951
  // src/pcb/pcb_fabrication_note_text.ts
2929
- import { z as z136 } from "zod";
2930
- var pcb_fabrication_note_text = z136.object({
2931
- type: z136.literal("pcb_fabrication_note_text"),
2952
+ import { z as z137 } from "zod";
2953
+ var pcb_fabrication_note_text = z137.object({
2954
+ type: z137.literal("pcb_fabrication_note_text"),
2932
2955
  pcb_fabrication_note_text_id: getZodPrefixedIdWithDefault(
2933
2956
  "pcb_fabrication_note_text"
2934
2957
  ),
2935
- subcircuit_id: z136.string().optional(),
2936
- pcb_group_id: z136.string().optional(),
2937
- font: z136.literal("tscircuit2024").default("tscircuit2024"),
2958
+ subcircuit_id: z137.string().optional(),
2959
+ pcb_group_id: z137.string().optional(),
2960
+ font: z137.literal("tscircuit2024").default("tscircuit2024"),
2938
2961
  font_size: distance.default("1mm"),
2939
- pcb_component_id: z136.string(),
2940
- text: z136.string(),
2941
- ccw_rotation: z136.number().optional(),
2962
+ pcb_component_id: z137.string(),
2963
+ text: z137.string(),
2964
+ ccw_rotation: z137.number().optional(),
2942
2965
  layer: visible_layer,
2943
2966
  anchor_position: point.default({ x: 0, y: 0 }),
2944
- anchor_alignment: z136.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2945
- color: z136.string().optional()
2967
+ anchor_alignment: z137.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
2968
+ color: z137.string().optional()
2946
2969
  }).describe(
2947
2970
  "Defines a fabrication note in text on the PCB, useful for leaving notes for assemblers or fabricators"
2948
2971
  );
2949
2972
  expectTypesMatch(true);
2950
2973
 
2951
2974
  // src/pcb/pcb_fabrication_note_path.ts
2952
- import { z as z137 } from "zod";
2953
- var pcb_fabrication_note_path = z137.object({
2954
- type: z137.literal("pcb_fabrication_note_path"),
2975
+ import { z as z138 } from "zod";
2976
+ var pcb_fabrication_note_path = z138.object({
2977
+ type: z138.literal("pcb_fabrication_note_path"),
2955
2978
  pcb_fabrication_note_path_id: getZodPrefixedIdWithDefault(
2956
2979
  "pcb_fabrication_note_path"
2957
2980
  ),
2958
- pcb_component_id: z137.string(),
2959
- subcircuit_id: z137.string().optional(),
2981
+ pcb_component_id: z138.string(),
2982
+ subcircuit_id: z138.string().optional(),
2960
2983
  layer: layer_ref,
2961
- route: z137.array(point),
2984
+ route: z138.array(point),
2962
2985
  stroke_width: length,
2963
- color: z137.string().optional()
2986
+ color: z138.string().optional()
2964
2987
  }).describe(
2965
2988
  "Defines a fabrication path on the PCB for fabricators or assemblers"
2966
2989
  );
2967
2990
  expectTypesMatch(true);
2968
2991
 
2969
2992
  // src/pcb/pcb_fabrication_note_rect.ts
2970
- import { z as z138 } from "zod";
2971
- var pcb_fabrication_note_rect = z138.object({
2972
- type: z138.literal("pcb_fabrication_note_rect"),
2993
+ import { z as z139 } from "zod";
2994
+ var pcb_fabrication_note_rect = z139.object({
2995
+ type: z139.literal("pcb_fabrication_note_rect"),
2973
2996
  pcb_fabrication_note_rect_id: getZodPrefixedIdWithDefault(
2974
2997
  "pcb_fabrication_note_rect"
2975
2998
  ),
2976
- pcb_component_id: z138.string(),
2977
- pcb_group_id: z138.string().optional(),
2978
- subcircuit_id: z138.string().optional(),
2999
+ pcb_component_id: z139.string(),
3000
+ pcb_group_id: z139.string().optional(),
3001
+ subcircuit_id: z139.string().optional(),
2979
3002
  center: point,
2980
3003
  width: length,
2981
3004
  height: length,
2982
3005
  layer: visible_layer,
2983
3006
  stroke_width: length.default("0.1mm"),
2984
3007
  corner_radius: length.optional(),
2985
- is_filled: z138.boolean().optional(),
2986
- has_stroke: z138.boolean().optional(),
2987
- is_stroke_dashed: z138.boolean().optional(),
2988
- color: z138.string().optional()
3008
+ is_filled: z139.boolean().optional(),
3009
+ has_stroke: z139.boolean().optional(),
3010
+ is_stroke_dashed: z139.boolean().optional(),
3011
+ color: z139.string().optional()
2989
3012
  }).describe("Defines a fabrication note rectangle on the PCB");
2990
3013
  expectTypesMatch(true);
2991
3014
 
2992
3015
  // src/pcb/pcb_fabrication_note_dimension.ts
2993
- import { z as z139 } from "zod";
2994
- var pcb_fabrication_note_dimension = z139.object({
2995
- type: z139.literal("pcb_fabrication_note_dimension"),
3016
+ import { z as z140 } from "zod";
3017
+ var pcb_fabrication_note_dimension = z140.object({
3018
+ type: z140.literal("pcb_fabrication_note_dimension"),
2996
3019
  pcb_fabrication_note_dimension_id: getZodPrefixedIdWithDefault(
2997
3020
  "pcb_fabrication_note_dimension"
2998
3021
  ),
2999
- pcb_component_id: z139.string(),
3000
- pcb_group_id: z139.string().optional(),
3001
- subcircuit_id: z139.string().optional(),
3022
+ pcb_component_id: z140.string(),
3023
+ pcb_group_id: z140.string().optional(),
3024
+ subcircuit_id: z140.string().optional(),
3002
3025
  layer: visible_layer,
3003
3026
  from: point,
3004
3027
  to: point,
3005
- text: z139.string().optional(),
3006
- text_ccw_rotation: z139.number().optional(),
3028
+ text: z140.string().optional(),
3029
+ text_ccw_rotation: z140.number().optional(),
3007
3030
  offset: length.optional(),
3008
3031
  offset_distance: length.optional(),
3009
- offset_direction: z139.object({
3010
- x: z139.number(),
3011
- y: z139.number()
3032
+ offset_direction: z140.object({
3033
+ x: z140.number(),
3034
+ y: z140.number()
3012
3035
  }).optional(),
3013
- font: z139.literal("tscircuit2024").default("tscircuit2024"),
3036
+ font: z140.literal("tscircuit2024").default("tscircuit2024"),
3014
3037
  font_size: length.default("1mm"),
3015
- color: z139.string().optional(),
3038
+ color: z140.string().optional(),
3016
3039
  arrow_size: length.default("1mm")
3017
3040
  }).describe("Defines a measurement annotation within PCB fabrication notes");
3018
3041
  expectTypesMatch(true);
3019
3042
 
3020
3043
  // src/pcb/pcb_note_text.ts
3021
- import { z as z140 } from "zod";
3022
- var pcb_note_text = z140.object({
3023
- type: z140.literal("pcb_note_text"),
3024
- pcb_note_text_id: getZodPrefixedIdWithDefault("pcb_note_text"),
3025
- pcb_component_id: z140.string().optional(),
3026
- pcb_group_id: z140.string().optional(),
3027
- subcircuit_id: z140.string().optional(),
3028
- name: z140.string().optional(),
3029
- font: z140.literal("tscircuit2024").default("tscircuit2024"),
3030
- font_size: distance.default("1mm"),
3031
- text: z140.string().optional(),
3032
- anchor_position: point.default({ x: 0, y: 0 }),
3033
- anchor_alignment: z140.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
3034
- layer: visible_layer.default("top"),
3035
- is_mirrored_from_top_view: z140.boolean().optional(),
3036
- color: z140.string().optional()
3037
- }).describe("Defines a documentation note in text on the PCB");
3038
- expectTypesMatch(true);
3039
-
3040
- // src/pcb/pcb_note_rect.ts
3041
3044
  import { z as z141 } from "zod";
3042
- var pcb_note_rect = z141.object({
3043
- type: z141.literal("pcb_note_rect"),
3044
- pcb_note_rect_id: getZodPrefixedIdWithDefault("pcb_note_rect"),
3045
+ var pcb_note_text = z141.object({
3046
+ type: z141.literal("pcb_note_text"),
3047
+ pcb_note_text_id: getZodPrefixedIdWithDefault("pcb_note_text"),
3045
3048
  pcb_component_id: z141.string().optional(),
3046
3049
  pcb_group_id: z141.string().optional(),
3047
3050
  subcircuit_id: z141.string().optional(),
3048
3051
  name: z141.string().optional(),
3052
+ font: z141.literal("tscircuit2024").default("tscircuit2024"),
3053
+ font_size: distance.default("1mm"),
3049
3054
  text: z141.string().optional(),
3050
- center: point,
3051
- width: length,
3052
- height: length,
3055
+ anchor_position: point.default({ x: 0, y: 0 }),
3056
+ anchor_alignment: z141.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
3053
3057
  layer: visible_layer.default("top"),
3054
- stroke_width: length.default("0.1mm"),
3055
- corner_radius: length.optional(),
3056
- is_filled: z141.boolean().optional(),
3057
- has_stroke: z141.boolean().optional(),
3058
- is_stroke_dashed: z141.boolean().optional(),
3058
+ is_mirrored_from_top_view: z141.boolean().optional(),
3059
3059
  color: z141.string().optional()
3060
- }).describe("Defines a rectangular documentation note on the PCB");
3060
+ }).describe("Defines a documentation note in text on the PCB");
3061
3061
  expectTypesMatch(true);
3062
3062
 
3063
- // src/pcb/pcb_note_path.ts
3063
+ // src/pcb/pcb_note_rect.ts
3064
3064
  import { z as z142 } from "zod";
3065
- var pcb_note_path = z142.object({
3066
- type: z142.literal("pcb_note_path"),
3067
- pcb_note_path_id: getZodPrefixedIdWithDefault("pcb_note_path"),
3065
+ var pcb_note_rect = z142.object({
3066
+ type: z142.literal("pcb_note_rect"),
3067
+ pcb_note_rect_id: getZodPrefixedIdWithDefault("pcb_note_rect"),
3068
3068
  pcb_component_id: z142.string().optional(),
3069
3069
  pcb_group_id: z142.string().optional(),
3070
3070
  subcircuit_id: z142.string().optional(),
3071
3071
  name: z142.string().optional(),
3072
3072
  text: z142.string().optional(),
3073
- route: z142.array(point),
3073
+ center: point,
3074
+ width: length,
3075
+ height: length,
3074
3076
  layer: visible_layer.default("top"),
3075
3077
  stroke_width: length.default("0.1mm"),
3078
+ corner_radius: length.optional(),
3079
+ is_filled: z142.boolean().optional(),
3080
+ has_stroke: z142.boolean().optional(),
3081
+ is_stroke_dashed: z142.boolean().optional(),
3076
3082
  color: z142.string().optional()
3077
- }).describe("Defines a polyline documentation note on the PCB");
3083
+ }).describe("Defines a rectangular documentation note on the PCB");
3078
3084
  expectTypesMatch(true);
3079
3085
 
3080
- // src/pcb/pcb_note_line.ts
3086
+ // src/pcb/pcb_note_path.ts
3081
3087
  import { z as z143 } from "zod";
3082
- var pcb_note_line = z143.object({
3083
- type: z143.literal("pcb_note_line"),
3084
- pcb_note_line_id: getZodPrefixedIdWithDefault("pcb_note_line"),
3088
+ var pcb_note_path = z143.object({
3089
+ type: z143.literal("pcb_note_path"),
3090
+ pcb_note_path_id: getZodPrefixedIdWithDefault("pcb_note_path"),
3085
3091
  pcb_component_id: z143.string().optional(),
3086
3092
  pcb_group_id: z143.string().optional(),
3087
3093
  subcircuit_id: z143.string().optional(),
3088
3094
  name: z143.string().optional(),
3089
3095
  text: z143.string().optional(),
3096
+ route: z143.array(point),
3097
+ layer: visible_layer.default("top"),
3098
+ stroke_width: length.default("0.1mm"),
3099
+ color: z143.string().optional()
3100
+ }).describe("Defines a polyline documentation note on the PCB");
3101
+ expectTypesMatch(true);
3102
+
3103
+ // src/pcb/pcb_note_line.ts
3104
+ import { z as z144 } from "zod";
3105
+ var pcb_note_line = z144.object({
3106
+ type: z144.literal("pcb_note_line"),
3107
+ pcb_note_line_id: getZodPrefixedIdWithDefault("pcb_note_line"),
3108
+ pcb_component_id: z144.string().optional(),
3109
+ pcb_group_id: z144.string().optional(),
3110
+ subcircuit_id: z144.string().optional(),
3111
+ name: z144.string().optional(),
3112
+ text: z144.string().optional(),
3090
3113
  x1: distance,
3091
3114
  y1: distance,
3092
3115
  x2: distance,
3093
3116
  y2: distance,
3094
3117
  layer: visible_layer.default("top"),
3095
3118
  stroke_width: distance.default("0.1mm"),
3096
- color: z143.string().optional(),
3097
- is_dashed: z143.boolean().optional()
3119
+ color: z144.string().optional(),
3120
+ is_dashed: z144.boolean().optional()
3098
3121
  }).describe("Defines a straight documentation note line on the PCB");
3099
3122
  expectTypesMatch(true);
3100
3123
 
3101
3124
  // src/pcb/pcb_note_dimension.ts
3102
- import { z as z144 } from "zod";
3103
- var pcb_note_dimension = z144.object({
3104
- type: z144.literal("pcb_note_dimension"),
3125
+ import { z as z145 } from "zod";
3126
+ var pcb_note_dimension = z145.object({
3127
+ type: z145.literal("pcb_note_dimension"),
3105
3128
  pcb_note_dimension_id: getZodPrefixedIdWithDefault("pcb_note_dimension"),
3106
- pcb_component_id: z144.string().optional(),
3107
- pcb_group_id: z144.string().optional(),
3108
- subcircuit_id: z144.string().optional(),
3109
- name: z144.string().optional(),
3129
+ pcb_component_id: z145.string().optional(),
3130
+ pcb_group_id: z145.string().optional(),
3131
+ subcircuit_id: z145.string().optional(),
3132
+ name: z145.string().optional(),
3110
3133
  from: point,
3111
3134
  to: point,
3112
- text: z144.string().optional(),
3113
- text_ccw_rotation: z144.number().optional(),
3135
+ text: z145.string().optional(),
3136
+ text_ccw_rotation: z145.number().optional(),
3114
3137
  offset_distance: length.optional(),
3115
- offset_direction: z144.object({
3116
- x: z144.number(),
3117
- y: z144.number()
3138
+ offset_direction: z145.object({
3139
+ x: z145.number(),
3140
+ y: z145.number()
3118
3141
  }).optional(),
3119
- font: z144.literal("tscircuit2024").default("tscircuit2024"),
3142
+ font: z145.literal("tscircuit2024").default("tscircuit2024"),
3120
3143
  font_size: length.default("1mm"),
3121
3144
  layer: visible_layer.default("top"),
3122
- color: z144.string().optional(),
3145
+ color: z145.string().optional(),
3123
3146
  arrow_size: length.default("1mm")
3124
3147
  }).describe("Defines a measurement annotation within PCB documentation notes");
3125
3148
  expectTypesMatch(true);
3126
3149
 
3127
3150
  // src/pcb/pcb_footprint_overlap_error.ts
3128
- import { z as z145 } from "zod";
3151
+ import { z as z146 } from "zod";
3129
3152
  var pcb_footprint_overlap_error = base_circuit_json_error.extend({
3130
- type: z145.literal("pcb_footprint_overlap_error"),
3153
+ type: z146.literal("pcb_footprint_overlap_error"),
3131
3154
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
3132
- error_type: z145.literal("pcb_footprint_overlap_error").default("pcb_footprint_overlap_error"),
3133
- pcb_smtpad_ids: z145.array(z145.string()).optional(),
3134
- pcb_plated_hole_ids: z145.array(z145.string()).optional(),
3135
- pcb_hole_ids: z145.array(z145.string()).optional(),
3136
- pcb_keepout_ids: z145.array(z145.string()).optional()
3155
+ error_type: z146.literal("pcb_footprint_overlap_error").default("pcb_footprint_overlap_error"),
3156
+ pcb_smtpad_ids: z146.array(z146.string()).optional(),
3157
+ pcb_plated_hole_ids: z146.array(z146.string()).optional(),
3158
+ pcb_hole_ids: z146.array(z146.string()).optional(),
3159
+ pcb_keepout_ids: z146.array(z146.string()).optional()
3137
3160
  }).describe("Error emitted when a pcb footprint overlaps with another element");
3138
3161
  expectTypesMatch(
3139
3162
  true
3140
3163
  );
3141
3164
 
3142
3165
  // src/pcb/pcb_courtyard_overlap_error.ts
3143
- import { z as z146 } from "zod";
3166
+ import { z as z147 } from "zod";
3144
3167
  var pcb_courtyard_overlap_error = base_circuit_json_error.extend({
3145
- type: z146.literal("pcb_courtyard_overlap_error"),
3168
+ type: z147.literal("pcb_courtyard_overlap_error"),
3146
3169
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
3147
- error_type: z146.literal("pcb_courtyard_overlap_error").default("pcb_courtyard_overlap_error"),
3148
- pcb_component_ids: z146.tuple([z146.string(), z146.string()])
3170
+ error_type: z147.literal("pcb_courtyard_overlap_error").default("pcb_courtyard_overlap_error"),
3171
+ pcb_component_ids: z147.tuple([z147.string(), z147.string()])
3149
3172
  }).describe(
3150
3173
  "Error emitted when the courtyard (CrtYd) of one PCB component overlaps with the courtyard of another"
3151
3174
  );
@@ -3154,51 +3177,64 @@ expectTypesMatch(
3154
3177
  );
3155
3178
 
3156
3179
  // src/pcb/pcb_keepout.ts
3157
- import { z as z147 } from "zod";
3158
- var pcb_keepout = z147.object({
3159
- type: z147.literal("pcb_keepout"),
3160
- shape: z147.literal("rect"),
3161
- pcb_group_id: z147.string().optional(),
3162
- subcircuit_id: z147.string().optional(),
3180
+ import { z as z148 } from "zod";
3181
+ var pcb_keepout_outline = z148.object({
3182
+ type: z148.literal("pcb_keepout"),
3183
+ shape: z148.literal("outline"),
3184
+ pcb_group_id: z148.string().optional(),
3185
+ subcircuit_id: z148.string().optional(),
3186
+ outline: z148.array(point).min(2),
3187
+ stroke_width: length,
3188
+ pcb_keepout_id: z148.string(),
3189
+ layers: z148.array(z148.string()),
3190
+ description: z148.string().optional(),
3191
+ excluded_pcb_component_ids: z148.array(z148.string()).optional()
3192
+ });
3193
+ var pcb_keepout = z148.object({
3194
+ type: z148.literal("pcb_keepout"),
3195
+ shape: z148.literal("rect"),
3196
+ pcb_group_id: z148.string().optional(),
3197
+ subcircuit_id: z148.string().optional(),
3163
3198
  center: point,
3164
3199
  width: distance,
3165
3200
  height: distance,
3166
- pcb_keepout_id: z147.string(),
3167
- layers: z147.array(z147.string()),
3201
+ pcb_keepout_id: z148.string(),
3202
+ layers: z148.array(z148.string()),
3168
3203
  // Specify layers where the keepout applies
3169
- description: z147.string().optional(),
3204
+ description: z148.string().optional(),
3170
3205
  // Optional description of the keepout
3171
- excluded_pcb_component_ids: z147.array(z147.string()).optional()
3206
+ excluded_pcb_component_ids: z148.array(z148.string()).optional()
3172
3207
  }).or(
3173
- z147.object({
3174
- type: z147.literal("pcb_keepout"),
3175
- shape: z147.literal("circle"),
3176
- pcb_group_id: z147.string().optional(),
3177
- subcircuit_id: z147.string().optional(),
3208
+ z148.object({
3209
+ type: z148.literal("pcb_keepout"),
3210
+ shape: z148.literal("circle"),
3211
+ pcb_group_id: z148.string().optional(),
3212
+ subcircuit_id: z148.string().optional(),
3178
3213
  center: point,
3179
3214
  radius: distance,
3180
- pcb_keepout_id: z147.string(),
3181
- layers: z147.array(z147.string()),
3215
+ pcb_keepout_id: z148.string(),
3216
+ layers: z148.array(z148.string()),
3182
3217
  // Specify layers where the keepout applies
3183
- description: z147.string().optional(),
3218
+ description: z148.string().optional(),
3184
3219
  // Optional description of the keepout
3185
- excluded_pcb_component_ids: z147.array(z147.string()).optional()
3220
+ excluded_pcb_component_ids: z148.array(z148.string()).optional()
3186
3221
  })
3187
- );
3222
+ ).or(pcb_keepout_outline);
3223
+ expectTypesMatch(true);
3188
3224
  expectTypesMatch(true);
3189
3225
 
3190
3226
  // src/pcb/pcb_cutout.ts
3191
- import { z as z148 } from "zod";
3192
- var pcb_cutout_base = z148.object({
3193
- type: z148.literal("pcb_cutout"),
3227
+ import { z as z149 } from "zod";
3228
+ var pcb_cutout_base = z149.object({
3229
+ type: z149.literal("pcb_cutout"),
3194
3230
  pcb_cutout_id: getZodPrefixedIdWithDefault("pcb_cutout"),
3195
- pcb_group_id: z148.string().optional(),
3196
- subcircuit_id: z148.string().optional(),
3197
- pcb_board_id: z148.string().optional(),
3198
- pcb_panel_id: z148.string().optional()
3231
+ pcb_group_id: z149.string().optional(),
3232
+ subcircuit_id: z149.string().optional(),
3233
+ pcb_board_id: z149.string().optional(),
3234
+ pcb_panel_id: z149.string().optional()
3199
3235
  });
3200
3236
  var pcb_cutout_rect = pcb_cutout_base.extend({
3201
- shape: z148.literal("rect"),
3237
+ shape: z149.literal("rect"),
3202
3238
  center: point,
3203
3239
  width: length,
3204
3240
  height: length,
@@ -3207,26 +3243,26 @@ var pcb_cutout_rect = pcb_cutout_base.extend({
3207
3243
  });
3208
3244
  expectTypesMatch(true);
3209
3245
  var pcb_cutout_circle = pcb_cutout_base.extend({
3210
- shape: z148.literal("circle"),
3246
+ shape: z149.literal("circle"),
3211
3247
  center: point,
3212
3248
  radius: length
3213
3249
  });
3214
3250
  expectTypesMatch(true);
3215
3251
  var pcb_cutout_polygon = pcb_cutout_base.extend({
3216
- shape: z148.literal("polygon"),
3217
- points: z148.array(point)
3252
+ shape: z149.literal("polygon"),
3253
+ points: z149.array(point)
3218
3254
  });
3219
3255
  expectTypesMatch(true);
3220
3256
  var pcb_cutout_path = pcb_cutout_base.extend({
3221
- shape: z148.literal("path"),
3222
- route: z148.array(point),
3257
+ shape: z149.literal("path"),
3258
+ route: z149.array(point),
3223
3259
  slot_width: length,
3224
3260
  slot_length: length.optional(),
3225
3261
  space_between_slots: length.optional(),
3226
3262
  slot_corner_radius: length.optional()
3227
3263
  });
3228
3264
  expectTypesMatch(true);
3229
- var pcb_cutout = z148.discriminatedUnion("shape", [
3265
+ var pcb_cutout = z149.discriminatedUnion("shape", [
3230
3266
  pcb_cutout_rect,
3231
3267
  pcb_cutout_circle,
3232
3268
  pcb_cutout_polygon,
@@ -3235,184 +3271,184 @@ var pcb_cutout = z148.discriminatedUnion("shape", [
3235
3271
  expectTypesMatch(true);
3236
3272
 
3237
3273
  // src/pcb/pcb_missing_footprint_error.ts
3238
- import { z as z149 } from "zod";
3274
+ import { z as z150 } from "zod";
3239
3275
  var pcb_missing_footprint_error = base_circuit_json_error.extend({
3240
- type: z149.literal("pcb_missing_footprint_error"),
3276
+ type: z150.literal("pcb_missing_footprint_error"),
3241
3277
  pcb_missing_footprint_error_id: getZodPrefixedIdWithDefault(
3242
3278
  "pcb_missing_footprint_error"
3243
3279
  ),
3244
- pcb_group_id: z149.string().optional(),
3245
- subcircuit_id: z149.string().optional(),
3246
- error_type: z149.literal("pcb_missing_footprint_error").default("pcb_missing_footprint_error"),
3247
- source_component_id: z149.string()
3280
+ pcb_group_id: z150.string().optional(),
3281
+ subcircuit_id: z150.string().optional(),
3282
+ error_type: z150.literal("pcb_missing_footprint_error").default("pcb_missing_footprint_error"),
3283
+ source_component_id: z150.string()
3248
3284
  }).describe("Defines a missing footprint error on the PCB");
3249
3285
  expectTypesMatch(
3250
3286
  true
3251
3287
  );
3252
3288
 
3253
3289
  // src/pcb/external_footprint_load_error.ts
3254
- import { z as z150 } from "zod";
3290
+ import { z as z151 } from "zod";
3255
3291
  var external_footprint_load_error = base_circuit_json_error.extend({
3256
- type: z150.literal("external_footprint_load_error"),
3292
+ type: z151.literal("external_footprint_load_error"),
3257
3293
  external_footprint_load_error_id: getZodPrefixedIdWithDefault(
3258
3294
  "external_footprint_load_error"
3259
3295
  ),
3260
- pcb_component_id: z150.string(),
3261
- source_component_id: z150.string(),
3262
- pcb_group_id: z150.string().optional(),
3263
- subcircuit_id: z150.string().optional(),
3264
- footprinter_string: z150.string().optional(),
3265
- error_type: z150.literal("external_footprint_load_error").default("external_footprint_load_error")
3296
+ pcb_component_id: z151.string(),
3297
+ source_component_id: z151.string(),
3298
+ pcb_group_id: z151.string().optional(),
3299
+ subcircuit_id: z151.string().optional(),
3300
+ footprinter_string: z151.string().optional(),
3301
+ error_type: z151.literal("external_footprint_load_error").default("external_footprint_load_error")
3266
3302
  }).describe("Defines an error when an external footprint fails to load");
3267
3303
  expectTypesMatch(true);
3268
3304
 
3269
3305
  // src/pcb/circuit_json_footprint_load_error.ts
3270
- import { z as z151 } from "zod";
3306
+ import { z as z152 } from "zod";
3271
3307
  var circuit_json_footprint_load_error = base_circuit_json_error.extend({
3272
- type: z151.literal("circuit_json_footprint_load_error"),
3308
+ type: z152.literal("circuit_json_footprint_load_error"),
3273
3309
  circuit_json_footprint_load_error_id: getZodPrefixedIdWithDefault(
3274
3310
  "circuit_json_footprint_load_error"
3275
3311
  ),
3276
- pcb_component_id: z151.string(),
3277
- source_component_id: z151.string(),
3278
- pcb_group_id: z151.string().optional(),
3279
- subcircuit_id: z151.string().optional(),
3280
- error_type: z151.literal("circuit_json_footprint_load_error").default("circuit_json_footprint_load_error"),
3281
- circuit_json: z151.array(z151.any()).optional()
3312
+ pcb_component_id: z152.string(),
3313
+ source_component_id: z152.string(),
3314
+ pcb_group_id: z152.string().optional(),
3315
+ subcircuit_id: z152.string().optional(),
3316
+ error_type: z152.literal("circuit_json_footprint_load_error").default("circuit_json_footprint_load_error"),
3317
+ circuit_json: z152.array(z152.any()).optional()
3282
3318
  }).describe("Defines an error when a circuit JSON footprint fails to load");
3283
3319
  expectTypesMatch(true);
3284
3320
 
3285
3321
  // src/pcb/pcb_group.ts
3286
- import { z as z152 } from "zod";
3287
- var pcb_group = z152.object({
3288
- type: z152.literal("pcb_group"),
3322
+ import { z as z153 } from "zod";
3323
+ var pcb_group = z153.object({
3324
+ type: z153.literal("pcb_group"),
3289
3325
  pcb_group_id: getZodPrefixedIdWithDefault("pcb_group"),
3290
- source_group_id: z152.string(),
3291
- is_subcircuit: z152.boolean().optional(),
3292
- subcircuit_id: z152.string().optional(),
3326
+ source_group_id: z153.string(),
3327
+ is_subcircuit: z153.boolean().optional(),
3328
+ subcircuit_id: z153.string().optional(),
3293
3329
  width: length.optional(),
3294
3330
  height: length.optional(),
3295
3331
  center: point,
3296
- display_offset_x: z152.string().optional().describe(
3332
+ display_offset_x: z153.string().optional().describe(
3297
3333
  "How to display the x offset for this group, usually corresponding with how the user specified it"
3298
3334
  ),
3299
- display_offset_y: z152.string().optional().describe(
3335
+ display_offset_y: z153.string().optional().describe(
3300
3336
  "How to display the y offset for this group, usually corresponding with how the user specified it"
3301
3337
  ),
3302
- outline: z152.array(point).optional(),
3338
+ outline: z153.array(point).optional(),
3303
3339
  anchor_position: point.optional(),
3304
3340
  anchor_alignment: ninePointAnchor.default("center"),
3305
- position_mode: z152.enum(["packed", "relative_to_group_anchor", "none"]).optional(),
3306
- positioned_relative_to_pcb_group_id: z152.string().optional(),
3307
- positioned_relative_to_pcb_board_id: z152.string().optional(),
3308
- pcb_component_ids: z152.array(z152.string()),
3309
- child_layout_mode: z152.enum(["packed", "none"]).optional(),
3310
- name: z152.string().optional(),
3311
- description: z152.string().optional(),
3312
- layout_mode: z152.string().optional(),
3313
- autorouter_configuration: z152.object({
3341
+ position_mode: z153.enum(["packed", "relative_to_group_anchor", "none"]).optional(),
3342
+ positioned_relative_to_pcb_group_id: z153.string().optional(),
3343
+ positioned_relative_to_pcb_board_id: z153.string().optional(),
3344
+ pcb_component_ids: z153.array(z153.string()),
3345
+ child_layout_mode: z153.enum(["packed", "none"]).optional(),
3346
+ name: z153.string().optional(),
3347
+ description: z153.string().optional(),
3348
+ layout_mode: z153.string().optional(),
3349
+ autorouter_configuration: z153.object({
3314
3350
  trace_clearance: length
3315
3351
  }).optional(),
3316
- autorouter_used_string: z152.string().optional()
3352
+ autorouter_used_string: z153.string().optional()
3317
3353
  }).describe("Defines a group of components on the PCB");
3318
3354
  expectTypesMatch(true);
3319
3355
 
3320
3356
  // src/pcb/pcb_autorouting_error.ts
3321
- import { z as z153 } from "zod";
3357
+ import { z as z154 } from "zod";
3322
3358
  var pcb_autorouting_error = base_circuit_json_error.extend({
3323
- type: z153.literal("pcb_autorouting_error"),
3359
+ type: z154.literal("pcb_autorouting_error"),
3324
3360
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_autorouting_error"),
3325
- error_type: z153.literal("pcb_autorouting_error").default("pcb_autorouting_error"),
3326
- subcircuit_id: z153.string().optional()
3361
+ error_type: z154.literal("pcb_autorouting_error").default("pcb_autorouting_error"),
3362
+ subcircuit_id: z154.string().optional()
3327
3363
  }).describe("The autorouting has failed to route a portion of the board");
3328
3364
  expectTypesMatch(true);
3329
3365
 
3330
3366
  // src/pcb/pcb_manual_edit_conflict_warning.ts
3331
- import { z as z154 } from "zod";
3332
- var pcb_manual_edit_conflict_warning = z154.object({
3333
- type: z154.literal("pcb_manual_edit_conflict_warning"),
3367
+ import { z as z155 } from "zod";
3368
+ var pcb_manual_edit_conflict_warning = z155.object({
3369
+ type: z155.literal("pcb_manual_edit_conflict_warning"),
3334
3370
  pcb_manual_edit_conflict_warning_id: getZodPrefixedIdWithDefault(
3335
3371
  "pcb_manual_edit_conflict_warning"
3336
3372
  ),
3337
- warning_type: z154.literal("pcb_manual_edit_conflict_warning").default("pcb_manual_edit_conflict_warning"),
3338
- message: z154.string(),
3339
- pcb_component_id: z154.string(),
3340
- pcb_group_id: z154.string().optional(),
3341
- subcircuit_id: z154.string().optional(),
3342
- source_component_id: z154.string()
3373
+ warning_type: z155.literal("pcb_manual_edit_conflict_warning").default("pcb_manual_edit_conflict_warning"),
3374
+ message: z155.string(),
3375
+ pcb_component_id: z155.string(),
3376
+ pcb_group_id: z155.string().optional(),
3377
+ subcircuit_id: z155.string().optional(),
3378
+ source_component_id: z155.string()
3343
3379
  }).describe(
3344
3380
  "Warning emitted when a component has both manual placement and explicit pcbX/pcbY coordinates"
3345
3381
  );
3346
3382
  expectTypesMatch(true);
3347
3383
 
3348
3384
  // src/pcb/pcb_connector_not_in_accessible_orientation_warning.ts
3349
- import { z as z155 } from "zod";
3350
- var connectorOrientationDirection = z155.enum(["x-", "x+", "y+", "y-"]);
3351
- var pcb_connector_not_in_accessible_orientation_warning = z155.object({
3352
- type: z155.literal("pcb_connector_not_in_accessible_orientation_warning"),
3385
+ import { z as z156 } from "zod";
3386
+ var connectorOrientationDirection = z156.enum(["x-", "x+", "y+", "y-"]);
3387
+ var pcb_connector_not_in_accessible_orientation_warning = z156.object({
3388
+ type: z156.literal("pcb_connector_not_in_accessible_orientation_warning"),
3353
3389
  pcb_connector_not_in_accessible_orientation_warning_id: getZodPrefixedIdWithDefault(
3354
3390
  "pcb_connector_not_in_accessible_orientation_warning"
3355
3391
  ),
3356
- warning_type: z155.literal("pcb_connector_not_in_accessible_orientation_warning").default("pcb_connector_not_in_accessible_orientation_warning"),
3357
- message: z155.string(),
3358
- pcb_component_id: z155.string(),
3359
- source_component_id: z155.string().optional(),
3360
- pcb_board_id: z155.string().optional(),
3392
+ warning_type: z156.literal("pcb_connector_not_in_accessible_orientation_warning").default("pcb_connector_not_in_accessible_orientation_warning"),
3393
+ message: z156.string(),
3394
+ pcb_component_id: z156.string(),
3395
+ source_component_id: z156.string().optional(),
3396
+ pcb_board_id: z156.string().optional(),
3361
3397
  facing_direction: connectorOrientationDirection,
3362
3398
  recommended_facing_direction: connectorOrientationDirection,
3363
- subcircuit_id: z155.string().optional()
3399
+ subcircuit_id: z156.string().optional()
3364
3400
  }).describe(
3365
3401
  "Warning emitted when a connector PCB component is facing inward toward the board and should be reoriented to an outward-facing direction"
3366
3402
  );
3367
3403
  expectTypesMatch(true);
3368
3404
 
3369
3405
  // src/pcb/pcb_component_missing_courtyard_warning.ts
3370
- import { z as z156 } from "zod";
3371
- var pcb_component_missing_courtyard_warning = z156.object({
3372
- type: z156.literal("pcb_component_missing_courtyard_warning"),
3406
+ import { z as z157 } from "zod";
3407
+ var pcb_component_missing_courtyard_warning = z157.object({
3408
+ type: z157.literal("pcb_component_missing_courtyard_warning"),
3373
3409
  pcb_component_missing_courtyard_warning_id: getZodPrefixedIdWithDefault(
3374
3410
  "pcb_component_missing_courtyard_warning"
3375
3411
  ),
3376
- warning_type: z156.literal("pcb_component_missing_courtyard_warning").default("pcb_component_missing_courtyard_warning"),
3377
- message: z156.string(),
3378
- pcb_component_id: z156.string(),
3379
- source_component_id: z156.string().optional(),
3380
- subcircuit_id: z156.string().optional()
3412
+ warning_type: z157.literal("pcb_component_missing_courtyard_warning").default("pcb_component_missing_courtyard_warning"),
3413
+ message: z157.string(),
3414
+ pcb_component_id: z157.string(),
3415
+ source_component_id: z157.string().optional(),
3416
+ subcircuit_id: z157.string().optional()
3381
3417
  }).describe("Warning emitted when a PCB component has no courtyard geometry");
3382
3418
  expectTypesMatch(true);
3383
3419
 
3384
3420
  // src/pcb/supplier_footprint_mismatch_warning.ts
3385
- import { z as z157 } from "zod";
3386
- var supplier_footprint_mismatch_warning = z157.object({
3387
- type: z157.literal("supplier_footprint_mismatch_warning"),
3421
+ import { z as z158 } from "zod";
3422
+ var supplier_footprint_mismatch_warning = z158.object({
3423
+ type: z158.literal("supplier_footprint_mismatch_warning"),
3388
3424
  supplier_footprint_mismatch_warning_id: getZodPrefixedIdWithDefault(
3389
3425
  "supplier_footprint_mismatch_warning"
3390
3426
  ),
3391
- warning_type: z157.literal("supplier_footprint_mismatch_warning").default("supplier_footprint_mismatch_warning"),
3392
- message: z157.string(),
3393
- source_component_id: z157.string(),
3394
- pcb_component_id: z157.string().optional(),
3395
- pcb_group_id: z157.string().optional(),
3396
- subcircuit_id: z157.string().optional(),
3427
+ warning_type: z158.literal("supplier_footprint_mismatch_warning").default("supplier_footprint_mismatch_warning"),
3428
+ message: z158.string(),
3429
+ source_component_id: z158.string(),
3430
+ pcb_component_id: z158.string().optional(),
3431
+ pcb_group_id: z158.string().optional(),
3432
+ subcircuit_id: z158.string().optional(),
3397
3433
  supplier_name: supplier_name.optional(),
3398
- supplier_part_number: z157.string().optional(),
3399
- supplier_footprint_url: z157.string().optional(),
3400
- footprint_copper_intersection_over_union: z157.number()
3434
+ supplier_part_number: z158.string().optional(),
3435
+ supplier_footprint_url: z158.string().optional(),
3436
+ footprint_copper_intersection_over_union: z158.number()
3401
3437
  }).describe(
3402
3438
  "Warning emitted when a supplier part footprint does not match the expected footprint"
3403
3439
  );
3404
3440
  expectTypesMatch(true);
3405
3441
 
3406
3442
  // src/pcb/pcb_breakout_point.ts
3407
- import { z as z158 } from "zod";
3408
- var pcb_breakout_point = z158.object({
3409
- type: z158.literal("pcb_breakout_point"),
3443
+ import { z as z159 } from "zod";
3444
+ var pcb_breakout_point = z159.object({
3445
+ type: z159.literal("pcb_breakout_point"),
3410
3446
  pcb_breakout_point_id: getZodPrefixedIdWithDefault("pcb_breakout_point"),
3411
- pcb_group_id: z158.string(),
3412
- subcircuit_id: z158.string().optional(),
3413
- source_trace_id: z158.string().optional(),
3414
- source_port_id: z158.string().optional(),
3415
- source_net_id: z158.string().optional(),
3447
+ pcb_group_id: z159.string(),
3448
+ subcircuit_id: z159.string().optional(),
3449
+ source_trace_id: z159.string().optional(),
3450
+ source_port_id: z159.string().optional(),
3451
+ source_net_id: z159.string().optional(),
3416
3452
  layer: layer_ref.optional(),
3417
3453
  x: distance,
3418
3454
  y: distance
@@ -3422,61 +3458,61 @@ var pcb_breakout_point = z158.object({
3422
3458
  expectTypesMatch(true);
3423
3459
 
3424
3460
  // src/pcb/pcb_ground_plane.ts
3425
- import { z as z159 } from "zod";
3426
- var pcb_ground_plane = z159.object({
3427
- type: z159.literal("pcb_ground_plane"),
3461
+ import { z as z160 } from "zod";
3462
+ var pcb_ground_plane = z160.object({
3463
+ type: z160.literal("pcb_ground_plane"),
3428
3464
  pcb_ground_plane_id: getZodPrefixedIdWithDefault("pcb_ground_plane"),
3429
- source_pcb_ground_plane_id: z159.string(),
3430
- source_net_id: z159.string(),
3431
- pcb_group_id: z159.string().optional(),
3432
- subcircuit_id: z159.string().optional()
3465
+ source_pcb_ground_plane_id: z160.string(),
3466
+ source_net_id: z160.string(),
3467
+ pcb_group_id: z160.string().optional(),
3468
+ subcircuit_id: z160.string().optional()
3433
3469
  }).describe("Defines a ground plane on the PCB");
3434
3470
  expectTypesMatch(true);
3435
3471
 
3436
3472
  // src/pcb/pcb_ground_plane_region.ts
3437
- import { z as z160 } from "zod";
3438
- var pcb_ground_plane_region = z160.object({
3439
- type: z160.literal("pcb_ground_plane_region"),
3473
+ import { z as z161 } from "zod";
3474
+ var pcb_ground_plane_region = z161.object({
3475
+ type: z161.literal("pcb_ground_plane_region"),
3440
3476
  pcb_ground_plane_region_id: getZodPrefixedIdWithDefault(
3441
3477
  "pcb_ground_plane_region"
3442
3478
  ),
3443
- pcb_ground_plane_id: z160.string(),
3444
- pcb_group_id: z160.string().optional(),
3445
- subcircuit_id: z160.string().optional(),
3479
+ pcb_ground_plane_id: z161.string(),
3480
+ pcb_group_id: z161.string().optional(),
3481
+ subcircuit_id: z161.string().optional(),
3446
3482
  layer: layer_ref,
3447
- points: z160.array(point)
3483
+ points: z161.array(point)
3448
3484
  }).describe("Defines a polygon region of a ground plane");
3449
3485
  expectTypesMatch(true);
3450
3486
 
3451
3487
  // src/pcb/pcb_thermal_spoke.ts
3452
- import { z as z161 } from "zod";
3453
- var pcb_thermal_spoke = z161.object({
3454
- type: z161.literal("pcb_thermal_spoke"),
3488
+ import { z as z162 } from "zod";
3489
+ var pcb_thermal_spoke = z162.object({
3490
+ type: z162.literal("pcb_thermal_spoke"),
3455
3491
  pcb_thermal_spoke_id: getZodPrefixedIdWithDefault("pcb_thermal_spoke"),
3456
- pcb_ground_plane_id: z161.string(),
3457
- shape: z161.string(),
3458
- spoke_count: z161.number(),
3492
+ pcb_ground_plane_id: z162.string(),
3493
+ shape: z162.string(),
3494
+ spoke_count: z162.number(),
3459
3495
  spoke_thickness: distance,
3460
3496
  spoke_inner_diameter: distance,
3461
3497
  spoke_outer_diameter: distance,
3462
- pcb_plated_hole_id: z161.string().optional(),
3463
- subcircuit_id: z161.string().optional()
3498
+ pcb_plated_hole_id: z162.string().optional(),
3499
+ subcircuit_id: z162.string().optional()
3464
3500
  }).describe("Pattern for connecting a ground plane to a plated hole");
3465
3501
  expectTypesMatch(true);
3466
3502
 
3467
3503
  // src/pcb/pcb_copper_pour.ts
3468
- import { z as z162 } from "zod";
3469
- var pcb_copper_pour_base = z162.object({
3470
- type: z162.literal("pcb_copper_pour"),
3504
+ import { z as z163 } from "zod";
3505
+ var pcb_copper_pour_base = z163.object({
3506
+ type: z163.literal("pcb_copper_pour"),
3471
3507
  pcb_copper_pour_id: getZodPrefixedIdWithDefault("pcb_copper_pour"),
3472
- pcb_group_id: z162.string().optional(),
3473
- subcircuit_id: z162.string().optional(),
3508
+ pcb_group_id: z163.string().optional(),
3509
+ subcircuit_id: z163.string().optional(),
3474
3510
  layer: layer_ref,
3475
- source_net_id: z162.string().optional(),
3476
- covered_with_solder_mask: z162.boolean().optional().default(true)
3511
+ source_net_id: z163.string().optional(),
3512
+ covered_with_solder_mask: z163.boolean().optional().default(true)
3477
3513
  });
3478
3514
  var pcb_copper_pour_rect = pcb_copper_pour_base.extend({
3479
- shape: z162.literal("rect"),
3515
+ shape: z163.literal("rect"),
3480
3516
  center: point,
3481
3517
  width: length,
3482
3518
  height: length,
@@ -3484,16 +3520,16 @@ var pcb_copper_pour_rect = pcb_copper_pour_base.extend({
3484
3520
  });
3485
3521
  expectTypesMatch(true);
3486
3522
  var pcb_copper_pour_brep = pcb_copper_pour_base.extend({
3487
- shape: z162.literal("brep"),
3523
+ shape: z163.literal("brep"),
3488
3524
  brep_shape
3489
3525
  });
3490
3526
  expectTypesMatch(true);
3491
3527
  var pcb_copper_pour_polygon = pcb_copper_pour_base.extend({
3492
- shape: z162.literal("polygon"),
3493
- points: z162.array(point)
3528
+ shape: z163.literal("polygon"),
3529
+ points: z163.array(point)
3494
3530
  });
3495
3531
  expectTypesMatch(true);
3496
- var pcb_copper_pour = z162.discriminatedUnion("shape", [
3532
+ var pcb_copper_pour = z163.discriminatedUnion("shape", [
3497
3533
  pcb_copper_pour_rect,
3498
3534
  pcb_copper_pour_brep,
3499
3535
  pcb_copper_pour_polygon
@@ -3501,99 +3537,99 @@ var pcb_copper_pour = z162.discriminatedUnion("shape", [
3501
3537
  expectTypesMatch(true);
3502
3538
 
3503
3539
  // src/pcb/pcb_component_outside_board_error.ts
3504
- import { z as z163 } from "zod";
3540
+ import { z as z164 } from "zod";
3505
3541
  var pcb_component_outside_board_error = base_circuit_json_error.extend({
3506
- type: z163.literal("pcb_component_outside_board_error"),
3542
+ type: z164.literal("pcb_component_outside_board_error"),
3507
3543
  pcb_component_outside_board_error_id: getZodPrefixedIdWithDefault(
3508
3544
  "pcb_component_outside_board_error"
3509
3545
  ),
3510
- error_type: z163.literal("pcb_component_outside_board_error").default("pcb_component_outside_board_error"),
3511
- pcb_component_id: z163.string(),
3512
- pcb_board_id: z163.string(),
3546
+ error_type: z164.literal("pcb_component_outside_board_error").default("pcb_component_outside_board_error"),
3547
+ pcb_component_id: z164.string(),
3548
+ pcb_board_id: z164.string(),
3513
3549
  component_center: point,
3514
- component_bounds: z163.object({
3515
- min_x: z163.number(),
3516
- max_x: z163.number(),
3517
- min_y: z163.number(),
3518
- max_y: z163.number()
3550
+ component_bounds: z164.object({
3551
+ min_x: z164.number(),
3552
+ max_x: z164.number(),
3553
+ min_y: z164.number(),
3554
+ max_y: z164.number()
3519
3555
  }),
3520
- subcircuit_id: z163.string().optional(),
3521
- source_component_id: z163.string().optional()
3556
+ subcircuit_id: z164.string().optional(),
3557
+ source_component_id: z164.string().optional()
3522
3558
  }).describe(
3523
3559
  "Error emitted when a PCB component is placed outside the board boundaries"
3524
3560
  );
3525
3561
  expectTypesMatch(true);
3526
3562
 
3527
3563
  // src/pcb/pcb_component_not_on_board_edge_error.ts
3528
- import { z as z164 } from "zod";
3564
+ import { z as z165 } from "zod";
3529
3565
  var pcb_component_not_on_board_edge_error = base_circuit_json_error.extend({
3530
- type: z164.literal("pcb_component_not_on_board_edge_error"),
3566
+ type: z165.literal("pcb_component_not_on_board_edge_error"),
3531
3567
  pcb_component_not_on_board_edge_error_id: getZodPrefixedIdWithDefault(
3532
3568
  "pcb_component_not_on_board_edge_error"
3533
3569
  ),
3534
- error_type: z164.literal("pcb_component_not_on_board_edge_error").default("pcb_component_not_on_board_edge_error"),
3535
- pcb_component_id: z164.string(),
3536
- pcb_board_id: z164.string(),
3570
+ error_type: z165.literal("pcb_component_not_on_board_edge_error").default("pcb_component_not_on_board_edge_error"),
3571
+ pcb_component_id: z165.string(),
3572
+ pcb_board_id: z165.string(),
3537
3573
  component_center: point,
3538
- pad_to_nearest_board_edge_distance: z164.number(),
3539
- source_component_id: z164.string().optional(),
3540
- subcircuit_id: z164.string().optional()
3574
+ pad_to_nearest_board_edge_distance: z165.number(),
3575
+ source_component_id: z165.string().optional(),
3576
+ subcircuit_id: z165.string().optional()
3541
3577
  }).describe(
3542
3578
  "Error emitted when a component that must be placed on the board edge is centered away from the edge"
3543
3579
  );
3544
3580
  expectTypesMatch(true);
3545
3581
 
3546
3582
  // src/pcb/pcb_component_invalid_layer_error.ts
3547
- import { z as z165 } from "zod";
3583
+ import { z as z166 } from "zod";
3548
3584
  var pcb_component_invalid_layer_error = base_circuit_json_error.extend({
3549
- type: z165.literal("pcb_component_invalid_layer_error"),
3585
+ type: z166.literal("pcb_component_invalid_layer_error"),
3550
3586
  pcb_component_invalid_layer_error_id: getZodPrefixedIdWithDefault(
3551
3587
  "pcb_component_invalid_layer_error"
3552
3588
  ),
3553
- error_type: z165.literal("pcb_component_invalid_layer_error").default("pcb_component_invalid_layer_error"),
3554
- pcb_component_id: z165.string().optional(),
3555
- source_component_id: z165.string(),
3589
+ error_type: z166.literal("pcb_component_invalid_layer_error").default("pcb_component_invalid_layer_error"),
3590
+ pcb_component_id: z166.string().optional(),
3591
+ source_component_id: z166.string(),
3556
3592
  layer: layer_ref,
3557
- subcircuit_id: z165.string().optional()
3593
+ subcircuit_id: z166.string().optional()
3558
3594
  }).describe(
3559
3595
  "Error emitted when a component is placed on an invalid layer (components can only be on 'top' or 'bottom' layers)"
3560
3596
  );
3561
3597
  expectTypesMatch(true);
3562
3598
 
3563
3599
  // src/pcb/pcb_via_clearance_error.ts
3564
- import { z as z166 } from "zod";
3600
+ import { z as z167 } from "zod";
3565
3601
  var pcb_via_clearance_error = base_circuit_json_error.extend({
3566
- type: z166.literal("pcb_via_clearance_error"),
3602
+ type: z167.literal("pcb_via_clearance_error"),
3567
3603
  pcb_error_id: getZodPrefixedIdWithDefault("pcb_error"),
3568
- error_type: z166.literal("pcb_via_clearance_error").default("pcb_via_clearance_error"),
3569
- pcb_via_ids: z166.array(z166.string()).min(2),
3604
+ error_type: z167.literal("pcb_via_clearance_error").default("pcb_via_clearance_error"),
3605
+ pcb_via_ids: z167.array(z167.string()).min(2),
3570
3606
  minimum_clearance: distance.optional(),
3571
3607
  actual_clearance: distance.optional(),
3572
- pcb_center: z166.object({
3573
- x: z166.number().optional(),
3574
- y: z166.number().optional()
3608
+ pcb_center: z167.object({
3609
+ x: z167.number().optional(),
3610
+ y: z167.number().optional()
3575
3611
  }).optional(),
3576
- subcircuit_id: z166.string().optional()
3612
+ subcircuit_id: z167.string().optional()
3577
3613
  }).describe("Error emitted when vias are closer than the allowed clearance");
3578
3614
  expectTypesMatch(true);
3579
3615
 
3580
3616
  // src/pcb/pcb_via_trace_clearance_error.ts
3581
- import { z as z167 } from "zod";
3617
+ import { z as z168 } from "zod";
3582
3618
  var pcb_via_trace_clearance_error = base_circuit_json_error.extend({
3583
- type: z167.literal("pcb_via_trace_clearance_error"),
3619
+ type: z168.literal("pcb_via_trace_clearance_error"),
3584
3620
  pcb_via_trace_clearance_error_id: getZodPrefixedIdWithDefault(
3585
3621
  "pcb_via_trace_clearance_error"
3586
3622
  ),
3587
- error_type: z167.literal("pcb_via_trace_clearance_error").default("pcb_via_trace_clearance_error"),
3588
- pcb_via_id: z167.string(),
3589
- pcb_trace_id: z167.string(),
3623
+ error_type: z168.literal("pcb_via_trace_clearance_error").default("pcb_via_trace_clearance_error"),
3624
+ pcb_via_id: z168.string(),
3625
+ pcb_trace_id: z168.string(),
3590
3626
  minimum_clearance: distance.optional(),
3591
3627
  actual_clearance: distance.optional(),
3592
- center: z167.object({
3593
- x: z167.number().optional(),
3594
- y: z167.number().optional()
3628
+ center: z168.object({
3629
+ x: z168.number().optional(),
3630
+ y: z168.number().optional()
3595
3631
  }).optional(),
3596
- subcircuit_id: z167.string().optional()
3632
+ subcircuit_id: z168.string().optional()
3597
3633
  }).describe(
3598
3634
  "Error emitted when a via and trace are closer than the allowed clearance"
3599
3635
  );
@@ -3602,41 +3638,41 @@ expectTypesMatch(
3602
3638
  );
3603
3639
 
3604
3640
  // src/pcb/pcb_pad_pad_clearance_error.ts
3605
- import { z as z168 } from "zod";
3641
+ import { z as z169 } from "zod";
3606
3642
  var pcb_pad_pad_clearance_error = base_circuit_json_error.extend({
3607
- type: z168.literal("pcb_pad_pad_clearance_error"),
3643
+ type: z169.literal("pcb_pad_pad_clearance_error"),
3608
3644
  pcb_pad_pad_clearance_error_id: getZodPrefixedIdWithDefault(
3609
3645
  "pcb_pad_pad_clearance_error"
3610
3646
  ),
3611
- error_type: z168.literal("pcb_pad_pad_clearance_error").default("pcb_pad_pad_clearance_error"),
3612
- pcb_pad_ids: z168.array(z168.string()).min(2),
3647
+ error_type: z169.literal("pcb_pad_pad_clearance_error").default("pcb_pad_pad_clearance_error"),
3648
+ pcb_pad_ids: z169.array(z169.string()).min(2),
3613
3649
  minimum_clearance: distance.optional(),
3614
3650
  actual_clearance: distance.optional(),
3615
- center: z168.object({
3616
- x: z168.number().optional(),
3617
- y: z168.number().optional()
3651
+ center: z169.object({
3652
+ x: z169.number().optional(),
3653
+ y: z169.number().optional()
3618
3654
  }).optional(),
3619
- subcircuit_id: z168.string().optional()
3655
+ subcircuit_id: z169.string().optional()
3620
3656
  }).describe("Error emitted when pads are closer than the allowed clearance");
3621
3657
  expectTypesMatch(true);
3622
3658
 
3623
3659
  // src/pcb/pcb_pad_trace_clearance_error.ts
3624
- import { z as z169 } from "zod";
3660
+ import { z as z170 } from "zod";
3625
3661
  var pcb_pad_trace_clearance_error = base_circuit_json_error.extend({
3626
- type: z169.literal("pcb_pad_trace_clearance_error"),
3662
+ type: z170.literal("pcb_pad_trace_clearance_error"),
3627
3663
  pcb_pad_trace_clearance_error_id: getZodPrefixedIdWithDefault(
3628
3664
  "pcb_pad_trace_clearance_error"
3629
3665
  ),
3630
- error_type: z169.literal("pcb_pad_trace_clearance_error").default("pcb_pad_trace_clearance_error"),
3631
- pcb_pad_id: z169.string(),
3632
- pcb_trace_id: z169.string(),
3666
+ error_type: z170.literal("pcb_pad_trace_clearance_error").default("pcb_pad_trace_clearance_error"),
3667
+ pcb_pad_id: z170.string(),
3668
+ pcb_trace_id: z170.string(),
3633
3669
  minimum_clearance: distance.optional(),
3634
3670
  actual_clearance: distance.optional(),
3635
- center: z169.object({
3636
- x: z169.number().optional(),
3637
- y: z169.number().optional()
3671
+ center: z170.object({
3672
+ x: z170.number().optional(),
3673
+ y: z170.number().optional()
3638
3674
  }).optional(),
3639
- subcircuit_id: z169.string().optional()
3675
+ subcircuit_id: z170.string().optional()
3640
3676
  }).describe(
3641
3677
  "Error emitted when a pad and trace are closer than allowed clearance"
3642
3678
  );
@@ -3645,89 +3681,89 @@ expectTypesMatch(
3645
3681
  );
3646
3682
 
3647
3683
  // src/pcb/pcb_courtyard_rect.ts
3648
- import { z as z170 } from "zod";
3649
- var pcb_courtyard_rect = z170.object({
3650
- type: z170.literal("pcb_courtyard_rect"),
3684
+ import { z as z171 } from "zod";
3685
+ var pcb_courtyard_rect = z171.object({
3686
+ type: z171.literal("pcb_courtyard_rect"),
3651
3687
  pcb_courtyard_rect_id: getZodPrefixedIdWithDefault("pcb_courtyard_rect"),
3652
- pcb_component_id: z170.string(),
3653
- pcb_group_id: z170.string().optional(),
3654
- subcircuit_id: z170.string().optional(),
3688
+ pcb_component_id: z171.string(),
3689
+ pcb_group_id: z171.string().optional(),
3690
+ subcircuit_id: z171.string().optional(),
3655
3691
  center: point,
3656
3692
  width: length,
3657
3693
  height: length,
3658
3694
  layer: visible_layer,
3659
3695
  ccw_rotation: rotation.optional(),
3660
- color: z170.string().optional()
3696
+ color: z171.string().optional()
3661
3697
  }).describe("Defines a courtyard rectangle on the PCB");
3662
3698
  expectTypesMatch(true);
3663
3699
 
3664
3700
  // src/pcb/pcb_courtyard_outline.ts
3665
- import { z as z171 } from "zod";
3666
- var pcb_courtyard_outline = z171.object({
3667
- type: z171.literal("pcb_courtyard_outline"),
3701
+ import { z as z172 } from "zod";
3702
+ var pcb_courtyard_outline = z172.object({
3703
+ type: z172.literal("pcb_courtyard_outline"),
3668
3704
  pcb_courtyard_outline_id: getZodPrefixedIdWithDefault(
3669
3705
  "pcb_courtyard_outline"
3670
3706
  ),
3671
- pcb_component_id: z171.string(),
3672
- pcb_group_id: z171.string().optional(),
3673
- subcircuit_id: z171.string().optional(),
3707
+ pcb_component_id: z172.string(),
3708
+ pcb_group_id: z172.string().optional(),
3709
+ subcircuit_id: z172.string().optional(),
3674
3710
  layer: visible_layer,
3675
- outline: z171.array(point).min(2)
3711
+ outline: z172.array(point).min(2)
3676
3712
  }).describe("Defines a courtyard outline on the PCB");
3677
3713
  expectTypesMatch(true);
3678
3714
 
3679
3715
  // src/pcb/pcb_courtyard_polygon.ts
3680
- import { z as z172 } from "zod";
3681
- var pcb_courtyard_polygon = z172.object({
3682
- type: z172.literal("pcb_courtyard_polygon"),
3716
+ import { z as z173 } from "zod";
3717
+ var pcb_courtyard_polygon = z173.object({
3718
+ type: z173.literal("pcb_courtyard_polygon"),
3683
3719
  pcb_courtyard_polygon_id: getZodPrefixedIdWithDefault(
3684
3720
  "pcb_courtyard_polygon"
3685
3721
  ),
3686
- pcb_component_id: z172.string(),
3687
- pcb_group_id: z172.string().optional(),
3688
- subcircuit_id: z172.string().optional(),
3722
+ pcb_component_id: z173.string(),
3723
+ pcb_group_id: z173.string().optional(),
3724
+ subcircuit_id: z173.string().optional(),
3689
3725
  layer: visible_layer,
3690
- points: z172.array(point).min(3),
3691
- color: z172.string().optional()
3726
+ points: z173.array(point).min(3),
3727
+ color: z173.string().optional()
3692
3728
  }).describe("Defines a courtyard polygon on the PCB");
3693
3729
  expectTypesMatch(true);
3694
3730
 
3695
3731
  // src/pcb/pcb_courtyard_circle.ts
3696
- import { z as z173 } from "zod";
3697
- var pcb_courtyard_circle = z173.object({
3698
- type: z173.literal("pcb_courtyard_circle"),
3732
+ import { z as z174 } from "zod";
3733
+ var pcb_courtyard_circle = z174.object({
3734
+ type: z174.literal("pcb_courtyard_circle"),
3699
3735
  pcb_courtyard_circle_id: getZodPrefixedIdWithDefault(
3700
3736
  "pcb_courtyard_circle"
3701
3737
  ),
3702
- pcb_component_id: z173.string(),
3703
- pcb_group_id: z173.string().optional(),
3704
- subcircuit_id: z173.string().optional(),
3738
+ pcb_component_id: z174.string(),
3739
+ pcb_group_id: z174.string().optional(),
3740
+ subcircuit_id: z174.string().optional(),
3705
3741
  center: point,
3706
3742
  radius: length,
3707
3743
  layer: visible_layer,
3708
- color: z173.string().optional()
3744
+ color: z174.string().optional()
3709
3745
  }).describe("Defines a courtyard circle on the PCB");
3710
3746
  expectTypesMatch(true);
3711
3747
 
3712
3748
  // src/pcb/pcb_courtyard_pill.ts
3713
- import { z as z174 } from "zod";
3714
- var pcb_courtyard_pill = z174.object({
3715
- type: z174.literal("pcb_courtyard_pill"),
3749
+ import { z as z175 } from "zod";
3750
+ var pcb_courtyard_pill = z175.object({
3751
+ type: z175.literal("pcb_courtyard_pill"),
3716
3752
  pcb_courtyard_pill_id: getZodPrefixedIdWithDefault("pcb_courtyard_pill"),
3717
- pcb_component_id: z174.string(),
3718
- pcb_group_id: z174.string().optional(),
3719
- subcircuit_id: z174.string().optional(),
3753
+ pcb_component_id: z175.string(),
3754
+ pcb_group_id: z175.string().optional(),
3755
+ subcircuit_id: z175.string().optional(),
3720
3756
  center: point,
3721
3757
  width: length,
3722
3758
  height: length,
3723
3759
  radius: length,
3724
3760
  layer: visible_layer,
3725
- color: z174.string().optional()
3761
+ color: z175.string().optional()
3726
3762
  }).describe("Defines a courtyard pill on the PCB");
3727
3763
  expectTypesMatch(true);
3728
3764
 
3729
3765
  // src/cad/cad_component.ts
3730
- import { z as z175 } from "zod";
3766
+ import { z as z176 } from "zod";
3731
3767
 
3732
3768
  // src/cad/cad_model_conventions.ts
3733
3769
  var cad_model_formats = [
@@ -3758,50 +3794,50 @@ var cadModelDefaultDirectionMap = {
3758
3794
  };
3759
3795
 
3760
3796
  // src/cad/cad_component.ts
3761
- var cad_component = z175.object({
3762
- type: z175.literal("cad_component"),
3763
- cad_component_id: z175.string(),
3764
- pcb_component_id: z175.string(),
3765
- source_component_id: z175.string(),
3797
+ var cad_component = z176.object({
3798
+ type: z176.literal("cad_component"),
3799
+ cad_component_id: z176.string(),
3800
+ pcb_component_id: z176.string(),
3801
+ source_component_id: z176.string(),
3766
3802
  position: point3,
3767
3803
  rotation: point3.optional(),
3768
3804
  size: point3.optional(),
3769
3805
  layer: layer_ref.optional(),
3770
- subcircuit_id: z175.string().optional(),
3806
+ subcircuit_id: z176.string().optional(),
3771
3807
  // These are all ways to generate/load the 3d model
3772
- footprinter_string: z175.string().optional(),
3773
- model_obj_url: z175.string().optional(),
3774
- model_stl_url: z175.string().optional(),
3775
- model_3mf_url: z175.string().optional(),
3776
- model_gltf_url: z175.string().optional(),
3777
- model_glb_url: z175.string().optional(),
3778
- model_step_url: z175.string().optional(),
3779
- model_wrl_url: z175.string().optional(),
3808
+ footprinter_string: z176.string().optional(),
3809
+ model_obj_url: z176.string().optional(),
3810
+ model_stl_url: z176.string().optional(),
3811
+ model_3mf_url: z176.string().optional(),
3812
+ model_gltf_url: z176.string().optional(),
3813
+ model_glb_url: z176.string().optional(),
3814
+ model_step_url: z176.string().optional(),
3815
+ model_wrl_url: z176.string().optional(),
3780
3816
  model_asset: asset.optional(),
3781
- model_unit_to_mm_scale_factor: z175.number().optional(),
3782
- model_board_normal_direction: z175.enum(cad_model_axis_directions).optional().describe(
3817
+ model_unit_to_mm_scale_factor: z176.number().optional(),
3818
+ model_board_normal_direction: z176.enum(cad_model_axis_directions).optional().describe(
3783
3819
  `The direction in the model's coordinate space that is considered "up" or "coming out of the board surface"`
3784
3820
  ),
3785
3821
  model_origin_position: point3.optional(),
3786
- model_origin_alignment: z175.enum([
3822
+ model_origin_alignment: z176.enum([
3787
3823
  "unknown",
3788
3824
  "center",
3789
3825
  "center_of_component_on_board_surface",
3790
3826
  "bottom_center_of_component"
3791
3827
  ]).optional(),
3792
- model_object_fit: z175.enum(["contain_within_bounds", "fill_bounds"]).optional().default("contain_within_bounds"),
3793
- model_jscad: z175.any().optional(),
3794
- show_as_translucent_model: z175.boolean().optional(),
3795
- show_as_bounding_box: z175.boolean().optional(),
3796
- show_hidden_edges: z175.boolean().optional(),
3797
- anchor_alignment: z175.enum(["center", "center_of_component_on_board_surface"]).optional().default("center")
3828
+ model_object_fit: z176.enum(["contain_within_bounds", "fill_bounds"]).optional().default("contain_within_bounds"),
3829
+ model_jscad: z176.any().optional(),
3830
+ show_as_translucent_model: z176.boolean().optional(),
3831
+ show_as_bounding_box: z176.boolean().optional(),
3832
+ show_hidden_edges: z176.boolean().optional(),
3833
+ anchor_alignment: z176.enum(["center", "center_of_component_on_board_surface"]).optional().default("center")
3798
3834
  }).describe("Defines a component on the PCB");
3799
3835
  expectTypesMatch(true);
3800
3836
 
3801
3837
  // src/simulation/simulation_voltage_source.ts
3802
- import { z as z176 } from "zod";
3803
- var wave_shape = z176.enum(["sinewave", "square", "triangle", "sawtooth"]);
3804
- var percentage = z176.union([z176.string(), z176.number()]).transform((val) => {
3838
+ import { z as z177 } from "zod";
3839
+ var wave_shape = z177.enum(["sinewave", "square", "triangle", "sawtooth"]);
3840
+ var percentage = z177.union([z177.string(), z177.number()]).transform((val) => {
3805
3841
  if (typeof val === "string") {
3806
3842
  if (val.endsWith("%")) {
3807
3843
  return parseFloat(val.slice(0, -1)) / 100;
@@ -3810,32 +3846,32 @@ var percentage = z176.union([z176.string(), z176.number()]).transform((val) => {
3810
3846
  }
3811
3847
  return val;
3812
3848
  }).pipe(
3813
- z176.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3849
+ z177.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3814
3850
  );
3815
- var simulation_dc_voltage_source = z176.object({
3816
- type: z176.literal("simulation_voltage_source"),
3851
+ var simulation_dc_voltage_source = z177.object({
3852
+ type: z177.literal("simulation_voltage_source"),
3817
3853
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
3818
3854
  "simulation_voltage_source"
3819
3855
  ),
3820
- is_dc_source: z176.literal(true).optional().default(true),
3821
- positive_source_port_id: z176.string().optional(),
3822
- negative_source_port_id: z176.string().optional(),
3823
- positive_source_net_id: z176.string().optional(),
3824
- negative_source_net_id: z176.string().optional(),
3856
+ is_dc_source: z177.literal(true).optional().default(true),
3857
+ positive_source_port_id: z177.string().optional(),
3858
+ negative_source_port_id: z177.string().optional(),
3859
+ positive_source_net_id: z177.string().optional(),
3860
+ negative_source_net_id: z177.string().optional(),
3825
3861
  voltage,
3826
3862
  ac_magnitude: voltage.optional(),
3827
3863
  ac_phase: rotation.optional()
3828
3864
  }).describe("Defines a DC voltage source for simulation");
3829
- var simulation_ac_voltage_source = z176.object({
3830
- type: z176.literal("simulation_voltage_source"),
3865
+ var simulation_ac_voltage_source = z177.object({
3866
+ type: z177.literal("simulation_voltage_source"),
3831
3867
  simulation_voltage_source_id: getZodPrefixedIdWithDefault(
3832
3868
  "simulation_voltage_source"
3833
3869
  ),
3834
- is_dc_source: z176.literal(false),
3835
- terminal1_source_port_id: z176.string().optional(),
3836
- terminal2_source_port_id: z176.string().optional(),
3837
- terminal1_source_net_id: z176.string().optional(),
3838
- terminal2_source_net_id: z176.string().optional(),
3870
+ is_dc_source: z177.literal(false),
3871
+ terminal1_source_port_id: z177.string().optional(),
3872
+ terminal2_source_port_id: z177.string().optional(),
3873
+ terminal1_source_net_id: z177.string().optional(),
3874
+ terminal2_source_net_id: z177.string().optional(),
3839
3875
  voltage: voltage.optional(),
3840
3876
  frequency: frequency.optional(),
3841
3877
  peak_to_peak_voltage: voltage.optional(),
@@ -3850,14 +3886,14 @@ var simulation_ac_voltage_source = z176.object({
3850
3886
  ac_magnitude: voltage.optional(),
3851
3887
  ac_phase: rotation.optional()
3852
3888
  }).describe("Defines an AC voltage source for simulation");
3853
- var simulation_voltage_source = z176.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
3889
+ var simulation_voltage_source = z177.union([simulation_dc_voltage_source, simulation_ac_voltage_source]).describe("Defines a voltage source for simulation");
3854
3890
  expectTypesMatch(true);
3855
3891
  expectTypesMatch(true);
3856
3892
  expectTypesMatch(true);
3857
3893
 
3858
3894
  // src/simulation/simulation_current_source.ts
3859
- import { z as z177 } from "zod";
3860
- var percentage2 = z177.union([z177.string(), z177.number()]).transform((val) => {
3895
+ import { z as z178 } from "zod";
3896
+ var percentage2 = z178.union([z178.string(), z178.number()]).transform((val) => {
3861
3897
  if (typeof val === "string") {
3862
3898
  if (val.endsWith("%")) {
3863
3899
  return parseFloat(val.slice(0, -1)) / 100;
@@ -3866,32 +3902,32 @@ var percentage2 = z177.union([z177.string(), z177.number()]).transform((val) =>
3866
3902
  }
3867
3903
  return val;
3868
3904
  }).pipe(
3869
- z177.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3905
+ z178.number().min(0, "Duty cycle must be non-negative").max(1, "Duty cycle cannot be greater than 100%")
3870
3906
  );
3871
- var simulation_dc_current_source = z177.object({
3872
- type: z177.literal("simulation_current_source"),
3907
+ var simulation_dc_current_source = z178.object({
3908
+ type: z178.literal("simulation_current_source"),
3873
3909
  simulation_current_source_id: getZodPrefixedIdWithDefault(
3874
3910
  "simulation_current_source"
3875
3911
  ),
3876
- is_dc_source: z177.literal(true).optional().default(true),
3877
- positive_source_port_id: z177.string().optional(),
3878
- negative_source_port_id: z177.string().optional(),
3879
- positive_source_net_id: z177.string().optional(),
3880
- negative_source_net_id: z177.string().optional(),
3912
+ is_dc_source: z178.literal(true).optional().default(true),
3913
+ positive_source_port_id: z178.string().optional(),
3914
+ negative_source_port_id: z178.string().optional(),
3915
+ positive_source_net_id: z178.string().optional(),
3916
+ negative_source_net_id: z178.string().optional(),
3881
3917
  current,
3882
3918
  ac_magnitude: current.optional(),
3883
3919
  ac_phase: rotation.optional()
3884
3920
  }).describe("Defines a DC current source for simulation");
3885
- var simulation_ac_current_source = z177.object({
3886
- type: z177.literal("simulation_current_source"),
3921
+ var simulation_ac_current_source = z178.object({
3922
+ type: z178.literal("simulation_current_source"),
3887
3923
  simulation_current_source_id: getZodPrefixedIdWithDefault(
3888
3924
  "simulation_current_source"
3889
3925
  ),
3890
- is_dc_source: z177.literal(false),
3891
- terminal1_source_port_id: z177.string().optional(),
3892
- terminal2_source_port_id: z177.string().optional(),
3893
- terminal1_source_net_id: z177.string().optional(),
3894
- terminal2_source_net_id: z177.string().optional(),
3926
+ is_dc_source: z178.literal(false),
3927
+ terminal1_source_port_id: z178.string().optional(),
3928
+ terminal2_source_port_id: z178.string().optional(),
3929
+ terminal1_source_net_id: z178.string().optional(),
3930
+ terminal2_source_net_id: z178.string().optional(),
3895
3931
  current: current.optional(),
3896
3932
  frequency: frequency.optional(),
3897
3933
  peak_to_peak_current: current.optional(),
@@ -3901,58 +3937,58 @@ var simulation_ac_current_source = z177.object({
3901
3937
  ac_magnitude: current.optional(),
3902
3938
  ac_phase: rotation.optional()
3903
3939
  }).describe("Defines an AC current source for simulation");
3904
- var simulation_current_source = z177.union([simulation_dc_current_source, simulation_ac_current_source]).describe("Defines a current source for simulation");
3940
+ var simulation_current_source = z178.union([simulation_dc_current_source, simulation_ac_current_source]).describe("Defines a current source for simulation");
3905
3941
  expectTypesMatch(true);
3906
3942
  expectTypesMatch(true);
3907
3943
  expectTypesMatch(true);
3908
3944
 
3909
3945
  // src/simulation/simulation_experiment.ts
3910
- import { z as z179 } from "zod";
3946
+ import { z as z180 } from "zod";
3911
3947
 
3912
3948
  // src/simulation/simulation_units.ts
3913
- import { z as z178 } from "zod";
3914
- var simulation_dc_sweep_unit = z178.custom(
3949
+ import { z as z179 } from "zod";
3950
+ var simulation_dc_sweep_unit = z179.custom(
3915
3951
  (dcSweepUnit) => dcSweepUnit === "V" || dcSweepUnit === "A"
3916
3952
  );
3917
- var simulation_parameter_unit = z178.custom(
3953
+ var simulation_parameter_unit = z179.custom(
3918
3954
  (parameterUnit) => parameterUnit === "\u03A9" || parameterUnit === "F" || parameterUnit === "H" || parameterUnit === "V" || parameterUnit === "A"
3919
3955
  );
3920
3956
 
3921
3957
  // src/simulation/simulation_experiment.ts
3922
- var experiment_type = z179.union([
3923
- z179.literal("spice_dc_sweep"),
3924
- z179.literal("spice_dc_operating_point"),
3925
- z179.literal("spice_transient_analysis"),
3926
- z179.literal("spice_ac_analysis")
3958
+ var experiment_type = z180.union([
3959
+ z180.literal("spice_dc_sweep"),
3960
+ z180.literal("spice_dc_operating_point"),
3961
+ z180.literal("spice_transient_analysis"),
3962
+ z180.literal("spice_ac_analysis")
3927
3963
  ]);
3928
- var spice_simulation_options = z179.object({
3929
- method: z179.enum(["trap", "gear"]).optional(),
3930
- reltol: z179.union([z179.number(), z179.string()]).optional(),
3931
- abstol: z179.union([z179.number(), z179.string()]).optional(),
3932
- vntol: z179.union([z179.number(), z179.string()]).optional()
3964
+ var spice_simulation_options = z180.object({
3965
+ method: z180.enum(["trap", "gear"]).optional(),
3966
+ reltol: z180.union([z180.number(), z180.string()]).optional(),
3967
+ abstol: z180.union([z180.number(), z180.string()]).optional(),
3968
+ vntol: z180.union([z180.number(), z180.string()]).optional()
3933
3969
  }).describe("SPICE solver options for a simulation experiment");
3934
- var simulation_experiment = z179.object({
3935
- type: z179.literal("simulation_experiment"),
3970
+ var simulation_experiment = z180.object({
3971
+ type: z180.literal("simulation_experiment"),
3936
3972
  simulation_experiment_id: getZodPrefixedIdWithDefault(
3937
3973
  "simulation_experiment"
3938
3974
  ),
3939
- name: z179.string(),
3975
+ name: z180.string(),
3940
3976
  experiment_type,
3941
3977
  time_per_step: duration_ms.optional(),
3942
3978
  start_time_ms: ms.optional(),
3943
3979
  end_time_ms: ms.optional(),
3944
3980
  spice_options: spice_simulation_options.optional(),
3945
- dc_sweep_voltage_source_id: z179.string().optional(),
3946
- dc_sweep_current_source_id: z179.string().optional(),
3947
- dc_sweep_start: z179.number().optional(),
3948
- dc_sweep_stop: z179.number().optional(),
3949
- dc_sweep_step: z179.number().refine((dcSweepStep) => dcSweepStep !== 0).optional(),
3981
+ dc_sweep_voltage_source_id: z180.string().optional(),
3982
+ dc_sweep_current_source_id: z180.string().optional(),
3983
+ dc_sweep_start: z180.number().optional(),
3984
+ dc_sweep_stop: z180.number().optional(),
3985
+ dc_sweep_step: z180.number().refine((dcSweepStep) => dcSweepStep !== 0).optional(),
3950
3986
  dc_sweep_unit: simulation_dc_sweep_unit.optional(),
3951
- ac_sweep_type: z179.enum(["linear", "decade", "octave"]).optional(),
3952
- ac_samples_per_interval: z179.number().int().positive().optional(),
3953
- ac_sample_count: z179.number().int().positive().optional(),
3954
- ac_start_frequency_hz: z179.number().positive().optional(),
3955
- ac_stop_frequency_hz: z179.number().positive().optional()
3987
+ ac_sweep_type: z180.enum(["linear", "decade", "octave"]).optional(),
3988
+ ac_samples_per_interval: z180.number().int().positive().optional(),
3989
+ ac_sample_count: z180.number().int().positive().optional(),
3990
+ ac_start_frequency_hz: z180.number().positive().optional(),
3991
+ ac_stop_frequency_hz: z180.number().positive().optional()
3956
3992
  }).superRefine((experiment, context) => {
3957
3993
  if (experiment.experiment_type === "spice_dc_sweep") {
3958
3994
  const requiredFields = [
@@ -3964,7 +4000,7 @@ var simulation_experiment = z179.object({
3964
4000
  for (const field of requiredFields) {
3965
4001
  if (experiment[field] === void 0) {
3966
4002
  context.addIssue({
3967
- code: z179.ZodIssueCode.custom,
4003
+ code: z180.ZodIssueCode.custom,
3968
4004
  path: [field],
3969
4005
  message: `${field} is required for a DC sweep`
3970
4006
  });
@@ -3974,7 +4010,7 @@ var simulation_experiment = z179.object({
3974
4010
  const hasCurrentSource = experiment.dc_sweep_current_source_id !== void 0;
3975
4011
  if (hasVoltageSource === hasCurrentSource) {
3976
4012
  context.addIssue({
3977
- code: z179.ZodIssueCode.custom,
4013
+ code: z180.ZodIssueCode.custom,
3978
4014
  path: ["dc_sweep_voltage_source_id"],
3979
4015
  message: "Exactly one DC sweep voltage or current source ID is required"
3980
4016
  });
@@ -3983,35 +4019,35 @@ var simulation_experiment = z179.object({
3983
4019
  if (experiment.experiment_type === "spice_ac_analysis") {
3984
4020
  if (experiment.ac_sweep_type === void 0) {
3985
4021
  context.addIssue({
3986
- code: z179.ZodIssueCode.custom,
4022
+ code: z180.ZodIssueCode.custom,
3987
4023
  path: ["ac_sweep_type"],
3988
4024
  message: "ac_sweep_type is required for an AC analysis"
3989
4025
  });
3990
4026
  }
3991
4027
  if (experiment.ac_start_frequency_hz === void 0) {
3992
4028
  context.addIssue({
3993
- code: z179.ZodIssueCode.custom,
4029
+ code: z180.ZodIssueCode.custom,
3994
4030
  path: ["ac_start_frequency_hz"],
3995
4031
  message: "ac_start_frequency_hz is required for an AC analysis"
3996
4032
  });
3997
4033
  }
3998
4034
  if (experiment.ac_stop_frequency_hz === void 0) {
3999
4035
  context.addIssue({
4000
- code: z179.ZodIssueCode.custom,
4036
+ code: z180.ZodIssueCode.custom,
4001
4037
  path: ["ac_stop_frequency_hz"],
4002
4038
  message: "ac_stop_frequency_hz is required for an AC analysis"
4003
4039
  });
4004
4040
  }
4005
4041
  if (experiment.ac_sweep_type === "linear" && experiment.ac_sample_count === void 0) {
4006
4042
  context.addIssue({
4007
- code: z179.ZodIssueCode.custom,
4043
+ code: z180.ZodIssueCode.custom,
4008
4044
  path: ["ac_sample_count"],
4009
4045
  message: "ac_sample_count is required for a linear AC analysis"
4010
4046
  });
4011
4047
  }
4012
4048
  if ((experiment.ac_sweep_type === "decade" || experiment.ac_sweep_type === "octave") && experiment.ac_samples_per_interval === void 0) {
4013
4049
  context.addIssue({
4014
- code: z179.ZodIssueCode.custom,
4050
+ code: z180.ZodIssueCode.custom,
4015
4051
  path: ["ac_samples_per_interval"],
4016
4052
  message: "ac_samples_per_interval is required for decade and octave AC analyses"
4017
4053
  });
@@ -4021,87 +4057,87 @@ var simulation_experiment = z179.object({
4021
4057
  expectTypesMatch(true);
4022
4058
 
4023
4059
  // src/simulation/simulation_transient_voltage_graph.ts
4024
- import { z as z181 } from "zod";
4060
+ import { z as z182 } from "zod";
4025
4061
 
4026
4062
  // src/simulation/simulation_parameter_sweep_coordinate.ts
4027
- import { z as z180 } from "zod";
4028
- var simulation_parameter_sweep_coordinate = z180.object({
4029
- simulation_parameter_sweep_id: z180.string(),
4030
- sweep_index: z180.number().int().nonnegative(),
4031
- parameter_value: z180.number(),
4063
+ import { z as z181 } from "zod";
4064
+ var simulation_parameter_sweep_coordinate = z181.object({
4065
+ simulation_parameter_sweep_id: z181.string(),
4066
+ sweep_index: z181.number().int().nonnegative(),
4067
+ parameter_value: z181.number(),
4032
4068
  parameter_unit: simulation_parameter_unit
4033
4069
  });
4034
4070
  expectTypesMatch(true);
4035
4071
 
4036
4072
  // src/simulation/simulation_transient_voltage_graph.ts
4037
- var simulation_transient_voltage_graph = z181.object({
4038
- type: z181.literal("simulation_transient_voltage_graph"),
4073
+ var simulation_transient_voltage_graph = z182.object({
4074
+ type: z182.literal("simulation_transient_voltage_graph"),
4039
4075
  simulation_transient_voltage_graph_id: getZodPrefixedIdWithDefault(
4040
4076
  "simulation_transient_voltage_graph"
4041
4077
  ),
4042
- simulation_experiment_id: z181.string(),
4078
+ simulation_experiment_id: z182.string(),
4043
4079
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4044
- timestamps_ms: z181.array(z181.number()).optional(),
4045
- voltage_levels: z181.array(z181.number()),
4046
- source_component_id: z181.string().optional(),
4047
- subcircuit_connectivity_map_key: z181.string().optional(),
4080
+ timestamps_ms: z182.array(z182.number()).optional(),
4081
+ voltage_levels: z182.array(z182.number()),
4082
+ source_component_id: z182.string().optional(),
4083
+ subcircuit_connectivity_map_key: z182.string().optional(),
4048
4084
  time_per_step: duration_ms,
4049
4085
  start_time_ms: ms,
4050
4086
  end_time_ms: ms,
4051
- name: z181.string().optional(),
4052
- color: z181.string().optional()
4087
+ name: z182.string().optional(),
4088
+ color: z182.string().optional()
4053
4089
  }).describe("Stores voltage measurements over time for a simulation");
4054
4090
  expectTypesMatch(true);
4055
4091
 
4056
4092
  // src/simulation/simulation_transient_current_graph.ts
4057
- import { z as z182 } from "zod";
4058
- var simulation_transient_current_graph = z182.object({
4059
- type: z182.literal("simulation_transient_current_graph"),
4093
+ import { z as z183 } from "zod";
4094
+ var simulation_transient_current_graph = z183.object({
4095
+ type: z183.literal("simulation_transient_current_graph"),
4060
4096
  simulation_transient_current_graph_id: getZodPrefixedIdWithDefault(
4061
4097
  "simulation_transient_current_graph"
4062
4098
  ),
4063
- simulation_experiment_id: z182.string(),
4099
+ simulation_experiment_id: z183.string(),
4064
4100
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4065
- timestamps_ms: z182.array(z182.number()).optional(),
4066
- current_levels: z182.array(z182.number()),
4067
- source_component_id: z182.string().optional(),
4068
- subcircuit_connectivity_map_key: z182.string().optional(),
4101
+ timestamps_ms: z183.array(z183.number()).optional(),
4102
+ current_levels: z183.array(z183.number()),
4103
+ source_component_id: z183.string().optional(),
4104
+ subcircuit_connectivity_map_key: z183.string().optional(),
4069
4105
  time_per_step: duration_ms,
4070
4106
  start_time_ms: ms,
4071
4107
  end_time_ms: ms,
4072
- name: z182.string().optional(),
4073
- color: z182.string().optional()
4108
+ name: z183.string().optional(),
4109
+ color: z183.string().optional()
4074
4110
  }).describe("Stores current measurements over time for a simulation");
4075
4111
  expectTypesMatch(true);
4076
4112
 
4077
4113
  // src/simulation/simulation_switch.ts
4078
- import { z as z183 } from "zod";
4079
- var simulation_switch = z183.object({
4080
- type: z183.literal("simulation_switch"),
4114
+ import { z as z184 } from "zod";
4115
+ var simulation_switch = z184.object({
4116
+ type: z184.literal("simulation_switch"),
4081
4117
  simulation_switch_id: getZodPrefixedIdWithDefault("simulation_switch"),
4082
- source_component_id: z183.string().optional(),
4118
+ source_component_id: z184.string().optional(),
4083
4119
  closes_at: ms.optional(),
4084
4120
  opens_at: ms.optional(),
4085
- starts_closed: z183.boolean().optional(),
4121
+ starts_closed: z184.boolean().optional(),
4086
4122
  switching_frequency: frequency.optional()
4087
4123
  }).describe("Defines a switch for simulation timing control");
4088
4124
  expectTypesMatch(true);
4089
4125
 
4090
4126
  // src/simulation/simulation_voltage_probe.ts
4091
- import { z as z184 } from "zod";
4092
- var simulation_voltage_probe = z184.object({
4093
- type: z184.literal("simulation_voltage_probe"),
4127
+ import { z as z185 } from "zod";
4128
+ var simulation_voltage_probe = z185.object({
4129
+ type: z185.literal("simulation_voltage_probe"),
4094
4130
  simulation_voltage_probe_id: getZodPrefixedIdWithDefault(
4095
4131
  "simulation_voltage_probe"
4096
4132
  ),
4097
- source_component_id: z184.string().optional(),
4098
- name: z184.string().optional(),
4099
- signal_input_source_port_id: z184.string().optional(),
4100
- signal_input_source_net_id: z184.string().optional(),
4101
- reference_input_source_port_id: z184.string().optional(),
4102
- reference_input_source_net_id: z184.string().optional(),
4103
- subcircuit_id: z184.string().optional(),
4104
- color: z184.string().optional()
4133
+ source_component_id: z185.string().optional(),
4134
+ name: z185.string().optional(),
4135
+ signal_input_source_port_id: z185.string().optional(),
4136
+ signal_input_source_net_id: z185.string().optional(),
4137
+ reference_input_source_port_id: z185.string().optional(),
4138
+ reference_input_source_net_id: z185.string().optional(),
4139
+ subcircuit_id: z185.string().optional(),
4140
+ color: z185.string().optional()
4105
4141
  }).describe(
4106
4142
  "Defines a voltage probe for simulation. If a reference input is not provided, it measures against ground. If a reference input is provided, it measures the differential voltage between two points."
4107
4143
  ).superRefine((data, ctx) => {
@@ -4111,20 +4147,20 @@ var simulation_voltage_probe = z184.object({
4111
4147
  const has_nets = !!data.signal_input_source_net_id || !!data.reference_input_source_net_id;
4112
4148
  if (has_ports && has_nets) {
4113
4149
  ctx.addIssue({
4114
- code: z184.ZodIssueCode.custom,
4150
+ code: z185.ZodIssueCode.custom,
4115
4151
  message: "Cannot mix port and net connections in a differential probe."
4116
4152
  });
4117
4153
  } else if (has_ports) {
4118
4154
  if (!data.signal_input_source_port_id || !data.reference_input_source_port_id) {
4119
4155
  ctx.addIssue({
4120
- code: z184.ZodIssueCode.custom,
4156
+ code: z185.ZodIssueCode.custom,
4121
4157
  message: "Differential port probe requires both signal_input_source_port_id and reference_input_source_port_id."
4122
4158
  });
4123
4159
  }
4124
4160
  } else if (has_nets) {
4125
4161
  if (!data.signal_input_source_net_id || !data.reference_input_source_net_id) {
4126
4162
  ctx.addIssue({
4127
- code: z184.ZodIssueCode.custom,
4163
+ code: z185.ZodIssueCode.custom,
4128
4164
  message: "Differential net probe requires both signal_input_source_net_id and reference_input_source_net_id."
4129
4165
  });
4130
4166
  }
@@ -4132,7 +4168,7 @@ var simulation_voltage_probe = z184.object({
4132
4168
  } else {
4133
4169
  if (!!data.signal_input_source_port_id === !!data.signal_input_source_net_id) {
4134
4170
  ctx.addIssue({
4135
- code: z184.ZodIssueCode.custom,
4171
+ code: z185.ZodIssueCode.custom,
4136
4172
  message: "A voltage probe must have exactly one of signal_input_source_port_id or signal_input_source_net_id."
4137
4173
  });
4138
4174
  }
@@ -4141,20 +4177,20 @@ var simulation_voltage_probe = z184.object({
4141
4177
  expectTypesMatch(true);
4142
4178
 
4143
4179
  // src/simulation/simulation_current_probe.ts
4144
- import { z as z185 } from "zod";
4145
- var simulation_current_probe = z185.object({
4146
- type: z185.literal("simulation_current_probe"),
4180
+ import { z as z186 } from "zod";
4181
+ var simulation_current_probe = z186.object({
4182
+ type: z186.literal("simulation_current_probe"),
4147
4183
  simulation_current_probe_id: getZodPrefixedIdWithDefault(
4148
4184
  "simulation_current_probe"
4149
4185
  ),
4150
- source_component_id: z185.string().optional(),
4151
- name: z185.string().optional(),
4152
- positive_source_port_id: z185.string().optional(),
4153
- negative_source_port_id: z185.string().optional(),
4154
- positive_source_net_id: z185.string().optional(),
4155
- negative_source_net_id: z185.string().optional(),
4156
- subcircuit_id: z185.string().optional(),
4157
- color: z185.string().optional()
4186
+ source_component_id: z186.string().optional(),
4187
+ name: z186.string().optional(),
4188
+ positive_source_port_id: z186.string().optional(),
4189
+ negative_source_port_id: z186.string().optional(),
4190
+ positive_source_net_id: z186.string().optional(),
4191
+ negative_source_net_id: z186.string().optional(),
4192
+ subcircuit_id: z186.string().optional(),
4193
+ color: z186.string().optional()
4158
4194
  }).describe(
4159
4195
  "Defines a current probe for simulation. It measures current flowing from the positive endpoint to the negative endpoint."
4160
4196
  ).superRefine((data, ctx) => {
@@ -4166,7 +4202,7 @@ var simulation_current_probe = z185.object({
4166
4202
  const hasNets = hasPositiveNet || hasNegativeNet;
4167
4203
  if (hasPorts && hasNets) {
4168
4204
  ctx.addIssue({
4169
- code: z185.ZodIssueCode.custom,
4205
+ code: z186.ZodIssueCode.custom,
4170
4206
  message: "Cannot mix port and net connections in a current probe."
4171
4207
  });
4172
4208
  return;
@@ -4174,7 +4210,7 @@ var simulation_current_probe = z185.object({
4174
4210
  if (hasPorts) {
4175
4211
  if (!hasPositivePort || !hasNegativePort) {
4176
4212
  ctx.addIssue({
4177
- code: z185.ZodIssueCode.custom,
4213
+ code: z186.ZodIssueCode.custom,
4178
4214
  message: "Current probe using source ports requires both positive_source_port_id and negative_source_port_id."
4179
4215
  });
4180
4216
  }
@@ -4183,71 +4219,71 @@ var simulation_current_probe = z185.object({
4183
4219
  if (hasNets) {
4184
4220
  if (!hasPositiveNet || !hasNegativeNet) {
4185
4221
  ctx.addIssue({
4186
- code: z185.ZodIssueCode.custom,
4222
+ code: z186.ZodIssueCode.custom,
4187
4223
  message: "Current probe using source nets requires both positive_source_net_id and negative_source_net_id."
4188
4224
  });
4189
4225
  }
4190
4226
  return;
4191
4227
  }
4192
4228
  ctx.addIssue({
4193
- code: z185.ZodIssueCode.custom,
4229
+ code: z186.ZodIssueCode.custom,
4194
4230
  message: "A current probe must have either positive/negative source port ids or positive/negative source net ids."
4195
4231
  });
4196
4232
  });
4197
4233
  expectTypesMatch(true);
4198
4234
 
4199
4235
  // src/simulation/simulation_unknown_experiment_error.ts
4200
- import { z as z186 } from "zod";
4236
+ import { z as z187 } from "zod";
4201
4237
  var simulation_unknown_experiment_error = base_circuit_json_error.extend({
4202
- type: z186.literal("simulation_unknown_experiment_error"),
4238
+ type: z187.literal("simulation_unknown_experiment_error"),
4203
4239
  simulation_unknown_experiment_error_id: getZodPrefixedIdWithDefault(
4204
4240
  "simulation_unknown_experiment_error"
4205
4241
  ),
4206
- error_type: z186.literal("simulation_unknown_experiment_error").default("simulation_unknown_experiment_error"),
4207
- simulation_experiment_id: z186.string().optional(),
4208
- subcircuit_id: z186.string().optional()
4242
+ error_type: z187.literal("simulation_unknown_experiment_error").default("simulation_unknown_experiment_error"),
4243
+ simulation_experiment_id: z187.string().optional(),
4244
+ subcircuit_id: z187.string().optional()
4209
4245
  }).describe("An unknown error occurred during the simulation experiment.");
4210
4246
  expectTypesMatch(true);
4211
4247
 
4212
4248
  // src/simulation/simulation_parameter_sweep.ts
4213
- import { z as z187 } from "zod";
4214
- var simulation_parameter_type = z187.enum([
4249
+ import { z as z188 } from "zod";
4250
+ var simulation_parameter_type = z188.enum([
4215
4251
  "resistance",
4216
4252
  "capacitance",
4217
4253
  "inductance",
4218
4254
  "voltage",
4219
4255
  "current"
4220
4256
  ]);
4221
- var simulation_parameter_sweep_base = z187.object({
4222
- type: z187.literal("simulation_parameter_sweep"),
4257
+ var simulation_parameter_sweep_base = z188.object({
4258
+ type: z188.literal("simulation_parameter_sweep"),
4223
4259
  simulation_parameter_sweep_id: getZodPrefixedIdWithDefault(
4224
4260
  "simulation_parameter_sweep"
4225
4261
  ),
4226
- simulation_experiment_id: z187.string(),
4227
- name: z187.string().optional(),
4228
- parameter_values: z187.array(z187.number()).min(1),
4262
+ simulation_experiment_id: z188.string(),
4263
+ name: z188.string().optional(),
4264
+ parameter_values: z188.array(z188.number()).min(1),
4229
4265
  parameter_unit: simulation_parameter_unit
4230
4266
  });
4231
- var simulation_parameter_sweep = z187.discriminatedUnion("parameter_type", [
4267
+ var simulation_parameter_sweep = z188.discriminatedUnion("parameter_type", [
4232
4268
  simulation_parameter_sweep_base.extend({
4233
- parameter_type: z187.literal("resistance"),
4234
- resistor_source_component_id: z187.string()
4269
+ parameter_type: z188.literal("resistance"),
4270
+ resistor_source_component_id: z188.string()
4235
4271
  }),
4236
4272
  simulation_parameter_sweep_base.extend({
4237
- parameter_type: z187.literal("capacitance"),
4238
- capacitor_source_component_id: z187.string()
4273
+ parameter_type: z188.literal("capacitance"),
4274
+ capacitor_source_component_id: z188.string()
4239
4275
  }),
4240
4276
  simulation_parameter_sweep_base.extend({
4241
- parameter_type: z187.literal("inductance"),
4242
- inductor_source_component_id: z187.string()
4277
+ parameter_type: z188.literal("inductance"),
4278
+ inductor_source_component_id: z188.string()
4243
4279
  }),
4244
4280
  simulation_parameter_sweep_base.extend({
4245
- parameter_type: z187.literal("voltage"),
4246
- source_net_id: z187.string()
4281
+ parameter_type: z188.literal("voltage"),
4282
+ source_net_id: z188.string()
4247
4283
  }),
4248
4284
  simulation_parameter_sweep_base.extend({
4249
- parameter_type: z187.literal("current"),
4250
- current_source_component_id: z187.string()
4285
+ parameter_type: z188.literal("current"),
4286
+ current_source_component_id: z188.string()
4251
4287
  })
4252
4288
  ]).describe("Repeats a simulation experiment over component parameter values");
4253
4289
  expectTypesMatch(
@@ -4255,52 +4291,52 @@ expectTypesMatch(
4255
4291
  );
4256
4292
 
4257
4293
  // src/simulation/simulation_dc_operating_point_voltage.ts
4258
- import { z as z188 } from "zod";
4259
- var simulation_dc_operating_point_voltage = z188.object({
4260
- type: z188.literal("simulation_dc_operating_point_voltage"),
4294
+ import { z as z189 } from "zod";
4295
+ var simulation_dc_operating_point_voltage = z189.object({
4296
+ type: z189.literal("simulation_dc_operating_point_voltage"),
4261
4297
  simulation_dc_operating_point_voltage_id: getZodPrefixedIdWithDefault(
4262
4298
  "simulation_dc_operating_point_voltage"
4263
4299
  ),
4264
- simulation_experiment_id: z188.string(),
4300
+ simulation_experiment_id: z189.string(),
4265
4301
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4266
- simulation_voltage_probe_id: z188.string(),
4267
- voltage: z188.number(),
4268
- name: z188.string().optional(),
4269
- color: z188.string().optional()
4302
+ simulation_voltage_probe_id: z189.string(),
4303
+ voltage: z189.number(),
4304
+ name: z189.string().optional(),
4305
+ color: z189.string().optional()
4270
4306
  });
4271
4307
  expectTypesMatch(true);
4272
4308
 
4273
4309
  // src/simulation/simulation_dc_operating_point_current.ts
4274
- import { z as z189 } from "zod";
4275
- var simulation_dc_operating_point_current = z189.object({
4276
- type: z189.literal("simulation_dc_operating_point_current"),
4310
+ import { z as z190 } from "zod";
4311
+ var simulation_dc_operating_point_current = z190.object({
4312
+ type: z190.literal("simulation_dc_operating_point_current"),
4277
4313
  simulation_dc_operating_point_current_id: getZodPrefixedIdWithDefault(
4278
4314
  "simulation_dc_operating_point_current"
4279
4315
  ),
4280
- simulation_experiment_id: z189.string(),
4316
+ simulation_experiment_id: z190.string(),
4281
4317
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4282
- simulation_current_probe_id: z189.string(),
4283
- current: z189.number(),
4284
- name: z189.string().optional(),
4285
- color: z189.string().optional()
4318
+ simulation_current_probe_id: z190.string(),
4319
+ current: z190.number(),
4320
+ name: z190.string().optional(),
4321
+ color: z190.string().optional()
4286
4322
  });
4287
4323
  expectTypesMatch(true);
4288
4324
 
4289
4325
  // src/simulation/simulation_dc_sweep_voltage_graph.ts
4290
- import { z as z190 } from "zod";
4291
- var simulation_dc_sweep_voltage_graph = z190.object({
4292
- type: z190.literal("simulation_dc_sweep_voltage_graph"),
4326
+ import { z as z191 } from "zod";
4327
+ var simulation_dc_sweep_voltage_graph = z191.object({
4328
+ type: z191.literal("simulation_dc_sweep_voltage_graph"),
4293
4329
  simulation_dc_sweep_voltage_graph_id: getZodPrefixedIdWithDefault(
4294
4330
  "simulation_dc_sweep_voltage_graph"
4295
4331
  ),
4296
- simulation_experiment_id: z190.string(),
4332
+ simulation_experiment_id: z191.string(),
4297
4333
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4298
- simulation_voltage_probe_id: z190.string(),
4299
- sweep_values: z190.array(z190.number()),
4334
+ simulation_voltage_probe_id: z191.string(),
4335
+ sweep_values: z191.array(z191.number()),
4300
4336
  sweep_unit: simulation_dc_sweep_unit,
4301
- voltage_levels: z190.array(z190.number()),
4302
- name: z190.string().optional(),
4303
- color: z190.string().optional()
4337
+ voltage_levels: z191.array(z191.number()),
4338
+ name: z191.string().optional(),
4339
+ color: z191.string().optional()
4304
4340
  }).refine(
4305
4341
  (graph) => graph.sweep_values.length === graph.voltage_levels.length,
4306
4342
  {
@@ -4310,20 +4346,20 @@ var simulation_dc_sweep_voltage_graph = z190.object({
4310
4346
  expectTypesMatch(true);
4311
4347
 
4312
4348
  // src/simulation/simulation_dc_sweep_current_graph.ts
4313
- import { z as z191 } from "zod";
4314
- var simulation_dc_sweep_current_graph = z191.object({
4315
- type: z191.literal("simulation_dc_sweep_current_graph"),
4349
+ import { z as z192 } from "zod";
4350
+ var simulation_dc_sweep_current_graph = z192.object({
4351
+ type: z192.literal("simulation_dc_sweep_current_graph"),
4316
4352
  simulation_dc_sweep_current_graph_id: getZodPrefixedIdWithDefault(
4317
4353
  "simulation_dc_sweep_current_graph"
4318
4354
  ),
4319
- simulation_experiment_id: z191.string(),
4355
+ simulation_experiment_id: z192.string(),
4320
4356
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4321
- simulation_current_probe_id: z191.string(),
4322
- sweep_values: z191.array(z191.number()),
4357
+ simulation_current_probe_id: z192.string(),
4358
+ sweep_values: z192.array(z192.number()),
4323
4359
  sweep_unit: simulation_dc_sweep_unit,
4324
- current_levels: z191.array(z191.number()),
4325
- name: z191.string().optional(),
4326
- color: z191.string().optional()
4360
+ current_levels: z192.array(z192.number()),
4361
+ name: z192.string().optional(),
4362
+ color: z192.string().optional()
4327
4363
  }).refine(
4328
4364
  (graph) => graph.sweep_values.length === graph.current_levels.length,
4329
4365
  {
@@ -4333,29 +4369,29 @@ var simulation_dc_sweep_current_graph = z191.object({
4333
4369
  expectTypesMatch(true);
4334
4370
 
4335
4371
  // src/simulation/simulation_ac_sweep_voltage_graph.ts
4336
- import { z as z193 } from "zod";
4372
+ import { z as z194 } from "zod";
4337
4373
 
4338
4374
  // src/simulation/simulation_complex_sample.ts
4339
- import { z as z192 } from "zod";
4340
- var simulation_complex_sample = z192.object({
4341
- re: z192.number(),
4342
- im: z192.number()
4375
+ import { z as z193 } from "zod";
4376
+ var simulation_complex_sample = z193.object({
4377
+ re: z193.number(),
4378
+ im: z193.number()
4343
4379
  });
4344
4380
  expectTypesMatch(true);
4345
4381
 
4346
4382
  // src/simulation/simulation_ac_sweep_voltage_graph.ts
4347
- var simulation_ac_sweep_voltage_graph = z193.object({
4348
- type: z193.literal("simulation_ac_sweep_voltage_graph"),
4383
+ var simulation_ac_sweep_voltage_graph = z194.object({
4384
+ type: z194.literal("simulation_ac_sweep_voltage_graph"),
4349
4385
  simulation_ac_sweep_voltage_graph_id: getZodPrefixedIdWithDefault(
4350
4386
  "simulation_ac_sweep_voltage_graph"
4351
4387
  ),
4352
- simulation_experiment_id: z193.string(),
4388
+ simulation_experiment_id: z194.string(),
4353
4389
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4354
- simulation_voltage_probe_id: z193.string(),
4355
- frequencies_hz: z193.array(z193.number()),
4356
- complex_voltages: z193.array(simulation_complex_sample),
4357
- name: z193.string().optional(),
4358
- color: z193.string().optional()
4390
+ simulation_voltage_probe_id: z194.string(),
4391
+ frequencies_hz: z194.array(z194.number()),
4392
+ complex_voltages: z194.array(simulation_complex_sample),
4393
+ name: z194.string().optional(),
4394
+ color: z194.string().optional()
4359
4395
  }).refine(
4360
4396
  (graph) => graph.frequencies_hz.length === graph.complex_voltages.length,
4361
4397
  {
@@ -4365,19 +4401,19 @@ var simulation_ac_sweep_voltage_graph = z193.object({
4365
4401
  expectTypesMatch(true);
4366
4402
 
4367
4403
  // src/simulation/simulation_ac_sweep_current_graph.ts
4368
- import { z as z194 } from "zod";
4369
- var simulation_ac_sweep_current_graph = z194.object({
4370
- type: z194.literal("simulation_ac_sweep_current_graph"),
4404
+ import { z as z195 } from "zod";
4405
+ var simulation_ac_sweep_current_graph = z195.object({
4406
+ type: z195.literal("simulation_ac_sweep_current_graph"),
4371
4407
  simulation_ac_sweep_current_graph_id: getZodPrefixedIdWithDefault(
4372
4408
  "simulation_ac_sweep_current_graph"
4373
4409
  ),
4374
- simulation_experiment_id: z194.string(),
4410
+ simulation_experiment_id: z195.string(),
4375
4411
  simulation_parameter_sweep_coordinate: simulation_parameter_sweep_coordinate.optional(),
4376
- simulation_current_probe_id: z194.string(),
4377
- frequencies_hz: z194.array(z194.number()),
4378
- complex_currents: z194.array(simulation_complex_sample),
4379
- name: z194.string().optional(),
4380
- color: z194.string().optional()
4412
+ simulation_current_probe_id: z195.string(),
4413
+ frequencies_hz: z195.array(z195.number()),
4414
+ complex_currents: z195.array(simulation_complex_sample),
4415
+ name: z195.string().optional(),
4416
+ color: z195.string().optional()
4381
4417
  }).refine(
4382
4418
  (graph) => graph.frequencies_hz.length === graph.complex_currents.length,
4383
4419
  {
@@ -4387,52 +4423,52 @@ var simulation_ac_sweep_current_graph = z194.object({
4387
4423
  expectTypesMatch(true);
4388
4424
 
4389
4425
  // src/simulation/simulation_op_amp.ts
4390
- import { z as z195 } from "zod";
4391
- var simulation_op_amp = z195.object({
4392
- type: z195.literal("simulation_op_amp"),
4426
+ import { z as z196 } from "zod";
4427
+ var simulation_op_amp = z196.object({
4428
+ type: z196.literal("simulation_op_amp"),
4393
4429
  simulation_op_amp_id: getZodPrefixedIdWithDefault("simulation_op_amp"),
4394
- source_component_id: z195.string().optional(),
4395
- inverting_input_source_port_id: z195.string(),
4396
- non_inverting_input_source_port_id: z195.string(),
4397
- output_source_port_id: z195.string(),
4398
- positive_supply_source_port_id: z195.string(),
4399
- negative_supply_source_port_id: z195.string()
4430
+ source_component_id: z196.string().optional(),
4431
+ inverting_input_source_port_id: z196.string(),
4432
+ non_inverting_input_source_port_id: z196.string(),
4433
+ output_source_port_id: z196.string(),
4434
+ positive_supply_source_port_id: z196.string(),
4435
+ negative_supply_source_port_id: z196.string()
4400
4436
  }).describe("Defines a simple ideal operational amplifier for simulation");
4401
4437
  expectTypesMatch(true);
4402
4438
 
4403
4439
  // src/simulation/simulation_spice_subcircuit.ts
4404
- import { z as z196 } from "zod";
4405
- var simulation_spice_subcircuit = z196.object({
4406
- type: z196.literal("simulation_spice_subcircuit"),
4440
+ import { z as z197 } from "zod";
4441
+ var simulation_spice_subcircuit = z197.object({
4442
+ type: z197.literal("simulation_spice_subcircuit"),
4407
4443
  simulation_spice_subcircuit_id: getZodPrefixedIdWithDefault(
4408
4444
  "simulation_spice_subcircuit"
4409
4445
  ),
4410
- source_component_id: z196.string(),
4411
- spice_pin_to_source_port_map: z196.record(z196.string(), z196.string()),
4412
- subcircuit_source: z196.string()
4446
+ source_component_id: z197.string(),
4447
+ spice_pin_to_source_port_map: z197.record(z197.string(), z197.string()),
4448
+ subcircuit_source: z197.string()
4413
4449
  }).describe("Defines a custom SPICE subcircuit model for simulation");
4414
4450
  expectTypesMatch(
4415
4451
  true
4416
4452
  );
4417
4453
 
4418
4454
  // src/simulation/simulation_oscilloscope_trace.ts
4419
- import { z as z197 } from "zod";
4455
+ import { z as z198 } from "zod";
4420
4456
  var hasValue = (value) => value !== void 0;
4421
- var simulation_oscilloscope_trace = z197.object({
4422
- type: z197.literal("simulation_oscilloscope_trace"),
4457
+ var simulation_oscilloscope_trace = z198.object({
4458
+ type: z198.literal("simulation_oscilloscope_trace"),
4423
4459
  simulation_oscilloscope_trace_id: getZodPrefixedIdWithDefault(
4424
4460
  "simulation_oscilloscope_trace"
4425
4461
  ),
4426
- simulation_transient_voltage_graph_id: z197.string().optional(),
4427
- simulation_transient_current_graph_id: z197.string().optional(),
4428
- simulation_voltage_probe_id: z197.string().optional(),
4429
- simulation_current_probe_id: z197.string().optional(),
4430
- display_name: z197.string().optional(),
4431
- color: z197.string().optional(),
4432
- display_center_value: z197.number().optional(),
4433
- display_center_offset_divs: z197.number().optional(),
4434
- volts_per_div: z197.number().positive().optional(),
4435
- amps_per_div: z197.number().positive().optional()
4462
+ simulation_transient_voltage_graph_id: z198.string().optional(),
4463
+ simulation_transient_current_graph_id: z198.string().optional(),
4464
+ simulation_voltage_probe_id: z198.string().optional(),
4465
+ simulation_current_probe_id: z198.string().optional(),
4466
+ display_name: z198.string().optional(),
4467
+ color: z198.string().optional(),
4468
+ display_center_value: z198.number().optional(),
4469
+ display_center_offset_divs: z198.number().optional(),
4470
+ volts_per_div: z198.number().positive().optional(),
4471
+ amps_per_div: z198.number().positive().optional()
4436
4472
  }).describe(
4437
4473
  "Defines how a simulation measurement is rendered as an oscilloscope-style trace."
4438
4474
  ).superRefine((data, ctx) => {
@@ -4446,19 +4482,19 @@ var simulation_oscilloscope_trace = z197.object({
4446
4482
  ].filter(hasValue).length;
4447
4483
  if (voltageReferences + currentReferences !== 1) {
4448
4484
  ctx.addIssue({
4449
- code: z197.ZodIssueCode.custom,
4485
+ code: z198.ZodIssueCode.custom,
4450
4486
  message: "An oscilloscope trace must reference exactly one voltage graph, current graph, voltage probe, or current probe."
4451
4487
  });
4452
4488
  }
4453
4489
  if (voltageReferences > 0 && data.amps_per_div !== void 0) {
4454
4490
  ctx.addIssue({
4455
- code: z197.ZodIssueCode.custom,
4491
+ code: z198.ZodIssueCode.custom,
4456
4492
  message: "Voltage oscilloscope traces must use volts_per_div, not amps_per_div."
4457
4493
  });
4458
4494
  }
4459
4495
  if (currentReferences > 0 && data.volts_per_div !== void 0) {
4460
4496
  ctx.addIssue({
4461
- code: z197.ZodIssueCode.custom,
4497
+ code: z198.ZodIssueCode.custom,
4462
4498
  message: "Current oscilloscope traces must use amps_per_div, not volts_per_div."
4463
4499
  });
4464
4500
  }
@@ -4466,8 +4502,8 @@ var simulation_oscilloscope_trace = z197.object({
4466
4502
  expectTypesMatch(true);
4467
4503
 
4468
4504
  // src/any_circuit_element.ts
4469
- import { z as z198 } from "zod";
4470
- var any_circuit_element = z198.union([
4505
+ import { z as z199 } from "zod";
4506
+ var any_circuit_element = z199.union([
4471
4507
  source_trace,
4472
4508
  source_port,
4473
4509
  source_component_internal_connection,
@@ -4603,6 +4639,7 @@ var any_circuit_element = z198.union([
4603
4639
  schematic_component_overlap_warning,
4604
4640
  schematic_component_styling_warning,
4605
4641
  schematic_element_outside_sheet_warning,
4642
+ schematic_graphic,
4606
4643
  schematic_group,
4607
4644
  schematic_sheet,
4608
4645
  schematic_table,
@@ -4727,6 +4764,7 @@ export {
4727
4764
  pcb_hole_rect_shape,
4728
4765
  pcb_hole_rotated_pill_shape,
4729
4766
  pcb_keepout,
4767
+ pcb_keepout_outline,
4730
4768
  pcb_manual_edit_conflict_warning,
4731
4769
  pcb_missing_footprint_error,
4732
4770
  pcb_net,
@@ -4801,6 +4839,7 @@ export {
4801
4839
  schematic_debug_rect,
4802
4840
  schematic_element_outside_sheet_warning,
4803
4841
  schematic_error,
4842
+ schematic_graphic,
4804
4843
  schematic_group,
4805
4844
  schematic_layout_error,
4806
4845
  schematic_line,