easyeda 0.0.233 → 0.0.234

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.
@@ -80251,6 +80251,14 @@ extendCatalogue({
80251
80251
  // lib/constants.ts
80252
80252
  var DEFAULT_PCB_THICKNESS_MM = 1.6;
80253
80253
 
80254
+ // lib/utils/normalize-symbol-name.ts
80255
+ var normalizeSymbolName = (name) => {
80256
+ const trimmedName = name.trim();
80257
+ if (trimmedName === "+") return "_POS";
80258
+ if (trimmedName === "-") return "_NEG";
80259
+ return trimmedName;
80260
+ };
80261
+
80254
80262
  // lib/convert-easyeda-json-to-tscircuit-soup-json.ts
80255
80263
  var mil2mm = (mil) => {
80256
80264
  if (typeof mil === "number") return mm(`${mil}mil`);
@@ -80402,7 +80410,7 @@ var convertEasyEdaJsonToCircuitJson = (easyEdaJson, { useModelCdn, shouldRecente
80402
80410
  const labels = [];
80403
80411
  if (pad2.number) labels.push(pad2.number.toString());
80404
80412
  const pin = pins.find((p2) => p2.pinNumber === pad2.number);
80405
- if (pin) labels.push(pin.label);
80413
+ if (pin) labels.push(normalizeSymbolName(pin.label));
80406
80414
  return labels;
80407
80415
  });
80408
80416
  const normalizedPinLabels = normalizePinLabels(pinLabelSets);
@@ -80569,7 +80577,7 @@ var convertEasyEdaJsonToCircuitJson = (easyEdaJson, { useModelCdn, shouldRecente
80569
80577
  type: "pcb_silkscreen_text",
80570
80578
  pcb_silkscreen_text_id: `pcb_silkscreen_text_${index + 1}`,
80571
80579
  pcb_component_id: "pcb_component_1",
80572
- text: shape.text,
80580
+ text: normalizeSymbolName(shape.text),
80573
80581
  anchor_position: {
80574
80582
  x: mil2mm(shape.x),
80575
80583
  y: mil2mm(shape.y)