@tscircuit/core 0.0.1167 → 0.0.1169
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 +12 -0
- package/dist/index.js +25 -12
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -15604,6 +15604,7 @@ declare class Chip<PinLabels extends string = never> extends NormalComponent<typ
|
|
|
15604
15604
|
schWidth: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
|
|
15605
15605
|
schHeight: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
|
|
15606
15606
|
noSchematicRepresentation: z.ZodOptional<z.ZodBoolean>;
|
|
15607
|
+
noConnect: z.ZodOptional<z.ZodUnion<[z.ZodReadonly<z.ZodArray<z.ZodString, "many">>, z.ZodArray<z.ZodString, "many">]>>;
|
|
15607
15608
|
connections: z.ZodOptional<z.ZodPipeline<z.ZodType<Partial<Record<string, string | string[] | readonly string[]>>, z.ZodTypeDef, Partial<Record<string, string | string[] | readonly string[]>>>, z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodReadonly<z.ZodArray<z.ZodString, "many">>]>, z.ZodArray<z.ZodString, "many">]>>>>;
|
|
15608
15609
|
}, "strip", z.ZodTypeAny, {
|
|
15609
15610
|
name: string;
|
|
@@ -16257,6 +16258,7 @@ declare class Chip<PinLabels extends string = never> extends NormalComponent<typ
|
|
|
16257
16258
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
16258
16259
|
}[] | undefined;
|
|
16259
16260
|
noSchematicRepresentation?: boolean | undefined;
|
|
16261
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
16260
16262
|
}, {
|
|
16261
16263
|
name: string;
|
|
16262
16264
|
symbol?: _tscircuit_props.SymbolProp | undefined;
|
|
@@ -16911,6 +16913,7 @@ declare class Chip<PinLabels extends string = never> extends NormalComponent<typ
|
|
|
16911
16913
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
16912
16914
|
}[] | undefined;
|
|
16913
16915
|
noSchematicRepresentation?: boolean | undefined;
|
|
16916
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
16914
16917
|
}>;
|
|
16915
16918
|
shouldRenderAsSchematicBox: boolean;
|
|
16916
16919
|
};
|
|
@@ -20577,6 +20580,7 @@ declare class Pinout<PinLabels extends string = never> extends Chip<PinLabels> {
|
|
|
20577
20580
|
schWidth: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
|
|
20578
20581
|
schHeight: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
|
|
20579
20582
|
noSchematicRepresentation: z.ZodOptional<z.ZodBoolean>;
|
|
20583
|
+
noConnect: z.ZodOptional<z.ZodUnion<[z.ZodReadonly<z.ZodArray<z.ZodString, "many">>, z.ZodArray<z.ZodString, "many">]>>;
|
|
20580
20584
|
connections: z.ZodOptional<z.ZodPipeline<z.ZodType<Partial<Record<string, string | string[] | readonly string[]>>, z.ZodTypeDef, Partial<Record<string, string | string[] | readonly string[]>>>, z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodReadonly<z.ZodArray<z.ZodString, "many">>]>, z.ZodArray<z.ZodString, "many">]>>>>;
|
|
20581
20585
|
}, "strip", z.ZodTypeAny, {
|
|
20582
20586
|
name: string;
|
|
@@ -21230,6 +21234,7 @@ declare class Pinout<PinLabels extends string = never> extends Chip<PinLabels> {
|
|
|
21230
21234
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
21231
21235
|
}[] | undefined;
|
|
21232
21236
|
noSchematicRepresentation?: boolean | undefined;
|
|
21237
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
21233
21238
|
}, {
|
|
21234
21239
|
name: string;
|
|
21235
21240
|
symbol?: _tscircuit_props.SymbolProp | undefined;
|
|
@@ -21884,6 +21889,7 @@ declare class Pinout<PinLabels extends string = never> extends Chip<PinLabels> {
|
|
|
21884
21889
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
21885
21890
|
}[] | undefined;
|
|
21886
21891
|
noSchematicRepresentation?: boolean | undefined;
|
|
21892
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
21887
21893
|
}>;
|
|
21888
21894
|
shouldRenderAsSchematicBox: boolean;
|
|
21889
21895
|
};
|
|
@@ -91832,6 +91838,7 @@ declare class Connector<PinLabels extends string = never> extends Chip<PinLabels
|
|
|
91832
91838
|
schWidth: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
91833
91839
|
schHeight: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
91834
91840
|
noSchematicRepresentation: zod.ZodOptional<zod.ZodBoolean>;
|
|
91841
|
+
noConnect: zod.ZodOptional<zod.ZodUnion<[zod.ZodReadonly<zod.ZodArray<zod.ZodString, "many">>, zod.ZodArray<zod.ZodString, "many">]>>;
|
|
91835
91842
|
connections: zod.ZodOptional<zod.ZodPipeline<zod.ZodType<Partial<Record<string, string | string[] | readonly string[]>>, zod.ZodTypeDef, Partial<Record<string, string | string[] | readonly string[]>>>, zod.ZodRecord<zod.ZodString, zod.ZodUnion<[zod.ZodUnion<[zod.ZodString, zod.ZodReadonly<zod.ZodArray<zod.ZodString, "many">>]>, zod.ZodArray<zod.ZodString, "many">]>>>>;
|
|
91836
91843
|
} & {
|
|
91837
91844
|
standard: zod.ZodOptional<zod.ZodEnum<["usb_c", "m2"]>>;
|
|
@@ -92487,6 +92494,7 @@ declare class Connector<PinLabels extends string = never> extends Chip<PinLabels
|
|
|
92487
92494
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
92488
92495
|
}[] | undefined;
|
|
92489
92496
|
noSchematicRepresentation?: boolean | undefined;
|
|
92497
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
92490
92498
|
standard?: "usb_c" | "m2" | undefined;
|
|
92491
92499
|
}, {
|
|
92492
92500
|
name: string;
|
|
@@ -93142,6 +93150,7 @@ declare class Connector<PinLabels extends string = never> extends Chip<PinLabels
|
|
|
93142
93150
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
93143
93151
|
}[] | undefined;
|
|
93144
93152
|
noSchematicRepresentation?: boolean | undefined;
|
|
93153
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
93145
93154
|
standard?: "usb_c" | "m2" | undefined;
|
|
93146
93155
|
}>;
|
|
93147
93156
|
shouldRenderAsSchematicBox: boolean;
|
|
@@ -115211,6 +115220,7 @@ declare class PushButton extends NormalComponent<typeof pushButtonProps, Passive
|
|
|
115211
115220
|
schWidth: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
115212
115221
|
schHeight: zod.ZodOptional<zod.ZodEffects<zod.ZodUnion<[zod.ZodString, zod.ZodNumber]>, number, string | number>>;
|
|
115213
115222
|
noSchematicRepresentation: zod.ZodOptional<zod.ZodBoolean>;
|
|
115223
|
+
noConnect: zod.ZodOptional<zod.ZodUnion<[zod.ZodReadonly<zod.ZodArray<zod.ZodString, "many">>, zod.ZodArray<zod.ZodString, "many">]>>;
|
|
115214
115224
|
connections: zod.ZodOptional<zod.ZodPipeline<zod.ZodType<Partial<Record<string, string | string[] | readonly string[]>>, zod.ZodTypeDef, Partial<Record<string, string | string[] | readonly string[]>>>, zod.ZodRecord<zod.ZodString, zod.ZodUnion<[zod.ZodUnion<[zod.ZodString, zod.ZodReadonly<zod.ZodArray<zod.ZodString, "many">>]>, zod.ZodArray<zod.ZodString, "many">]>>>>;
|
|
115215
115225
|
}, "strip", zod.ZodTypeAny, {
|
|
115216
115226
|
name: string;
|
|
@@ -115864,6 +115874,7 @@ declare class PushButton extends NormalComponent<typeof pushButtonProps, Passive
|
|
|
115864
115874
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
115865
115875
|
}[] | undefined;
|
|
115866
115876
|
noSchematicRepresentation?: boolean | undefined;
|
|
115877
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
115867
115878
|
}, {
|
|
115868
115879
|
name: string;
|
|
115869
115880
|
symbol?: _tscircuit_props.SymbolProp | undefined;
|
|
@@ -116518,6 +116529,7 @@ declare class PushButton extends NormalComponent<typeof pushButtonProps, Passive
|
|
|
116518
116529
|
supplierPartNumber?: Partial<Record<"jlcpcb" | "macrofab" | "pcbway" | "digikey" | "mouser" | "lcsc", string[]>> | undefined;
|
|
116519
116530
|
}[] | undefined;
|
|
116520
116531
|
noSchematicRepresentation?: boolean | undefined;
|
|
116532
|
+
noConnect?: readonly string[] | string[] | undefined;
|
|
116521
116533
|
}>;
|
|
116522
116534
|
sourceFtype: "simple_push_button";
|
|
116523
116535
|
};
|
package/dist/index.js
CHANGED
|
@@ -1970,11 +1970,13 @@ var PrimitiveComponent2 = class extends Renderable {
|
|
|
1970
1970
|
(n) => n.lowercaseComponentName === options.type
|
|
1971
1971
|
);
|
|
1972
1972
|
}
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1973
|
+
if (!options?.type) {
|
|
1974
|
+
result ??= selectOne(
|
|
1975
|
+
selector,
|
|
1976
|
+
this,
|
|
1977
|
+
cssSelectOptionsInsideSubcircuit
|
|
1978
|
+
);
|
|
1979
|
+
}
|
|
1978
1980
|
if (result) {
|
|
1979
1981
|
this._cachedSelectOneQueries.set(selectorRaw, result);
|
|
1980
1982
|
return result;
|
|
@@ -8861,15 +8863,24 @@ var Port = class extends PrimitiveComponent2 {
|
|
|
8861
8863
|
);
|
|
8862
8864
|
}
|
|
8863
8865
|
_getMatchingPinAttributes() {
|
|
8864
|
-
const
|
|
8865
|
-
|
|
8866
|
+
const parentProps = this.parent?._parsedProps;
|
|
8867
|
+
const pinAttributes = parentProps?.pinAttributes;
|
|
8868
|
+
const noConnect = parentProps?.noConnect;
|
|
8866
8869
|
const matches = [];
|
|
8867
8870
|
for (const alias of this.getNameAndAliases()) {
|
|
8868
|
-
|
|
8869
|
-
|
|
8870
|
-
|
|
8871
|
+
if (pinAttributes) {
|
|
8872
|
+
const attributes = pinAttributes[alias];
|
|
8873
|
+
if (attributes) {
|
|
8874
|
+
matches.push(attributes);
|
|
8875
|
+
}
|
|
8876
|
+
}
|
|
8877
|
+
if (noConnect?.includes(alias)) {
|
|
8878
|
+
matches.push({ doNotConnect: true });
|
|
8871
8879
|
}
|
|
8872
8880
|
}
|
|
8881
|
+
if (matches.length === 0) {
|
|
8882
|
+
return [];
|
|
8883
|
+
}
|
|
8873
8884
|
return matches;
|
|
8874
8885
|
}
|
|
8875
8886
|
_shouldIncludeInBoardPinout() {
|
|
@@ -10533,6 +10544,8 @@ var NormalComponent_doInitialSourceDesignRuleChecks = (component) => {
|
|
|
10533
10544
|
for (const port of ports) {
|
|
10534
10545
|
if (!port.source_port_id) continue;
|
|
10535
10546
|
if (!shouldCheckPortForMissingTrace(component, port)) continue;
|
|
10547
|
+
const sourcePort = db.source_port.get(port.source_port_id);
|
|
10548
|
+
if (sourcePort?.do_not_connect) continue;
|
|
10536
10549
|
if (connected.has(port.source_port_id)) continue;
|
|
10537
10550
|
db.source_pin_missing_trace_warning.insert({
|
|
10538
10551
|
message: `Port ${port.getNameAndAliases()[0]} on ${component.props.name} is missing a trace`,
|
|
@@ -19609,7 +19622,7 @@ import { identity as identity5 } from "transformation-matrix";
|
|
|
19609
19622
|
var package_default = {
|
|
19610
19623
|
name: "@tscircuit/core",
|
|
19611
19624
|
type: "module",
|
|
19612
|
-
version: "0.0.
|
|
19625
|
+
version: "0.0.1168",
|
|
19613
19626
|
types: "dist/index.d.ts",
|
|
19614
19627
|
main: "dist/index.js",
|
|
19615
19628
|
module: "dist/index.js",
|
|
@@ -19654,7 +19667,7 @@ var package_default = {
|
|
|
19654
19667
|
"@tscircuit/math-utils": "^0.0.36",
|
|
19655
19668
|
"@tscircuit/miniflex": "^0.0.4",
|
|
19656
19669
|
"@tscircuit/ngspice-spice-engine": "^0.0.8",
|
|
19657
|
-
"@tscircuit/props": "^0.0.
|
|
19670
|
+
"@tscircuit/props": "^0.0.506",
|
|
19658
19671
|
"@tscircuit/schematic-match-adapt": "^0.0.16",
|
|
19659
19672
|
"@tscircuit/schematic-trace-solver": "^v0.0.45",
|
|
19660
19673
|
"@tscircuit/solver-utils": "^0.0.3",
|
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.1169",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.js",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"@tscircuit/math-utils": "^0.0.36",
|
|
47
47
|
"@tscircuit/miniflex": "^0.0.4",
|
|
48
48
|
"@tscircuit/ngspice-spice-engine": "^0.0.8",
|
|
49
|
-
"@tscircuit/props": "^0.0.
|
|
49
|
+
"@tscircuit/props": "^0.0.506",
|
|
50
50
|
"@tscircuit/schematic-match-adapt": "^0.0.16",
|
|
51
51
|
"@tscircuit/schematic-trace-solver": "^v0.0.45",
|
|
52
52
|
"@tscircuit/solver-utils": "^0.0.3",
|