@tscircuit/props 0.0.407 → 0.0.409
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 +80 -8
- package/dist/index.js +24 -10
- package/dist/index.js.map +1 -1
- package/lib/components/hole.ts +6 -0
- package/lib/components/panel.ts +12 -0
- package/lib/components/platedhole.ts +12 -0
- package/package.json +1 -1
package/lib/components/hole.ts
CHANGED
|
@@ -9,6 +9,7 @@ export interface CircleHoleProps extends PcbLayoutProps {
|
|
|
9
9
|
diameter?: Distance
|
|
10
10
|
radius?: Distance
|
|
11
11
|
solderMaskMargin?: Distance
|
|
12
|
+
coveredWithSolderMask?: boolean
|
|
12
13
|
}
|
|
13
14
|
|
|
14
15
|
export interface PillHoleProps extends PcbLayoutProps {
|
|
@@ -17,6 +18,7 @@ export interface PillHoleProps extends PcbLayoutProps {
|
|
|
17
18
|
width: Distance
|
|
18
19
|
height: Distance
|
|
19
20
|
solderMaskMargin?: Distance
|
|
21
|
+
coveredWithSolderMask?: boolean
|
|
20
22
|
}
|
|
21
23
|
|
|
22
24
|
export interface RectHoleProps extends PcbLayoutProps {
|
|
@@ -25,6 +27,7 @@ export interface RectHoleProps extends PcbLayoutProps {
|
|
|
25
27
|
width: Distance
|
|
26
28
|
height: Distance
|
|
27
29
|
solderMaskMargin?: Distance
|
|
30
|
+
coveredWithSolderMask?: boolean
|
|
28
31
|
}
|
|
29
32
|
|
|
30
33
|
export type HoleProps = CircleHoleProps | PillHoleProps | RectHoleProps
|
|
@@ -36,6 +39,7 @@ const circleHoleProps = pcbLayoutProps
|
|
|
36
39
|
diameter: distance.optional(),
|
|
37
40
|
radius: distance.optional(),
|
|
38
41
|
solderMaskMargin: distance.optional(),
|
|
42
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
39
43
|
})
|
|
40
44
|
.transform((d) => ({
|
|
41
45
|
...d,
|
|
@@ -49,6 +53,7 @@ const pillHoleProps = pcbLayoutProps.extend({
|
|
|
49
53
|
width: distance,
|
|
50
54
|
height: distance,
|
|
51
55
|
solderMaskMargin: distance.optional(),
|
|
56
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
52
57
|
})
|
|
53
58
|
|
|
54
59
|
const rectHoleProps = pcbLayoutProps.extend({
|
|
@@ -57,6 +62,7 @@ const rectHoleProps = pcbLayoutProps.extend({
|
|
|
57
62
|
width: distance,
|
|
58
63
|
height: distance,
|
|
59
64
|
solderMaskMargin: distance.optional(),
|
|
65
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
60
66
|
})
|
|
61
67
|
|
|
62
68
|
export const holeProps = z.union([
|
package/lib/components/panel.ts
CHANGED
|
@@ -11,6 +11,13 @@ export interface PanelProps extends BaseGroupProps {
|
|
|
11
11
|
* If true, prevent a solder mask from being applied to this panel.
|
|
12
12
|
*/
|
|
13
13
|
noSolderMask?: boolean
|
|
14
|
+
/** Method for panelization */
|
|
15
|
+
panelizationMethod?: "tab-routing" | "none"
|
|
16
|
+
/** Gap between boards in a panel */
|
|
17
|
+
boardGap?: Distance
|
|
18
|
+
tabWidth?: Distance
|
|
19
|
+
tabLength?: Distance
|
|
20
|
+
mouseBites?: boolean
|
|
14
21
|
}
|
|
15
22
|
|
|
16
23
|
export const panelProps = baseGroupProps
|
|
@@ -24,6 +31,11 @@ export const panelProps = baseGroupProps
|
|
|
24
31
|
height: distance,
|
|
25
32
|
children: z.any().optional(),
|
|
26
33
|
noSolderMask: z.boolean().optional(),
|
|
34
|
+
panelizationMethod: z.enum(["tab-routing", "none"]).optional(),
|
|
35
|
+
boardGap: distance.optional(),
|
|
36
|
+
tabWidth: distance.optional(),
|
|
37
|
+
tabLength: distance.optional(),
|
|
38
|
+
mouseBites: z.boolean().optional(),
|
|
27
39
|
})
|
|
28
40
|
|
|
29
41
|
type InferredPanelProps = z.input<typeof panelProps>
|
|
@@ -16,6 +16,7 @@ export interface CirclePlatedHoleProps
|
|
|
16
16
|
outerDiameter: number | string
|
|
17
17
|
portHints?: PortHints
|
|
18
18
|
solderMaskMargin?: Distance
|
|
19
|
+
coveredWithSolderMask?: boolean
|
|
19
20
|
}
|
|
20
21
|
|
|
21
22
|
export interface OvalPlatedHoleProps extends Omit<PcbLayoutProps, "layer"> {
|
|
@@ -33,6 +34,7 @@ export interface OvalPlatedHoleProps extends Omit<PcbLayoutProps, "layer"> {
|
|
|
33
34
|
innerWidth?: number | string
|
|
34
35
|
/** @deprecated use holeHeight */
|
|
35
36
|
innerHeight?: number | string
|
|
37
|
+
coveredWithSolderMask?: boolean
|
|
36
38
|
}
|
|
37
39
|
|
|
38
40
|
export interface PillPlatedHoleProps extends Omit<PcbLayoutProps, "layer"> {
|
|
@@ -54,6 +56,7 @@ export interface PillPlatedHoleProps extends Omit<PcbLayoutProps, "layer"> {
|
|
|
54
56
|
|
|
55
57
|
portHints?: PortHints
|
|
56
58
|
solderMaskMargin?: Distance
|
|
59
|
+
coveredWithSolderMask?: boolean
|
|
57
60
|
}
|
|
58
61
|
|
|
59
62
|
export interface CircularHoleWithRectPlatedProps
|
|
@@ -71,6 +74,7 @@ export interface CircularHoleWithRectPlatedProps
|
|
|
71
74
|
holeOffsetX?: number | string
|
|
72
75
|
holeOffsetY?: number | string
|
|
73
76
|
solderMaskMargin?: Distance
|
|
77
|
+
coveredWithSolderMask?: boolean
|
|
74
78
|
}
|
|
75
79
|
|
|
76
80
|
export interface PillWithRectPadPlatedHoleProps
|
|
@@ -88,6 +92,7 @@ export interface PillWithRectPadPlatedHoleProps
|
|
|
88
92
|
holeOffsetX?: number | string
|
|
89
93
|
holeOffsetY?: number | string
|
|
90
94
|
solderMaskMargin?: Distance
|
|
95
|
+
coveredWithSolderMask?: boolean
|
|
91
96
|
}
|
|
92
97
|
|
|
93
98
|
export interface HoleWithPolygonPadPlatedHoleProps
|
|
@@ -104,6 +109,7 @@ export interface HoleWithPolygonPadPlatedHoleProps
|
|
|
104
109
|
holeOffsetY: number | string
|
|
105
110
|
portHints?: PortHints
|
|
106
111
|
solderMaskMargin?: Distance
|
|
112
|
+
coveredWithSolderMask?: boolean
|
|
107
113
|
}
|
|
108
114
|
|
|
109
115
|
export type PlatedHoleProps =
|
|
@@ -131,6 +137,7 @@ export const platedHoleProps = z
|
|
|
131
137
|
outerDiameter: distance,
|
|
132
138
|
portHints: portHints.optional(),
|
|
133
139
|
solderMaskMargin: distance.optional(),
|
|
140
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
134
141
|
}),
|
|
135
142
|
pcbLayoutProps.omit({ layer: true }).extend({
|
|
136
143
|
name: z.string().optional(),
|
|
@@ -144,6 +151,7 @@ export const platedHoleProps = z
|
|
|
144
151
|
innerHeight: distance.optional().describe("DEPRECATED use holeHeight"),
|
|
145
152
|
portHints: portHints.optional(),
|
|
146
153
|
solderMaskMargin: distance.optional(),
|
|
154
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
147
155
|
}),
|
|
148
156
|
pcbLayoutProps.omit({ layer: true }).extend({
|
|
149
157
|
name: z.string().optional(),
|
|
@@ -160,6 +168,7 @@ export const platedHoleProps = z
|
|
|
160
168
|
holeOffsetX: distance.optional(),
|
|
161
169
|
holeOffsetY: distance.optional(),
|
|
162
170
|
solderMaskMargin: distance.optional(),
|
|
171
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
163
172
|
}),
|
|
164
173
|
pcbLayoutProps.omit({ pcbRotation: true, layer: true }).extend({
|
|
165
174
|
name: z.string().optional(),
|
|
@@ -175,6 +184,7 @@ export const platedHoleProps = z
|
|
|
175
184
|
holeOffsetX: distance.optional(),
|
|
176
185
|
holeOffsetY: distance.optional(),
|
|
177
186
|
solderMaskMargin: distance.optional(),
|
|
187
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
178
188
|
}),
|
|
179
189
|
pcbLayoutProps.omit({ pcbRotation: true, layer: true }).extend({
|
|
180
190
|
name: z.string().optional(),
|
|
@@ -190,6 +200,7 @@ export const platedHoleProps = z
|
|
|
190
200
|
holeOffsetX: distance.optional(),
|
|
191
201
|
holeOffsetY: distance.optional(),
|
|
192
202
|
solderMaskMargin: distance.optional(),
|
|
203
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
193
204
|
}),
|
|
194
205
|
pcbLayoutProps.omit({ pcbRotation: true, layer: true }).extend({
|
|
195
206
|
name: z.string().optional(),
|
|
@@ -204,6 +215,7 @@ export const platedHoleProps = z
|
|
|
204
215
|
holeOffsetY: distance,
|
|
205
216
|
portHints: portHints.optional(),
|
|
206
217
|
solderMaskMargin: distance.optional(),
|
|
218
|
+
coveredWithSolderMask: z.boolean().optional(),
|
|
207
219
|
}),
|
|
208
220
|
])
|
|
209
221
|
.refine((a) => {
|