@tscircuit/cli 0.0.88 → 0.0.89

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.
@@ -142,7 +142,7 @@ export default {
142
142
  import manual_edits from "./MyCircuit.manual-edits"
143
143
 
144
144
  export const MyCircuit = () => (
145
- <group layout={layout().manualPcbPositions(manual_edits.pcb_placements)}>
145
+ <group layout={layout().manualEdits(manual_edits)}>
146
146
  <resistor
147
147
  resistance="10kohm"
148
148
  name="R1"
@@ -161,7 +161,9 @@ export default {
161
161
  import { MyCircuit } from "lib/MyCircuit"
162
162
 
163
163
  export const MyExample = () => (
164
- <MyCircuit />
164
+ <board width="40mm" height="40mm" pcbCenterX={0} pcbCenterY={0}>
165
+ <MyCircuit />
166
+ </board>
165
167
  )
166
168
  `.trim()
167
169
  )
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tscircuit/cli",
3
- "version": "0.0.88",
3
+ "version": "0.0.89",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "Command line tool for developing, publishing and installing tscircuit circuits",
@@ -18,7 +18,7 @@
18
18
  "build": "bun build:dev-server && npm run build:cli",
19
19
  "dev-with-test-project": "bun cli.ts dev --cwd ./tests/assets/example-project",
20
20
  "test:init": "bun cli.ts init --dir ./tmp/test --name test",
21
- "update-deps": "npm add @tscircuit/builder@latest @tscircuit/react-fiber@latest && cd dev-server-frontend && npm run update-deps && cd ../tests/assets/example-project && npm add @tscircuit/builder@latest @tscircuit/react-fiber@latest"
21
+ "update-deps": "npm add @tscircuit/builder@latest @tscircuit/react-fiber@latest && cd dev-server-frontend && npm run update-deps && cd ../tests/assets/example-project && npm add @tscircuit/builder@latest @tscircuit/react-fiber@latest @tscircuit/layout@latest"
22
22
  },
23
23
  "bin": {
24
24
  "tscircuit": "./dist/cli.js",
@@ -36,8 +36,8 @@
36
36
  "dependencies": {
37
37
  "@edge-runtime/primitives": "^4.1.0",
38
38
  "@hono/node-server": "^1.8.2",
39
- "@tscircuit/builder": "^1.5.87",
40
- "@tscircuit/react-fiber": "^1.0.39",
39
+ "@tscircuit/builder": "^1.5.92",
40
+ "@tscircuit/react-fiber": "^1.1.12",
41
41
  "@tscircuit/soup-util": "^0.0.1",
42
42
  "archiver": "^7.0.1",
43
43
  "axios": "^1.6.7",
@@ -8,8 +8,9 @@
8
8
  "name": "example-project",
9
9
  "version": "1.2.26",
10
10
  "dependencies": {
11
- "@tscircuit/builder": "^1.5.87",
12
- "@tscircuit/react-fiber": "^1.0.39"
11
+ "@tscircuit/builder": "^1.5.92",
12
+ "@tscircuit/layout": "^0.0.12",
13
+ "@tscircuit/react-fiber": "^1.1.12"
13
14
  }
14
15
  },
15
16
  "node_modules/@babel/runtime": {
@@ -29,16 +30,17 @@
29
30
  "integrity": "sha512-iB+oaYyaVK1hQ0cODubnoSDg4gGYL9cp/4ad7G1b9Z0/IqehPztp5qE3KP2mV9Ns0UYmzwvtkEhTCmKUuhorbg=="
30
31
  },
31
32
  "node_modules/@tscircuit/builder": {
32
- "version": "1.5.87",
33
- "resolved": "https://registry.npmjs.org/@tscircuit/builder/-/builder-1.5.87.tgz",
34
- "integrity": "sha512-ITtSXjOpHL4J03HemsVtnFl3DfFc0ELTctk5XfhYAdYHKvy+ege6EKWiYRT90CMLb6N0r9+6NaZUaHALJLgYRw==",
33
+ "version": "1.5.92",
34
+ "resolved": "https://registry.npmjs.org/@tscircuit/builder/-/builder-1.5.92.tgz",
35
+ "integrity": "sha512-cuztSJQS18GYG5ntYMd1aJ5gis9WrExg4Y+qTa5CLnPJFAxFkpgLDNDiQU4vTDqXH23mqsTufysHCHHcKjy5EA==",
35
36
  "dependencies": {
36
37
  "@lume/kiwi": "^0.1.0",
37
38
  "@tscircuit/footprints": "^0.0.14",
38
- "@tscircuit/layout": "^0.0.7",
39
+ "@tscircuit/layout": "^0.0.8",
39
40
  "@tscircuit/routing": "^1.3.1",
40
41
  "@tscircuit/schematic-autolayout": "^0.0.5",
41
- "@tscircuit/soup-util": "^0.0.1",
42
+ "@tscircuit/soup": "^0.0.17",
43
+ "@tscircuit/soup-util": "^0.0.10",
42
44
  "@tscircuit/sparkfun-packages": "^1.2.1",
43
45
  "convert-units": "^2.3.4",
44
46
  "fast-json-stable-stringify": "^2.1.0",
@@ -49,6 +51,17 @@
49
51
  "transformation-matrix": "^2.12.0"
50
52
  }
51
53
  },
54
+ "node_modules/@tscircuit/builder/node_modules/@tscircuit/layout": {
55
+ "version": "0.0.8",
56
+ "resolved": "https://registry.npmjs.org/@tscircuit/layout/-/layout-0.0.8.tgz",
57
+ "integrity": "sha512-tGeZhg8eKJ7kekwgNj0hKwPh1/sReappOhc0+198DQr/M9ju0ufsqE2NgxCZc119P9wE/fLLkHDjYYgd+Lvl6A==",
58
+ "dependencies": {
59
+ "transformation-matrix": "^2.16.1"
60
+ },
61
+ "peerDependencies": {
62
+ "zod": "*"
63
+ }
64
+ },
52
65
  "node_modules/@tscircuit/footprints": {
53
66
  "version": "0.0.14",
54
67
  "resolved": "https://registry.npmjs.org/@tscircuit/footprints/-/footprints-0.0.14.tgz",
@@ -61,17 +74,27 @@
61
74
  }
62
75
  },
63
76
  "node_modules/@tscircuit/layout": {
64
- "version": "0.0.7",
65
- "resolved": "https://registry.npmjs.org/@tscircuit/layout/-/layout-0.0.7.tgz",
66
- "integrity": "sha512-Jdd6j0+p4yK8zAqFX7dgmb5PT8A9KJduDBhEgAm+OgwDrw3Mp0hQ80pbR2Mvm02UF2Gu9H7TWpMytACCoNqPdA==",
77
+ "version": "0.0.12",
78
+ "resolved": "https://registry.npmjs.org/@tscircuit/layout/-/layout-0.0.12.tgz",
79
+ "integrity": "sha512-xmNvvB5OikkmS0iPeJIPZsI1VNe7V/vBIgNFSSGxjAO0mMsLU6DbtOxj/+5+b5qTSSpjaSjAxwiYLNS2nSYYww==",
67
80
  "dependencies": {
81
+ "@tscircuit/soup": "^0.0.4",
82
+ "@tscircuit/soup-util": "^0.0.10",
68
83
  "transformation-matrix": "^2.16.1"
69
84
  },
70
85
  "peerDependencies": {
71
- "@tscircuit/builder": "*",
72
86
  "zod": "*"
73
87
  }
74
88
  },
89
+ "node_modules/@tscircuit/layout/node_modules/@tscircuit/soup": {
90
+ "version": "0.0.4",
91
+ "resolved": "https://registry.npmjs.org/@tscircuit/soup/-/soup-0.0.4.tgz",
92
+ "integrity": "sha512-XhlI13Sg0p8EL5qc8v+cW/bYIJ5cI2+dLARv4KZE6pMwVVd2Z0toeIGAv7nKWqH2DdBmMmkHD+Xa4gLomRJPrg==",
93
+ "dependencies": {
94
+ "convert-units": "^2.3.4",
95
+ "zod": "^3.23.6"
96
+ }
97
+ },
75
98
  "node_modules/@tscircuit/mm": {
76
99
  "version": "0.0.4",
77
100
  "resolved": "https://registry.npmjs.org/@tscircuit/mm/-/mm-0.0.4.tgz",
@@ -84,17 +107,28 @@
84
107
  }
85
108
  },
86
109
  "node_modules/@tscircuit/react-fiber": {
87
- "version": "1.0.39",
88
- "resolved": "https://registry.npmjs.org/@tscircuit/react-fiber/-/react-fiber-1.0.39.tgz",
89
- "integrity": "sha512-xdEghvKDm9xr5j+zvEH8VVLj6haYCsQ5V8vNOyuXLoc63o7B/Maibsp5Yf6DdoC+SsxYYdZIt8cc0lAj7REfFg==",
110
+ "version": "1.1.12",
111
+ "resolved": "https://registry.npmjs.org/@tscircuit/react-fiber/-/react-fiber-1.1.12.tgz",
112
+ "integrity": "sha512-pgPWij4NQT15kkwwUV3ezaAa51O3Ta1i+V5viiVvP4ElMBvL7nuIZuVO0ALzB5NibQSgDeLFoLq+A6DxDCfaew==",
90
113
  "dependencies": {
91
- "react-reconciler": "^0.29.0"
114
+ "@tscircuit/soup": "^0.0.8",
115
+ "react-reconciler": "^0.29.0",
116
+ "to-snake-case": "^1.0.0"
92
117
  },
93
118
  "peerDependencies": {
94
119
  "@tscircuit/builder": "*",
95
120
  "react": "*"
96
121
  }
97
122
  },
123
+ "node_modules/@tscircuit/react-fiber/node_modules/@tscircuit/soup": {
124
+ "version": "0.0.8",
125
+ "resolved": "https://registry.npmjs.org/@tscircuit/soup/-/soup-0.0.8.tgz",
126
+ "integrity": "sha512-juZxNOauOxcB63c9u8UtMr8cIN0O1J/d6w3GC/MfsRe+y49lvs7GNtnddmD23pQqgxNOwg0FFObOuL2uEfHIaA==",
127
+ "dependencies": {
128
+ "convert-units": "^2.3.4",
129
+ "zod": "^3.23.6"
130
+ }
131
+ },
98
132
  "node_modules/@tscircuit/routing": {
99
133
  "version": "1.3.1",
100
134
  "resolved": "https://registry.npmjs.org/@tscircuit/routing/-/routing-1.3.1.tgz",
@@ -116,15 +150,35 @@
116
150
  "use-mouse-matrix-transform": "^1.1.12"
117
151
  }
118
152
  },
153
+ "node_modules/@tscircuit/soup": {
154
+ "version": "0.0.17",
155
+ "resolved": "https://registry.npmjs.org/@tscircuit/soup/-/soup-0.0.17.tgz",
156
+ "integrity": "sha512-kOXChvI5UNImuEJ1L2SrJ0F1a1CoCtzBBto5Ssg4a+8liO763L8Yk25gsdcHeBv2O6g9sEPB+DSoxutXR/RGhg==",
157
+ "dependencies": {
158
+ "convert-units": "^2.3.4",
159
+ "zod": "^3.23.6"
160
+ }
161
+ },
119
162
  "node_modules/@tscircuit/soup-util": {
120
- "version": "0.0.1",
121
- "resolved": "https://registry.npmjs.org/@tscircuit/soup-util/-/soup-util-0.0.1.tgz",
122
- "integrity": "sha512-hNJayJ/Z+Clms1uAv8j6TCkK2aVNrm/C0PnAUcbSMY3gZfA+os7ovTxS/hCJfC22K4wHoBwsbZ+mE8R3KxaFfQ==",
163
+ "version": "0.0.10",
164
+ "resolved": "https://registry.npmjs.org/@tscircuit/soup-util/-/soup-util-0.0.10.tgz",
165
+ "integrity": "sha512-mwZS7C6f6wjp20g77GucXZ8VrzNsIZxqRQjGitvLUK7y+n3xd7iKb/eP5QDM0PldbidTDC/RR/A46MhJLz0Rhg==",
166
+ "dependencies": {
167
+ "@tscircuit/soup": "^0.0.15"
168
+ },
123
169
  "peerDependencies": {
124
- "@tscircuit/builder": "*",
125
170
  "zod": "*"
126
171
  }
127
172
  },
173
+ "node_modules/@tscircuit/soup-util/node_modules/@tscircuit/soup": {
174
+ "version": "0.0.15",
175
+ "resolved": "https://registry.npmjs.org/@tscircuit/soup/-/soup-0.0.15.tgz",
176
+ "integrity": "sha512-lMCjcIztiYjBDNNEcMFtwgosUTbget2arwqkRVCAjRP8G+r6gjUNhVLcMyN3cZGdLpHce8lm/h2kE4tYO4S7GA==",
177
+ "dependencies": {
178
+ "convert-units": "^2.3.4",
179
+ "zod": "^3.23.6"
180
+ }
181
+ },
128
182
  "node_modules/@tscircuit/sparkfun-packages": {
129
183
  "version": "1.2.1",
130
184
  "resolved": "https://registry.npmjs.org/@tscircuit/sparkfun-packages/-/sparkfun-packages-1.2.1.tgz",
@@ -499,6 +553,27 @@
499
553
  "parse-svg-path": "^0.1.2"
500
554
  }
501
555
  },
556
+ "node_modules/to-no-case": {
557
+ "version": "1.0.2",
558
+ "resolved": "https://registry.npmjs.org/to-no-case/-/to-no-case-1.0.2.tgz",
559
+ "integrity": "sha512-Z3g735FxuZY8rodxV4gH7LxClE4H0hTIyHNIHdk+vpQxjLm0cwnKXq/OFVZ76SOQmto7txVcwSCwkU5kqp+FKg=="
560
+ },
561
+ "node_modules/to-snake-case": {
562
+ "version": "1.0.0",
563
+ "resolved": "https://registry.npmjs.org/to-snake-case/-/to-snake-case-1.0.0.tgz",
564
+ "integrity": "sha512-joRpzBAk1Bhi2eGEYBjukEWHOe/IvclOkiJl3DtA91jV6NwQ3MwXA4FHYeqk8BNp/D8bmi9tcNbRu/SozP0jbQ==",
565
+ "dependencies": {
566
+ "to-space-case": "^1.0.0"
567
+ }
568
+ },
569
+ "node_modules/to-space-case": {
570
+ "version": "1.0.0",
571
+ "resolved": "https://registry.npmjs.org/to-space-case/-/to-space-case-1.0.0.tgz",
572
+ "integrity": "sha512-rLdvwXZ39VOn1IxGL3V6ZstoTbwLRckQmn/U8ZDLuWwIXNpuZDhQ3AiRUlhTbOXFVE9C+dR51wM0CBDhk31VcA==",
573
+ "dependencies": {
574
+ "to-no-case": "^1.0.0"
575
+ }
576
+ },
502
577
  "node_modules/transformation-matrix": {
503
578
  "version": "2.16.1",
504
579
  "resolved": "https://registry.npmjs.org/transformation-matrix/-/transformation-matrix-2.16.1.tgz",
@@ -532,10 +607,9 @@
532
607
  }
533
608
  },
534
609
  "node_modules/zod": {
535
- "version": "3.23.6",
536
- "resolved": "https://registry.npmjs.org/zod/-/zod-3.23.6.tgz",
537
- "integrity": "sha512-RTHJlZhsRbuA8Hmp/iNL7jnfc4nZishjsanDAfEY1QpDQZCahUp3xDzl+zfweE9BklxMUcgBgS1b7Lvie/ZVwA==",
538
- "peer": true,
610
+ "version": "3.23.8",
611
+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.23.8.tgz",
612
+ "integrity": "sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==",
539
613
  "funding": {
540
614
  "url": "https://github.com/sponsors/colinhacks"
541
615
  }
@@ -4,7 +4,8 @@
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "dependencies": {
7
- "@tscircuit/builder": "^1.5.87",
8
- "@tscircuit/react-fiber": "^1.0.39"
7
+ "@tscircuit/builder": "^1.5.92",
8
+ "@tscircuit/layout": "^0.0.12",
9
+ "@tscircuit/react-fiber": "^1.1.12"
9
10
  }
10
11
  }
@@ -6,16 +6,16 @@ export const MyCircuit = () => (
6
6
  <board
7
7
  width="40mm"
8
8
  height="40mm"
9
- center_x={0}
10
- center_y={0}
11
- layout={layout().manualPcbPlacement(manual_edits.pcb_placements)}
9
+ pcbCenterX={0}
10
+ pcbCenterY={0}
11
+ layout={layout().manualEdits(manual_edits)}
12
12
  >
13
13
  <resistor
14
14
  name="R1"
15
15
  resistance="20kohm"
16
16
  footprint="0805"
17
- supplier_part_numbers={{
18
- jlcpcb: "C2759650",
17
+ supplierPartNumbers={{
18
+ jlcpcb: ["C2759650"],
19
19
  }}
20
20
  />
21
21
  </board>