@iframe-resizer/core 6.0.0-beta.1 → 6.0.0-beta.3

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.
package/index.esm.js CHANGED
@@ -1,43 +1,38 @@
1
- import tt, { NORMAL as nt, HIGHLIGHT as l, FOREGROUND as w } from "auto-console-group";
2
- const _ = "6.0.0-beta.1", pe = "iframeResizer", L = ":", ot = "[iFrameResizerChild]Ready", ge = "autoResize", it = "beforeUnload", st = "close", rt = "inPageLink", j = "init", de = "iframeReady", ct = "lazy", G = "load", A = "message", at = "mouseenter", lt = "mouseleave", me = "onload", ye = "pageInfo", be = "parentInfo", ut = "pageInfoStop", ft = "parentInfoStop", U = "reset", Y = "resize", ht = "scrollBy", pt = "scrollTo", gt = "scrollToOffset", dt = "title", ee = 1, mt = "height", yt = "width", bt = "offset", vt = "offsetSize", te = "scroll", C = `
3
- `, wt = "hidden", zt = "child", V = "parent", X = "string", Et = "number", ve = "object", we = "function", q = "auto", Ot = "font-weight: bold;", ze = "none", Ee = "both", D = "vertical", Oe = "horizontal", Tt = "omit", It = A.length, F = "[iFrameSizer]", Z = F.length, kt = Object.freeze({
1
+ import et, { NORMAL as tt, HIGHLIGHT as c, FOREGROUND as z } from "auto-console-group";
2
+ const _ = "6.0.0-beta.3", he = "iframeResizer", A = ":", nt = "[iFrameResizerChild]Ready", ge = "autoResize", ot = "beforeUnload", it = "close", st = "inPageLink", $ = "init", de = "iframeReady", rt = "lazy", G = "load", L = "message", lt = "mouseenter", at = "mouseleave", ye = "onload", me = "pageInfo", be = "parentInfo", ct = "pageInfoStop", ut = "parentInfoStop", V = "reset", ve = "resize", ft = "scrollBy", pt = "scrollTo", ht = "scrollToOffset", gt = "title", Q = 1, dt = "height", yt = "width", mt = "offset", bt = "offsetSize", ee = "scroll", C = `
3
+ `, vt = "hidden", zt = "child", U = "parent", Y = "string", wt = "number", ze = "object", Et = "function", q = "auto", Ot = "font-weight: bold;", we = "none", Ee = "both", W = "vertical", Oe = "horizontal", kt = "omit", Tt = L.length, B = "[iFrameSizer]", Z = B.length, jt = Object.freeze({
4
4
  max: 1,
5
5
  scroll: 1,
6
6
  bodyScroll: 1,
7
7
  documentElementScroll: 1
8
- }), ne = Object.freeze({
9
- [me]: 1,
10
- [j]: 1,
8
+ }), te = Object.freeze({
9
+ [ye]: 1,
10
+ [$]: 1,
11
11
  [de]: 1
12
- }), M = "expanded", S = "collapsed", Te = 0, Ie = 1, ke = 2, $t = Object.freeze({
13
- [M]: 1,
14
- [S]: 1
15
- }), $e = "Use of the old name will be removed in a future version of <i>iframe-resizer</>.", Me = (e) => typeof e === ve && e !== null, K = (e) => typeof e === X;
16
- function Mt(e) {
17
- if (!Me(e)) return !1;
12
+ }), I = "expanded", M = "collapsed", ke = 0, Te = 1, je = 2, It = Object.freeze({
13
+ [I]: 1,
14
+ [M]: 1
15
+ }), Mt = "Use of the old name will be removed in a future version of <i>iframe-resizer</>.", Ie = (e) => typeof e === ze && e !== null, X = (e) => typeof e === Y;
16
+ function St(e) {
17
+ if (!Ie(e)) return !1;
18
18
  try {
19
19
  return e.tagName === "IFRAME" || e instanceof HTMLIFrameElement;
20
20
  } catch {
21
21
  return !1;
22
22
  }
23
23
  }
24
- const St = (e, ...t) => setTimeout(() => e(...t), 0), jt = (e) => {
24
+ const $t = (e, ...t) => setTimeout(() => e(...t), 0), Rt = (e) => {
25
25
  let t = !1;
26
26
  return function(...n) {
27
27
  return t ? void 0 : (t = !0, e.apply(this, n));
28
28
  };
29
- }, Rt = (e, t) => Object.prototype.hasOwnProperty.call(e, t), P = (e, t) => Object.hasOwn ? Object.hasOwn(e, t) : Rt(e, t), Lt = (e) => e, At = (e) => e.charAt(0).toUpperCase() + e.slice(1), Pt = (e) => (
29
+ }, At = (e, t) => Object.prototype.hasOwnProperty.call(e, t), P = (e, t) => Object.hasOwn ? Object.hasOwn(e, t) : At(e, t), Lt = (e) => e, Pt = (e) => e.charAt(0).toUpperCase() + e.slice(1), Nt = (e) => (
30
30
  // eslint-disable-next-line no-underscore-dangle
31
31
  e?.__esModule ? e.default : e
32
- ), Nt = (e, t, n) => {
32
+ ), Ct = (e, t, n) => {
33
33
  if (typeof e !== t)
34
- throw new TypeError(`${n} is not a ${At(t)}`);
35
- }, Ct = (e) => (t, n = "renamed to") => (o, s, c = "", r = "") => e(
36
- r,
37
- `<rb>Deprecated ${t}(${o.replace("()", "")})</>
38
-
39
- The <b>${o}</> ${t.toLowerCase()} has been ${n} <b>${s}</>. ${c}Use of the old ${t.toLowerCase()} will be removed in a future version of <i>iframe-resizer</>.`
40
- ), Se = {
34
+ throw new TypeError(`${n} is not a ${Pt(t)}`);
35
+ }, Me = {
41
36
  br: `
42
37
  `,
43
38
  rb: "\x1B[31;1m",
@@ -52,56 +47,53 @@ The <b>${o}</> ${t.toLowerCase()} has been ${n} <b>${s}</>. ${c}Use of the old $
52
47
  // underline
53
48
  "/": "\x1B[m"
54
49
  // reset
55
- }, xt = Object.keys(Se), _t = new RegExp(`<(${xt.join("|")})>`, "gi"), Ft = (e, t) => Se[t] ?? "", Bt = (e) => e.replace(_t, Ft), Wt = (e) => e.replaceAll("<br>", C).replaceAll(/<\/?[^>]+>/gi, ""), je = (e) => (t) => e(
56
- K(t) ? window.chrome ? Bt(t) : Wt(t) : t
57
- ), i = {}, Re = Pt(tt);
58
- let Q = !0;
59
- const Dt = Re({
50
+ }, xt = Object.keys(Me), _t = new RegExp(`<(${xt.join("|")})>`, "gi"), Bt = (e, t) => Me[t] ?? "", Ft = (e) => e.replace(_t, Bt), Ht = (e) => e.replaceAll("<br>", C).replaceAll(/<\/?[^>]+>/gi, ""), Se = (e) => (t) => e(
51
+ X(t) ? window.chrome ? Ft(t) : Ht(t) : t
52
+ ), i = {}, $e = Nt(et);
53
+ let K = !0;
54
+ const Wt = $e({
60
55
  expand: !1,
61
- label: V
62
- }), Ht = (e) => window.top === window.self ? `parent(${e})` : `nested parent(${e})`, Gt = (e) => i[e] ? i[e].log : Q;
63
- function Ut({
56
+ label: U
57
+ }), Dt = (e) => window.top === window.self ? `parent(${e})` : `nested parent(${e})`, Gt = (e) => i[e] ? i[e].log : K;
58
+ function Vt({
64
59
  enabled: e,
65
60
  expand: t,
66
61
  iframeId: n
67
62
  }) {
68
- const o = Re({
63
+ const o = $e({
69
64
  expand: t,
70
- label: Ht(n)
65
+ label: Dt(n)
71
66
  });
72
- Q = e, i[n] || (i[n] = {
67
+ K = e, i[n] || (i[n] = {
73
68
  console: o
74
69
  });
75
70
  }
76
- const k = (e) => (t, ...n) => i[t] ? i[t].console[e](...n) : Dt[e](...n), Le = (e) => (t, ...n) => Gt(t) === !0 ? k(e)(t, ...n) : null, u = Le("log"), y = u, Vt = Le("debug"), z = k("warn"), qt = k("error"), b = k("event"), Zt = k("purge"), Jt = k("endAutoGroup"), Ae = k("errorBoundary");
71
+ const T = (e) => (t, ...n) => i[t] ? i[t].console[e](...n) : Wt[e](...n), Re = (e) => (t, ...n) => Gt(t) === !0 ? T(e)(t, ...n) : null, u = Re("log"), y = u, Ut = Re("debug"), w = T("warn"), qt = T("error"), b = T("event"), Zt = T("purge"), Jt = T("endAutoGroup"), Ae = T("errorBoundary");
77
72
  function Yt(e, t) {
78
73
  queueMicrotask(
79
74
  () => (
80
75
  // eslint-disable-next-line no-console
81
76
  console.info(
82
77
  `%ciframe-resizer ${e}`,
83
- Q || t < 1 ? Ot : nt
78
+ K || t < 1 ? Ot : tt
84
79
  )
85
80
  )
86
81
  );
87
82
  }
88
- const Xt = (e) => (...t) => [`${pe}(${e})`, ...t].join(" "), Kt = je(Lt), m = (e, ...t) => i[e] ? i[e].console.warn(...t.map(Kt)) : queueMicrotask(() => {
89
- const n = je(Xt(e));
83
+ const Xt = (e) => (...t) => [`${he}(${e})`, ...t].join(" "), Kt = Se(Lt), m = (e, ...t) => i[e] ? i[e].console.warn(...t.map(Kt)) : queueMicrotask(() => {
84
+ const n = Se(Xt(e));
90
85
  console?.warn(...t.map(n));
91
- }), Qt = Ct(m), en = Qt("Option"), tn = (e) => {
92
- typeof i[e.id].onInit === we && (en("init()", "onReady()", "", e.id), i[e.id].onInit(e));
93
- }, B = Object.freeze({
86
+ }), F = Object.freeze({
94
87
  autoResize: !0,
95
88
  bodyBackground: null,
96
89
  bodyMargin: null,
97
90
  bodyPadding: null,
98
91
  checkOrigin: !0,
99
- direction: D,
92
+ direction: W,
100
93
  firstRun: !0,
101
94
  inPageLinks: !1,
102
95
  heightCalculationMethod: q,
103
- id: "iFrameResizer",
104
- // TODO: v6 change to 'iframeResizer'
96
+ id: "iframeResizer",
105
97
  log: !1,
106
98
  logExpand: !1,
107
99
  license: void 0,
@@ -121,150 +113,150 @@ const Xt = (e) => (...t) => [`${pe}(${e})`, ...t].join(" "), Kt = je(Lt), m = (e
121
113
  onBeforeClose: () => !0,
122
114
  onAfterClose() {
123
115
  },
124
- onInit: !1,
125
116
  onMessage: null,
126
117
  onMouseEnter() {
127
118
  },
128
119
  onMouseLeave() {
129
120
  },
130
- onReady: tn,
121
+ onReady() {
122
+ },
131
123
  onResized() {
132
124
  },
133
125
  onScroll: () => !0
134
126
  });
135
- let oe = 0;
136
- function nn(e) {
137
- const t = e?.id || B.id + oe++;
138
- return document.getElementById(t) === null ? t : `${t}${oe++}`;
127
+ let ne = 0;
128
+ function Qt(e) {
129
+ const t = e?.id || F.id + ne++;
130
+ return document.getElementById(t) === null ? t : `${t}${ne++}`;
139
131
  }
140
- function on(e, t) {
132
+ function en(e, t) {
141
133
  let { id: n } = e;
142
- if (n && !K(n))
143
- throw new TypeError("Invalid id for iFrame. Expected String");
144
- return (!n || n === "") && (n = nn(t), e.id = n, b(n, "assignId"), u(n, `Added missing iframe ID: ${n} (${e.src})`)), n;
134
+ if (n && !X(n))
135
+ throw new TypeError("Invalid id for iframe. Expected String");
136
+ return (!n || n === "") && (n = Qt(t), e.id = n, b(n, "assignId"), u(n, `Added missing iframe ID: ${n} (${e.src})`)), n;
145
137
  }
146
- function sn(e) {
138
+ function tn(e) {
147
139
  const { search: t } = window.location;
148
140
  if (t.includes("ifrlog"))
149
141
  switch (new URLSearchParams(t).get("ifrlog")) {
150
- case String(Te): {
142
+ case String(ke): {
151
143
  e.log = !1;
152
144
  break;
153
145
  }
154
- case M:
155
- case String(ke): {
156
- e.log = M;
146
+ case I:
147
+ case String(je): {
148
+ e.log = I;
157
149
  break;
158
150
  }
159
- case S:
160
- case String(Ie): {
161
- e.log = S;
151
+ case M:
152
+ case String(Te): {
153
+ e.log = M;
162
154
  break;
163
155
  }
164
156
  default:
165
- e.log = S;
157
+ e.log = M;
166
158
  }
167
159
  }
168
- const N = (e, t, n, o) => e.addEventListener(t, n, o || !1), ie = (e, t, n) => e.removeEventListener(t, n, !1), rn = (e) => e.split(L).filter((t, n) => n !== 19).join(L);
169
- function cn(e, t, n) {
160
+ const N = (e, t, n, o) => e.addEventListener(t, n, o || !1), oe = (e, t, n) => e.removeEventListener(t, n, !1), nn = (e) => e.split(A).filter((t, n) => n !== 19).join(A);
161
+ function on(e, t, n) {
170
162
  function o(f) {
171
- const h = e in ne ? rn(t) : t;
172
- y(n, f, l, w, l), y(n, `Message data: %c${h}`, l);
163
+ const p = e in te ? nn(t) : t;
164
+ y(n, f, c, z, c), y(n, `Message data: %c${p}`, c);
173
165
  }
174
- const { iframe: s, postMessageTarget: c, sameOrigin: r, targetOrigin: a } = i[n];
166
+ const { iframe: s, postMessageTarget: a, sameOrigin: r, targetOrigin: l } = i[n];
175
167
  if (r)
176
168
  try {
177
- s.contentWindow.iframeChildListener(F + t), o(`Sending message to iframe %c${n}%c via same origin%c`);
169
+ s.contentWindow.iframeChildListener(B + t), o(`Sending message to iframe %c${n}%c via same origin%c`);
178
170
  return;
179
171
  } catch {
180
- e in ne ? (i[n].sameOrigin = !1, u(n, "New iframe does not support same origin")) : z(n, "Same origin messaging failed, falling back to postMessage");
172
+ e in te ? (i[n].sameOrigin = !1, u(n, "New iframe does not support same origin")) : w(n, "Same origin messaging failed, falling back to postMessage");
181
173
  }
182
174
  o(
183
- `Sending message to iframe: %c${n}%c targetOrigin: %c${a.join(", ")}`
175
+ `Sending message to iframe: %c${n}%c targetOrigin: %c${l.join(", ")}`
184
176
  );
185
- for (const f of a)
186
- c.postMessage(F + t, f);
177
+ for (const f of l)
178
+ a.postMessage(B + t, f);
187
179
  }
188
- function T(e, t, n) {
180
+ function S(e, t, n) {
189
181
  if (b(n, e), !i[n]?.postMessageTarget) {
190
- z(n, "Iframe not found");
182
+ w(n, "Iframe not found");
191
183
  return;
192
184
  }
193
- cn(e, t, n);
185
+ on(e, t, n);
194
186
  }
195
- const an = (e, t) => Object.values(i).filter(({ autoResize: n, firstRun: o }) => n && !o).forEach(({ iframe: n }) => T(e, t, n.id));
196
- function ln() {
197
- document.hidden !== !0 && an("tabVisible", Y);
187
+ const sn = (e, t) => Object.values(i).filter(({ autoResize: n, firstRun: o }) => n && !o).forEach(({ iframe: n }) => S(e, t, n.id));
188
+ function rn() {
189
+ document.hidden !== !0 && sn("tabVisible", ve);
198
190
  }
199
- function un(e) {
191
+ function ln(e) {
200
192
  if (e.boxSizing !== "border-box") return 0;
201
193
  const t = e.paddingTop ? parseInt(e.paddingTop, 10) : 0, n = e.paddingBottom ? parseInt(e.paddingBottom, 10) : 0;
202
194
  return t + n;
203
195
  }
204
- function fn(e) {
196
+ function an(e) {
205
197
  if (e.boxSizing !== "border-box") return 0;
206
198
  const t = e.borderTopWidth ? parseInt(e.borderTopWidth, 10) : 0, n = e.borderBottomWidth ? parseInt(e.borderBottomWidth, 10) : 0;
207
199
  return t + n;
208
200
  }
209
- function hn(e) {
210
- const t = e.slice(Z).split(":"), n = t[1] ? Number(t[1]) : 0, o = i[t[0]]?.iframe, s = getComputedStyle(o), c = {
201
+ function cn(e) {
202
+ const t = e.slice(Z).split(":"), n = t[1] ? Number(t[1]) : 0, o = i[t[0]]?.iframe, s = o ? getComputedStyle(o) : null, a = s ? ln(s) + an(s) : 0, r = {
211
203
  iframe: o,
212
204
  id: t[0],
213
- height: n + un(s) + fn(s),
205
+ height: n + a,
214
206
  width: Number(t[2]),
215
207
  type: t[3],
216
208
  msg: t[4],
217
209
  message: t[4]
218
210
  };
219
- return t[5] && (c.mode = t[5]), c;
211
+ return t[5] && (r.mode = t[5]), r;
220
212
  }
221
- const pn = { true: 1, false: 1, undefined: 1 };
222
- function gn(e) {
223
- const { id: t, msg: n, iframe: o } = e, s = Mt(o);
224
- return s || (u(t, `Received: %c${n}`, l), z(t, "The target iframe was not found.")), s;
213
+ const un = { true: 1, false: 1, undefined: 1 };
214
+ function fn(e) {
215
+ const { id: t, msg: n, iframe: o } = e, s = St(o);
216
+ return s || (u(t, `Received: %c${n}`, c), w(t, "The target iframe was not found.")), s;
225
217
  }
226
- function dn(e, t) {
218
+ function pn(e, t) {
227
219
  const { id: n } = e, { data: o, origin: s } = t;
228
220
  if ("sameOrigin" in t && t.sameOrigin) return !0;
229
221
  const r = i[n]?.checkOrigin;
230
- function a() {
222
+ function l() {
231
223
  function f() {
232
224
  u(
233
225
  n,
234
226
  `Checking connection is from allowed list of origins: %c${r}`,
235
- l
227
+ c
236
228
  );
237
- for (const g of r)
238
- if (g === s)
229
+ for (const h of r)
230
+ if (h === s)
239
231
  return !0;
240
232
  return !1;
241
233
  }
242
- function h() {
243
- const g = i[n]?.remoteHost;
244
- return u(n, `Checking connection is from: %c${g}`, l), s === g;
234
+ function p() {
235
+ const h = i[n]?.remoteHost;
236
+ return u(n, `Checking connection is from: %c${h}`, c), s === h;
245
237
  }
246
- return r.constructor === Array ? f() : h();
238
+ return r.constructor === Array ? f() : p();
247
239
  }
248
- if (r && `${s}` != "null" && !a())
240
+ if (r && `${s}` != "null" && !l())
249
241
  throw new Error(
250
242
  `Unexpected message received from: ${s} for ${n}. Message was: ${o}. This error can be disabled by setting the checkOrigin: false option or by providing an array of trusted domains.`
251
243
  );
252
244
  return !0;
253
245
  }
254
- const mn = (e) => F === `${e}`.slice(0, Z) && e.slice(Z).split(":")[0] in i;
255
- function yn(e) {
256
- const { id: t, type: n } = e, o = n in pn;
246
+ const hn = (e) => B === `${e}`.slice(0, Z) && e.slice(Z).split(":")[0] in i;
247
+ function gn(e) {
248
+ const { id: t, type: n } = e, o = n in un;
257
249
  return o && u(t, "Ignoring init message from meta parent page"), o;
258
250
  }
259
- function bn(e) {
251
+ function dn(e) {
260
252
  try {
261
253
  i[e].sameOrigin = !!i[e]?.iframe?.contentWindow?.iframeChildListener;
262
254
  } catch {
263
255
  i[e].sameOrigin = !1;
264
256
  }
265
- u(e, `sameOrigin: %c${i[e].sameOrigin}`, l);
257
+ u(e, `sameOrigin: %c${i[e].sameOrigin}`, c);
266
258
  }
267
- function vn(e, t) {
259
+ function yn(e, t) {
268
260
  if (t !== _) {
269
261
  if (t === void 0) {
270
262
  m(
@@ -281,35 +273,35 @@ See <u>https://iframe-resizer.com/setup/#child-page-setup</> for more details.
281
273
  u(
282
274
  e,
283
275
  `Version mismatch (Child: %c${t}%c !== Parent: %c${_})`,
284
- l,
285
- w,
286
- l
276
+ c,
277
+ z,
278
+ c
287
279
  );
288
280
  }
289
281
  }
290
- function I(e, t, n) {
282
+ function k(e, t, n) {
291
283
  if (!i[e]) return null;
292
284
  const o = i[e][t];
293
- if (typeof o !== we)
285
+ if (typeof o !== Et)
294
286
  throw new TypeError(`${t} on iframe[${e}] is not a function`);
295
287
  if (t !== "onBeforeClose" && t !== "onScroll")
296
- return St(o, n);
288
+ return $t(o, n);
297
289
  try {
298
290
  return o(n);
299
291
  } catch (s) {
300
- return console.error(s), z(e, `Error in ${t} callback`), null;
292
+ return console.error(s), w(e, `Error in ${t} callback`), null;
301
293
  }
302
294
  }
303
- function wn(e, t) {
295
+ function mn(e, t) {
304
296
  const { id: n, iframe: o } = e;
305
297
  u(
306
298
  n,
307
299
  `onMessage passed: {iframe: %c${n}%c, message: %c${t}%c}`,
308
- l,
309
- w,
310
- l,
311
- w
312
- ), I(n, "onMessage", {
300
+ c,
301
+ z,
302
+ c,
303
+ z
304
+ ), k(n, "onMessage", {
313
305
  iframe: o,
314
306
  message: JSON.parse(t)
315
307
  });
@@ -317,159 +309,167 @@ function wn(e, t) {
317
309
  function x(e, t) {
318
310
  const { lastMessage: n } = i[e];
319
311
  return n.slice(
320
- n.indexOf(L) + It + t
312
+ n.indexOf(A) + Tt + t
321
313
  );
322
314
  }
323
- function se(e, t) {
324
- const { id: n, iframe: o, height: s, type: c, width: r } = t;
325
- let a = { x: 0, y: 0 };
315
+ function ie(e, t) {
316
+ const { id: n, iframe: o, height: s, type: a, width: r } = t;
317
+ let l = { x: 0, y: 0 };
326
318
  if (r === 0 && s === 0) {
327
- const f = x(n, 9).split(L);
328
- a = {
319
+ const f = x(n, 9).split(A);
320
+ l = {
329
321
  x: f[1],
330
322
  y: f[0]
331
323
  };
332
324
  } else
333
- a = {
325
+ l = {
334
326
  x: r,
335
327
  y: s
336
328
  };
337
- I(n, e, {
329
+ k(n, e, {
338
330
  iframe: o,
339
- screenX: Number(a.x),
340
- screenY: Number(a.y),
341
- type: c
331
+ screenX: Number(l.x),
332
+ screenY: Number(l.y),
333
+ type: a
342
334
  });
343
335
  }
344
- const p = {
336
+ const g = {
345
337
  position: null,
346
338
  version: _
347
339
  };
348
- function Pe() {
349
- p.position = null;
340
+ function Le() {
341
+ g.position = null;
350
342
  }
351
- const zn = () => p.position;
352
- function En(e) {
353
- p.position = e;
343
+ const bn = () => g.position;
344
+ function vn(e) {
345
+ g.position = e;
354
346
  }
355
- function Ne(e) {
356
- return p.position === null && (p.position = {
347
+ function Pe(e) {
348
+ return g.position === null && (g.position = {
357
349
  x: window.scrollX,
358
350
  y: window.scrollY
359
351
  }), u(
360
352
  e,
361
- `Get page position: %c${p.position.x}%c, %c${p.position.y}`,
362
- l,
363
- w,
364
- l
365
- ), p.position;
353
+ `Get page position: %c${g.position.x}%c, %c${g.position.y}`,
354
+ c,
355
+ z,
356
+ c
357
+ ), g.position;
366
358
  }
367
- function Ce(e) {
368
- p.position !== null && (window.scrollTo(p.position.x, p.position.y), y(
359
+ function Ne(e) {
360
+ g.position !== null && (window.scrollTo(g.position.x, g.position.y), y(
369
361
  e,
370
- `Set page position: %c${p.position.x}%c, %c${p.position.y}`,
371
- l,
372
- w,
373
- l
374
- ), Pe());
362
+ `Set page position: %c${g.position.x}%c, %c${g.position.y}`,
363
+ c,
364
+ z,
365
+ c
366
+ ), Le());
375
367
  }
376
- function re(e, t) {
368
+ function se(e, t) {
377
369
  const { id: n } = t, o = `${t[e]}px`;
378
- i[n].iframe.style[e] = o, y(n, `Set ${e}: %c${o}`, l);
370
+ i[n].iframe.style[e] = o, y(n, `Set ${e}: %c${o}`, c);
379
371
  }
380
- function xe(e) {
372
+ function Ce(e) {
381
373
  const { id: t } = e, { sizeHeight: n, sizeWidth: o } = i[t];
382
- n && re(mt, e), o && re(yt, e);
374
+ n && se(dt, e), o && se(yt, e);
383
375
  }
384
- function ce(e) {
376
+ function re(e) {
385
377
  const { id: t } = e;
386
- xe(e), Ce(t), I(t, "onResized", e);
378
+ Ce(e), Ne(t), k(t, "onResized", e);
387
379
  }
388
- function _e(e) {
380
+ function xe(e) {
389
381
  const { id: t } = e;
390
382
  u(t, "Disconnected from iframe"), delete i[t], delete e.iframeResizer;
391
383
  }
392
- function Fe(e) {
384
+ function _e(e) {
393
385
  const { id: t } = e;
394
- if (I(t, "onBeforeClose", t) === !1) {
386
+ if (k(t, "onBeforeClose", t) === !1) {
395
387
  u(t, "Close iframe cancelled by onBeforeClose");
396
388
  return;
397
389
  }
398
- u(t, `Removing iFrame: %c${t}`, l);
390
+ u(t, `Removing iframe: %c${t}`, c);
399
391
  try {
400
392
  e.parentNode && e.remove();
401
393
  } catch (n) {
402
- z(t, n);
394
+ w(t, n);
403
395
  }
404
- I(t, "onAfterClose", t), _e(e);
396
+ k(t, "onAfterClose", t), xe(e);
405
397
  }
406
398
  function Be(e) {
407
399
  const { id: t, type: n } = e;
408
400
  u(
409
401
  t,
410
- `Size reset requested by ${n === j ? "parent page" : "child page"}`
411
- ), Ne(t), xe(e), T(U, U, t);
402
+ `Size reset requested by ${n === $ ? "parent page" : "child page"}`
403
+ ), Pe(t), Ce(e), S(V, V, t);
412
404
  }
413
- const We = (e, t) => {
405
+ const Fe = (e, t) => {
414
406
  const n = {};
415
407
  return (o, s) => {
416
- const { iframe: c } = i[s];
417
- function r(f, h) {
418
- n[h] || (f(), n[h] = requestAnimationFrame(() => {
419
- n[h] = null;
408
+ const { iframe: a } = i[s];
409
+ function r(f, p) {
410
+ n[p] || (f(), n[p] = requestAnimationFrame(() => {
411
+ n[p] = null;
420
412
  }));
421
413
  }
422
- function a() {
423
- T(`${o} (${e})`, `${e}:${t(c)}`, s);
414
+ function l() {
415
+ S(`${o} (${e})`, `${e}:${t(a)}`, s);
424
416
  }
425
- r(a, s);
417
+ r(l, s);
426
418
  };
427
- }, De = (e) => (t) => {
419
+ }, He = (e) => (t) => {
428
420
  e in i[t] && (i[t][e](), delete i[t][e]);
429
- }, He = (
421
+ }, We = (
430
422
  // eslint-disable-next-line @typescript-eslint/no-shadow
431
423
  ((e, t) => (n) => {
432
424
  let o = !1;
433
425
  const s = (d) => () => {
434
426
  i[n] ? (!o || o === d) && (e(d, n), o = d, requestAnimationFrame(() => {
435
427
  o = !1;
436
- })) : g();
437
- }, c = s(te), r = s("resize window"), a = new ResizeObserver(s("pageObserver")), f = new ResizeObserver(s("iframeObserver"));
438
- function h(d, E) {
439
- u(n, `${d}listeners for send${t}`), E(window, te, c), E(window, Y, r);
428
+ })) : h();
429
+ }, a = s(ee), r = s("resize window"), l = new ResizeObserver(s("pageObserver")), f = new ResizeObserver(s("iframeObserver"));
430
+ function p(d, E) {
431
+ u(n, `${d}listeners for send${t}`), E(window, ee, a), E(window, ve, r);
440
432
  }
441
- function g() {
442
- b(n, `stop${t}`), h("Remove ", ie), a.disconnect(), f.disconnect(), i[n] && ie(i[n].iframe, G, g);
433
+ function h() {
434
+ b(n, `stop${t}`), p("Remove ", oe), l.disconnect(), f.disconnect(), i[n] && oe(i[n].iframe, G, h);
443
435
  }
444
- function $() {
445
- h("Add ", N), a.observe(document.body), f.observe(i[n].iframe);
436
+ function j() {
437
+ p("Add ", N), l.observe(document.body), f.observe(i[n].iframe);
446
438
  }
447
- i[n] && (i[n][`stop${t}`] = g, N(i[n].iframe, G, g), $());
439
+ i[n] && (i[n][`stop${t}`] = h, N(i[n].iframe, G, h), j());
448
440
  })
449
441
  );
450
- function On(e) {
451
- const t = document.body.getBoundingClientRect(), n = e.getBoundingClientRect(), { scrollY: o, scrollX: s, innerHeight: c, innerWidth: r } = window, { clientHeight: a, clientWidth: f } = document.documentElement;
442
+ function zn(e) {
443
+ const t = document.body.getBoundingClientRect(), n = e.getBoundingClientRect(), { scrollY: o, scrollX: s, innerHeight: a, innerWidth: r } = window, { clientHeight: l, clientWidth: f } = document.documentElement;
452
444
  return JSON.stringify({
453
445
  iframeHeight: n.height,
454
446
  iframeWidth: n.width,
455
- clientHeight: Math.max(a, c || 0),
447
+ clientHeight: Math.max(l, a || 0),
456
448
  clientWidth: Math.max(f, r || 0),
457
449
  offsetTop: Math.trunc(n.top - t.top),
458
450
  offsetLeft: Math.trunc(n.left - t.left),
459
451
  scrollTop: o,
460
452
  scrollLeft: s,
461
- documentHeight: a,
453
+ documentHeight: l,
462
454
  documentWidth: f,
463
- windowHeight: c,
455
+ windowHeight: a,
464
456
  windowWidth: r
465
457
  });
466
458
  }
467
- const Tn = We(ye, On), In = He(
468
- Tn,
459
+ const wn = Fe(me, zn), En = We(
460
+ wn,
469
461
  "PageInfo"
470
- ), kn = De("stopPageInfo");
471
- function $n(e) {
472
- const { scrollWidth: t, scrollHeight: n } = document.documentElement, { width: o, height: s, offsetLeft: c, offsetTop: r, pageLeft: a, pageTop: f, scale: h } = window.visualViewport;
462
+ ), On = He("stopPageInfo");
463
+ function kn(e) {
464
+ const { scrollWidth: t, scrollHeight: n } = document.documentElement, o = typeof window < "u" && window.visualViewport ? window.visualViewport : {}, {
465
+ width: s = 0,
466
+ height: a = 0,
467
+ offsetLeft: r = 0,
468
+ offsetTop: l = 0,
469
+ pageLeft: f = 0,
470
+ pageTop: p = 0,
471
+ scale: h = 1
472
+ } = o;
473
473
  return JSON.stringify({
474
474
  iframe: e.getBoundingClientRect(),
475
475
  document: {
@@ -477,73 +477,73 @@ function $n(e) {
477
477
  scrollHeight: n
478
478
  },
479
479
  viewport: {
480
- width: o,
481
- height: s,
482
- offsetLeft: c,
483
- offsetTop: r,
484
- pageLeft: a,
485
- pageTop: f,
480
+ width: s,
481
+ height: a,
482
+ offsetLeft: r,
483
+ offsetTop: l,
484
+ pageLeft: f,
485
+ pageTop: p,
486
486
  scale: h
487
487
  }
488
488
  });
489
489
  }
490
- const Mn = We(be, $n), Sn = He(
491
- Mn,
490
+ const Tn = Fe(be, kn), jn = We(
491
+ Tn,
492
492
  "ParentInfo"
493
- ), jn = De("stopParentInfo");
494
- function Ge(e) {
495
- const t = e.getBoundingClientRect(), n = Ne(e.id);
493
+ ), In = He("stopParentInfo");
494
+ function De(e) {
495
+ const t = e.getBoundingClientRect(), n = Pe(e.id);
496
496
  return {
497
497
  x: Number(t.left) + Number(n.x),
498
498
  y: Number(t.top) + Number(n.y)
499
499
  };
500
500
  }
501
- function Ue(e) {
502
- const { x: t, y: n } = zn(), o = i[e]?.iframe;
503
- if (I(e, "onScroll", { iframe: o, top: n, left: t, x: t, y: n }) === !1) {
504
- Pe();
501
+ function Ge(e) {
502
+ const { x: t, y: n } = bn(), o = i[e]?.iframe;
503
+ if (k(e, "onScroll", { iframe: o, top: n, left: t, x: t, y: n }) === !1) {
504
+ Le();
505
505
  return;
506
506
  }
507
- Ce(e);
507
+ Ne(e);
508
508
  }
509
- function Rn(e) {
509
+ function Mn(e) {
510
510
  const { id: t, height: n, width: o } = e, s = window.parentIframe || window.parentIFrame || window;
511
511
  y(
512
512
  t,
513
513
  `scrollBy: x: %c${o}%c y: %c${n}`,
514
- l,
515
- w,
516
- l
514
+ c,
515
+ z,
516
+ c
517
517
  ), s.scrollBy(o, n);
518
518
  }
519
519
  const Ve = (e) => (t) => {
520
- const { id: n, iframe: o, height: s, width: c } = t;
520
+ const { id: n, iframe: o, height: s, width: a } = t;
521
521
  function r(d) {
522
- En(d), Ue(n);
522
+ vn(d), Ge(n);
523
523
  }
524
- function a(d, E) {
524
+ function l(d, E) {
525
525
  d[`scrollTo${e ? "Offset" : ""}`](
526
526
  E.x,
527
527
  E.y
528
528
  );
529
529
  }
530
530
  const f = (d) => ({
531
- x: c + d.x,
531
+ x: a + d.x,
532
532
  y: s + d.y
533
- }), h = e ? Ge(o) : { x: 0, y: 0 }, g = f(h), $ = window.parentIframe || window.parentIFrame;
533
+ }), p = e ? De(o) : { x: 0, y: 0 }, h = f(p), j = window.parentIframe || window.parentIFrame;
534
534
  y(
535
535
  n,
536
- `Reposition requested (offset x:%c${h.x}%c y:%c${h.y})`,
537
- l,
538
- w,
539
- l
540
- ), $ ? a($, g) : r(g);
541
- }, Ln = Ve(!1), An = Ve(!0);
542
- function Pn(e, t, n) {
543
- const { x: o, y: s } = Ge(n);
544
- y(e, `Moving to in page link: %c#${t}`, l), p.position = { x: o, y: s }, Ue(e), window.location.hash = t;
545
- }
546
- function Nn(e, t) {
536
+ `Reposition requested (offset x:%c${p.x}%c y:%c${p.y})`,
537
+ c,
538
+ z,
539
+ c
540
+ ), j ? l(j, h) : r(h);
541
+ }, Sn = Ve(!1), $n = Ve(!0);
542
+ function Rn(e, t, n) {
543
+ const { x: o, y: s } = De(n);
544
+ y(e, `Moving to in page link: %c#${t}`, c), g.position = { x: o, y: s }, Ge(e), window.location.hash = t;
545
+ }
546
+ function An(e, t) {
547
547
  const n = window.parentIframe || window.parentIFrame;
548
548
  if (!n) {
549
549
  u(e, `In page link #${t} not found`);
@@ -551,26 +551,26 @@ function Nn(e, t) {
551
551
  }
552
552
  n.moveToAnchor(t);
553
553
  }
554
- function Cn(e, t) {
554
+ function Ln(e, t) {
555
555
  const n = t.split("#")[1] || "", o = decodeURIComponent(n), s = document.getElementById(o) || document.getElementsByName(o)[0];
556
556
  if (s) {
557
- Pn(e, n, s);
557
+ Rn(e, n, s);
558
558
  return;
559
559
  }
560
560
  if (window.top === window.self) {
561
561
  u(e, `In page link #${n} not found`);
562
562
  return;
563
563
  }
564
- Nn(e, n);
564
+ An(e, n);
565
565
  }
566
- function xn(e) {
566
+ function Pn(e) {
567
567
  const t = i[e]?.iframe?.title;
568
568
  return t === "" || t === void 0;
569
569
  }
570
- function _n(e, t) {
571
- i[e]?.syncTitle && (i[e].iframe.title = t, y(e, `Set iframe title attribute: %c${t}`, l));
570
+ function Nn(e, t) {
571
+ i[e]?.syncTitle && (i[e].iframe.title = t, y(e, `Set iframe title attribute: %c${t}`, c));
572
572
  }
573
- const W = (e) => {
573
+ const H = (e) => {
574
574
  if (!e) return "";
575
575
  let t = -559038744, n = 1103547984;
576
576
  for (let o, s = 0; s < e.length; s++)
@@ -581,25 +581,23 @@ const W = (e) => {
581
581
  (t) => String.fromCodePoint(
582
582
  (t <= "Z" ? 90 : 122) >= (t = t.codePointAt(0) + 19) ? t : t - 26
583
583
  )
584
- ), Fn = /* @__PURE__ */ new Date(), qe = (e) => new Set(Array.from({ length: 9 }, e)), Bn = (e) => [
585
- e[0],
586
- ...e.slice(1).map((t) => `${t} - lewpylk`),
587
- `${e[4]} - lewpylk`,
588
- ...e.slice(1)
589
- ], R = ["spjluzl", "rlf", "clyzpvu", "rlf2", "nlaMbssFlhy"], Wn = [
584
+ ), Cn = /* @__PURE__ */ new Date(), Ue = (e) => new Set(Array.from({ length: 9 }, e)), le = " - lewpylk", R = ["spjluzl", "rlf", "clyzpvu", "rlf2", "nlaMbssFlhy"], xn = [
590
585
  "<yi>Puchspk Spjluzl Rlf</><iy><iy>",
591
586
  "<yi>Tpzzpun Spjluzl Rlf</><iy><iy>",
592
- "Aopz spiyhyf pz hchpshisl dpao ivao Jvttlyjphs huk Vwlu-Zvbyjl spjluzlz.<iy><iy><i>Jvttlyjphs Spjluzl</><iy>Mvy jvttlyjphs bzl, <p>pmyhtl-ylzpgly</> ylxbpylz h svd jvza vul aptl spjluzl mll. Mvy tvyl pumvythapvu cpzpa <b>oaawz://pmyhtl-ylzpgly.jvt/wypjpun</>.<iy><iy><i>Vwlu Zvbyjl Spjluzl</><iy>Pm fvb hyl bzpun aopz spiyhyf pu h uvu-jvttlyjphs vwlu zvbyjl wyvqlja aolu fvb jhu bzl pa mvy myll bukly aol alytz vm aol NWS C3 Spjluzl. Av jvumpyt fvb hjjlwa aolzl alytz, wslhzl zla aol <i>spjluzl</> rlf pu <p>pmyhtl-ylzpgly</> vwapvuz av <i>NWSc3</>.<iy><iy>Mvy tvyl pumvythapvu wslhzl zll: <b>oaawz://pmyhtl-ylzpgly.jvt/nws</>",
587
+ "Aopz spiyhyf pz hchpshisl dpao ivao Jvttlyjphs huk Vwlu-Zvbyjl spjluzlz.<iy><iy><i>Jvttlyjphs Spjluzl</><iy>Mvy jvttlyjphs bzl, <p>pmyhtl-ylzpgly</> ylxbpylz h svd jvza vul aptl spjluzl mll. Mvy tvyl pumvythapvu cpzpa <b>oaawz://pmyhtl-ylzpgly.jvt/wypjpun</>.<iy><iy><i>Vwlu Zvbyjl Spjluzl</><iy>Pm fvb hyl bzpun aopz spiyhyf pu h uvu-jvttlyjphs vwlu zvbyjl wyvqlja aolu fvb jhu bzl pa mvy myll bukly aol alytz vm aol NWS C3 Spjluzl. Av jvumpyt fvb hjjlwa aolzl alytz, wslhzl zla aol <i>spjluzl</> rlf pu <p>pmyhtl-ylzpgly</> vwapvuz av <i>NWSc3</>. Mvy tvyl pumvythapvu wslhzl zll: <b>oaawz://pmyhtl-ylzpgly.jvt/nws</>",
593
588
  "<i>NWSc3 Spjluzl Clyzpvu</><iy><iy>Aopz clyzpvu vm <p>pmyhtl-ylzpgly</> pz ilpun bzlk bukly aol alytz vm aol <i>NWS C3</> spjluzl. Aopz spjluzl hssvdz fvb av bzl <p>pmyhtl-ylzpgly</> pu Vwlu Zvbyjl wyvqljaz, iba pa ylxbpylz fvby wyvqlja av il wbispj, wyvcpkl haaypibapvu huk il spjluzlk bukly clyzpvu 3 vy shaly vm aol NUB Nlulyhs Wbispj Spjluzl.<iy><iy>Pm fvb hyl bzpun aopz spiyhyf pu h uvu-vwlu zvbyjl wyvqlja vy dlizpal, fvb dpss ullk av wbyjohzl h svd jvza vul aptl jvttlyjphs spjluzl.<iy><iy>Mvy tvyl pumvythapvu cpzpa <b>oaawz://pmyhtl-ylzpgly.jvt/wypjpun</>.",
594
589
  "<iy><yi>Zvsv spjluzl kvlz uva zbwwvya jyvzz-kvthpu</><iy><iy>Av bzl <p>pmyhtl-ylzpgly</> dpao jyvzz kvthpu pmyhtlz fvb ullk lpaoly aol Wyvmlzzpvuhs vy Ibzpulzz spjluzlz. Mvy klahpsz vu bwnyhkl wypjpun wslhzl jvuahja pumv@pmyhtl-ylzpgly.jvt.",
595
590
  "Pu whnl spurpun ylxbpylz h Wyvmlzzpvuhs vy Ibzpulzz spjluzl. Wslhzl zll <b>oaawz://pmyhtl-ylzpgly.jvt/wypjpun</> mvy tvyl klahpsz.",
596
- "<yi>Clyzpvu 5 rlf klaljalk</><iy><iy>Av bwnyhkl av <i>Clyzpvu 6</> vm <p>pmyhtl-ylzpgly</> fvb jhu bzl aol mpyza 11 johyhjalyz vm fvb spjlujl rlf av nla h 60% kpzjvbua ha <ii>oaaw://pmyhtl-ylzpgly.jvt</>.",
597
- // Upgrade
598
- "<yi>Clyzpvu 5 rlf klaljalk</><iy><iy>Av bwnyhkl av clyzpvu 6 vm<p>pmyhtl-ylzpgly</> wslhzl kvdusvhk aol shalza rlf myvt sltvu-zxbllgf.jvt.",
599
- // Upgrade OEM
600
- "<yi>VLT rlf lewpylk</><iy><iy>Wslhzl kvdusvhk aol shalza rlf myvt sltvu-zxbllgf.jvt."
601
- // key expired
602
- ], Dn = Bn(["NWSc3", "zvsv", "wyv", "ibzpulzz", "VLT"]), ae = Object.fromEntries(
591
+ "<yi>Clyzpvu 5 rlf klaljalk</><iy><iy>Fvb hyl jbyyluasf bzpun h spjluzl rlf mvy aol wylcpvbz clyzpvu vm <p>pmyhtl-ylzpgly</>.</><iy><iy>Av bwnyhkl av <i>Clyzpvu 6</> fvb jhu bzl aol <i>mpyza 11 johyhjalyz vm fvb spjluzl rlf</> av nla h 60% kpzjvbua ha oaawz://pmyhtl-ylzpgly.jvt/wypjpun.",
592
+ "<yi>Clyzpvu 5 rlf klaljalk</><iy><iy>Fvb hyl jbyyluasf bzpun h spjluzl rlf mvy aol wylcpvbz clyzpvu vm <p>pmyhtl-ylzpgly</>.<iy><iy>Av bwnyhkl av <i>Clyzpvu 6</> vm <p>pmyhtl-ylzpgly</> wslhzl kvdusvhk aol shalza rlf myvt oaawz://pmyhtl-ylzpgly.jvt/tf-vyklyz.",
593
+ "<yi> VLT rlf lewpylk</><iy><iy>Aol spjluzl rlf fvb hyl bzpun mvy <p>pmyhtl-ylzpgly</> pz myvt h wypvy flhy huk ohz lewpylk. Hu bwkhalk rlf pz ylslhzlk vu aol mpyza vm Uvcltily lhjo flhy.<iy><iy>Wslhzl kvdusvhk aol shalza rlf myvt oaawz://pmyhtl-ylzpgly.jvt/tf-vyklyz.",
594
+ "<yi>Bzl dpao slnhjf jspluaz</><iy><iy>Dolu bzpun <p>pmyhtl-ylzpgly</> jopsk whjrhnl dpao hu vskly clyzpvu vm aol whylua, fvb jhu zla aol spjluzl rlf pu aol pmyhtl. Mvy klahpsz vu ovd av zla aopz bw, wslhzl zll aol kvjbtluahapvu ha:<iy><iy>oaawz://pmyhtl-ylzpgly.jvt/zlabw/jopsk/#spjluzl"
595
+ ], _n = (e) => [
596
+ e[0],
597
+ ...e.slice(1).map((t) => `${t}${le}`),
598
+ `${e[4]}${le}`,
599
+ ...e.slice(1)
600
+ ], Bn = _n(["NWSc3", "zvsv", "wyv", "ibzpulzz", "VLT"]), ae = Object.fromEntries(
603
601
  [
604
602
  "2cgs7fdf4xb",
605
603
  "1c9ctcccr4z",
@@ -613,114 +611,114 @@ const W = (e) => {
613
611
  "oclbb4thgl",
614
612
  "igb1wzrjqr"
615
613
  ].map((e, t) => [e, Math.max(0, t - 1)])
616
- ), Ze = Fn[v(R[4])](), Hn = qe((e, t) => W(`${Ze + t}`)), Gn = qe((e, t) => W(`${Ze - ++t}`)), Un = (e) => Hn.has(e) ? 9 : Gn.has(e) ? 5 : -2, O = (e) => v(Wn[e]), Vn = (e) => v(Dn[e]), qn = (e) => {
614
+ ), qe = Cn[v(R[4])](), Fn = Ue((e, t) => H(`${qe + t}`)), Hn = Ue((e, t) => H(`${qe - ++t}`)), Wn = (e) => Fn.has(e) ? 9 : Hn.has(e) ? 5 : -2, O = (e) => v(xn[e]), Dn = (e) => v(Bn[e]), Gn = (e) => {
617
615
  const t = e[v(R[0])] || e[v(R[1])] || e[v(R[2])] || e[v(R[3])];
618
616
  if (!t) return -1;
619
617
  const n = t.split("-");
620
- let o = (function(s = "", c = "") {
618
+ let o = (function(s = "", a = "") {
621
619
  let r = -2;
622
- const a = W(v(s));
623
- return a in ae && (r = ae[a]), r === 9 ? Un(c) : r;
620
+ const l = H(v(s));
621
+ return l in ae && (r = ae[l]), r === 9 ? Wn(a) : r;
624
622
  })(...n);
625
- return o === 0 || ((s) => s[2] === W(s[0] + s[1]))(n) || (o = -2), o;
623
+ return o === 0 || ((s) => s[2] === H(s[0] + s[1]))(n) || (o = -2), o;
626
624
  };
627
- let J = !1, Je = !1;
628
- function Ye(e, t = -3) {
625
+ let J = !1, Ze = !1;
626
+ function Je(e, t = -3) {
629
627
  if (J) return;
630
628
  const n = Math.max(i[e].mode, t);
631
629
  if (n > i[e].mode && (i[e].mode = n), n < 0)
632
630
  throw Zt(e), i[e].vAdvised || m(e || "Parent", `${O(n + 2)}${O(2)}`), i[e].vAdvised = !0, O(n + 2).replace(/<\/?[a-z][^>]*>|<\/>/gi, "");
633
- switch (n > 5 && Je || Yt(`v${_} (${Vn(n)})`, n), n) {
631
+ switch (n > 5 && Ze || Yt(`v${_} (${Dn(n)})`, n), n) {
634
632
  case 1:
635
633
  case 2:
636
634
  case 3:
637
- m(e, O(6));
635
+ m("Parent", O(6));
638
636
  break;
639
637
  case 4:
640
- m(e, O(7));
638
+ m("Parent", O(7));
641
639
  break;
642
640
  case 5:
643
- m(e, O(8));
641
+ m("Parent", O(8));
644
642
  break;
645
643
  default:
646
644
  n < 1 && m("Parent", O(3));
647
645
  }
648
646
  J = !0;
649
647
  }
650
- function Zn(e) {
648
+ function Vn(e) {
651
649
  if (J) return;
652
650
  const { mode: t } = i[e];
653
- t > 5 && Ye(e, t);
651
+ t > 5 && Je(e, t);
654
652
  }
655
- function Jn(e) {
656
- e?.log === -1 && (e.log = !1, Je = !0);
653
+ function Un(e) {
654
+ e?.log === -1 && (e.log = !1, Ze = !0);
657
655
  }
658
- function Yn(e, t) {
659
- i[e] && (u(e, `First run for ${e}`), Ye(e, t === void 0 ? void 0 : Number(t)), i[e].firstRun = !1);
656
+ function qn(e, t) {
657
+ i[e] && (u(e, `First run for ${e}`), Je(e, t === void 0 ? void 0 : Number(t)), i[e].firstRun = !1);
660
658
  }
661
- function Xn(e) {
662
- const { height: t, id: n, iframe: o, mode: s, message: c, type: r, width: a } = e, { lastMessage: f } = i[n];
663
- switch (i[n]?.firstRun && Yn(n, s), u(n, `Received: %c${f}`, l), r) {
659
+ function Zn(e) {
660
+ const { height: t, id: n, iframe: o, mode: s, message: a, type: r, width: l } = e, { lastMessage: f } = i[n];
661
+ switch (i[n]?.firstRun && qn(n, s), u(n, `Received: %c${f}`, c), r) {
664
662
  case ge:
665
663
  i[n].autoResize = JSON.parse(x(n, 9));
666
664
  break;
667
- case it:
665
+ case ot:
668
666
  y(n, "Ready state reset"), i[n].initialised = !1;
669
667
  break;
668
+ case it:
669
+ _e(o);
670
+ break;
670
671
  case st:
671
- Fe(o);
672
+ Ln(n, x(n, 9));
672
673
  break;
673
- case rt:
674
- Cn(n, x(n, 9));
674
+ case $:
675
+ re(e), dn(n), yn(n, a), i[n].initialised = !0, k(n, "onReady", o);
675
676
  break;
676
- case j:
677
- ce(e), bn(n), vn(n, c), i[n].initialised = !0, I(n, "onReady", o);
677
+ case L:
678
+ mn(e, x(n, 6));
678
679
  break;
679
- case A:
680
- wn(e, x(n, 6));
680
+ case lt:
681
+ ie("onMouseEnter", e);
681
682
  break;
682
683
  case at:
683
- se("onMouseEnter", e);
684
+ ie("onMouseLeave", e);
684
685
  break;
685
- case lt:
686
- se("onMouseLeave", e);
687
- break;
688
- case ye:
689
- In(n);
686
+ case me:
687
+ En(n);
690
688
  break;
691
689
  case be:
692
- Sn(n);
690
+ jn(n);
693
691
  break;
694
- case ut:
695
- kn(n);
692
+ case ct:
693
+ On(n);
696
694
  break;
697
- case ft:
698
- jn(n);
695
+ case ut:
696
+ In(n);
699
697
  break;
700
- case U:
698
+ case V:
701
699
  Be(e);
702
700
  break;
703
- case ht:
704
- Rn(e);
701
+ case ft:
702
+ Mn(e);
705
703
  break;
706
704
  case pt:
707
- Ln(e);
705
+ Sn(e);
708
706
  break;
709
- case gt:
710
- An(e);
707
+ case ht:
708
+ $n(e);
711
709
  break;
712
- case dt:
713
- _n(n, c);
710
+ case gt:
711
+ Nn(n, a);
714
712
  break;
715
713
  default:
716
- if (a === 0 && t === 0) {
717
- z(
714
+ if (l === 0 && t === 0) {
715
+ w(
718
716
  n,
719
717
  `Unsupported message received (${r}), this is likely due to the iframe containing a later version of iframe-resizer than the parent page`
720
718
  );
721
719
  return;
722
720
  }
723
- if (a === 0 || t === 0) {
721
+ if (l === 0 || t === 0) {
724
722
  u(n, "Ignoring message with 0 height or width");
725
723
  return;
726
724
  }
@@ -728,42 +726,42 @@ function Xn(e) {
728
726
  u(n, "Page hidden - ignored resize request");
729
727
  return;
730
728
  }
731
- ce(e);
729
+ re(e);
732
730
  }
733
731
  }
734
- const Kn = (e) => ({
732
+ const Jn = (e) => ({
735
733
  initChild: t,
736
734
  postMessageTarget: n
737
735
  }) => {
738
736
  e === n && t();
739
- }, Qn = (e) => Object.values(i).forEach(Kn(e));
740
- function le(e) {
737
+ }, Yn = (e) => Object.values(i).forEach(Jn(e));
738
+ function ce(e) {
741
739
  const t = e.data;
742
- if (t === ot) {
743
- Qn(e.source);
740
+ if (t === nt) {
741
+ Yn(e.source);
744
742
  return;
745
743
  }
746
- if (!mn(t)) {
747
- if (typeof t !== X) return;
748
- b(V, "ignoredMessage"), Vt(V, t);
744
+ if (!hn(t)) {
745
+ if (typeof t !== Y) return;
746
+ b(U, "ignoredMessage"), Ut(U, t);
749
747
  return;
750
748
  }
751
- const n = hn(t), { id: o, type: s } = n;
749
+ const n = cn(t), { id: o, type: s } = n;
752
750
  switch (b(o, s), !0) {
753
751
  case !i[o]:
754
752
  throw new Error(`${s} No settings for ${o}. Message was: ${t}`);
755
- case !gn(n):
756
- case yn(n):
757
- case !dn(n, e):
753
+ case !fn(n):
754
+ case gn(n):
755
+ case !pn(n, e):
758
756
  return;
759
757
  default:
760
- i[o].lastMessage = e.data, Ae(o, Xn)(n);
758
+ i[o].lastMessage = e.data, Ae(o, Zn)(n);
761
759
  }
762
760
  }
763
- const eo = jt(() => {
764
- N(window, A, le), N(document, "visibilitychange", ln), window.iframeParentListener = (e) => setTimeout(() => le({ data: e, sameOrigin: !0 }));
761
+ const Xn = Rt(() => {
762
+ N(window, L, ce), N(document, "visibilitychange", rn), window.iframeParentListener = (e) => setTimeout(() => ce({ data: e, sameOrigin: !0 }));
765
763
  }), ue = {};
766
- function to(e) {
764
+ function Kn(e) {
767
765
  if (ue[e] === !0) return !1;
768
766
  const t = document.querySelectorAll(`iframe#${CSS.escape(e)}`);
769
767
  if (t.length <= 1) return !0;
@@ -784,151 +782,140 @@ Found <bb>${t.length}</> iframes with the <b>${e}</> ID:`,
784
782
  C
785
783
  ), !1;
786
784
  }
787
- const no = `<rb>Deprecated Method Name</>
788
-
789
- The <b>removeListeners()</> method has been renamed to <b>disconnect()</>. ${$e}`, oo = `<rb>Deprecated Method</>
790
-
791
- Use of the <b>resize()</> method from the parent page is deprecated and will be removed in a future version of <i>iframe-resizer</>. As there are no longer any edge cases that require triggering a resize from the parent page, it is recommended to remove this method from your code.`;
792
- function io(e) {
785
+ function Qn(e) {
793
786
  if (i[e]) {
794
- const { iframe: t } = i[e], n = {
795
- close: Fe.bind(null, t),
796
- disconnect: _e.bind(null, t),
797
- moveToAnchor(o) {
798
- Nt(o, X, "moveToAnchor(anchor) anchor"), T("Move to anchor", `moveToAnchor:${o}`, e);
787
+ const { iframe: t } = i[e];
788
+ t.iframeResizer = {
789
+ close: _e.bind(null, t),
790
+ disconnect: xe.bind(null, t),
791
+ moveToAnchor(n) {
792
+ Ct(n, Y, "moveToAnchor(anchor) anchor"), S("Move to anchor", `moveToAnchor:${n}`, e);
799
793
  },
800
- removeListeners() {
801
- m(e, no), this.disconnect();
802
- },
803
- resize() {
804
- m(e, oo), T("Window resize", Y, e);
805
- },
806
- sendMessage(o) {
807
- o = JSON.stringify(o), T(A, `${A}:${o}`, e);
794
+ sendMessage(n) {
795
+ n = JSON.stringify(n), S(L, `${L}:${n}`, e);
808
796
  }
809
797
  };
810
- t.iframeResizer = n, t.iFrameResizer = n;
811
798
  }
812
799
  }
813
- const so = "8", ro = "32", co = zt, ao = !0;
814
- function lo(e) {
800
+ const eo = "8", to = "32", no = zt, oo = !0;
801
+ function io(e) {
815
802
  const {
816
803
  autoResize: t,
817
804
  bodyBackground: n,
818
805
  bodyMargin: o,
819
806
  bodyPadding: s,
820
- heightCalculationMethod: c,
807
+ heightCalculationMethod: a,
821
808
  inPageLinks: r,
822
- license: a,
809
+ license: l,
823
810
  log: f,
824
- logExpand: h,
825
- mouseEvents: g,
826
- offsetHeight: $,
811
+ logExpand: p,
812
+ mouseEvents: h,
813
+ offsetHeight: j,
827
814
  offsetWidth: d,
828
815
  mode: E,
829
- sizeHeight: Xe,
816
+ sizeHeight: Ye,
830
817
  // sizeSelector,
831
- sizeWidth: Ke,
832
- tolerance: Qe,
833
- widthCalculationMethod: et
818
+ sizeWidth: Xe,
819
+ tolerance: Ke,
820
+ widthCalculationMethod: Qe
834
821
  } = i[e];
835
822
  return [
836
823
  e,
837
- so,
838
- Ke,
824
+ eo,
825
+ Xe,
839
826
  f,
840
- ro,
841
- ao,
827
+ to,
828
+ oo,
842
829
  t,
843
830
  o,
844
- c,
831
+ a,
845
832
  n,
846
833
  s,
847
- Qe,
834
+ Ke,
848
835
  r,
849
- co,
850
- et,
851
- g,
852
- $,
836
+ no,
837
+ Qe,
838
+ h,
839
+ j,
853
840
  d,
854
- Xe,
855
- a,
856
- p.version,
841
+ Ye,
842
+ l,
843
+ g.version,
857
844
  E,
858
845
  "",
859
846
  // sizeSelector,
860
- h
861
- ].join(L);
847
+ p
848
+ ].join(A);
862
849
  }
863
- const uo = "0";
864
- function fo(e) {
850
+ const so = "0";
851
+ function ro(e) {
865
852
  const { bodyMargin: t } = i[e];
866
- (typeof t === Et || t === uo) && (i[e].bodyMargin = `${t}px`);
853
+ (typeof t === wt || t === so) && (i[e].bodyMargin = `${t}px`);
867
854
  }
868
- const ho = (e) => {
855
+ const lo = (e) => {
869
856
  try {
870
857
  return new URL(e).origin;
871
858
  } catch {
872
859
  return null;
873
860
  }
874
- }, po = (e) => typeof e === ve && e.length > 0 && !(e.contains("allow-scripts") && e.contains("allow-same-origin"));
875
- function go(e, t) {
861
+ }, ao = (e) => typeof e === ze && e.length > 0 && !(e.contains("allow-scripts") && e.contains("allow-same-origin"));
862
+ function co(e, t) {
876
863
  const {
877
864
  checkOrigin: n,
878
865
  iframe: { src: o, sandbox: s },
879
- initialisedFirstPage: c,
866
+ initialisedFirstPage: a,
880
867
  waitForLoad: r
881
- } = t[e], a = ho(o);
868
+ } = t[e], l = lo(o);
882
869
  b(e, "noResponse"), m(
883
870
  e,
884
871
  `<rb>No response from iframe</>
885
872
 
886
873
  The iframe (<i>${e}</>) has not responded within ${t[e].warningTimeout / 1e3} seconds. Check <b>@iframe-resizer/child</> package has been loaded in the iframe.
887
- ${n && a ? `
888
- The <b>checkOrigin</> option is currently enabled. If the iframe redirects away from <i>${a}</>, then the connection to the iframe may be blocked by the browser. To disable this option, set <b>checkOrigin</> to <bb>false</> or an array of allowed origins. See <u>https://iframe-resizer.com/checkorigin</> for more information.
889
- ` : ""}${r && !c ? `
874
+ ${n && l ? `
875
+ The <b>checkOrigin</> option is currently enabled. If the iframe redirects away from <i>${l}</>, then the connection to the iframe may be blocked by the browser. To disable this option, set <b>checkOrigin</> to <bb>false</> or an array of allowed origins. See <u>https://iframe-resizer.com/checkorigin</> for more information.
876
+ ` : ""}${r && !a ? `
890
877
  The <b>waitForLoad</> option is currently set to <bb>true</>. If the iframe loads before <i>iframe-resizer</> runs, this option will prevent <i>iframe-resizer</> initialising. To disable this option, set <b>waitForLoad</> to <bb>false</>.
891
- ` : ""}${po(s) ? `
878
+ ` : ""}${ao(s) ? `
892
879
  The iframe has the <b>sandbox</> attribute, please ensure it contains both the <bb>allow-same-origin</> and <bb>allow-scripts</> values.
893
880
  ` : ""}
894
881
  This message can be ignored if everything is working, or you can set the <b>warningTimeout</> option to a higher value or zero to suppress this warning.
895
882
  `
896
883
  );
897
884
  }
898
- function mo(e, t) {
885
+ function uo(e, t) {
899
886
  function n() {
900
887
  if (t[e] === void 0) return;
901
- const { initialised: c, loadErrorShown: r } = t[e];
902
- if (t[e].msgTimeout = void 0, c) {
888
+ const { initialised: a, loadErrorShown: r } = t[e];
889
+ if (t[e].msgTimeout = void 0, a) {
903
890
  t[e].initialisedFirstPage = !0;
904
891
  return;
905
892
  }
906
- r || (t[e].loadErrorShown = !0, go(e, t));
893
+ r || (t[e].loadErrorShown = !0, co(e, t));
907
894
  }
908
895
  const { msgTimeout: o, warningTimeout: s } = t[e];
909
896
  s && (o && clearTimeout(o), t[e].msgTimeout = setTimeout(n, s));
910
897
  }
911
- const yo = 1, bo = (e) => e.loading === ct, vo = (e) => e === j;
912
- function wo(e) {
913
- i[e]?.heightCalculationMethod in kt && Be({
898
+ const fo = 1, po = (e) => e.loading === rt, ho = (e) => e === $;
899
+ function go(e) {
900
+ i[e]?.heightCalculationMethod in jt && Be({
914
901
  id: e,
915
902
  iframe: i[e].iframe,
916
- height: ee,
917
- width: ee,
918
- type: j
903
+ height: Q,
904
+ width: Q,
905
+ type: $
919
906
  });
920
907
  }
921
- function zo(e, t) {
922
- N(e, G, () => setTimeout(t, yo));
908
+ function yo(e, t) {
909
+ N(e, G, () => setTimeout(t, fo));
923
910
  }
924
- const Eo = (e) => {
911
+ const mo = (e) => {
925
912
  const { src: t, srcdoc: n } = e;
926
913
  return !n && (t == null || t === "" || t === "about:blank");
927
914
  };
928
- function Oo(e, t) {
915
+ function bo(e, t) {
929
916
  const { iframe: n, waitForLoad: o } = i[e];
930
917
  if (o !== !0) {
931
- if (Eo(n)) {
918
+ if (mo(n)) {
932
919
  setTimeout(() => {
933
920
  b(e, "noContent"), y(e, "No content detected in the iframe, delaying initialisation");
934
921
  });
@@ -937,34 +924,34 @@ function Oo(e, t) {
937
924
  setTimeout(t);
938
925
  }
939
926
  }
940
- function To(e, t) {
927
+ function vo(e, t) {
941
928
  const n = (s) => () => {
942
929
  if (!i[e]) return;
943
- const { firstRun: c, iframe: r } = i[e];
944
- T(s, t, e), vo(s) && bo(r) || mo(e, i), c || wo(e);
930
+ const { firstRun: a, iframe: r } = i[e];
931
+ S(s, t, e), ho(s) && po(r) || uo(e, i), a || go(e);
945
932
  }, { iframe: o } = i[e];
946
- i[e].initChild = n(de), zo(o, n(me)), Oo(e, n(j));
933
+ i[e].initChild = n(de), yo(o, n(ye)), bo(e, n($));
947
934
  }
948
- function Io(e, t) {
935
+ function zo(e, t) {
949
936
  return t ? (("sizeWidth" in t || "sizeHeight" in t || ge in t) && m(
950
937
  e,
951
938
  `<rb>Deprecated Option</>
952
939
 
953
- The <b>sizeWidth</>, <b>sizeHeight</> and <b>autoResize</> options have been replaced with new <b>direction</> option which expects values of <bb>${D}</>, <bb>${Oe}</>, <bb>${Ee}</> or <bb>${ze}</>.
940
+ The <b>sizeWidth</>, <b>sizeHeight</> and <b>autoResize</> options have been replaced with new <b>direction</> option which expects values of <bb>${W}</>, <bb>${Oe}</>, <bb>${Ee}</> or <bb>${we}</>.
954
941
  `
955
942
  ), t) : {};
956
943
  }
957
- function ko(e) {
958
- i[e].warningTimeout || y(e, "warningTimeout:%c disabled", l);
944
+ function wo(e) {
945
+ i[e].warningTimeout || y(e, "warningTimeout:%c disabled", c);
959
946
  }
960
- function $o(e, { offset: t, offsetSize: n }) {
947
+ function Eo(e, { offset: t, offsetSize: n }) {
961
948
  const o = n || t;
962
- o && (i[e].direction === D ? (i[e].offsetHeight = o, u(e, `Offset height: %c${o}`, l)) : (i[e].offsetWidth = o, u(e, `Offset width: %c${o}`, l)));
949
+ o && (i[e].direction === W ? (i[e].offsetHeight = o, u(e, `Offset height: %c${o}`, c)) : (i[e].offsetWidth = o, u(e, `Offset width: %c${o}`, c)));
963
950
  }
964
- function Mo(e) {
951
+ function Oo(e) {
965
952
  const { direction: t } = i[e];
966
953
  switch (t) {
967
- case D:
954
+ case W:
968
955
  break;
969
956
  case Oe:
970
957
  i[e].sizeHeight = !1;
@@ -972,100 +959,100 @@ function Mo(e) {
972
959
  case Ee:
973
960
  i[e].sizeWidth = !0;
974
961
  break;
975
- case ze:
962
+ case we:
976
963
  i[e].sizeWidth = !1, i[e].sizeHeight = !1, i[e].autoResize = !1;
977
964
  break;
978
965
  default:
979
966
  throw new TypeError(`Direction value of "${t}" is not valid`);
980
967
  }
981
- u(e, `direction: %c${t}`, l);
968
+ u(e, `direction: %c${t}`, c);
982
969
  }
983
970
  const fe = (e) => e === "" || e.match(/^(about:blank|javascript:|file:\/\/)/) !== null ? "*" : e;
984
- function So(e) {
971
+ function ko(e) {
985
972
  const { checkOrigin: t, remoteHost: n } = i[e];
986
- Array.isArray(t) && t.length === 0 && z(
973
+ Array.isArray(t) && t.length === 0 && w(
987
974
  e,
988
975
  "checkOrigin is an empty array — no messages will be sent to the iframe"
989
976
  ), i[e].targetOrigin = Array.isArray(t) ? t.map(fe) : [t === !1 ? "*" : fe(n)];
990
977
  }
991
- function jo(e) {
978
+ function To(e) {
992
979
  const { id: t } = e;
993
980
  i[t].postMessageTarget === null && (i[t].postMessageTarget = e.contentWindow);
994
981
  }
995
- function H(e, t, n) {
982
+ function D(e, t, n) {
996
983
  P(i[e], t) && (m(
997
984
  e,
998
985
  `<rb>Deprecated option</>
999
986
 
1000
- The <b>${t}</> option has been renamed to <b>${n}</>. ${$e}`
987
+ The <b>${t}</> option has been renamed to <b>${n}</>. ${Mt}`
1001
988
  ), i[e][n] = i[e][t], delete i[e][t]);
1002
989
  }
1003
- function Ro(e) {
1004
- H(e, bt, vt), H(e, "onClose", "onBeforeClose"), H(e, "onClosed", "onAfterClose");
990
+ function jo(e) {
991
+ D(e, mt, bt), D(e, "onClose", "onBeforeClose"), D(e, "onClosed", "onAfterClose");
1005
992
  }
1006
- const Lo = (e) => P(e, "onMouseEnter") || P(e, "onMouseLeave");
1007
- function Ao(e, t) {
993
+ const Io = (e) => P(e, "onMouseEnter") || P(e, "onMouseLeave");
994
+ function Mo(e, t) {
1008
995
  const { id: n } = e;
1009
996
  i[n] = {
1010
997
  ...i[n],
1011
998
  iframe: e,
1012
999
  remoteHost: e?.src.split("/").slice(0, 3).join("/"),
1013
- ...B,
1014
- ...Io(n, t),
1015
- mouseEvents: Lo(t),
1016
- mode: qn(t),
1017
- syncTitle: xn(n)
1018
- }, Ro(n), Mo(n), $o(n, t), ko(n), jo(e), So(n);
1019
- }
1020
- const Po = "yes", he = "no";
1021
- function No(e) {
1000
+ ...F,
1001
+ ...zo(n, t),
1002
+ mouseEvents: Io(t),
1003
+ mode: Gn(t),
1004
+ syncTitle: Pn(n)
1005
+ }, jo(n), Oo(n), Eo(n, t), wo(n), To(e), ko(n);
1006
+ }
1007
+ const So = "yes", pe = "no";
1008
+ function $o(e) {
1022
1009
  const { id: t } = e;
1023
1010
  switch (u(
1024
1011
  t,
1025
1012
  `Iframe scrolling ${i[t]?.scrolling ? "enabled" : "disabled"} for ${t}`
1026
- ), e.style.overflow = i[t]?.scrolling === !1 ? wt : q, i[t]?.scrolling) {
1027
- case Tt:
1013
+ ), e.style.overflow = i[t]?.scrolling === !1 ? vt : q, i[t]?.scrolling) {
1014
+ case kt:
1028
1015
  break;
1029
1016
  case !0:
1030
- e.scrolling = Po;
1017
+ e.scrolling = So;
1031
1018
  break;
1032
1019
  case !1:
1033
- e.scrolling = he;
1020
+ e.scrolling = pe;
1034
1021
  break;
1035
1022
  default:
1036
- e.scrolling = i[t]?.scrolling || he;
1023
+ e.scrolling = i[t]?.scrolling || pe;
1037
1024
  }
1038
1025
  }
1039
- function Co(e, t, n) {
1040
- Ao(t, n), u(e, `src: %c${t.srcdoc || t.src}`, l), Zn(e), No(t), fo(e), To(e, lo(e)), io(e), u(e, "Setup complete");
1026
+ function Ro(e, t, n) {
1027
+ Mo(t, n), u(e, `src: %c${t.srcdoc || t.src}`, c), Vn(e), $o(t), ro(e), vo(e, io(e)), Qn(e), u(e, "Setup complete");
1041
1028
  }
1042
- function xo(e, t) {
1029
+ function Ao(e, t) {
1043
1030
  const { id: n } = e;
1044
- b(n, "setup"), to(n) && Co(n, e, t), Jt(n);
1031
+ b(n, "setup"), Kn(n) && Ro(n, e, t), Jt(n);
1045
1032
  }
1046
- function _o(e, t) {
1047
- t.log === Te ? t.log = !1 : t.log === Ie ? t.log = S : t.log === ke && (t.log = M);
1048
- const n = P(t, "log"), o = K(t.log), s = n ? o ? !0 : t.log : B.log;
1049
- P(t, "logExpand") || (t.logExpand = n && o ? t.log === M : B.logExpand), Jn(t), Ut({
1033
+ function Lo(e, t) {
1034
+ t.log === ke ? t.log = !1 : t.log === Te ? t.log = M : t.log === je && (t.log = I);
1035
+ const n = P(t, "log"), o = X(t.log), s = n ? o ? !0 : t.log : F.log;
1036
+ P(t, "logExpand") || (t.logExpand = n && o ? t.log === I : F.logExpand), Un(t), Vt({
1050
1037
  enabled: s,
1051
1038
  expand: t.logExpand,
1052
1039
  iframeId: e
1053
- }), o && !(t.log in $t) && qt(
1040
+ }), o && !(t.log in It) && qt(
1054
1041
  e,
1055
- `Invalid value for options.log: Accepted values are "${M}" and "${S}"`
1042
+ `Invalid value for options.log: Accepted values are "${I}" and "${M}"`
1056
1043
  ), t.log = s;
1057
1044
  }
1058
- function Bo(e) {
1059
- if (!Me(e)) throw new TypeError("Options is not an object");
1060
- return eo(), sn(e), (t) => {
1061
- const n = on(t, e);
1062
- return pe in t ? (b(n, "alreadySetup"), z(n, `Ignored iframe (${n}), already setup.`)) : (_o(n, e), Ae(n, xo)(t, e)), t?.iframeResizer;
1045
+ function No(e) {
1046
+ if (!Ie(e)) throw new TypeError("Options is not an object");
1047
+ return Xn(), tn(e), (t) => {
1048
+ const n = en(t, e);
1049
+ return he in t ? (b(n, "alreadySetup"), w(n, `Ignored iframe (${n}), already setup.`)) : (Lo(n, e), Ae(n, Ao)(t, e)), t?.iframeResizer;
1063
1050
  };
1064
1051
  }
1065
1052
  export {
1066
- Ie as LOG_COLLAPSED,
1067
- Te as LOG_DISABLED,
1068
- ke as LOG_EXPANDED,
1069
- Bo as default
1053
+ Te as LOG_COLLAPSED,
1054
+ ke as LOG_DISABLED,
1055
+ je as LOG_EXPANDED,
1056
+ No as default
1070
1057
  };
1071
1058
  //# sourceMappingURL=index.esm.js.map