@tscircuit/core 0.0.1473 → 0.0.1475
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 +301 -0
- package/dist/index.js +64 -42
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -152814,6 +152814,133 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152814
152814
|
get config(): {
|
|
152815
152815
|
componentName: string;
|
|
152816
152816
|
zodProps: zod.ZodEffects<zod.ZodEffects<zod.ZodObject<{
|
|
152817
|
+
name: zod.ZodOptional<zod.ZodString>;
|
|
152818
|
+
chipRef: zod.ZodOptional<zod.ZodString>;
|
|
152819
|
+
pinLabels: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodUnion<[zod.ZodUnion<[zod.ZodString, zod.ZodReadonly<zod.ZodArray<zod.ZodString, "many">>]>, zod.ZodArray<zod.ZodString, "many">]>>>;
|
|
152820
|
+
schPinArrangement: zod.ZodOptional<zod.ZodObject<{
|
|
152821
|
+
leftSize: zod.ZodOptional<zod.ZodNumber>;
|
|
152822
|
+
topSize: zod.ZodOptional<zod.ZodNumber>;
|
|
152823
|
+
rightSize: zod.ZodOptional<zod.ZodNumber>;
|
|
152824
|
+
bottomSize: zod.ZodOptional<zod.ZodNumber>;
|
|
152825
|
+
leftPinCount: zod.ZodOptional<zod.ZodNumber>;
|
|
152826
|
+
rightPinCount: zod.ZodOptional<zod.ZodNumber>;
|
|
152827
|
+
topPinCount: zod.ZodOptional<zod.ZodNumber>;
|
|
152828
|
+
bottomPinCount: zod.ZodOptional<zod.ZodNumber>;
|
|
152829
|
+
leftSide: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodObject<{
|
|
152830
|
+
pins: zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">;
|
|
152831
|
+
direction: zod.ZodUnion<[zod.ZodLiteral<"top-to-bottom">, zod.ZodLiteral<"left-to-right">, zod.ZodLiteral<"bottom-to-top">, zod.ZodLiteral<"right-to-left">]>;
|
|
152832
|
+
}, "strip", zod.ZodTypeAny, {
|
|
152833
|
+
pins: (string | number)[];
|
|
152834
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152835
|
+
}, {
|
|
152836
|
+
pins: (string | number)[];
|
|
152837
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152838
|
+
}>, zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">]>, {
|
|
152839
|
+
pins: (string | number)[];
|
|
152840
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152841
|
+
}, (string | number)[] | {
|
|
152842
|
+
pins: (string | number)[];
|
|
152843
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152844
|
+
}>>;
|
|
152845
|
+
rightSide: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodObject<{
|
|
152846
|
+
pins: zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">;
|
|
152847
|
+
direction: zod.ZodUnion<[zod.ZodLiteral<"top-to-bottom">, zod.ZodLiteral<"left-to-right">, zod.ZodLiteral<"bottom-to-top">, zod.ZodLiteral<"right-to-left">]>;
|
|
152848
|
+
}, "strip", zod.ZodTypeAny, {
|
|
152849
|
+
pins: (string | number)[];
|
|
152850
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152851
|
+
}, {
|
|
152852
|
+
pins: (string | number)[];
|
|
152853
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152854
|
+
}>, zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">]>, {
|
|
152855
|
+
pins: (string | number)[];
|
|
152856
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152857
|
+
}, (string | number)[] | {
|
|
152858
|
+
pins: (string | number)[];
|
|
152859
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152860
|
+
}>>;
|
|
152861
|
+
topSide: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodObject<{
|
|
152862
|
+
pins: zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">;
|
|
152863
|
+
direction: zod.ZodUnion<[zod.ZodLiteral<"top-to-bottom">, zod.ZodLiteral<"left-to-right">, zod.ZodLiteral<"bottom-to-top">, zod.ZodLiteral<"right-to-left">]>;
|
|
152864
|
+
}, "strip", zod.ZodTypeAny, {
|
|
152865
|
+
pins: (string | number)[];
|
|
152866
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152867
|
+
}, {
|
|
152868
|
+
pins: (string | number)[];
|
|
152869
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152870
|
+
}>, zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">]>, {
|
|
152871
|
+
pins: (string | number)[];
|
|
152872
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152873
|
+
}, (string | number)[] | {
|
|
152874
|
+
pins: (string | number)[];
|
|
152875
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152876
|
+
}>>;
|
|
152877
|
+
bottomSide: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodObject<{
|
|
152878
|
+
pins: zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">;
|
|
152879
|
+
direction: zod.ZodUnion<[zod.ZodLiteral<"top-to-bottom">, zod.ZodLiteral<"left-to-right">, zod.ZodLiteral<"bottom-to-top">, zod.ZodLiteral<"right-to-left">]>;
|
|
152880
|
+
}, "strip", zod.ZodTypeAny, {
|
|
152881
|
+
pins: (string | number)[];
|
|
152882
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152883
|
+
}, {
|
|
152884
|
+
pins: (string | number)[];
|
|
152885
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152886
|
+
}>, zod.ZodArray<zod.ZodUnion<[zod.ZodNumber, zod.ZodString]>, "many">]>, {
|
|
152887
|
+
pins: (string | number)[];
|
|
152888
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152889
|
+
}, (string | number)[] | {
|
|
152890
|
+
pins: (string | number)[];
|
|
152891
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152892
|
+
}>>;
|
|
152893
|
+
}, "strip", zod.ZodTypeAny, {
|
|
152894
|
+
leftSize?: number | undefined;
|
|
152895
|
+
topSize?: number | undefined;
|
|
152896
|
+
rightSize?: number | undefined;
|
|
152897
|
+
bottomSize?: number | undefined;
|
|
152898
|
+
leftSide?: {
|
|
152899
|
+
pins: (string | number)[];
|
|
152900
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152901
|
+
} | undefined;
|
|
152902
|
+
topSide?: {
|
|
152903
|
+
pins: (string | number)[];
|
|
152904
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152905
|
+
} | undefined;
|
|
152906
|
+
rightSide?: {
|
|
152907
|
+
pins: (string | number)[];
|
|
152908
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152909
|
+
} | undefined;
|
|
152910
|
+
bottomSide?: {
|
|
152911
|
+
pins: (string | number)[];
|
|
152912
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152913
|
+
} | undefined;
|
|
152914
|
+
leftPinCount?: number | undefined;
|
|
152915
|
+
rightPinCount?: number | undefined;
|
|
152916
|
+
topPinCount?: number | undefined;
|
|
152917
|
+
bottomPinCount?: number | undefined;
|
|
152918
|
+
}, {
|
|
152919
|
+
leftSize?: number | undefined;
|
|
152920
|
+
topSize?: number | undefined;
|
|
152921
|
+
rightSize?: number | undefined;
|
|
152922
|
+
bottomSize?: number | undefined;
|
|
152923
|
+
leftSide?: (string | number)[] | {
|
|
152924
|
+
pins: (string | number)[];
|
|
152925
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152926
|
+
} | undefined;
|
|
152927
|
+
topSide?: (string | number)[] | {
|
|
152928
|
+
pins: (string | number)[];
|
|
152929
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152930
|
+
} | undefined;
|
|
152931
|
+
rightSide?: (string | number)[] | {
|
|
152932
|
+
pins: (string | number)[];
|
|
152933
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152934
|
+
} | undefined;
|
|
152935
|
+
bottomSide?: (string | number)[] | {
|
|
152936
|
+
pins: (string | number)[];
|
|
152937
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152938
|
+
} | undefined;
|
|
152939
|
+
leftPinCount?: number | undefined;
|
|
152940
|
+
rightPinCount?: number | undefined;
|
|
152941
|
+
topPinCount?: number | undefined;
|
|
152942
|
+
bottomPinCount?: number | undefined;
|
|
152943
|
+
}>>;
|
|
152817
152944
|
schX: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
152818
152945
|
schY: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
152819
152946
|
width: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
@@ -152836,6 +152963,7 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152836
152963
|
strokeStyle: "dashed" | "solid";
|
|
152837
152964
|
width?: number | undefined;
|
|
152838
152965
|
height?: number | undefined;
|
|
152966
|
+
name?: string | undefined;
|
|
152839
152967
|
schX?: number | undefined;
|
|
152840
152968
|
schY?: number | undefined;
|
|
152841
152969
|
padding?: number | undefined;
|
|
@@ -152843,13 +152971,42 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152843
152971
|
paddingRight?: number | undefined;
|
|
152844
152972
|
paddingTop?: number | undefined;
|
|
152845
152973
|
paddingBottom?: number | undefined;
|
|
152974
|
+
schPinArrangement?: {
|
|
152975
|
+
leftSize?: number | undefined;
|
|
152976
|
+
topSize?: number | undefined;
|
|
152977
|
+
rightSize?: number | undefined;
|
|
152978
|
+
bottomSize?: number | undefined;
|
|
152979
|
+
leftSide?: {
|
|
152980
|
+
pins: (string | number)[];
|
|
152981
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152982
|
+
} | undefined;
|
|
152983
|
+
topSide?: {
|
|
152984
|
+
pins: (string | number)[];
|
|
152985
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152986
|
+
} | undefined;
|
|
152987
|
+
rightSide?: {
|
|
152988
|
+
pins: (string | number)[];
|
|
152989
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152990
|
+
} | undefined;
|
|
152991
|
+
bottomSide?: {
|
|
152992
|
+
pins: (string | number)[];
|
|
152993
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
152994
|
+
} | undefined;
|
|
152995
|
+
leftPinCount?: number | undefined;
|
|
152996
|
+
rightPinCount?: number | undefined;
|
|
152997
|
+
topPinCount?: number | undefined;
|
|
152998
|
+
bottomPinCount?: number | undefined;
|
|
152999
|
+
} | undefined;
|
|
152846
153000
|
title?: string | undefined;
|
|
153001
|
+
pinLabels?: Record<string, string | readonly string[] | string[]> | undefined;
|
|
153002
|
+
chipRef?: string | undefined;
|
|
152847
153003
|
overlay?: string[] | undefined;
|
|
152848
153004
|
titleColor?: string | undefined;
|
|
152849
153005
|
titleFontSize?: number | undefined;
|
|
152850
153006
|
}, {
|
|
152851
153007
|
width?: string | number | undefined;
|
|
152852
153008
|
height?: string | number | undefined;
|
|
153009
|
+
name?: string | undefined;
|
|
152853
153010
|
schX?: string | number | undefined;
|
|
152854
153011
|
schY?: string | number | undefined;
|
|
152855
153012
|
padding?: string | number | undefined;
|
|
@@ -152857,7 +153014,35 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152857
153014
|
paddingRight?: string | number | undefined;
|
|
152858
153015
|
paddingTop?: string | number | undefined;
|
|
152859
153016
|
paddingBottom?: string | number | undefined;
|
|
153017
|
+
schPinArrangement?: {
|
|
153018
|
+
leftSize?: number | undefined;
|
|
153019
|
+
topSize?: number | undefined;
|
|
153020
|
+
rightSize?: number | undefined;
|
|
153021
|
+
bottomSize?: number | undefined;
|
|
153022
|
+
leftSide?: (string | number)[] | {
|
|
153023
|
+
pins: (string | number)[];
|
|
153024
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153025
|
+
} | undefined;
|
|
153026
|
+
topSide?: (string | number)[] | {
|
|
153027
|
+
pins: (string | number)[];
|
|
153028
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153029
|
+
} | undefined;
|
|
153030
|
+
rightSide?: (string | number)[] | {
|
|
153031
|
+
pins: (string | number)[];
|
|
153032
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153033
|
+
} | undefined;
|
|
153034
|
+
bottomSide?: (string | number)[] | {
|
|
153035
|
+
pins: (string | number)[];
|
|
153036
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153037
|
+
} | undefined;
|
|
153038
|
+
leftPinCount?: number | undefined;
|
|
153039
|
+
rightPinCount?: number | undefined;
|
|
153040
|
+
topPinCount?: number | undefined;
|
|
153041
|
+
bottomPinCount?: number | undefined;
|
|
153042
|
+
} | undefined;
|
|
152860
153043
|
title?: string | undefined;
|
|
153044
|
+
pinLabels?: Record<string, string | readonly string[] | string[]> | undefined;
|
|
153045
|
+
chipRef?: string | undefined;
|
|
152861
153046
|
overlay?: string[] | undefined;
|
|
152862
153047
|
titleAlignment?: "top_left" | "top_center" | "top_right" | "center_left" | "center" | "center_right" | "bottom_left" | "bottom_center" | "bottom_right" | undefined;
|
|
152863
153048
|
titleColor?: string | undefined;
|
|
@@ -152870,6 +153055,7 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152870
153055
|
strokeStyle: "dashed" | "solid";
|
|
152871
153056
|
width?: number | undefined;
|
|
152872
153057
|
height?: number | undefined;
|
|
153058
|
+
name?: string | undefined;
|
|
152873
153059
|
schX?: number | undefined;
|
|
152874
153060
|
schY?: number | undefined;
|
|
152875
153061
|
padding?: number | undefined;
|
|
@@ -152877,13 +153063,42 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152877
153063
|
paddingRight?: number | undefined;
|
|
152878
153064
|
paddingTop?: number | undefined;
|
|
152879
153065
|
paddingBottom?: number | undefined;
|
|
153066
|
+
schPinArrangement?: {
|
|
153067
|
+
leftSize?: number | undefined;
|
|
153068
|
+
topSize?: number | undefined;
|
|
153069
|
+
rightSize?: number | undefined;
|
|
153070
|
+
bottomSize?: number | undefined;
|
|
153071
|
+
leftSide?: {
|
|
153072
|
+
pins: (string | number)[];
|
|
153073
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153074
|
+
} | undefined;
|
|
153075
|
+
topSide?: {
|
|
153076
|
+
pins: (string | number)[];
|
|
153077
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153078
|
+
} | undefined;
|
|
153079
|
+
rightSide?: {
|
|
153080
|
+
pins: (string | number)[];
|
|
153081
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153082
|
+
} | undefined;
|
|
153083
|
+
bottomSide?: {
|
|
153084
|
+
pins: (string | number)[];
|
|
153085
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153086
|
+
} | undefined;
|
|
153087
|
+
leftPinCount?: number | undefined;
|
|
153088
|
+
rightPinCount?: number | undefined;
|
|
153089
|
+
topPinCount?: number | undefined;
|
|
153090
|
+
bottomPinCount?: number | undefined;
|
|
153091
|
+
} | undefined;
|
|
152880
153092
|
title?: string | undefined;
|
|
153093
|
+
pinLabels?: Record<string, string | readonly string[] | string[]> | undefined;
|
|
153094
|
+
chipRef?: string | undefined;
|
|
152881
153095
|
overlay?: string[] | undefined;
|
|
152882
153096
|
titleColor?: string | undefined;
|
|
152883
153097
|
titleFontSize?: number | undefined;
|
|
152884
153098
|
}, {
|
|
152885
153099
|
width?: string | number | undefined;
|
|
152886
153100
|
height?: string | number | undefined;
|
|
153101
|
+
name?: string | undefined;
|
|
152887
153102
|
schX?: string | number | undefined;
|
|
152888
153103
|
schY?: string | number | undefined;
|
|
152889
153104
|
padding?: string | number | undefined;
|
|
@@ -152891,7 +153106,35 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152891
153106
|
paddingRight?: string | number | undefined;
|
|
152892
153107
|
paddingTop?: string | number | undefined;
|
|
152893
153108
|
paddingBottom?: string | number | undefined;
|
|
153109
|
+
schPinArrangement?: {
|
|
153110
|
+
leftSize?: number | undefined;
|
|
153111
|
+
topSize?: number | undefined;
|
|
153112
|
+
rightSize?: number | undefined;
|
|
153113
|
+
bottomSize?: number | undefined;
|
|
153114
|
+
leftSide?: (string | number)[] | {
|
|
153115
|
+
pins: (string | number)[];
|
|
153116
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153117
|
+
} | undefined;
|
|
153118
|
+
topSide?: (string | number)[] | {
|
|
153119
|
+
pins: (string | number)[];
|
|
153120
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153121
|
+
} | undefined;
|
|
153122
|
+
rightSide?: (string | number)[] | {
|
|
153123
|
+
pins: (string | number)[];
|
|
153124
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153125
|
+
} | undefined;
|
|
153126
|
+
bottomSide?: (string | number)[] | {
|
|
153127
|
+
pins: (string | number)[];
|
|
153128
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153129
|
+
} | undefined;
|
|
153130
|
+
leftPinCount?: number | undefined;
|
|
153131
|
+
rightPinCount?: number | undefined;
|
|
153132
|
+
topPinCount?: number | undefined;
|
|
153133
|
+
bottomPinCount?: number | undefined;
|
|
153134
|
+
} | undefined;
|
|
152894
153135
|
title?: string | undefined;
|
|
153136
|
+
pinLabels?: Record<string, string | readonly string[] | string[]> | undefined;
|
|
153137
|
+
chipRef?: string | undefined;
|
|
152895
153138
|
overlay?: string[] | undefined;
|
|
152896
153139
|
titleAlignment?: "top_left" | "top_center" | "top_right" | "center_left" | "center" | "center_right" | "bottom_left" | "bottom_center" | "bottom_right" | undefined;
|
|
152897
153140
|
titleColor?: string | undefined;
|
|
@@ -152904,6 +153147,7 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152904
153147
|
strokeStyle: "dashed" | "solid";
|
|
152905
153148
|
width?: number | undefined;
|
|
152906
153149
|
height?: number | undefined;
|
|
153150
|
+
name?: string | undefined;
|
|
152907
153151
|
schX?: number | undefined;
|
|
152908
153152
|
schY?: number | undefined;
|
|
152909
153153
|
padding?: number | undefined;
|
|
@@ -152911,13 +153155,42 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152911
153155
|
paddingRight?: number | undefined;
|
|
152912
153156
|
paddingTop?: number | undefined;
|
|
152913
153157
|
paddingBottom?: number | undefined;
|
|
153158
|
+
schPinArrangement?: {
|
|
153159
|
+
leftSize?: number | undefined;
|
|
153160
|
+
topSize?: number | undefined;
|
|
153161
|
+
rightSize?: number | undefined;
|
|
153162
|
+
bottomSize?: number | undefined;
|
|
153163
|
+
leftSide?: {
|
|
153164
|
+
pins: (string | number)[];
|
|
153165
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153166
|
+
} | undefined;
|
|
153167
|
+
topSide?: {
|
|
153168
|
+
pins: (string | number)[];
|
|
153169
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153170
|
+
} | undefined;
|
|
153171
|
+
rightSide?: {
|
|
153172
|
+
pins: (string | number)[];
|
|
153173
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153174
|
+
} | undefined;
|
|
153175
|
+
bottomSide?: {
|
|
153176
|
+
pins: (string | number)[];
|
|
153177
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153178
|
+
} | undefined;
|
|
153179
|
+
leftPinCount?: number | undefined;
|
|
153180
|
+
rightPinCount?: number | undefined;
|
|
153181
|
+
topPinCount?: number | undefined;
|
|
153182
|
+
bottomPinCount?: number | undefined;
|
|
153183
|
+
} | undefined;
|
|
152914
153184
|
title?: string | undefined;
|
|
153185
|
+
pinLabels?: Record<string, string | readonly string[] | string[]> | undefined;
|
|
153186
|
+
chipRef?: string | undefined;
|
|
152915
153187
|
overlay?: string[] | undefined;
|
|
152916
153188
|
titleColor?: string | undefined;
|
|
152917
153189
|
titleFontSize?: number | undefined;
|
|
152918
153190
|
}, {
|
|
152919
153191
|
width?: string | number | undefined;
|
|
152920
153192
|
height?: string | number | undefined;
|
|
153193
|
+
name?: string | undefined;
|
|
152921
153194
|
schX?: string | number | undefined;
|
|
152922
153195
|
schY?: string | number | undefined;
|
|
152923
153196
|
padding?: string | number | undefined;
|
|
@@ -152925,7 +153198,35 @@ declare class SchematicBox extends PrimitiveComponent<typeof schematicBoxProps>
|
|
|
152925
153198
|
paddingRight?: string | number | undefined;
|
|
152926
153199
|
paddingTop?: string | number | undefined;
|
|
152927
153200
|
paddingBottom?: string | number | undefined;
|
|
153201
|
+
schPinArrangement?: {
|
|
153202
|
+
leftSize?: number | undefined;
|
|
153203
|
+
topSize?: number | undefined;
|
|
153204
|
+
rightSize?: number | undefined;
|
|
153205
|
+
bottomSize?: number | undefined;
|
|
153206
|
+
leftSide?: (string | number)[] | {
|
|
153207
|
+
pins: (string | number)[];
|
|
153208
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153209
|
+
} | undefined;
|
|
153210
|
+
topSide?: (string | number)[] | {
|
|
153211
|
+
pins: (string | number)[];
|
|
153212
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153213
|
+
} | undefined;
|
|
153214
|
+
rightSide?: (string | number)[] | {
|
|
153215
|
+
pins: (string | number)[];
|
|
153216
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153217
|
+
} | undefined;
|
|
153218
|
+
bottomSide?: (string | number)[] | {
|
|
153219
|
+
pins: (string | number)[];
|
|
153220
|
+
direction: "top-to-bottom" | "left-to-right" | "bottom-to-top" | "right-to-left";
|
|
153221
|
+
} | undefined;
|
|
153222
|
+
leftPinCount?: number | undefined;
|
|
153223
|
+
rightPinCount?: number | undefined;
|
|
153224
|
+
topPinCount?: number | undefined;
|
|
153225
|
+
bottomPinCount?: number | undefined;
|
|
153226
|
+
} | undefined;
|
|
152928
153227
|
title?: string | undefined;
|
|
153228
|
+
pinLabels?: Record<string, string | readonly string[] | string[]> | undefined;
|
|
153229
|
+
chipRef?: string | undefined;
|
|
152929
153230
|
overlay?: string[] | undefined;
|
|
152930
153231
|
titleAlignment?: "top_left" | "top_center" | "top_right" | "center_left" | "center" | "center_right" | "bottom_left" | "bottom_center" | "bottom_right" | undefined;
|
|
152931
153232
|
titleColor?: string | undefined;
|
package/dist/index.js
CHANGED
|
@@ -19665,7 +19665,15 @@ function getTreeChildChipId(child, index) {
|
|
|
19665
19665
|
}
|
|
19666
19666
|
return null;
|
|
19667
19667
|
}
|
|
19668
|
-
|
|
19668
|
+
var getSchematicComponentForSourceComponent = ({
|
|
19669
|
+
db,
|
|
19670
|
+
sourceComponentId,
|
|
19671
|
+
schematicSheetId
|
|
19672
|
+
}) => db.schematic_component.getWhere({
|
|
19673
|
+
source_component_id: sourceComponentId,
|
|
19674
|
+
...schematicSheetId ? { schematic_sheet_id: schematicSheetId } : {}
|
|
19675
|
+
});
|
|
19676
|
+
function convertTreeToMatchPackInputProblem(tree, db, group, opts = {}) {
|
|
19669
19677
|
const problem = {
|
|
19670
19678
|
chipMap: {},
|
|
19671
19679
|
chipPinMap: {},
|
|
@@ -19699,8 +19707,10 @@ function convertTreeToMatchPackInputProblem(tree, db, group) {
|
|
|
19699
19707
|
}
|
|
19700
19708
|
if (child.nodeType === "component" && child.sourceComponent) {
|
|
19701
19709
|
const chipId = getTreeChildChipId(child, index);
|
|
19702
|
-
const schematicComponent =
|
|
19703
|
-
|
|
19710
|
+
const schematicComponent = getSchematicComponentForSourceComponent({
|
|
19711
|
+
db,
|
|
19712
|
+
sourceComponentId: child.sourceComponent.source_component_id,
|
|
19713
|
+
schematicSheetId: opts.schematicSheetId
|
|
19704
19714
|
});
|
|
19705
19715
|
if (!schematicComponent) return;
|
|
19706
19716
|
const component = group.children.find(
|
|
@@ -19980,7 +19990,7 @@ function convertTreeToMatchPackInputProblem(tree, db, group) {
|
|
|
19980
19990
|
}
|
|
19981
19991
|
return { inputProblem: problem, nestedGroupMatchpackProxyMap };
|
|
19982
19992
|
}
|
|
19983
|
-
function applySchematicMatchPackLayoutToTree(group, tree) {
|
|
19993
|
+
function applySchematicMatchPackLayoutToTree(group, tree, opts = {}) {
|
|
19984
19994
|
const { db } = group.root;
|
|
19985
19995
|
debug6(
|
|
19986
19996
|
`[${group.name}] Starting matchpack layout with ${tree.childNodes.length} children`
|
|
@@ -19993,7 +20003,7 @@ function applySchematicMatchPackLayoutToTree(group, tree) {
|
|
|
19993
20003
|
return;
|
|
19994
20004
|
}
|
|
19995
20005
|
debug6("Converting circuit tree to InputProblem...");
|
|
19996
|
-
const { inputProblem, nestedGroupMatchpackProxyMap } = convertTreeToMatchPackInputProblem(tree, db, group);
|
|
20006
|
+
const { inputProblem, nestedGroupMatchpackProxyMap } = convertTreeToMatchPackInputProblem(tree, db, group, opts);
|
|
19997
20007
|
if (debug6.enabled) {
|
|
19998
20008
|
group.root?.emit("debug:logOutput", {
|
|
19999
20009
|
type: "debug:logOutput",
|
|
@@ -20080,8 +20090,10 @@ function applySchematicMatchPackLayoutToTree(group, tree) {
|
|
|
20080
20090
|
debug6(`Skipping position update for fixed chip ${chipId}`);
|
|
20081
20091
|
continue;
|
|
20082
20092
|
}
|
|
20083
|
-
const schematicComponent =
|
|
20084
|
-
|
|
20093
|
+
const schematicComponent = getSchematicComponentForSourceComponent({
|
|
20094
|
+
db,
|
|
20095
|
+
sourceComponentId: treeNode.sourceComponent.source_component_id,
|
|
20096
|
+
schematicSheetId: opts.schematicSheetId
|
|
20085
20097
|
});
|
|
20086
20098
|
if (schematicComponent) {
|
|
20087
20099
|
debug6(`Moving component ${chipId} to (${newCenter.x}, ${newCenter.y})`);
|
|
@@ -20228,9 +20240,9 @@ function applySchematicMatchPackLayoutToTree(group, tree) {
|
|
|
20228
20240
|
import {
|
|
20229
20241
|
getCircuitJsonTree as getCircuitJsonTree2
|
|
20230
20242
|
} from "@tscircuit/circuit-json-util";
|
|
20231
|
-
function
|
|
20243
|
+
function getSchematicSheetIdBySourceGroupId({
|
|
20232
20244
|
circuitJson,
|
|
20233
|
-
|
|
20245
|
+
schematicSheetIdBySourceComponentId
|
|
20234
20246
|
}) {
|
|
20235
20247
|
const parentBySourceGroupId = /* @__PURE__ */ new Map();
|
|
20236
20248
|
for (const element of circuitJson) {
|
|
@@ -20241,34 +20253,36 @@ function getSchematicSheetIdByGroupId({
|
|
|
20241
20253
|
);
|
|
20242
20254
|
}
|
|
20243
20255
|
}
|
|
20244
|
-
const
|
|
20256
|
+
const schematicSheetIdBySourceGroupId = /* @__PURE__ */ new Map();
|
|
20245
20257
|
for (const element of circuitJson) {
|
|
20246
20258
|
if (element.type !== "source_component") continue;
|
|
20247
20259
|
if (!element.source_group_id) continue;
|
|
20248
|
-
const
|
|
20249
|
-
|
|
20250
|
-
|
|
20251
|
-
|
|
20252
|
-
|
|
20253
|
-
|
|
20260
|
+
const schematicSheetId = schematicSheetIdBySourceComponentId.get(
|
|
20261
|
+
element.source_component_id
|
|
20262
|
+
);
|
|
20263
|
+
if (schematicSheetId === void 0) continue;
|
|
20264
|
+
let sourceGroupId = element.source_group_id;
|
|
20265
|
+
while (sourceGroupId && !schematicSheetIdBySourceGroupId.has(sourceGroupId)) {
|
|
20266
|
+
schematicSheetIdBySourceGroupId.set(sourceGroupId, schematicSheetId);
|
|
20267
|
+
sourceGroupId = parentBySourceGroupId.get(sourceGroupId);
|
|
20254
20268
|
}
|
|
20255
20269
|
}
|
|
20256
|
-
return
|
|
20270
|
+
return schematicSheetIdBySourceGroupId;
|
|
20257
20271
|
}
|
|
20258
20272
|
function getCircuitJsonScopedToSchematicSheet({
|
|
20259
20273
|
circuitJson,
|
|
20260
|
-
|
|
20274
|
+
schematicSheetId,
|
|
20261
20275
|
rootSourceGroupId,
|
|
20262
|
-
|
|
20263
|
-
|
|
20276
|
+
schematicSheetIdBySourceComponentId,
|
|
20277
|
+
schematicSheetIdBySourceGroupId
|
|
20264
20278
|
}) {
|
|
20265
|
-
const isGroupOnSheet = (sourceGroupId) => sourceGroupId === rootSourceGroupId ||
|
|
20279
|
+
const isGroupOnSheet = (sourceGroupId) => sourceGroupId === rootSourceGroupId || schematicSheetIdBySourceGroupId.get(sourceGroupId) === schematicSheetId;
|
|
20266
20280
|
return circuitJson.filter((element) => {
|
|
20267
20281
|
if (element.type === "source_group") {
|
|
20268
20282
|
return isGroupOnSheet(element.source_group_id);
|
|
20269
20283
|
}
|
|
20270
20284
|
if (element.type === "source_component") {
|
|
20271
|
-
if (
|
|
20285
|
+
if (schematicSheetIdBySourceComponentId.get(element.source_component_id) !== schematicSheetId) {
|
|
20272
20286
|
return false;
|
|
20273
20287
|
}
|
|
20274
20288
|
return element.source_group_id ? isGroupOnSheet(element.source_group_id) : true;
|
|
@@ -20278,36 +20292,44 @@ function getCircuitJsonScopedToSchematicSheet({
|
|
|
20278
20292
|
}
|
|
20279
20293
|
function getSchematicCircuitJsonTrees(circuitJson, opts) {
|
|
20280
20294
|
const { source_group_id } = opts;
|
|
20281
|
-
const
|
|
20295
|
+
const schematicSheetIdBySourceComponentId = /* @__PURE__ */ new Map();
|
|
20282
20296
|
for (const element of circuitJson) {
|
|
20283
20297
|
if (element.type !== "schematic_component") continue;
|
|
20284
20298
|
if (!element.source_component_id) continue;
|
|
20285
20299
|
if (!element.schematic_sheet_id) continue;
|
|
20286
|
-
|
|
20300
|
+
schematicSheetIdBySourceComponentId.set(
|
|
20287
20301
|
element.source_component_id,
|
|
20288
20302
|
element.schematic_sheet_id
|
|
20289
20303
|
);
|
|
20290
20304
|
}
|
|
20291
|
-
const
|
|
20292
|
-
|
|
20293
|
-
|
|
20305
|
+
const schematicSheetIds = new Set(
|
|
20306
|
+
schematicSheetIdBySourceComponentId.values()
|
|
20307
|
+
);
|
|
20308
|
+
if (schematicSheetIds.size <= 1) {
|
|
20309
|
+
return [
|
|
20310
|
+
{
|
|
20311
|
+
tree: getCircuitJsonTree2(circuitJson, { source_group_id }),
|
|
20312
|
+
schematicSheetId: schematicSheetIds.values().next().value
|
|
20313
|
+
}
|
|
20314
|
+
];
|
|
20294
20315
|
}
|
|
20295
|
-
const
|
|
20316
|
+
const schematicSheetIdBySourceGroupId = getSchematicSheetIdBySourceGroupId({
|
|
20296
20317
|
circuitJson,
|
|
20297
|
-
|
|
20318
|
+
schematicSheetIdBySourceComponentId
|
|
20298
20319
|
});
|
|
20299
|
-
return Array.from(
|
|
20300
|
-
|
|
20320
|
+
return Array.from(schematicSheetIds).map((schematicSheetId) => ({
|
|
20321
|
+
tree: getCircuitJsonTree2(
|
|
20301
20322
|
getCircuitJsonScopedToSchematicSheet({
|
|
20302
20323
|
circuitJson,
|
|
20303
|
-
|
|
20324
|
+
schematicSheetId,
|
|
20304
20325
|
rootSourceGroupId: source_group_id,
|
|
20305
|
-
|
|
20306
|
-
|
|
20326
|
+
schematicSheetIdBySourceComponentId,
|
|
20327
|
+
schematicSheetIdBySourceGroupId
|
|
20307
20328
|
}),
|
|
20308
20329
|
{ source_group_id }
|
|
20309
|
-
)
|
|
20310
|
-
|
|
20330
|
+
),
|
|
20331
|
+
schematicSheetId
|
|
20332
|
+
}));
|
|
20311
20333
|
}
|
|
20312
20334
|
|
|
20313
20335
|
// lib/components/primitive-components/Group/Group_doInitialSchematicLayoutMatchPack.ts
|
|
@@ -20316,8 +20338,8 @@ function Group_doInitialSchematicLayoutMatchPack(group) {
|
|
|
20316
20338
|
const trees = getSchematicCircuitJsonTrees(db.toArray(), {
|
|
20317
20339
|
source_group_id: group.source_group_id
|
|
20318
20340
|
});
|
|
20319
|
-
for (const tree of trees) {
|
|
20320
|
-
applySchematicMatchPackLayoutToTree(group, tree);
|
|
20341
|
+
for (const { tree, schematicSheetId } of trees) {
|
|
20342
|
+
applySchematicMatchPackLayoutToTree(group, tree, { schematicSheetId });
|
|
20321
20343
|
}
|
|
20322
20344
|
}
|
|
20323
20345
|
|
|
@@ -22889,7 +22911,7 @@ function Group_getRoutingPhasePlans(group) {
|
|
|
22889
22911
|
var package_default = {
|
|
22890
22912
|
name: "@tscircuit/core",
|
|
22891
22913
|
type: "module",
|
|
22892
|
-
version: "0.0.
|
|
22914
|
+
version: "0.0.1474",
|
|
22893
22915
|
types: "dist/index.d.ts",
|
|
22894
22916
|
main: "dist/index.js",
|
|
22895
22917
|
module: "dist/index.js",
|
|
@@ -22938,7 +22960,7 @@ var package_default = {
|
|
|
22938
22960
|
"@tscircuit/math-utils": "^0.0.36",
|
|
22939
22961
|
"@tscircuit/miniflex": "^0.0.4",
|
|
22940
22962
|
"@tscircuit/ngspice-spice-engine": "^0.0.19",
|
|
22941
|
-
"@tscircuit/props": "^0.0.
|
|
22963
|
+
"@tscircuit/props": "^0.0.587",
|
|
22942
22964
|
"@tscircuit/schematic-match-adapt": "^0.0.18",
|
|
22943
22965
|
"@tscircuit/schematic-trace-solver": "^0.0.104",
|
|
22944
22966
|
"@tscircuit/solver-utils": "^0.0.16",
|
|
@@ -32741,7 +32763,7 @@ var TestPoint = class extends NormalComponent3 {
|
|
|
32741
32763
|
}
|
|
32742
32764
|
};
|
|
32743
32765
|
|
|
32744
|
-
// lib/components/primitive-components/SchematicBox.ts
|
|
32766
|
+
// lib/components/primitive-components/SchematicBox/SchematicBox.ts
|
|
32745
32767
|
import { schematicBoxProps } from "@tscircuit/props";
|
|
32746
32768
|
|
|
32747
32769
|
// lib/components/primitive-components/getTitleAnchorAndPosition.ts
|
|
@@ -32817,7 +32839,7 @@ function getTitleAnchorAndPosition({
|
|
|
32817
32839
|
}
|
|
32818
32840
|
}
|
|
32819
32841
|
|
|
32820
|
-
// lib/components/primitive-components/SchematicBox.ts
|
|
32842
|
+
// lib/components/primitive-components/SchematicBox/SchematicBox.ts
|
|
32821
32843
|
var SchematicBox = class extends PrimitiveComponent2 {
|
|
32822
32844
|
isSchematicPrimitive = true;
|
|
32823
32845
|
get config() {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tscircuit/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.1475",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.js",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"@tscircuit/math-utils": "^0.0.36",
|
|
51
51
|
"@tscircuit/miniflex": "^0.0.4",
|
|
52
52
|
"@tscircuit/ngspice-spice-engine": "^0.0.19",
|
|
53
|
-
"@tscircuit/props": "^0.0.
|
|
53
|
+
"@tscircuit/props": "^0.0.587",
|
|
54
54
|
"@tscircuit/schematic-match-adapt": "^0.0.18",
|
|
55
55
|
"@tscircuit/schematic-trace-solver": "^0.0.104",
|
|
56
56
|
"@tscircuit/solver-utils": "^0.0.16",
|