@tscircuit/props 0.0.630 → 0.0.632

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.
@@ -22,8 +22,17 @@ export interface BreakoutProps
22
22
  paddingRight?: Distance
23
23
  paddingTop?: Distance
24
24
  paddingBottom?: Distance
25
+ /**
26
+ * Minimum clearance between this fanout boundary and another fanout
27
+ * boundary. Fanout boundaries may never overlap, even when this is omitted.
28
+ */
29
+ fanoutMargin?: Distance
25
30
  }
26
31
 
32
+ const nonnegativeFanoutMargin = distance.refine((value) => value >= 0, {
33
+ message: "Fanout margin cannot be negative",
34
+ })
35
+
27
36
  export const breakoutProps = subcircuitGroupProps.extend({
28
37
  autorouter: autorouterProp.default("fanout"),
29
38
  padding: distance.optional(),
@@ -31,6 +40,7 @@ export const breakoutProps = subcircuitGroupProps.extend({
31
40
  paddingRight: distance.optional(),
32
41
  paddingTop: distance.optional(),
33
42
  paddingBottom: distance.optional(),
43
+ fanoutMargin: nonnegativeFanoutMargin.optional(),
34
44
  ...fanoutProps.shape,
35
45
  })
36
46
 
@@ -1,3 +1,4 @@
1
+ import { distance } from "circuit-json"
1
2
  import { direction } from "lib/common/direction"
2
3
  import { commonLayoutProps } from "lib/common/layout"
3
4
  import { kicadPinMetadata } from "lib/common/kicadPinMetadata"
@@ -7,6 +8,14 @@ export const portProps = commonLayoutProps.extend({
7
8
  name: z.string().optional(),
8
9
  pinNumber: z.number().optional(),
9
10
  schStemLength: z.number().optional(),
11
+ schPinLabelFontSize: z
12
+ .enum(["default", "sm"])
13
+ .or(
14
+ distance.refine((value) => Number.isFinite(value) && value > 0, {
15
+ message: "Schematic pin-label font size must be positive and finite",
16
+ }),
17
+ )
18
+ .optional(),
10
19
  aliases: z.array(z.string()).optional(),
11
20
  layer: z.string().optional(),
12
21
  layers: z.array(z.string()).optional(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tscircuit/props",
3
- "version": "0.0.630",
3
+ "version": "0.0.632",
4
4
  "description": "Props for tscircuit builtin component types",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",