schematex 0.9.9 → 0.9.11

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.
Files changed (87) hide show
  1. package/dist/ai/ai-sdk.cjs +9 -9
  2. package/dist/ai/ai-sdk.d.cts +3 -3
  3. package/dist/ai/ai-sdk.d.ts +3 -3
  4. package/dist/ai/ai-sdk.js +4 -4
  5. package/dist/ai/index.cjs +18 -18
  6. package/dist/ai/index.d.cts +4 -4
  7. package/dist/ai/index.d.ts +4 -4
  8. package/dist/ai/index.js +5 -5
  9. package/dist/{api-D_d-JklT.d.ts → api-DAiP83-P.d.ts} +1 -1
  10. package/dist/{api-DnTyW-6F.d.cts → api-DecITB-t.d.cts} +1 -1
  11. package/dist/browser.cjs +10 -10
  12. package/dist/browser.d.cts +3 -3
  13. package/dist/browser.d.ts +3 -3
  14. package/dist/browser.js +4 -4
  15. package/dist/{chunk-IHX6J4HF.js → chunk-32LOZTNP.js} +178 -4
  16. package/dist/chunk-32LOZTNP.js.map +1 -0
  17. package/dist/{chunk-RCR4UGKV.js → chunk-4QBC4475.js} +35 -20
  18. package/dist/chunk-4QBC4475.js.map +1 -0
  19. package/dist/{chunk-OY2CXLVY.cjs → chunk-5YTFNOKY.cjs} +170 -15
  20. package/dist/{chunk-OY2CXLVY.cjs.map → chunk-5YTFNOKY.cjs.map} +1 -1
  21. package/dist/{chunk-EUN6FEGE.cjs → chunk-6ZTPWE22.cjs} +37 -22
  22. package/dist/chunk-6ZTPWE22.cjs.map +1 -0
  23. package/dist/{chunk-TXWVJAMR.cjs → chunk-HEGDKO2E.cjs} +178 -4
  24. package/dist/chunk-HEGDKO2E.cjs.map +1 -0
  25. package/dist/{chunk-T5QOVX2I.js → chunk-RU3N57OB.js} +168 -13
  26. package/dist/{chunk-T5QOVX2I.js.map → chunk-RU3N57OB.js.map} +1 -1
  27. package/dist/{chunk-MVTYPWHO.js → chunk-WTGABYFK.js} +80 -17
  28. package/dist/chunk-WTGABYFK.js.map +1 -0
  29. package/dist/{chunk-MXV3XJFH.cjs → chunk-YN7EBTWB.cjs} +80 -17
  30. package/dist/chunk-YN7EBTWB.cjs.map +1 -0
  31. package/dist/{diagnostics-D2qkBfFx.d.cts → diagnostics-Bps9pzlF.d.cts} +8 -2
  32. package/dist/{diagnostics-D2qkBfFx.d.ts → diagnostics-Bps9pzlF.d.ts} +8 -2
  33. package/dist/diagrams/blockdiagram/index.d.cts +1 -1
  34. package/dist/diagrams/blockdiagram/index.d.ts +1 -1
  35. package/dist/diagrams/circuit/index.cjs +8 -8
  36. package/dist/diagrams/circuit/index.d.cts +1 -1
  37. package/dist/diagrams/circuit/index.d.ts +1 -1
  38. package/dist/diagrams/circuit/index.js +1 -1
  39. package/dist/diagrams/ecomap/index.d.cts +1 -1
  40. package/dist/diagrams/ecomap/index.d.ts +1 -1
  41. package/dist/diagrams/entity/index.d.cts +1 -1
  42. package/dist/diagrams/entity/index.d.ts +1 -1
  43. package/dist/diagrams/fishbone/index.d.cts +1 -1
  44. package/dist/diagrams/fishbone/index.d.ts +1 -1
  45. package/dist/diagrams/flowchart/index.d.cts +2 -2
  46. package/dist/diagrams/flowchart/index.d.ts +2 -2
  47. package/dist/diagrams/genogram/index.d.cts +1 -1
  48. package/dist/diagrams/genogram/index.d.ts +1 -1
  49. package/dist/diagrams/ladder/index.d.cts +1 -1
  50. package/dist/diagrams/ladder/index.d.ts +1 -1
  51. package/dist/diagrams/logic/index.d.cts +1 -1
  52. package/dist/diagrams/logic/index.d.ts +1 -1
  53. package/dist/diagrams/orgchart/index.d.cts +1 -1
  54. package/dist/diagrams/orgchart/index.d.ts +1 -1
  55. package/dist/diagrams/pedigree/index.d.cts +1 -1
  56. package/dist/diagrams/pedigree/index.d.ts +1 -1
  57. package/dist/diagrams/phylo/index.d.cts +1 -1
  58. package/dist/diagrams/phylo/index.d.ts +1 -1
  59. package/dist/diagrams/sld/index.cjs +7 -7
  60. package/dist/diagrams/sld/index.d.cts +4 -1
  61. package/dist/diagrams/sld/index.d.ts +4 -1
  62. package/dist/diagrams/sld/index.js +1 -1
  63. package/dist/diagrams/sociogram/index.d.cts +1 -1
  64. package/dist/diagrams/sociogram/index.d.ts +1 -1
  65. package/dist/diagrams/timing/index.d.cts +1 -1
  66. package/dist/diagrams/timing/index.d.ts +1 -1
  67. package/dist/diagrams/venn/index.d.cts +1 -1
  68. package/dist/diagrams/venn/index.d.ts +1 -1
  69. package/dist/{index-D9u0YRxL.d.ts → index-F6MCisQe.d.ts} +1 -1
  70. package/dist/{index-JZlLiE6K.d.cts → index-fvBAmlv7.d.cts} +1 -1
  71. package/dist/index.cjs +43 -43
  72. package/dist/index.d.cts +4 -4
  73. package/dist/index.d.ts +4 -4
  74. package/dist/index.js +6 -6
  75. package/dist/react.cjs +4 -4
  76. package/dist/react.d.cts +2 -2
  77. package/dist/react.d.ts +2 -2
  78. package/dist/react.js +3 -3
  79. package/dist/{tools-DM0aLCbc.d.ts → tools-CdzIw2Az.d.ts} +2 -2
  80. package/dist/{tools-DAKYNcPv.d.cts → tools-vyVK2DHa.d.cts} +2 -2
  81. package/package.json +1 -1
  82. package/dist/chunk-EUN6FEGE.cjs.map +0 -1
  83. package/dist/chunk-IHX6J4HF.js.map +0 -1
  84. package/dist/chunk-MVTYPWHO.js.map +0 -1
  85. package/dist/chunk-MXV3XJFH.cjs.map +0 -1
  86. package/dist/chunk-RCR4UGKV.js.map +0 -1
  87. package/dist/chunk-TXWVJAMR.cjs.map +0 -1
@@ -1,8 +1,8 @@
1
1
  import { orgchart } from './chunk-EB7T5SEO.js';
2
- import { circuit } from './chunk-IHX6J4HF.js';
2
+ import { circuit } from './chunk-32LOZTNP.js';
3
3
  import { blockdiagram } from './chunk-P4U565XH.js';
4
4
  import { ladder } from './chunk-W4UVDMUC.js';
5
- import { sld } from './chunk-MVTYPWHO.js';
5
+ import { sld } from './chunk-WTGABYFK.js';
6
6
  import { entity } from './chunk-2IRYXK4M.js';
7
7
  import { fishbone } from './chunk-NP7N3DZG.js';
8
8
  import { venn } from './chunk-KUSW5I2P.js';
@@ -33514,30 +33514,42 @@ var KIND_ALIASES2 = {
33514
33514
  diode: "diode",
33515
33515
  button: "button",
33516
33516
  dip: "dip",
33517
- header: "header"
33517
+ header: "header",
33518
+ pot: "potentiometer",
33519
+ potentiometer: "potentiometer"
33518
33520
  // multi-token forms handled separately: "mcu uno", "sensor hcsr04", etc.
33519
33521
  };
33520
33522
  var MCU_SUBTYPES = {
33521
33523
  uno: "mcu-uno",
33522
33524
  nano: "mcu-nano",
33523
33525
  esp32: "mcu-esp32",
33526
+ "esp32-devkit": "mcu-esp32",
33527
+ "esp32-c3": "mcu-esp32",
33528
+ "esp32-s3": "mcu-esp32",
33524
33529
  pico: "mcu-pico"
33525
33530
  };
33526
33531
  var SENSOR_SUBTYPES = {
33527
33532
  hcsr04: "sensor-hcsr04",
33528
33533
  "hc-sr04": "sensor-hcsr04",
33529
33534
  dht11: "sensor-dht11",
33530
- dht22: "sensor-dht22"
33535
+ dht22: "sensor-dht22",
33536
+ vl53l0x: "sensor-vl53l0x",
33537
+ "vl53-l0x": "sensor-vl53l0x",
33538
+ tof: "sensor-vl53l0x"
33531
33539
  };
33532
33540
  var DISPLAY_SUBTYPES = {
33533
33541
  "oled-ssd1306": "display-oled-ssd1306",
33534
33542
  oled: "display-oled-ssd1306",
33535
33543
  "lcd-1602-i2c": "display-lcd-1602-i2c",
33536
- lcd: "display-lcd-1602-i2c"
33544
+ lcd: "display-lcd-1602-i2c",
33545
+ tm1637: "display-tm1637"
33537
33546
  };
33538
33547
  var MODULE_SUBTYPES = {
33539
33548
  "rotary-ky040": "module-rotary-ky040",
33540
- rotary: "module-rotary-ky040"
33549
+ rotary: "module-rotary-ky040",
33550
+ l298n: "module-l298n",
33551
+ "l298": "module-l298n",
33552
+ motor: "module-l298n"
33541
33553
  };
33542
33554
  var ACTUATOR_SUBTYPES = {
33543
33555
  "servo-sg90": "actuator-servo-sg90",
@@ -34134,12 +34146,16 @@ var PART_CATALOG = {
34134
34146
  "mcu-nano": mcuSpec("mcu-nano", "#0d9488", "Arduino Nano", UNO_SLOTS.slice(0, 18), { width: 90, height: 180, cornerR: 4 }),
34135
34147
  "mcu-esp32": mcuSpec("mcu-esp32", "#1e293b", "ESP32 DevKit", ESP32_SLOTS, { width: 110, height: 180, cornerR: 4 }),
34136
34148
  "mcu-pico": mcuSpec("mcu-pico", "#1e3a8a", "Raspberry Pi Pico", ESP32_SLOTS, { width: 100, height: 180, cornerR: 4 }),
34149
+ potentiometer: moduleSpec("potentiometer", 54, 46, "#eab308", ["1", "2", "3"], "POT"),
34137
34150
  "sensor-hcsr04": moduleSpec("sensor-hcsr04", 100, 60, "#1e3a8a", ["VCC", "TRIG", "ECHO", "GND"], "HC-SR04"),
34138
34151
  "sensor-dht11": moduleSpec("sensor-dht11", 70, 60, "#1e40af", ["VCC", "DATA", "GND"], "DHT11"),
34139
34152
  "sensor-dht22": moduleSpec("sensor-dht22", 70, 60, "#1e40af", ["VCC", "DATA", "GND"], "DHT22"),
34153
+ "sensor-vl53l0x": moduleSpec("sensor-vl53l0x", 80, 56, "#1e3a8a", ["VIN", "GND", "SCL", "SDA"], "VL53L0X"),
34140
34154
  "display-oled-ssd1306": moduleSpec("display-oled-ssd1306", 90, 60, "#0f172a", ["GND", "VCC", "SCL", "SDA"], "OLED 128\xD764"),
34141
34155
  "display-lcd-1602-i2c": moduleSpec("display-lcd-1602-i2c", 130, 60, "#166534", ["GND", "VCC", "SDA", "SCL"], "LCD 1602 I\xB2C"),
34156
+ "display-tm1637": moduleSpec("display-tm1637", 84, 52, "#7c2d12", ["CLK", "DIO", "VCC", "GND"], "TM1637"),
34142
34157
  "module-rotary-ky040": moduleSpec("module-rotary-ky040", 80, 60, "#7c2d12", ["CLK", "DT", "SW", "VCC", "GND"], "KY-040"),
34158
+ "module-l298n": moduleSpec("module-l298n", 150, 72, "#991b1b", ["ENA", "IN1", "IN2", "IN3", "IN4", "ENB", "5V", "GND", "12V"], "L298N"),
34143
34159
  "actuator-servo-sg90": moduleSpec("actuator-servo-sg90", 60, 60, "#475569", ["GND", "VCC", "SIG"], "Servo SG90")
34144
34160
  };
34145
34161
  function partSpec(kind, args = {}) {
@@ -34277,6 +34293,7 @@ function placePart(sub, part, reservedSides) {
34277
34293
  }
34278
34294
  const pins2 = {};
34279
34295
  for (const p of spec.pins) pins2[p.name] = { x: x2 + p.x, y: y2 + p.y };
34296
+ addPinAliases(part.kind, pins2);
34280
34297
  if (placement === "beside-left") reservedSides.left = Math.max(reservedSides.left, spec.width + BB_CONST.MCU_GAP);
34281
34298
  if (placement === "beside-right") reservedSides.right = Math.max(reservedSides.right, spec.width + BB_CONST.MCU_GAP);
34282
34299
  if (placement === "above") reservedSides.above = Math.max(reservedSides.above, spec.height + BB_CONST.MCU_GAP);
@@ -34303,6 +34320,7 @@ function placePart(sub, part, reservedSides) {
34303
34320
  const y2 = anchorXY.y - spec.pins[0].y;
34304
34321
  const pins2 = {};
34305
34322
  for (const p of spec.pins) pins2[p.name] = { x: x2 + p.x, y: y2 + p.y };
34323
+ addPinAliases(part.kind, pins2);
34306
34324
  return { part, x: x2, y: y2, width: spec.width, height: spec.height, rotation: 0, pins: pins2 };
34307
34325
  }
34308
34326
  const x = anchorXY.x;
@@ -34313,14 +34331,69 @@ function placePart(sub, part, reservedSides) {
34313
34331
  }
34314
34332
  const pins = {};
34315
34333
  for (const p of spec.pins) pins[p.name] = { x: x + p.x, y: y + p.y };
34334
+ addPinAliases(part.kind, pins);
34316
34335
  return { part, x, y, width: spec.width, height: spec.height, rotation: 0, pins };
34317
34336
  }
34337
+ function setAlias(pins, alias, xy) {
34338
+ if (!pins[alias]) pins[alias] = xy;
34339
+ }
34340
+ function addPinAliases(kind, pins) {
34341
+ const entries = Object.entries(pins);
34342
+ for (const [name, xy] of entries) {
34343
+ setAlias(pins, name.toUpperCase(), xy);
34344
+ setAlias(pins, name.toLowerCase(), xy);
34345
+ const gpio = /^GPIO(\d+)$/i.exec(name);
34346
+ if (gpio) {
34347
+ const n = gpio[1];
34348
+ setAlias(pins, `D${n}`, xy);
34349
+ setAlias(pins, `IO${n}`, xy);
34350
+ setAlias(pins, `GP${n}`, xy);
34351
+ setAlias(pins, n, xy);
34352
+ }
34353
+ const digital = /^D(\d+)$/i.exec(name);
34354
+ if (digital) {
34355
+ const n = digital[1];
34356
+ setAlias(pins, n, xy);
34357
+ setAlias(pins, `GPIO${n}`, xy);
34358
+ setAlias(pins, `IO${n}`, xy);
34359
+ }
34360
+ }
34361
+ const alias = (canonical, ...aliases) => {
34362
+ const xy = pins[canonical];
34363
+ if (!xy) return;
34364
+ for (const a of aliases) setAlias(pins, a, xy);
34365
+ };
34366
+ alias("3V3", "3.3V", "3V", "VCC3V3", "VDD");
34367
+ alias("5V", "+5V", "VCC", "VBUS", "USB");
34368
+ alias("VIN", "5V", "+5V", "VCC", "VBUS", "USB", "RAW");
34369
+ alias("GND", "0V", "GROUND", "VSS", "COM", "-");
34370
+ alias("RST", "RESET", "EN");
34371
+ alias("A4", "SDA");
34372
+ alias("A5", "SCL");
34373
+ alias("TX", "D1", "GPIO1", "IO1");
34374
+ alias("RX", "D0", "GPIO0", "IO0");
34375
+ alias("VCC", "5V", "+5V", "VIN");
34376
+ alias("DATA", "DAT", "OUT", "SIG", "SIGNAL");
34377
+ alias("DIO", "DATA", "DAT");
34378
+ alias("CLK", "SCK", "SCLK", "CLOCK");
34379
+ alias("TRIG", "TRIGGER");
34380
+ alias("SIG", "SIGNAL", "PWM", "DATA");
34381
+ alias("1", "A", "P1");
34382
+ alias("2", "W", "WIPER", "P2");
34383
+ alias("3", "B", "P3");
34384
+ if (kind === "mcu-esp32" || kind === "mcu-pico") {
34385
+ alias("VIN", "5V", "VBUS", "USB");
34386
+ }
34387
+ }
34318
34388
  function endpointXY(ep, parts, sub) {
34319
34389
  if (ep.kind === "coord") return holeXY(sub, ep.at);
34320
34390
  const part = parts.find((p) => p.part.id === ep.partId);
34321
34391
  if (!part) throw new Error(`Wire references unknown part '${ep.partId}'`);
34322
- const pin = part.pins[ep.pin];
34323
- if (!pin) throw new Error(`Part '${ep.partId}' has no pin named '${ep.pin}'`);
34392
+ const pin = part.pins[ep.pin] ?? part.pins[ep.pin.toUpperCase()] ?? part.pins[ep.pin.toLowerCase()];
34393
+ if (!pin) {
34394
+ const known = Object.keys(part.pins).filter((name, idx, all) => all.indexOf(name) === idx).slice(0, 24).join(", ");
34395
+ throw new Error(`Part '${ep.partId}' has no pin named '${ep.pin}' (known pins: ${known})`);
34396
+ }
34324
34397
  return { x: pin.x, y: pin.y };
34325
34398
  }
34326
34399
  function bezierPath(p1, p2, via) {
@@ -38653,6 +38726,55 @@ function spiralStairs(c) {
38653
38726
  parts.push(dirArrow(c, pts, c.label ?? "UP"));
38654
38727
  return parts.join("");
38655
38728
  }
38729
+ function outletDraw(duplex) {
38730
+ return (c) => {
38731
+ const parts = [];
38732
+ const cx = c.w / 2;
38733
+ const centers = duplex ? [c.h * 0.34, c.h * 0.66] : [c.h / 2];
38734
+ parts.push(rect({ class: "sx-fp-furn-nofill", x: 0, y: 0, width: c.px(c.w), height: c.px(c.h), rx: c.px(0.04) }));
38735
+ for (const cy of centers) {
38736
+ parts.push(circle({ class: "sx-fp-furn-line", cx: c.px(cx), cy: c.px(cy), r: c.px(Math.min(c.w, c.h) * 0.16) }));
38737
+ parts.push(line({ class: "sx-fp-furn-line", x1: c.px(cx - c.w * 0.1), y1: c.px(cy), x2: c.px(cx + c.w * 0.1), y2: c.px(cy) }));
38738
+ }
38739
+ return parts.join("");
38740
+ };
38741
+ }
38742
+ function electricalSwitchDraw(c) {
38743
+ return [
38744
+ rect({ class: "sx-fp-furn-nofill", x: 0, y: 0, width: c.px(c.w), height: c.px(c.h), rx: c.px(0.04) }),
38745
+ line({ class: "sx-fp-furn-line", x1: c.px(c.w * 0.28), y1: c.px(c.h * 0.65), x2: c.px(c.w * 0.72), y2: c.px(c.h * 0.35) }),
38746
+ circle({ class: "sx-fp-furn-dot", cx: c.px(c.w * 0.28), cy: c.px(c.h * 0.65), r: c.px(0.025) })
38747
+ ].join("");
38748
+ }
38749
+ function lightDraw(label = "L") {
38750
+ return (c) => {
38751
+ const r7 = Math.min(c.w, c.h) / 2 - 0.01;
38752
+ const cx = c.w / 2;
38753
+ const cy = c.h / 2;
38754
+ return [
38755
+ circle({ class: "sx-fp-furn-nofill", cx: c.px(cx), cy: c.px(cy), r: c.px(r7) }),
38756
+ line({ class: "sx-fp-furn-line", x1: c.px(cx - r7 * 0.65), y1: c.px(cy - r7 * 0.65), x2: c.px(cx + r7 * 0.65), y2: c.px(cy + r7 * 0.65) }),
38757
+ line({ class: "sx-fp-furn-line", x1: c.px(cx + r7 * 0.65), y1: c.px(cy - r7 * 0.65), x2: c.px(cx - r7 * 0.65), y2: c.px(cy + r7 * 0.65) }),
38758
+ text({ class: "sx-fp-furn-text", x: c.px(cx), y: c.px(cy + r7 + 0.11), "text-anchor": "middle", "font-size": c.px(0.16) }, label)
38759
+ ].join("");
38760
+ };
38761
+ }
38762
+ function panelDraw(label) {
38763
+ return (c) => {
38764
+ const parts = [
38765
+ rect({ class: "sx-fp-furn", x: 0, y: 0, width: c.px(c.w), height: c.px(c.h), rx: c.px(0.03) }),
38766
+ text({
38767
+ class: "sx-fp-furn-text",
38768
+ x: c.px(c.w / 2),
38769
+ y: c.px(c.h / 2),
38770
+ "text-anchor": "middle",
38771
+ "dominant-baseline": "central",
38772
+ "font-size": c.px(Math.min(0.14, c.h * 0.45))
38773
+ }, label)
38774
+ ];
38775
+ return parts.join("");
38776
+ };
38777
+ }
38656
38778
  var FLOORPLAN_SYMBOLS = {
38657
38779
  // ── residential / living ──
38658
38780
  "bed-double": { w: 1.6, h: 2, draw: bedDraw(2) },
@@ -39527,6 +39649,15 @@ var FLOORPLAN_SYMBOLS = {
39527
39649
  return parts.join("");
39528
39650
  }
39529
39651
  },
39652
+ // ── electrical overlay fixtures ──
39653
+ outlet: { w: 0.22, h: 0.22, underlay: true, draw: outletDraw(false) },
39654
+ "duplex-outlet": { w: 0.24, h: 0.36, underlay: true, draw: outletDraw(true) },
39655
+ switch: { w: 0.24, h: 0.3, underlay: true, draw: electricalSwitchDraw },
39656
+ light: { w: 0.35, h: 0.35, underlay: true, draw: lightDraw("L") },
39657
+ "ceiling-light": { w: 0.45, h: 0.45, underlay: true, draw: lightDraw("CL") },
39658
+ "data-outlet": { w: 0.28, h: 0.24, underlay: true, draw: panelDraw("D") },
39659
+ "electrical-panel": { w: 0.55, h: 0.24, underlay: true, draw: panelDraw("PANEL") },
39660
+ "distribution-board": { w: 0.6, h: 0.28, underlay: true, draw: panelDraw("DB") },
39530
39661
  // ── site / outdoor ──
39531
39662
  // Tree in plan: a canopy disc with a foliage ring and a trunk dot.
39532
39663
  tree: {
@@ -39597,7 +39728,12 @@ function parseCoord2(t, what, ln) {
39597
39728
  }
39598
39729
  function parseDims(t, what, ln) {
39599
39730
  if (!isWord(t)) throw new FloorplanParseError(`expected "WxH" for ${what}`, ln);
39600
- const m = /^(\d*\.?\d+)x(\d*\.?\d+)$/i.exec(t.word);
39731
+ const normalized = t.word.replace("\xD7", "x");
39732
+ const m = /^(\d*\.?\d+)x(\d*\.?\d+)$/i.exec(normalized);
39733
+ if (!m && /^(\d*\.?\d+)$/.test(normalized)) {
39734
+ const v = Number(normalized);
39735
+ return { w: v, h: v };
39736
+ }
39601
39737
  if (!m) throw new FloorplanParseError(`expected "WxH" for ${what}, got "${t.word}"`, ln);
39602
39738
  return { w: Number(m[1]), h: Number(m[2]) };
39603
39739
  }
@@ -39613,15 +39749,34 @@ function parseId(t, what, ln) {
39613
39749
  }
39614
39750
  var SIDES = ["north", "south", "east", "west"];
39615
39751
  var REL_HOW = ["right-of", "left-of", "above", "below"];
39752
+ var FURNITURE_ALIASES = {
39753
+ section: "sectional",
39754
+ sectional_sofa: "sectional",
39755
+ cabinet: "wall-cabinet",
39756
+ socket: "outlet",
39757
+ receptacle: "duplex-outlet",
39758
+ "power-outlet": "duplex-outlet",
39759
+ "duplex-receptacle": "duplex-outlet",
39760
+ "light-fixture": "ceiling-light",
39761
+ "ceiling-lamp": "ceiling-light",
39762
+ lamp: "light",
39763
+ "data-socket": "data-outlet",
39764
+ "ethernet-outlet": "data-outlet",
39765
+ panel: "electrical-panel",
39766
+ "breaker-panel": "electrical-panel",
39767
+ db: "distribution-board",
39768
+ "consumer-unit": "distribution-board"
39769
+ };
39616
39770
  function parseFurnitureType(t, ln) {
39617
39771
  const word = isWord(t) ? t.word : "";
39618
- if (!FURNITURE_TYPES.includes(word)) {
39772
+ const canonical = FURNITURE_ALIASES[word] ?? word;
39773
+ if (!FURNITURE_TYPES.includes(canonical)) {
39619
39774
  throw new FloorplanParseError(
39620
39775
  `unknown furniture type "${word}". Valid types: ${FURNITURE_TYPES.join(", ")}`,
39621
39776
  ln
39622
39777
  );
39623
39778
  }
39624
- return word;
39779
+ return canonical;
39625
39780
  }
39626
39781
  function parseHeader3(tok, ast, ln) {
39627
39782
  while (tok.length) {
@@ -42702,5 +42857,5 @@ function renderWithPlugin(prepared, plugin, config) {
42702
42857
  }
42703
42858
 
42704
42859
  export { FLOORPLAN_SYMBOLS, GEOMETRY, bowtie2 as bowtie, causalloop, comparison, decisiontree, drawDeviceIcon, epc, eventtree, faulttree, fmea, gitgraph, iconSize, idef0, markov, network, parse, parseResult, pert, petri, pid, prisma, rbd, render, renderEquip, renderPreview, renderResult, sequence, state, threatmodel, timeline, umlclass, usecase, welding };
42705
- //# sourceMappingURL=chunk-T5QOVX2I.js.map
42706
- //# sourceMappingURL=chunk-T5QOVX2I.js.map
42860
+ //# sourceMappingURL=chunk-RU3N57OB.js.map
42861
+ //# sourceMappingURL=chunk-RU3N57OB.js.map