@tscircuit/props 0.0.641 → 0.0.643
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 +7 -1
- package/dist/index.d.ts +8 -3
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/lib/components/bus.ts +3 -3
- package/lib/platformConfig.ts +6 -0
- package/lib/projectConfig.ts +2 -0
- package/package.json +1 -1
package/lib/components/bus.ts
CHANGED
|
@@ -10,12 +10,12 @@ import { z } from "zod"
|
|
|
10
10
|
export type BusName = string
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
|
-
* Declares
|
|
13
|
+
* Declares one or more connections that an autorouter should route as a group.
|
|
14
14
|
* Each connection may be a trace name or a port selector.
|
|
15
15
|
*/
|
|
16
16
|
export interface BusProps {
|
|
17
17
|
name?: string
|
|
18
|
-
/**
|
|
18
|
+
/** One or more trace names or port selectors for the connections in the bus. */
|
|
19
19
|
connections: string[]
|
|
20
20
|
/** If set, every trace in this bus is assigned to this autorouting phase. */
|
|
21
21
|
routingPhaseIndex?: number | null
|
|
@@ -35,7 +35,7 @@ export interface BusProps {
|
|
|
35
35
|
|
|
36
36
|
export const busProps = z.object({
|
|
37
37
|
name: z.string().optional(),
|
|
38
|
-
connections: z.array(z.string()).min(
|
|
38
|
+
connections: z.array(z.string()).min(1),
|
|
39
39
|
routingPhaseIndex: z.number().nullable().optional(),
|
|
40
40
|
maxLengthSkew: distance.pipe(z.number().min(0).finite()).optional(),
|
|
41
41
|
targetImpedance: resistance.pipe(z.number().positive().finite()).optional(),
|
package/lib/platformConfig.ts
CHANGED
|
@@ -113,6 +113,11 @@ export interface PlatformConfig {
|
|
|
113
113
|
routingDisabled?: boolean
|
|
114
114
|
schematicDisabled?: boolean
|
|
115
115
|
partsEngineDisabled?: boolean
|
|
116
|
+
/**
|
|
117
|
+
* Disables analog simulation model processing and simulator execution.
|
|
118
|
+
* Defaults to false.
|
|
119
|
+
*/
|
|
120
|
+
analogSimulationDisabled?: boolean
|
|
116
121
|
drcChecksDisabled?: boolean
|
|
117
122
|
netlistDrcChecksDisabled?: boolean
|
|
118
123
|
routingDrcChecksDisabled?: boolean
|
|
@@ -266,6 +271,7 @@ export const platformConfig = z.object({
|
|
|
266
271
|
routingDisabled: z.boolean().optional(),
|
|
267
272
|
schematicDisabled: z.boolean().optional(),
|
|
268
273
|
partsEngineDisabled: z.boolean().optional(),
|
|
274
|
+
analogSimulationDisabled: z.boolean().optional(),
|
|
269
275
|
drcChecksDisabled: z.boolean().optional(),
|
|
270
276
|
netlistDrcChecksDisabled: z.boolean().optional(),
|
|
271
277
|
routingDrcChecksDisabled: z.boolean().optional(),
|
package/lib/projectConfig.ts
CHANGED
|
@@ -15,6 +15,7 @@ export interface ProjectConfig
|
|
|
15
15
|
| "defaultSpiceEngine"
|
|
16
16
|
| "pcbDisabled"
|
|
17
17
|
| "schematicDisabled"
|
|
18
|
+
| "analogSimulationDisabled"
|
|
18
19
|
> {}
|
|
19
20
|
|
|
20
21
|
const platformConfigObject = platformConfig as z.ZodObject<any>
|
|
@@ -30,6 +31,7 @@ export const projectConfig = platformConfigObject.pick({
|
|
|
30
31
|
defaultSpiceEngine: true,
|
|
31
32
|
pcbDisabled: true,
|
|
32
33
|
schematicDisabled: true,
|
|
34
|
+
analogSimulationDisabled: true,
|
|
33
35
|
}) as z.ZodType<ProjectConfig>
|
|
34
36
|
|
|
35
37
|
expectTypesMatch<ProjectConfig, z.infer<typeof projectConfig>>(true)
|