@tscircuit/core 0.0.442 → 0.0.443
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 +11 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -481,6 +481,11 @@ var preprocessSelector = (selector) => {
|
|
|
481
481
|
'Net names cannot contain a period, try using "sel.net..." to autocomplete with conventional net names, e.g. V3_3'
|
|
482
482
|
);
|
|
483
483
|
}
|
|
484
|
+
if (/net\.[0-9]/.test(selector)) {
|
|
485
|
+
throw new Error(
|
|
486
|
+
'Net names cannot start with a number, try using a prefix like "VBUS1"'
|
|
487
|
+
);
|
|
488
|
+
}
|
|
484
489
|
return selector.replace(/ pin/g, " port").replace(/ subcircuit\./g, " group[isSubcircuit=true]").replace(/([^ ])\>([^ ])/g, "$1 > $2").replace(
|
|
485
490
|
/(^|[ >])(?!pin\.)(?!port\.)(?!net\.)([A-Z][A-Za-z0-9_-]*)\.([A-Za-z0-9_-]+)/g,
|
|
486
491
|
(_, sep, name, pin) => {
|
|
@@ -1607,6 +1612,11 @@ var createNetsFromProps = (component, props) => {
|
|
|
1607
1612
|
'Net names cannot contain a period, try using "sel.net..." to autocomplete with conventional net names, e.g. V3_3'
|
|
1608
1613
|
);
|
|
1609
1614
|
}
|
|
1615
|
+
if (/net\.[0-9]/.test(prop)) {
|
|
1616
|
+
throw new Error(
|
|
1617
|
+
'Net names cannot start with a number, try using a prefix like "VBUS1"'
|
|
1618
|
+
);
|
|
1619
|
+
}
|
|
1610
1620
|
const subcircuit = component.getSubcircuit();
|
|
1611
1621
|
if (!subcircuit.selectOne(prop)) {
|
|
1612
1622
|
const net = new Net({
|
|
@@ -9397,7 +9407,7 @@ import { identity as identity4 } from "transformation-matrix";
|
|
|
9397
9407
|
var package_default = {
|
|
9398
9408
|
name: "@tscircuit/core",
|
|
9399
9409
|
type: "module",
|
|
9400
|
-
version: "0.0.
|
|
9410
|
+
version: "0.0.442",
|
|
9401
9411
|
types: "dist/index.d.ts",
|
|
9402
9412
|
main: "dist/index.js",
|
|
9403
9413
|
module: "dist/index.js",
|