@nine-lab/nine-ux 0.1.11 → 0.1.13

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.
@@ -59,22 +59,32 @@ class Nr extends HTMLElement {
59
59
  }
60
60
  }
61
61
  Ne(Nr, "alert", async (e, t = "Alert", r = {}) => {
62
- var c;
62
+ var a;
63
63
  const i = {
64
64
  class: "",
65
65
  animation: "",
66
- ...((c = Cn.options) == null ? void 0 : c.alert) || {},
66
+ ...((a = Cn.options) == null ? void 0 : a.alert) || {},
67
67
  ...r
68
68
  };
69
- document.querySelectorAll("nine-alert-popup").forEach((u) => u.remove());
69
+ document.querySelectorAll("nine-alert-popup").forEach((c) => c.remove());
70
70
  const s = document.createElement("nine-alert-popup");
71
71
  i.class && s.classList.add(...i.class.split(" ")), i.animation && s.classList.add(i.animation), document.body.appendChild(s);
72
- const o = s.shadowRoot.querySelector("nine-dialog"), l = s.shadowRoot.querySelector(".cancel"), a = s.shadowRoot.querySelector(".msg");
73
- return o == null || o.setAttribute("title", t), a.innerHTML = e.replace(/\n/g, "<br/>"), new Promise((u) => {
74
- const d = () => {
75
- u(!1), o.querySelector(".close").click();
76
- };
77
- l.onclick = d, console.log("======================="), console.log(s, o), console.log("======================="), o.showModal();
72
+ const o = s.shadowRoot.querySelector("nine-dialog");
73
+ s.shadowRoot.querySelector(".cancel");
74
+ const l = s.shadowRoot.querySelector(".msg");
75
+ return o == null || o.setAttribute("title", t), l.innerHTML = e.replace(/\n/g, "<br/>"), new Promise((c) => {
76
+ requestAnimationFrame(() => {
77
+ const u = s.shadowRoot.querySelector("nine-dialog");
78
+ if (!u || typeof u.showModal != "function") {
79
+ console.error("nine-dialog가 등록되었으나 showModal 메서드가 없습니다. 클래스 정의를 확인하세요."), console.log("dialogEl 상태:", u);
80
+ return;
81
+ }
82
+ const d = s.shadowRoot.querySelector(".cancel"), f = s.shadowRoot.querySelector(".msg");
83
+ u.setAttribute("title", t), f && (f.innerHTML = e), d.onclick = () => {
84
+ var h;
85
+ c(!1), (h = u.querySelector(".close")) == null || h.click();
86
+ }, u.showModal();
87
+ });
78
88
  });
79
89
  });
80
90
  customElements.get("nine-confirm-popup") || customElements.define("nine-confirm-popup", Er);
@@ -14150,7 +14160,7 @@ Or = function() {
14150
14160
  const t = Cn.getComponentCssPath("nineEditor.css"), r = t ? `@import "${t}";` : "";
14151
14161
  this.shadowRoot.innerHTML = `
14152
14162
  <style>
14153
- @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-ux@0.1.11/dist/css/nineEditor.css";
14163
+ @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-ux@0.1.13/dist/css/nineEditor.css";
14154
14164
  ${r}
14155
14165
  </style>
14156
14166