@tscircuit/props 0.0.598 → 0.0.599

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.
@@ -1,5 +1,6 @@
1
1
  import { expectTypesMatch } from "lib/typecheck"
2
2
  import { z } from "zod"
3
+ import { layer_ref, type LayerRef, type LayerRefInput } from "circuit-json"
3
4
  import {
4
5
  type FanoutBoundaryPadding,
5
6
  fanoutBoundaryPadding,
@@ -22,6 +23,10 @@ export type BusFanoutDirection =
22
23
  direction: NinePointAnchor
23
24
  }
24
25
 
26
+ export type FanoutPourNetMap = Partial<
27
+ Record<Extract<LayerRef, string>, string | string[]>
28
+ >
29
+
25
30
  export interface AutoroutingPhaseProps extends RoutingTolerances {
26
31
  key?: any
27
32
  name?: string
@@ -47,6 +52,20 @@ export interface AutoroutingPhaseProps extends RoutingTolerances {
47
52
  * boundary where fanout traces terminate.
48
53
  */
49
54
  fanoutBoundaryPadding?: FanoutBoundaryPadding
55
+ /**
56
+ * Copper layers available to boundary-terminated fanout buses. Source-only
57
+ * traces whose nets are mapped by `fanoutPourNetMap` terminate on their
58
+ * mapped plane layer.
59
+ */
60
+ fanoutRoutingLayers?: LayerRefInput[]
61
+ /**
62
+ * Maps copper layers to the net or nets poured on them. During fanout,
63
+ * source-only traces on those nets drop to the mapped layer instead of
64
+ * routing to the breakout boundary.
65
+ *
66
+ * This is inferred from `<copperpour>` components when omitted.
67
+ */
68
+ fanoutPourNetMap?: FanoutPourNetMap
50
69
  }
51
70
 
52
71
  const busFanoutDirection = z.union([
@@ -75,6 +94,10 @@ export const autoroutingPhaseProps = z
75
94
  reroute: z.boolean().optional(),
76
95
  busFanoutDirections: z.record(busFanoutDirection).optional(),
77
96
  fanoutBoundaryPadding: fanoutBoundaryPadding.optional(),
97
+ fanoutRoutingLayers: z.array(layer_ref).min(1).optional(),
98
+ fanoutPourNetMap: z
99
+ .record(layer_ref, z.union([z.string(), z.array(z.string()).min(1)]))
100
+ .optional(),
78
101
  })
79
102
  .superRefine((value, ctx) => {
80
103
  if (
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tscircuit/props",
3
- "version": "0.0.598",
3
+ "version": "0.0.599",
4
4
  "description": "Props for tscircuit builtin component types",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",