@tscircuit/props 0.0.598 → 0.0.600
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 +14 -0
- package/dist/index.d.ts +86 -2
- package/dist/index.js +34 -26
- package/dist/index.js.map +1 -1
- package/lib/components/autoroutingphase.ts +23 -0
- package/lib/components/smtpad.ts +10 -0
- package/lib/components/transistor.ts +3 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -17174,7 +17174,8 @@ var rectSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
|
17174
17174
|
solderMaskMarginLeft: distance.optional(),
|
|
17175
17175
|
solderMaskMarginRight: distance.optional(),
|
|
17176
17176
|
solderMaskMarginTop: distance.optional(),
|
|
17177
|
-
solderMaskMarginBottom: distance.optional()
|
|
17177
|
+
solderMaskMarginBottom: distance.optional(),
|
|
17178
|
+
solderPasteMargin: distance.optional()
|
|
17178
17179
|
});
|
|
17179
17180
|
expectTypesMatch(true);
|
|
17180
17181
|
var rotatedRectSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
@@ -17190,7 +17191,8 @@ var rotatedRectSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
|
17190
17191
|
solderMaskMarginLeft: distance.optional(),
|
|
17191
17192
|
solderMaskMarginRight: distance.optional(),
|
|
17192
17193
|
solderMaskMarginTop: distance.optional(),
|
|
17193
|
-
solderMaskMarginBottom: distance.optional()
|
|
17194
|
+
solderMaskMarginBottom: distance.optional(),
|
|
17195
|
+
solderPasteMargin: distance.optional()
|
|
17194
17196
|
});
|
|
17195
17197
|
expectTypesMatch(true);
|
|
17196
17198
|
var circleSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
@@ -17199,7 +17201,8 @@ var circleSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
|
17199
17201
|
radius: distance,
|
|
17200
17202
|
portHints: portHints.optional(),
|
|
17201
17203
|
coveredWithSolderMask: z66.boolean().optional(),
|
|
17202
|
-
solderMaskMargin: distance.optional()
|
|
17204
|
+
solderMaskMargin: distance.optional(),
|
|
17205
|
+
solderPasteMargin: distance.optional()
|
|
17203
17206
|
});
|
|
17204
17207
|
expectTypesMatch(true);
|
|
17205
17208
|
var pillSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
@@ -17210,7 +17213,8 @@ var pillSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
|
17210
17213
|
radius: distance,
|
|
17211
17214
|
portHints: portHints.optional(),
|
|
17212
17215
|
coveredWithSolderMask: z66.boolean().optional(),
|
|
17213
|
-
solderMaskMargin: distance.optional()
|
|
17216
|
+
solderMaskMargin: distance.optional(),
|
|
17217
|
+
solderPasteMargin: distance.optional()
|
|
17214
17218
|
});
|
|
17215
17219
|
expectTypesMatch(true);
|
|
17216
17220
|
var polygonSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
@@ -17219,7 +17223,8 @@ var polygonSmtPadProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
|
17219
17223
|
points: z66.array(point),
|
|
17220
17224
|
portHints: portHints.optional(),
|
|
17221
17225
|
coveredWithSolderMask: z66.boolean().optional(),
|
|
17222
|
-
solderMaskMargin: distance.optional()
|
|
17226
|
+
solderMaskMargin: distance.optional(),
|
|
17227
|
+
solderPasteMargin: distance.optional()
|
|
17223
17228
|
});
|
|
17224
17229
|
expectTypesMatch(true);
|
|
17225
17230
|
var smtPadProps = z66.discriminatedUnion("shape", [
|
|
@@ -17767,6 +17772,7 @@ expectTypesMatch(true);
|
|
|
17767
17772
|
|
|
17768
17773
|
// lib/components/autoroutingphase.ts
|
|
17769
17774
|
import { z as z87 } from "zod";
|
|
17775
|
+
import { layer_ref as layer_ref6 } from "circuit-json";
|
|
17770
17776
|
var busFanoutDirection = z87.union([
|
|
17771
17777
|
ninePointAnchor,
|
|
17772
17778
|
z87.object({ direction: ninePointAnchor })
|
|
@@ -17788,7 +17794,9 @@ var autoroutingPhaseProps = z87.object({
|
|
|
17788
17794
|
connections: z87.array(z87.string()).optional(),
|
|
17789
17795
|
reroute: z87.boolean().optional(),
|
|
17790
17796
|
busFanoutDirections: z87.record(busFanoutDirection).optional(),
|
|
17791
|
-
fanoutBoundaryPadding: fanoutBoundaryPadding.optional()
|
|
17797
|
+
fanoutBoundaryPadding: fanoutBoundaryPadding.optional(),
|
|
17798
|
+
fanoutRoutingLayers: z87.array(layer_ref6).min(1).optional(),
|
|
17799
|
+
fanoutPourNetMap: z87.record(layer_ref6, z87.union([z87.string(), z87.array(z87.string()).min(1)])).optional()
|
|
17792
17800
|
}).superRefine((value, ctx) => {
|
|
17793
17801
|
if (value.reroute !== void 0 && value.region === void 0 && value.connection === void 0 && value.connections === void 0) {
|
|
17794
17802
|
ctx.addIssue({
|
|
@@ -17827,11 +17835,11 @@ var transistorProps = commonComponentProps.extend({
|
|
|
17827
17835
|
});
|
|
17828
17836
|
var transistorPins = [
|
|
17829
17837
|
"pin1",
|
|
17830
|
-
"emitter",
|
|
17831
|
-
"pin2",
|
|
17832
17838
|
"collector",
|
|
17839
|
+
"pin2",
|
|
17840
|
+
"base",
|
|
17833
17841
|
"pin3",
|
|
17834
|
-
"
|
|
17842
|
+
"emitter"
|
|
17835
17843
|
];
|
|
17836
17844
|
expectTypesMatch(true);
|
|
17837
17845
|
|
|
@@ -18130,15 +18138,15 @@ var pcbTraceProps = z101.object({
|
|
|
18130
18138
|
});
|
|
18131
18139
|
|
|
18132
18140
|
// lib/components/via.ts
|
|
18133
|
-
import { distance as distance23, layer_ref as
|
|
18141
|
+
import { distance as distance23, layer_ref as layer_ref7 } from "circuit-json";
|
|
18134
18142
|
import { z as z102 } from "zod";
|
|
18135
18143
|
var viaProps = commonLayoutProps.extend({
|
|
18136
18144
|
name: z102.string().optional(),
|
|
18137
|
-
fromLayer:
|
|
18138
|
-
toLayer:
|
|
18145
|
+
fromLayer: layer_ref7.optional(),
|
|
18146
|
+
toLayer: layer_ref7.optional(),
|
|
18139
18147
|
holeDiameter: distance23.optional(),
|
|
18140
18148
|
outerDiameter: distance23.optional(),
|
|
18141
|
-
layers: z102.array(
|
|
18149
|
+
layers: z102.array(layer_ref7).optional(),
|
|
18142
18150
|
connectsTo: z102.string().or(z102.array(z102.string())).optional(),
|
|
18143
18151
|
netIsAssignable: z102.boolean().optional()
|
|
18144
18152
|
});
|
|
@@ -18173,19 +18181,19 @@ var breakoutPointProps = pcbLayoutProps.omit({ pcbRotation: true, layer: true })
|
|
|
18173
18181
|
expectTypesMatch(true);
|
|
18174
18182
|
|
|
18175
18183
|
// lib/components/pcb-keepout.ts
|
|
18176
|
-
import { distance as distance25, layer_ref as
|
|
18184
|
+
import { distance as distance25, layer_ref as layer_ref8 } from "circuit-json";
|
|
18177
18185
|
import { z as z105 } from "zod";
|
|
18178
18186
|
var pcbKeepoutProps = z105.union([
|
|
18179
18187
|
pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
18180
18188
|
shape: z105.literal("circle"),
|
|
18181
18189
|
radius: distance25,
|
|
18182
|
-
layers: z105.array(
|
|
18190
|
+
layers: z105.array(layer_ref8).optional()
|
|
18183
18191
|
}),
|
|
18184
18192
|
pcbLayoutProps.extend({
|
|
18185
18193
|
shape: z105.literal("rect"),
|
|
18186
18194
|
width: distance25,
|
|
18187
18195
|
height: distance25,
|
|
18188
|
-
layers: z105.array(
|
|
18196
|
+
layers: z105.array(layer_ref8).optional()
|
|
18189
18197
|
})
|
|
18190
18198
|
]);
|
|
18191
18199
|
|
|
@@ -18241,10 +18249,10 @@ var courtyardPillProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
|
|
|
18241
18249
|
|
|
18242
18250
|
// lib/components/copper-pour.ts
|
|
18243
18251
|
import { z as z110 } from "zod";
|
|
18244
|
-
import { layer_ref as
|
|
18252
|
+
import { layer_ref as layer_ref9 } from "circuit-json";
|
|
18245
18253
|
var copperPourProps = z110.object({
|
|
18246
18254
|
name: z110.string().optional(),
|
|
18247
|
-
layer:
|
|
18255
|
+
layer: layer_ref9,
|
|
18248
18256
|
connectsTo: z110.string(),
|
|
18249
18257
|
unbroken: z110.boolean().optional(),
|
|
18250
18258
|
padMargin: distance.optional(),
|
|
@@ -18258,10 +18266,10 @@ var copperPourProps = z110.object({
|
|
|
18258
18266
|
expectTypesMatch(true);
|
|
18259
18267
|
|
|
18260
18268
|
// lib/components/cadassembly.ts
|
|
18261
|
-
import { layer_ref as
|
|
18269
|
+
import { layer_ref as layer_ref10 } from "circuit-json";
|
|
18262
18270
|
import { z as z111 } from "zod";
|
|
18263
18271
|
var cadassemblyProps = z111.object({
|
|
18264
|
-
originalLayer:
|
|
18272
|
+
originalLayer: layer_ref10.default("top").optional(),
|
|
18265
18273
|
children: z111.any().optional()
|
|
18266
18274
|
});
|
|
18267
18275
|
expectTypesMatch(true);
|
|
@@ -18624,20 +18632,20 @@ var schematicSheetProps = z131.object({
|
|
|
18624
18632
|
expectTypesMatch(true);
|
|
18625
18633
|
|
|
18626
18634
|
// lib/components/copper-text.ts
|
|
18627
|
-
import { layer_ref as
|
|
18635
|
+
import { layer_ref as layer_ref11, length as length8 } from "circuit-json";
|
|
18628
18636
|
import { z as z132 } from "zod";
|
|
18629
18637
|
var copperTextProps = pcbLayoutProps.extend({
|
|
18630
18638
|
text: z132.string(),
|
|
18631
18639
|
anchorAlignment: ninePointAnchor.default("center"),
|
|
18632
18640
|
font: z132.enum(["tscircuit2024"]).optional(),
|
|
18633
18641
|
fontSize: length8.optional(),
|
|
18634
|
-
layers: z132.array(
|
|
18642
|
+
layers: z132.array(layer_ref11).optional(),
|
|
18635
18643
|
knockout: z132.boolean().optional(),
|
|
18636
18644
|
mirrored: z132.boolean().optional()
|
|
18637
18645
|
});
|
|
18638
18646
|
|
|
18639
18647
|
// lib/components/silkscreen-text.ts
|
|
18640
|
-
import { layer_ref as
|
|
18648
|
+
import { layer_ref as layer_ref12, length as length9 } from "circuit-json";
|
|
18641
18649
|
import { z as z133 } from "zod";
|
|
18642
18650
|
var silkscreenTextProps = pcbLayoutProps.extend({
|
|
18643
18651
|
text: z133.string(),
|
|
@@ -18653,7 +18661,7 @@ var silkscreenTextProps = pcbLayoutProps.extend({
|
|
|
18653
18661
|
knockoutPaddingRight: length9.optional(),
|
|
18654
18662
|
knockoutPaddingTop: length9.optional(),
|
|
18655
18663
|
knockoutPaddingBottom: length9.optional(),
|
|
18656
|
-
layers: z133.array(
|
|
18664
|
+
layers: z133.array(layer_ref12).optional()
|
|
18657
18665
|
});
|
|
18658
18666
|
|
|
18659
18667
|
// lib/components/silkscreen-path.ts
|
|
@@ -18724,13 +18732,13 @@ var silkscreenGraphicProps = pcbLayoutProps.omit({ layer: true, pcbStyle: true,
|
|
|
18724
18732
|
expectTypesMatch(true);
|
|
18725
18733
|
|
|
18726
18734
|
// lib/components/trace-hint.ts
|
|
18727
|
-
import { distance as distance43, layer_ref as
|
|
18735
|
+
import { distance as distance43, layer_ref as layer_ref13, route_hint_point as route_hint_point6 } from "circuit-json";
|
|
18728
18736
|
import { z as z138 } from "zod";
|
|
18729
18737
|
var routeHintPointProps = z138.object({
|
|
18730
18738
|
x: distance43,
|
|
18731
18739
|
y: distance43,
|
|
18732
18740
|
via: z138.boolean().optional(),
|
|
18733
|
-
toLayer:
|
|
18741
|
+
toLayer: layer_ref13.optional()
|
|
18734
18742
|
});
|
|
18735
18743
|
var traceHintProps = z138.object({
|
|
18736
18744
|
for: z138.string().optional().describe(
|