@developer.notchatbot/webchat 1.2.7 → 1.2.8

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.
@@ -16964,6 +16964,25 @@ También puedes pedir hablar con nuestro equipo de los sueños!`, bd = (e) => ({
16964
16964
  }
16965
16965
  );
16966
16966
  };
16967
+ (() => {
16968
+ if (typeof document == "undefined") return;
16969
+ const e = {}, t = document.dispatchEvent.bind(document);
16970
+ document.dispatchEvent = (r) => {
16971
+ const o = r == null ? void 0 : r.type;
16972
+ return (o === "WebChatReady" || o === "EmbedChatReady") && (e[o] = !0), t(r);
16973
+ };
16974
+ const n = document.addEventListener.bind(document);
16975
+ document.addEventListener = (r, o, i) => {
16976
+ const a = r;
16977
+ if ((a === "WebChatReady" || a === "EmbedChatReady") && e[a]) {
16978
+ const l = new CustomEvent(a);
16979
+ setTimeout(() => {
16980
+ typeof o == "function" ? o.call(document, l) : o && typeof o.handleEvent == "function" && o.handleEvent(l);
16981
+ }, 0);
16982
+ }
16983
+ return n(r, o, i);
16984
+ };
16985
+ })();
16967
16986
  let En = null;
16968
16987
  const Er = {}, No = {};
16969
16988
  let et = null, Te = null, ns = !1, Wr = {};
@@ -17130,17 +17149,17 @@ typeof window != "undefined" && (window.WebChat = ym, window.EmbedChat = wm, win
17130
17149
  window.setWebChatPosition(t);
17131
17150
  }
17132
17151
  }), setTimeout(() => {
17133
- const e = new CustomEvent("WebChatReady");
17152
+ const e = new CustomEvent("WebChatReady", { bubbles: !0 });
17134
17153
  document.dispatchEvent(e);
17135
17154
  }, 0), setTimeout(() => {
17136
- const e = new CustomEvent("EmbedChatReady");
17155
+ const e = new CustomEvent("EmbedChatReady", { bubbles: !0 });
17137
17156
  document.dispatchEvent(e);
17138
17157
  }, 0));
17139
17158
  const xm = () => {
17140
- const e = new CustomEvent("WebChatReady");
17159
+ const e = new CustomEvent("WebChatReady", { bubbles: !0 });
17141
17160
  document.dispatchEvent(e);
17142
17161
  }, Ed = () => {
17143
- const e = new CustomEvent("EmbedChatReady");
17162
+ const e = new CustomEvent("EmbedChatReady", { bubbles: !0 });
17144
17163
  document.dispatchEvent(e);
17145
17164
  }, Nu = () => {
17146
17165
  xm(), Ed();