@tscircuit/props 0.0.568 → 0.0.570

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 CHANGED
@@ -248,6 +248,7 @@ export interface AnalogSimulationProps {
248
248
  ```ts
249
249
  export interface AutoroutingPhaseProps extends RoutingTolerances {
250
250
  key?: any;
251
+ name?: string;
251
252
  autorouter?: AutorouterProp;
252
253
  phaseIndex?: number;
253
254
  region?: {
@@ -1030,6 +1031,7 @@ export interface MosfetProps<
1030
1031
  > extends CommonComponentProps<PinLabel> {
1031
1032
  channelType: "n" | "p";
1032
1033
  mosfetMode: "enhancement" | "depletion";
1034
+ connections?: Connections<MosfetPinLabels>;
1033
1035
  }
1034
1036
  ```
1035
1037
 
package/dist/index.d.ts CHANGED
@@ -122000,6 +122000,7 @@ declare const analogSimulationProps: z.ZodObject<{
122000
122000
 
122001
122001
  interface AutoroutingPhaseProps extends RoutingTolerances {
122002
122002
  key?: any;
122003
+ name?: string;
122003
122004
  autorouter?: AutorouterProp;
122004
122005
  phaseIndex?: number;
122005
122006
  region?: {
@@ -122046,10 +122047,12 @@ declare const autoroutingPhaseProps: z.ZodEffects<z.ZodObject<{
122046
122047
  minViaHoleDiameter: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
122047
122048
  minViaPadDiameter: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
122048
122049
  key: z.ZodOptional<z.ZodAny>;
122050
+ name: z.ZodOptional<z.ZodString>;
122049
122051
  autorouter: z.ZodOptional<z.ZodType<AutorouterProp, z.ZodTypeDef, AutorouterProp>>;
122050
122052
  phaseIndex: z.ZodOptional<z.ZodNumber>;
122051
122053
  }, "strip", z.ZodTypeAny, {
122052
122054
  key?: any;
122055
+ name?: string | undefined;
122053
122056
  connections?: string[] | undefined;
122054
122057
  minTraceWidth?: number | undefined;
122055
122058
  minViaHoleEdgeToViaHoleEdgeClearance?: number | undefined;
@@ -122073,6 +122076,7 @@ declare const autoroutingPhaseProps: z.ZodEffects<z.ZodObject<{
122073
122076
  reroute?: boolean | undefined;
122074
122077
  }, {
122075
122078
  key?: any;
122079
+ name?: string | undefined;
122076
122080
  connections?: string[] | undefined;
122077
122081
  minTraceWidth?: string | number | undefined;
122078
122082
  minViaHoleEdgeToViaHoleEdgeClearance?: string | number | undefined;
@@ -122096,6 +122100,7 @@ declare const autoroutingPhaseProps: z.ZodEffects<z.ZodObject<{
122096
122100
  reroute?: boolean | undefined;
122097
122101
  }>, {
122098
122102
  key?: any;
122103
+ name?: string | undefined;
122099
122104
  connections?: string[] | undefined;
122100
122105
  minTraceWidth?: number | undefined;
122101
122106
  minViaHoleEdgeToViaHoleEdgeClearance?: number | undefined;
@@ -122119,6 +122124,7 @@ declare const autoroutingPhaseProps: z.ZodEffects<z.ZodObject<{
122119
122124
  reroute?: boolean | undefined;
122120
122125
  }, {
122121
122126
  key?: any;
122127
+ name?: string | undefined;
122122
122128
  connections?: string[] | undefined;
122123
122129
  minTraceWidth?: string | number | undefined;
122124
122130
  minViaHoleEdgeToViaHoleEdgeClearance?: string | number | undefined;
@@ -126676,9 +126682,12 @@ declare const transistorProps: z.ZodObject<{
126676
126682
  declare const transistorPins: readonly ["pin1", "emitter", "pin2", "collector", "pin3", "base"];
126677
126683
  type TransistorPinLabels = (typeof transistorPins)[number];
126678
126684
 
126685
+ declare const mosfetPins: readonly ["pin1", "drain", "pin2", "source", "pin3", "gate"];
126686
+ type MosfetPinLabels = (typeof mosfetPins)[number];
126679
126687
  interface MosfetProps<PinLabel extends string = string> extends CommonComponentProps<PinLabel> {
126680
126688
  channelType: "n" | "p";
126681
126689
  mosfetMode: "enhancement" | "depletion";
126690
+ connections?: Connections<MosfetPinLabels>;
126682
126691
  }
126683
126692
  declare const mosfetProps: z.ZodObject<{
126684
126693
  pcbX: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>]>>;
@@ -130042,6 +130051,7 @@ declare const mosfetProps: z.ZodObject<{
130042
130051
  } & {
130043
130052
  channelType: z.ZodEnum<["n", "p"]>;
130044
130053
  mosfetMode: z.ZodEnum<["enhancement", "depletion"]>;
130054
+ connections: z.ZodOptional<z.ZodRecord<z.ZodEnum<["pin1", "drain", "pin2", "source", "pin3", "gate"]>, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodReadonly<z.ZodArray<z.ZodString, "many">>]>, z.ZodArray<z.ZodString, "many">]>>>;
130045
130055
  }, "strip", z.ZodTypeAny, {
130046
130056
  name: string;
130047
130057
  channelType: "n" | "p";
@@ -130622,6 +130632,7 @@ declare const mosfetProps: z.ZodObject<{
130622
130632
  manufacturerPartNumber?: string | undefined;
130623
130633
  schSectionName?: string | undefined;
130624
130634
  schSheetName?: string | undefined;
130635
+ connections?: Partial<Record<"pin1" | "pin2" | "source" | "pin3" | "gate" | "drain", string | readonly string[] | string[]>> | undefined;
130625
130636
  }, {
130626
130637
  name: string;
130627
130638
  channelType: "n" | "p";
@@ -131204,9 +131215,8 @@ declare const mosfetProps: z.ZodObject<{
131204
131215
  manufacturerPartNumber?: string | undefined;
131205
131216
  schSectionName?: string | undefined;
131206
131217
  schSheetName?: string | undefined;
131218
+ connections?: Partial<Record<"pin1" | "pin2" | "source" | "pin3" | "gate" | "drain", string | readonly string[] | string[]>> | undefined;
131207
131219
  }>;
131208
- declare const mosfetPins: readonly ["pin1", "drain", "pin2", "source", "pin3", "gate"];
131209
- type MosfetPinLabels = (typeof mosfetPins)[number];
131210
131220
 
131211
131221
  declare const opampPinLabels: readonly ["inverting_input", "non_inverting_input", "output", "positive_supply", "negative_supply"];
131212
131222
  /**
package/dist/index.js CHANGED
@@ -17426,6 +17426,7 @@ expectTypesMatch(
17426
17426
  import { z as z75 } from "zod";
17427
17427
  var autoroutingPhaseProps = z75.object({
17428
17428
  key: z75.any().optional(),
17429
+ name: z75.string().optional(),
17429
17430
  autorouter: autorouterProp.optional(),
17430
17431
  phaseIndex: z75.number().optional(),
17431
17432
  ...routingTolerances.shape,
@@ -17487,10 +17488,6 @@ expectTypesMatch(true);
17487
17488
 
17488
17489
  // lib/components/mosfet.ts
17489
17490
  import { z as z78 } from "zod";
17490
- var mosfetProps = commonComponentProps.extend({
17491
- channelType: z78.enum(["n", "p"]),
17492
- mosfetMode: z78.enum(["enhancement", "depletion"])
17493
- });
17494
17491
  var mosfetPins = [
17495
17492
  "pin1",
17496
17493
  "drain",
@@ -17499,6 +17496,11 @@ var mosfetPins = [
17499
17496
  "pin3",
17500
17497
  "gate"
17501
17498
  ];
17499
+ var mosfetProps = commonComponentProps.extend({
17500
+ channelType: z78.enum(["n", "p"]),
17501
+ mosfetMode: z78.enum(["enhancement", "depletion"]),
17502
+ connections: createConnectionsProp(mosfetPins).optional()
17503
+ });
17502
17504
  expectTypesMatch(true);
17503
17505
 
17504
17506
  // lib/components/opamp.ts