@liquidcars/atlas 0.1.47 → 0.1.48

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.
@@ -11890,7 +11890,7 @@ var $c = class {
11890
11890
  }
11891
11891
  }, el = {
11892
11892
  name: "@liquidcars/atlas",
11893
- version: "0.1.47",
11893
+ version: "0.1.48",
11894
11894
  description: "Reusable 3D conceptual atlas Web Component for LiquidCars-style models",
11895
11895
  type: "module",
11896
11896
  scripts: {
@@ -12294,7 +12294,7 @@ function Wl(e, t) {
12294
12294
  let n = t?.relatedTarget;
12295
12295
  return n ? !e?.contains?.(n) : !1;
12296
12296
  }
12297
- var Gl = (e, t, n, r, i) => `<details class="toolbar-menu" data-toolbar-menu="${e}"><summary aria-label="${n}" title="${n}">${t}<span class="toolbar-menu-status" data-toolbar-status="${e}" aria-live="polite">${r}</span>${Bl.chevron}</summary><div class="toolbar-popover" role="menu"><div class="toolbar-popover-title">${n}</div>${i}</div></details>`, Kl = `<div class="toolbar-group" data-toolbar-group="copy">${Gl("copy", Bl.copy, "Copiar imagen", "PNG", Hl("copy-theme", "PNG con fondo · HD 2×") + Hl("copy-transparent", "PNG transparente · HD 2×"))}</div>`, ql = `<div class="atlas"><section class="viewport"><canvas tabindex="0" aria-label="Modelo 3D interactivo"></canvas><div class="toolbar" role="toolbar" aria-label="Controles de la vista"><div class="toolbar-group" data-toolbar-group="camera"><button class="toolbar-icon" data-action="minus" aria-label="Alejar" title="Alejar">${Bl.minus}</button><button class="toolbar-icon" data-action="plus" aria-label="Acercar" title="Acercar">${Bl.plus}</button><button class="toolbar-icon" data-action="fit" aria-label="Encuadrar todo el modelo" title="Encuadrar todo el modelo">${Bl.fit}</button><button class="toolbar-icon" data-action="front" aria-label="Vista frontal" title="Vista frontal">${Bl.front}</button></div><div class="toolbar-group" data-toolbar-group="view">${Gl("view", Bl.view, "Vista", "Vista", Vl("labels", "Etiquetas", !0) + Vl("panel", "Información", !0) + Vl("item-facing", "Caras a cámara", !0) + "<div class=\"toolbar-option-separator\"></div>" + Vl("open-all", "Abrir todos") + Vl("close-all", "Cerrar todos"))}</div><div class="toolbar-group" data-toolbar-group="relations">${Gl("relations", Bl.relations, "Relaciones", "Selección", Vl("relations-all", "Todas") + Vl("relations-selected", "Selección", !0) + Vl("relations-callers", "All callers") + Vl("relations-called", "All called") + Vl("relations-none", "Ocultar") + "<div data-relation-groups-section hidden><div class=\"toolbar-option-separator\"></div><div class=\"toolbar-popover-title\">Grupos</div><div data-relation-groups></div></div>")}</div><div class="toolbar-group" data-toolbar-group="focus">${Gl("focus", Bl.focus, "Foco", "Todo", Vl("focus-all", "Todo", !0) + Vl("focus-dim", "Conectados") + Vl("focus-hide", "Aislar") + "<div class=\"toolbar-option-separator\"></div>" + Vl("focus-selection", "Enfocar selección") + Vl("focus-layout", "Reorganizar visibles"))}</div></div><div class="hint">Gira: arrastra · Pan: botón derecho / ⇧+arrastra / 2 dedos · Zoom: rueda o pellizco · Selecciona: clic · Enfoca: doble clic</div></section><aside class="panel" aria-live="polite"></aside></div>`;
12297
+ var Gl = (e, t, n, r, i) => `<details class="toolbar-menu" data-toolbar-menu="${e}"><summary aria-label="${n}" title="${n}">${t}<span class="toolbar-menu-status" data-toolbar-status="${e}" aria-live="polite">${r}</span>${Bl.chevron}</summary><div class="toolbar-popover" role="menu"><div class="toolbar-popover-title">${n}</div>${i}</div></details>`, Kl = `<div class="toolbar-group" data-toolbar-group="copy">${Gl("copy", Bl.copy, "Copy image", "PNG", Hl("copy-theme", "PNG with background · HD 2×") + Hl("copy-transparent", "Transparent PNG · HD 2×"))}</div>`, ql = `<div class="atlas"><section class="viewport"><canvas tabindex="0" aria-label="Interactive 3D model"></canvas><div class="toolbar" role="toolbar" aria-label="View controls"><div class="toolbar-group" data-toolbar-group="camera"><button class="toolbar-icon" data-action="minus" aria-label="Zoom out" title="Zoom out">${Bl.minus}</button><button class="toolbar-icon" data-action="plus" aria-label="Zoom in" title="Zoom in">${Bl.plus}</button><button class="toolbar-icon" data-action="fit" aria-label="Fit entire model" title="Fit entire model">${Bl.fit}</button><button class="toolbar-icon" data-action="front" aria-label="Front view" title="Front view">${Bl.front}</button></div><div class="toolbar-group" data-toolbar-group="view">${Gl("view", Bl.view, "View", "View", Vl("labels", "Labels", !0) + Vl("panel", "Information", !0) + Vl("item-facing", "Face camera", !0) + "<div class=\"toolbar-option-separator\"></div>" + Vl("open-all", "Open all") + Vl("close-all", "Close all"))}</div><div class="toolbar-group" data-toolbar-group="relations">${Gl("relations", Bl.relations, "Relations", "Selection", Vl("relations-all", "All") + Vl("relations-selected", "Selection", !0) + Vl("relations-callers", "Upstream") + Vl("relations-called", "Downstream") + Vl("relations-none", "Hide") + "<div data-relation-groups-section hidden><div class=\"toolbar-option-separator\"></div><div class=\"toolbar-popover-title\">Groups</div><div data-relation-groups></div></div>")}</div><div class="toolbar-group" data-toolbar-group="focus">${Gl("focus", Bl.focus, "Focus", "All", Vl("focus-all", "All", !0) + Vl("focus-dim", "Connected") + Vl("focus-hide", "Isolate") + "<div class=\"toolbar-option-separator\"></div>" + Vl("focus-selection", "Focus selection") + Vl("focus-layout", "Reflow visible"))}</div></div><div class="hint">Rotate: drag · Pan: right button / ⇧+drag / 2 fingers · Zoom: wheel or pinch · Select: click · Focus: double-click</div></section><aside class="panel" aria-live="polite"></aside></div>`;
12298
12298
  function $(e) {
12299
12299
  return String(e ?? "").replace(/[&<>"']/g, (e) => ({
12300
12300
  "&": "&amp;",
@@ -13076,7 +13076,7 @@ var Eu = class extends HTMLElement {
13076
13076
  width: e.width,
13077
13077
  height: e.height,
13078
13078
  aspect: r
13079
- })) : this._emit("lc-print-error", { message: "No se pudo capturar el framebuffer WebGL." }), this;
13079
+ })) : this._emit("lc-print-error", { message: "Could not capture the WebGL framebuffer." }), this;
13080
13080
  }
13081
13081
  restoreAfterPrint() {
13082
13082
  let e = this._printState;
@@ -13201,7 +13201,7 @@ var Eu = class extends HTMLElement {
13201
13201
  let n = this.shadowRoot.querySelector("[data-action=\"focus-selection\"]");
13202
13202
  n && (n.disabled = !this.selected && this.selectedRelationIndex === null);
13203
13203
  let r = this.shadowRoot.querySelector("[data-toolbar-status=\"focus\"]");
13204
- r && (r.textContent = e === "all" ? "Todo" : e === "dim" ? "Conectados" : "Aislar");
13204
+ r && (r.textContent = e === "all" ? "All" : e === "dim" ? "Connected" : "Isolate");
13205
13205
  }
13206
13206
  _syncRelationToolbar() {
13207
13207
  if (!this.shadowRoot) return;
@@ -13209,19 +13209,15 @@ var Eu = class extends HTMLElement {
13209
13209
  let t = this.shadowRoot.querySelector(`[data-action="relations-${e}"]`);
13210
13210
  if (!t) continue;
13211
13211
  let n = e === this.relationMode;
13212
- t.classList.toggle("active", n), t.setAttribute("aria-pressed", String(n)), [
13213
- "selected",
13214
- "callers",
13215
- "called"
13216
- ].includes(e) && (t.disabled = !this.selected && this.selectedRelationIndex === null);
13212
+ t.classList.toggle("active", n), t.setAttribute("aria-pressed", String(n)), t.disabled = !1;
13217
13213
  }
13218
13214
  let e = this.shadowRoot.querySelector("[data-toolbar-status=\"relations\"]");
13219
13215
  e && (e.textContent = {
13220
- all: "Todas",
13221
- selected: "Selección",
13222
- callers: "All callers",
13223
- called: "All called",
13224
- none: "Ocultar"
13216
+ all: "All",
13217
+ selected: "Selection",
13218
+ callers: "Upstream",
13219
+ called: "Downstream",
13220
+ none: "Hide"
13225
13221
  }[this.relationMode]);
13226
13222
  let t = this.modelData?.relationGroups || [], n = this.shadowRoot.querySelector("[data-relation-groups-section]"), r = this.shadowRoot.querySelector("[data-relation-groups]");
13227
13223
  n && (n.hidden = t.length === 0), r && (r.innerHTML = t.map((e) => {
@@ -13364,7 +13360,7 @@ var Eu = class extends HTMLElement {
13364
13360
  }), this;
13365
13361
  }
13366
13362
  updateModel(e = {}, t = {}) {
13367
- if (!e || typeof e != "object" || Array.isArray(e)) throw TypeError("El parche del modelo debe ser un objeto.");
13363
+ if (!e || typeof e != "object" || Array.isArray(e)) throw TypeError("The model patch must be an object.");
13368
13364
  let n = this.modelData || Zl({}), r = JSON.stringify(n.render?.camera || null), i = {
13369
13365
  ...n,
13370
13366
  ...e,
@@ -13379,18 +13375,18 @@ var Eu = class extends HTMLElement {
13379
13375
  return this.modelData = Zl(i), this.theme = this.modelData.theme, this._commitModelChange("model-update", { patch: e }, t), this._applyModelRenderOptions(), JSON.stringify(this.modelData.render?.camera || null) !== r && this.modelData.render?.camera && this.setCameraView(this.modelData.render.camera, { animate: t.animateCamera !== !1 }), this;
13380
13376
  }
13381
13377
  addEntity(e, t = {}) {
13382
- if (!e || typeof e != "object" || !e.id) throw TypeError("La entidad debe incluir un id.");
13383
- if (this.modelData ||= Zl({}), this.modelData.entities.some((t) => t.id === e.id)) throw Error(`Ya existe una entidad con id "${e.id}".`);
13384
- if (e.parent && !this.modelData.entities.some((t) => t.id === e.parent)) throw Error(`No existe el contenedor padre "${e.parent}".`);
13378
+ if (!e || typeof e != "object" || !e.id) throw TypeError("The entity must include an id.");
13379
+ if (this.modelData ||= Zl({}), this.modelData.entities.some((t) => t.id === e.id)) throw Error(`An entity with id "${e.id}" already exists.`);
13380
+ if (e.parent && !this.modelData.entities.some((t) => t.id === e.parent)) throw Error(`Parent container "${e.parent}" does not exist.`);
13385
13381
  return this.modelData.entities = [...this.modelData.entities, { ...e }], this._commitModelChange("entity-add", { entity: this._publicEntity(e.id) }, t);
13386
13382
  }
13387
13383
  updateEntity(e, t = {}, n = {}) {
13388
- if (!this.modelData) throw Error("No hay ningún modelo cargado.");
13384
+ if (!this.modelData) throw Error("No model is loaded.");
13389
13385
  let r = this.modelData.entities.findIndex((t) => t.id === e);
13390
- if (r < 0) throw Error(`No existe una entidad con id "${e}".`);
13391
- if (!t || typeof t != "object" || Array.isArray(t)) throw TypeError("Los cambios de una entidad deben ser un objeto.");
13392
- if (t.id && t.id !== e) throw Error("El id de una entidad no se puede modificar.");
13393
- if (t.parent && t.parent !== e && !this.modelData.entities.some((e) => e.id === t.parent)) throw Error(`No existe el contenedor padre "${t.parent}".`);
13386
+ if (r < 0) throw Error(`No entity with id "${e}" exists.`);
13387
+ if (!t || typeof t != "object" || Array.isArray(t)) throw TypeError("Entity changes must be an object.");
13388
+ if (t.id && t.id !== e) throw Error("An entity id cannot be changed.");
13389
+ if (t.parent && t.parent !== e && !this.modelData.entities.some((e) => e.id === t.parent)) throw Error(`Parent container "${t.parent}" does not exist.`);
13394
13390
  return this.modelData.entities = this.modelData.entities.map((n, i) => i === r ? {
13395
13391
  ...n,
13396
13392
  ...t,
@@ -13402,7 +13398,7 @@ var Eu = class extends HTMLElement {
13402
13398
  }, n);
13403
13399
  }
13404
13400
  removeEntity(e, t = {}) {
13405
- if (!this.modelData) throw Error("No hay ningún modelo cargado.");
13401
+ if (!this.modelData) throw Error("No model is loaded.");
13406
13402
  let n = t.cascade !== !1, r = /* @__PURE__ */ new Set([e]);
13407
13403
  if (n) {
13408
13404
  let e = !0;
@@ -13411,7 +13407,7 @@ var Eu = class extends HTMLElement {
13411
13407
  for (let t of this.modelData.entities) t.parent && r.has(t.parent) && !r.has(t.id) && (r.add(t.id), e = !0);
13412
13408
  }
13413
13409
  }
13414
- if (!this.modelData.entities.some((t) => t.id === e)) throw Error(`No existe una entidad con id "${e}".`);
13410
+ if (!this.modelData.entities.some((t) => t.id === e)) throw Error(`No entity with id "${e}" exists.`);
13415
13411
  let i = this.modelData.relations[this.selectedRelationIndex];
13416
13412
  this.modelData.entities = this.modelData.entities.filter((e) => !r.has(e.id)), this.modelData.relations = this.modelData.relations.filter((e) => !r.has(e.from) && !r.has(e.to));
13417
13413
  let a = i ? this.modelData.relations.indexOf(i) : -1;
@@ -13421,22 +13417,22 @@ var Eu = class extends HTMLElement {
13421
13417
  });
13422
13418
  }
13423
13419
  addRelation(e, t = {}) {
13424
- if (!e || typeof e != "object" || !e.from || !e.to) throw TypeError("La relación debe incluir from y to.");
13425
- if (!this.modelData) throw Error("No hay ningún modelo cargado.");
13420
+ if (!e || typeof e != "object" || !e.from || !e.to) throw TypeError("The relation must include from and to.");
13421
+ if (!this.modelData) throw Error("No model is loaded.");
13426
13422
  let n = new Set(this.modelData.entities.map((e) => e.id));
13427
- if (!n.has(e.from) || !n.has(e.to)) throw Error("Los extremos de la relación deben existir en el modelo.");
13423
+ if (!n.has(e.from) || !n.has(e.to)) throw Error("Both relation endpoints must exist in the model.");
13428
13424
  return this.modelData.relations = [...this.modelData.relations, { ...e }], this._commitModelChange("relation-add", { relation: { ...e } }, t);
13429
13425
  }
13430
13426
  updateRelation(e, t = {}, n = {}) {
13431
- if (!this.modelData) throw Error("No hay ningún modelo cargado.");
13427
+ if (!this.modelData) throw Error("No model is loaded.");
13432
13428
  let r = this._relationIndex(e);
13433
- if (r < 0 || r >= this.modelData.relations.length) throw Error("No existe la relación indicada.");
13434
- if (!t || typeof t != "object" || Array.isArray(t)) throw TypeError("Los cambios de una relación deben ser un objeto.");
13429
+ if (r < 0 || r >= this.modelData.relations.length) throw Error("The requested relation does not exist.");
13430
+ if (!t || typeof t != "object" || Array.isArray(t)) throw TypeError("Relation changes must be an object.");
13435
13431
  let i = {
13436
13432
  ...this.modelData.relations[r],
13437
13433
  ...t
13438
13434
  }, a = new Set(this.modelData.entities.map((e) => e.id));
13439
- if (!a.has(i.from) || !a.has(i.to)) throw Error("Los extremos de la relación deben existir en el modelo.");
13435
+ if (!a.has(i.from) || !a.has(i.to)) throw Error("Both relation endpoints must exist in the model.");
13440
13436
  return this.modelData.relations = this.modelData.relations.map((e, t) => t === r ? i : e), this._commitModelChange("relation-update", {
13441
13437
  index: r,
13442
13438
  patch: t,
@@ -13444,9 +13440,9 @@ var Eu = class extends HTMLElement {
13444
13440
  }, n);
13445
13441
  }
13446
13442
  removeRelation(e, t = {}) {
13447
- if (!this.modelData) throw Error("No hay ningún modelo cargado.");
13443
+ if (!this.modelData) throw Error("No model is loaded.");
13448
13444
  let n = this._relationIndex(e);
13449
- if (n < 0 || n >= this.modelData.relations.length) throw Error("No existe la relación indicada.");
13445
+ if (n < 0 || n >= this.modelData.relations.length) throw Error("The requested relation does not exist.");
13450
13446
  let [r] = this.modelData.relations.splice(n, 1);
13451
13447
  return this.selectedRelationIndex === n ? this.selectedRelationIndex = null : this.selectedRelationIndex > n && --this.selectedRelationIndex, this._commitModelChange("relation-remove", {
13452
13448
  index: n,
@@ -13564,13 +13560,13 @@ var Eu = class extends HTMLElement {
13564
13560
  return this._containerEntityIds().filter((e) => this.open.has(e));
13565
13561
  }
13566
13562
  setOpenContainers(e, t = {}) {
13567
- if (e == null || typeof e == "string" || typeof e[Symbol.iterator] != "function") throw TypeError("Los contenedores abiertos deben indicarse mediante un iterable de ids.");
13563
+ if (e == null || typeof e == "string" || typeof e[Symbol.iterator] != "function") throw TypeError("Open containers must be provided as an iterable of ids.");
13568
13564
  return this._replaceOpenContainers(e, t), this;
13569
13565
  }
13570
13566
  setContainerOpen(e, t = !0, n = {}) {
13571
13567
  let r = this.modelData?.entities?.find((t) => t.id === e);
13572
- if (!r) throw Error(`No existe una entidad con id "${e}".`);
13573
- if (!Tl(r.type)) throw TypeError(`La entidad "${e}" no es un contenedor.`);
13568
+ if (!r) throw Error(`No entity with id "${e}" exists.`);
13569
+ if (!Tl(r.type)) throw TypeError(`Entity "${e}" is not a container.`);
13574
13570
  let i = new Set(this.open);
13575
13571
  if (t) i.add(e);
13576
13572
  else if (i.delete(e), n.closeDescendants !== !1) for (let t of this.modelData.entities) {
@@ -13644,7 +13640,7 @@ var Eu = class extends HTMLElement {
13644
13640
  try {
13645
13641
  return this.load(JSON.parse(t.textContent));
13646
13642
  } catch (e) {
13647
- this._showError("No se pudo leer el modelo JSON: " + e.message), this.dispatchEvent(new CustomEvent("lc-error", { detail: e }));
13643
+ this._showError("Could not read the JSON model: " + e.message), this.dispatchEvent(new CustomEvent("lc-error", { detail: e }));
13648
13644
  }
13649
13645
  }
13650
13646
  async load(e) {
@@ -13662,7 +13658,7 @@ var Eu = class extends HTMLElement {
13662
13658
  let n = this._pendingSelection;
13663
13659
  return this._pendingSelection = null, this._loading = !1, n?.kind === "relation" ? this.selectRelation(n.index, n.options) : n?.kind === "entity" && this.select(n.id, n.options), this;
13664
13660
  } catch (e) {
13665
- throw this._showError("No se pudo cargar el modelo: " + e.message), this.dispatchEvent(new CustomEvent("lc-error", { detail: e })), e;
13661
+ throw this._showError("Could not load the model: " + e.message), this.dispatchEvent(new CustomEvent("lc-error", { detail: e })), e;
13666
13662
  } finally {
13667
13663
  this._loading = !1;
13668
13664
  }
@@ -13677,7 +13673,7 @@ var Eu = class extends HTMLElement {
13677
13673
  powerPreference: "high-performance"
13678
13674
  }), this.ambientLight = new Ca(14282495, 2503739, 2.3), this.directionalLight = new Aa(16777215, 2.4), this.scene.add(this.ambientLight, this.directionalLight), this._applyLighting(), this.resize(), !0;
13679
13675
  } catch {
13680
- return this._showError("No se pudo iniciar WebGL. Activa la aceleración gráfica del navegador."), !1;
13676
+ return this._showError("WebGL could not start. Enable hardware acceleration in your browser."), !1;
13681
13677
  }
13682
13678
  }
13683
13679
  _applyLighting() {
@@ -13970,24 +13966,24 @@ var Eu = class extends HTMLElement {
13970
13966
  let e = this.selectedRelationIndex === null ? null : this.relations[this.selectedRelationIndex];
13971
13967
  if (e) {
13972
13968
  let t = Fl(e), n = (this.modelData.relationGroups || []).find((t) => t.id === e.group), r = new Map((this.modelData.relationGroups || []).map((e) => [e.id, e])), i = this.getRelationBundle(this.selectedRelationIndex), a = e.text ? "<p>" + $(e.text) + "</p>" : "", o = Jl(e.url), s = n ? "<h3>GRUPO</h3><p>" + $(n.label || n.id) + "</p>" : "", c = i.map(({ index: e, relation: t }) => {
13973
- let n = r.get(t.group), i = [n?.label || n?.id || "Sin grupo", Fl(t)].join(" · ");
13969
+ let n = r.get(t.group), i = [n?.label || n?.id || "Ungrouped", Fl(t)].join(" · ");
13974
13970
  return "<button class=\"relation" + (e === this.selectedRelationIndex ? " selected" : "") + "\" data-action=\"relation\" data-relation-index=\"" + e + "\"><strong>" + $(t.label || `${t.from} → ${t.to}`) + "</strong><small>" + $(i) + "</small></button>";
13975
- }).join(""), l = i.length === 1 ? "1 conexión" : `${i.length} conexiones`;
13976
- this.panel.innerHTML = "<button class=\"back\" data-action=\"overview\">← Vista de conjunto</button><button data-action=\"focus-selection\">◎ Enfocar selección</button><div class=\"eyebrow\">RELACIÓN</div><h2>" + $(e.label || `${e.from} → ${e.to}`) + "</h2><div class=\"sub\">" + $(e.from) + " → " + $(e.to) + "</div>" + a + o + s + "<h3>MODO</h3><p>" + $(t) + "</p><h3>TUBO VIRTUAL</h3><p>" + $(`${e.from} ↔ ${e.to} · ${l}`) + "</p>" + c, this.panel.querySelector("[data-action=\"overview\"]")?.addEventListener("click", () => this.reset()), this.panel.querySelector("[data-action=\"focus-selection\"]")?.addEventListener("click", () => this.focusSelection()), this.panel.querySelectorAll("[data-action=\"relation\"]").forEach((e) => e.addEventListener("click", () => this.selectRelation(Number(e.dataset.relationIndex), { source: "panel" }))), this._applyTheme();
13971
+ }).join(""), l = i.length === 1 ? "1 connection" : `${i.length} connections`;
13972
+ this.panel.innerHTML = "<button class=\"back\" data-action=\"overview\">← Overview</button><button data-action=\"focus-selection\">◎ Focus selection</button><div class=\"eyebrow\">RELATION</div><h2>" + $(e.label || `${e.from} → ${e.to}`) + "</h2><div class=\"sub\">" + $(e.from) + " → " + $(e.to) + "</div>" + a + o + s + "<h3>MODE</h3><p>" + $(t) + "</p><h3>VIRTUAL TUBE</h3><p>" + $(`${e.from} ↔ ${e.to} · ${l}`) + "</p>" + c, this.panel.querySelector("[data-action=\"overview\"]")?.addEventListener("click", () => this.reset()), this.panel.querySelector("[data-action=\"focus-selection\"]")?.addEventListener("click", () => this.focusSelection()), this.panel.querySelectorAll("[data-action=\"relation\"]").forEach((e) => e.addEventListener("click", () => this.selectRelation(Number(e.dataset.relationIndex), { source: "panel" }))), this._applyTheme();
13977
13973
  return;
13978
13974
  }
13979
13975
  let t = this.selected;
13980
13976
  if (!t) {
13981
- this.panel.innerHTML = "<div class=\"eyebrow\">LIQUIDCARS ATLAS</div><h2>Explora el modelo.</h2><p>Selecciona un volumen para consultar su función y sus relaciones.</p><p class=\"note\">El componente acepta un objeto JSON con palette, entities y relations.</p>", this._applyTheme();
13977
+ this.panel.innerHTML = "<div class=\"eyebrow\">LIQUIDCARS ATLAS</div><h2>Explore the model.</h2><p>Select an item to inspect its purpose and relations.</p><p class=\"note\">The component accepts a JSON object with palette, entities and relations.</p>", this._applyTheme();
13982
13978
  return;
13983
13979
  }
13984
13980
  let n = this.relations.filter((e) => e.from === t.id || e.to === t.id), r = this.modelData.entities.filter((e) => e.parent === t.id), i = [], a = /* @__PURE__ */ new Set(), o = t;
13985
13981
  for (; o && !a.has(o.id);) a.add(o.id), i.unshift(o), o = o.parent ? this.nodes.get(o.parent) : null;
13986
- let s = "<nav class=\"crumbs\" aria-label=\"Ruta del modelo\"><button data-action=\"overview\">Modelo</button>" + i.map((e, t) => "<span>/</span><button data-action=\"path\" data-id=\"" + $(e.id) + "\" class=\"" + (t === i.length - 1 ? "current" : "") + "\">" + $(e.name) + "</button>").join("") + "</nav>", c = n.map((e) => {
13982
+ let s = "<nav class=\"crumbs\" aria-label=\"Model path\"><button data-action=\"overview\">Model</button>" + i.map((e, t) => "<span>/</span><button data-action=\"path\" data-id=\"" + $(e.id) + "\" class=\"" + (t === i.length - 1 ? "current" : "") + "\">" + $(e.name) + "</button>").join("") + "</nav>", c = n.map((e) => {
13987
13983
  let n = this.relations.indexOf(e), r = e.text ? "<small>" + $(e.text) + "</small>" : "";
13988
13984
  return "<button class=\"relation\" data-action=\"relation\" data-relation-index=\"" + n + "\"><strong>" + $(e.label || (e.from === t.id ? e.to : e.from)) + "</strong><small>" + $(e.from) + " → " + $(e.to) + "</small>" + r + "</button>";
13989
13985
  }).join("");
13990
- this.panel.innerHTML = "<button class=\"back\" data-action=\"overview\">← Vista de conjunto</button>" + s + "<button data-action=\"focus-selection\">◎ Enfocar selección</button><div class=\"eyebrow\">" + $(Tl(t.type) ? "CONTENEDOR" : t.type === "actor" ? "ACTOR EXTERNO" : "COMPONENTE") + "</div><h2>" + $(t.name) + "</h2><div class=\"sub\">" + $(t.sub || "") + "</div><p>" + $(t.text || "") + "</p>" + Jl(t.url) + (Tl(t.type) ? "<button data-action=\"toggle-shell\">" + (this.open.has(t.id) ? "Cerrar bloque" : "Abrir bloque") + "</button>" : "") + (r.length ? "<h3>CONTIENE</h3><p>" + r.length + " pieza(s) interna(s).</p>" : "") + "<h3>RELACIONES</h3>" + (c || "<p>No hay relaciones directas.</p>"), this.panel.querySelectorAll("[data-action=\"overview\"]").forEach((e) => e.addEventListener("click", () => this.reset())), this.panel.querySelectorAll("[data-action=\"path\"]").forEach((e) => e.addEventListener("click", () => this.select(e.dataset.id))), this.panel.querySelectorAll("[data-action=\"relation\"]").forEach((e) => e.addEventListener("click", () => this.selectRelation(Number(e.dataset.relationIndex), { source: "panel" }))), this.panel.querySelector("[data-action=\"focus-selection\"]")?.addEventListener("click", () => this.focusSelection()), this.panel.querySelector("[data-action=\"toggle-shell\"]")?.addEventListener("click", () => {
13986
+ this.panel.innerHTML = "<button class=\"back\" data-action=\"overview\">← Overview</button>" + s + "<button data-action=\"focus-selection\">◎ Focus selection</button><div class=\"eyebrow\">" + $(Tl(t.type) ? "CONTAINER" : t.type === "actor" ? "EXTERNAL ACTOR" : "COMPONENT") + "</div><h2>" + $(t.name) + "</h2><div class=\"sub\">" + $(t.sub || "") + "</div><p>" + $(t.text || "") + "</p>" + Jl(t.url) + (Tl(t.type) ? "<button data-action=\"toggle-shell\">" + (this.open.has(t.id) ? "Close container" : "Open container") + "</button>" : "") + (r.length ? "<h3>CONTAINS</h3><p>" + r.length + " internal item" + (r.length === 1 ? "" : "s") + ".</p>" : "") + "<h3>RELATIONS</h3>" + (c || "<p>No direct relations.</p>"), this.panel.querySelectorAll("[data-action=\"overview\"]").forEach((e) => e.addEventListener("click", () => this.reset())), this.panel.querySelectorAll("[data-action=\"path\"]").forEach((e) => e.addEventListener("click", () => this.select(e.dataset.id))), this.panel.querySelectorAll("[data-action=\"relation\"]").forEach((e) => e.addEventListener("click", () => this.selectRelation(Number(e.dataset.relationIndex), { source: "panel" }))), this.panel.querySelector("[data-action=\"focus-selection\"]")?.addEventListener("click", () => this.focusSelection()), this.panel.querySelector("[data-action=\"toggle-shell\"]")?.addEventListener("click", () => {
13991
13987
  this.toggleContainer(t.id, { source: "panel" });
13992
13988
  }), this._applyTheme();
13993
13989
  }
@@ -14148,7 +14144,7 @@ var Eu = class extends HTMLElement {
14148
14144
  }, t === "error" ? 4200 : 2400)));
14149
14145
  }
14150
14146
  async _copyFromToolbar(e, t) {
14151
- t && (t.disabled = !0), this._setCopyToolbarStatus("Copiando…");
14147
+ t && (t.disabled = !0), this._setCopyToolbarStatus("Copying…");
14152
14148
  try {
14153
14149
  let t = await this.copyFrame({
14154
14150
  background: e,
@@ -14156,7 +14152,7 @@ var Eu = class extends HTMLElement {
14156
14152
  fallback: "download",
14157
14153
  source: "toolbar"
14158
14154
  });
14159
- return this._setCopyToolbarStatus(t.method === "clipboard" ? "Copiado" : "Descargado", "success"), t;
14155
+ return this._setCopyToolbarStatus(t.method === "clipboard" ? "Copied" : "Downloaded", "success"), t;
14160
14156
  } catch (e) {
14161
14157
  return this._setCopyToolbarStatus("Error", "error"), globalThis.console?.error?.("Atlas PNG export failed.", e), null;
14162
14158
  } finally {