easyeda 0.0.132 → 0.0.134
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.
|
@@ -3262,9 +3262,9 @@ var convertEasyEdaJsonToVariousFormats = async ({
|
|
|
3262
3262
|
};
|
|
3263
3263
|
|
|
3264
3264
|
export {
|
|
3265
|
+
fetchEasyEDAComponent,
|
|
3265
3266
|
convertEasyEdaJsonToCircuitJson,
|
|
3266
3267
|
convertEasyEdaJsonToTscircuitSoupJson,
|
|
3267
|
-
fetchEasyEDAComponent,
|
|
3268
3268
|
maybeNumber,
|
|
3269
3269
|
SzlcscSchema,
|
|
3270
3270
|
LcscSchema,
|
|
@@ -3281,4 +3281,4 @@ export {
|
|
|
3281
3281
|
convertRawEasyToTsx,
|
|
3282
3282
|
convertEasyEdaJsonToVariousFormats
|
|
3283
3283
|
};
|
|
3284
|
-
//# sourceMappingURL=chunk-
|
|
3284
|
+
//# sourceMappingURL=chunk-SMM32IOL.js.map
|
package/dist/cli/main.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {
|
|
3
3
|
convertEasyEdaJsonToVariousFormats,
|
|
4
4
|
fetchEasyEDAComponent
|
|
5
|
-
} from "../chunk-
|
|
5
|
+
} from "../chunk-SMM32IOL.js";
|
|
6
6
|
|
|
7
7
|
// cli/main.ts
|
|
8
8
|
import { Command } from "commander";
|
|
@@ -12,7 +12,7 @@ import fs from "fs/promises";
|
|
|
12
12
|
var package_default = {
|
|
13
13
|
name: "easyeda",
|
|
14
14
|
type: "module",
|
|
15
|
-
version: "0.0.
|
|
15
|
+
version: "0.0.133",
|
|
16
16
|
files: [
|
|
17
17
|
"dist"
|
|
18
18
|
],
|
|
@@ -43,7 +43,7 @@ var package_default = {
|
|
|
43
43
|
devDependencies: {
|
|
44
44
|
"@biomejs/biome": "^1.9.4",
|
|
45
45
|
"@tscircuit/log-soup": "1.0.2",
|
|
46
|
-
"@tscircuit/props": "^0.0.
|
|
46
|
+
"@tscircuit/props": "^0.0.172",
|
|
47
47
|
"@tscircuit/soup-util": "^0.0.41",
|
|
48
48
|
"@types/bun": "latest",
|
|
49
49
|
"bun-match-svg": "^0.0.6",
|
package/dist/cli/main.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../cli/main.ts","../../package.json"],"sourcesContent":["#!/usr/bin/env node\n\nimport { Command } from \"commander\"\nimport { fetchEasyEDAComponent } from \"../lib/websafe/fetch-easyeda-json\"\nimport { convertEasyEdaJsonToTscircuitSoupJson } from \"../lib/convert-easyeda-json-to-tscircuit-soup-json\"\nimport fs from \"fs/promises\"\nimport packageJson from \"../package.json\"\nimport { EasyEdaJsonSchema } from \"lib/schemas/easy-eda-json-schema\"\nimport { convertRawEasyToTsx } from \"lib/websafe/convert-to-typescript-component\"\nimport * as path from \"path\"\nimport { normalizeManufacturerPartNumber } from \"lib\"\nimport { convertEasyEdaJsonToVariousFormats } from \"lib/convert-easyeda-json-to-various-formats\"\n\nconst program = new Command()\n\nprogram\n .name(\"easyeda\")\n .description(\"Convert EasyEDA JSON PCB footprints into various formats\")\n .version(packageJson.version)\n\nprogram\n .command(\"convert\")\n .description(\"Convert EasyEDA JSON to various formats\")\n .option(\"-i, --input <jlcpcbPartNumber>\", \"JLCPCB part number\")\n .option(\"-o, --output <filename>\", \"Output filename\")\n .option(\n \"--output-format <format>\",\n \"Output format (can be inferred from filename)\",\n )\n .action(async (options) => {\n await convertEasyEdaJsonToVariousFormats({\n jlcpcbPartNumberOrFilepath: options.input,\n outputFilename: options.output,\n outputFormat: options.outputFormat,\n })\n })\n\nprogram\n .command(\"download\")\n .description(\"Download JSON for footprint\")\n .requiredOption(\"-i, --input <jlcpcbPartNumber>\", \"JLCPCB part number\")\n .option(\"-o, --output <filename>\", \"Output filename\")\n .action(async (options) => {\n if (!options.output) {\n options.output = `${options.input}.raweasy.json`\n }\n try {\n const easyEdaJsonRes = await fetchEasyEDAComponent(options.input)\n await fs.writeFile(\n options.output,\n JSON.stringify(easyEdaJsonRes, null, 2),\n )\n console.log(`Downloaded JSON footprint: ${options.output}`)\n } catch (error: any) {\n console.error(\"Error:\", error.message)\n }\n })\n\nprogram.parse(process.argv)\n// perfectCli(program, process.argv)\n","{\n \"name\": \"easyeda\",\n \"type\": \"module\",\n \"version\": \"0.0.
|
|
1
|
+
{"version":3,"sources":["../../cli/main.ts","../../package.json"],"sourcesContent":["#!/usr/bin/env node\n\nimport { Command } from \"commander\"\nimport { fetchEasyEDAComponent } from \"../lib/websafe/fetch-easyeda-json\"\nimport { convertEasyEdaJsonToTscircuitSoupJson } from \"../lib/convert-easyeda-json-to-tscircuit-soup-json\"\nimport fs from \"fs/promises\"\nimport packageJson from \"../package.json\"\nimport { EasyEdaJsonSchema } from \"lib/schemas/easy-eda-json-schema\"\nimport { convertRawEasyToTsx } from \"lib/websafe/convert-to-typescript-component\"\nimport * as path from \"path\"\nimport { normalizeManufacturerPartNumber } from \"lib\"\nimport { convertEasyEdaJsonToVariousFormats } from \"lib/convert-easyeda-json-to-various-formats\"\n\nconst program = new Command()\n\nprogram\n .name(\"easyeda\")\n .description(\"Convert EasyEDA JSON PCB footprints into various formats\")\n .version(packageJson.version)\n\nprogram\n .command(\"convert\")\n .description(\"Convert EasyEDA JSON to various formats\")\n .option(\"-i, --input <jlcpcbPartNumber>\", \"JLCPCB part number\")\n .option(\"-o, --output <filename>\", \"Output filename\")\n .option(\n \"--output-format <format>\",\n \"Output format (can be inferred from filename)\",\n )\n .action(async (options) => {\n await convertEasyEdaJsonToVariousFormats({\n jlcpcbPartNumberOrFilepath: options.input,\n outputFilename: options.output,\n outputFormat: options.outputFormat,\n })\n })\n\nprogram\n .command(\"download\")\n .description(\"Download JSON for footprint\")\n .requiredOption(\"-i, --input <jlcpcbPartNumber>\", \"JLCPCB part number\")\n .option(\"-o, --output <filename>\", \"Output filename\")\n .action(async (options) => {\n if (!options.output) {\n options.output = `${options.input}.raweasy.json`\n }\n try {\n const easyEdaJsonRes = await fetchEasyEDAComponent(options.input)\n await fs.writeFile(\n options.output,\n JSON.stringify(easyEdaJsonRes, null, 2),\n )\n console.log(`Downloaded JSON footprint: ${options.output}`)\n } catch (error: any) {\n console.error(\"Error:\", error.message)\n }\n })\n\nprogram.parse(process.argv)\n// perfectCli(program, process.argv)\n","{\n \"name\": \"easyeda\",\n \"type\": \"module\",\n \"version\": \"0.0.133\",\n \"files\": [\n \"dist\"\n ],\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/tscircuit/easyeda-converter\"\n },\n \"scripts\": {\n \"test\": \"bun test\",\n \"cli\": \"bun cli/main.ts\",\n \"build\": \"bun build:node && bun build:web\",\n \"build:node\": \"tsup lib/index.ts cli/main.ts --platform node --format esm --dts --sourcemap\",\n \"build:web\": \"tsup lib/websafe/index.ts --platform browser --format esm --dts --sourcemap -d dist/browser\",\n \"aider\": \"aider\",\n \"format:check\": \"biome format .\",\n \"format\": \"biome format . --write\",\n \"add-test-for-part\": \"bun run scripts/add-test-for-part.ts\"\n },\n \"main\": \"./dist/lib/index.js\",\n \"exports\": {\n \".\": \"./dist/lib/index.js\",\n \"./browser\": \"./dist/browser/index.js\"\n },\n \"bin\": {\n \"easyeda-converter\": \"./dist/cli/main.js\",\n \"easyeda\": \"./dist/cli/main.js\"\n },\n \"devDependencies\": {\n \"@biomejs/biome\": \"^1.9.4\",\n \"@tscircuit/log-soup\": \"1.0.2\",\n \"@tscircuit/props\": \"^0.0.172\",\n \"@tscircuit/soup-util\": \"^0.0.41\",\n \"@types/bun\": \"latest\",\n \"bun-match-svg\": \"^0.0.6\",\n \"circuit-json\": \"^0.0.153\",\n \"circuit-to-svg\": \"^0.0.56\",\n \"tsup\": \"^8.4.0\"\n },\n \"peerDependencies\": {\n \"typescript\": \"^5.5.2\"\n },\n \"dependencies\": {\n \"@tscircuit/mm\": \"^0.0.8\",\n \"commander\": \"^12.1.0\",\n \"transformation-matrix\": \"^2.16.1\",\n \"zod\": \"^3.24.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