@modular-circuit/transpiler 0.1.2 → 0.1.3

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.d.mts CHANGED
@@ -463,7 +463,7 @@ declare class StringFormatter {
463
463
  }
464
464
 
465
465
  interface NamedContent {
466
- name: string;
466
+ filename: string;
467
467
  content: string;
468
468
  }
469
469
  interface DesignBlock {
package/dist/index.d.ts CHANGED
@@ -463,7 +463,7 @@ declare class StringFormatter {
463
463
  }
464
464
 
465
465
  interface NamedContent {
466
- name: string;
466
+ filename: string;
467
467
  content: string;
468
468
  }
469
469
  interface DesignBlock {
package/dist/index.js CHANGED
@@ -315,16 +315,16 @@ async function collect_sub_sheets_by_id(module_ids, module_resolver) {
315
315
  const files = await (0, import_utils2.unzipFile)(zip_archive);
316
316
  for (const [name, content] of Object.entries(files)) {
317
317
  if (name.endsWith(import_utils2.KICAD_SHC_FILE_EXT)) {
318
- const fileName = (0, import_utils2.remove_filename_path_prefix)(name);
319
- if (fileName in sheets) {
320
- console.error(`Duplicate sheet name: ${fileName}`);
318
+ const filename = (0, import_utils2.remove_filename_path_prefix)(name);
319
+ if (filename in sheets) {
320
+ console.error(`Duplicate sheet name: ${filename}`);
321
321
  continue;
322
322
  }
323
- sheets[fileName] = content;
324
- design_block.sheets.push({ name: fileName, content });
323
+ sheets[filename] = content;
324
+ design_block.sheets.push({ filename, content });
325
325
  } else if (name.endsWith(import_utils2.KICAD_PCB_FILE_EXT)) {
326
- const fileName = (0, import_utils2.remove_filename_path_prefix)(name);
327
- design_block.pcb = { name: fileName, content };
326
+ const filename = (0, import_utils2.remove_filename_path_prefix)(name);
327
+ design_block.pcb = { filename, content };
328
328
  }
329
329
  }
330
330
  }
package/dist/index.mjs CHANGED
@@ -202,16 +202,16 @@ async function collect_sub_sheets_by_id(module_ids, module_resolver) {
202
202
  const files = await unzipFile2(zip_archive);
203
203
  for (const [name, content] of Object.entries(files)) {
204
204
  if (name.endsWith(KICAD_SHC_FILE_EXT2)) {
205
- const fileName = remove_filename_path_prefix2(name);
206
- if (fileName in sheets) {
207
- console.error(`Duplicate sheet name: ${fileName}`);
205
+ const filename = remove_filename_path_prefix2(name);
206
+ if (filename in sheets) {
207
+ console.error(`Duplicate sheet name: ${filename}`);
208
208
  continue;
209
209
  }
210
- sheets[fileName] = content;
211
- design_block.sheets.push({ name: fileName, content });
210
+ sheets[filename] = content;
211
+ design_block.sheets.push({ filename, content });
212
212
  } else if (name.endsWith(KICAD_PCB_FILE_EXT)) {
213
- const fileName = remove_filename_path_prefix2(name);
214
- design_block.pcb = { name: fileName, content };
213
+ const filename = remove_filename_path_prefix2(name);
214
+ design_block.pcb = { filename, content };
215
215
  }
216
216
  }
217
217
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@modular-circuit/transpiler",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "Intermediate representation of the modular circuit",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",