@tscircuit/core 0.0.12 → 0.0.14
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.js
CHANGED
|
@@ -248,7 +248,7 @@ var PrimitiveComponent = class extends Renderable {
|
|
|
248
248
|
}
|
|
249
249
|
const { config } = this;
|
|
250
250
|
if (!config.schematicSymbolName) return null;
|
|
251
|
-
return symbols[`${config.schematicSymbolName}_${variant}`];
|
|
251
|
+
return symbols[`${config.schematicSymbolName}_${variant}`] ?? null;
|
|
252
252
|
}
|
|
253
253
|
getGlobalPcbPosition() {
|
|
254
254
|
return applyToPoint(this.computePcbGlobalTransform(), { x: 0, y: 0 });
|
|
@@ -1420,8 +1420,8 @@ searched component ${targetComponent.getString()}, which has ports:${targetCompo
|
|
|
1420
1420
|
}
|
|
1421
1421
|
if (pcbRouteHints.length === 0) {
|
|
1422
1422
|
const { solution } = autoroute(pcbElements.concat([source_trace]));
|
|
1423
|
-
const
|
|
1424
|
-
db.pcb_trace.insert(
|
|
1423
|
+
const inputPcbTrace = solution[0];
|
|
1424
|
+
const pcb_trace2 = db.pcb_trace.insert(inputPcbTrace);
|
|
1425
1425
|
this.pcb_trace_id = pcb_trace2.pcb_trace_id;
|
|
1426
1426
|
return;
|
|
1427
1427
|
}
|
|
@@ -136,9 +136,11 @@ export abstract class PrimitiveComponent<
|
|
|
136
136
|
}
|
|
137
137
|
const { config } = this
|
|
138
138
|
if (!config.schematicSymbolName) return null
|
|
139
|
-
return
|
|
140
|
-
|
|
141
|
-
|
|
139
|
+
return (
|
|
140
|
+
symbols[
|
|
141
|
+
`${config.schematicSymbolName}_${variant}` as keyof typeof symbols
|
|
142
|
+
] ?? null
|
|
143
|
+
)
|
|
142
144
|
}
|
|
143
145
|
|
|
144
146
|
getGlobalPcbPosition(): { x: number; y: number } {
|
|
@@ -172,8 +172,9 @@ export class Trace extends PrimitiveComponent<typeof traceProps> {
|
|
|
172
172
|
if (pcbRouteHints.length === 0) {
|
|
173
173
|
const { solution } = autoroute(pcbElements.concat([source_trace]))
|
|
174
174
|
// TODO for some reason, the solution gets duplicated inside ijump-astar
|
|
175
|
-
const
|
|
176
|
-
db.pcb_trace.insert(
|
|
175
|
+
const inputPcbTrace = solution[0]
|
|
176
|
+
const pcb_trace = db.pcb_trace.insert(inputPcbTrace as any)
|
|
177
|
+
|
|
177
178
|
this.pcb_trace_id = pcb_trace.pcb_trace_id
|
|
178
179
|
return
|
|
179
180
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@tscircuit/core",
|
|
3
3
|
"module": "index.ts",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "0.0.
|
|
5
|
+
"version": "0.0.14",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
7
|
"main": "dist/index.js",
|
|
8
8
|
"files": [
|
|
@@ -27,14 +27,14 @@
|
|
|
27
27
|
"typescript": "^5.0.0"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@tscircuit/infgrid-ijump-astar": "0.0.
|
|
30
|
+
"@tscircuit/infgrid-ijump-astar": "0.0.5",
|
|
31
31
|
"@tscircuit/props": "^0.0.46",
|
|
32
32
|
"@tscircuit/soup": "^0.0.58",
|
|
33
33
|
"@tscircuit/soup-util": "0.0.18",
|
|
34
34
|
"footprinter": "^0.0.44",
|
|
35
35
|
"react": "^18.3.1",
|
|
36
36
|
"react-reconciler": "^0.29.2",
|
|
37
|
-
"schematic-symbols": "0.0.
|
|
37
|
+
"schematic-symbols": "0.0.17",
|
|
38
38
|
"transformation-matrix": "^2.16.1",
|
|
39
39
|
"zod": "^3.23.8"
|
|
40
40
|
}
|