kicadts 0.0.25 → 0.0.26

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.d.ts CHANGED
@@ -1816,6 +1816,7 @@ declare class FootprintAttr extends SxClass {
1816
1816
  private _excludeFromPosFiles;
1817
1817
  private _excludeFromBom;
1818
1818
  private _allowSoldermaskBridges;
1819
+ private _dnp;
1819
1820
  static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): FootprintAttr;
1820
1821
  private applyFlag;
1821
1822
  get type(): string | undefined;
@@ -1828,6 +1829,8 @@ declare class FootprintAttr extends SxClass {
1828
1829
  set excludeFromBom(value: boolean);
1829
1830
  get allowSoldermaskBridges(): boolean;
1830
1831
  set allowSoldermaskBridges(value: boolean);
1832
+ get dnp(): boolean;
1833
+ set dnp(value: boolean);
1831
1834
  getChildren(): SxClass[];
1832
1835
  getString(): string;
1833
1836
  }
@@ -2443,6 +2446,19 @@ declare class PadZoneConnect extends SxPrimitiveNumber {
2443
2446
  token: string;
2444
2447
  }
2445
2448
 
2449
+ declare class PadProperty extends SxClass {
2450
+ static token: string;
2451
+ static parentToken: string;
2452
+ token: string;
2453
+ private _value;
2454
+ constructor(value: string);
2455
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): PadProperty;
2456
+ get value(): string;
2457
+ set value(value: string);
2458
+ getChildren(): SxClass[];
2459
+ getString(): string;
2460
+ }
2461
+
2446
2462
  declare class PadTeardrops extends SxClass {
2447
2463
  static token: string;
2448
2464
  static parentToken: string;
@@ -2508,7 +2524,7 @@ interface FootprintPadConstructorParams {
2508
2524
  layers?: PadLayersInput;
2509
2525
  width?: Width | number;
2510
2526
  stroke?: Stroke;
2511
- properties?: Property[];
2527
+ properties?: PadProperty[];
2512
2528
  roundrectRatio?: number | PadRoundrectRratio;
2513
2529
  chamferRatio?: number | PadChamferRatio;
2514
2530
  chamfer?: PadChamfer;
@@ -2594,8 +2610,8 @@ declare class FootprintPad extends SxClass {
2594
2610
  set width(value: number | Width | undefined);
2595
2611
  get stroke(): Stroke | undefined;
2596
2612
  set stroke(value: Stroke | undefined);
2597
- get properties(): Property[];
2598
- set properties(value: Property[]);
2613
+ get properties(): PadProperty[];
2614
+ set properties(value: PadProperty[]);
2599
2615
  get roundrectRatio(): number | undefined;
2600
2616
  set roundrectRatio(value: number | PadRoundrectRratio | undefined);
2601
2617
  get chamferRatio(): number | undefined;
@@ -3259,6 +3275,102 @@ declare class FootprintModel extends SxClass {
3259
3275
  getString(): string;
3260
3276
  }
3261
3277
 
3278
+ declare class EmbeddedFileChecksum extends SxClass {
3279
+ static token: string;
3280
+ static parentToken: string;
3281
+ token: string;
3282
+ private _value;
3283
+ constructor(value: string);
3284
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): EmbeddedFileChecksum;
3285
+ get value(): string;
3286
+ set value(value: string);
3287
+ getChildren(): SxClass[];
3288
+ getString(): string;
3289
+ }
3290
+
3291
+ declare class EmbeddedFileData extends SxClass {
3292
+ static token: string;
3293
+ static parentToken: string;
3294
+ token: string;
3295
+ private _chunks;
3296
+ constructor(chunks?: string[]);
3297
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): EmbeddedFileData;
3298
+ static fromStrings(values: string[]): EmbeddedFileData;
3299
+ get chunks(): string[];
3300
+ set chunks(values: string[]);
3301
+ get value(): string;
3302
+ set value(data: string);
3303
+ getChildren(): SxClass[];
3304
+ getString(): string;
3305
+ }
3306
+
3307
+ declare class EmbeddedFileName extends SxClass {
3308
+ static token: string;
3309
+ static parentToken: string;
3310
+ token: string;
3311
+ private _value;
3312
+ constructor(value: string);
3313
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): EmbeddedFileName;
3314
+ get value(): string;
3315
+ set value(value: string);
3316
+ getChildren(): SxClass[];
3317
+ getString(): string;
3318
+ }
3319
+
3320
+ declare class EmbeddedFileType extends SxClass {
3321
+ static token: string;
3322
+ static parentToken: string;
3323
+ token: string;
3324
+ private _value;
3325
+ constructor(value: string);
3326
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): EmbeddedFileType;
3327
+ get value(): string;
3328
+ set value(value: string);
3329
+ getChildren(): SxClass[];
3330
+ getString(): string;
3331
+ }
3332
+
3333
+ interface EmbeddedFileConstructorParams {
3334
+ name?: string | EmbeddedFileName;
3335
+ type?: string | EmbeddedFileType;
3336
+ checksum?: string | EmbeddedFileChecksum;
3337
+ data?: EmbeddedFileData | string | string[];
3338
+ }
3339
+ declare class EmbeddedFile extends SxClass {
3340
+ static token: string;
3341
+ static parentToken: string;
3342
+ token: string;
3343
+ private _sxName?;
3344
+ private _sxType?;
3345
+ private _sxChecksum?;
3346
+ private _sxData?;
3347
+ constructor(params?: EmbeddedFileConstructorParams);
3348
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): EmbeddedFile;
3349
+ get name(): string | undefined;
3350
+ set name(value: string | EmbeddedFileName | undefined);
3351
+ get type(): string | undefined;
3352
+ set type(value: string | EmbeddedFileType | undefined);
3353
+ get checksum(): string | undefined;
3354
+ set checksum(value: string | EmbeddedFileChecksum | undefined);
3355
+ get data(): EmbeddedFileData | undefined;
3356
+ set data(value: EmbeddedFileData | string | string[] | undefined);
3357
+ getChildren(): SxClass[];
3358
+ }
3359
+
3360
+ interface EmbeddedFilesConstructorParams {
3361
+ files?: EmbeddedFile[];
3362
+ }
3363
+ declare class EmbeddedFiles extends SxClass {
3364
+ static token: string;
3365
+ token: string;
3366
+ private _files;
3367
+ constructor(params?: EmbeddedFilesConstructorParams);
3368
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): EmbeddedFiles;
3369
+ get files(): EmbeddedFile[];
3370
+ set files(value: EmbeddedFile[]);
3371
+ getChildren(): SxClass[];
3372
+ }
3373
+
3262
3374
  declare class FootprintLocked extends SxPrimitiveBoolean {
3263
3375
  static token: string;
3264
3376
  static parentToken: string;
@@ -3304,6 +3416,7 @@ interface FootprintConstructorParams {
3304
3416
  sheetname?: string | FootprintSheetname;
3305
3417
  sheetfile?: string | FootprintSheetfile;
3306
3418
  embeddedFonts?: EmbeddedFonts;
3419
+ embeddedFiles?: EmbeddedFiles;
3307
3420
  properties?: Property[];
3308
3421
  fpTexts?: FpText[];
3309
3422
  fpTextBoxes?: FpTextBox[];
@@ -3348,6 +3461,7 @@ declare class Footprint extends SxClass {
3348
3461
  private _sxSheetname?;
3349
3462
  private _sxSheetfile?;
3350
3463
  private _sxEmbeddedFonts?;
3464
+ private _sxEmbeddedFiles?;
3351
3465
  private _properties;
3352
3466
  private _fpTexts;
3353
3467
  private _fpTextBoxes;
@@ -3418,6 +3532,8 @@ declare class Footprint extends SxClass {
3418
3532
  set sheetfile(value: string | FootprintSheetfile | undefined);
3419
3533
  get embeddedFonts(): EmbeddedFonts | undefined;
3420
3534
  set embeddedFonts(value: EmbeddedFonts | undefined);
3535
+ get embeddedFiles(): EmbeddedFiles | undefined;
3536
+ set embeddedFiles(value: EmbeddedFiles | undefined);
3421
3537
  get properties(): Property[];
3422
3538
  set properties(value: Property[]);
3423
3539
  get fpTexts(): FpText[];
@@ -4040,6 +4156,63 @@ declare class GroupMembers extends SxClass {
4040
4156
  getString(): string;
4041
4157
  }
4042
4158
 
4159
+ declare class Generated extends SxClass {
4160
+ static token: string;
4161
+ static parentToken: string;
4162
+ token: string;
4163
+ private _rawChildren;
4164
+ constructor();
4165
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): Generated;
4166
+ get rawChildren(): PrimitiveSExpr[];
4167
+ set rawChildren(value: PrimitiveSExpr[]);
4168
+ getChildren(): SxClass[];
4169
+ getString(): string;
4170
+ }
4171
+
4172
+ interface PcbArcPoint {
4173
+ x: number;
4174
+ y: number;
4175
+ }
4176
+ interface PcbArcConstructorParams {
4177
+ start?: PcbArcPoint;
4178
+ mid?: PcbArcPoint;
4179
+ end?: PcbArcPoint;
4180
+ width?: number | Width;
4181
+ layer?: string | Layer;
4182
+ net?: number;
4183
+ uuid?: string | Uuid;
4184
+ }
4185
+ declare class PcbArc extends SxClass {
4186
+ static token: string;
4187
+ static parentToken: string;
4188
+ token: string;
4189
+ private _start?;
4190
+ private _mid?;
4191
+ private _end?;
4192
+ private _sxWidth?;
4193
+ private _sxLayer?;
4194
+ private _net?;
4195
+ private _sxUuid?;
4196
+ constructor(params?: PcbArcConstructorParams);
4197
+ static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): PcbArc;
4198
+ get start(): PcbArcPoint | undefined;
4199
+ set start(value: PcbArcPoint | undefined);
4200
+ get mid(): PcbArcPoint | undefined;
4201
+ set mid(value: PcbArcPoint | undefined);
4202
+ get end(): PcbArcPoint | undefined;
4203
+ set end(value: PcbArcPoint | undefined);
4204
+ get width(): number | undefined;
4205
+ set width(value: number | Width | undefined);
4206
+ get layer(): Layer | undefined;
4207
+ set layer(value: string | Layer | undefined);
4208
+ get net(): number | undefined;
4209
+ set net(value: number | undefined);
4210
+ get uuid(): Uuid | undefined;
4211
+ set uuid(value: string | Uuid | undefined);
4212
+ getChildren(): SxClass[];
4213
+ getString(): string;
4214
+ }
4215
+
4043
4216
  declare class SegmentEnd extends SxClass {
4044
4217
  static token: string;
4045
4218
  static parentToken: string;
@@ -5190,6 +5363,7 @@ interface KicadPcbConstructorParams {
5190
5363
  vias?: Via[];
5191
5364
  zones?: Zone[];
5192
5365
  embeddedFonts?: EmbeddedFonts;
5366
+ embeddedFiles?: EmbeddedFiles;
5193
5367
  otherChildren?: SxClass[];
5194
5368
  }
5195
5369
  declare class KicadPcb extends SxClass {
@@ -5215,6 +5389,7 @@ declare class KicadPcb extends SxClass {
5215
5389
  private _vias;
5216
5390
  private _zones;
5217
5391
  private _sxEmbeddedFonts?;
5392
+ private _sxEmbeddedFiles?;
5218
5393
  private _otherChildren;
5219
5394
  constructor(params?: KicadPcbConstructorParams);
5220
5395
  static fromSexprPrimitives(primitiveSexprs: PrimitiveSExpr[]): KicadPcb;
@@ -5259,6 +5434,8 @@ declare class KicadPcb extends SxClass {
5259
5434
  set zones(value: Zone[]);
5260
5435
  get embeddedFonts(): EmbeddedFonts | undefined;
5261
5436
  set embeddedFonts(value: EmbeddedFonts | undefined);
5437
+ get embeddedFiles(): EmbeddedFiles | undefined;
5438
+ set embeddedFiles(value: EmbeddedFiles | undefined);
5262
5439
  get otherChildren(): SxClass[];
5263
5440
  set otherChildren(value: SxClass[]);
5264
5441
  getChildren(): SxClass[];
@@ -5269,4 +5446,4 @@ declare const parseKicadSch: (sexpr: string) => KicadSch;
5269
5446
  declare const parseKicadPcb: (sexpr: string) => KicadPcb;
5270
5447
  declare const parseKicadMod: (sexpr: string) => Footprint;
5271
5448
 
5272
- export { At, type AtInput, Bus, type BusConstructorParams, BusEntry, type BusEntryConstructorParams, BusEntrySize, Color, Dnp, EmbeddedFonts, ExcludeFromSim, FieldsAutoplaced, Footprint, FootprintAttr, FootprintAutoplaceCost180, FootprintAutoplaceCost90, FootprintClearance, type FootprintConstructorParams, FootprintDescr, FootprintGenerator, FootprintGeneratorVersion, FootprintLocked, FootprintModel, FootprintNetTiePadGroups, FootprintPad, type FootprintPadConstructorParams, FootprintPath, FootprintPlaced, FootprintPrivateLayers, FootprintSheetfile, FootprintSheetname, FootprintSolderMaskMargin, FootprintSolderPasteMargin, FootprintSolderPasteRatio, FootprintTags, FootprintTedit, FootprintThermalGap, FootprintThermalWidth, FootprintVersion, FootprintZoneConnect, FpArc, type FpArcConstructorParams, FpArcEnd, FpArcMid, FpArcStart, FpCircle, FpCircleCenter, type FpCircleConstructorParams, FpCircleEnd, FpCircleFill, FpLine, type FpLineConstructorParams, FpLineEnd, FpLineStart, FpPoly, type FpPolyConstructorParams, FpPolyFill, FpPolyLocked, FpRect, type FpRectConstructorParams, FpRectEnd, FpRectFill, FpRectStart, FpText, FpTextBox, FpTextBoxAngle, type FpTextBoxConstructorParams, FpTextBoxEnd, FpTextBoxStart, type FpTextConstructorParams, type FpTextType, GlobalLabel, type GlobalLabelConstructorParams, type GlobalLabelShape, GrArc, type GrArcConstructorParams, GrArcEnd, GrArcMid, type GrArcPoint, GrArcStart, GrCircle, GrCircleCenter, type GrCircleConstructorParams, GrCircleEnd, GrCircleLocked, type GrCirclePoint, GrCurve, type GrCurveConstructorParams, GrLine, GrLineAngle, type GrLineConstructorParams, GrLineEnd, GrLineLocked, type GrLinePoint, GrLineStart, GrPoly, type GrPolyConstructorParams, GrPolyFill, GrRect, type GrRectConstructorParams, GrRectEnd, GrRectFill, GrRectLocked, GrRectStart, GrText, type GrTextConstructorParams, type GrTextPosition, GrTextRenderCache, GrTextRenderCachePolygon, Group, type GroupConstructorParams, GroupLocked, GroupMembers, Image, type ImageConstructorParams, ImageData, ImageScale, InBom, Junction, type JunctionConstructorParams, JunctionDiameter, KicadPcb, type KicadPcbConstructorParams, KicadSch, type KicadSchConstructorParams, KicadSchGenerator, KicadSchGeneratorVersion, KicadSchVersion, KicadSymbolLib, type KicadSymbolLibConstructorParams, KicadSymbolLibGenerator, KicadSymbolLibVersion, Label, type LabelConstructorParams, Layer, Layers, LibSymbols, Mirror, type ModelVector, NoConnect, type NoConnectConstructorParams, OnBoard, PadChamfer, PadChamferRatio, PadClearance, PadDieLength, PadDrill, PadDrillOffset, PadLayers, type PadLayersInput, PadNet, PadOptions, type PadOptionsAnchorShape, type PadOptionsClearanceType, PadPinFunction, PadPinType, PadPrimitiveGrArc, type PadPrimitiveGrArcConstructorParams, PadPrimitiveGrCircle, type PadPrimitiveGrCircleConstructorParams, PadPrimitiveGrCircleFill, PadPrimitiveGrLine, PadPrimitiveGrPoly, PadPrimitives, PadRectDelta, PadRoundrectRratio, PadSize, type PadSizeInput, PadSolderMaskMargin, PadSolderPasteMargin, PadSolderPasteMarginRatio, PadTeardrops, PadThermalBridgeAngle, PadThermalGap, PadThermalWidth, PadZoneConnect, Paper, PcbGeneral, PcbGeneralLegacyTeardrops, PcbGeneralThickness, PcbGenerator, PcbGeneratorVersion, PcbLayerDefinition, PcbLayers, PcbNet, PcbPlotParams, PcbVersion, PlotParamCreateGerberJobFile, PlotParamCrossoutDnpOnFab, PlotParamDashedLineDashRatio, PlotParamDashedLineGapRatio, PlotParamDisableApertMacros, PlotParamDrillShape, PlotParamDxfImperialUnits, PlotParamDxfPolygonMode, PlotParamDxfUsePcbnewFont, PlotParamExcludeEdgeLayer, PlotParamHideDnpOnFab, PlotParamHpglPenDiameter, PlotParamHpglPenNumber, PlotParamHpglPenOverlay, PlotParamHpglPenSpeed, PlotParamLayerSelection, PlotParamLineWidth, PlotParamMirror, PlotParamMode, PlotParamOutputDirectory, PlotParamOutputFormat, PlotParamPadOnSilk, PlotParamPdfBackFpPropertyPopups, PlotParamPdfFrontFpPropertyPopups, PlotParamPdfMetadata, PlotParamPdfSingleDocument, PlotParamPlotBlackAndWhite, PlotParamPlotFrameRef, PlotParamPlotInvisible, PlotParamPlotInvisibleText, PlotParamPlotOnAllLayers, PlotParamPlotOnAllLayersSelection, PlotParamPlotOtherText, PlotParamPlotPadNumbers, PlotParamPlotReference, PlotParamPlotValue, PlotParamProperty, PlotParamPsA4Output, PlotParamPsNegative, PlotParamScaleSelection, PlotParamSketchDnpOnFab, PlotParamSketchPadsOnFab, PlotParamSubtractMaskFromSilk, PlotParamSvgPrecision, PlotParamUseAuxOrigin, PlotParamUseGerberAdvancedAttributes, PlotParamUseGerberAttributes, PlotParamUseGerberExtensions, PlotParamViaOnMask, Polyline, type PolylineConstructorParams, Property, type PropertyConstructorParams, PropertyHide, PropertyUnlocked, Pts, PtsArc, PtsArcEnd, PtsArcMid, PtsArcStart, type RGBAColor, RenderCache, SchematicPolyline, SchematicSymbol, type SchematicSymbolConstructorParams, SchematicText, type SchematicTextConstructorParams, Segment, type SegmentConstructorParams, SegmentEnd, SegmentLocked, SegmentNet, SegmentStart, Setup, SetupAllowSoldermaskBridgesInFootprints, SetupAuxAxisOrigin, SetupEdgeWidth, SetupGridOrigin, SetupLastTraceWidth, SetupModEdgeWidth, SetupModTextSize, SetupModTextWidth, SetupPadDrill, SetupPadSize, SetupPadToMaskClearance, SetupPadToPasteClearance, SetupPadToPasteClearanceRatio, SetupPadToPasteClearanceValues, SetupPcbTextSize, SetupPcbTextWidth, type SetupProperty, type SetupPropertyValues, SetupSegmentWidth, SetupSolderMaskMinWidth, SetupTenting, SetupTraceClearance, SetupTraceMin, SetupTraceWidth, SetupUviaDrill, SetupUviaMinDrill, SetupUviaMinSize, SetupUviaSize, SetupUviasAllowed, SetupViaDrill, SetupViaMinDrill, SetupViaMinSize, SetupViaSize, SetupVisibleElements, SetupZone45Only, SetupZoneClearance, Sheet, type SheetConstructorParams, SheetFill, SheetInstancePage, SheetInstancePath, SheetInstances, SheetInstancesForSheet, SheetInstancesProject, SheetInstancesRoot, SheetInstancesRootPage, SheetInstancesRootPath, SheetPin, type SheetPinElectricalType, SheetProperty, SheetSize, Stackup, StackupCastellatedPads, StackupCopperFinish, StackupDielectricConstraints, StackupEdgeConnector, StackupEdgePlating, StackupLayer, StackupLayerColor, StackupLayerEpsilonR, StackupLayerLossTangent, StackupLayerMaterial, StackupLayerThickness, StackupLayerType, type StandardPaperSize, Stroke, type StrokeProperty, StrokeType, type StrokeTypeString, SxClass, SymbolArc, SymbolArcEnd, SymbolArcFill, SymbolArcMid, SymbolArcStart, SymbolCircle, SymbolCircleCenter, SymbolCircleFill, SymbolCircleRadius, SymbolDuplicatePinNumbersAreJumpers, SymbolFillType, SymbolInstancePath, SymbolInstanceReference, SymbolInstanceUnit, SymbolInstances, SymbolInstancesProject, SymbolLibId, SymbolPin, SymbolPinLength, SymbolPinName, SymbolPinNames, SymbolPinNamesHide, SymbolPinNamesOffset, SymbolPinNumber, SymbolPinNumbers, SymbolPinNumbersHide, SymbolPolyline, SymbolPolylineFill, type SymbolPolylineFillLike, SymbolPower, SymbolProperty, SymbolPropertyId, SymbolRectangle, SymbolRectangleEnd, SymbolRectangleFill, SymbolRectangleStart, SymbolText, SymbolUnit, TextEffects, type TextEffectsConstructorParams, TextEffectsFont, TextEffectsFontBold, TextEffectsFontFace, TextEffectsFontItalic, TextEffectsFontLineSpacing, type TextEffectsFontProperty, TextEffectsFontSize, TextEffectsFontThickness, TextEffectsJustify, type TextEffectsProperty, TitleBlock, TitleBlockComment, TitleBlockCompany, type TitleBlockConstructorParams, TitleBlockDate, TitleBlockRevision, TitleBlockTitle, Tstamp, Unit, type UnitString, Uuid, Via, type ViaConstructorParams, ViaNet, Width, Wire, type WireConstructorParams, Xy, Zone, parseKicadMod, parseKicadPcb, parseKicadSch, parseKicadSexpr };
5449
+ export { At, type AtInput, Bus, type BusConstructorParams, BusEntry, type BusEntryConstructorParams, BusEntrySize, Color, Dnp, EmbeddedFile, EmbeddedFileChecksum, type EmbeddedFileConstructorParams, EmbeddedFileData, EmbeddedFileName, EmbeddedFileType, EmbeddedFiles, type EmbeddedFilesConstructorParams, EmbeddedFonts, ExcludeFromSim, FieldsAutoplaced, Footprint, FootprintAttr, FootprintAutoplaceCost180, FootprintAutoplaceCost90, FootprintClearance, type FootprintConstructorParams, FootprintDescr, FootprintGenerator, FootprintGeneratorVersion, FootprintLocked, FootprintModel, FootprintNetTiePadGroups, FootprintPad, type FootprintPadConstructorParams, FootprintPath, FootprintPlaced, FootprintPrivateLayers, FootprintSheetfile, FootprintSheetname, FootprintSolderMaskMargin, FootprintSolderPasteMargin, FootprintSolderPasteRatio, FootprintTags, FootprintTedit, FootprintThermalGap, FootprintThermalWidth, FootprintVersion, FootprintZoneConnect, FpArc, type FpArcConstructorParams, FpArcEnd, FpArcMid, FpArcStart, FpCircle, FpCircleCenter, type FpCircleConstructorParams, FpCircleEnd, FpCircleFill, FpLine, type FpLineConstructorParams, FpLineEnd, FpLineStart, FpPoly, type FpPolyConstructorParams, FpPolyFill, FpPolyLocked, FpRect, type FpRectConstructorParams, FpRectEnd, FpRectFill, FpRectStart, FpText, FpTextBox, FpTextBoxAngle, type FpTextBoxConstructorParams, FpTextBoxEnd, FpTextBoxStart, type FpTextConstructorParams, type FpTextType, Generated, GlobalLabel, type GlobalLabelConstructorParams, type GlobalLabelShape, GrArc, type GrArcConstructorParams, GrArcEnd, GrArcMid, type GrArcPoint, GrArcStart, GrCircle, GrCircleCenter, type GrCircleConstructorParams, GrCircleEnd, GrCircleLocked, type GrCirclePoint, GrCurve, type GrCurveConstructorParams, GrLine, GrLineAngle, type GrLineConstructorParams, GrLineEnd, GrLineLocked, type GrLinePoint, GrLineStart, GrPoly, type GrPolyConstructorParams, GrPolyFill, GrRect, type GrRectConstructorParams, GrRectEnd, GrRectFill, GrRectLocked, GrRectStart, GrText, type GrTextConstructorParams, type GrTextPosition, GrTextRenderCache, GrTextRenderCachePolygon, Group, type GroupConstructorParams, GroupLocked, GroupMembers, Image, type ImageConstructorParams, ImageData, ImageScale, InBom, Junction, type JunctionConstructorParams, JunctionDiameter, KicadPcb, type KicadPcbConstructorParams, KicadSch, type KicadSchConstructorParams, KicadSchGenerator, KicadSchGeneratorVersion, KicadSchVersion, KicadSymbolLib, type KicadSymbolLibConstructorParams, KicadSymbolLibGenerator, KicadSymbolLibVersion, Label, type LabelConstructorParams, Layer, Layers, LibSymbols, Mirror, type ModelVector, NoConnect, type NoConnectConstructorParams, OnBoard, PadChamfer, PadChamferRatio, PadClearance, PadDieLength, PadDrill, PadDrillOffset, PadLayers, type PadLayersInput, PadNet, PadOptions, type PadOptionsAnchorShape, type PadOptionsClearanceType, PadPinFunction, PadPinType, PadPrimitiveGrArc, type PadPrimitiveGrArcConstructorParams, PadPrimitiveGrCircle, type PadPrimitiveGrCircleConstructorParams, PadPrimitiveGrCircleFill, PadPrimitiveGrLine, PadPrimitiveGrPoly, PadPrimitives, PadProperty, PadRectDelta, PadRoundrectRratio, PadSize, type PadSizeInput, PadSolderMaskMargin, PadSolderPasteMargin, PadSolderPasteMarginRatio, PadTeardrops, PadThermalBridgeAngle, PadThermalGap, PadThermalWidth, PadZoneConnect, Paper, PcbArc, type PcbArcConstructorParams, type PcbArcPoint, PcbGeneral, PcbGeneralLegacyTeardrops, PcbGeneralThickness, PcbGenerator, PcbGeneratorVersion, PcbLayerDefinition, PcbLayers, PcbNet, PcbPlotParams, PcbVersion, PlotParamCreateGerberJobFile, PlotParamCrossoutDnpOnFab, PlotParamDashedLineDashRatio, PlotParamDashedLineGapRatio, PlotParamDisableApertMacros, PlotParamDrillShape, PlotParamDxfImperialUnits, PlotParamDxfPolygonMode, PlotParamDxfUsePcbnewFont, PlotParamExcludeEdgeLayer, PlotParamHideDnpOnFab, PlotParamHpglPenDiameter, PlotParamHpglPenNumber, PlotParamHpglPenOverlay, PlotParamHpglPenSpeed, PlotParamLayerSelection, PlotParamLineWidth, PlotParamMirror, PlotParamMode, PlotParamOutputDirectory, PlotParamOutputFormat, PlotParamPadOnSilk, PlotParamPdfBackFpPropertyPopups, PlotParamPdfFrontFpPropertyPopups, PlotParamPdfMetadata, PlotParamPdfSingleDocument, PlotParamPlotBlackAndWhite, PlotParamPlotFrameRef, PlotParamPlotInvisible, PlotParamPlotInvisibleText, PlotParamPlotOnAllLayers, PlotParamPlotOnAllLayersSelection, PlotParamPlotOtherText, PlotParamPlotPadNumbers, PlotParamPlotReference, PlotParamPlotValue, PlotParamProperty, PlotParamPsA4Output, PlotParamPsNegative, PlotParamScaleSelection, PlotParamSketchDnpOnFab, PlotParamSketchPadsOnFab, PlotParamSubtractMaskFromSilk, PlotParamSvgPrecision, PlotParamUseAuxOrigin, PlotParamUseGerberAdvancedAttributes, PlotParamUseGerberAttributes, PlotParamUseGerberExtensions, PlotParamViaOnMask, Polyline, type PolylineConstructorParams, Property, type PropertyConstructorParams, PropertyHide, PropertyUnlocked, Pts, PtsArc, PtsArcEnd, PtsArcMid, PtsArcStart, type RGBAColor, RenderCache, SchematicPolyline, SchematicSymbol, type SchematicSymbolConstructorParams, SchematicText, type SchematicTextConstructorParams, Segment, type SegmentConstructorParams, SegmentEnd, SegmentLocked, SegmentNet, SegmentStart, Setup, SetupAllowSoldermaskBridgesInFootprints, SetupAuxAxisOrigin, SetupEdgeWidth, SetupGridOrigin, SetupLastTraceWidth, SetupModEdgeWidth, SetupModTextSize, SetupModTextWidth, SetupPadDrill, SetupPadSize, SetupPadToMaskClearance, SetupPadToPasteClearance, SetupPadToPasteClearanceRatio, SetupPadToPasteClearanceValues, SetupPcbTextSize, SetupPcbTextWidth, type SetupProperty, type SetupPropertyValues, SetupSegmentWidth, SetupSolderMaskMinWidth, SetupTenting, SetupTraceClearance, SetupTraceMin, SetupTraceWidth, SetupUviaDrill, SetupUviaMinDrill, SetupUviaMinSize, SetupUviaSize, SetupUviasAllowed, SetupViaDrill, SetupViaMinDrill, SetupViaMinSize, SetupViaSize, SetupVisibleElements, SetupZone45Only, SetupZoneClearance, Sheet, type SheetConstructorParams, SheetFill, SheetInstancePage, SheetInstancePath, SheetInstances, SheetInstancesForSheet, SheetInstancesProject, SheetInstancesRoot, SheetInstancesRootPage, SheetInstancesRootPath, SheetPin, type SheetPinElectricalType, SheetProperty, SheetSize, Stackup, StackupCastellatedPads, StackupCopperFinish, StackupDielectricConstraints, StackupEdgeConnector, StackupEdgePlating, StackupLayer, StackupLayerColor, StackupLayerEpsilonR, StackupLayerLossTangent, StackupLayerMaterial, StackupLayerThickness, StackupLayerType, type StandardPaperSize, Stroke, type StrokeProperty, StrokeType, type StrokeTypeString, SxClass, SymbolArc, SymbolArcEnd, SymbolArcFill, SymbolArcMid, SymbolArcStart, SymbolCircle, SymbolCircleCenter, SymbolCircleFill, SymbolCircleRadius, SymbolDuplicatePinNumbersAreJumpers, SymbolFillType, SymbolInstancePath, SymbolInstanceReference, SymbolInstanceUnit, SymbolInstances, SymbolInstancesProject, SymbolLibId, SymbolPin, SymbolPinLength, SymbolPinName, SymbolPinNames, SymbolPinNamesHide, SymbolPinNamesOffset, SymbolPinNumber, SymbolPinNumbers, SymbolPinNumbersHide, SymbolPolyline, SymbolPolylineFill, type SymbolPolylineFillLike, SymbolPower, SymbolProperty, SymbolPropertyId, SymbolRectangle, SymbolRectangleEnd, SymbolRectangleFill, SymbolRectangleStart, SymbolText, SymbolUnit, TextEffects, type TextEffectsConstructorParams, TextEffectsFont, TextEffectsFontBold, TextEffectsFontFace, TextEffectsFontItalic, TextEffectsFontLineSpacing, type TextEffectsFontProperty, TextEffectsFontSize, TextEffectsFontThickness, TextEffectsJustify, type TextEffectsProperty, TitleBlock, TitleBlockComment, TitleBlockCompany, type TitleBlockConstructorParams, TitleBlockDate, TitleBlockRevision, TitleBlockTitle, Tstamp, Unit, type UnitString, Uuid, Via, type ViaConstructorParams, ViaNet, Width, Wire, type WireConstructorParams, Xy, Zone, parseKicadMod, parseKicadPcb, parseKicadSch, parseKicadSexpr };
package/dist/index.js CHANGED
@@ -631,6 +631,8 @@ var PtsArcStart = class _PtsArcStart extends SxClass {
631
631
  this.x = x;
632
632
  this.y = y;
633
633
  }
634
+ x;
635
+ y;
634
636
  static token = "start";
635
637
  static parentToken = "arc";
636
638
  token = "start";
@@ -650,6 +652,8 @@ var PtsArcMid = class _PtsArcMid extends SxClass {
650
652
  this.x = x;
651
653
  this.y = y;
652
654
  }
655
+ x;
656
+ y;
653
657
  static token = "mid";
654
658
  static parentToken = "arc";
655
659
  token = "mid";
@@ -669,6 +673,8 @@ var PtsArcEnd = class _PtsArcEnd extends SxClass {
669
673
  this.x = x;
670
674
  this.y = y;
671
675
  }
676
+ x;
677
+ y;
672
678
  static token = "end";
673
679
  static parentToken = "arc";
674
680
  token = "end";
@@ -5774,7 +5780,8 @@ var FLAG_TOKENS = /* @__PURE__ */ new Set([
5774
5780
  "board_only",
5775
5781
  "exclude_from_pos_files",
5776
5782
  "exclude_from_bom",
5777
- "allow_soldermask_bridges"
5783
+ "allow_soldermask_bridges",
5784
+ "dnp"
5778
5785
  ]);
5779
5786
  var FootprintAttr = class _FootprintAttr extends SxClass {
5780
5787
  static token = "attr";
@@ -5785,6 +5792,7 @@ var FootprintAttr = class _FootprintAttr extends SxClass {
5785
5792
  _excludeFromPosFiles = false;
5786
5793
  _excludeFromBom = false;
5787
5794
  _allowSoldermaskBridges = false;
5795
+ _dnp = false;
5788
5796
  static fromSexprPrimitives(primitiveSexprs) {
5789
5797
  const attr = new _FootprintAttr();
5790
5798
  for (const primitive of primitiveSexprs) {
@@ -5821,6 +5829,9 @@ var FootprintAttr = class _FootprintAttr extends SxClass {
5821
5829
  case "allow_soldermask_bridges":
5822
5830
  this._allowSoldermaskBridges = true;
5823
5831
  break;
5832
+ case "dnp":
5833
+ this._dnp = true;
5834
+ break;
5824
5835
  }
5825
5836
  }
5826
5837
  get type() {
@@ -5853,6 +5864,12 @@ var FootprintAttr = class _FootprintAttr extends SxClass {
5853
5864
  set allowSoldermaskBridges(value) {
5854
5865
  this._allowSoldermaskBridges = value;
5855
5866
  }
5867
+ get dnp() {
5868
+ return this._dnp;
5869
+ }
5870
+ set dnp(value) {
5871
+ this._dnp = value;
5872
+ }
5856
5873
  getChildren() {
5857
5874
  return [];
5858
5875
  }
@@ -5863,6 +5880,7 @@ var FootprintAttr = class _FootprintAttr extends SxClass {
5863
5880
  if (this._excludeFromPosFiles) tokens.push("exclude_from_pos_files");
5864
5881
  if (this._excludeFromBom) tokens.push("exclude_from_bom");
5865
5882
  if (this._allowSoldermaskBridges) tokens.push("allow_soldermask_bridges");
5883
+ if (this._dnp) tokens.push("dnp");
5866
5884
  return `(${tokens.join(" ")})`;
5867
5885
  }
5868
5886
  };
@@ -7582,6 +7600,51 @@ var PadZoneConnect = class extends SxPrimitiveNumber {
7582
7600
  };
7583
7601
  SxClass.register(PadZoneConnect);
7584
7602
 
7603
+ // lib/sexpr/classes/PadProperty.ts
7604
+ var primitiveToValue = (primitive) => {
7605
+ if (primitive === void 0) {
7606
+ return void 0;
7607
+ }
7608
+ const stringValue = toStringValue(primitive);
7609
+ if (stringValue !== void 0) {
7610
+ return stringValue;
7611
+ }
7612
+ return printSExpr(primitive);
7613
+ };
7614
+ var PadProperty = class _PadProperty extends SxClass {
7615
+ static token = "property";
7616
+ static parentToken = "pad";
7617
+ token = "property";
7618
+ _value;
7619
+ constructor(value) {
7620
+ super();
7621
+ this._value = value;
7622
+ }
7623
+ static fromSexprPrimitives(primitiveSexprs) {
7624
+ if (primitiveSexprs.length !== 1) {
7625
+ throw new Error("pad property expects exactly one value");
7626
+ }
7627
+ const value = primitiveToValue(primitiveSexprs[0]);
7628
+ if (value === void 0) {
7629
+ throw new Error("pad property expects a printable value");
7630
+ }
7631
+ return new _PadProperty(value);
7632
+ }
7633
+ get value() {
7634
+ return this._value;
7635
+ }
7636
+ set value(value) {
7637
+ this._value = value;
7638
+ }
7639
+ getChildren() {
7640
+ return [];
7641
+ }
7642
+ getString() {
7643
+ return `(property ${printSExpr(this._value)})`;
7644
+ }
7645
+ };
7646
+ SxClass.register(PadProperty);
7647
+
7585
7648
  // lib/sexpr/utils/parseYesNo.ts
7586
7649
  var parseYesNo = (value) => {
7587
7650
  const str = toStringValue(value);
@@ -10377,6 +10440,8 @@ var FpLineStart = class _FpLineStart extends SxClass {
10377
10440
  this.x = x;
10378
10441
  this.y = y;
10379
10442
  }
10443
+ x;
10444
+ y;
10380
10445
  static token = "start";
10381
10446
  static parentToken = "fp_line";
10382
10447
  token = "start";
@@ -10403,6 +10468,8 @@ var FpLineEnd = class _FpLineEnd extends SxClass {
10403
10468
  this.x = x;
10404
10469
  this.y = y;
10405
10470
  }
10471
+ x;
10472
+ y;
10406
10473
  static token = "end";
10407
10474
  static parentToken = "fp_line";
10408
10475
  token = "end";
@@ -10490,6 +10557,10 @@ var FootprintModel = class _FootprintModel extends SxClass {
10490
10557
  model._rotate = parseVectorArgs(args, "rotate");
10491
10558
  continue;
10492
10559
  }
10560
+ if (token === "hide") {
10561
+ model._hide = parseHideArgs(args);
10562
+ continue;
10563
+ }
10493
10564
  throw new Error(`model encountered unsupported child token "${token}"`);
10494
10565
  }
10495
10566
  return model;
@@ -10530,7 +10601,7 @@ var FootprintModel = class _FootprintModel extends SxClass {
10530
10601
  getString() {
10531
10602
  const lines = [`(model ${quoteSExprString(this._path)}`];
10532
10603
  if (this._hide) {
10533
- lines.push(" hide");
10604
+ lines.push(" (hide yes)");
10534
10605
  }
10535
10606
  if (this._offset) {
10536
10607
  lines.push(renderVectorBlock("offset", this._offset));
@@ -10567,6 +10638,305 @@ function renderVectorBlock(label, vector) {
10567
10638
  (xyz ${vector.x} ${vector.y} ${vector.z})
10568
10639
  )`;
10569
10640
  }
10641
+ function parseHideArgs(args) {
10642
+ if (args.length === 0) {
10643
+ return true;
10644
+ }
10645
+ if (args.length > 1) {
10646
+ throw new Error("model hide expects at most one value");
10647
+ }
10648
+ const parsed = parseYesNo(args[0]);
10649
+ if (parsed === void 0) {
10650
+ throw new Error(
10651
+ `model hide expects yes/no, received ${JSON.stringify(args[0])}`
10652
+ );
10653
+ }
10654
+ return parsed;
10655
+ }
10656
+
10657
+ // lib/sexpr/classes/EmbeddedFileChecksum.ts
10658
+ var EmbeddedFileChecksum = class _EmbeddedFileChecksum extends SxClass {
10659
+ static token = "checksum";
10660
+ static parentToken = "file";
10661
+ token = "checksum";
10662
+ _value;
10663
+ constructor(value) {
10664
+ super();
10665
+ this._value = value;
10666
+ }
10667
+ static fromSexprPrimitives(primitiveSexprs) {
10668
+ const value = toStringValue(primitiveSexprs[0]);
10669
+ if (value === void 0) {
10670
+ throw new Error("file checksum expects a string value");
10671
+ }
10672
+ return new _EmbeddedFileChecksum(value);
10673
+ }
10674
+ get value() {
10675
+ return this._value;
10676
+ }
10677
+ set value(value) {
10678
+ this._value = value;
10679
+ }
10680
+ getChildren() {
10681
+ return [];
10682
+ }
10683
+ getString() {
10684
+ return `(checksum ${quoteSExprString(this._value)})`;
10685
+ }
10686
+ };
10687
+ SxClass.register(EmbeddedFileChecksum);
10688
+
10689
+ // lib/sexpr/classes/EmbeddedFileData.ts
10690
+ var EmbeddedFileData = class _EmbeddedFileData extends SxClass {
10691
+ static token = "data";
10692
+ static parentToken = "file";
10693
+ token = "data";
10694
+ _chunks;
10695
+ constructor(chunks = []) {
10696
+ super();
10697
+ this._chunks = chunks;
10698
+ }
10699
+ static fromSexprPrimitives(primitiveSexprs) {
10700
+ const chunks = primitiveSexprs.map(
10701
+ (primitive) => primitiveToChunk2(primitive)
10702
+ );
10703
+ return new _EmbeddedFileData(chunks);
10704
+ }
10705
+ static fromStrings(values) {
10706
+ return new _EmbeddedFileData(values);
10707
+ }
10708
+ get chunks() {
10709
+ return [...this._chunks];
10710
+ }
10711
+ set chunks(values) {
10712
+ this._chunks = [...values];
10713
+ }
10714
+ get value() {
10715
+ return this._chunks.join("");
10716
+ }
10717
+ set value(data) {
10718
+ this._chunks = [data];
10719
+ }
10720
+ getChildren() {
10721
+ return [];
10722
+ }
10723
+ getString() {
10724
+ if (this._chunks.length === 0) {
10725
+ return "(data)";
10726
+ }
10727
+ const rendered = this._chunks.map((chunk) => printSExpr(chunk)).join(" ");
10728
+ return `(data ${rendered})`;
10729
+ }
10730
+ };
10731
+ SxClass.register(EmbeddedFileData);
10732
+ function primitiveToChunk2(value) {
10733
+ const stringValue = toStringValue(value);
10734
+ if (stringValue !== void 0) {
10735
+ return stringValue;
10736
+ }
10737
+ return printSExpr(value);
10738
+ }
10739
+
10740
+ // lib/sexpr/classes/EmbeddedFileName.ts
10741
+ var EmbeddedFileName = class _EmbeddedFileName extends SxClass {
10742
+ static token = "name";
10743
+ static parentToken = "file";
10744
+ token = "name";
10745
+ _value;
10746
+ constructor(value) {
10747
+ super();
10748
+ this._value = value;
10749
+ }
10750
+ static fromSexprPrimitives(primitiveSexprs) {
10751
+ const value = toStringValue(primitiveSexprs[0]);
10752
+ if (value === void 0) {
10753
+ throw new Error("file name expects a string value");
10754
+ }
10755
+ return new _EmbeddedFileName(value);
10756
+ }
10757
+ get value() {
10758
+ return this._value;
10759
+ }
10760
+ set value(value) {
10761
+ this._value = value;
10762
+ }
10763
+ getChildren() {
10764
+ return [];
10765
+ }
10766
+ getString() {
10767
+ return `(name ${quoteSExprString(this._value)})`;
10768
+ }
10769
+ };
10770
+ SxClass.register(EmbeddedFileName);
10771
+
10772
+ // lib/sexpr/classes/EmbeddedFileType.ts
10773
+ var EmbeddedFileType = class _EmbeddedFileType extends SxClass {
10774
+ static token = "type";
10775
+ static parentToken = "file";
10776
+ token = "type";
10777
+ _value;
10778
+ constructor(value) {
10779
+ super();
10780
+ this._value = value;
10781
+ }
10782
+ static fromSexprPrimitives(primitiveSexprs) {
10783
+ const value = toStringValue(primitiveSexprs[0]);
10784
+ if (value === void 0) {
10785
+ throw new Error("file type expects a string value");
10786
+ }
10787
+ return new _EmbeddedFileType(value);
10788
+ }
10789
+ get value() {
10790
+ return this._value;
10791
+ }
10792
+ set value(value) {
10793
+ this._value = value;
10794
+ }
10795
+ getChildren() {
10796
+ return [];
10797
+ }
10798
+ getString() {
10799
+ return `(type ${quoteSExprString(this._value)})`;
10800
+ }
10801
+ };
10802
+ SxClass.register(EmbeddedFileType);
10803
+
10804
+ // lib/sexpr/classes/EmbeddedFile.ts
10805
+ var SUPPORTED_SINGLE_TOKENS5 = /* @__PURE__ */ new Set(["name", "type", "checksum", "data"]);
10806
+ var EmbeddedFile = class _EmbeddedFile extends SxClass {
10807
+ static token = "file";
10808
+ static parentToken = "embedded_files";
10809
+ token = "file";
10810
+ _sxName;
10811
+ _sxType;
10812
+ _sxChecksum;
10813
+ _sxData;
10814
+ constructor(params = {}) {
10815
+ super();
10816
+ if (params.name !== void 0) this.name = params.name;
10817
+ if (params.type !== void 0) this.type = params.type;
10818
+ if (params.checksum !== void 0) this.checksum = params.checksum;
10819
+ if (params.data !== void 0) this.data = params.data;
10820
+ }
10821
+ static fromSexprPrimitives(primitiveSexprs) {
10822
+ const embeddedFile = new _EmbeddedFile();
10823
+ const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(primitiveSexprs, this.token);
10824
+ for (const token of Object.keys(propertyMap)) {
10825
+ if (!SUPPORTED_SINGLE_TOKENS5.has(token)) {
10826
+ throw new Error(`file encountered unsupported child token "${token}"`);
10827
+ }
10828
+ }
10829
+ for (const [token, entries] of Object.entries(arrayPropertyMap)) {
10830
+ if (!SUPPORTED_SINGLE_TOKENS5.has(token)) {
10831
+ throw new Error(`file encountered unsupported child token "${token}"`);
10832
+ }
10833
+ if (entries.length > 1) {
10834
+ throw new Error(`file does not support repeated child token "${token}"`);
10835
+ }
10836
+ }
10837
+ embeddedFile._sxName = propertyMap.name;
10838
+ embeddedFile._sxType = propertyMap.type;
10839
+ embeddedFile._sxChecksum = propertyMap.checksum;
10840
+ embeddedFile._sxData = propertyMap.data;
10841
+ return embeddedFile;
10842
+ }
10843
+ get name() {
10844
+ return this._sxName?.value;
10845
+ }
10846
+ set name(value) {
10847
+ if (value === void 0) {
10848
+ this._sxName = void 0;
10849
+ return;
10850
+ }
10851
+ this._sxName = value instanceof EmbeddedFileName ? value : new EmbeddedFileName(value);
10852
+ }
10853
+ get type() {
10854
+ return this._sxType?.value;
10855
+ }
10856
+ set type(value) {
10857
+ if (value === void 0) {
10858
+ this._sxType = void 0;
10859
+ return;
10860
+ }
10861
+ this._sxType = value instanceof EmbeddedFileType ? value : new EmbeddedFileType(value);
10862
+ }
10863
+ get checksum() {
10864
+ return this._sxChecksum?.value;
10865
+ }
10866
+ set checksum(value) {
10867
+ if (value === void 0) {
10868
+ this._sxChecksum = void 0;
10869
+ return;
10870
+ }
10871
+ this._sxChecksum = value instanceof EmbeddedFileChecksum ? value : new EmbeddedFileChecksum(value);
10872
+ }
10873
+ get data() {
10874
+ return this._sxData;
10875
+ }
10876
+ set data(value) {
10877
+ if (value === void 0) {
10878
+ this._sxData = void 0;
10879
+ return;
10880
+ }
10881
+ if (value instanceof EmbeddedFileData) {
10882
+ this._sxData = value;
10883
+ return;
10884
+ }
10885
+ this._sxData = EmbeddedFileData.fromStrings(
10886
+ Array.isArray(value) ? value : [value]
10887
+ );
10888
+ }
10889
+ getChildren() {
10890
+ const children = [];
10891
+ if (this._sxName) children.push(this._sxName);
10892
+ if (this._sxType) children.push(this._sxType);
10893
+ if (this._sxChecksum) children.push(this._sxChecksum);
10894
+ if (this._sxData) children.push(this._sxData);
10895
+ return children;
10896
+ }
10897
+ };
10898
+ SxClass.register(EmbeddedFile);
10899
+
10900
+ // lib/sexpr/classes/EmbeddedFiles.ts
10901
+ var EmbeddedFiles = class _EmbeddedFiles extends SxClass {
10902
+ static token = "embedded_files";
10903
+ token = "embedded_files";
10904
+ _files = [];
10905
+ constructor(params = {}) {
10906
+ super();
10907
+ if (params.files !== void 0) this.files = params.files;
10908
+ }
10909
+ static fromSexprPrimitives(primitiveSexprs) {
10910
+ const embeddedFiles = new _EmbeddedFiles();
10911
+ for (const primitive of primitiveSexprs) {
10912
+ if (!Array.isArray(primitive) || primitive.length === 0) {
10913
+ throw new Error(
10914
+ `embedded_files encountered unsupported child: ${JSON.stringify(primitive)}`
10915
+ );
10916
+ }
10917
+ const parsed = SxClass.parsePrimitiveSexpr(primitive, {
10918
+ parentToken: this.token
10919
+ });
10920
+ if (!(parsed instanceof EmbeddedFile)) {
10921
+ throw new Error(
10922
+ `embedded_files expected file child, received ${JSON.stringify(primitive)}`
10923
+ );
10924
+ }
10925
+ embeddedFiles._files.push(parsed);
10926
+ }
10927
+ return embeddedFiles;
10928
+ }
10929
+ get files() {
10930
+ return [...this._files];
10931
+ }
10932
+ set files(value) {
10933
+ this._files = [...value];
10934
+ }
10935
+ getChildren() {
10936
+ return [...this._files];
10937
+ }
10938
+ };
10939
+ SxClass.register(EmbeddedFiles);
10570
10940
 
10571
10941
  // lib/sexpr/classes/FootprintLocked.ts
10572
10942
  var FootprintLocked = class _FootprintLocked extends SxPrimitiveBoolean {
@@ -10644,7 +11014,8 @@ var SINGLE_TOKENS2 = /* @__PURE__ */ new Set([
10644
11014
  "net_tie_pad_groups",
10645
11015
  "sheetname",
10646
11016
  "sheetfile",
10647
- "embedded_fonts"
11017
+ "embedded_fonts",
11018
+ "embedded_files"
10648
11019
  ]);
10649
11020
  var MULTI_TOKENS2 = /* @__PURE__ */ new Set([
10650
11021
  "property",
@@ -10692,6 +11063,7 @@ var Footprint = class _Footprint extends SxClass {
10692
11063
  _sxSheetname;
10693
11064
  _sxSheetfile;
10694
11065
  _sxEmbeddedFonts;
11066
+ _sxEmbeddedFiles;
10695
11067
  _properties = [];
10696
11068
  _fpTexts = [];
10697
11069
  _fpTextBoxes = [];
@@ -10742,6 +11114,8 @@ var Footprint = class _Footprint extends SxClass {
10742
11114
  if (params.sheetfile !== void 0) this.sheetfile = params.sheetfile;
10743
11115
  if (params.embeddedFonts !== void 0)
10744
11116
  this.embeddedFonts = params.embeddedFonts;
11117
+ if (params.embeddedFiles !== void 0)
11118
+ this.embeddedFiles = params.embeddedFiles;
10745
11119
  if (params.properties !== void 0) this.properties = params.properties;
10746
11120
  if (params.fpTexts !== void 0) this.fpTexts = params.fpTexts;
10747
11121
  if (params.fpTextBoxes !== void 0) this.fpTextBoxes = params.fpTextBoxes;
@@ -10833,6 +11207,7 @@ var Footprint = class _Footprint extends SxClass {
10833
11207
  footprint._sxSheetname = propertyMap.sheetname;
10834
11208
  footprint._sxSheetfile = propertyMap.sheetfile;
10835
11209
  footprint._sxEmbeddedFonts = propertyMap.embedded_fonts;
11210
+ footprint._sxEmbeddedFiles = propertyMap.embedded_files;
10836
11211
  footprint._properties = arrayPropertyMap.property ?? [];
10837
11212
  footprint._fpTexts = arrayPropertyMap["fp_text"] ?? [];
10838
11213
  footprint._fpTextBoxes = arrayPropertyMap["fp_text_box"] ?? [];
@@ -11165,6 +11540,12 @@ var Footprint = class _Footprint extends SxClass {
11165
11540
  set embeddedFonts(value) {
11166
11541
  this._sxEmbeddedFonts = value;
11167
11542
  }
11543
+ get embeddedFiles() {
11544
+ return this._sxEmbeddedFiles;
11545
+ }
11546
+ set embeddedFiles(value) {
11547
+ this._sxEmbeddedFiles = value;
11548
+ }
11168
11549
  get properties() {
11169
11550
  return [...this._properties];
11170
11551
  }
@@ -11256,6 +11637,7 @@ var Footprint = class _Footprint extends SxClass {
11256
11637
  if (this._sxSheetname) children.push(this._sxSheetname);
11257
11638
  if (this._sxSheetfile) children.push(this._sxSheetfile);
11258
11639
  if (this._sxEmbeddedFonts) children.push(this._sxEmbeddedFonts);
11640
+ if (this._sxEmbeddedFiles) children.push(this._sxEmbeddedFiles);
11259
11641
  children.push(...this._properties);
11260
11642
  children.push(...this._fpTexts);
11261
11643
  children.push(...this._fpTextBoxes);
@@ -11283,7 +11665,7 @@ var Footprint = class _Footprint extends SxClass {
11283
11665
  SxClass.register(Footprint);
11284
11666
 
11285
11667
  // lib/sexpr/classes/GrArc.ts
11286
- var SUPPORTED_SINGLE_TOKENS5 = /* @__PURE__ */ new Set([
11668
+ var SUPPORTED_SINGLE_TOKENS6 = /* @__PURE__ */ new Set([
11287
11669
  "start",
11288
11670
  "mid",
11289
11671
  "end",
@@ -11320,12 +11702,12 @@ var GrArc = class _GrArc extends SxClass {
11320
11702
  const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(primitiveSexprs, this.token);
11321
11703
  const unexpectedTokens = /* @__PURE__ */ new Set();
11322
11704
  for (const token of Object.keys(propertyMap)) {
11323
- if (!SUPPORTED_SINGLE_TOKENS5.has(token)) {
11705
+ if (!SUPPORTED_SINGLE_TOKENS6.has(token)) {
11324
11706
  unexpectedTokens.add(token);
11325
11707
  }
11326
11708
  }
11327
11709
  for (const token of Object.keys(arrayPropertyMap)) {
11328
- if (!SUPPORTED_SINGLE_TOKENS5.has(token)) {
11710
+ if (!SUPPORTED_SINGLE_TOKENS6.has(token)) {
11329
11711
  unexpectedTokens.add(token);
11330
11712
  continue;
11331
11713
  }
@@ -11499,6 +11881,8 @@ var GrArcStart = class _GrArcStart extends SxClass {
11499
11881
  this.x = x;
11500
11882
  this.y = y;
11501
11883
  }
11884
+ x;
11885
+ y;
11502
11886
  static token = "start";
11503
11887
  static parentToken = "gr_arc";
11504
11888
  token = "start";
@@ -11528,6 +11912,8 @@ var GrArcMid = class _GrArcMid extends SxClass {
11528
11912
  this.x = x;
11529
11913
  this.y = y;
11530
11914
  }
11915
+ x;
11916
+ y;
11531
11917
  static token = "mid";
11532
11918
  static parentToken = "gr_arc";
11533
11919
  token = "mid";
@@ -11557,6 +11943,8 @@ var GrArcEnd = class _GrArcEnd extends SxClass {
11557
11943
  this.x = x;
11558
11944
  this.y = y;
11559
11945
  }
11946
+ x;
11947
+ y;
11560
11948
  static token = "end";
11561
11949
  static parentToken = "gr_arc";
11562
11950
  token = "end";
@@ -11582,7 +11970,7 @@ var GrArcEnd = class _GrArcEnd extends SxClass {
11582
11970
  SxClass.register(GrArcEnd);
11583
11971
 
11584
11972
  // lib/sexpr/classes/GrCircle.ts
11585
- var SUPPORTED_SINGLE_TOKENS6 = /* @__PURE__ */ new Set([
11973
+ var SUPPORTED_SINGLE_TOKENS7 = /* @__PURE__ */ new Set([
11586
11974
  "center",
11587
11975
  "end",
11588
11976
  "layer",
@@ -11622,12 +12010,12 @@ var GrCircle = class _GrCircle extends SxClass {
11622
12010
  const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(primitiveSexprs, this.token);
11623
12011
  const unexpectedTokens = /* @__PURE__ */ new Set();
11624
12012
  for (const token of Object.keys(propertyMap)) {
11625
- if (!SUPPORTED_SINGLE_TOKENS6.has(token)) {
12013
+ if (!SUPPORTED_SINGLE_TOKENS7.has(token)) {
11626
12014
  unexpectedTokens.add(token);
11627
12015
  }
11628
12016
  }
11629
12017
  for (const token of Object.keys(arrayPropertyMap)) {
11630
- if (!SUPPORTED_SINGLE_TOKENS6.has(token)) {
12018
+ if (!SUPPORTED_SINGLE_TOKENS7.has(token)) {
11631
12019
  unexpectedTokens.add(token);
11632
12020
  continue;
11633
12021
  }
@@ -11813,6 +12201,8 @@ var GrCircleCenter = class _GrCircleCenter extends SxClass {
11813
12201
  this.x = x;
11814
12202
  this.y = y;
11815
12203
  }
12204
+ x;
12205
+ y;
11816
12206
  static token = "center";
11817
12207
  static parentToken = "gr_circle";
11818
12208
  token = "center";
@@ -11842,6 +12232,8 @@ var GrCircleEnd = class _GrCircleEnd extends SxClass {
11842
12232
  this.x = x;
11843
12233
  this.y = y;
11844
12234
  }
12235
+ x;
12236
+ y;
11845
12237
  static token = "end";
11846
12238
  static parentToken = "gr_circle";
11847
12239
  token = "end";
@@ -12118,7 +12510,7 @@ var GrLineLocked = class _GrLineLocked extends SxPrimitiveBoolean {
12118
12510
  SxClass.register(GrLineLocked);
12119
12511
 
12120
12512
  // lib/sexpr/classes/GrLine.ts
12121
- var SUPPORTED_SINGLE_TOKENS7 = /* @__PURE__ */ new Set([
12513
+ var SUPPORTED_SINGLE_TOKENS8 = /* @__PURE__ */ new Set([
12122
12514
  "start",
12123
12515
  "end",
12124
12516
  "angle",
@@ -12158,12 +12550,12 @@ var GrLine = class _GrLine extends SxClass {
12158
12550
  const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(primitiveSexprs, this.token);
12159
12551
  const unexpectedTokens = /* @__PURE__ */ new Set();
12160
12552
  for (const token of Object.keys(propertyMap)) {
12161
- if (!SUPPORTED_SINGLE_TOKENS7.has(token)) {
12553
+ if (!SUPPORTED_SINGLE_TOKENS8.has(token)) {
12162
12554
  unexpectedTokens.add(token);
12163
12555
  }
12164
12556
  }
12165
12557
  for (const token of Object.keys(arrayPropertyMap)) {
12166
- if (!SUPPORTED_SINGLE_TOKENS7.has(token)) {
12558
+ if (!SUPPORTED_SINGLE_TOKENS8.has(token)) {
12167
12559
  unexpectedTokens.add(token);
12168
12560
  continue;
12169
12561
  }
@@ -12331,7 +12723,7 @@ var GrLine = class _GrLine extends SxClass {
12331
12723
  SxClass.register(GrLine);
12332
12724
 
12333
12725
  // lib/sexpr/classes/GrRect.ts
12334
- var SUPPORTED_SINGLE_TOKENS8 = /* @__PURE__ */ new Set([
12726
+ var SUPPORTED_SINGLE_TOKENS9 = /* @__PURE__ */ new Set([
12335
12727
  "start",
12336
12728
  "end",
12337
12729
  "layer",
@@ -12368,12 +12760,12 @@ var GrRect = class _GrRect extends SxClass {
12368
12760
  const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(primitiveSexprs, this.token);
12369
12761
  const unexpectedTokens = /* @__PURE__ */ new Set();
12370
12762
  for (const token of Object.keys(propertyMap)) {
12371
- if (!SUPPORTED_SINGLE_TOKENS8.has(token)) {
12763
+ if (!SUPPORTED_SINGLE_TOKENS9.has(token)) {
12372
12764
  unexpectedTokens.add(token);
12373
12765
  }
12374
12766
  }
12375
12767
  for (const token of Object.keys(arrayPropertyMap)) {
12376
- if (!SUPPORTED_SINGLE_TOKENS8.has(token)) {
12768
+ if (!SUPPORTED_SINGLE_TOKENS9.has(token)) {
12377
12769
  unexpectedTokens.add(token);
12378
12770
  continue;
12379
12771
  }
@@ -12670,7 +13062,7 @@ var GrRectLocked = class _GrRectLocked extends SxClass {
12670
13062
  SxClass.register(GrRectLocked);
12671
13063
 
12672
13064
  // lib/sexpr/classes/GrText.ts
12673
- var SUPPORTED_SINGLE_TOKENS9 = /* @__PURE__ */ new Set([
13065
+ var SUPPORTED_SINGLE_TOKENS10 = /* @__PURE__ */ new Set([
12674
13066
  "at",
12675
13067
  "xy",
12676
13068
  "layer",
@@ -12726,7 +13118,7 @@ var GrText = class _GrText extends SxClass {
12726
13118
  const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(rest, this.token);
12727
13119
  const unexpectedTokens = /* @__PURE__ */ new Set();
12728
13120
  for (const token of Object.keys(propertyMap)) {
12729
- if (!SUPPORTED_SINGLE_TOKENS9.has(token)) {
13121
+ if (!SUPPORTED_SINGLE_TOKENS10.has(token)) {
12730
13122
  unexpectedTokens.add(token);
12731
13123
  }
12732
13124
  }
@@ -13212,7 +13604,7 @@ var GrPoly = class _GrPoly extends SxClass {
13212
13604
  SxClass.register(GrPoly);
13213
13605
 
13214
13606
  // lib/sexpr/classes/Group.ts
13215
- var SUPPORTED_SINGLE_TOKENS10 = /* @__PURE__ */ new Set(["uuid", "locked", "members"]);
13607
+ var SUPPORTED_SINGLE_TOKENS11 = /* @__PURE__ */ new Set(["uuid", "locked", "members"]);
13216
13608
  var Group = class _Group extends SxClass {
13217
13609
  static token = "group";
13218
13610
  token = "group";
@@ -13238,12 +13630,12 @@ var Group = class _Group extends SxClass {
13238
13630
  );
13239
13631
  const unexpectedTokens = /* @__PURE__ */ new Set();
13240
13632
  for (const token of Object.keys(propertyMap)) {
13241
- if (!SUPPORTED_SINGLE_TOKENS10.has(token)) {
13633
+ if (!SUPPORTED_SINGLE_TOKENS11.has(token)) {
13242
13634
  unexpectedTokens.add(token);
13243
13635
  }
13244
13636
  }
13245
13637
  for (const token of Object.keys(arrayPropertyMap)) {
13246
- if (!SUPPORTED_SINGLE_TOKENS10.has(token)) {
13638
+ if (!SUPPORTED_SINGLE_TOKENS11.has(token)) {
13247
13639
  unexpectedTokens.add(token);
13248
13640
  continue;
13249
13641
  }
@@ -13375,6 +13767,214 @@ var GroupMembers = class _GroupMembers extends SxClass {
13375
13767
  };
13376
13768
  SxClass.register(GroupMembers);
13377
13769
 
13770
+ // lib/sexpr/classes/Generated.ts
13771
+ var Generated = class _Generated extends SxClass {
13772
+ static token = "generated";
13773
+ static parentToken = "kicad_pcb";
13774
+ token = "generated";
13775
+ _rawChildren = [];
13776
+ constructor() {
13777
+ super();
13778
+ }
13779
+ static fromSexprPrimitives(primitiveSexprs) {
13780
+ const generated = new _Generated();
13781
+ generated.rawChildren = primitiveSexprs;
13782
+ return generated;
13783
+ }
13784
+ get rawChildren() {
13785
+ return [...this._rawChildren];
13786
+ }
13787
+ set rawChildren(value) {
13788
+ this._rawChildren = [...value];
13789
+ }
13790
+ getChildren() {
13791
+ return [];
13792
+ }
13793
+ getString() {
13794
+ const lines = ["(generated"];
13795
+ for (const child of this._rawChildren) {
13796
+ const rendered = printSExpr(child);
13797
+ lines.push(...rendered.split("\n").map((line) => ` ${line}`));
13798
+ }
13799
+ lines.push(")");
13800
+ return lines.join("\n");
13801
+ }
13802
+ };
13803
+ SxClass.register(Generated);
13804
+
13805
+ // lib/sexpr/classes/PcbArc.ts
13806
+ var PcbArc = class _PcbArc extends SxClass {
13807
+ static token = "arc";
13808
+ static parentToken = "kicad_pcb";
13809
+ token = "arc";
13810
+ _start;
13811
+ _mid;
13812
+ _end;
13813
+ _sxWidth;
13814
+ _sxLayer;
13815
+ _net;
13816
+ _sxUuid;
13817
+ constructor(params = {}) {
13818
+ super();
13819
+ if (params.start !== void 0) this.start = params.start;
13820
+ if (params.mid !== void 0) this.mid = params.mid;
13821
+ if (params.end !== void 0) this.end = params.end;
13822
+ if (params.width !== void 0) this.width = params.width;
13823
+ if (params.layer !== void 0) this.layer = params.layer;
13824
+ if (params.net !== void 0) this.net = params.net;
13825
+ if (params.uuid !== void 0) this.uuid = params.uuid;
13826
+ }
13827
+ static fromSexprPrimitives(primitiveSexprs) {
13828
+ const arc = new _PcbArc();
13829
+ for (const primitive of primitiveSexprs) {
13830
+ if (!Array.isArray(primitive) || primitive.length === 0) {
13831
+ throw new Error(
13832
+ `arc encountered unsupported child: ${JSON.stringify(primitive)}`
13833
+ );
13834
+ }
13835
+ const [token, ...args] = primitive;
13836
+ if (token === "start") {
13837
+ arc._start = parsePoint(args, "start");
13838
+ continue;
13839
+ }
13840
+ if (token === "mid") {
13841
+ arc._mid = parsePoint(args, "mid");
13842
+ continue;
13843
+ }
13844
+ if (token === "end") {
13845
+ arc._end = parsePoint(args, "end");
13846
+ continue;
13847
+ }
13848
+ if (token === "width") {
13849
+ arc._sxWidth = new Width(parseNumber(args[0], "width"));
13850
+ continue;
13851
+ }
13852
+ if (token === "layer") {
13853
+ const layerName = parseLayer(args);
13854
+ arc._sxLayer = new Layer([layerName]);
13855
+ continue;
13856
+ }
13857
+ if (token === "net") {
13858
+ arc._net = parseNumber(args[0], "net");
13859
+ continue;
13860
+ }
13861
+ if (token === "uuid") {
13862
+ arc._sxUuid = new Uuid(parseString(args[0], "uuid"));
13863
+ continue;
13864
+ }
13865
+ throw new Error(`arc encountered unsupported child token "${token}"`);
13866
+ }
13867
+ if (!arc._start || !arc._mid || !arc._end) {
13868
+ throw new Error("arc requires start, mid, and end child tokens");
13869
+ }
13870
+ if (!arc._sxLayer) {
13871
+ throw new Error("arc requires a layer child token");
13872
+ }
13873
+ return arc;
13874
+ }
13875
+ get start() {
13876
+ return this._start ? { ...this._start } : void 0;
13877
+ }
13878
+ set start(value) {
13879
+ this._start = value ? { ...value } : void 0;
13880
+ }
13881
+ get mid() {
13882
+ return this._mid ? { ...this._mid } : void 0;
13883
+ }
13884
+ set mid(value) {
13885
+ this._mid = value ? { ...value } : void 0;
13886
+ }
13887
+ get end() {
13888
+ return this._end ? { ...this._end } : void 0;
13889
+ }
13890
+ set end(value) {
13891
+ this._end = value ? { ...value } : void 0;
13892
+ }
13893
+ get width() {
13894
+ return this._sxWidth?.value;
13895
+ }
13896
+ set width(value) {
13897
+ if (value === void 0) {
13898
+ this._sxWidth = void 0;
13899
+ return;
13900
+ }
13901
+ this._sxWidth = value instanceof Width ? value : new Width(value);
13902
+ }
13903
+ get layer() {
13904
+ return this._sxLayer;
13905
+ }
13906
+ set layer(value) {
13907
+ if (value === void 0) {
13908
+ this._sxLayer = void 0;
13909
+ return;
13910
+ }
13911
+ this._sxLayer = value instanceof Layer ? value : new Layer([value]);
13912
+ }
13913
+ get net() {
13914
+ return this._net;
13915
+ }
13916
+ set net(value) {
13917
+ this._net = value;
13918
+ }
13919
+ get uuid() {
13920
+ return this._sxUuid;
13921
+ }
13922
+ set uuid(value) {
13923
+ if (value === void 0) {
13924
+ this._sxUuid = void 0;
13925
+ return;
13926
+ }
13927
+ this._sxUuid = value instanceof Uuid ? value : new Uuid(value);
13928
+ }
13929
+ getChildren() {
13930
+ return [];
13931
+ }
13932
+ getString() {
13933
+ const lines = ["(arc"];
13934
+ if (this._start) lines.push(renderPoint("start", this._start));
13935
+ if (this._mid) lines.push(renderPoint("mid", this._mid));
13936
+ if (this._end) lines.push(renderPoint("end", this._end));
13937
+ if (this._sxWidth) lines.push(this._sxWidth.getStringIndented());
13938
+ if (this._sxLayer) lines.push(this._sxLayer.getStringIndented());
13939
+ if (this._net !== void 0) lines.push(` (net ${this._net})`);
13940
+ if (this._sxUuid) lines.push(this._sxUuid.getStringIndented());
13941
+ lines.push(")");
13942
+ return lines.join("\n");
13943
+ }
13944
+ };
13945
+ SxClass.register(PcbArc);
13946
+ function parsePoint(args, label) {
13947
+ if (args.length !== 2) {
13948
+ throw new Error(`arc ${label} expects two numeric values`);
13949
+ }
13950
+ return {
13951
+ x: parseNumber(args[0], `${label}.x`),
13952
+ y: parseNumber(args[1], `${label}.y`)
13953
+ };
13954
+ }
13955
+ function parseNumber(value, label) {
13956
+ const numeric = toNumberValue(value);
13957
+ if (numeric === void 0) {
13958
+ throw new Error(`arc ${label} expects a numeric value`);
13959
+ }
13960
+ return numeric;
13961
+ }
13962
+ function parseString(value, label) {
13963
+ if (typeof value !== "string") {
13964
+ throw new Error(`arc ${label} expects a string value`);
13965
+ }
13966
+ return value;
13967
+ }
13968
+ function parseLayer(args) {
13969
+ if (args.length !== 1) {
13970
+ throw new Error("arc layer expects a single string value");
13971
+ }
13972
+ return parseString(args[0], "layer");
13973
+ }
13974
+ function renderPoint(label, point) {
13975
+ return ` (${label} ${point.x} ${point.y})`;
13976
+ }
13977
+
13378
13978
  // lib/sexpr/classes/SegmentEnd.ts
13379
13979
  var SegmentEnd = class _SegmentEnd extends SxClass {
13380
13980
  static token = "end";
@@ -13537,7 +14137,7 @@ var SegmentStart = class _SegmentStart extends SxClass {
13537
14137
  SxClass.register(SegmentStart);
13538
14138
 
13539
14139
  // lib/sexpr/classes/Segment.ts
13540
- var SUPPORTED_SINGLE_TOKENS11 = /* @__PURE__ */ new Set([
14140
+ var SUPPORTED_SINGLE_TOKENS12 = /* @__PURE__ */ new Set([
13541
14141
  "start",
13542
14142
  "end",
13543
14143
  "width",
@@ -13573,7 +14173,7 @@ var Segment = class _Segment extends SxClass {
13573
14173
  const segment = new _Segment();
13574
14174
  const { propertyMap, arrayPropertyMap } = SxClass.parsePrimitivesToClassProperties(primitiveSexprs, this.token);
13575
14175
  const unexpectedSingleTokens = Object.keys(propertyMap).filter(
13576
- (token) => !SUPPORTED_SINGLE_TOKENS11.has(token)
14176
+ (token) => !SUPPORTED_SINGLE_TOKENS12.has(token)
13577
14177
  );
13578
14178
  if (unexpectedSingleTokens.length > 0) {
13579
14179
  throw new Error(
@@ -13581,7 +14181,7 @@ var Segment = class _Segment extends SxClass {
13581
14181
  );
13582
14182
  }
13583
14183
  for (const [token, entries] of Object.entries(arrayPropertyMap)) {
13584
- if (!SUPPORTED_SINGLE_TOKENS11.has(token)) {
14184
+ if (!SUPPORTED_SINGLE_TOKENS12.has(token)) {
13585
14185
  throw new Error(
13586
14186
  `Unsupported child tokens inside segment expression: ${token}`
13587
14187
  );
@@ -16307,6 +16907,7 @@ var KicadPcb = class _KicadPcb extends SxClass {
16307
16907
  _vias = [];
16308
16908
  _zones = [];
16309
16909
  _sxEmbeddedFonts;
16910
+ _sxEmbeddedFiles;
16310
16911
  _otherChildren = [];
16311
16912
  constructor(params = {}) {
16312
16913
  super();
@@ -16336,6 +16937,8 @@ var KicadPcb = class _KicadPcb extends SxClass {
16336
16937
  if (params.zones !== void 0) this.zones = params.zones;
16337
16938
  if (params.embeddedFonts !== void 0)
16338
16939
  this.embeddedFonts = params.embeddedFonts;
16940
+ if (params.embeddedFiles !== void 0)
16941
+ this.embeddedFiles = params.embeddedFiles;
16339
16942
  if (params.otherChildren !== void 0)
16340
16943
  this.otherChildren = params.otherChildren;
16341
16944
  }
@@ -16440,6 +17043,10 @@ var KicadPcb = class _KicadPcb extends SxClass {
16440
17043
  this._sxEmbeddedFonts = child;
16441
17044
  return;
16442
17045
  }
17046
+ if (child instanceof EmbeddedFiles) {
17047
+ this._sxEmbeddedFiles = child;
17048
+ return;
17049
+ }
16443
17050
  this._otherChildren.push(child);
16444
17051
  }
16445
17052
  get version() {
@@ -16562,6 +17169,12 @@ var KicadPcb = class _KicadPcb extends SxClass {
16562
17169
  set embeddedFonts(value) {
16563
17170
  this._sxEmbeddedFonts = value;
16564
17171
  }
17172
+ get embeddedFiles() {
17173
+ return this._sxEmbeddedFiles;
17174
+ }
17175
+ set embeddedFiles(value) {
17176
+ this._sxEmbeddedFiles = value;
17177
+ }
16565
17178
  get otherChildren() {
16566
17179
  return [...this._otherChildren];
16567
17180
  }
@@ -16590,6 +17203,7 @@ var KicadPcb = class _KicadPcb extends SxClass {
16590
17203
  children.push(...this._vias);
16591
17204
  children.push(...this._zones);
16592
17205
  if (this._sxEmbeddedFonts) children.push(this._sxEmbeddedFonts);
17206
+ if (this._sxEmbeddedFiles) children.push(this._sxEmbeddedFiles);
16593
17207
  children.push(...this._otherChildren);
16594
17208
  return children;
16595
17209
  }
@@ -16634,6 +17248,12 @@ export {
16634
17248
  BusEntrySize,
16635
17249
  Color,
16636
17250
  Dnp,
17251
+ EmbeddedFile,
17252
+ EmbeddedFileChecksum,
17253
+ EmbeddedFileData,
17254
+ EmbeddedFileName,
17255
+ EmbeddedFileType,
17256
+ EmbeddedFiles,
16637
17257
  EmbeddedFonts,
16638
17258
  ExcludeFromSim,
16639
17259
  FieldsAutoplaced,
@@ -16686,6 +17306,7 @@ export {
16686
17306
  FpTextBoxAngle,
16687
17307
  FpTextBoxEnd,
16688
17308
  FpTextBoxStart,
17309
+ Generated,
16689
17310
  GlobalLabel,
16690
17311
  GrArc,
16691
17312
  GrArcEnd,
@@ -16752,6 +17373,7 @@ export {
16752
17373
  PadPrimitiveGrLine,
16753
17374
  PadPrimitiveGrPoly,
16754
17375
  PadPrimitives,
17376
+ PadProperty,
16755
17377
  PadRectDelta,
16756
17378
  PadRoundrectRratio,
16757
17379
  PadSize,
@@ -16764,6 +17386,7 @@ export {
16764
17386
  PadThermalWidth,
16765
17387
  PadZoneConnect,
16766
17388
  Paper,
17389
+ PcbArc,
16767
17390
  PcbGeneral,
16768
17391
  PcbGeneralLegacyTeardrops,
16769
17392
  PcbGeneralThickness,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "kicadts",
3
3
  "main": "dist/index.js",
4
- "version": "0.0.25",
4
+ "version": "0.0.26",
5
5
  "type": "module",
6
6
  "repository": {
7
7
  "type": "git",