easyeda 0.0.20 → 0.0.21
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/cli/main.cjs +10 -8
- package/dist/cli/main.cjs.map +1 -1
- package/dist/lib/index.cjs +14 -10
- package/dist/lib/index.cjs.map +1 -1
- package/dist/lib/index.d.cts +3 -1
- package/package.json +1 -1
package/dist/cli/main.cjs
CHANGED
|
@@ -29595,6 +29595,16 @@ export const use${componentName} = createUseComponent(${componentName}, pinNames
|
|
|
29595
29595
|
`.trim();
|
|
29596
29596
|
};
|
|
29597
29597
|
|
|
29598
|
+
// lib/utils/normalize-manufacturer-part-number.ts
|
|
29599
|
+
function normalizeManufacturerPartNumber(partNumber) {
|
|
29600
|
+
let normalized = partNumber.replace(/-/g, "_");
|
|
29601
|
+
normalized = normalized.replace(/[^a-zA-Z0-9_$]/g, "");
|
|
29602
|
+
if (/^\d/.test(normalized)) {
|
|
29603
|
+
normalized = "A" + normalized;
|
|
29604
|
+
}
|
|
29605
|
+
return normalized;
|
|
29606
|
+
}
|
|
29607
|
+
|
|
29598
29608
|
// lib/convert-to-typescript-component/index.tsx
|
|
29599
29609
|
var convertRawEasyEdaToTs = (rawEasy) => {
|
|
29600
29610
|
const easyeda = EasyEdaJsonSchema.parse(rawEasy);
|
|
@@ -29642,14 +29652,6 @@ var convertToTypescriptComponent = ({
|
|
|
29642
29652
|
easyEdaJson
|
|
29643
29653
|
});
|
|
29644
29654
|
};
|
|
29645
|
-
function normalizeManufacturerPartNumber(partNumber) {
|
|
29646
|
-
let normalized = partNumber.replace(/-/g, "_");
|
|
29647
|
-
normalized = normalized.replace(/[^a-zA-Z0-9_$]/g, "");
|
|
29648
|
-
if (/^\d/.test(normalized)) {
|
|
29649
|
-
normalized = "A" + normalized;
|
|
29650
|
-
}
|
|
29651
|
-
return normalized;
|
|
29652
|
-
}
|
|
29653
29655
|
|
|
29654
29656
|
// cli/main.ts
|
|
29655
29657
|
var path = __toESM(require("path"), 1);
|