@tscircuit/props 0.0.328 → 0.0.329

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -37,7 +37,7 @@ resistorProps.parse({ resistance: "10k" } as ResistorPropsInput);
37
37
  | `<footprint />` | [`FootprintProps`](#footprintprops-footprint) |
38
38
  | `<fuse />` | [`FuseProps`](#fuseprops-fuse) |
39
39
  | `<group />` | [`BaseGroupProps`](#basegroupprops-group) |
40
- | `<hole />` | [`HoleProps`](#holeprops-hole) |
40
+ | `<hole />` | [`CircleHoleProps`](#circleholeprops-hole) |
41
41
  | `<inductor />` | [`InductorProps`](#inductorprops-inductor) |
42
42
  | `<jumper />` | [`JumperProps`](#jumperprops-jumper) |
43
43
  | `<mosfet />` | [`MosfetProps`](#mosfetprops-mosfet) |
@@ -461,6 +461,21 @@ export interface BaseGroupProps extends CommonLayoutProps, LayoutConfig {
461
461
  */
462
462
  schTitle?: string;
463
463
 
464
+ /**
465
+ * If true, render this group as a single schematic box
466
+ */
467
+ showAsSchematicBox?: boolean;
468
+
469
+ /**
470
+ * Mapping of external pin names to internal connection targets
471
+ */
472
+ connections?: Connections;
473
+
474
+ /**
475
+ * Arrangement for pins when rendered as a schematic box
476
+ */
477
+ schPinArrangement?: SchematicPinArrangement;
478
+
464
479
  pcbWidth?: Distance;
465
480
  pcbHeight?: Distance;
466
481
  schWidth?: Distance;
@@ -547,14 +562,6 @@ export interface BaseGroupProps extends CommonLayoutProps, LayoutConfig {
547
562
 
548
563
  [Source](https://github.com/tscircuit/props/blob/main/lib/components/group.ts)
549
564
 
550
- ### HoleProps `<hole />`
551
-
552
- ```ts
553
- export type HoleProps = CircleHoleProps | PillHoleProps;
554
- ```
555
-
556
- [Source](https://github.com/tscircuit/props/blob/main/lib/components/hole.ts)
557
-
558
565
  ### CircleHoleProps `<hole />`
559
566
 
560
567
  ```ts
@@ -568,19 +575,6 @@ export interface CircleHoleProps extends PcbLayoutProps {
568
575
 
569
576
  [Source](https://github.com/tscircuit/props/blob/main/lib/components/hole.ts)
570
577
 
571
- ### PillHoleProps `<hole />`
572
-
573
- ```ts
574
- export interface PillHoleProps extends PcbLayoutProps {
575
- name?: string;
576
- shape: "pill";
577
- width: Distance;
578
- height: Distance;
579
- }
580
- ```
581
-
582
- [Source](https://github.com/tscircuit/props/blob/main/lib/components/hole.ts)
583
-
584
578
  ### InductorProps `<inductor />`
585
579
 
586
580
  ```ts
@@ -901,6 +895,7 @@ export interface RectSmtPadProps extends Omit<PcbLayoutProps, "pcbRotation"> {
901
895
  shape: "rect";
902
896
  width: Distance;
903
897
  height: Distance;
898
+ rectBorderRadius?: Distance;
904
899
  portHints?: PortHints;
905
900
  coveredWithSolderMask?: boolean;
906
901
  }
@@ -1074,6 +1069,15 @@ export interface VoltageSourceProps<PinLabel extends string = string>
1074
1069
  ### PlatformConfig
1075
1070
 
1076
1071
  ```ts
1072
+ export interface FootprintLibraryResult {
1073
+ footprintCircuitJson: any[];
1074
+ cadModel?: CadModelProp;
1075
+ }
1076
+
1077
+ export interface FootprintFileParserEntry {
1078
+ loadFromUrl: (url: string) => Promise<FootprintLibraryResult>;
1079
+ }
1080
+
1077
1081
  export interface PlatformConfig {
1078
1082
  partsEngine?: PartsEngine;
1079
1083
 
@@ -1104,6 +1108,8 @@ export interface PlatformConfig {
1104
1108
  any[] | ((path: string) => Promise<FootprintLibraryResult>)
1105
1109
  >
1106
1110
  >;
1111
+
1112
+ footprintFileParserMap?: Record<string, FootprintFileParserEntry>;
1107
1113
  }
1108
1114
  ```
1109
1115
 
package/dist/index.d.ts CHANGED
@@ -22373,8 +22373,8 @@ interface CircularHoleWithRectPlatedProps extends Omit<PcbLayoutProps, "pcbRotat
22373
22373
  holeShape?: "circle";
22374
22374
  padShape?: "rect";
22375
22375
  portHints?: PortHints;
22376
- pcbHoleOffsetX?: number | string;
22377
- pcbHoleOffsetY?: number | string;
22376
+ holeOffsetX?: number | string;
22377
+ holeOffsetY?: number | string;
22378
22378
  }
22379
22379
  interface PillWithRectPadPlatedHoleProps extends Omit<PcbLayoutProps, "pcbRotation" | "layer"> {
22380
22380
  name?: string;
@@ -22387,6 +22387,8 @@ interface PillWithRectPadPlatedHoleProps extends Omit<PcbLayoutProps, "pcbRotati
22387
22387
  rectPadWidth: number | string;
22388
22388
  rectPadHeight: number | string;
22389
22389
  portHints?: PortHints;
22390
+ holeOffsetX?: number | string;
22391
+ holeOffsetY?: number | string;
22390
22392
  }
22391
22393
  type PlatedHoleProps = CirclePlatedHoleProps | OvalPlatedHoleProps | PillPlatedHoleProps | CircularHoleWithRectPlatedProps | PillWithRectPadPlatedHoleProps;
22392
22394
  declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.ZodObject<Omit<{
@@ -22648,8 +22650,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22648
22650
  holeShape: z.ZodOptional<z.ZodLiteral<"circle">>;
22649
22651
  padShape: z.ZodOptional<z.ZodLiteral<"rect">>;
22650
22652
  portHints: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber]>, "many">>;
22651
- pcbHoleOffsetX: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22652
- pcbHoleOffsetY: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22653
+ holeOffsetX: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22654
+ holeOffsetY: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22653
22655
  }, "strip", z.ZodTypeAny, {
22654
22656
  shape: "circular_hole_with_rect_pad";
22655
22657
  holeDiameter: number;
@@ -22672,8 +22674,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22672
22674
  rectBorderRadius?: number | undefined;
22673
22675
  holeShape?: "circle" | undefined;
22674
22676
  padShape?: "rect" | undefined;
22675
- pcbHoleOffsetX?: number | undefined;
22676
- pcbHoleOffsetY?: number | undefined;
22677
+ holeOffsetX?: number | undefined;
22678
+ holeOffsetY?: number | undefined;
22677
22679
  }, {
22678
22680
  shape: "circular_hole_with_rect_pad";
22679
22681
  holeDiameter: string | number;
@@ -22696,8 +22698,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22696
22698
  rectBorderRadius?: string | number | undefined;
22697
22699
  holeShape?: "circle" | undefined;
22698
22700
  padShape?: "rect" | undefined;
22699
- pcbHoleOffsetX?: string | number | undefined;
22700
- pcbHoleOffsetY?: string | number | undefined;
22701
+ holeOffsetX?: string | number | undefined;
22702
+ holeOffsetY?: string | number | undefined;
22701
22703
  }>, z.ZodObject<Omit<{
22702
22704
  pcbX: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22703
22705
  pcbY: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
@@ -22731,6 +22733,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22731
22733
  rectPadWidth: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
22732
22734
  rectPadHeight: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
22733
22735
  portHints: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber]>, "many">>;
22736
+ holeOffsetX: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22737
+ holeOffsetY: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
22734
22738
  }, "strip", z.ZodTypeAny, {
22735
22739
  shape: "pill_hole_with_rect_pad";
22736
22740
  holeWidth: number;
@@ -22753,6 +22757,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22753
22757
  name?: string | undefined;
22754
22758
  connectsTo?: string | string[] | undefined;
22755
22759
  portHints?: (string | number)[] | undefined;
22760
+ holeOffsetX?: number | undefined;
22761
+ holeOffsetY?: number | undefined;
22756
22762
  }, {
22757
22763
  shape: "pill_hole_with_rect_pad";
22758
22764
  holeWidth: string | number;
@@ -22775,6 +22781,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22775
22781
  name?: string | undefined;
22776
22782
  connectsTo?: string | string[] | undefined;
22777
22783
  portHints?: (string | number)[] | undefined;
22784
+ holeOffsetX?: string | number | undefined;
22785
+ holeOffsetY?: string | number | undefined;
22778
22786
  }>]>, {
22779
22787
  shape: "circle";
22780
22788
  holeDiameter: number;
@@ -22862,8 +22870,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22862
22870
  rectBorderRadius?: number | undefined;
22863
22871
  holeShape?: "circle" | undefined;
22864
22872
  padShape?: "rect" | undefined;
22865
- pcbHoleOffsetX?: number | undefined;
22866
- pcbHoleOffsetY?: number | undefined;
22873
+ holeOffsetX?: number | undefined;
22874
+ holeOffsetY?: number | undefined;
22867
22875
  } | {
22868
22876
  shape: "pill_hole_with_rect_pad";
22869
22877
  holeWidth: number;
@@ -22886,6 +22894,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22886
22894
  name?: string | undefined;
22887
22895
  connectsTo?: string | string[] | undefined;
22888
22896
  portHints?: (string | number)[] | undefined;
22897
+ holeOffsetX?: number | undefined;
22898
+ holeOffsetY?: number | undefined;
22889
22899
  }, {
22890
22900
  shape: "circle";
22891
22901
  holeDiameter: string | number;
@@ -22973,8 +22983,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22973
22983
  rectBorderRadius?: string | number | undefined;
22974
22984
  holeShape?: "circle" | undefined;
22975
22985
  padShape?: "rect" | undefined;
22976
- pcbHoleOffsetX?: string | number | undefined;
22977
- pcbHoleOffsetY?: string | number | undefined;
22986
+ holeOffsetX?: string | number | undefined;
22987
+ holeOffsetY?: string | number | undefined;
22978
22988
  } | {
22979
22989
  shape: "pill_hole_with_rect_pad";
22980
22990
  holeWidth: string | number;
@@ -22997,6 +23007,8 @@ declare const platedHoleProps: z.ZodEffects<z.ZodDiscriminatedUnion<"shape", [z.
22997
23007
  name?: string | undefined;
22998
23008
  connectsTo?: string | string[] | undefined;
22999
23009
  portHints?: (string | number)[] | undefined;
23010
+ holeOffsetX?: string | number | undefined;
23011
+ holeOffsetY?: string | number | undefined;
23000
23012
  }>;
23001
23013
 
23002
23014
  declare const resistorPinLabels: readonly ["pin1", "pin2", "pos", "neg"];
@@ -48338,6 +48350,9 @@ interface FootprintLibraryResult {
48338
48350
  footprintCircuitJson: any[];
48339
48351
  cadModel?: CadModelProp;
48340
48352
  }
48353
+ interface FootprintFileParserEntry {
48354
+ loadFromUrl: (url: string) => Promise<FootprintLibraryResult>;
48355
+ }
48341
48356
  interface PlatformConfig {
48342
48357
  partsEngine?: PartsEngine;
48343
48358
  autorouter?: AutorouterProp;
@@ -48353,6 +48368,7 @@ interface PlatformConfig {
48353
48368
  schematicDisabled?: boolean;
48354
48369
  partsEngineDisabled?: boolean;
48355
48370
  footprintLibraryMap?: Record<string, ((path: string) => Promise<FootprintLibraryResult>) | Record<string, any[] | ((path: string) => Promise<FootprintLibraryResult>)>>;
48371
+ footprintFileParserMap?: Record<string, FootprintFileParserEntry>;
48356
48372
  }
48357
48373
  declare const platformConfig: z.ZodType<PlatformConfig>;
48358
48374
 
@@ -48360,4 +48376,4 @@ interface ProjectConfig extends Pick<PlatformConfig, "projectName" | "projectBas
48360
48376
  }
48361
48377
  declare const projectConfig: z.ZodType<ProjectConfig>;
48362
48378
 
48363
- export { type AutocompleteString, type AutorouterConfig, type AutorouterProp, type BaseGroupProps, type BaseManualEditEvent, type BaseManualEditEventInput, type BasicFootprint, type BatteryPinLabels, type BatteryProps, type BoardProps, type Border, type BreakoutPointProps, type BreakoutProps, type CadAssemblyProps, type CadAssemblyPropsInput, type CadModelBase, type CadModelGlb, type CadModelGltf, type CadModelJscad, type CadModelObj, type CadModelProp, type CadModelProps, type CadModelPropsInput, type CadModelStep, type CadModelStl, type CadModelWrl, type CapacitorPinLabels, type CapacitorProps, type ChipConnections, type ChipPinLabels, type ChipProps, type ChipPropsSU, type CircleCutoutProps, type CircleHoleProps, type CirclePlatedHoleProps, type CircleSmtPadProps, type CircleSolderPasteProps, type CircularHoleWithRectPlatedProps, type CommonComponentProps, type CommonLayoutProps, type ComponentProps, type ConnectionTarget, type Connections, type ConnectorProps, type ConstrainedLayoutProps, type ConstraintProps, type CopperPourProps, type CopperPourPropsInput, type CrystalPinLabels, type CrystalProps, type CutoutProps, type CutoutPropsInput, type DiodePinLabels, type DiodeProps, type Direction, type DirectionAlongEdge, type EditPcbComponentLocationEvent, type EditPcbComponentLocationEventInput, type EditPcbGroupLocationEvent, type EditPcbGroupLocationEventInput, type EditSchematicComponentLocationEvent, type EditSchematicComponentLocationEventInput, type EditSchematicGroupLocationEvent, type EditSchematicGroupLocationEventInput, type EditTraceHintEvent, type EditTraceHintEventInput, type FabricationNotePathProps, type FabricationNoteTextProps, type FootprintLibraryResult, type FootprintProp, type FootprintProps, type FootprintPropsInput, type FootprintSoupElements, type FusePinLabels, type FuseProps, type GroupProps, type HoleProps, type InductorPinLabels, type InductorProps, type InferredChipProps, type InferredConstrainedLayoutProps, type InferredDiodeProps, type InferredFuseProps, type InferredHoleProps, type InferredSmtPadProps, type InferredSolderPasteProps, type InferredSwitchProps, type InferredTestpointProps, type InferredViaProps, type JumperProps, type KicadAutocompleteStringPath, type KicadPath, type LayoutConfig, type LedPinLabels, type LedProps, type ManualEditEvent, type ManualEditEventInput, type ManualEditsFile, type ManualEditsFileInput, type ManualPcbPlacement, type ManualPcbPlacementInput, type ManualSchematicPlacement, type ManualSchematicPlacementInput, type ManualTraceHint, type ManualTraceHintInput, type MosfetPinLabels, type MosfetProps, type NetAliasProps, type NetLabelProps, type NetProps, type NonSubcircuitGroupProps, type OvalPlatedHoleProps, type PartsEngine, type PcbKeepoutProps, type PcbLayoutProps, type PcbRouteCache, type PcbSameXConstraint, type PcbSameYConstraint, type PcbTraceProps, type PcbXDistConstraint, type PcbYDistConstraint, type PillHoleProps, type PillPlatedHoleProps, type PillSmtPadProps, type PillWithRectPadPlatedHoleProps, type PinAttributeMap, type PinCompatibleVariant, type PinHeaderProps, type PinLabelFromPinLabelMap, type PinLabelsProp, type PinSideDefinition, type PinVariant, type PinoutProps, type PlatedHoleProps, type PlatformConfig, type PolygonCutoutProps, type PolygonSmtPadProps, type PortHints, type PortProps, type PotentiometerPinVariant, type PotentiometerProps, type PowerSourceProps, type ProjectConfig, type PushButtonProps, type RectCutoutProps, type RectSmtPadProps, type RectSolderPasteProps, type ResistorPinLabels, type ResistorProps, type ResonatorPinVariant, type ResonatorProps, type RotatedRectSmtPadProps, type SchematicBoxProps, type SchematicCellProps, type SchematicLineProps, type SchematicOrientation, type SchematicPathProps, type SchematicPinArrangement, type SchematicPinArrangementWithPinCounts, type SchematicPinArrangementWithSides, type SchematicPinArrangementWithSizes, type SchematicPinLabel, type SchematicPinStyle, type SchematicPortArrangement, type SchematicPortArrangementWithPinCounts, type SchematicPortArrangementWithSides, type SchematicPortArrangementWithSizes, type SchematicRowProps, type SchematicTableProps, type SchematicTextProps, type Selectors, type SilkscreenCircleProps, type SilkscreenLineProps, type SilkscreenPathProps, type SilkscreenRectProps, type SilkscreenTextProps, type SmtPadProps, type SolderJumperProps, type SolderPasteProps, type StampboardProps, type SubcircuitGroupProps, type SubcircuitGroupPropsWithBool, type SubcircuitProps, type SupplierName, type SupplierPartNumbers, type SupplierProps, type SwitchProps, type SymbolProp, type SymbolProps, type SymbolPropsInput, type TestpointProps, type TraceHintProps, type TraceProps, type TransistorPinLabels, type TransistorProps, type ViaProps, type VoltageSourcePinLabels, type VoltageSourceProps, type WaveShape, autorouterConfig, autorouterProp, baseGroupProps, base_manual_edit_event, batteryPins, batteryProps, boardProps, border, breakoutPointProps, breakoutProps, bugProps, cadModelBase, cadModelGlb, cadModelGltf, cadModelJscad, cadModelObj, cadModelProp, cadModelStep, cadModelStl, cadModelWrl, cadassemblyProps, cadmodelProps, capacitorPinLabels, capacitorPins, capacitorProps, chipProps, circleCutoutProps, circleSmtPadProps, circleSolderPasteProps, commonComponentProps, commonLayoutProps, componentProps, connectorProps, constrainedLayoutProps, constraintProps, copperPourProps, crystalPins, crystalProps, cutoutProps, diodePins, diodeProps, direction, directionAlongEdge, distanceOrMultiplier, edit_component_location_event, edit_pcb_component_location_event, edit_pcb_group_location_event, edit_schematic_component_location_event, edit_schematic_group_location_event, edit_trace_hint_event, explicitPinSideDefinition, fabricationNotePathProps, fabricationNoteTextProps, footprintProp, footprintProps, fusePinLabels, fuseProps, groupProps, holeProps, inductorPins, inductorProps, jumperProps, layoutConfig, ledPins, ledProps, lrPins, lrPolarPins, manual_edit_event, manual_edits_file, manual_pcb_placement, manual_schematic_placement, manual_trace_hint, mosfetPins, mosfetProps, netAliasProps, netLabelProps, netProps, ninePointAnchor, partsEngine, pcbKeepoutProps, pcbLayoutProps, pcbSameXConstraintProps, pcbSameYConstraintProps, pcbTraceProps, pcbXDistConstraintProps, pcbYDistConstraintProps, pillSmtPadProps, pinAttributeMap, pinCompatibleVariant, pinHeaderProps, pinLabelsProp, pinoutProps, platedHoleProps, platformConfig, point3, polygonCutoutProps, polygonSmtPadProps, portHints, portProps, portRef, potentiometerProps, powerSourceProps, projectConfig, pushButtonProps, rectCutoutProps, rectSmtPadProps, rectSolderPasteProps, resistorPinLabels, resistorPins, resistorProps, resonatorProps, rotatedRectSmtPadProps, rotationPoint3, routeHintPointProps, schematicBoxProps, schematicCellProps, schematicLineProps, schematicOrientation, schematicPathProps, schematicPinArrangement, schematicPinLabel, schematicPinStyle, schematicPortArrangement, schematicRowProps, schematicTableProps, schematicTextProps, silkscreenCircleProps, silkscreenLineProps, silkscreenPathProps, silkscreenRectProps, silkscreenTextProps, smtPadProps, solderPasteProps, solderjumperProps, stampboardProps, subcircuitGroupProps, subcircuitGroupPropsWithBool, subcircuitProps, supplierProps, switchProps, symbolProp, symbolProps, testpointProps, traceHintProps, traceProps, transistorPins, transistorPinsLabels, transistorProps, viaProps, voltageSourcePinLabels, voltageSourcePins, voltageSourceProps };
48379
+ export { type AutocompleteString, type AutorouterConfig, type AutorouterProp, type BaseGroupProps, type BaseManualEditEvent, type BaseManualEditEventInput, type BasicFootprint, type BatteryPinLabels, type BatteryProps, type BoardProps, type Border, type BreakoutPointProps, type BreakoutProps, type CadAssemblyProps, type CadAssemblyPropsInput, type CadModelBase, type CadModelGlb, type CadModelGltf, type CadModelJscad, type CadModelObj, type CadModelProp, type CadModelProps, type CadModelPropsInput, type CadModelStep, type CadModelStl, type CadModelWrl, type CapacitorPinLabels, type CapacitorProps, type ChipConnections, type ChipPinLabels, type ChipProps, type ChipPropsSU, type CircleCutoutProps, type CircleHoleProps, type CirclePlatedHoleProps, type CircleSmtPadProps, type CircleSolderPasteProps, type CircularHoleWithRectPlatedProps, type CommonComponentProps, type CommonLayoutProps, type ComponentProps, type ConnectionTarget, type Connections, type ConnectorProps, type ConstrainedLayoutProps, type ConstraintProps, type CopperPourProps, type CopperPourPropsInput, type CrystalPinLabels, type CrystalProps, type CutoutProps, type CutoutPropsInput, type DiodePinLabels, type DiodeProps, type Direction, type DirectionAlongEdge, type EditPcbComponentLocationEvent, type EditPcbComponentLocationEventInput, type EditPcbGroupLocationEvent, type EditPcbGroupLocationEventInput, type EditSchematicComponentLocationEvent, type EditSchematicComponentLocationEventInput, type EditSchematicGroupLocationEvent, type EditSchematicGroupLocationEventInput, type EditTraceHintEvent, type EditTraceHintEventInput, type FabricationNotePathProps, type FabricationNoteTextProps, type FootprintFileParserEntry, type FootprintLibraryResult, type FootprintProp, type FootprintProps, type FootprintPropsInput, type FootprintSoupElements, type FusePinLabels, type FuseProps, type GroupProps, type HoleProps, type InductorPinLabels, type InductorProps, type InferredChipProps, type InferredConstrainedLayoutProps, type InferredDiodeProps, type InferredFuseProps, type InferredHoleProps, type InferredSmtPadProps, type InferredSolderPasteProps, type InferredSwitchProps, type InferredTestpointProps, type InferredViaProps, type JumperProps, type KicadAutocompleteStringPath, type KicadPath, type LayoutConfig, type LedPinLabels, type LedProps, type ManualEditEvent, type ManualEditEventInput, type ManualEditsFile, type ManualEditsFileInput, type ManualPcbPlacement, type ManualPcbPlacementInput, type ManualSchematicPlacement, type ManualSchematicPlacementInput, type ManualTraceHint, type ManualTraceHintInput, type MosfetPinLabels, type MosfetProps, type NetAliasProps, type NetLabelProps, type NetProps, type NonSubcircuitGroupProps, type OvalPlatedHoleProps, type PartsEngine, type PcbKeepoutProps, type PcbLayoutProps, type PcbRouteCache, type PcbSameXConstraint, type PcbSameYConstraint, type PcbTraceProps, type PcbXDistConstraint, type PcbYDistConstraint, type PillHoleProps, type PillPlatedHoleProps, type PillSmtPadProps, type PillWithRectPadPlatedHoleProps, type PinAttributeMap, type PinCompatibleVariant, type PinHeaderProps, type PinLabelFromPinLabelMap, type PinLabelsProp, type PinSideDefinition, type PinVariant, type PinoutProps, type PlatedHoleProps, type PlatformConfig, type PolygonCutoutProps, type PolygonSmtPadProps, type PortHints, type PortProps, type PotentiometerPinVariant, type PotentiometerProps, type PowerSourceProps, type ProjectConfig, type PushButtonProps, type RectCutoutProps, type RectSmtPadProps, type RectSolderPasteProps, type ResistorPinLabels, type ResistorProps, type ResonatorPinVariant, type ResonatorProps, type RotatedRectSmtPadProps, type SchematicBoxProps, type SchematicCellProps, type SchematicLineProps, type SchematicOrientation, type SchematicPathProps, type SchematicPinArrangement, type SchematicPinArrangementWithPinCounts, type SchematicPinArrangementWithSides, type SchematicPinArrangementWithSizes, type SchematicPinLabel, type SchematicPinStyle, type SchematicPortArrangement, type SchematicPortArrangementWithPinCounts, type SchematicPortArrangementWithSides, type SchematicPortArrangementWithSizes, type SchematicRowProps, type SchematicTableProps, type SchematicTextProps, type Selectors, type SilkscreenCircleProps, type SilkscreenLineProps, type SilkscreenPathProps, type SilkscreenRectProps, type SilkscreenTextProps, type SmtPadProps, type SolderJumperProps, type SolderPasteProps, type StampboardProps, type SubcircuitGroupProps, type SubcircuitGroupPropsWithBool, type SubcircuitProps, type SupplierName, type SupplierPartNumbers, type SupplierProps, type SwitchProps, type SymbolProp, type SymbolProps, type SymbolPropsInput, type TestpointProps, type TraceHintProps, type TraceProps, type TransistorPinLabels, type TransistorProps, type ViaProps, type VoltageSourcePinLabels, type VoltageSourceProps, type WaveShape, autorouterConfig, autorouterProp, baseGroupProps, base_manual_edit_event, batteryPins, batteryProps, boardProps, border, breakoutPointProps, breakoutProps, bugProps, cadModelBase, cadModelGlb, cadModelGltf, cadModelJscad, cadModelObj, cadModelProp, cadModelStep, cadModelStl, cadModelWrl, cadassemblyProps, cadmodelProps, capacitorPinLabels, capacitorPins, capacitorProps, chipProps, circleCutoutProps, circleSmtPadProps, circleSolderPasteProps, commonComponentProps, commonLayoutProps, componentProps, connectorProps, constrainedLayoutProps, constraintProps, copperPourProps, crystalPins, crystalProps, cutoutProps, diodePins, diodeProps, direction, directionAlongEdge, distanceOrMultiplier, edit_component_location_event, edit_pcb_component_location_event, edit_pcb_group_location_event, edit_schematic_component_location_event, edit_schematic_group_location_event, edit_trace_hint_event, explicitPinSideDefinition, fabricationNotePathProps, fabricationNoteTextProps, footprintProp, footprintProps, fusePinLabels, fuseProps, groupProps, holeProps, inductorPins, inductorProps, jumperProps, layoutConfig, ledPins, ledProps, lrPins, lrPolarPins, manual_edit_event, manual_edits_file, manual_pcb_placement, manual_schematic_placement, manual_trace_hint, mosfetPins, mosfetProps, netAliasProps, netLabelProps, netProps, ninePointAnchor, partsEngine, pcbKeepoutProps, pcbLayoutProps, pcbSameXConstraintProps, pcbSameYConstraintProps, pcbTraceProps, pcbXDistConstraintProps, pcbYDistConstraintProps, pillSmtPadProps, pinAttributeMap, pinCompatibleVariant, pinHeaderProps, pinLabelsProp, pinoutProps, platedHoleProps, platformConfig, point3, polygonCutoutProps, polygonSmtPadProps, portHints, portProps, portRef, potentiometerProps, powerSourceProps, projectConfig, pushButtonProps, rectCutoutProps, rectSmtPadProps, rectSolderPasteProps, resistorPinLabels, resistorPins, resistorProps, resonatorProps, rotatedRectSmtPadProps, rotationPoint3, routeHintPointProps, schematicBoxProps, schematicCellProps, schematicLineProps, schematicOrientation, schematicPathProps, schematicPinArrangement, schematicPinLabel, schematicPinStyle, schematicPortArrangement, schematicRowProps, schematicTableProps, schematicTextProps, silkscreenCircleProps, silkscreenLineProps, silkscreenPathProps, silkscreenRectProps, silkscreenTextProps, smtPadProps, solderPasteProps, solderjumperProps, stampboardProps, subcircuitGroupProps, subcircuitGroupPropsWithBool, subcircuitProps, supplierProps, switchProps, symbolProp, symbolProps, testpointProps, traceHintProps, traceProps, transistorPins, transistorPinsLabels, transistorProps, viaProps, voltageSourcePinLabels, voltageSourcePins, voltageSourceProps };
package/dist/index.js CHANGED
@@ -787,8 +787,8 @@ var platedHoleProps = z34.discriminatedUnion("shape", [
787
787
  holeShape: z34.literal("circle").optional(),
788
788
  padShape: z34.literal("rect").optional(),
789
789
  portHints: portHints.optional(),
790
- pcbHoleOffsetX: distance11.optional(),
791
- pcbHoleOffsetY: distance11.optional()
790
+ holeOffsetX: distance11.optional(),
791
+ holeOffsetY: distance11.optional()
792
792
  }),
793
793
  pcbLayoutProps.omit({ pcbRotation: true, layer: true }).extend({
794
794
  name: z34.string().optional(),
@@ -800,7 +800,9 @@ var platedHoleProps = z34.discriminatedUnion("shape", [
800
800
  holeHeight: distance11,
801
801
  rectPadWidth: distance11,
802
802
  rectPadHeight: distance11,
803
- portHints: portHints.optional()
803
+ portHints: portHints.optional(),
804
+ holeOffsetX: distance11.optional(),
805
+ holeOffsetY: distance11.optional()
804
806
  })
805
807
  ]).refine((a) => {
806
808
  if ("innerWidth" in a && a.innerWidth !== void 0) {
@@ -1813,6 +1815,11 @@ var footprintLibraryResult = z89.object({
1813
1815
  cadModel: cadModelProp.optional()
1814
1816
  });
1815
1817
  var pathToCircuitJsonFn = z89.function().args(z89.string()).returns(z89.promise(footprintLibraryResult)).describe("A function that takes a path and returns Circuit JSON");
1818
+ var footprintFileParserEntry = z89.object({
1819
+ loadFromUrl: z89.function().args(z89.string()).returns(z89.promise(footprintLibraryResult)).describe(
1820
+ "A function that takes a footprint file URL and returns Circuit JSON"
1821
+ )
1822
+ });
1816
1823
  var platformConfig = z89.object({
1817
1824
  partsEngine: partsEngine.optional(),
1818
1825
  autorouter: autorouterProp.optional(),
@@ -1836,7 +1843,8 @@ var platformConfig = z89.object({
1836
1843
  z89.union([unvalidatedCircuitJson, pathToCircuitJsonFn])
1837
1844
  )
1838
1845
  ])
1839
- ).optional()
1846
+ ).optional(),
1847
+ footprintFileParserMap: z89.record(z89.string(), footprintFileParserEntry).optional()
1840
1848
  });
1841
1849
  expectTypesMatch(true);
1842
1850