@telia-ace/widget-runtime-flamingo 1.0.4 → 1.0.5

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.
@@ -1,16 +1,16 @@
1
- var Hn = Object.defineProperty, Vn = Object.defineProperties;
2
- var Bn = Object.getOwnPropertyDescriptors;
3
- var xe = Object.getOwnPropertySymbols;
4
- var Un = Object.prototype.hasOwnProperty, Wn = Object.prototype.propertyIsEnumerable;
5
- var $e = (n, t, e) => t in n ? Hn(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, dt = (n, t) => {
1
+ var Ur = Object.defineProperty, Br = Object.defineProperties;
2
+ var Vr = Object.getOwnPropertyDescriptors;
3
+ var on = Object.getOwnPropertySymbols, zr = Object.getPrototypeOf, Wr = Object.prototype.hasOwnProperty, Fr = Object.prototype.propertyIsEnumerable, Jr = Reflect.get;
4
+ var an = (n, t, e) => t in n ? Ur(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, st = (n, t) => {
6
5
  for (var e in t || (t = {}))
7
- Un.call(t, e) && $e(n, e, t[e]);
8
- if (xe)
9
- for (var e of xe(t))
10
- Wn.call(t, e) && $e(n, e, t[e]);
6
+ Wr.call(t, e) && an(n, e, t[e]);
7
+ if (on)
8
+ for (var e of on(t))
9
+ Fr.call(t, e) && an(n, e, t[e]);
11
10
  return n;
12
- }, Pe = (n, t) => Vn(n, Bn(t));
13
- var Zt = (n, t, e) => new Promise((r, s) => {
11
+ }, zt = (n, t) => Br(n, Vr(t));
12
+ var cn = (n, t, e) => Jr(zr(n), e, t);
13
+ var Q = (n, t, e) => new Promise((r, s) => {
14
14
  var i = (c) => {
15
15
  try {
16
16
  a(e.next(c));
@@ -26,7 +26,7 @@ var Zt = (n, t, e) => new Promise((r, s) => {
26
26
  }, a = (c) => c.done ? r(c.value) : Promise.resolve(c.value).then(i, o);
27
27
  a((e = e.apply(n, t)).next());
28
28
  });
29
- const Xt = (n, t, e, ...r) => {
29
+ const Oe = (n, t, e, ...r) => {
30
30
  const s = `[${n.get("$environment").name || "webprovisions"}] ${e}`;
31
31
  switch (t) {
32
32
  case "info":
@@ -39,16 +39,16 @@ const Xt = (n, t, e, ...r) => {
39
39
  console.error(s, ...r);
40
40
  break;
41
41
  }
42
- }, zn = (n) => {
42
+ }, qr = (n) => {
43
43
  const t = n.container || n;
44
44
  return {
45
- info: (e, ...r) => Xt(t, "info", e, ...r),
46
- warn: (e, ...r) => Xt(t, "warning", e, ...r),
47
- error: (e, ...r) => Xt(t, "error", e, ...r)
45
+ info: (e, ...r) => Oe(t, "info", e, ...r),
46
+ warn: (e, ...r) => Oe(t, "warning", e, ...r),
47
+ error: (e, ...r) => Oe(t, "error", e, ...r)
48
48
  };
49
49
  };
50
- var Tt = /* @__PURE__ */ ((n) => (n.Implementation = "implementation", n.Widget = "widget", n))(Tt || {}), at = /* @__PURE__ */ ((n) => (n.Pre = "pre", n.Post = "post", n))(at || {});
51
- const Fn = (n, t, e, r) => {
50
+ var se = /* @__PURE__ */ ((n) => (n.Implementation = "implementation", n.Widget = "widget", n))(se || {}), pt = /* @__PURE__ */ ((n) => (n.Pre = "pre", n.Post = "post", n))(pt || {});
51
+ const Kr = (n, t, e, r) => {
52
52
  try {
53
53
  const s = new t(e, r);
54
54
  return {
@@ -72,23 +72,23 @@ const Fn = (n, t, e, r) => {
72
72
  throw s;
73
73
  }
74
74
  };
75
- function Se(n, t) {
75
+ function hn(n, t) {
76
76
  return typeof n == "undefined" ? t : n;
77
77
  }
78
- let Jn = class {
78
+ let Yr = class {
79
79
  constructor(t = {}) {
80
80
  this.part = t;
81
81
  }
82
82
  createCommand(t, e, r) {
83
83
  let s;
84
84
  typeof e == "function" ? s = {
85
- scope: Tt.Widget,
86
- stage: at.Post,
85
+ scope: se.Widget,
86
+ stage: pt.Post,
87
87
  defaultArgs: void 0,
88
88
  handlerResolver: e
89
89
  } : s = {
90
- scope: Se(e.scope, Tt.Widget),
91
- stage: Se(e.stage, at.Post),
90
+ scope: hn(e.scope, se.Widget),
91
+ stage: hn(e.stage, pt.Post),
92
92
  defaultArgs: e.defaultArgs,
93
93
  handlerResolver: r
94
94
  };
@@ -102,26 +102,26 @@ let Jn = class {
102
102
  return this.part;
103
103
  }
104
104
  };
105
- const fe = (n) => {
106
- const t = new Jn({});
105
+ const qe = (n) => {
106
+ const t = new Yr({});
107
107
  return n(t), t.get();
108
108
  };
109
- fe((n) => {
109
+ qe((n) => {
110
110
  n.createCommand(
111
111
  "types.register",
112
- { scope: Tt.Implementation, stage: at.Pre },
112
+ { scope: se.Implementation, stage: pt.Pre },
113
113
  (t) => (e, r) => {
114
114
  t.container.get("$types")[e] = r;
115
115
  }
116
116
  ).createCommand(
117
117
  "type",
118
- { stage: at.Pre },
118
+ { stage: pt.Pre },
119
119
  (t) => (e) => {
120
120
  t.container.register("$type", e);
121
121
  }
122
122
  ).createCommand(
123
123
  "settings",
124
- { stage: at.Pre, defaultArgs: [null] },
124
+ { stage: pt.Pre, defaultArgs: [null] },
125
125
  (t) => (e) => {
126
126
  t.events.dispatch(
127
127
  "settings:change",
@@ -131,28 +131,28 @@ fe((n) => {
131
131
  }
132
132
  ).createCommand(
133
133
  "plugin",
134
- { stage: at.Pre },
134
+ { stage: pt.Pre },
135
135
  (t) => (e, r, s) => {
136
136
  const { container: i } = t;
137
137
  let o = null, a = e, c = r;
138
138
  typeof e == "string" && (o = e, a = r, c = s);
139
- const h = (u) => {
140
- const { transformPluginSettings: l } = t.container.get("$environmentOptions"), d = l ? l(
139
+ const h = (l) => {
140
+ const { transformPluginSettings: u } = t.container.get("$environmentOptions"), d = u ? u(
141
141
  c || {},
142
142
  o,
143
143
  t.container,
144
144
  a
145
145
  ) : r;
146
146
  try {
147
- const f = Fn(
147
+ const p = Kr(
148
148
  o,
149
149
  a,
150
150
  i,
151
151
  d
152
152
  );
153
- i.get("$plugins").push(f), u && f.invoke("initialize", null);
154
- } catch (f) {
155
- zn(t).warn("Error when initializing plugin", f);
153
+ i.get("$plugins").push(p), l && p.invoke("initialize", null);
154
+ } catch (p) {
155
+ qr(t).warn("Error when initializing plugin", p);
156
156
  }
157
157
  };
158
158
  t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
@@ -185,8 +185,8 @@ fe((n) => {
185
185
  }
186
186
  );
187
187
  });
188
- var nn = /* @__PURE__ */ ((n) => (n.Activating = "activating", n.Loading = "loading", n.Activated = "activated", n.Deactivating = "deactivating", n.Deactivated = "deactivated", n))(nn || {});
189
- let Kn = class {
188
+ var Zn = /* @__PURE__ */ ((n) => (n.Activating = "activating", n.Loading = "loading", n.Activated = "activated", n.Deactivating = "deactivating", n.Deactivated = "deactivated", n))(Zn || {});
189
+ let Gr = class {
190
190
  /**
191
191
  * Creates a new `Widget` instance.
192
192
  * @param container The `Container` instance to base the widget upon.
@@ -197,16 +197,16 @@ let Kn = class {
197
197
  });
198
198
  }
199
199
  };
200
- var Ce = Object.getOwnPropertySymbols, qn = Object.prototype.hasOwnProperty, Yn = Object.prototype.propertyIsEnumerable, Gn = (n, t) => {
200
+ var ln = Object.getOwnPropertySymbols, Zr = Object.prototype.hasOwnProperty, Qr = Object.prototype.propertyIsEnumerable, Xr = (n, t) => {
201
201
  var e = {};
202
202
  for (var r in n)
203
- qn.call(n, r) && t.indexOf(r) < 0 && (e[r] = n[r]);
204
- if (n != null && Ce)
205
- for (var r of Ce(n))
206
- t.indexOf(r) < 0 && Yn.call(n, r) && (e[r] = n[r]);
203
+ Zr.call(n, r) && t.indexOf(r) < 0 && (e[r] = n[r]);
204
+ if (n != null && ln)
205
+ for (var r of ln(n))
206
+ t.indexOf(r) < 0 && Qr.call(n, r) && (e[r] = n[r]);
207
207
  return e;
208
208
  };
209
- function Qn(n = {}) {
209
+ function ts(n = {}) {
210
210
  const t = n, {
211
211
  phrase: e = "",
212
212
  category: r,
@@ -216,12 +216,12 @@ function Qn(n = {}) {
216
216
  connectionKey: a,
217
217
  accordion: c,
218
218
  id: h,
219
- uriName: u,
220
- sorting: l,
219
+ uriName: l,
220
+ sorting: u,
221
221
  tag: d,
222
- tagId: f,
223
- tagTitle: g
224
- } = t, E = Gn(t, [
222
+ tagId: p,
223
+ tagTitle: b
224
+ } = t, v = Xr(t, [
225
225
  "phrase",
226
226
  "category",
227
227
  "guideCategory",
@@ -235,34 +235,34 @@ function Qn(n = {}) {
235
235
  "tag",
236
236
  "tagId",
237
237
  "tagTitle"
238
- ]), p = {};
239
- return Object.keys(E).forEach((C) => {
240
- typeof n[C] == "string" && (p[C] = n[C]);
241
- }), typeof e == "string" && e.length && (p.phrase = e), e === null && (p.phrase = e), typeof s == "string" && s !== "0" && (p.guideCategory = s), typeof s == "number" && s !== 0 && (p.guideCategory = s), typeof s == "object" && s !== null && (typeof s.id == "string" && s.id !== "0" && (p.guideCategory = s.id), typeof s.id == "number" && s.id !== 0 && (p.guideCategory = s.id)), typeof i == "string" && i !== "0" && (p.contactCategory = i), typeof i == "number" && i !== 0 && (p.contactCategory = i), typeof i == "object" && i !== null && (typeof i.id == "string" && i.id !== "0" && (p.contactCategory = i.id), typeof i.id == "number" && i.id !== 0 && (p.contactCategory = i.id)), typeof r == "string" && r !== "0" && (p.category = r), typeof r == "number" && r !== 0 && (p.category = r), typeof r == "object" && r !== null && (typeof r.id == "string" && r.id !== "0" && (p.category = r.id), typeof r.id == "number" && r.id !== 0 && (p.category = r.id)), h && (p.id = h), u && (+p.category || +p.guideCategory || +p.guide || +p.contactCategory || +p.contactMethod) && (p.uriName = u), a && (p.connectionKey = a), o && (p.take = o), l && (p.sorting = l), typeof c == "string" && c.length > 0 && (p.accordion = c), typeof d == "string" && d !== "0" && (p.tag = d), typeof d == "number" && d !== 0 && (p.tag = d), Array.isArray(d) && d.length && (p.tag = d), (typeof f == "string" || typeof f == "number") && (p.tagId = f), typeof g == "string" && (p.tagTitle = g), typeof p.tag == "string" && (p.tag = p.tag.split(",")), p;
238
+ ]), g = {};
239
+ return Object.keys(v).forEach((E) => {
240
+ typeof n[E] == "string" && (g[E] = n[E]);
241
+ }), typeof e == "string" && e.length && (g.phrase = e), e === null && (g.phrase = e), typeof s == "string" && s !== "0" && (g.guideCategory = s), typeof s == "number" && s !== 0 && (g.guideCategory = s), typeof s == "object" && s !== null && (typeof s.id == "string" && s.id !== "0" && (g.guideCategory = s.id), typeof s.id == "number" && s.id !== 0 && (g.guideCategory = s.id)), typeof i == "string" && i !== "0" && (g.contactCategory = i), typeof i == "number" && i !== 0 && (g.contactCategory = i), typeof i == "object" && i !== null && (typeof i.id == "string" && i.id !== "0" && (g.contactCategory = i.id), typeof i.id == "number" && i.id !== 0 && (g.contactCategory = i.id)), typeof r == "string" && r !== "0" && (g.category = r), typeof r == "number" && r !== 0 && (g.category = r), typeof r == "object" && r !== null && (typeof r.id == "string" && r.id !== "0" && (g.category = r.id), typeof r.id == "number" && r.id !== 0 && (g.category = r.id)), h && (g.id = h), l && (+g.category || +g.guideCategory || +g.guide || +g.contactCategory || +g.contactMethod) && (g.uriName = l), a && (g.connectionKey = a), o && (g.take = o), u && (g.sorting = u), typeof c == "string" && c.length > 0 && (g.accordion = c), typeof d == "string" && d !== "0" && (g.tag = d), typeof d == "number" && d !== 0 && (g.tag = d), Array.isArray(d) && d.length && (g.tag = d), (typeof p == "string" || typeof p == "number") && (g.tagId = p), typeof b == "string" && (g.tagTitle = b), typeof g.tag == "string" && (g.tag = g.tag.split(",")), g;
242
242
  }
243
- const Ft = (n, t, ...e) => typeof t == "string" ? n(`[humany] ${t}`, ...e) : n(t, ...e), bt = class {
243
+ const pe = (n, t, ...e) => typeof t == "string" ? n(`[humany] ${t}`, ...e) : n(t, ...e), Nt = class {
244
244
  constructor() {
245
- this.keys = [], this.log = (t, ...e) => this.lookup(t, () => bt.log(...e)), this.warn = (t, ...e) => this.lookup(t, () => bt.warn(...e)), this.error = (t, ...e) => this.lookup(t, () => bt.error(...e)), this.info = (t, ...e) => this.lookup(t, () => bt.info(...e));
245
+ this.keys = [], this.log = (t, ...e) => this.lookup(t, () => Nt.log(...e)), this.warn = (t, ...e) => this.lookup(t, () => Nt.warn(...e)), this.error = (t, ...e) => this.lookup(t, () => Nt.error(...e)), this.info = (t, ...e) => this.lookup(t, () => Nt.info(...e));
246
246
  }
247
247
  lookup(t, e) {
248
248
  this.keys.indexOf(t) === -1 && (this.keys.push(t), e());
249
249
  }
250
250
  };
251
- let R = bt;
252
- R.log = (...n) => Ft(console.log, ...n);
253
- R.warn = (...n) => Ft(console.warn, ...n);
254
- R.error = (...n) => Ft(console.error, ...n);
255
- R.info = (...n) => Ft(console.info, ...n);
256
- const rn = (n) => {
251
+ let I = Nt;
252
+ I.log = (...n) => pe(console.log, ...n);
253
+ I.warn = (...n) => pe(console.warn, ...n);
254
+ I.error = (...n) => pe(console.error, ...n);
255
+ I.info = (...n) => pe(console.info, ...n);
256
+ const Qn = (n) => {
257
257
  let t = {}, e, r;
258
258
  if (typeof n != "object" || n === null)
259
259
  return n;
260
260
  t = Array.isArray(n) ? [] : {};
261
261
  for (r in n)
262
- e = n[r], t[r] = typeof e == "object" && e !== null ? rn(e) : e;
262
+ e = n[r], t[r] = typeof e == "object" && e !== null ? Qn(e) : e;
263
263
  return t;
264
- }, Zn = rn;
265
- function ke(n) {
264
+ }, es = Qn;
265
+ function un(n) {
266
266
  let t = 0;
267
267
  if (n.length === 0)
268
268
  return t.toString();
@@ -272,7 +272,7 @@ function ke(n) {
272
272
  }
273
273
  return t.toString();
274
274
  }
275
- let Xn = class {
275
+ let ns = class {
276
276
  constructor(t, e) {
277
277
  this.lockWarningTime = t, this.lockErrorTime = e, this.tasks = [], this.current = Promise.resolve(), this.next = this.next.bind(this);
278
278
  }
@@ -285,7 +285,7 @@ let Xn = class {
285
285
  if (t) {
286
286
  let e;
287
287
  const r = setTimeout(() => {
288
- process.env.NODE_ENV !== "production" && R.warn(
288
+ process.env.NODE_ENV !== "production" && I.warn(
289
289
  `A lock has exceeded ${this.lockWarningTime} ms. Waiting additional ${this.lockErrorTime} ms before rejecting the task.`,
290
290
  t
291
291
  ), e = setTimeout(() => {
@@ -302,16 +302,16 @@ let Xn = class {
302
302
  });
303
303
  }
304
304
  };
305
- const St = /* @__PURE__ */ new WeakMap();
306
- function G(n, t = 5e3, e = 1e3) {
307
- return St.has(n) || St.set(n, new Xn(t, e)), (r) => new Promise((s, i) => {
308
- const o = St.get(n);
305
+ const Wt = /* @__PURE__ */ new WeakMap();
306
+ function Z(n, t = 5e3, e = 1e3) {
307
+ return Wt.has(n) || Wt.set(n, new ns(t, e)), (r) => new Promise((s, i) => {
308
+ const o = Wt.get(n);
309
309
  o.add(r, s, i, () => {
310
- o.tasks.length || St.delete(n);
310
+ o.tasks.length || Wt.delete(n);
311
311
  });
312
312
  });
313
313
  }
314
- const tr = (n, t) => {
314
+ const rs = (n, t) => {
315
315
  const e = () => t.querySelectorAll("[data-loading=true]").length > 0, r = (() => {
316
316
  let s = !1;
317
317
  return () => {
@@ -331,7 +331,7 @@ const tr = (n, t) => {
331
331
  childList: !0,
332
332
  subtree: !0
333
333
  });
334
- }, er = (n, t) => {
334
+ }, ss = (n, t) => {
335
335
  n.get("$widget").container.getAsync("components").then((e) => {
336
336
  e.events.subscribeOnce("components:component-model-initialized", () => {
337
337
  let r = e.nodes.visible.reduce(
@@ -343,11 +343,11 @@ const tr = (n, t) => {
343
343
  if (a.addedNodes) {
344
344
  const c = Array.from(
345
345
  a.addedNodes
346
- ).reduce((h, u) => {
347
- const l = u.getAttribute && u.getAttribute("data-name");
348
- return l && r.indexOf(l) > -1 && h.push(l), h;
346
+ ).reduce((h, l) => {
347
+ const u = l.getAttribute && l.getAttribute("data-name");
348
+ return u && r.indexOf(u) > -1 && h.push(u), h;
349
349
  }, []);
350
- r = r.filter((h) => c.indexOf(h) === -1), !s && r.length === 0 && (s = !0, tr(n, t), o.disconnect());
350
+ r = r.filter((h) => c.indexOf(h) === -1), !s && r.length === 0 && (s = !0, rs(n, t), o.disconnect());
351
351
  }
352
352
  });
353
353
  }).observe(t, {
@@ -360,9 +360,9 @@ const tr = (n, t) => {
360
360
  });
361
361
  });
362
362
  });
363
- }, nr = er, rr = (n = {}) => (Object.keys(n).forEach((t) => {
363
+ }, is = ss, os = (n = {}) => (Object.keys(n).forEach((t) => {
364
364
  (n[t] === null || typeof n[t] == "undefined") && delete n[t];
365
- }), n), lt = rr, Ae = (n, t) => {
365
+ }), n), yt = os, dn = (n, t) => {
366
366
  let e = !0;
367
367
  return Object.keys(n).length !== Object.keys(t).length || Object.keys(n).some((r) => !Object.keys(t).some((s) => r === s)) ? !1 : (Object.keys(n).forEach((r) => {
368
368
  if (e) {
@@ -370,19 +370,19 @@ const tr = (n, t) => {
370
370
  e = s.toString() === i.toString();
371
371
  }
372
372
  }), e);
373
- }, nt = () => Math.floor((1 + Math.random()) * 65536).toString(16).substring(1);
374
- function Pt() {
375
- return nt() + nt() + "-" + nt() + "-" + nt() + "-" + nt() + "-" + nt() + nt() + nt();
373
+ }, it = () => Math.floor((1 + Math.random()) * 65536).toString(16).substring(1);
374
+ function Bt() {
375
+ return it() + it() + "-" + it() + "-" + it() + "-" + it() + "-" + it() + it() + it();
376
376
  }
377
- var sr = Object.defineProperty, ir = Object.defineProperties, or = Object.getOwnPropertyDescriptors, Ne = Object.getOwnPropertySymbols, ar = Object.prototype.hasOwnProperty, cr = Object.prototype.propertyIsEnumerable, Le = (n, t, e) => t in n ? sr(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, hr = (n, t) => {
377
+ var as = Object.defineProperty, cs = Object.defineProperties, hs = Object.getOwnPropertyDescriptors, pn = Object.getOwnPropertySymbols, ls = Object.prototype.hasOwnProperty, us = Object.prototype.propertyIsEnumerable, gn = (n, t, e) => t in n ? as(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, ds = (n, t) => {
378
378
  for (var e in t || (t = {}))
379
- ar.call(t, e) && Le(n, e, t[e]);
380
- if (Ne)
381
- for (var e of Ne(t))
382
- cr.call(t, e) && Le(n, e, t[e]);
379
+ ls.call(t, e) && gn(n, e, t[e]);
380
+ if (pn)
381
+ for (var e of pn(t))
382
+ us.call(t, e) && gn(n, e, t[e]);
383
383
  return n;
384
- }, ur = (n, t) => ir(n, or(t));
385
- class lr {
384
+ }, ps = (n, t) => cs(n, hs(t));
385
+ class gs {
386
386
  constructor(t) {
387
387
  const { events: e } = t.get("$widget");
388
388
  this.events = e.createChild(this);
@@ -397,7 +397,7 @@ class lr {
397
397
  );
398
398
  }
399
399
  }
400
- const sn = (n) => {
400
+ const Xn = (n) => {
401
401
  const t = [];
402
402
  return [
403
403
  (e, r) => {
@@ -410,7 +410,7 @@ const sn = (n) => {
410
410
  }
411
411
  ];
412
412
  };
413
- let yt = class {
413
+ let Pt = class {
414
414
  constructor(t, e = []) {
415
415
  this.platform = t, this.rules = e;
416
416
  }
@@ -424,17 +424,16 @@ let yt = class {
424
424
  return this.rules.push({ id: t }), this;
425
425
  }
426
426
  select() {
427
- return new dr(this.platform, this);
427
+ return new fs(this.platform, this);
428
428
  }
429
- };
430
- class ge {
429
+ }, Ke = class {
431
430
  constructor(t, e, r) {
432
- this.platform = t, this.node = e, this.actions = new Jt(
431
+ this.platform = t, this.node = e, this.actions = new ge(
433
432
  t,
434
- new yt(t).withId(e.id),
433
+ new Pt(t).withId(e.id),
435
434
  r
436
435
  );
437
- const [s, i] = sn(this.platform.events);
436
+ const [s, i] = Xn(this.platform.events);
438
437
  this.subscribe = s, this.unsubscribe = i;
439
438
  }
440
439
  properties(t) {
@@ -462,10 +461,10 @@ class ge {
462
461
  dispose() {
463
462
  this.unsubscribe(), this.actions.dispose();
464
463
  }
465
- }
466
- class dr {
464
+ };
465
+ class fs {
467
466
  constructor(t, e, r = !0) {
468
- this.platform = t, this.target = e, this.clearOnDispose = r, this.removes = [], this.actions = new Jt(this.platform, this.target);
467
+ this.platform = t, this.target = e, this.clearOnDispose = r, this.removes = [], this.actions = new ge(this.platform, this.target);
469
468
  }
470
469
  writeProperties(t, e) {
471
470
  this.removes.push(
@@ -503,12 +502,12 @@ class dr {
503
502
  }), this.actions.dispose();
504
503
  }
505
504
  }
506
- const pr = (n, t, e) => {
505
+ const ms = (n, t, e) => {
507
506
  const r = n.concat(), s = (i, o, a) => {
508
507
  let c = !0;
509
508
  if (r.length) {
510
- const h = r.shift(), u = (l, d) => (c = !1, s(l, Object.assign({}, o, d), a));
511
- return Promise.resolve(h(i, u, a)).then((l) => ur(hr({}, l), {
509
+ const h = r.shift(), l = (u, d) => (c = !1, s(u, Object.assign({}, o, d), a));
510
+ return Promise.resolve(h(i, l, a)).then((u) => ps(ds({}, u), {
512
511
  cancelled: c
513
512
  }));
514
513
  }
@@ -516,7 +515,7 @@ const pr = (n, t, e) => {
516
515
  };
517
516
  return s(t, {}, e);
518
517
  };
519
- let Jt = class {
518
+ let ge = class {
520
519
  constructor(t, e, r) {
521
520
  this.platform = t, this.target = e, this.ns = r, this.subscriptions = [], this.create = this.create.bind(this);
522
521
  }
@@ -545,20 +544,20 @@ let Jt = class {
545
544
  i.map((o) => {
546
545
  const a = r.filter(
547
546
  (h) => o.target.match(h) && this.target.match(h)
548
- ), c = this.platform.actionsState.watchers.filter((h) => h.key === t && (!h.ns || !this.ns || h.ns === this.ns) && a.some((u) => h.target.match(u))).map((h) => h.fn);
547
+ ), c = this.platform.actionsState.watchers.filter((h) => h.key === t && (!h.ns || !this.ns || h.ns === this.ns) && a.some((l) => h.target.match(l))).map((h) => h.fn);
549
548
  return Promise.all(
550
549
  a.map((h) => {
551
- const u = new ge(
550
+ const l = new Ke(
552
551
  this.platform,
553
552
  h,
554
553
  this.ns
555
554
  );
556
- return pr(c, e, u).then((l) => {
557
- const { data: d = {}, options: f, cancelled: g } = l;
555
+ return ms(c, e, l).then((u) => {
556
+ const { data: d = {}, options: p, cancelled: b } = u;
558
557
  return Promise.resolve(
559
- g ? {} : o.fn(d, f, u)
560
- ).then((E) => {
561
- s[h.id] = E;
558
+ b ? {} : o.fn(d, p, l)
559
+ ).then((v) => {
560
+ s[h.id] = v;
562
561
  });
563
562
  });
564
563
  })
@@ -587,7 +586,7 @@ let Jt = class {
587
586
  this.subscriptions.forEach((t) => t());
588
587
  }
589
588
  };
590
- fe((n) => {
589
+ qe((n) => {
591
590
  n.createCommand("components", (t) => (e) => {
592
591
  t.events.subscribeOnce("components:platform-created", (r, { platform: s }) => {
593
592
  e.handlers && e.handlers.forEach(([i, o]) => {
@@ -596,9 +595,9 @@ fe((n) => {
596
595
  });
597
596
  });
598
597
  });
599
- let le = class {
598
+ let Be = class {
600
599
  constructor(t, e) {
601
- this.events = t, this.tags = [], this.children = {}, this.changesets = [], this.mountCount = 0, this.id = Pt(), this.type = e, this.attributes = {
600
+ this.events = t, this.tags = [], this.children = {}, this.changesets = [], this.mountCount = 0, this.id = Bt(), this.type = e, this.attributes = {
602
601
  context: {},
603
602
  properties: {},
604
603
  layout: {},
@@ -607,7 +606,7 @@ let le = class {
607
606
  }
608
607
  mount(t, e) {
609
608
  let r = t.get("mounted-nodes");
610
- return r || (r = /* @__PURE__ */ new Map(), t.register("mounted-nodes", r)), r.has(this) ? (process.env.NODE_ENV !== "production" && R.error("Trying to mount an already mounted component node.", this), () => {
609
+ return r || (r = /* @__PURE__ */ new Map(), t.register("mounted-nodes", r)), r.has(this) ? (process.env.NODE_ENV !== "production" && I.error("Trying to mount an already mounted component node.", this), () => {
611
610
  }) : (this.events.dispatch("components:node-mounted", { node: this }), this.mountCount === 0 && (this.mountCount = this.mountCount + 1, this.events.dispatch("components:node-enter", { node: this })), () => {
612
611
  r.delete(this), this.events.dispatch("components:node-unmounted", { node: this }), this.mountCount = this.mountCount - 1, this.mountCount === 0 && this.events.dispatch("components:node-exit", { node: this });
613
612
  });
@@ -681,49 +680,49 @@ let le = class {
681
680
  }), delete t.parent;
682
681
  }
683
682
  };
684
- const on = (n, t, e) => {
683
+ const tr = (n, t, e) => {
685
684
  for (let r = 0, s = n.length; r < s && e(n[r]) !== !0; r++) {
686
685
  const i = t[n[r].id] || "default", o = n[r].getChildren(i);
687
- on(o, t, e);
686
+ tr(o, t, e);
688
687
  }
689
- }, Kt = (n, t, e) => {
688
+ }, fe = (n, t, e) => {
690
689
  if (e(n) !== !0) {
691
690
  const r = t[n.id] || "default", s = n.children[r];
692
- on(s, t, e);
691
+ tr(s, t, e);
693
692
  }
694
- }, Mt = (n, t) => {
693
+ }, Zt = (n, t) => {
695
694
  const e = [];
696
- return Kt(n, t, (r) => {
695
+ return fe(n, t, (r) => {
697
696
  e.push(r);
698
697
  }), e;
699
- }, an = (n, t, e) => {
698
+ }, er = (n, t, e) => {
700
699
  let r;
701
- return Kt(n, t, (s) => {
700
+ return fe(n, t, (s) => {
702
701
  if (e(s))
703
702
  return r = s, !0;
704
703
  }), r;
705
704
  };
706
- let fr = class {
705
+ let vs = class {
707
706
  constructor(t, e, r) {
708
707
  this.root = t, this.switches = e, this.all = [], this.visible = [], this.detached = [], r.subscribe("components:node-appended", (s, i) => {
709
- this.all.push(i.node), this.visible = Mt(t, e);
708
+ this.all.push(i.node), this.visible = Zt(t, e);
710
709
  }), r.subscribe("components:node-removed", (s, i) => {
711
710
  let o = this.all.indexOf(i.node);
712
- o > -1 && this.all.splice(o, 1), o = this.visible.indexOf(i.node), o > -1 && this.visible.splice(o, 1), this.visible = Mt(t, e);
711
+ o > -1 && this.all.splice(o, 1), o = this.visible.indexOf(i.node), o > -1 && this.visible.splice(o, 1), this.visible = Zt(t, e);
713
712
  }), r.subscribe("components:node-switched", (s, i) => {
714
- this.visible = Mt(t, e);
713
+ this.visible = Zt(t, e);
715
714
  });
716
715
  }
717
716
  query(t = {}) {
718
717
  const e = [];
719
- return Kt(this.root, this.switches, (r) => {
718
+ return fe(this.root, this.switches, (r) => {
720
719
  Object.keys(t).every((s) => t[s] === r[s]) && e.push(r);
721
720
  }), e;
722
721
  }
723
722
  get(t) {
724
- return an(this.root, this.switches, (e) => e.id === t) || this.detached.find((e) => e.id === t);
723
+ return er(this.root, this.switches, (e) => e.id === t) || this.detached.find((e) => e.id === t);
725
724
  }
726
- }, gr = class {
725
+ }, ys = class {
727
726
  constructor() {
728
727
  this.handlers = /* @__PURE__ */ new Map();
729
728
  }
@@ -734,54 +733,54 @@ let fr = class {
734
733
  return this.handlers.get(t);
735
734
  }
736
735
  };
737
- const mr = (n) => {
736
+ const bs = (n) => {
738
737
  let t = n, e = 0;
739
738
  for (; t.parent; )
740
739
  e = e + 1, t = t.parent;
741
740
  return e;
742
- }, yr = (n) => n.map(([t, e]) => [mr(t), t, e]).sort(([t], [e]) => t - e).map(([, t, e]) => [t, e]), te = (n) => n instanceof Date ? !1 : n && typeof n == "object" && !Array.isArray(n), Q = (n, ...t) => {
741
+ }, ws = (n) => n.map(([t, e]) => [bs(t), t, e]).sort(([t], [e]) => t - e).map(([, t, e]) => [t, e]), Ee = (n) => n instanceof Date ? !1 : n && typeof n == "object" && !Array.isArray(n), X = (n, ...t) => {
743
742
  if (!t.length)
744
743
  return n;
745
744
  const e = t.shift();
746
- if (te(n) && te(e))
745
+ if (Ee(n) && Ee(e))
747
746
  for (const r in e)
748
- te(e[r]) ? (n[r] || Object.assign(n, { [r]: {} }), Q(n[r], e[r])) : Object.assign(n, { [r]: e[r] });
749
- return Q(n, ...t);
750
- }, vr = (n, t) => !n || n === "all" ? !0 : n.some((e) => t.indexOf(e) > -1), br = (n, t) => {
747
+ Ee(e[r]) ? (n[r] || Object.assign(n, { [r]: {} }), X(n[r], e[r])) : Object.assign(n, { [r]: e[r] });
748
+ return X(n, ...t);
749
+ }, $s = (n, t) => !n || n === "all" ? !0 : n.some((e) => t.indexOf(e) > -1), Os = (n, t) => {
751
750
  let e = [], r = [], s;
752
751
  const i = () => {
753
752
  process.env.NODE_ENV !== "production" && console.time("state-processor.flush");
754
- const a = /* @__PURE__ */ new Map(), c = yr(e.map((u, l) => [u, r[l]])), h = (u, l) => {
753
+ const a = /* @__PURE__ */ new Map(), c = ws(e.map((l, u) => [l, r[u]])), h = (l, u) => {
755
754
  var d;
756
- const f = a.get(u) || {}, g = l.context && !f.context, E = l.properties && !f.properties, p = l.layout && !f.layout;
757
- a.set(u, {
758
- context: f.context || g,
759
- properties: f.properties || E,
760
- layout: f.layout || p
761
- }), E && (u.attributes.properties = {}), p && (u.attributes.layout = {}), g && (u.attributes.context = Q({}, (d = u.parent) == null ? void 0 : d.attributes.context));
762
- const C = [], T = [], U = [];
763
- if (u.changesets.forEach((_) => {
764
- const [D, H] = _;
765
- vr(H.breakpoints, n.breakpoints) && (E && (typeof D.properties == "function" ? C.push(
766
- D.properties
767
- ) : Q(u.attributes.properties, D.properties)), p && (typeof D.layout == "function" ? T.push(D.layout) : Q(u.attributes.layout, D.layout)), g && (typeof D.context == "function" ? U.push(D.context) : Q(u.attributes.context, D.context)));
768
- }), C.forEach((_) => {
769
- Q(u.attributes.properties, _(u.attributes.properties));
770
- }), T.forEach((_) => {
771
- Q(u.attributes.layout, _(u.attributes.layout));
772
- }), U.forEach((_) => {
773
- Q(u.attributes.context, _(u.attributes.context));
774
- }), g || l.recursive) {
775
- const _ = n.getBranch(u), D = l.recursive ? l : {
776
- context: !!g
755
+ const p = a.get(l) || {}, b = u.context && !p.context, v = u.properties && !p.properties, g = u.layout && !p.layout;
756
+ a.set(l, {
757
+ context: p.context || b,
758
+ properties: p.properties || v,
759
+ layout: p.layout || g
760
+ }), v && (l.attributes.properties = {}), g && (l.attributes.layout = {}), b && (l.attributes.context = X({}, (d = l.parent) == null ? void 0 : d.attributes.context));
761
+ const E = [], j = [], z = [];
762
+ if (l.changesets.forEach((H) => {
763
+ const [k, U] = H;
764
+ $s(U.breakpoints, n.breakpoints) && (v && (typeof k.properties == "function" ? E.push(
765
+ k.properties
766
+ ) : X(l.attributes.properties, k.properties)), g && (typeof k.layout == "function" ? j.push(k.layout) : X(l.attributes.layout, k.layout)), b && (typeof k.context == "function" ? z.push(k.context) : X(l.attributes.context, k.context)));
767
+ }), E.forEach((H) => {
768
+ X(l.attributes.properties, H(l.attributes.properties));
769
+ }), j.forEach((H) => {
770
+ X(l.attributes.layout, H(l.attributes.layout));
771
+ }), z.forEach((H) => {
772
+ X(l.attributes.context, H(l.attributes.context));
773
+ }), b || u.recursive) {
774
+ const H = n.getBranch(l), k = u.recursive ? u : {
775
+ context: !!b
777
776
  };
778
- u.getChildren(_).forEach((H) => {
779
- h(H, D);
777
+ l.getChildren(H).forEach((U) => {
778
+ h(U, k);
780
779
  });
781
780
  }
782
781
  };
783
- process.env.NODE_ENV !== "production" && console.timeEnd("state-processor.flush"), c.forEach(([u, l]) => {
784
- h(u, l);
782
+ process.env.NODE_ENV !== "production" && console.timeEnd("state-processor.flush"), c.forEach(([l, u]) => {
783
+ h(l, u);
785
784
  }), e = [], r = [], t(a);
786
785
  }, o = () => {
787
786
  clearTimeout(s), s = setTimeout(i, 0);
@@ -789,18 +788,18 @@ const mr = (n) => {
789
788
  return (a, c) => {
790
789
  const h = e.indexOf(a);
791
790
  if (h > -1) {
792
- const u = r[h];
793
- return c.context && (u.context = !0), c.properties && (u.properties = !0), c.layout && (u.layout = !0), c.recursive && (u.recursive = !0), o();
791
+ const l = r[h];
792
+ return c.context && (l.context = !0), c.properties && (l.properties = !0), c.layout && (l.layout = !0), c.recursive && (l.recursive = !0), o();
794
793
  }
795
794
  return e.push(a), r.push(c), o();
796
795
  };
797
796
  };
798
- let qt = class {
797
+ let me = class {
799
798
  constructor(t, e = {}) {
800
- this.providers = e, this.breakpoints = [], this.actionsState = { handlers: [], watchers: [] }, this.switches = {}, this.changesets = [], this.subscriptions = [], this.customComponentHandler = new gr(), this.events = t.events.createChild(this);
801
- const r = new le(this.events, "root");
802
- r.name = `root-${t.name}`, this.nodes = new fr(r, this.switches, this.events);
803
- const s = this.processNode = br(this, (i) => {
799
+ this.providers = e, this.breakpoints = [], this.actionsState = { handlers: [], watchers: [] }, this.switches = {}, this.changesets = [], this.subscriptions = [], this.customComponentHandler = new ys(), this.events = t.events.createChild(this);
800
+ const r = new Be(this.events, "root");
801
+ r.name = `root-${t.name}`, this.nodes = new vs(r, this.switches, this.events);
802
+ const s = this.processNode = Os(this, (i) => {
804
803
  const o = Array.from(i.keys());
805
804
  process.env.NODE_ENV !== "production" && console.info(`STATE PROCESSOR: ${o.length} node(s) processed:
806
805
  ${o.map(
@@ -819,8 +818,8 @@ ${o.map(
819
818
  (i, o) => {
820
819
  const { node: a } = o;
821
820
  this.changesets.forEach((c) => {
822
- const { changeset: h, target: u, removes: l } = c, [d, f] = h;
823
- u.match(o.node) && (d.properties && l.push(a.writeProperties(d.properties, f)), d.context && l.push(a.writeContext(d.context, f)), d.layout && l.push(a.writeLayout(d.layout, f)));
821
+ const { changeset: h, target: l, removes: u } = c, [d, p] = h;
822
+ l.match(o.node) && (d.properties && u.push(a.writeProperties(d.properties, p)), d.context && u.push(a.writeContext(d.context, p)), d.layout && u.push(a.writeLayout(d.layout, p)));
824
823
  });
825
824
  }
826
825
  )
@@ -905,17 +904,17 @@ ${o.map(
905
904
  * @param type Type of node.
906
905
  */
907
906
  createNode(t, e = {}) {
908
- const r = new le(this.events, t);
907
+ const r = new Be(this.events, t);
909
908
  return e.detached && this.nodes.detached.push(r), r;
910
909
  }
911
910
  components() {
912
- return new yt(this);
911
+ return new Pt(this);
913
912
  }
914
913
  actions(t, e) {
915
- return new Jt(this, t, e);
914
+ return new ge(this, t, e);
916
915
  }
917
916
  write(t) {
918
- const { provider: e, target: r, attributes: s, options: i = {}, removable: o } = t, a = t.key || Pt(), c = { changeset: [s, i], target: r, removes: [] };
917
+ const { provider: e, target: r, attributes: s, options: i = {}, removable: o } = t, a = t.key || Bt(), c = { changeset: [s, i], target: r, removes: [] };
919
918
  if (e) {
920
919
  const h = this.providers[e];
921
920
  h.write(a, r, s, i), c.removes.push(() => {
@@ -924,13 +923,13 @@ ${o.map(
924
923
  }
925
924
  return this.changesets.push(c), this.nodes.all.forEach((h) => {
926
925
  if (r.match(h)) {
927
- let u = () => {
926
+ let l = () => {
928
927
  };
929
- s.properties && (u = h.writeProperties(s.properties, i, o)), s.context && (u = h.writeContext(s.context, i, o)), s.layout && (u = h.writeContext(s.layout, i, o)), c.removes.push(u);
928
+ s.properties && (l = h.writeProperties(s.properties, i, o)), s.context && (l = h.writeContext(s.context, i, o)), s.layout && (l = h.writeContext(s.layout, i, o)), c.removes.push(l);
930
929
  }
931
930
  }), () => {
932
931
  if (o) {
933
- c.removes.forEach((u) => u());
932
+ c.removes.forEach((l) => l());
934
933
  const h = this.changesets.indexOf(c);
935
934
  h > -1 && this.changesets.splice(h, 1);
936
935
  }
@@ -946,7 +945,7 @@ ${o.map(
946
945
  this.subscriptions.forEach((t) => t());
947
946
  }
948
947
  };
949
- const wr = (n) => {
948
+ const Es = (n) => {
950
949
  if (Array.isArray(n)) {
951
950
  const [t, ...e] = n;
952
951
  return {
@@ -958,18 +957,18 @@ const wr = (n) => {
958
957
  definitionId: n,
959
958
  overrides: []
960
959
  };
961
- }, Ht = (n, t, e, r, s, i) => {
960
+ }, ie = (n, t, e, r, s, i) => {
962
961
  e.forEach((o) => {
963
- const a = wr(o), c = r[a.definitionId];
962
+ const a = Es(o), c = r[a.definitionId];
964
963
  if (a.definitionId === "view") {
965
964
  const h = n.createNode("view");
966
- h.name = "view", Object.keys(s).forEach((u) => {
967
- const l = s[u];
968
- Ht(n, h, [l.entry], r, s, u);
969
- }), t.appendChild(h), a.overrides.forEach((u) => {
970
- u.properties && h.writeProperties(u.properties, {
971
- breakpoints: u.breakpoints
972
- }), u.context && h.writeContext(u.context, { breakpoints: u.breakpoints }), u.layout && h.writeLayout(u.layout, { breakpoints: u.breakpoints });
965
+ h.name = "view", Object.keys(s).forEach((l) => {
966
+ const u = s[l];
967
+ ie(n, h, [u.entry], r, s, l);
968
+ }), t.appendChild(h), a.overrides.forEach((l) => {
969
+ l.properties && h.writeProperties(l.properties, {
970
+ breakpoints: l.breakpoints
971
+ }), l.context && h.writeContext(l.context, { breakpoints: l.breakpoints }), l.layout && h.writeLayout(l.layout, { breakpoints: l.breakpoints });
973
972
  });
974
973
  } else if (n.getComponentHandler(c.type)) {
975
974
  const h = n.getComponentHandler(c.type);
@@ -984,69 +983,69 @@ const wr = (n) => {
984
983
  } else {
985
984
  const h = r[a.definitionId];
986
985
  if (process.env.NODE_ENV !== "production" && !h) {
987
- R.error(
986
+ I.error(
988
987
  `No definition found for component type '${a.definitionId}'.`
989
988
  );
990
989
  return;
991
990
  }
992
- const u = n.createNode(h.type);
993
- u.name = a.definitionId, u.tags = h.tags || [], h.properties && u.writeProperties(h.properties), h.context && u.writeContext(h.context), h.layout && u.writeLayout(h.layout), t.appendChild(u, i), a.overrides.forEach((l) => {
994
- const d = { breakpoints: l.breakpoints };
995
- l.properties && u.writeProperties(l.properties, d), l.context && u.writeContext(l.context, d), l.layout && u.writeLayout(l.layout, d);
996
- }), h.children && Ht(n, u, h.children, r, s);
991
+ const l = n.createNode(h.type);
992
+ l.name = a.definitionId, l.tags = h.tags || [], h.properties && l.writeProperties(h.properties), h.context && l.writeContext(h.context), h.layout && l.writeLayout(h.layout), t.appendChild(l, i), a.overrides.forEach((u) => {
993
+ const d = { breakpoints: u.breakpoints };
994
+ u.properties && l.writeProperties(u.properties, d), u.context && l.writeContext(u.context, d), u.layout && l.writeLayout(u.layout, d);
995
+ }), h.children && ie(n, l, h.children, r, s);
997
996
  }
998
997
  });
999
- }, cn = (n, t) => {
998
+ }, nr = (n, t) => {
1000
999
  const { entry: e, components: r, breakpoints: s, views: i } = t, o = [];
1001
1000
  return Object.keys(s).forEach((a) => {
1002
1001
  const c = s[a], h = window.matchMedia(c);
1003
1002
  h.matches && n.breakpoints.push(a);
1004
- const u = (l) => {
1005
- l.matches ? n.addBreakpoint(a) : n.removeBreakpoint(a);
1003
+ const l = (u) => {
1004
+ u.matches ? n.addBreakpoint(a) : n.removeBreakpoint(a);
1006
1005
  };
1007
- h.addListener(u), o.push(() => h.removeListener(u));
1008
- }), Ht(n, n.nodes.root, [e], r, i), () => o.forEach((a) => {
1006
+ h.addListener(l), o.push(() => h.removeListener(l));
1007
+ }), ie(n, n.nodes.root, [e], r, i), () => o.forEach((a) => {
1009
1008
  a();
1010
1009
  });
1011
- }, Or = (n, t) => ({
1010
+ }, As = (n, t) => ({
1012
1011
  id: n.id,
1013
1012
  type: n.type,
1014
1013
  name: n.name,
1015
1014
  branch: t || "default"
1016
- }), hn = (n, t, e, r = Pt(), s = {}) => n.getAsync("components").then((i) => {
1015
+ }), rr = (n, t, e, r = Bt(), s = {}) => n.getAsync("components").then((i) => {
1017
1016
  let o;
1018
1017
  if (typeof t == "string") {
1019
- const h = new yt(i);
1018
+ const h = new Pt(i);
1020
1019
  h.ofType(t), o = h;
1021
1020
  } else
1022
1021
  o = t;
1023
1022
  const a = {}, c = (h) => {
1024
- const u = a[h.id];
1025
- return u ? Promise.resolve(u.controller) : qt.getInstance(n).then((l) => new ge(l, h, r));
1023
+ const l = a[h.id];
1024
+ return l ? Promise.resolve(l.controller) : me.getInstance(n).then((u) => new Ke(u, h, r));
1026
1025
  };
1027
1026
  i.events.subscribe(
1028
1027
  "components:node-enter",
1029
- (h, { node: u }) => {
1030
- o.match(u) && c(u).then((l) => {
1031
- Promise.resolve(e(l)).then((d) => {
1032
- a[u.id] = {
1028
+ (h, { node: l }) => {
1029
+ o.match(l) && c(l).then((u) => {
1030
+ Promise.resolve(e(u)).then((d) => {
1031
+ a[l.id] = {
1033
1032
  dispose: d,
1034
- controller: l
1033
+ controller: u
1035
1034
  };
1036
1035
  });
1037
1036
  });
1038
1037
  }
1039
1038
  ), i.events.subscribe(
1040
1039
  "components:node-exit",
1041
- (h, { node: u }) => {
1042
- const l = a[u.id];
1043
- l && (l.dispose && l.dispose(), s.reuseController || (l.controller.dispose(), delete a[u.id]));
1040
+ (h, { node: l }) => {
1041
+ const u = a[l.id];
1042
+ u && (u.dispose && u.dispose(), s.reuseController || (u.controller.dispose(), delete a[l.id]));
1044
1043
  }
1045
1044
  );
1046
1045
  });
1047
- class Er {
1046
+ class xs {
1048
1047
  constructor(t) {
1049
- this.aliases = /* @__PURE__ */ new Map(), this.components = /* @__PURE__ */ new Map(), this.logger = new R();
1048
+ this.aliases = /* @__PURE__ */ new Map(), this.components = /* @__PURE__ */ new Map(), this.logger = new I();
1050
1049
  const { events: e } = t.get("$widget");
1051
1050
  this.events = e;
1052
1051
  }
@@ -1076,32 +1075,32 @@ class Er {
1076
1075
  };
1077
1076
  }
1078
1077
  }
1079
- var z = /* @__PURE__ */ ((n) => (n.open = "open", n.closed = "closed", n.hidden = "hidden", n))(z || {});
1080
- const me = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1078
+ var F = /* @__PURE__ */ ((n) => (n.open = "open", n.closed = "closed", n.hidden = "hidden", n))(F || {});
1079
+ const Ye = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1081
1080
  __proto__: null,
1082
- ActionResolver: lr,
1083
- ActionsController: Jt,
1084
- ComponentNode: le,
1085
- ComponentNodeController: ge,
1086
- ComponentPlatform: qt,
1087
- ComponentQuery: yt,
1088
- ComponentResolver: Er,
1089
- WidgetRenderState: z,
1090
- asDescriptor: Or,
1091
- createChildren: Ht,
1092
- createComponentModel: cn,
1093
- createEventSubscriber: sn,
1094
- extendComponent: hn,
1095
- findComponent: an,
1096
- findVisibleComponents: Mt,
1097
- traverseComponents: Kt
1081
+ ActionResolver: gs,
1082
+ ActionsController: ge,
1083
+ ComponentNode: Be,
1084
+ ComponentNodeController: Ke,
1085
+ ComponentPlatform: me,
1086
+ ComponentQuery: Pt,
1087
+ ComponentResolver: xs,
1088
+ WidgetRenderState: F,
1089
+ asDescriptor: As,
1090
+ createChildren: ie,
1091
+ createComponentModel: nr,
1092
+ createEventSubscriber: Xn,
1093
+ extendComponent: rr,
1094
+ findComponent: er,
1095
+ findVisibleComponents: Zt,
1096
+ traverseComponents: fe
1098
1097
  }, Symbol.toStringTag, { value: "Module" }));
1099
- function un(n) {
1098
+ function sr(n) {
1100
1099
  return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
1101
1100
  }
1102
- var ln = function() {
1101
+ var ir = function() {
1103
1102
  };
1104
- process.env.NODE_ENV !== "production" && (ln = function(n, t, e) {
1103
+ process.env.NODE_ENV !== "production" && (ir = function(n, t, e) {
1105
1104
  var r = arguments.length;
1106
1105
  e = new Array(r > 2 ? r - 2 : 0);
1107
1106
  for (var s = 2; s < r; s++)
@@ -1125,9 +1124,9 @@ process.env.NODE_ENV !== "production" && (ln = function(n, t, e) {
1125
1124
  }
1126
1125
  }
1127
1126
  });
1128
- var xr = ln;
1129
- const Z = /* @__PURE__ */ un(xr);
1130
- var $r = function(n, t, e, r, s, i, o, a) {
1127
+ var _s = ir;
1128
+ const tt = /* @__PURE__ */ sr(_s);
1129
+ var Ss = function(n, t, e, r, s, i, o, a) {
1131
1130
  if (process.env.NODE_ENV !== "production" && t === void 0)
1132
1131
  throw new Error("invariant requires an error message argument");
1133
1132
  if (!n) {
@@ -1137,28 +1136,28 @@ var $r = function(n, t, e, r, s, i, o, a) {
1137
1136
  "Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings."
1138
1137
  );
1139
1138
  else {
1140
- var h = [e, r, s, i, o, a], u = 0;
1139
+ var h = [e, r, s, i, o, a], l = 0;
1141
1140
  c = new Error(
1142
1141
  t.replace(/%s/g, function() {
1143
- return h[u++];
1142
+ return h[l++];
1144
1143
  })
1145
1144
  ), c.name = "Invariant Violation";
1146
1145
  }
1147
1146
  throw c.framesToPop = 1, c;
1148
1147
  }
1149
- }, Pr = $r;
1150
- const Sr = /* @__PURE__ */ un(Pr);
1151
- function Ct(n) {
1148
+ }, Ps = Ss;
1149
+ const Cs = /* @__PURE__ */ sr(Ps);
1150
+ function Ft(n) {
1152
1151
  return n.charAt(0) === "/";
1153
1152
  }
1154
- function ee(n, t) {
1153
+ function Ae(n, t) {
1155
1154
  for (var e = t, r = e + 1, s = n.length; r < s; e += 1, r += 1)
1156
1155
  n[e] = n[r];
1157
1156
  n.pop();
1158
1157
  }
1159
- function Cr(n) {
1160
- var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", e = n && n.split("/") || [], r = t && t.split("/") || [], s = n && Ct(n), i = t && Ct(t), o = s || i;
1161
- if (n && Ct(n) ? r = e : e.length && (r.pop(), r = r.concat(e)), !r.length)
1158
+ function ks(n) {
1159
+ var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", e = n && n.split("/") || [], r = t && t.split("/") || [], s = n && Ft(n), i = t && Ft(t), o = s || i;
1160
+ if (n && Ft(n) ? r = e : e.length && (r.pop(), r = r.concat(e)), !r.length)
1162
1161
  return "/";
1163
1162
  var a = void 0;
1164
1163
  if (r.length) {
@@ -1166,26 +1165,26 @@ function Cr(n) {
1166
1165
  a = c === "." || c === ".." || c === "";
1167
1166
  } else
1168
1167
  a = !1;
1169
- for (var h = 0, u = r.length; u >= 0; u--) {
1170
- var l = r[u];
1171
- l === "." ? ee(r, u) : l === ".." ? (ee(r, u), h++) : h && (ee(r, u), h--);
1168
+ for (var h = 0, l = r.length; l >= 0; l--) {
1169
+ var u = r[l];
1170
+ u === "." ? Ae(r, l) : u === ".." ? (Ae(r, l), h++) : h && (Ae(r, l), h--);
1172
1171
  }
1173
1172
  if (!o)
1174
1173
  for (; h--; h)
1175
1174
  r.unshift("..");
1176
- o && r[0] !== "" && (!r[0] || !Ct(r[0])) && r.unshift("");
1175
+ o && r[0] !== "" && (!r[0] || !Ft(r[0])) && r.unshift("");
1177
1176
  var d = r.join("/");
1178
1177
  return a && d.substr(-1) !== "/" && (d += "/"), d;
1179
1178
  }
1180
- var kr = function(t) {
1179
+ var Ns = function(t) {
1181
1180
  return t.charAt(0) === "/" ? t : "/" + t;
1182
- }, dn = function(t, e) {
1181
+ }, or = function(t, e) {
1183
1182
  return new RegExp("^" + e + "(\\/|\\?|#|$)", "i").test(t);
1184
- }, Ar = function(t, e) {
1185
- return dn(t, e) ? t.substr(e.length) : t;
1186
- }, Nr = function(t) {
1183
+ }, Ms = function(t, e) {
1184
+ return or(t, e) ? t.substr(e.length) : t;
1185
+ }, Ls = function(t) {
1187
1186
  return t.charAt(t.length - 1) === "/" ? t.slice(0, -1) : t;
1188
- }, Lr = function(t) {
1187
+ }, Ds = function(t) {
1189
1188
  var e = t || "/", r = "", s = "", i = e.indexOf("#");
1190
1189
  i !== -1 && (s = e.substr(i), e = e.substr(0, i));
1191
1190
  var o = e.indexOf("?");
@@ -1194,50 +1193,50 @@ var kr = function(t) {
1194
1193
  search: r === "?" ? "" : r,
1195
1194
  hash: s === "#" ? "" : s
1196
1195
  };
1197
- }, pn = function(t) {
1196
+ }, ar = function(t) {
1198
1197
  var e = t.pathname, r = t.search, s = t.hash, i = e || "/";
1199
1198
  return r && r !== "?" && (i += r.charAt(0) === "?" ? r : "?" + r), s && s !== "#" && (i += s.charAt(0) === "#" ? s : "#" + s), i;
1200
- }, Mr = Object.assign || function(n) {
1199
+ }, Ts = Object.assign || function(n) {
1201
1200
  for (var t = 1; t < arguments.length; t++) {
1202
1201
  var e = arguments[t];
1203
1202
  for (var r in e)
1204
1203
  Object.prototype.hasOwnProperty.call(e, r) && (n[r] = e[r]);
1205
1204
  }
1206
1205
  return n;
1207
- }, ct = function(t, e, r, s) {
1206
+ }, gt = function(t, e, r, s) {
1208
1207
  var i = void 0;
1209
- typeof t == "string" ? (i = Lr(t), i.state = e) : (i = Mr({}, t), i.pathname === void 0 && (i.pathname = ""), i.search ? i.search.charAt(0) !== "?" && (i.search = "?" + i.search) : i.search = "", i.hash ? i.hash.charAt(0) !== "#" && (i.hash = "#" + i.hash) : i.hash = "", e !== void 0 && i.state === void 0 && (i.state = e));
1208
+ typeof t == "string" ? (i = Ds(t), i.state = e) : (i = Ts({}, t), i.pathname === void 0 && (i.pathname = ""), i.search ? i.search.charAt(0) !== "?" && (i.search = "?" + i.search) : i.search = "", i.hash ? i.hash.charAt(0) !== "#" && (i.hash = "#" + i.hash) : i.hash = "", e !== void 0 && i.state === void 0 && (i.state = e));
1210
1209
  try {
1211
1210
  i.pathname = decodeURI(i.pathname);
1212
1211
  } catch (o) {
1213
1212
  throw o instanceof URIError ? new URIError('Pathname "' + i.pathname + '" could not be decoded. This is likely caused by an invalid percent-encoding.') : o;
1214
1213
  }
1215
- return r && (i.key = r), s ? i.pathname ? i.pathname.charAt(0) !== "/" && (i.pathname = Cr(i.pathname, s.pathname)) : i.pathname = s.pathname : i.pathname || (i.pathname = "/"), i;
1216
- }, fn = function() {
1214
+ return r && (i.key = r), s ? i.pathname ? i.pathname.charAt(0) !== "/" && (i.pathname = ks(i.pathname, s.pathname)) : i.pathname = s.pathname : i.pathname || (i.pathname = "/"), i;
1215
+ }, cr = function() {
1217
1216
  var t = null, e = function(c) {
1218
- return Z(t == null, "A history supports only one prompt at a time"), t = c, function() {
1217
+ return tt(t == null, "A history supports only one prompt at a time"), t = c, function() {
1219
1218
  t === c && (t = null);
1220
1219
  };
1221
- }, r = function(c, h, u, l) {
1220
+ }, r = function(c, h, l, u) {
1222
1221
  if (t != null) {
1223
1222
  var d = typeof t == "function" ? t(c, h) : t;
1224
- typeof d == "string" ? typeof u == "function" ? u(d, l) : (Z(!1, "A history needs a getUserConfirmation function in order to use a prompt message"), l(!0)) : l(d !== !1);
1223
+ typeof d == "string" ? typeof l == "function" ? l(d, u) : (tt(!1, "A history needs a getUserConfirmation function in order to use a prompt message"), u(!0)) : u(d !== !1);
1225
1224
  } else
1226
- l(!0);
1225
+ u(!0);
1227
1226
  }, s = [], i = function(c) {
1228
- var h = !0, u = function() {
1227
+ var h = !0, l = function() {
1229
1228
  h && c.apply(void 0, arguments);
1230
1229
  };
1231
- return s.push(u), function() {
1232
- h = !1, s = s.filter(function(l) {
1233
- return l !== u;
1230
+ return s.push(l), function() {
1231
+ h = !1, s = s.filter(function(u) {
1232
+ return u !== l;
1234
1233
  });
1235
1234
  };
1236
1235
  }, o = function() {
1237
- for (var c = arguments.length, h = Array(c), u = 0; u < c; u++)
1238
- h[u] = arguments[u];
1239
- s.forEach(function(l) {
1240
- return l.apply(void 0, h);
1236
+ for (var c = arguments.length, h = Array(c), l = 0; l < c; l++)
1237
+ h[l] = arguments[l];
1238
+ s.forEach(function(u) {
1239
+ return u.apply(void 0, h);
1241
1240
  });
1242
1241
  };
1243
1242
  return {
@@ -1246,220 +1245,220 @@ var kr = function(t) {
1246
1245
  appendListener: i,
1247
1246
  notifyListeners: o
1248
1247
  };
1249
- }, Dr = !!(typeof window != "undefined" && window.document && window.document.createElement), Me = function(t, e, r) {
1248
+ }, js = !!(typeof window != "undefined" && window.document && window.document.createElement), fn = function(t, e, r) {
1250
1249
  return t.addEventListener ? t.addEventListener(e, r, !1) : t.attachEvent("on" + e, r);
1251
- }, De = function(t, e, r) {
1250
+ }, mn = function(t, e, r) {
1252
1251
  return t.removeEventListener ? t.removeEventListener(e, r, !1) : t.detachEvent("on" + e, r);
1253
- }, jr = function(t, e) {
1252
+ }, Rs = function(t, e) {
1254
1253
  return e(window.confirm(t));
1255
- }, _r = function() {
1254
+ }, Is = function() {
1256
1255
  var t = window.navigator.userAgent;
1257
1256
  return (t.indexOf("Android 2.") !== -1 || t.indexOf("Android 4.0") !== -1) && t.indexOf("Mobile Safari") !== -1 && t.indexOf("Chrome") === -1 && t.indexOf("Windows Phone") === -1 ? !1 : window.history && "pushState" in window.history;
1258
- }, Ir = function() {
1257
+ }, Hs = function() {
1259
1258
  return window.navigator.userAgent.indexOf("Trident") === -1;
1260
- }, Rr = function(t) {
1259
+ }, Us = function(t) {
1261
1260
  return t.state === void 0 && navigator.userAgent.indexOf("CriOS") === -1;
1262
- }, je = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
1261
+ }, vn = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
1263
1262
  return typeof n;
1264
1263
  } : function(n) {
1265
1264
  return n && typeof Symbol == "function" && n.constructor === Symbol && n !== Symbol.prototype ? "symbol" : typeof n;
1266
- }, Tr = Object.assign || function(n) {
1265
+ }, Bs = Object.assign || function(n) {
1267
1266
  for (var t = 1; t < arguments.length; t++) {
1268
1267
  var e = arguments[t];
1269
1268
  for (var r in e)
1270
1269
  Object.prototype.hasOwnProperty.call(e, r) && (n[r] = e[r]);
1271
1270
  }
1272
1271
  return n;
1273
- }, _e = "popstate", Ie = "hashchange", Re = function() {
1272
+ }, yn = "popstate", bn = "hashchange", wn = function() {
1274
1273
  try {
1275
1274
  return window.history.state || {};
1276
1275
  } catch (t) {
1277
1276
  return {};
1278
1277
  }
1279
- }, Hr = function() {
1278
+ }, Vs = function() {
1280
1279
  var t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
1281
- Sr(Dr, "Browser history needs a DOM");
1282
- var e = window.history, r = _r(), s = !Ir(), i = t.forceRefresh, o = i === void 0 ? !1 : i, a = t.getUserConfirmation, c = a === void 0 ? jr : a, h = t.keyLength, u = h === void 0 ? 6 : h, l = t.basename ? Nr(kr(t.basename)) : "", d = function(y) {
1283
- var O = y || {}, L = O.key, M = O.state, F = window.location, J = F.pathname, et = F.search, Y = F.hash, W = J + et + Y;
1284
- return Z(!l || dn(W, l), 'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "' + W + '" to begin with "' + l + '".'), l && (W = Ar(W, l)), ct(W, M, L);
1285
- }, f = function() {
1286
- return Math.random().toString(36).substr(2, u);
1287
- }, g = fn(), E = function(y) {
1288
- Tr(P, y), P.length = e.length, g.notifyListeners(P.location, P.action);
1289
- }, p = function(y) {
1290
- Rr(y) || U(d(y.state));
1291
- }, C = function() {
1292
- U(d(Re()));
1293
- }, T = !1, U = function(y) {
1294
- if (T)
1295
- T = !1, E();
1280
+ Cs(js, "Browser history needs a DOM");
1281
+ var e = window.history, r = Is(), s = !Hs(), i = t.forceRefresh, o = i === void 0 ? !1 : i, a = t.getUserConfirmation, c = a === void 0 ? Rs : a, h = t.keyLength, l = h === void 0 ? 6 : h, u = t.basename ? Ls(Ns(t.basename)) : "", d = function(m) {
1282
+ var O = m || {}, M = O.key, L = O.state, J = window.location, q = J.pathname, rt = J.search, G = J.hash, W = q + rt + G;
1283
+ return tt(!u || or(W, u), 'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "' + W + '" to begin with "' + u + '".'), u && (W = Ms(W, u)), gt(W, L, M);
1284
+ }, p = function() {
1285
+ return Math.random().toString(36).substr(2, l);
1286
+ }, b = cr(), v = function(m) {
1287
+ Bs(_, m), _.length = e.length, b.notifyListeners(_.location, _.action);
1288
+ }, g = function(m) {
1289
+ Us(m) || z(d(m.state));
1290
+ }, E = function() {
1291
+ z(d(wn()));
1292
+ }, j = !1, z = function(m) {
1293
+ if (j)
1294
+ j = !1, v();
1296
1295
  else {
1297
1296
  var O = "POP";
1298
- g.confirmTransitionTo(y, O, c, function(L) {
1299
- L ? E({ action: O, location: y }) : _(y);
1297
+ b.confirmTransitionTo(m, O, c, function(M) {
1298
+ M ? v({ action: O, location: m }) : H(m);
1300
1299
  });
1301
1300
  }
1302
- }, _ = function(y) {
1303
- var O = P.location, L = H.indexOf(O.key);
1304
- L === -1 && (L = 0);
1305
- var M = H.indexOf(y.key);
1301
+ }, H = function(m) {
1302
+ var O = _.location, M = U.indexOf(O.key);
1306
1303
  M === -1 && (M = 0);
1307
- var F = L - M;
1308
- F && (T = !0, j(F));
1309
- }, D = d(Re()), H = [D.key], x = function(y) {
1310
- return l + pn(y);
1311
- }, N = function(y, O) {
1312
- Z(!((typeof y == "undefined" ? "undefined" : je(y)) === "object" && y.state !== void 0 && O !== void 0), "You should avoid providing a 2nd state argument to push when the 1st argument is a location-like object that already has state; it is ignored");
1313
- var L = "PUSH", M = ct(y, O, f(), P.location);
1314
- g.confirmTransitionTo(M, L, c, function(F) {
1315
- if (F) {
1316
- var J = x(M), et = M.key, Y = M.state;
1304
+ var L = U.indexOf(m.key);
1305
+ L === -1 && (L = 0);
1306
+ var J = M - L;
1307
+ J && (j = !0, D(J));
1308
+ }, k = d(wn()), U = [k.key], A = function(m) {
1309
+ return u + ar(m);
1310
+ }, N = function(m, O) {
1311
+ tt(!((typeof m == "undefined" ? "undefined" : vn(m)) === "object" && m.state !== void 0 && O !== void 0), "You should avoid providing a 2nd state argument to push when the 1st argument is a location-like object that already has state; it is ignored");
1312
+ var M = "PUSH", L = gt(m, O, p(), _.location);
1313
+ b.confirmTransitionTo(L, M, c, function(J) {
1314
+ if (J) {
1315
+ var q = A(L), rt = L.key, G = L.state;
1317
1316
  if (r)
1318
- if (e.pushState({ key: et, state: Y }, null, J), o)
1319
- window.location.href = J;
1317
+ if (e.pushState({ key: rt, state: G }, null, q), o)
1318
+ window.location.href = q;
1320
1319
  else {
1321
- var W = H.indexOf(P.location.key), Ee = H.slice(0, W === -1 ? 0 : W + 1);
1322
- Ee.push(M.key), H = Ee, E({ action: L, location: M });
1320
+ var W = U.indexOf(_.location.key), sn = U.slice(0, W === -1 ? 0 : W + 1);
1321
+ sn.push(L.key), U = sn, v({ action: M, location: L });
1323
1322
  }
1324
1323
  else
1325
- Z(Y === void 0, "Browser history cannot push state in browsers that do not support HTML5 history"), window.location.href = J;
1324
+ tt(G === void 0, "Browser history cannot push state in browsers that do not support HTML5 history"), window.location.href = q;
1326
1325
  }
1327
1326
  });
1328
- }, A = function(y, O) {
1329
- Z(!((typeof y == "undefined" ? "undefined" : je(y)) === "object" && y.state !== void 0 && O !== void 0), "You should avoid providing a 2nd state argument to replace when the 1st argument is a location-like object that already has state; it is ignored");
1330
- var L = "REPLACE", M = ct(y, O, f(), P.location);
1331
- g.confirmTransitionTo(M, L, c, function(F) {
1332
- if (F) {
1333
- var J = x(M), et = M.key, Y = M.state;
1327
+ }, C = function(m, O) {
1328
+ tt(!((typeof m == "undefined" ? "undefined" : vn(m)) === "object" && m.state !== void 0 && O !== void 0), "You should avoid providing a 2nd state argument to replace when the 1st argument is a location-like object that already has state; it is ignored");
1329
+ var M = "REPLACE", L = gt(m, O, p(), _.location);
1330
+ b.confirmTransitionTo(L, M, c, function(J) {
1331
+ if (J) {
1332
+ var q = A(L), rt = L.key, G = L.state;
1334
1333
  if (r)
1335
- if (e.replaceState({ key: et, state: Y }, null, J), o)
1336
- window.location.replace(J);
1334
+ if (e.replaceState({ key: rt, state: G }, null, q), o)
1335
+ window.location.replace(q);
1337
1336
  else {
1338
- var W = H.indexOf(P.location.key);
1339
- W !== -1 && (H[W] = M.key), E({ action: L, location: M });
1337
+ var W = U.indexOf(_.location.key);
1338
+ W !== -1 && (U[W] = L.key), v({ action: M, location: L });
1340
1339
  }
1341
1340
  else
1342
- Z(Y === void 0, "Browser history cannot replace state in browsers that do not support HTML5 history"), window.location.replace(J);
1341
+ tt(G === void 0, "Browser history cannot replace state in browsers that do not support HTML5 history"), window.location.replace(q);
1343
1342
  }
1344
1343
  });
1345
- }, j = function(y) {
1346
- e.go(y);
1347
- }, B = function() {
1348
- return j(-1);
1344
+ }, D = function(m) {
1345
+ e.go(m);
1349
1346
  }, V = function() {
1350
- return j(1);
1351
- }, I = 0, m = function(y) {
1352
- I += y, I === 1 ? (Me(window, _e, p), s && Me(window, Ie, C)) : I === 0 && (De(window, _e, p), s && De(window, Ie, C));
1353
- }, b = !1, v = function() {
1354
- var y = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1, O = g.setPrompt(y);
1355
- return b || (m(1), b = !0), function() {
1356
- return b && (b = !1, m(-1)), O();
1347
+ return D(-1);
1348
+ }, B = function() {
1349
+ return D(1);
1350
+ }, R = 0, f = function(m) {
1351
+ R += m, R === 1 ? (fn(window, yn, g), s && fn(window, bn, E)) : R === 0 && (mn(window, yn, g), s && mn(window, bn, E));
1352
+ }, w = !1, y = function() {
1353
+ var m = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1, O = b.setPrompt(m);
1354
+ return w || (f(1), w = !0), function() {
1355
+ return w && (w = !1, f(-1)), O();
1357
1356
  };
1358
- }, w = function(y) {
1359
- var O = g.appendListener(y);
1360
- return m(1), function() {
1361
- m(-1), O();
1357
+ }, $ = function(m) {
1358
+ var O = b.appendListener(m);
1359
+ return f(1), function() {
1360
+ f(-1), O();
1362
1361
  };
1363
- }, P = {
1362
+ }, _ = {
1364
1363
  length: e.length,
1365
1364
  action: "POP",
1366
- location: D,
1367
- createHref: x,
1365
+ location: k,
1366
+ createHref: A,
1368
1367
  push: N,
1369
- replace: A,
1370
- go: j,
1371
- goBack: B,
1372
- goForward: V,
1373
- block: v,
1374
- listen: w
1368
+ replace: C,
1369
+ go: D,
1370
+ goBack: V,
1371
+ goForward: B,
1372
+ block: y,
1373
+ listen: $
1375
1374
  };
1376
- return P;
1377
- }, Te = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
1375
+ return _;
1376
+ }, $n = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
1378
1377
  return typeof n;
1379
1378
  } : function(n) {
1380
1379
  return n && typeof Symbol == "function" && n.constructor === Symbol && n !== Symbol.prototype ? "symbol" : typeof n;
1381
- }, Vr = Object.assign || function(n) {
1380
+ }, zs = Object.assign || function(n) {
1382
1381
  for (var t = 1; t < arguments.length; t++) {
1383
1382
  var e = arguments[t];
1384
1383
  for (var r in e)
1385
1384
  Object.prototype.hasOwnProperty.call(e, r) && (n[r] = e[r]);
1386
1385
  }
1387
1386
  return n;
1388
- }, He = function(t, e, r) {
1387
+ }, On = function(t, e, r) {
1389
1388
  return Math.min(Math.max(t, e), r);
1390
- }, Br = function() {
1391
- var t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, e = t.getUserConfirmation, r = t.initialEntries, s = r === void 0 ? ["/"] : r, i = t.initialIndex, o = i === void 0 ? 0 : i, a = t.keyLength, c = a === void 0 ? 6 : a, h = fn(), u = function(A) {
1392
- Vr(x, A), x.length = x.entries.length, h.notifyListeners(x.location, x.action);
1393
- }, l = function() {
1389
+ }, Ws = function() {
1390
+ var t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, e = t.getUserConfirmation, r = t.initialEntries, s = r === void 0 ? ["/"] : r, i = t.initialIndex, o = i === void 0 ? 0 : i, a = t.keyLength, c = a === void 0 ? 6 : a, h = cr(), l = function(C) {
1391
+ zs(A, C), A.length = A.entries.length, h.notifyListeners(A.location, A.action);
1392
+ }, u = function() {
1394
1393
  return Math.random().toString(36).substr(2, c);
1395
- }, d = He(o, 0, s.length - 1), f = s.map(function(N) {
1396
- return typeof N == "string" ? ct(N, void 0, l()) : ct(N, void 0, N.key || l());
1397
- }), g = pn, E = function(A, j) {
1398
- Z(!((typeof A == "undefined" ? "undefined" : Te(A)) === "object" && A.state !== void 0 && j !== void 0), "You should avoid providing a 2nd state argument to push when the 1st argument is a location-like object that already has state; it is ignored");
1399
- var B = "PUSH", V = ct(A, j, l(), x.location);
1400
- h.confirmTransitionTo(V, B, e, function(I) {
1401
- if (I) {
1402
- var m = x.index, b = m + 1, v = x.entries.slice(0);
1403
- v.length > b ? v.splice(b, v.length - b, V) : v.push(V), u({
1404
- action: B,
1405
- location: V,
1406
- index: b,
1407
- entries: v
1394
+ }, d = On(o, 0, s.length - 1), p = s.map(function(N) {
1395
+ return typeof N == "string" ? gt(N, void 0, u()) : gt(N, void 0, N.key || u());
1396
+ }), b = ar, v = function(C, D) {
1397
+ tt(!((typeof C == "undefined" ? "undefined" : $n(C)) === "object" && C.state !== void 0 && D !== void 0), "You should avoid providing a 2nd state argument to push when the 1st argument is a location-like object that already has state; it is ignored");
1398
+ var V = "PUSH", B = gt(C, D, u(), A.location);
1399
+ h.confirmTransitionTo(B, V, e, function(R) {
1400
+ if (R) {
1401
+ var f = A.index, w = f + 1, y = A.entries.slice(0);
1402
+ y.length > w ? y.splice(w, y.length - w, B) : y.push(B), l({
1403
+ action: V,
1404
+ location: B,
1405
+ index: w,
1406
+ entries: y
1408
1407
  });
1409
1408
  }
1410
1409
  });
1411
- }, p = function(A, j) {
1412
- Z(!((typeof A == "undefined" ? "undefined" : Te(A)) === "object" && A.state !== void 0 && j !== void 0), "You should avoid providing a 2nd state argument to replace when the 1st argument is a location-like object that already has state; it is ignored");
1413
- var B = "REPLACE", V = ct(A, j, l(), x.location);
1414
- h.confirmTransitionTo(V, B, e, function(I) {
1415
- I && (x.entries[x.index] = V, u({ action: B, location: V }));
1410
+ }, g = function(C, D) {
1411
+ tt(!((typeof C == "undefined" ? "undefined" : $n(C)) === "object" && C.state !== void 0 && D !== void 0), "You should avoid providing a 2nd state argument to replace when the 1st argument is a location-like object that already has state; it is ignored");
1412
+ var V = "REPLACE", B = gt(C, D, u(), A.location);
1413
+ h.confirmTransitionTo(B, V, e, function(R) {
1414
+ R && (A.entries[A.index] = B, l({ action: V, location: B }));
1416
1415
  });
1417
- }, C = function(A) {
1418
- var j = He(x.index + A, 0, x.entries.length - 1), B = "POP", V = x.entries[j];
1419
- h.confirmTransitionTo(V, B, e, function(I) {
1420
- I ? u({
1421
- action: B,
1422
- location: V,
1423
- index: j
1424
- }) : u();
1416
+ }, E = function(C) {
1417
+ var D = On(A.index + C, 0, A.entries.length - 1), V = "POP", B = A.entries[D];
1418
+ h.confirmTransitionTo(B, V, e, function(R) {
1419
+ R ? l({
1420
+ action: V,
1421
+ location: B,
1422
+ index: D
1423
+ }) : l();
1425
1424
  });
1426
- }, T = function() {
1427
- return C(-1);
1428
- }, U = function() {
1429
- return C(1);
1430
- }, _ = function(A) {
1431
- var j = x.index + A;
1432
- return j >= 0 && j < x.entries.length;
1433
- }, D = function() {
1434
- var A = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
1435
- return h.setPrompt(A);
1436
- }, H = function(A) {
1437
- return h.appendListener(A);
1438
- }, x = {
1439
- length: f.length,
1425
+ }, j = function() {
1426
+ return E(-1);
1427
+ }, z = function() {
1428
+ return E(1);
1429
+ }, H = function(C) {
1430
+ var D = A.index + C;
1431
+ return D >= 0 && D < A.entries.length;
1432
+ }, k = function() {
1433
+ var C = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
1434
+ return h.setPrompt(C);
1435
+ }, U = function(C) {
1436
+ return h.appendListener(C);
1437
+ }, A = {
1438
+ length: p.length,
1440
1439
  action: "POP",
1441
- location: f[d],
1440
+ location: p[d],
1442
1441
  index: d,
1443
- entries: f,
1444
- createHref: g,
1445
- push: E,
1446
- replace: p,
1447
- go: C,
1448
- goBack: T,
1449
- goForward: U,
1450
- canGo: _,
1451
- block: D,
1452
- listen: H
1442
+ entries: p,
1443
+ createHref: b,
1444
+ push: v,
1445
+ replace: g,
1446
+ go: E,
1447
+ goBack: j,
1448
+ goForward: z,
1449
+ canGo: H,
1450
+ block: k,
1451
+ listen: U
1453
1452
  };
1454
- return x;
1455
- }, Ur = Object.defineProperty, Ve = Object.getOwnPropertySymbols, Wr = Object.prototype.hasOwnProperty, zr = Object.prototype.propertyIsEnumerable, Be = (n, t, e) => t in n ? Ur(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, pt = (n, t) => {
1453
+ return A;
1454
+ }, Fs = Object.defineProperty, En = Object.getOwnPropertySymbols, Js = Object.prototype.hasOwnProperty, qs = Object.prototype.propertyIsEnumerable, An = (n, t, e) => t in n ? Fs(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, $t = (n, t) => {
1456
1455
  for (var e in t || (t = {}))
1457
- Wr.call(t, e) && Be(n, e, t[e]);
1458
- if (Ve)
1459
- for (var e of Ve(t))
1460
- zr.call(t, e) && Be(n, e, t[e]);
1456
+ Js.call(t, e) && An(n, e, t[e]);
1457
+ if (En)
1458
+ for (var e of En(t))
1459
+ qs.call(t, e) && An(n, e, t[e]);
1461
1460
  return n;
1462
- }, kt = (n, t, e) => new Promise((r, s) => {
1461
+ }, Jt = (n, t, e) => new Promise((r, s) => {
1463
1462
  var i = (c) => {
1464
1463
  try {
1465
1464
  a(e.next(c));
@@ -1474,15 +1473,15 @@ var kr = function(t) {
1474
1473
  }
1475
1474
  }, a = (c) => c.done ? r(c.value) : Promise.resolve(c.value).then(i, o);
1476
1475
  a((e = e.apply(n, t)).next());
1477
- }), S = /* @__PURE__ */ ((n) => (n.Cookie = "cookie", n.Local = "local", n.Session = "session", n))(S || {}), vt = /* @__PURE__ */ ((n) => (n.Tenant = "tenant", n.Implementation = "implementation", n.Widget = "widget", n))(vt || {}), k = /* @__PURE__ */ ((n) => (n.Necessary = "necessary", n.Functional = "functional", n.Analytical = "analytical", n.Marketing = "marketing", n))(k || {});
1478
- const X = (n, t, e, r = {}) => Ue(n, e).then((s) => (process.env.NODE_ENV !== "production" && s && R.warn(
1476
+ }), S = /* @__PURE__ */ ((n) => (n.Cookie = "cookie", n.Local = "local", n.Session = "session", n))(S || {}), Ct = /* @__PURE__ */ ((n) => (n.Tenant = "tenant", n.Implementation = "implementation", n.Widget = "widget", n))(Ct || {}), P = /* @__PURE__ */ ((n) => (n.Necessary = "necessary", n.Functional = "functional", n.Analytical = "analytical", n.Marketing = "marketing", n))(P || {});
1477
+ const et = (n, t, e, r = {}) => xn(n, e).then((s) => (process.env.NODE_ENV !== "production" && s && I.warn(
1479
1478
  `createStorageWriter: Attempted to create storage writer using unallowed category.
1480
1479
  Key: ${t}
1481
1480
  Category: ${JSON.stringify(e)}
1482
1481
  Options: ${JSON.stringify(r)}`
1483
- ), (i) => (be(n), Ue(n, e).then((o) => {
1482
+ ), (i) => (Qe(n), xn(n, e).then((o) => {
1484
1483
  if (o) {
1485
- process.env.NODE_ENV !== "production" && R.warn(
1484
+ process.env.NODE_ENV !== "production" && I.warn(
1486
1485
  `storageWriter: Attempted to write to storage using unallowed category.
1487
1486
  Key: ${t}
1488
1487
  Category: ${JSON.stringify(e)}
@@ -1492,104 +1491,104 @@ const X = (n, t, e, r = {}) => Ue(n, e).then((s) => (process.env.NODE_ENV !== "p
1492
1491
  return;
1493
1492
  }
1494
1493
  const {
1495
- scope: a = vt.Widget,
1494
+ scope: a = Ct.Widget,
1496
1495
  medium: c = S.Session,
1497
1496
  duration: h
1498
- } = r, u = Jr();
1499
- return u[a][t] = ve(i, e, h), c === S.Cookie ? Gr(n, u) : Zr(n, c, u);
1500
- })))), q = (n, t, e = S.Session) => (be(n), typeof t == "undefined" ? (process.env.NODE_ENV !== "production" && R.warn("readStorage: Undefined key passed when reading storage. ", t, e), Promise.resolve(void 0)) : e === S.Cookie ? Yr(n).then((r) => Bt(r, t)) : Qr(n, e).then((r) => Bt(r, t))), mt = (n) => !!Object.entries(n).filter(([t, e]) => typeof e != "undefined").length, ne = (n) => Object.entries(n).filter(([t, e]) => typeof e != "undefined").forEach(([t, { value: e }]) => {
1497
+ } = r, l = Ys();
1498
+ return l[a][t] = Ze(i, e, h), c === S.Cookie ? Xs(n, l) : ei(n, c, l);
1499
+ })))), Y = (n, t, e = S.Session) => (Qe(n), typeof t == "undefined" ? (process.env.NODE_ENV !== "production" && I.warn("readStorage: Undefined key passed when reading storage. ", t, e), Promise.resolve(void 0)) : e === S.Cookie ? Qs(n).then((r) => ae(r, t)) : ti(n, e).then((r) => ae(r, t))), xt = (n) => !!Object.entries(n).filter(([t, e]) => typeof e != "undefined").length, xe = (n) => Object.entries(n).filter(([t, e]) => typeof e != "undefined").forEach(([t, { value: e }]) => {
1501
1500
  typeof e == "undefined" && delete n[t];
1502
- }), gn = (n, t) => {
1501
+ }), hr = (n, t) => {
1503
1502
  const e = {
1504
- tenant: pt(pt({}, n.tenant), t.tenant),
1505
- implementation: pt(pt({}, n.implementation), t.implementation),
1506
- widget: pt(pt({}, n.widget), t.widget)
1503
+ tenant: $t($t({}, n.tenant), t.tenant),
1504
+ implementation: $t($t({}, n.implementation), t.implementation),
1505
+ widget: $t($t({}, n.widget), t.widget)
1507
1506
  };
1508
- return ne(e.tenant), ne(e.implementation), ne(e.widget), e;
1509
- }, Fr = (n) => Object.entries(n).reduce((t, e) => {
1507
+ return xe(e.tenant), xe(e.implementation), xe(e.widget), e;
1508
+ }, Ks = (n) => Object.entries(n).reduce((t, e) => {
1510
1509
  const [r, s] = e;
1511
1510
  return Object.entries(s).forEach((i) => {
1512
1511
  const [o, { expiration: a }] = i;
1513
1512
  a && t.push(a);
1514
1513
  }), t;
1515
- }, []).slice().sort((t, e) => new Date(e).valueOf() - new Date(t).valueOf()).shift() || Gt(), Yt = (n) => {
1514
+ }, []).slice().sort((t, e) => new Date(e).valueOf() - new Date(t).valueOf()).shift() || ye(), ve = (n) => {
1516
1515
  const {
1517
1516
  name: t,
1518
1517
  implementation: { name: e, tenant: r }
1519
1518
  } = n.get("$widget");
1520
1519
  return [
1521
1520
  `humany_${r}`,
1522
- `humany_${ke(r + e)}`,
1523
- `humany_${ke(r + e + t)}`
1521
+ `humany_${un(r + e)}`,
1522
+ `humany_${un(r + e + t)}`
1524
1523
  ];
1525
- }, re = (n) => {
1524
+ }, _e = (n) => {
1526
1525
  const t = new RegExp(`(?:^|;)\\s?${n}=(.*?)(?:;|$)`, "i"), e = document.cookie.match(t);
1527
1526
  return e && e[1] && JSON.parse(e[1]) || void 0;
1528
- }, se = (n, t, e) => {
1527
+ }, Se = (n, t, e) => {
1529
1528
  const r = `${n}=${JSON.stringify(t).trim()}`, s = `expires=${new Date(e).toUTCString()}`, i = "path=/", o = "SameSite=None;Secure";
1530
1529
  return document.cookie = `${r}; ${s}; ${i}; ${o}`;
1531
- }, ye = (n) => {
1532
- const [t, e, r] = Yt(n), s = re(t) || {}, i = re(e) || {}, o = re(r) || {};
1530
+ }, Ge = (n) => {
1531
+ const [t, e, r] = ve(n), s = _e(t) || {}, i = _e(e) || {}, o = _e(r) || {};
1533
1532
  return {
1534
1533
  tenant: s,
1535
1534
  implementation: i,
1536
1535
  widget: o
1537
1536
  };
1538
- }, mn = (n, t) => {
1539
- const e = ye(n), r = gn(e, t), [s, i, o] = Yt(n), { tenant: a, implementation: c, widget: h } = r, u = Fr(t), l = Gt({ days: -1 });
1540
- se(s, a, mt(a) ? u : l), se(
1537
+ }, lr = (n, t) => {
1538
+ const e = Ge(n), r = hr(e, t), [s, i, o] = ve(n), { tenant: a, implementation: c, widget: h } = r, l = Ks(t), u = ye({ days: -1 });
1539
+ Se(s, a, xt(a) ? l : u), Se(
1541
1540
  i,
1542
1541
  c,
1543
- mt(c) ? u : l
1544
- ), se(o, h, mt(h) ? u : l);
1545
- }, Vt = (n, t) => {
1546
- const [e, r, s] = Yt(n), i = t.getItem(e) || "{}", o = t.getItem(r) || "{}", a = t.getItem(s) || "{}";
1542
+ xt(c) ? l : u
1543
+ ), Se(o, h, xt(h) ? l : u);
1544
+ }, oe = (n, t) => {
1545
+ const [e, r, s] = ve(n), i = t.getItem(e) || "{}", o = t.getItem(r) || "{}", a = t.getItem(s) || "{}";
1547
1546
  return {
1548
1547
  tenant: JSON.parse(i),
1549
1548
  implementation: JSON.parse(o),
1550
1549
  widget: JSON.parse(a)
1551
1550
  };
1552
- }, de = (n, t, e) => {
1553
- const r = Vt(n, t), s = gn(r, e), [i, o, a] = Yt(n), { tenant: c, implementation: h, widget: u } = s;
1554
- mt(c) ? t.setItem(i, JSON.stringify(c)) : t.removeItem(i), mt(h) ? t.setItem(o, JSON.stringify(h)) : t.removeItem(o), mt(u) ? t.setItem(a, JSON.stringify(u)) : t.removeItem(a);
1555
- }, Jr = () => ({ tenant: {}, implementation: {}, widget: {} }), Kr = (n) => n ? !!n && /* @__PURE__ */ new Date() > new Date(n) : !1, Bt = (n, t) => {
1551
+ }, Ve = (n, t, e) => {
1552
+ const r = oe(n, t), s = hr(r, e), [i, o, a] = ve(n), { tenant: c, implementation: h, widget: l } = s;
1553
+ xt(c) ? t.setItem(i, JSON.stringify(c)) : t.removeItem(i), xt(h) ? t.setItem(o, JSON.stringify(h)) : t.removeItem(o), xt(l) ? t.setItem(a, JSON.stringify(l)) : t.removeItem(a);
1554
+ }, Ys = () => ({ tenant: {}, implementation: {}, widget: {} }), Gs = (n) => n ? !!n && /* @__PURE__ */ new Date() > new Date(n) : !1, ae = (n, t) => {
1556
1555
  const e = n.widget[t] || n.implementation[t] || n.tenant[t];
1557
1556
  return e == null ? void 0 : e.value;
1558
- }, ve = (n, t, e) => e ? {
1557
+ }, Ze = (n, t, e) => e ? {
1559
1558
  value: n,
1560
1559
  category: t,
1561
- expiration: typeof e == "object" ? Gt(e) : e
1560
+ expiration: typeof e == "object" ? ye(e) : e
1562
1561
  } : {
1563
1562
  value: n,
1564
1563
  category: t
1565
- }, Dt = (n, t) => {
1566
- const e = Zn(n);
1564
+ }, Qt = (n, t) => {
1565
+ const e = es(n);
1567
1566
  return Object.entries(e).forEach(([r, s]) => {
1568
1567
  Object.entries(s).forEach(([i, o]) => {
1569
1568
  const { expiration: a, category: c } = o;
1570
- (Kr(a) || qr(t, c)) && (s[i] = ve(void 0, c, a));
1569
+ (Gs(a) || Zs(t, c)) && (s[i] = Ze(void 0, c, a));
1571
1570
  });
1572
1571
  }), e;
1573
- }, Ue = (n, t) => q(n, "storagePolicy", S.Cookie).then(
1574
- (e = [k.Necessary]) => !!t && e.indexOf(t) === -1
1575
- ), qr = (n = [k.Necessary], t) => !!t && n.indexOf(t) === -1, be = (n) => {
1576
- const t = ye(n), e = Vt(n, window.localStorage), r = Vt(n, sessionStorage), s = Bt(t, "storagePolicy"), [i, o, a] = [
1572
+ }, xn = (n, t) => Y(n, "storagePolicy", S.Cookie).then(
1573
+ (e = [P.Necessary]) => !!t && e.indexOf(t) === -1
1574
+ ), Zs = (n = [P.Necessary], t) => !!t && n.indexOf(t) === -1, Qe = (n) => {
1575
+ const t = Ge(n), e = oe(n, window.localStorage), r = oe(n, sessionStorage), s = ae(t, "storagePolicy"), [i, o, a] = [
1577
1576
  t,
1578
1577
  e,
1579
1578
  r
1580
- ].map((c) => Dt(c, s));
1581
- mn(n, i), de(n, window.localStorage, o), de(n, window.sessionStorage, a);
1582
- }, Gt = (n = { days: 30 }) => {
1579
+ ].map((c) => Qt(c, s));
1580
+ lr(n, i), Ve(n, window.localStorage, o), Ve(n, window.sessionStorage, a);
1581
+ }, ye = (n = { days: 30 }) => {
1583
1582
  const { days: t = 0, hours: e = 0, minutes: r = 0, seconds: s = 0 } = n, i = /* @__PURE__ */ new Date();
1584
1583
  return i.setTime(i.getTime() + e * 60 * 60 * 1e3), i.setTime(i.getTime() + t * 24 * 60 * 60 * 1e3), i.setTime(i.getTime() + r * 60 * 1e3), i.setTime(i.getTime() + s * 1e3), i.toISOString();
1585
- }, Yr = (n) => G(document)(() => ye(n)), Gr = (n, t) => G(document)(() => mn(n, t)), Qr = (n, t) => {
1584
+ }, Qs = (n) => Z(document)(() => Ge(n)), Xs = (n, t) => Z(document)(() => lr(n, t)), ti = (n, t) => {
1586
1585
  const e = t === S.Local ? window.localStorage : window.sessionStorage;
1587
- return G(e)(() => Vt(n, e));
1588
- }, Zr = (n, t, e) => {
1586
+ return Z(e)(() => oe(n, e));
1587
+ }, ei = (n, t, e) => {
1589
1588
  const r = t === S.Local ? window.localStorage : window.sessionStorage;
1590
- return G(r)(() => de(n, r, e));
1589
+ return Z(r)(() => Ve(n, r, e));
1591
1590
  };
1592
- class jt {
1591
+ let Xt = class {
1593
1592
  constructor() {
1594
1593
  this.memory = {
1595
1594
  tenant: {},
@@ -1598,14 +1597,14 @@ class jt {
1598
1597
  };
1599
1598
  }
1600
1599
  setItem(t, e) {
1601
- return kt(this, arguments, function* (r, s, i = {}) {
1602
- return G(this)(() => {
1603
- const o = Dt(this.memory, [k.Necessary]), { scope: a = vt.Tenant, expiration: c } = i;
1604
- o[a][r] = ve(
1600
+ return Jt(this, arguments, function* (r, s, i = {}) {
1601
+ return Z(this)(() => {
1602
+ const o = Qt(this.memory, [P.Necessary]), { scope: a = Ct.Tenant, expiration: c } = i;
1603
+ o[a][r] = Ze(
1605
1604
  s,
1606
- k.Necessary,
1607
- (c == null ? void 0 : c.toISOString()) || Gt()
1608
- ), this.memory = o, process.env.NODE_ENV !== "production" && R.warn(
1605
+ P.Necessary,
1606
+ (c == null ? void 0 : c.toISOString()) || ye()
1607
+ ), this.memory = o, process.env.NODE_ENV !== "production" && I.warn(
1609
1608
  `StorageProvider: StorageProvider is deprecated, use createStorageWriter and readStorage instead, value stored temporarily in memory.
1610
1609
  Key: ${r}
1611
1610
  Value: ${JSON.stringify(s)}
@@ -1616,24 +1615,24 @@ class jt {
1616
1615
  });
1617
1616
  }
1618
1617
  getItem(t) {
1619
- return kt(this, null, function* () {
1620
- return G(this)(() => {
1621
- const e = Dt(this.memory, [k.Necessary]);
1622
- process.env.NODE_ENV !== "production" && R.warn(
1618
+ return Jt(this, null, function* () {
1619
+ return Z(this)(() => {
1620
+ const e = Qt(this.memory, [P.Necessary]);
1621
+ process.env.NODE_ENV !== "production" && I.warn(
1623
1622
  `StorageProvider: StorageProvider is deprecated, use createStorageWriter and readStorage instead, value fetched from legacy memory storage.
1624
1623
  Key: ${t}
1625
1624
  Memory: ${JSON.stringify(e)}`
1626
1625
  );
1627
- const r = Bt(e, t);
1626
+ const r = ae(e, t);
1628
1627
  return this.memory = e, r;
1629
1628
  });
1630
1629
  });
1631
1630
  }
1632
1631
  removeItem(t) {
1633
- return kt(this, null, function* () {
1634
- return G(this)(() => {
1635
- const e = Dt(this.memory, [k.Necessary]);
1636
- delete e.tenant[t], delete e.implementation[t], delete e.widget[t], this.memory = e, process.env.NODE_ENV !== "production" && R.warn(
1632
+ return Jt(this, null, function* () {
1633
+ return Z(this)(() => {
1634
+ const e = Qt(this.memory, [P.Necessary]);
1635
+ delete e.tenant[t], delete e.implementation[t], delete e.widget[t], this.memory = e, process.env.NODE_ENV !== "production" && I.warn(
1637
1636
  `StorageProvider: StorageProvider is deprecated, use createStorageWriter and readStorage instead, value removed from memory.
1638
1637
  Key: ${t}
1639
1638
  Memory: ${JSON.stringify(e)}`
@@ -1642,17 +1641,16 @@ class jt {
1642
1641
  });
1643
1642
  }
1644
1643
  clear() {
1645
- return kt(this, null, function* () {
1644
+ return Jt(this, null, function* () {
1646
1645
  return Promise.resolve();
1647
1646
  });
1648
1647
  }
1649
- }
1650
- let Xr = class {
1648
+ }, ni = class {
1651
1649
  constructor() {
1652
- this.cookies = new jt(), this.session = new jt(), this.local = new jt();
1650
+ this.cookies = new Xt(), this.session = new Xt(), this.local = new Xt();
1653
1651
  }
1654
1652
  };
1655
- const ie = (n, t, e, ...r) => {
1653
+ const Pe = (n, t, e, ...r) => {
1656
1654
  const s = `[${n.get("$environment").name || "webprovisions"}] ${e}`;
1657
1655
  switch (t) {
1658
1656
  case "info":
@@ -1665,16 +1663,16 @@ const ie = (n, t, e, ...r) => {
1665
1663
  console.error(s, ...r);
1666
1664
  break;
1667
1665
  }
1668
- }, ts = (n) => {
1666
+ }, ri = (n) => {
1669
1667
  const t = n.container || n;
1670
1668
  return {
1671
- info: (e, ...r) => ie(t, "info", e, ...r),
1672
- warn: (e, ...r) => ie(t, "warning", e, ...r),
1673
- error: (e, ...r) => ie(t, "error", e, ...r)
1669
+ info: (e, ...r) => Pe(t, "info", e, ...r),
1670
+ warn: (e, ...r) => Pe(t, "warning", e, ...r),
1671
+ error: (e, ...r) => Pe(t, "error", e, ...r)
1674
1672
  };
1675
1673
  };
1676
- var Ut = /* @__PURE__ */ ((n) => (n.Implementation = "implementation", n.Widget = "widget", n))(Ut || {}), ht = /* @__PURE__ */ ((n) => (n.Pre = "pre", n.Post = "post", n))(ht || {});
1677
- const es = (n, t, e, r) => {
1674
+ var ce = /* @__PURE__ */ ((n) => (n.Implementation = "implementation", n.Widget = "widget", n))(ce || {}), ft = /* @__PURE__ */ ((n) => (n.Pre = "pre", n.Post = "post", n))(ft || {});
1675
+ const si = (n, t, e, r) => {
1678
1676
  try {
1679
1677
  const s = new t(e, r);
1680
1678
  return {
@@ -1698,23 +1696,23 @@ const es = (n, t, e, r) => {
1698
1696
  throw s;
1699
1697
  }
1700
1698
  };
1701
- function We(n, t) {
1699
+ function _n(n, t) {
1702
1700
  return typeof n == "undefined" ? t : n;
1703
1701
  }
1704
- let ns = class {
1702
+ let ii = class {
1705
1703
  constructor(t = {}) {
1706
1704
  this.part = t;
1707
1705
  }
1708
1706
  createCommand(t, e, r) {
1709
1707
  let s;
1710
1708
  typeof e == "function" ? s = {
1711
- scope: Ut.Widget,
1712
- stage: ht.Post,
1709
+ scope: ce.Widget,
1710
+ stage: ft.Post,
1713
1711
  defaultArgs: void 0,
1714
1712
  handlerResolver: e
1715
1713
  } : s = {
1716
- scope: We(e.scope, Ut.Widget),
1717
- stage: We(e.stage, ht.Post),
1714
+ scope: _n(e.scope, ce.Widget),
1715
+ stage: _n(e.stage, ft.Post),
1718
1716
  defaultArgs: e.defaultArgs,
1719
1717
  handlerResolver: r
1720
1718
  };
@@ -1728,26 +1726,26 @@ let ns = class {
1728
1726
  return this.part;
1729
1727
  }
1730
1728
  };
1731
- const yn = (n) => {
1732
- const t = new ns({});
1729
+ const ur = (n) => {
1730
+ const t = new ii({});
1733
1731
  return n(t), t.get();
1734
1732
  };
1735
- yn((n) => {
1733
+ ur((n) => {
1736
1734
  n.createCommand(
1737
1735
  "types.register",
1738
- { scope: Ut.Implementation, stage: ht.Pre },
1736
+ { scope: ce.Implementation, stage: ft.Pre },
1739
1737
  (t) => (e, r) => {
1740
1738
  t.container.get("$types")[e] = r;
1741
1739
  }
1742
1740
  ).createCommand(
1743
1741
  "type",
1744
- { stage: ht.Pre },
1742
+ { stage: ft.Pre },
1745
1743
  (t) => (e) => {
1746
1744
  t.container.register("$type", e);
1747
1745
  }
1748
1746
  ).createCommand(
1749
1747
  "settings",
1750
- { stage: ht.Pre, defaultArgs: [null] },
1748
+ { stage: ft.Pre, defaultArgs: [null] },
1751
1749
  (t) => (e) => {
1752
1750
  t.events.dispatch(
1753
1751
  "settings:change",
@@ -1757,28 +1755,28 @@ yn((n) => {
1757
1755
  }
1758
1756
  ).createCommand(
1759
1757
  "plugin",
1760
- { stage: ht.Pre },
1758
+ { stage: ft.Pre },
1761
1759
  (t) => (e, r, s) => {
1762
1760
  const { container: i } = t;
1763
1761
  let o = null, a = e, c = r;
1764
1762
  typeof e == "string" && (o = e, a = r, c = s);
1765
- const h = (u) => {
1766
- const { transformPluginSettings: l } = t.container.get("$environmentOptions"), d = l ? l(
1763
+ const h = (l) => {
1764
+ const { transformPluginSettings: u } = t.container.get("$environmentOptions"), d = u ? u(
1767
1765
  c || {},
1768
1766
  o,
1769
1767
  t.container,
1770
1768
  a
1771
1769
  ) : r;
1772
1770
  try {
1773
- const f = es(
1771
+ const p = si(
1774
1772
  o,
1775
1773
  a,
1776
1774
  i,
1777
1775
  d
1778
1776
  );
1779
- i.get("$plugins").push(f), u && f.invoke("initialize", null);
1780
- } catch (f) {
1781
- ts(t).warn("Error when initializing plugin", f);
1777
+ i.get("$plugins").push(p), l && p.invoke("initialize", null);
1778
+ } catch (p) {
1779
+ ri(t).warn("Error when initializing plugin", p);
1782
1780
  }
1783
1781
  };
1784
1782
  t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
@@ -1811,12 +1809,12 @@ yn((n) => {
1811
1809
  }
1812
1810
  );
1813
1811
  });
1814
- yn((n) => {
1812
+ ur((n) => {
1815
1813
  n.createCommand("storage", (t) => (e = {}) => {
1816
1814
  const { consent: r } = e;
1817
1815
  if (typeof r != "undefined") {
1818
1816
  if (typeof r != "number" && typeof r != "string" && !Array.isArray(r)) {
1819
- process.env.NODE_ENV !== "production" && R.warn(
1817
+ process.env.NODE_ENV !== "production" && I.warn(
1820
1818
  `storagePolicyConfigurationApi: passed consent is not valid. Consent either has to be a number, a string, an array of strings or an array of numbers.
1821
1819
  Passed consent: ${JSON.stringify(r)}`
1822
1820
  );
@@ -1825,63 +1823,63 @@ yn((n) => {
1825
1823
  if (Array.isArray(r) && !r.every(
1826
1824
  (i) => typeof i == "number" || typeof i == "string"
1827
1825
  )) {
1828
- process.env.NODE_ENV !== "production" && R.warn(
1826
+ process.env.NODE_ENV !== "production" && I.warn(
1829
1827
  `storagePolicyConfigurationApi: passed consent is not valid. Consent either has to be a number, a string, an array of strings or an array of numbers.
1830
1828
  Passed consent: ${JSON.stringify(r)}`
1831
1829
  );
1832
1830
  return;
1833
1831
  }
1834
1832
  const s = [
1835
- k.Necessary,
1836
- k.Functional,
1837
- k.Analytical,
1838
- k.Marketing
1833
+ P.Necessary,
1834
+ P.Functional,
1835
+ P.Analytical,
1836
+ P.Marketing
1839
1837
  ].filter((i, o, a) => typeof r == "number" ? r > o : typeof r == "string" ? a.indexOf(r) + 1 > o : Array.isArray(r) ? r.findIndex((c) => c === o + 1 || c === i) > -1 : !0);
1840
- return s.indexOf(k.Necessary) === -1 && (process.env.NODE_ENV !== "production" && R.warn(
1841
- `storagePolicyConfigurationApi: passed consent does not include category: '${k.Necessary}'. Consent has to atleast include the '${k.Necessary}' category.
1838
+ return s.indexOf(P.Necessary) === -1 && (process.env.NODE_ENV !== "production" && I.warn(
1839
+ `storagePolicyConfigurationApi: passed consent does not include category: '${P.Necessary}'. Consent has to atleast include the '${P.Necessary}' category.
1842
1840
  Passed consent: ${JSON.stringify(r)}`
1843
- ), s.unshift(k.Necessary)), X(
1841
+ ), s.unshift(P.Necessary)), et(
1844
1842
  t.container,
1845
1843
  "storagePolicy",
1846
- k.Necessary,
1844
+ P.Necessary,
1847
1845
  {
1848
1846
  medium: S.Cookie,
1849
- scope: vt.Tenant,
1847
+ scope: Ct.Tenant,
1850
1848
  duration: { days: 365 }
1851
1849
  }
1852
1850
  ).then((i) => i(s)).then(() => {
1853
- be(t.container), t.events.dispatch("storage:policy-changed", s);
1851
+ Qe(t.container), t.events.dispatch("storage:policy-changed", s);
1854
1852
  });
1855
1853
  }
1856
1854
  });
1857
1855
  });
1858
- const rs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1856
+ const oi = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1859
1857
  __proto__: null,
1860
- StorageCategory: k,
1858
+ StorageCategory: P,
1861
1859
  StorageMedium: S,
1862
- StorageProvider: Xr,
1863
- StorageScope: vt,
1864
- StorageService: jt,
1865
- createStorageWriter: X,
1866
- readStorage: q
1860
+ StorageProvider: ni,
1861
+ StorageScope: Ct,
1862
+ StorageService: Xt,
1863
+ createStorageWriter: et,
1864
+ readStorage: Y
1867
1865
  }, Symbol.toStringTag, { value: "Module" }));
1868
- var ss = Object.defineProperty, is = Object.defineProperties, os = Object.getOwnPropertyDescriptors, Wt = Object.getOwnPropertySymbols, vn = Object.prototype.hasOwnProperty, bn = Object.prototype.propertyIsEnumerable, ze = (n, t, e) => t in n ? ss(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, gt = (n, t) => {
1866
+ var ai = Object.defineProperty, ci = Object.defineProperties, hi = Object.getOwnPropertyDescriptors, he = Object.getOwnPropertySymbols, dr = Object.prototype.hasOwnProperty, pr = Object.prototype.propertyIsEnumerable, Sn = (n, t, e) => t in n ? ai(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, Et = (n, t) => {
1869
1867
  for (var e in t || (t = {}))
1870
- vn.call(t, e) && ze(n, e, t[e]);
1871
- if (Wt)
1872
- for (var e of Wt(t))
1873
- bn.call(t, e) && ze(n, e, t[e]);
1868
+ dr.call(t, e) && Sn(n, e, t[e]);
1869
+ if (he)
1870
+ for (var e of he(t))
1871
+ pr.call(t, e) && Sn(n, e, t[e]);
1874
1872
  return n;
1875
- }, wn = (n, t) => is(n, os(t)), as = (n, t) => {
1873
+ }, gr = (n, t) => ci(n, hi(t)), li = (n, t) => {
1876
1874
  var e = {};
1877
1875
  for (var r in n)
1878
- vn.call(n, r) && t.indexOf(r) < 0 && (e[r] = n[r]);
1879
- if (n != null && Wt)
1880
- for (var r of Wt(n))
1881
- t.indexOf(r) < 0 && bn.call(n, r) && (e[r] = n[r]);
1876
+ dr.call(n, r) && t.indexOf(r) < 0 && (e[r] = n[r]);
1877
+ if (n != null && he)
1878
+ for (var r of he(n))
1879
+ t.indexOf(r) < 0 && pr.call(n, r) && (e[r] = n[r]);
1882
1880
  return e;
1883
1881
  };
1884
- function On(n) {
1882
+ function fr(n) {
1885
1883
  if (n.__esModule)
1886
1884
  return n;
1887
1885
  var t = n.default;
@@ -1908,9 +1906,9 @@ function On(n) {
1908
1906
  });
1909
1907
  }), e;
1910
1908
  }
1911
- var En = function() {
1909
+ var mr = function() {
1912
1910
  };
1913
- process.env.NODE_ENV !== "production" && (En = function(n, t, e) {
1911
+ process.env.NODE_ENV !== "production" && (mr = function(n, t, e) {
1914
1912
  var r = arguments.length;
1915
1913
  e = new Array(r > 2 ? r - 2 : 0);
1916
1914
  for (var s = 2; s < r; s++)
@@ -1934,19 +1932,19 @@ process.env.NODE_ENV !== "production" && (En = function(n, t, e) {
1934
1932
  }
1935
1933
  }
1936
1934
  });
1937
- var cs = En, hs = cs, Fe = us(hs);
1938
- function us(n) {
1935
+ var ui = mr, di = ui, Pn = pi(di);
1936
+ function pi(n) {
1939
1937
  return n && n.__esModule ? n : { default: n };
1940
1938
  }
1941
- var ls = function() {
1939
+ var gi = function() {
1942
1940
  var n = null, t = function(o) {
1943
- return (0, Fe.default)(n == null, "A history supports only one prompt at a time"), n = o, function() {
1941
+ return (0, Pn.default)(n == null, "A history supports only one prompt at a time"), n = o, function() {
1944
1942
  n === o && (n = null);
1945
1943
  };
1946
1944
  }, e = function(o, a, c, h) {
1947
1945
  if (n != null) {
1948
- var u = typeof n == "function" ? n(o, a) : n;
1949
- typeof u == "string" ? typeof c == "function" ? c(u, h) : ((0, Fe.default)(!1, "A history needs a getUserConfirmation function in order to use a prompt message"), h(!0)) : h(u !== !1);
1946
+ var l = typeof n == "function" ? n(o, a) : n;
1947
+ typeof l == "string" ? typeof c == "function" ? c(l, h) : ((0, Pn.default)(!1, "A history needs a getUserConfirmation function in order to use a prompt message"), h(!0)) : h(l !== !1);
1950
1948
  } else
1951
1949
  h(!0);
1952
1950
  }, r = [], s = function(o) {
@@ -1971,21 +1969,21 @@ var ls = function() {
1971
1969
  appendListener: s,
1972
1970
  notifyListeners: i
1973
1971
  };
1974
- }, xn = ls, $n;
1975
- $n = function(n, t) {
1972
+ }, vr = gi, yr;
1973
+ yr = function(n, t) {
1976
1974
  return t(window.confirm(n));
1977
1975
  };
1978
- function At(n) {
1976
+ function qt(n) {
1979
1977
  return n.charAt(0) === "/";
1980
1978
  }
1981
- function oe(n, t) {
1979
+ function Ce(n, t) {
1982
1980
  for (var e = t, r = e + 1, s = n.length; r < s; e += 1, r += 1)
1983
1981
  n[e] = n[r];
1984
1982
  n.pop();
1985
1983
  }
1986
- function ds(n) {
1987
- var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", e = n && n.split("/") || [], r = t && t.split("/") || [], s = n && At(n), i = t && At(t), o = s || i;
1988
- if (n && At(n) ? r = e : e.length && (r.pop(), r = r.concat(e)), !r.length)
1984
+ function fi(n) {
1985
+ var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", e = n && n.split("/") || [], r = t && t.split("/") || [], s = n && qt(n), i = t && qt(t), o = s || i;
1986
+ if (n && qt(n) ? r = e : e.length && (r.pop(), r = r.concat(e)), !r.length)
1989
1987
  return "/";
1990
1988
  var a = void 0;
1991
1989
  if (r.length) {
@@ -1993,71 +1991,71 @@ function ds(n) {
1993
1991
  a = c === "." || c === ".." || c === "";
1994
1992
  } else
1995
1993
  a = !1;
1996
- for (var h = 0, u = r.length; u >= 0; u--) {
1997
- var l = r[u];
1998
- l === "." ? oe(r, u) : l === ".." ? (oe(r, u), h++) : h && (oe(r, u), h--);
1994
+ for (var h = 0, l = r.length; l >= 0; l--) {
1995
+ var u = r[l];
1996
+ u === "." ? Ce(r, l) : u === ".." ? (Ce(r, l), h++) : h && (Ce(r, l), h--);
1999
1997
  }
2000
1998
  if (!o)
2001
1999
  for (; h--; h)
2002
2000
  r.unshift("..");
2003
- o && r[0] !== "" && (!r[0] || !At(r[0])) && r.unshift("");
2001
+ o && r[0] !== "" && (!r[0] || !qt(r[0])) && r.unshift("");
2004
2002
  var d = r.join("/");
2005
2003
  return a && d.substr(-1) !== "/" && (d += "/"), d;
2006
2004
  }
2007
- const ps = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2005
+ const mi = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2008
2006
  __proto__: null,
2009
- default: ds
2010
- }, Symbol.toStringTag, { value: "Module" })), fs = /* @__PURE__ */ On(ps);
2011
- var Je = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
2007
+ default: fi
2008
+ }, Symbol.toStringTag, { value: "Module" })), vi = /* @__PURE__ */ fr(mi);
2009
+ var Cn = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(n) {
2012
2010
  return typeof n;
2013
2011
  } : function(n) {
2014
2012
  return n && typeof Symbol == "function" && n.constructor === Symbol && n !== Symbol.prototype ? "symbol" : typeof n;
2015
2013
  };
2016
- function _t(n, t) {
2014
+ function te(n, t) {
2017
2015
  if (n === t)
2018
2016
  return !0;
2019
2017
  if (n == null || t == null)
2020
2018
  return !1;
2021
2019
  if (Array.isArray(n))
2022
2020
  return Array.isArray(t) && n.length === t.length && n.every(function(c, h) {
2023
- return _t(c, t[h]);
2021
+ return te(c, t[h]);
2024
2022
  });
2025
- var e = typeof n == "undefined" ? "undefined" : Je(n), r = typeof t == "undefined" ? "undefined" : Je(t);
2023
+ var e = typeof n == "undefined" ? "undefined" : Cn(n), r = typeof t == "undefined" ? "undefined" : Cn(t);
2026
2024
  if (e !== r)
2027
2025
  return !1;
2028
2026
  if (e === "object") {
2029
2027
  var s = n.valueOf(), i = t.valueOf();
2030
2028
  if (s !== n || i !== t)
2031
- return _t(s, i);
2029
+ return te(s, i);
2032
2030
  var o = Object.keys(n), a = Object.keys(t);
2033
2031
  return o.length !== a.length ? !1 : o.every(function(c) {
2034
- return _t(n[c], t[c]);
2032
+ return te(n[c], t[c]);
2035
2033
  });
2036
2034
  }
2037
2035
  return !1;
2038
2036
  }
2039
- const gs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2037
+ const yi = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2040
2038
  __proto__: null,
2041
- default: _t
2042
- }, Symbol.toStringTag, { value: "Module" })), ms = /* @__PURE__ */ On(gs);
2043
- var tt = {}, rt, Pn, pe, xt;
2044
- tt.__esModule = !0;
2045
- xt = tt.addLeadingSlash = function(n) {
2039
+ default: te
2040
+ }, Symbol.toStringTag, { value: "Module" })), bi = /* @__PURE__ */ fr(yi);
2041
+ var nt = {}, ot, br, ze, Tt;
2042
+ nt.__esModule = !0;
2043
+ Tt = nt.addLeadingSlash = function(n) {
2046
2044
  return n.charAt(0) === "/" ? n : "/" + n;
2047
2045
  };
2048
- pe = tt.stripLeadingSlash = function(n) {
2046
+ ze = nt.stripLeadingSlash = function(n) {
2049
2047
  return n.charAt(0) === "/" ? n.substr(1) : n;
2050
2048
  };
2051
- var ys = tt.hasBasename = function(n, t) {
2049
+ var wi = nt.hasBasename = function(n, t) {
2052
2050
  return new RegExp("^" + t + "(\\/|\\?|#|$)", "i").test(n);
2053
2051
  };
2054
- tt.stripBasename = function(n, t) {
2055
- return ys(n, t) ? n.substr(t.length) : n;
2052
+ nt.stripBasename = function(n, t) {
2053
+ return wi(n, t) ? n.substr(t.length) : n;
2056
2054
  };
2057
- Pn = tt.stripTrailingSlash = function(n) {
2055
+ br = nt.stripTrailingSlash = function(n) {
2058
2056
  return n.charAt(n.length - 1) === "/" ? n.slice(0, -1) : n;
2059
2057
  };
2060
- tt.parsePath = function(n) {
2058
+ nt.parsePath = function(n) {
2061
2059
  var t = n || "/", e = "", r = "", s = t.indexOf("#");
2062
2060
  s !== -1 && (r = t.substr(s), t = t.substr(0, s));
2063
2061
  var i = t.indexOf("?");
@@ -2067,35 +2065,35 @@ tt.parsePath = function(n) {
2067
2065
  hash: r === "#" ? "" : r
2068
2066
  };
2069
2067
  };
2070
- rt = tt.createPath = function(n) {
2068
+ ot = nt.createPath = function(n) {
2071
2069
  var t = n.pathname, e = n.search, r = n.hash, s = t || "/";
2072
2070
  return e && e !== "?" && (s += e.charAt(0) === "?" ? e : "?" + e), r && r !== "#" && (s += r.charAt(0) === "#" ? r : "#" + r), s;
2073
2071
  };
2074
- var Qt, Sn = Qt = void 0, vs = Object.assign || function(n) {
2072
+ var be, wr = be = void 0, $i = Object.assign || function(n) {
2075
2073
  for (var t = 1; t < arguments.length; t++) {
2076
2074
  var e = arguments[t];
2077
2075
  for (var r in e)
2078
2076
  Object.prototype.hasOwnProperty.call(e, r) && (n[r] = e[r]);
2079
2077
  }
2080
2078
  return n;
2081
- }, bs = fs, ws = Cn(bs), Os = ms, Es = Cn(Os), xs = tt;
2082
- function Cn(n) {
2079
+ }, Oi = vi, Ei = $r(Oi), Ai = bi, xi = $r(Ai), _i = nt;
2080
+ function $r(n) {
2083
2081
  return n && n.__esModule ? n : { default: n };
2084
2082
  }
2085
- Qt = function(n, t, e, r) {
2083
+ be = function(n, t, e, r) {
2086
2084
  var s = void 0;
2087
- typeof n == "string" ? (s = (0, xs.parsePath)(n), s.state = t) : (s = vs({}, n), s.pathname === void 0 && (s.pathname = ""), s.search ? s.search.charAt(0) !== "?" && (s.search = "?" + s.search) : s.search = "", s.hash ? s.hash.charAt(0) !== "#" && (s.hash = "#" + s.hash) : s.hash = "", t !== void 0 && s.state === void 0 && (s.state = t));
2085
+ typeof n == "string" ? (s = (0, _i.parsePath)(n), s.state = t) : (s = $i({}, n), s.pathname === void 0 && (s.pathname = ""), s.search ? s.search.charAt(0) !== "?" && (s.search = "?" + s.search) : s.search = "", s.hash ? s.hash.charAt(0) !== "#" && (s.hash = "#" + s.hash) : s.hash = "", t !== void 0 && s.state === void 0 && (s.state = t));
2088
2086
  try {
2089
2087
  s.pathname = decodeURI(s.pathname);
2090
2088
  } catch (i) {
2091
2089
  throw i instanceof URIError ? new URIError('Pathname "' + s.pathname + '" could not be decoded. This is likely caused by an invalid percent-encoding.') : i;
2092
2090
  }
2093
- return e && (s.key = e), r ? s.pathname ? s.pathname.charAt(0) !== "/" && (s.pathname = (0, ws.default)(s.pathname, r.pathname)) : s.pathname = r.pathname : s.pathname || (s.pathname = "/"), s;
2091
+ return e && (s.key = e), r ? s.pathname ? s.pathname.charAt(0) !== "/" && (s.pathname = (0, Ei.default)(s.pathname, r.pathname)) : s.pathname = r.pathname : s.pathname || (s.pathname = "/"), s;
2094
2092
  };
2095
- Sn = function(n, t) {
2096
- return n.pathname === t.pathname && n.search === t.search && n.hash === t.hash && n.key === t.key && (0, Es.default)(n.state, t.state);
2093
+ wr = function(n, t) {
2094
+ return n.pathname === t.pathname && n.search === t.search && n.hash === t.hash && n.key === t.key && (0, xi.default)(n.state, t.state);
2097
2095
  };
2098
- const kn = "/", An = "./", $s = new RegExp(
2096
+ const Or = "/", Er = "./", Si = new RegExp(
2099
2097
  [
2100
2098
  // Match escaped characters that would otherwise appear in future matches.
2101
2099
  // This allows the user to escape special characters that won't transform.
@@ -2108,38 +2106,38 @@ const kn = "/", An = "./", $s = new RegExp(
2108
2106
  "(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?"
2109
2107
  ].join("|"),
2110
2108
  "g"
2111
- ), Nn = (n, t) => {
2109
+ ), Ar = (n, t) => {
2112
2110
  const e = [];
2113
2111
  let r = 0, s = 0, i = "";
2114
- const o = t && t.delimiter || kn, a = t && t.delimiters || An;
2112
+ const o = t && t.delimiter || Or, a = t && t.delimiters || Er;
2115
2113
  let c = !1, h;
2116
- for (; (h = $s.exec(n)) !== null; ) {
2117
- const u = h[0], l = h[1], d = h.index;
2118
- if (i += n.slice(s, d), s = d + u.length, l) {
2119
- i += l[1], c = !0;
2114
+ for (; (h = Si.exec(n)) !== null; ) {
2115
+ const l = h[0], u = h[1], d = h.index;
2116
+ if (i += n.slice(s, d), s = d + l.length, u) {
2117
+ i += u[1], c = !0;
2120
2118
  continue;
2121
2119
  }
2122
- let f = "";
2123
- const g = n[s], E = h[2], p = h[3], C = h[4], T = h[5];
2120
+ let p = "";
2121
+ const b = n[s], v = h[2], g = h[3], E = h[4], j = h[5];
2124
2122
  if (!c && i.length) {
2125
2123
  const N = i.length - 1;
2126
- a.indexOf(i[N]) > -1 && (f = i[N], i = i.slice(0, N));
2124
+ a.indexOf(i[N]) > -1 && (p = i[N], i = i.slice(0, N));
2127
2125
  }
2128
2126
  i && (e.push(i), i = "", c = !1);
2129
- const U = f !== "" && g !== void 0 && g !== f, _ = T === "+" || T === "*", D = T === "?" || T === "*", H = f || o, x = p || C;
2127
+ const z = p !== "" && b !== void 0 && b !== p, H = j === "+" || j === "*", k = j === "?" || j === "*", U = p || o, A = g || E;
2130
2128
  e.push({
2131
- delimiter: H,
2132
- optional: D,
2133
- repeat: _,
2134
- partial: U,
2135
- name: E || r++,
2129
+ delimiter: U,
2130
+ optional: k,
2131
+ repeat: H,
2132
+ partial: z,
2133
+ name: v || r++,
2136
2134
  // tslint:disable-line:no-increment-decrement
2137
- prefix: f,
2138
- pattern: x ? Cs(x) : "[^" + wt(H) + "]+?"
2135
+ prefix: p,
2136
+ pattern: A ? ki(A) : "[^" + Mt(U) + "]+?"
2139
2137
  });
2140
2138
  }
2141
2139
  return (i || s < n.length) && e.push(i + n.substr(s)), e;
2142
- }, Ps = (n, t) => Ss(Nn(n, t)), Ss = (n) => {
2140
+ }, Pi = (n, t) => Ci(Ar(n, t)), Ci = (n) => {
2143
2141
  const t = new Array(n.length);
2144
2142
  for (let e = 0; e < n.length; e++)
2145
2143
  typeof n[e] == "object" && (t[e] = new RegExp("^(?:" + n[e].pattern + ")$"));
@@ -2164,12 +2162,12 @@ const kn = "/", An = "./", $s = new RegExp(
2164
2162
  continue;
2165
2163
  throw new TypeError('Expected "' + a.name + '" to not be empty');
2166
2164
  }
2167
- for (let u = 0; u < c.length; u++) {
2168
- if (h = i(c[u], a), !t[o].test(h))
2165
+ for (let l = 0; l < c.length; l++) {
2166
+ if (h = i(c[l], a), !t[o].test(h))
2169
2167
  throw new TypeError(
2170
2168
  'Expected all "' + a.name + '" to match "' + a.pattern + '"'
2171
2169
  );
2172
- s += (u === 0 ? a.prefix : a.delimiter) + h;
2170
+ s += (l === 0 ? a.prefix : a.delimiter) + h;
2173
2171
  }
2174
2172
  continue;
2175
2173
  }
@@ -2191,7 +2189,7 @@ const kn = "/", An = "./", $s = new RegExp(
2191
2189
  }
2192
2190
  return s;
2193
2191
  };
2194
- }, wt = (n) => n.replace(/([.+*?=^!:${}()[\]|/\\])/g, "\\$1"), Cs = (n) => n.replace(/([=!:$/()])/g, "\\$1"), Ln = (n) => n && n.sensitive ? "" : "i", ks = (n, t) => {
2192
+ }, Mt = (n) => n.replace(/([.+*?=^!:${}()[\]|/\\])/g, "\\$1"), ki = (n) => n.replace(/([=!:$/()])/g, "\\$1"), xr = (n) => n && n.sensitive ? "" : "i", Ni = (n, t) => {
2195
2193
  if (!t)
2196
2194
  return n;
2197
2195
  const e = n.source.match(/\((?!\?)/g);
@@ -2207,56 +2205,56 @@ const kn = "/", An = "./", $s = new RegExp(
2207
2205
  pattern: ""
2208
2206
  });
2209
2207
  return n;
2210
- }, As = (n, t, e) => {
2208
+ }, Mi = (n, t, e) => {
2211
2209
  const r = [];
2212
2210
  for (let s = 0; s < n.length; s++)
2213
- r.push(Mn(n[s], t, e).source);
2214
- return new RegExp("(?:" + r.join("|") + ")", Ln(e));
2215
- }, Ns = (n, t, e) => Ls(Nn(n, e), t, e), Ls = (n, t, e) => {
2211
+ r.push(_r(n[s], t, e).source);
2212
+ return new RegExp("(?:" + r.join("|") + ")", xr(e));
2213
+ }, Li = (n, t, e) => Di(Ar(n, e), t, e), Di = (n, t, e) => {
2216
2214
  e = e || {};
2217
- const r = e.strict, s = e.end !== !1, i = wt(e.delimiter || kn), o = e.delimiters || An, a = [].concat(e.endsWith || []).map(wt).concat("$").join("|");
2215
+ const r = e.strict, s = e.end !== !1, i = Mt(e.delimiter || Or), o = e.delimiters || Er, a = [].concat(e.endsWith || []).map(Mt).concat("$").join("|");
2218
2216
  let c = "", h = !1;
2219
- for (let u = 0; u < n.length; u++) {
2220
- const l = n[u];
2221
- if (typeof l == "string")
2222
- c += wt(l), h = u === n.length - 1 && o.indexOf(l[l.length - 1]) > -1;
2217
+ for (let l = 0; l < n.length; l++) {
2218
+ const u = n[l];
2219
+ if (typeof u == "string")
2220
+ c += Mt(u), h = l === n.length - 1 && o.indexOf(u[u.length - 1]) > -1;
2223
2221
  else {
2224
- const d = wt(l.prefix), f = l.repeat ? "(?:" + l.pattern + ")(?:" + d + "(?:" + l.pattern + "))*" : l.pattern;
2225
- t && t.push(l), l.optional ? l.partial ? c += d + "(" + f + ")?" : c += "(?:" + d + "(" + f + "))?" : c += d + "(" + f + ")";
2222
+ const d = Mt(u.prefix), p = u.repeat ? "(?:" + u.pattern + ")(?:" + d + "(?:" + u.pattern + "))*" : u.pattern;
2223
+ t && t.push(u), u.optional ? u.partial ? c += d + "(" + p + ")?" : c += "(?:" + d + "(" + p + "))?" : c += d + "(" + p + ")";
2226
2224
  }
2227
2225
  }
2228
- return s ? (r || (c += "(?:" + i + ")?"), c += a === "$" ? "$" : "(?=" + a + ")") : (r || (c += "(?:" + i + "(?=" + a + "))?"), h || (c += "(?=" + i + "|" + a + ")")), new RegExp("^" + c, Ln(e));
2229
- }, Mn = (n, t, e) => n instanceof RegExp ? ks(n, t || []) : Array.isArray(n) ? As(n, t, e) : Ns(n, t, e), zt = Mn;
2230
- var K = /* @__PURE__ */ ((n) => (n.scopedHash = "scopedHash", n.hash = "hash", n.browser = "browser", n.memory = "memory", n))(K || {}), ot = /* @__PURE__ */ ((n) => (n.storage = "storage", n.path = "path", n.initialPath = "initial", n))(ot || {});
2231
- const Ot = (n, t) => {
2232
- const e = [], r = zt(t, e).exec(n);
2226
+ return s ? (r || (c += "(?:" + i + ")?"), c += a === "$" ? "$" : "(?=" + a + ")") : (r || (c += "(?:" + i + "(?=" + a + "))?"), h || (c += "(?=" + i + "|" + a + ")")), new RegExp("^" + c, xr(e));
2227
+ }, _r = (n, t, e) => n instanceof RegExp ? Ni(n, t || []) : Array.isArray(n) ? Mi(n, t, e) : Li(n, t, e), le = _r;
2228
+ var K = /* @__PURE__ */ ((n) => (n.scopedHash = "scopedHash", n.hash = "hash", n.browser = "browser", n.memory = "memory", n))(K || {}), dt = /* @__PURE__ */ ((n) => (n.storage = "storage", n.path = "path", n.initialPath = "initial", n))(dt || {});
2229
+ const Lt = (n, t) => {
2230
+ const e = [], r = le(t, e).exec(n);
2233
2231
  if (!r)
2234
2232
  return {};
2235
2233
  const [s, ...i] = r;
2236
2234
  return e.reduce((o, a, c) => (o[a.name] = i[c], o), {});
2237
- }, Ms = (n) => Object.keys(n).reduce((t, e) => {
2235
+ }, Ti = (n) => Object.keys(n).reduce((t, e) => {
2238
2236
  const r = typeof n[e] == "string" ? n[e].replace("&", "%20") : n[e];
2239
2237
  let s = `${e}=${r}`;
2240
2238
  return t.length > 1 && (s = "&".concat(s)), t.concat(s);
2241
- }, "?"), ae = (n, t) => {
2239
+ }, "?"), ke = (n, t) => {
2242
2240
  const e = t.find((r) => r.name === n);
2243
2241
  if (!e) {
2244
- process.env.NODE_ENV !== "production" && R.warn(`Unable to find route with specified name: ${n}`);
2242
+ process.env.NODE_ENV !== "production" && I.warn(`Unable to find route with specified name: ${n}`);
2245
2243
  return;
2246
2244
  }
2247
2245
  return e;
2248
- }, Dn = (n) => n.length ? n.slice(1).split("&").map((t) => t.split("=")).reduce((t, e) => {
2246
+ }, Sr = (n) => n.length ? n.slice(1).split("&").map((t) => t.split("=")).reduce((t, e) => {
2249
2247
  const [r, s] = e.map(encodeURI).map(decodeURIComponent);
2250
- return wn(gt({}, t), { [r]: decodeURIComponent(s).replace("%20", "&") });
2251
- }, {}) : {}, Ds = (n, t) => {
2252
- const e = t.map((r) => It(n, r)).reduce(
2248
+ return gr(Et({}, t), { [r]: decodeURIComponent(s).replace("%20", "&") });
2249
+ }, {}) : {}, ji = (n, t) => {
2250
+ const e = t.map((r) => ee(n, r)).reduce(
2253
2251
  (r, s) => {
2254
2252
  if (s === null)
2255
2253
  return r;
2256
2254
  const i = s.split("?")[1];
2257
2255
  let o = 0;
2258
2256
  if (i) {
2259
- const a = Dn(`?${i}`);
2257
+ const a = Sr(`?${i}`);
2260
2258
  o = Object.keys(a).length;
2261
2259
  }
2262
2260
  return !r.path || r.count && o < r.count ? {
@@ -2267,15 +2265,15 @@ const Ot = (n, t) => {
2267
2265
  { count: void 0, path: void 0 }
2268
2266
  );
2269
2267
  return e ? e.path : t[0];
2270
- }, It = (n, t) => {
2271
- const e = lt(n);
2268
+ }, ee = (n, t) => {
2269
+ const e = yt(n);
2272
2270
  if (Array.isArray(t)) {
2273
- const c = Ds(e, t);
2271
+ const c = ji(e, t);
2274
2272
  if (!c)
2275
2273
  throw new Error("Unable to match path.");
2276
2274
  return c;
2277
2275
  }
2278
- const r = Ps(t);
2276
+ const r = Pi(t);
2279
2277
  let s = t;
2280
2278
  try {
2281
2279
  s = r(e);
@@ -2283,28 +2281,28 @@ const Ot = (n, t) => {
2283
2281
  return null;
2284
2282
  }
2285
2283
  const i = [];
2286
- zt(t, i);
2287
- const o = Object.keys(e).reduce((c, h) => (i.find((u) => u.name === h) || c.push(h), c), []), a = {};
2288
- return o.forEach((c) => a[c] = e[c]), Object.keys(a).forEach((c) => a[c] === null && delete a[c]), Object.keys(a).length > 0 ? `${s}${Ms(a)}` : s;
2289
- }, ft = (n, t) => {
2284
+ le(t, i);
2285
+ const o = Object.keys(e).reduce((c, h) => (i.find((l) => l.name === h) || c.push(h), c), []), a = {};
2286
+ return o.forEach((c) => a[c] = e[c]), Object.keys(a).forEach((c) => a[c] === null && delete a[c]), Object.keys(a).length > 0 ? `${s}${Ti(a)}` : s;
2287
+ }, Ot = (n, t) => {
2290
2288
  let e = n;
2291
2289
  return e.indexOf("?") > -1 && (e = e.substring(0, e.indexOf("?"))), e.indexOf(";") > -1 && (e = e.substring(0, e.indexOf(";"))), e === "" && (e = "/"), t.reduce((r, s) => {
2292
2290
  if (Array.isArray(s.path))
2293
- return s.path.reduce((o, a) => zt(a, []).exec(e || "") && !o ? e : o, void 0) && !r ? s : r;
2291
+ return s.path.reduce((o, a) => le(a, []).exec(e || "") && !o ? e : o, void 0) && !r ? s : r;
2294
2292
  if (!s.path)
2295
2293
  return r;
2296
2294
  const i = [];
2297
- return zt(s.path, i).exec(e || "") && !r ? s : r;
2295
+ return le(s.path, i).exec(e || "") && !r ? s : r;
2298
2296
  }, void 0);
2299
- }, js = (n) => {
2297
+ }, Ri = (n) => {
2300
2298
  let t = n.get("historyTransitionManager");
2301
- return t || (t = xn(), n.parent && n.parent.register("historyTransitionManager", t)), t;
2302
- }, Et = (n, t = null) => n ? Qt(t ? t(n) : n) : {
2299
+ return t || (t = vr(), n.parent && n.parent.register("historyTransitionManager", t)), t;
2300
+ }, Dt = (n, t = null) => n ? be(t ? t(n) : n) : {
2303
2301
  pathname: "",
2304
2302
  search: "",
2305
2303
  hash: ""
2306
- }, _s = (n, t) => {
2307
- if (lt(n), lt(t), Object.keys(n).length !== Object.keys(t).length)
2304
+ }, Ii = (n, t) => {
2305
+ if (yt(n), yt(t), Object.keys(n).length !== Object.keys(t).length)
2308
2306
  return !1;
2309
2307
  if (Object.keys(n).length === 0 && Object.keys(t).length === 0)
2310
2308
  return !0;
@@ -2312,7 +2310,7 @@ const Ot = (n, t) => {
2312
2310
  return Object.keys(t).forEach((r) => {
2313
2311
  t[r] !== n[r] && (e = !1);
2314
2312
  }), e;
2315
- }, Is = (n) => {
2313
+ }, Hi = (n) => {
2316
2314
  if (typeof n.mode == "string") {
2317
2315
  if (n.mode === K.memory)
2318
2316
  return !0;
@@ -2322,34 +2320,34 @@ const Ot = (n, t) => {
2322
2320
  return typeof e == "undefined" ? !0 : e;
2323
2321
  }
2324
2322
  return !1;
2325
- }, ce = (n) => {
2323
+ }, Ne = (n) => {
2326
2324
  const { views: t } = n.get("$settings"), e = Object.keys(t).reduce((r, s) => typeof t[s].path == "undefined" ? s : r, void 0);
2327
2325
  return e ? {
2328
2326
  name: e,
2329
2327
  params: {}
2330
2328
  } : null;
2331
- }, Ke = "hashchange", Rs = {
2329
+ }, kn = "hashchange", Ui = {
2332
2330
  hashbang: {
2333
- encodePath: (n) => n.charAt(0) === "!" ? n : "!/" + pe(n),
2331
+ encodePath: (n) => n.charAt(0) === "!" ? n : "!/" + ze(n),
2334
2332
  decodePath: (n) => n.charAt(0) === "!" ? n.substr(1) : n
2335
2333
  },
2336
2334
  noslash: {
2337
- encodePath: pe,
2338
- decodePath: xt
2335
+ encodePath: ze,
2336
+ decodePath: Tt
2339
2337
  },
2340
2338
  slash: {
2341
- encodePath: xt,
2342
- decodePath: xt
2339
+ encodePath: Tt,
2340
+ decodePath: Tt
2343
2341
  }
2344
- }, st = () => {
2342
+ }, at = () => {
2345
2343
  const n = window.location.href, t = n.indexOf("#");
2346
2344
  return t === -1 ? "" : n.substring(t + 1);
2347
- }, qe = (n) => window.location.hash = n, Ye = (n) => {
2345
+ }, Nn = (n) => window.location.hash = n, Mn = (n) => {
2348
2346
  const t = window.location.href.indexOf("#");
2349
2347
  window.location.replace(
2350
2348
  window.location.href.slice(0, t >= 0 ? t : 0) + "#" + n
2351
2349
  );
2352
- }, Rt = (n = "") => {
2350
+ }, ne = (n = "") => {
2353
2351
  const t = n.replace(";", "?"), e = [
2354
2352
  { from: /\;+/gi, to: "&" },
2355
2353
  { from: /:+/gi, to: "=" }
@@ -2358,145 +2356,145 @@ const Ot = (n, t) => {
2358
2356
  return e.forEach(({ to: s, from: i }) => {
2359
2357
  r = r.replace(i, s);
2360
2358
  }), r;
2361
- }, Ts = (n = {}) => {
2362
- const t = window.history, { getUserConfirmation: e = $n, hashType: r = "slash" } = n, s = n.basename ? Pn(xt(n.basename)) : "", { encodePath: i } = Rs[r], o = () => {
2363
- const m = st(), b = u(m);
2364
- return Et(b, Rt);
2365
- }, a = n.transitionManager || xn(), c = (m) => {
2366
- Object.assign(I, m), I.length = t.length, a.notifyListeners(I.location, I.action, n.widgetName);
2359
+ }, Bi = (n = {}) => {
2360
+ const t = window.history, { getUserConfirmation: e = yr, hashType: r = "slash" } = n, s = n.basename ? br(Tt(n.basename)) : "", { encodePath: i } = Ui[r], o = () => {
2361
+ const f = at(), w = l(f);
2362
+ return Dt(w, ne);
2363
+ }, a = n.transitionManager || vr(), c = (f) => {
2364
+ Object.assign(R, f), R.length = t.length, a.notifyListeners(R.location, R.action, n.widgetName);
2367
2365
  };
2368
2366
  let h = !1;
2369
- const u = (m) => {
2370
- const b = (w) => {
2371
- function P($, y) {
2367
+ const l = (f) => {
2368
+ const w = ($) => {
2369
+ function _(x, m) {
2372
2370
  const O = {};
2373
- let L;
2374
- for (; L = y.exec($); )
2375
- O[L[1]] = L[2];
2371
+ let M;
2372
+ for (; M = m.exec(x); )
2373
+ O[M[1]] = M[2];
2376
2374
  return O;
2377
2375
  }
2378
- return P(w, /([^#?&=]+)=([^&#]*)(?!.*?\#)/gi) || null;
2379
- }, v = "humany-" + n.widgetName;
2380
- return b(m)[v];
2381
- }, l = () => {
2382
- const m = o(), b = I.location;
2383
- !h && Sn(b, m) || d(m);
2384
- }, d = (m) => {
2376
+ return _($, /([^#?&=]+)=([^&#]*)(?!.*?\#)/gi) || null;
2377
+ }, y = "humany-" + n.widgetName;
2378
+ return w(f)[y];
2379
+ }, u = () => {
2380
+ const f = o(), w = R.location;
2381
+ !h && wr(w, f) || d(f);
2382
+ }, d = (f) => {
2385
2383
  if (h)
2386
2384
  h = !1, c();
2387
2385
  else {
2388
- const b = "POP";
2386
+ const w = "POP";
2389
2387
  a.confirmTransitionTo(
2390
- m,
2391
- b,
2388
+ f,
2389
+ w,
2392
2390
  e,
2393
- (v) => {
2394
- v ? c({ action: b, location: m }) : f(m);
2391
+ (y) => {
2392
+ y ? c({ action: w, location: f }) : p(f);
2395
2393
  }
2396
2394
  );
2397
2395
  }
2398
- }, f = (m) => {
2399
- const b = I.location;
2400
- let v = p.lastIndexOf(rt(b));
2401
- v === -1 && (v = 0);
2402
- let w = p.lastIndexOf(rt(m));
2403
- w === -1 && (w = 0);
2404
- const P = v - w;
2405
- P && (h = !0, x(P));
2406
- }, g = st(), E = i(g);
2407
- g !== E && Ye(E);
2408
- let p = [];
2409
- const C = o();
2410
- C.pathname !== null && p.push(rt(C));
2411
- const T = (m = "") => {
2412
- const b = [
2396
+ }, p = (f) => {
2397
+ const w = R.location;
2398
+ let y = g.lastIndexOf(ot(w));
2399
+ y === -1 && (y = 0);
2400
+ let $ = g.lastIndexOf(ot(f));
2401
+ $ === -1 && ($ = 0);
2402
+ const _ = y - $;
2403
+ _ && (h = !0, A(_));
2404
+ }, b = at(), v = i(b);
2405
+ b !== v && Mn(v);
2406
+ let g = [];
2407
+ const E = o();
2408
+ E.pathname !== null && g.push(ot(E));
2409
+ const j = (f = "") => {
2410
+ const w = [
2413
2411
  { from: /\?+/gi, to: ";" },
2414
2412
  { from: /\&amp;+/gi, to: ";" },
2415
2413
  { from: /\&+/gi, to: ";" },
2416
2414
  { from: /=+/gi, to: ":" }
2417
2415
  ];
2418
- let v = m;
2419
- return b.forEach(({ to: w, from: P }) => {
2420
- v = v.replace(P, w);
2421
- }), v;
2422
- }, U = (m, b, v) => {
2423
- let w = "", P = !1;
2424
- return m.split("&").forEach(($) => {
2425
- const y = $.split("="), O = y[0], L = y[1];
2426
- if (O === b) {
2427
- if (P = !0, v === null)
2416
+ let y = f;
2417
+ return w.forEach(({ to: $, from: _ }) => {
2418
+ y = y.replace(_, $);
2419
+ }), y;
2420
+ }, z = (f, w, y) => {
2421
+ let $ = "", _ = !1;
2422
+ return f.split("&").forEach((x) => {
2423
+ const m = x.split("="), O = m[0], M = m[1];
2424
+ if (O === w) {
2425
+ if (_ = !0, y === null)
2428
2426
  return;
2429
- w.length > 0 && (w += "&"), typeof v != "undefined" ? w += O + "=" + v : w += O;
2427
+ $.length > 0 && ($ += "&"), typeof y != "undefined" ? $ += O + "=" + y : $ += O;
2430
2428
  } else
2431
- O && (w.length > 0 && (w += "&"), w += O + "=" + L);
2432
- }), !P && v !== null && (w.length > 0 && (w += "&"), typeof v != "undefined" ? w += b + "=" + v : w += b), w;
2433
- }, _ = (m) => {
2434
- const b = m.pathname, v = T(m.search), w = b + (v ? `;${v}` : ""), P = `humany-${n.widgetName}`, $ = st();
2435
- return `#${U($, P, w).replace(";;", ";")}`;
2436
- }, D = (m, b) => {
2437
- const v = "PUSH", w = Et(m, Rt), P = w.pathname, $ = T(w.search), y = P + ($ ? `${$}` : ""), O = `humany-${n.widgetName}`, L = st(), M = U(L, O, y);
2438
- a.confirmTransitionTo(w, v, e, (F) => {
2439
- if (!F)
2429
+ O && ($.length > 0 && ($ += "&"), $ += O + "=" + M);
2430
+ }), !_ && y !== null && ($.length > 0 && ($ += "&"), typeof y != "undefined" ? $ += w + "=" + y : $ += w), $;
2431
+ }, H = (f) => {
2432
+ const w = f.pathname, y = j(f.search), $ = w + (y ? `;${y}` : ""), _ = `humany-${n.widgetName}`, x = at();
2433
+ return `#${z(x, _, $).replace(";;", ";")}`;
2434
+ }, k = (f, w) => {
2435
+ const y = "PUSH", $ = Dt(f, ne), _ = $.pathname, x = j($.search), m = _ + (x ? `${x}` : ""), O = `humany-${n.widgetName}`, M = at(), L = z(M, O, m);
2436
+ a.confirmTransitionTo($, y, e, (J) => {
2437
+ if (!J)
2440
2438
  return;
2441
- const J = rt(w), et = i(M);
2442
- if (st() !== et) {
2443
- qe(et);
2444
- const Y = p.lastIndexOf(rt(I.location)), W = p.slice(0, Y === -1 ? 0 : Y + 1);
2445
- W.push(J), p = W, c({ action: v, location: w });
2439
+ const q = ot($), rt = i(L);
2440
+ if (at() !== rt) {
2441
+ Nn(rt);
2442
+ const G = g.lastIndexOf(ot(R.location)), W = g.slice(0, G === -1 ? 0 : G + 1);
2443
+ W.push(q), g = W, c({ action: y, location: $ });
2446
2444
  } else
2447
2445
  c();
2448
2446
  });
2449
- }, H = (m, b) => {
2450
- const v = "REPLACE", w = Et(m, Rt);
2451
- a.confirmTransitionTo(w, v, e, (P) => {
2452
- if (!P)
2447
+ }, U = (f, w) => {
2448
+ const y = "REPLACE", $ = Dt(f, ne);
2449
+ a.confirmTransitionTo($, y, e, (_) => {
2450
+ if (!_)
2453
2451
  return;
2454
- const $ = rt(w), y = i(s + $);
2455
- st() !== y && Ye(y);
2456
- const O = p.indexOf(rt(I.location));
2457
- O !== -1 && (p[O] = $), c({ action: v, location: w });
2452
+ const x = ot($), m = i(s + x);
2453
+ at() !== m && Mn(m);
2454
+ const O = g.indexOf(ot(R.location));
2455
+ O !== -1 && (g[O] = x), c({ action: y, location: $ });
2458
2456
  });
2459
- }, x = (m) => {
2460
- t.go(m);
2461
- }, N = () => x(-1), A = () => x(1);
2462
- let j = 0;
2463
- const B = (m) => {
2464
- j += m, j === 1 ? window.addEventListener(Ke, l) : j === 0 && window.removeEventListener(Ke, l);
2457
+ }, A = (f) => {
2458
+ t.go(f);
2459
+ }, N = () => A(-1), C = () => A(1);
2460
+ let D = 0;
2461
+ const V = (f) => {
2462
+ D += f, D === 1 ? window.addEventListener(kn, u) : D === 0 && window.removeEventListener(kn, u);
2465
2463
  };
2466
- let V = !1;
2467
- const I = {
2468
- createHref: _,
2469
- createLocation: Et,
2470
- push: D,
2471
- replace: H,
2472
- go: x,
2464
+ let B = !1;
2465
+ const R = {
2466
+ createHref: H,
2467
+ createLocation: Dt,
2468
+ push: k,
2469
+ replace: U,
2470
+ go: A,
2473
2471
  goBack: N,
2474
- goForward: A,
2475
- block: (m = !1) => {
2476
- const b = a.setPrompt(m);
2477
- return V || (B(1), V = !0), () => (V && (V = !1, B(-1)), b());
2472
+ goForward: C,
2473
+ block: (f = !1) => {
2474
+ const w = a.setPrompt(f);
2475
+ return B || (V(1), B = !0), () => (B && (B = !1, V(-1)), w());
2478
2476
  },
2479
- listen: (m) => {
2480
- const b = a.appendListener(m);
2481
- return B(1), () => {
2482
- B(-1), b();
2477
+ listen: (f) => {
2478
+ const w = a.appendListener(f);
2479
+ return V(1), () => {
2480
+ V(-1), w();
2483
2481
  };
2484
2482
  },
2485
2483
  stop: () => {
2486
- const m = st(), b = U(m, `humany-${n.widgetName}`, null), v = i(b);
2487
- qe(v);
2484
+ const f = at(), w = z(f, `humany-${n.widgetName}`, null), y = i(w);
2485
+ Nn(y);
2488
2486
  },
2489
2487
  length: t.length,
2490
2488
  action: "POP",
2491
- location: C
2489
+ location: E
2492
2490
  };
2493
- return I;
2494
- }, jn = Ts, Hs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2491
+ return R;
2492
+ }, Pr = Bi, Vi = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2495
2493
  __proto__: null,
2496
- decodeSearch: Rt,
2497
- default: jn,
2498
- getHashPath: st
2499
- }, Symbol.toStringTag, { value: "Module" })), Vs = (n, t) => {
2494
+ decodeSearch: ne,
2495
+ default: Pr,
2496
+ getHashPath: at
2497
+ }, Symbol.toStringTag, { value: "Module" })), zi = (n, t) => {
2500
2498
  const e = (s) => {
2501
2499
  function i(o, a) {
2502
2500
  const c = {};
@@ -2508,10 +2506,10 @@ const Ot = (n, t) => {
2508
2506
  return i(s, /([^#?&=]+)=([^&#]*)(?!.*?\#)/gi) || null;
2509
2507
  }, r = `humany-${t}`;
2510
2508
  return e(n)[r];
2511
- }, Bs = () => {
2509
+ }, Wi = () => {
2512
2510
  const n = window.location.href, t = n.indexOf("#");
2513
2511
  return t === -1 ? "" : n.substring(t + 1);
2514
- }, Us = (n = "") => {
2512
+ }, Fi = (n = "") => {
2515
2513
  const t = n.replace(";", "?"), e = [
2516
2514
  { from: /\;+/gi, to: "&" },
2517
2515
  { from: /:+/gi, to: "=" }
@@ -2520,18 +2518,18 @@ const Ot = (n, t) => {
2520
2518
  return e.forEach(({ to: s, from: i }) => {
2521
2519
  r = r.replace(i, s);
2522
2520
  }), r;
2523
- }, Ws = (n, t = null) => n ? Qt(t ? t(n) : n) : {
2521
+ }, Ji = (n, t = null) => n ? be(t ? t(n) : n) : {
2524
2522
  pathname: "",
2525
2523
  search: "",
2526
2524
  hash: ""
2527
- }, _n = (n) => {
2528
- const t = Bs(), e = Vs(t, n);
2529
- return Ws(e, Us);
2530
- }, we = (n) => {
2525
+ }, Cr = (n) => {
2526
+ const t = Wi(), e = zi(t, n);
2527
+ return Ji(e, Fi);
2528
+ }, Xe = (n) => {
2531
2529
  const { name: t } = n.get("$widget");
2532
- return !!_n(t).pathname;
2530
+ return !!Cr(t).pathname;
2533
2531
  };
2534
- fe((n) => {
2532
+ qe((n) => {
2535
2533
  n.createCommand("routing", (t) => (e) => {
2536
2534
  const r = {
2537
2535
  mode: e.mode
@@ -2539,13 +2537,13 @@ fe((n) => {
2539
2537
  e.basePath && (r.basePath = e.basePath), t.container.register("routingSettings", r);
2540
2538
  });
2541
2539
  });
2542
- const Ge = "routeData";
2543
- class zs {
2540
+ const Ln = "routeData";
2541
+ class qi {
2544
2542
  constructor(t, e) {
2545
2543
  this.container = t, this.steps = [], this.historyListenSubscription = () => {
2546
2544
  }, this.sticky = !1, this.storageWriter = null, this.widget = t.get("$widget");
2547
- const r = e, { routes: s } = r, i = as(r, ["routes"]);
2548
- this.settings = gt(gt({}, i), t.get("routingSettings")), this.sticky = Is(this.settings), this.storageMedium = this.sticky ? S.Local : S.Session, X(t, Ge, k.Necessary, {
2545
+ const r = e, { routes: s } = r, i = li(r, ["routes"]);
2546
+ this.settings = Et(Et({}, i), t.get("routingSettings")), this.sticky = Hi(this.settings), this.storageMedium = this.sticky ? S.Local : S.Session, et(t, Ln, P.Necessary, {
2549
2547
  medium: this.storageMedium
2550
2548
  }).then((o) => this.storageWriter = o), this.routes = s;
2551
2549
  }
@@ -2561,7 +2559,7 @@ class zs {
2561
2559
  const e = this.getRouteData(), r = {
2562
2560
  routeData: e,
2563
2561
  location: this.location
2564
- }, s = this.steps[0], i = e.name === (s == null ? void 0 : s.routeData.name), o = Ae(
2562
+ }, s = this.steps[0], i = e.name === (s == null ? void 0 : s.routeData.name), o = dn(
2565
2563
  e.params,
2566
2564
  (s == null ? void 0 : s.routeData.params) || {}
2567
2565
  );
@@ -2580,13 +2578,13 @@ class zs {
2580
2578
  * @param params Optional: route params
2581
2579
  */
2582
2580
  generate(t, e = {}) {
2583
- const r = ae(t, this.routes);
2581
+ const r = ke(t, this.routes);
2584
2582
  if (!r || !this.history)
2585
2583
  throw `No route found for ${t}`;
2586
- const s = It(e, r.path);
2584
+ const s = ee(e, r.path);
2587
2585
  if (!s)
2588
2586
  throw `Unable to generate path for "${t}".`;
2589
- const i = Et(s, this.settings.decodeSearch);
2587
+ const i = Dt(s, this.settings.decodeSearch);
2590
2588
  let o = this.history.createHref(i);
2591
2589
  const { mode: a, basePath: c } = this.settings;
2592
2590
  return a === "browser" && c && (o = o.replace(c, "")), o.charAt(0) !== "/" && (o = `/${o}`), o;
@@ -2597,13 +2595,13 @@ class zs {
2597
2595
  * @param params Optional: route params
2598
2596
  */
2599
2597
  navigate(t, e = {}) {
2600
- const r = ae(t, this.routes);
2598
+ const r = ke(t, this.routes);
2601
2599
  if (!r || !this.history)
2602
2600
  return;
2603
- const s = It(e, r.path);
2601
+ const s = ee(e, r.path);
2604
2602
  if (!s)
2605
2603
  return;
2606
- const i = this.getRouteData(), o = i && i.name === t && _s(i.params, e);
2604
+ const i = this.getRouteData(), o = i && i.name === t && Ii(i.params, e);
2607
2605
  if (this.steps[0] && o)
2608
2606
  return;
2609
2607
  const { decodeSearch: a } = this.settings, c = a ? a(s) : s;
@@ -2618,7 +2616,7 @@ class zs {
2618
2616
  hasBack() {
2619
2617
  if (this.steps.length > 1)
2620
2618
  return !0;
2621
- const t = this.getRouteData(this.settings.initialPath), e = this.getRouteData(), r = e.name === t.name, s = Ae(e.params, t.params);
2619
+ const t = this.getRouteData(this.settings.initialPath), e = this.getRouteData(), r = e.name === t.name, s = dn(e.params, t.params);
2622
2620
  return !r || !s;
2623
2621
  }
2624
2622
  /**
@@ -2630,7 +2628,7 @@ class zs {
2630
2628
  e && e.name && (this.navigate(e.name, e.params), this.steps = []);
2631
2629
  } else {
2632
2630
  const e = t >= this.steps.length ? this.steps.length - 1 : t, { routeData: r } = this.steps[e];
2633
- this.steps = [...this.steps.slice(e + 1)], this.navigate(r.name, Qn(r.params));
2631
+ this.steps = [...this.steps.slice(e + 1)], this.navigate(r.name, ts(r.params));
2634
2632
  }
2635
2633
  }
2636
2634
  /**
@@ -2651,14 +2649,14 @@ class zs {
2651
2649
  */
2652
2650
  getInitialRoute() {
2653
2651
  const { name: t } = this.getRouteData(this.settings.initialPath);
2654
- return this.routes.find((r) => r.name === t) || (this.routes.length > 0 ? this.routes[0] : (process.env.NODE_ENV !== "production" && R.warn("Unable to get initial route as no routes are defined."), null));
2652
+ return this.routes.find((r) => r.name === t) || (this.routes.length > 0 ? this.routes[0] : (process.env.NODE_ENV !== "production" && I.warn("Unable to get initial route as no routes are defined."), null));
2655
2653
  }
2656
2654
  getRouteData(t) {
2657
- const e = ce(this.container);
2655
+ const e = Ne(this.container);
2658
2656
  if (t) {
2659
- const r = ft(t, this.routes);
2657
+ const r = Ot(t, this.routes);
2660
2658
  return r ? {
2661
- params: lt(Ot(t, r.path)),
2659
+ params: yt(Lt(t, r.path)),
2662
2660
  name: r.name
2663
2661
  } : e || {
2664
2662
  name: "",
@@ -2667,15 +2665,15 @@ class zs {
2667
2665
  }
2668
2666
  if (this.location) {
2669
2667
  const { pathname: r, search: s } = this.location;
2670
- if (this.currentRoute = this.currentRoute || ft(r, this.routes), this.currentRoute) {
2668
+ if (this.currentRoute = this.currentRoute || Ot(r, this.routes), this.currentRoute) {
2671
2669
  const { path: i, name: o } = this.currentRoute;
2672
2670
  this.match || (this.match = {
2673
- params: Ot(r, i),
2671
+ params: Lt(r, i),
2674
2672
  isExact: !0,
2675
2673
  path: i,
2676
2674
  url: r
2677
2675
  });
2678
- const a = lt(gt(gt({}, this.match.params), s.length > 0 && Dn(s)));
2676
+ const a = yt(Et(Et({}, this.match.params), s.length > 0 && Sr(s)));
2679
2677
  return {
2680
2678
  name: o,
2681
2679
  params: a
@@ -2694,31 +2692,31 @@ class zs {
2694
2692
  * Setup and load the initial route based on router configuration
2695
2693
  */
2696
2694
  setupInitialRoute() {
2697
- return q(this.container, Ge, this.storageMedium).then(
2695
+ return Y(this.container, Ln, this.storageMedium).then(
2698
2696
  (t) => {
2699
2697
  if (!this.location || !this.history)
2700
2698
  return;
2701
2699
  const { initialPath: e, mode: r } = this.settings;
2702
2700
  switch ((() => {
2703
- const s = we(this.container);
2704
- return r === K.browser || s ? ot.path : r === K.memory && t ? ot.storage : ot.initialPath;
2701
+ const s = Xe(this.container);
2702
+ return r === K.browser || s ? dt.path : r === K.memory && t ? dt.storage : dt.initialPath;
2705
2703
  })()) {
2706
- case ot.initialPath: {
2704
+ case dt.initialPath: {
2707
2705
  const s = this.getRouteData(e);
2708
2706
  return s && s.name ? this.navigate(s.name, s.params) : void 0;
2709
2707
  }
2710
- case ot.path: {
2708
+ case dt.path: {
2711
2709
  const { pathname: s } = this.location;
2712
- if (this.currentRoute = ft(s, this.routes), this.currentRoute) {
2710
+ if (this.currentRoute = Ot(s, this.routes), this.currentRoute) {
2713
2711
  const { path: o } = this.currentRoute;
2714
2712
  return this.setMatch({
2715
- params: Ot(s, o),
2713
+ params: Lt(s, o),
2716
2714
  isExact: !0,
2717
2715
  path: o,
2718
2716
  url: s
2719
2717
  });
2720
2718
  }
2721
- const i = ce(this.container);
2719
+ const i = Ne(this.container);
2722
2720
  return i ? this.setMatch({
2723
2721
  params: {},
2724
2722
  isExact: !0,
@@ -2726,14 +2724,14 @@ class zs {
2726
2724
  url: s
2727
2725
  }) : void 0;
2728
2726
  }
2729
- case ot.storage: {
2727
+ case dt.storage: {
2730
2728
  const { pathname: s } = this.location;
2731
- this.currentRoute = ft(s, this.routes);
2732
- const { name: i = "", params: o = {} } = t || {}, a = ae(i, this.routes);
2729
+ this.currentRoute = Ot(s, this.routes);
2730
+ const { name: i = "", params: o = {} } = t || {}, a = ke(i, this.routes);
2733
2731
  if (a) {
2734
- const c = It(o, a.path);
2732
+ const c = ee(o, a.path);
2735
2733
  if (c)
2736
- return this.history.push(c), this.location = wn(gt({}, this.location), { pathname: c }), this.currentRoute = ft(c, this.routes), this.setMatch({
2734
+ return this.history.push(c), this.location = gr(Et({}, this.location), { pathname: c }), this.currentRoute = Ot(c, this.routes), this.setMatch({
2737
2735
  params: o,
2738
2736
  isExact: !0,
2739
2737
  path: a.path,
@@ -2756,12 +2754,12 @@ class zs {
2756
2754
  const { pathname: r } = t, { mode: s } = this.settings;
2757
2755
  if (r.indexOf("?") > -1 || r.indexOf(";") > -1 || s === K.scopedHash && e !== this.widget.name)
2758
2756
  return;
2759
- this.location = t, this.currentRoute = ft(r, this.routes);
2760
- const i = ce(this.container);
2757
+ this.location = t, this.currentRoute = Ot(r, this.routes);
2758
+ const i = Ne(this.container);
2761
2759
  if (this.currentRoute) {
2762
2760
  const { path: o } = this.currentRoute;
2763
2761
  this.setMatch({
2764
- params: Ot(r, o),
2762
+ params: Lt(r, o),
2765
2763
  isExact: !0,
2766
2764
  path: o,
2767
2765
  url: r
@@ -2778,8 +2776,8 @@ class zs {
2778
2776
  return new Promise((t) => {
2779
2777
  const { mode: e, basePath: r } = this.settings;
2780
2778
  if (e === K.scopedHash) {
2781
- const s = this.widget.name, i = js(this.container);
2782
- return Promise.resolve().then(() => Hs).then((o) => {
2779
+ const s = this.widget.name, i = Ri(this.container);
2780
+ return Promise.resolve().then(() => Vi).then((o) => {
2783
2781
  const a = o.default({
2784
2782
  widgetName: s,
2785
2783
  transitionManager: i,
@@ -2789,22 +2787,22 @@ class zs {
2789
2787
  });
2790
2788
  }
2791
2789
  if (e === K.memory)
2792
- return t(Br());
2790
+ return t(Ws());
2793
2791
  if (e === K.browser)
2794
- return t(Hr({ basename: r }));
2792
+ return t(Vs({ basename: r }));
2795
2793
  throw "RoutingService: History could not be created.";
2796
2794
  });
2797
2795
  }
2798
2796
  }
2799
- const Fs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2797
+ const Ki = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2800
2798
  __proto__: null,
2801
2799
  HistoryMode: K,
2802
- RoutingService: zs,
2803
- createHashHistory: jn,
2804
- getScopedHashDOMLocation: _n,
2805
- matchParams: Ot,
2806
- onWidgetUrl: we
2807
- }, Symbol.toStringTag, { value: "Module" })), he = (n, t, e, ...r) => {
2800
+ RoutingService: qi,
2801
+ createHashHistory: Pr,
2802
+ getScopedHashDOMLocation: Cr,
2803
+ matchParams: Lt,
2804
+ onWidgetUrl: Xe
2805
+ }, Symbol.toStringTag, { value: "Module" })), Me = (n, t, e, ...r) => {
2808
2806
  const s = `[${n.get("$environment").name || "webprovisions"}] ${e}`;
2809
2807
  switch (t) {
2810
2808
  case "info":
@@ -2817,16 +2815,16 @@ const Fs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2817
2815
  console.error(s, ...r);
2818
2816
  break;
2819
2817
  }
2820
- }, Js = (n) => {
2818
+ }, Yi = (n) => {
2821
2819
  const t = n.container || n;
2822
2820
  return {
2823
- info: (e, ...r) => he(t, "info", e, ...r),
2824
- warn: (e, ...r) => he(t, "warning", e, ...r),
2825
- error: (e, ...r) => he(t, "error", e, ...r)
2821
+ info: (e, ...r) => Me(t, "info", e, ...r),
2822
+ warn: (e, ...r) => Me(t, "warning", e, ...r),
2823
+ error: (e, ...r) => Me(t, "error", e, ...r)
2826
2824
  };
2827
2825
  };
2828
- var $t = /* @__PURE__ */ ((n) => (n.Implementation = "implementation", n.Widget = "widget", n))($t || {}), it = /* @__PURE__ */ ((n) => (n.Pre = "pre", n.Post = "post", n))(it || {});
2829
- const Ks = (n, t, e, r) => {
2826
+ var Rt = /* @__PURE__ */ ((n) => (n.Implementation = "implementation", n.Widget = "widget", n))(Rt || {}), ht = /* @__PURE__ */ ((n) => (n.Pre = "pre", n.Post = "post", n))(ht || {});
2827
+ const Gi = (n, t, e, r) => {
2830
2828
  try {
2831
2829
  const s = new t(e, r);
2832
2830
  return {
@@ -2850,23 +2848,23 @@ const Ks = (n, t, e, r) => {
2850
2848
  throw s;
2851
2849
  }
2852
2850
  };
2853
- function Qe(n, t) {
2851
+ function Dn(n, t) {
2854
2852
  return typeof n == "undefined" ? t : n;
2855
2853
  }
2856
- class qs {
2854
+ class Zi {
2857
2855
  constructor(t = {}) {
2858
2856
  this.part = t;
2859
2857
  }
2860
2858
  createCommand(t, e, r) {
2861
2859
  let s;
2862
2860
  typeof e == "function" ? s = {
2863
- scope: $t.Widget,
2864
- stage: it.Post,
2861
+ scope: Rt.Widget,
2862
+ stage: ht.Post,
2865
2863
  defaultArgs: void 0,
2866
2864
  handlerResolver: e
2867
2865
  } : s = {
2868
- scope: Qe(e.scope, $t.Widget),
2869
- stage: Qe(e.stage, it.Post),
2866
+ scope: Dn(e.scope, Rt.Widget),
2867
+ stage: Dn(e.stage, ht.Post),
2870
2868
  defaultArgs: e.defaultArgs,
2871
2869
  handlerResolver: r
2872
2870
  };
@@ -2880,26 +2878,26 @@ class qs {
2880
2878
  return this.part;
2881
2879
  }
2882
2880
  }
2883
- const In = (n) => {
2884
- const t = new qs({});
2881
+ const kr = (n) => {
2882
+ const t = new Zi({});
2885
2883
  return n(t), t.get();
2886
2884
  };
2887
- In((n) => {
2885
+ kr((n) => {
2888
2886
  n.createCommand(
2889
2887
  "types.register",
2890
- { scope: $t.Implementation, stage: it.Pre },
2888
+ { scope: Rt.Implementation, stage: ht.Pre },
2891
2889
  (t) => (e, r) => {
2892
2890
  t.container.get("$types")[e] = r;
2893
2891
  }
2894
2892
  ).createCommand(
2895
2893
  "type",
2896
- { stage: it.Pre },
2894
+ { stage: ht.Pre },
2897
2895
  (t) => (e) => {
2898
2896
  t.container.register("$type", e);
2899
2897
  }
2900
2898
  ).createCommand(
2901
2899
  "settings",
2902
- { stage: it.Pre, defaultArgs: [null] },
2900
+ { stage: ht.Pre, defaultArgs: [null] },
2903
2901
  (t) => (e) => {
2904
2902
  t.events.dispatch(
2905
2903
  "settings:change",
@@ -2909,28 +2907,28 @@ In((n) => {
2909
2907
  }
2910
2908
  ).createCommand(
2911
2909
  "plugin",
2912
- { stage: it.Pre },
2910
+ { stage: ht.Pre },
2913
2911
  (t) => (e, r, s) => {
2914
2912
  const { container: i } = t;
2915
2913
  let o = null, a = e, c = r;
2916
2914
  typeof e == "string" && (o = e, a = r, c = s);
2917
- const h = (u) => {
2918
- const { transformPluginSettings: l } = t.container.get("$environmentOptions"), d = l ? l(
2915
+ const h = (l) => {
2916
+ const { transformPluginSettings: u } = t.container.get("$environmentOptions"), d = u ? u(
2919
2917
  c || {},
2920
2918
  o,
2921
2919
  t.container,
2922
2920
  a
2923
2921
  ) : r;
2924
2922
  try {
2925
- const f = Ks(
2923
+ const p = Gi(
2926
2924
  o,
2927
2925
  a,
2928
2926
  i,
2929
2927
  d
2930
2928
  );
2931
- i.get("$plugins").push(f), u && f.invoke("initialize", null);
2932
- } catch (f) {
2933
- Js(t).warn("Error when initializing plugin", f);
2929
+ i.get("$plugins").push(p), l && p.invoke("initialize", null);
2930
+ } catch (p) {
2931
+ Yi(t).warn("Error when initializing plugin", p);
2934
2932
  }
2935
2933
  };
2936
2934
  t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
@@ -2963,45 +2961,45 @@ In((n) => {
2963
2961
  }
2964
2962
  );
2965
2963
  });
2966
- function Ys(n) {
2964
+ function Qi(n) {
2967
2965
  const t = {};
2968
2966
  return [].filter.call(n.attributes, (e) => /^data-/.test(e.name)).map((e) => e.name).forEach((e) => t[e.substr(5)] = n.getAttribute(e)), t;
2969
2967
  }
2970
- const Ze = (n, t, e) => {
2971
- const r = Ys(n);
2968
+ const Tn = (n, t, e) => {
2969
+ const r = Qi(n);
2972
2970
  e({
2973
2971
  sourceDOMElement: n,
2974
2972
  eventType: t,
2975
2973
  data: r
2976
2974
  });
2977
2975
  };
2978
- function Xe(n, t, e) {
2976
+ function jn(n, t, e) {
2979
2977
  n.forEach((r) => {
2980
- r.dataset.attached !== "true" && (t === "load" ? Ze(r, t, e) : r.addEventListener(t, (s) => {
2981
- s.preventDefault(), Ze(r, t, e);
2978
+ r.dataset.attached !== "true" && (t === "load" ? Tn(r, t, e) : r.addEventListener(t, (s) => {
2979
+ s.preventDefault(), Tn(r, t, e);
2982
2980
  }), r.dataset.monitored = "true");
2983
2981
  });
2984
2982
  }
2985
- function Gs(n, t, e) {
2983
+ function Xi(n, t, e) {
2986
2984
  const r = n.container.get("bootstrapping.monitor");
2987
2985
  r && r.events.subscribe("bootstrap:trigger-elements-updated", (i, o) => {
2988
- Xe(
2986
+ jn(
2989
2987
  o.triggerElements,
2990
2988
  t,
2991
2989
  e
2992
2990
  );
2993
2991
  });
2994
2992
  const s = n.container.get("triggerElements");
2995
- s && Xe(
2993
+ s && jn(
2996
2994
  s,
2997
2995
  t,
2998
2996
  e
2999
2997
  );
3000
2998
  }
3001
- In((n) => {
2999
+ kr((n) => {
3002
3000
  n.createCommand(
3003
3001
  "ready",
3004
- { scope: $t.Implementation, stage: it.Pre },
3002
+ { scope: Rt.Implementation, stage: ht.Pre },
3005
3003
  (t) => (e) => {
3006
3004
  const { container: r } = t, s = r.owner;
3007
3005
  r.get("bootstrapping").ready ? e(s) : s.events.subscribeOnce("bootstrap:ready", () => {
@@ -3010,84 +3008,870 @@ In((n) => {
3010
3008
  }
3011
3009
  );
3012
3010
  });
3013
- const Qs = (n) => {
3014
- if (n) {
3015
- const { type: t, content: e } = n;
3016
- switch (t) {
3017
- case "FontAwesome":
3018
- return `<i class="humany-icon fa fa-${e}"></i>`;
3019
- case "Uri":
3020
- return `<i class="humany-icon humany-custom-icon" style="background: url(${e}) no-repeat center center;background-size: contain;"></i>`;
3021
- default:
3022
- return "";
3023
- }
3024
- }
3025
- }, Zs = (n) => {
3011
+ const to = (n) => {
3026
3012
  const t = (s, i) => {
3027
- s && (i ? s.classList.add("humany-tabbing") : s.classList.remove("humany-tabbing"));
3013
+ s && (i ? s.classList.add("ace-tabbing") : s.classList.remove("ace-tabbing"));
3028
3014
  }, e = (s) => {
3029
- s.key === "Tab" ? t(n, !0) : s.key === "Enter" && document.activeElement && document.activeElement.classList.contains("humany-trigger") || t(n, !1);
3015
+ s.key === "Tab" ? t(n, !0) : s.key === "Enter" && document.activeElement && document.activeElement.classList.contains("ace-widget-trigger") || t(n, !1);
3030
3016
  }, r = (s) => {
3031
- document.activeElement && document.activeElement.classList.contains("humany-trigger") && document.activeElement.classList.contains("humany-tabbing") || t(n, !1);
3017
+ document.activeElement && document.activeElement.classList.contains("ace-widget-trigger") && document.activeElement.classList.contains("ace-tabbing") || t(n, !1);
3032
3018
  };
3033
3019
  return document.addEventListener("keydown", e), document.addEventListener("click", r), () => {
3034
3020
  document.removeEventListener("keydown", e), document.removeEventListener("click", r);
3035
3021
  };
3036
3022
  };
3037
- function Xs(n, t) {
3023
+ function eo(n, t) {
3038
3024
  const {
3039
- symbol: e,
3040
- widgetName: r,
3041
- label: s = "",
3042
- ariaLabel: i = "",
3043
- tooltip: o = ""
3025
+ // symbol,
3026
+ widgetName: e,
3027
+ label: r = "",
3028
+ ariaLabel: s = "",
3029
+ tooltip: i = ""
3044
3030
  } = t;
3045
- n.classList.add("humany-trigger"), n.classList.add(`humany_${r}`), s.length && n.classList.add("humany-has-text"), i.length && !n.getAttribute("aria-label") && n.setAttribute("aria-label", i), i.length && !n.getAttribute("tabindex") && n.setAttribute("tabindex", "0"), o.length && !n.getAttribute("title") && n.setAttribute("title", o);
3046
- const a = Qs(e) || "";
3047
- return n.innerHTML = `${a}
3048
- <span class="humany-close">
3049
- <svg width="18" height="9" viewBox="0 0 18 9" fill="none" xmlns="http://www.w3.org/2000/svg">
3050
- <path d="M9 9C8.81794 9.00045 8.63759 8.96634 8.46939 8.89965C8.3012 8.83295 8.14851 8.735 8.02015 8.61145L0.194523 1.12367C0.068294 0.99862 -0.00155266 0.831133 2.61958e-05 0.657285C0.00160506 0.483436 0.0744832 0.317136 0.202964 0.194202C0.331445 0.0712675 0.505249 0.00153576 0.686941 2.50649e-05C0.868634 -0.00148563 1.04368 0.0653456 1.17437 0.186125L9 7.6739L16.8256 0.186125C16.9563 0.0653456 17.1314 -0.00148563 17.3131 2.50649e-05C17.4948 0.00153576 17.6686 0.0712675 17.797 0.194202C17.9255 0.317136 17.9984 0.483436 18 0.657285C18.0016 0.831133 17.9317 0.99862 17.8055 1.12367L9.97985 8.61145C9.85149 8.735 9.6988 8.83295 9.53061 8.89965C9.36241 8.96634 9.18206 9.00045 9 9Z" fill="white"/>
3051
- </svg>
3052
- </span>
3053
- <span class="humany-loader">
3054
- <svg viewBox="25 25 50 50">
3055
- <circle
3056
- cx="50"
3057
- cy="50"
3058
- r="20"
3059
- fill="none"
3060
- stroke="#000"
3061
- stroke-width="2"
3062
- stroke-miterlimit="10" />
3063
- </svg>
3064
- </span>
3065
- ${s.length ? `<span>${s}</span>` : ""}`, setTimeout(
3066
- () => n && n.classList.add("humany-rendered")
3067
- ), Zs(n);
3031
+ return n.classList.add("ace-widget-trigger"), n.classList.add(`ace-widget_${e}`), r.length && n.classList.add("trigger-has-text"), s.length && !n.getAttribute("aria-label") && n.setAttribute("aria-label", s), s.length && !n.getAttribute("tabindex") && n.setAttribute("tabindex", "0"), i.length && !n.getAttribute("title") && n.setAttribute("title", i), to(n);
3068
3032
  }
3069
- function ti(n, t) {
3070
- n instanceof HTMLElement ? (t && n.setAttribute("title", t), n.classList.remove("humany-active"), n.classList.remove("humany-loading")) : n instanceof Array && n.forEach((e) => {
3071
- t && e.setAttribute("title", t), e.classList.remove("humany-active"), e.classList.remove("humany-loading");
3033
+ function no(n, t) {
3034
+ n instanceof HTMLElement ? (t && n.setAttribute("title", t), n.classList.remove("ace-trigger-active"), n.classList.remove("ace-trigger-loading")) : n instanceof Array && n.forEach((e) => {
3035
+ t && e.setAttribute("title", t), e.classList.remove("ace-trigger-active"), e.classList.remove("ace-trigger-loading");
3072
3036
  });
3073
3037
  }
3074
- function ei(n) {
3075
- n instanceof HTMLElement ? (n.classList.remove("humany-active"), n.classList.add("humany-loading")) : n instanceof Array && n.forEach((t) => {
3076
- t.classList.remove("humany-active"), t.classList.add("humany-loading");
3038
+ function ro(n) {
3039
+ n instanceof HTMLElement ? (n.classList.remove("ace-trigger-active"), n.classList.add("ace-trigger-loading")) : n instanceof Array && n.forEach((t) => {
3040
+ t.classList.remove("ace-trigger-active"), t.classList.add("ace-trigger-loading");
3077
3041
  });
3078
3042
  }
3079
- function Rn(n, t) {
3080
- n instanceof HTMLElement ? (t && n.setAttribute("title", t), n.classList.add("humany-active"), n.classList.remove("humany-loading")) : n instanceof Array && n.forEach((e) => {
3081
- t && e.setAttribute("title", t), e.classList.add("humany-active"), e.classList.remove("humany-loading");
3043
+ function Nr(n, t) {
3044
+ n instanceof HTMLElement ? (t && n.setAttribute("title", t), n.classList.add("ace-trigger-active"), n.classList.remove("ace-trigger-loading")) : n instanceof Array && n.forEach((e) => {
3045
+ t && e.setAttribute("title", t), e.classList.add("ace-trigger-active"), e.classList.remove("ace-trigger-loading");
3082
3046
  });
3083
3047
  }
3084
- var ut = /* @__PURE__ */ ((n) => (n.Inline = "inline", n.Link = "link", n.Badge = "badge", n.Unsupported = "unsupported", n))(ut || {});
3085
- const ni = (n, t) => n && t ? "both" : n ? "widgetDOM" : t ? "triggerDOM" : "none", Tn = (n) => n ? typeof n == "boolean" && n ? "link" : typeof n == "object" && !Array.isArray(n) ? "badge" : "unsupported" : "inline", ri = (n, t, e, r, s = !1) => {
3086
- var h, u;
3087
- const i = ni(
3048
+ /**
3049
+ * @license
3050
+ * Copyright 2019 Google LLC
3051
+ * SPDX-License-Identifier: BSD-3-Clause
3052
+ */
3053
+ const re = window, tn = re.ShadowRoot && (re.ShadyCSS === void 0 || re.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, en = Symbol(), Rn = /* @__PURE__ */ new WeakMap();
3054
+ let Mr = class {
3055
+ constructor(t, e, r) {
3056
+ if (this._$cssResult$ = !0, r !== en)
3057
+ throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
3058
+ this.cssText = t, this.t = e;
3059
+ }
3060
+ get styleSheet() {
3061
+ let t = this.o;
3062
+ const e = this.t;
3063
+ if (tn && t === void 0) {
3064
+ const r = e !== void 0 && e.length === 1;
3065
+ r && (t = Rn.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), r && Rn.set(e, t));
3066
+ }
3067
+ return t;
3068
+ }
3069
+ toString() {
3070
+ return this.cssText;
3071
+ }
3072
+ };
3073
+ const so = (n) => new Mr(typeof n == "string" ? n : n + "", void 0, en), io = (n, ...t) => {
3074
+ const e = n.length === 1 ? n[0] : t.reduce((r, s, i) => r + ((o) => {
3075
+ if (o._$cssResult$ === !0)
3076
+ return o.cssText;
3077
+ if (typeof o == "number")
3078
+ return o;
3079
+ throw Error("Value passed to 'css' function must be a 'css' function result: " + o + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
3080
+ })(s) + n[i + 1], n[0]);
3081
+ return new Mr(e, n, en);
3082
+ }, oo = (n, t) => {
3083
+ tn ? n.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet) : t.forEach((e) => {
3084
+ const r = document.createElement("style"), s = re.litNonce;
3085
+ s !== void 0 && r.setAttribute("nonce", s), r.textContent = e.cssText, n.appendChild(r);
3086
+ });
3087
+ }, In = tn ? (n) => n : (n) => n instanceof CSSStyleSheet ? ((t) => {
3088
+ let e = "";
3089
+ for (const r of t.cssRules)
3090
+ e += r.cssText;
3091
+ return so(e);
3092
+ })(n) : n;
3093
+ /**
3094
+ * @license
3095
+ * Copyright 2017 Google LLC
3096
+ * SPDX-License-Identifier: BSD-3-Clause
3097
+ */
3098
+ var Le;
3099
+ const ue = window, Hn = ue.trustedTypes, ao = Hn ? Hn.emptyScript : "", Un = ue.reactiveElementPolyfillSupport, We = { toAttribute(n, t) {
3100
+ switch (t) {
3101
+ case Boolean:
3102
+ n = n ? ao : null;
3103
+ break;
3104
+ case Object:
3105
+ case Array:
3106
+ n = n == null ? n : JSON.stringify(n);
3107
+ }
3108
+ return n;
3109
+ }, fromAttribute(n, t) {
3110
+ let e = n;
3111
+ switch (t) {
3112
+ case Boolean:
3113
+ e = n !== null;
3114
+ break;
3115
+ case Number:
3116
+ e = n === null ? null : Number(n);
3117
+ break;
3118
+ case Object:
3119
+ case Array:
3120
+ try {
3121
+ e = JSON.parse(n);
3122
+ } catch (r) {
3123
+ e = null;
3124
+ }
3125
+ }
3126
+ return e;
3127
+ } }, Lr = (n, t) => t !== n && (t == t || n == n), De = { attribute: !0, type: String, converter: We, reflect: !1, hasChanged: Lr }, Fe = "finalized";
3128
+ let At = class extends HTMLElement {
3129
+ constructor() {
3130
+ super(), this._$Ei = /* @__PURE__ */ new Map(), this.isUpdatePending = !1, this.hasUpdated = !1, this._$El = null, this._$Eu();
3131
+ }
3132
+ static addInitializer(t) {
3133
+ var e;
3134
+ this.finalize(), ((e = this.h) !== null && e !== void 0 ? e : this.h = []).push(t);
3135
+ }
3136
+ static get observedAttributes() {
3137
+ this.finalize();
3138
+ const t = [];
3139
+ return this.elementProperties.forEach((e, r) => {
3140
+ const s = this._$Ep(r, e);
3141
+ s !== void 0 && (this._$Ev.set(s, r), t.push(s));
3142
+ }), t;
3143
+ }
3144
+ static createProperty(t, e = De) {
3145
+ if (e.state && (e.attribute = !1), this.finalize(), this.elementProperties.set(t, e), !e.noAccessor && !this.prototype.hasOwnProperty(t)) {
3146
+ const r = typeof t == "symbol" ? Symbol() : "__" + t, s = this.getPropertyDescriptor(t, r, e);
3147
+ s !== void 0 && Object.defineProperty(this.prototype, t, s);
3148
+ }
3149
+ }
3150
+ static getPropertyDescriptor(t, e, r) {
3151
+ return { get() {
3152
+ return this[e];
3153
+ }, set(s) {
3154
+ const i = this[t];
3155
+ this[e] = s, this.requestUpdate(t, i, r);
3156
+ }, configurable: !0, enumerable: !0 };
3157
+ }
3158
+ static getPropertyOptions(t) {
3159
+ return this.elementProperties.get(t) || De;
3160
+ }
3161
+ static finalize() {
3162
+ if (this.hasOwnProperty(Fe))
3163
+ return !1;
3164
+ this[Fe] = !0;
3165
+ const t = Object.getPrototypeOf(this);
3166
+ if (t.finalize(), t.h !== void 0 && (this.h = [...t.h]), this.elementProperties = new Map(t.elementProperties), this._$Ev = /* @__PURE__ */ new Map(), this.hasOwnProperty("properties")) {
3167
+ const e = this.properties, r = [...Object.getOwnPropertyNames(e), ...Object.getOwnPropertySymbols(e)];
3168
+ for (const s of r)
3169
+ this.createProperty(s, e[s]);
3170
+ }
3171
+ return this.elementStyles = this.finalizeStyles(this.styles), !0;
3172
+ }
3173
+ static finalizeStyles(t) {
3174
+ const e = [];
3175
+ if (Array.isArray(t)) {
3176
+ const r = new Set(t.flat(1 / 0).reverse());
3177
+ for (const s of r)
3178
+ e.unshift(In(s));
3179
+ } else
3180
+ t !== void 0 && e.push(In(t));
3181
+ return e;
3182
+ }
3183
+ static _$Ep(t, e) {
3184
+ const r = e.attribute;
3185
+ return r === !1 ? void 0 : typeof r == "string" ? r : typeof t == "string" ? t.toLowerCase() : void 0;
3186
+ }
3187
+ _$Eu() {
3188
+ var t;
3189
+ this._$E_ = new Promise((e) => this.enableUpdating = e), this._$AL = /* @__PURE__ */ new Map(), this._$Eg(), this.requestUpdate(), (t = this.constructor.h) === null || t === void 0 || t.forEach((e) => e(this));
3190
+ }
3191
+ addController(t) {
3192
+ var e, r;
3193
+ ((e = this._$ES) !== null && e !== void 0 ? e : this._$ES = []).push(t), this.renderRoot !== void 0 && this.isConnected && ((r = t.hostConnected) === null || r === void 0 || r.call(t));
3194
+ }
3195
+ removeController(t) {
3196
+ var e;
3197
+ (e = this._$ES) === null || e === void 0 || e.splice(this._$ES.indexOf(t) >>> 0, 1);
3198
+ }
3199
+ _$Eg() {
3200
+ this.constructor.elementProperties.forEach((t, e) => {
3201
+ this.hasOwnProperty(e) && (this._$Ei.set(e, this[e]), delete this[e]);
3202
+ });
3203
+ }
3204
+ createRenderRoot() {
3205
+ var t;
3206
+ const e = (t = this.shadowRoot) !== null && t !== void 0 ? t : this.attachShadow(this.constructor.shadowRootOptions);
3207
+ return oo(e, this.constructor.elementStyles), e;
3208
+ }
3209
+ connectedCallback() {
3210
+ var t;
3211
+ this.renderRoot === void 0 && (this.renderRoot = this.createRenderRoot()), this.enableUpdating(!0), (t = this._$ES) === null || t === void 0 || t.forEach((e) => {
3212
+ var r;
3213
+ return (r = e.hostConnected) === null || r === void 0 ? void 0 : r.call(e);
3214
+ });
3215
+ }
3216
+ enableUpdating(t) {
3217
+ }
3218
+ disconnectedCallback() {
3219
+ var t;
3220
+ (t = this._$ES) === null || t === void 0 || t.forEach((e) => {
3221
+ var r;
3222
+ return (r = e.hostDisconnected) === null || r === void 0 ? void 0 : r.call(e);
3223
+ });
3224
+ }
3225
+ attributeChangedCallback(t, e, r) {
3226
+ this._$AK(t, r);
3227
+ }
3228
+ _$EO(t, e, r = De) {
3229
+ var s;
3230
+ const i = this.constructor._$Ep(t, r);
3231
+ if (i !== void 0 && r.reflect === !0) {
3232
+ const o = (((s = r.converter) === null || s === void 0 ? void 0 : s.toAttribute) !== void 0 ? r.converter : We).toAttribute(e, r.type);
3233
+ this._$El = t, o == null ? this.removeAttribute(i) : this.setAttribute(i, o), this._$El = null;
3234
+ }
3235
+ }
3236
+ _$AK(t, e) {
3237
+ var r;
3238
+ const s = this.constructor, i = s._$Ev.get(t);
3239
+ if (i !== void 0 && this._$El !== i) {
3240
+ const o = s.getPropertyOptions(i), a = typeof o.converter == "function" ? { fromAttribute: o.converter } : ((r = o.converter) === null || r === void 0 ? void 0 : r.fromAttribute) !== void 0 ? o.converter : We;
3241
+ this._$El = i, this[i] = a.fromAttribute(e, o.type), this._$El = null;
3242
+ }
3243
+ }
3244
+ requestUpdate(t, e, r) {
3245
+ let s = !0;
3246
+ t !== void 0 && (((r = r || this.constructor.getPropertyOptions(t)).hasChanged || Lr)(this[t], e) ? (this._$AL.has(t) || this._$AL.set(t, e), r.reflect === !0 && this._$El !== t && (this._$EC === void 0 && (this._$EC = /* @__PURE__ */ new Map()), this._$EC.set(t, r))) : s = !1), !this.isUpdatePending && s && (this._$E_ = this._$Ej());
3247
+ }
3248
+ _$Ej() {
3249
+ return Q(this, null, function* () {
3250
+ this.isUpdatePending = !0;
3251
+ try {
3252
+ yield this._$E_;
3253
+ } catch (e) {
3254
+ Promise.reject(e);
3255
+ }
3256
+ const t = this.scheduleUpdate();
3257
+ return t != null && (yield t), !this.isUpdatePending;
3258
+ });
3259
+ }
3260
+ scheduleUpdate() {
3261
+ return this.performUpdate();
3262
+ }
3263
+ performUpdate() {
3264
+ var t;
3265
+ if (!this.isUpdatePending)
3266
+ return;
3267
+ this.hasUpdated, this._$Ei && (this._$Ei.forEach((s, i) => this[i] = s), this._$Ei = void 0);
3268
+ let e = !1;
3269
+ const r = this._$AL;
3270
+ try {
3271
+ e = this.shouldUpdate(r), e ? (this.willUpdate(r), (t = this._$ES) === null || t === void 0 || t.forEach((s) => {
3272
+ var i;
3273
+ return (i = s.hostUpdate) === null || i === void 0 ? void 0 : i.call(s);
3274
+ }), this.update(r)) : this._$Ek();
3275
+ } catch (s) {
3276
+ throw e = !1, this._$Ek(), s;
3277
+ }
3278
+ e && this._$AE(r);
3279
+ }
3280
+ willUpdate(t) {
3281
+ }
3282
+ _$AE(t) {
3283
+ var e;
3284
+ (e = this._$ES) === null || e === void 0 || e.forEach((r) => {
3285
+ var s;
3286
+ return (s = r.hostUpdated) === null || s === void 0 ? void 0 : s.call(r);
3287
+ }), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
3288
+ }
3289
+ _$Ek() {
3290
+ this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
3291
+ }
3292
+ get updateComplete() {
3293
+ return this.getUpdateComplete();
3294
+ }
3295
+ getUpdateComplete() {
3296
+ return this._$E_;
3297
+ }
3298
+ shouldUpdate(t) {
3299
+ return !0;
3300
+ }
3301
+ update(t) {
3302
+ this._$EC !== void 0 && (this._$EC.forEach((e, r) => this._$EO(r, this[r], e)), this._$EC = void 0), this._$Ek();
3303
+ }
3304
+ updated(t) {
3305
+ }
3306
+ firstUpdated(t) {
3307
+ }
3308
+ };
3309
+ At[Fe] = !0, At.elementProperties = /* @__PURE__ */ new Map(), At.elementStyles = [], At.shadowRootOptions = { mode: "open" }, Un == null || Un({ ReactiveElement: At }), ((Le = ue.reactiveElementVersions) !== null && Le !== void 0 ? Le : ue.reactiveElementVersions = []).push("1.6.3");
3310
+ /**
3311
+ * @license
3312
+ * Copyright 2017 Google LLC
3313
+ * SPDX-License-Identifier: BSD-3-Clause
3314
+ */
3315
+ var Te;
3316
+ const de = window, _t = de.trustedTypes, Bn = _t ? _t.createPolicy("lit-html", { createHTML: (n) => n }) : void 0, Je = "$lit$", ct = `lit$${(Math.random() + "").slice(9)}$`, Dr = "?" + ct, co = `<${Dr}>`, bt = document, It = () => bt.createComment(""), Ht = (n) => n === null || typeof n != "object" && typeof n != "function", Tr = Array.isArray, ho = (n) => Tr(n) || typeof (n == null ? void 0 : n[Symbol.iterator]) == "function", je = `[
3317
+ \f\r]`, kt = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Vn = /-->/g, zn = />/g, ut = RegExp(`>|${je}(?:([^\\s"'>=/]+)(${je}*=${je}*(?:[^
3318
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), Wn = /'/g, Fn = /"/g, jr = /^(?:script|style|textarea|title)$/i, lo = (n) => (t, ...e) => ({ _$litType$: n, strings: t, values: e }), Kt = lo(1), wt = Symbol.for("lit-noChange"), T = Symbol.for("lit-nothing"), Jn = /* @__PURE__ */ new WeakMap(), mt = bt.createTreeWalker(bt, 129, null, !1);
3319
+ function Rr(n, t) {
3320
+ if (!Array.isArray(n) || !n.hasOwnProperty("raw"))
3321
+ throw Error("invalid template strings array");
3322
+ return Bn !== void 0 ? Bn.createHTML(t) : t;
3323
+ }
3324
+ const uo = (n, t) => {
3325
+ const e = n.length - 1, r = [];
3326
+ let s, i = t === 2 ? "<svg>" : "", o = kt;
3327
+ for (let a = 0; a < e; a++) {
3328
+ const c = n[a];
3329
+ let h, l, u = -1, d = 0;
3330
+ for (; d < c.length && (o.lastIndex = d, l = o.exec(c), l !== null); )
3331
+ d = o.lastIndex, o === kt ? l[1] === "!--" ? o = Vn : l[1] !== void 0 ? o = zn : l[2] !== void 0 ? (jr.test(l[2]) && (s = RegExp("</" + l[2], "g")), o = ut) : l[3] !== void 0 && (o = ut) : o === ut ? l[0] === ">" ? (o = s != null ? s : kt, u = -1) : l[1] === void 0 ? u = -2 : (u = o.lastIndex - l[2].length, h = l[1], o = l[3] === void 0 ? ut : l[3] === '"' ? Fn : Wn) : o === Fn || o === Wn ? o = ut : o === Vn || o === zn ? o = kt : (o = ut, s = void 0);
3332
+ const p = o === ut && n[a + 1].startsWith("/>") ? " " : "";
3333
+ i += o === kt ? c + co : u >= 0 ? (r.push(h), c.slice(0, u) + Je + c.slice(u) + ct + p) : c + ct + (u === -2 ? (r.push(void 0), a) : p);
3334
+ }
3335
+ return [Rr(n, i + (n[e] || "<?>") + (t === 2 ? "</svg>" : "")), r];
3336
+ };
3337
+ class Ut {
3338
+ constructor({ strings: t, _$litType$: e }, r) {
3339
+ let s;
3340
+ this.parts = [];
3341
+ let i = 0, o = 0;
3342
+ const a = t.length - 1, c = this.parts, [h, l] = uo(t, e);
3343
+ if (this.el = Ut.createElement(h, r), mt.currentNode = this.el.content, e === 2) {
3344
+ const u = this.el.content, d = u.firstChild;
3345
+ d.remove(), u.append(...d.childNodes);
3346
+ }
3347
+ for (; (s = mt.nextNode()) !== null && c.length < a; ) {
3348
+ if (s.nodeType === 1) {
3349
+ if (s.hasAttributes()) {
3350
+ const u = [];
3351
+ for (const d of s.getAttributeNames())
3352
+ if (d.endsWith(Je) || d.startsWith(ct)) {
3353
+ const p = l[o++];
3354
+ if (u.push(d), p !== void 0) {
3355
+ const b = s.getAttribute(p.toLowerCase() + Je).split(ct), v = /([.?@])?(.*)/.exec(p);
3356
+ c.push({ type: 1, index: i, name: v[2], strings: b, ctor: v[1] === "." ? go : v[1] === "?" ? mo : v[1] === "@" ? vo : we });
3357
+ } else
3358
+ c.push({ type: 6, index: i });
3359
+ }
3360
+ for (const d of u)
3361
+ s.removeAttribute(d);
3362
+ }
3363
+ if (jr.test(s.tagName)) {
3364
+ const u = s.textContent.split(ct), d = u.length - 1;
3365
+ if (d > 0) {
3366
+ s.textContent = _t ? _t.emptyScript : "";
3367
+ for (let p = 0; p < d; p++)
3368
+ s.append(u[p], It()), mt.nextNode(), c.push({ type: 2, index: ++i });
3369
+ s.append(u[d], It());
3370
+ }
3371
+ }
3372
+ } else if (s.nodeType === 8)
3373
+ if (s.data === Dr)
3374
+ c.push({ type: 2, index: i });
3375
+ else {
3376
+ let u = -1;
3377
+ for (; (u = s.data.indexOf(ct, u + 1)) !== -1; )
3378
+ c.push({ type: 7, index: i }), u += ct.length - 1;
3379
+ }
3380
+ i++;
3381
+ }
3382
+ }
3383
+ static createElement(t, e) {
3384
+ const r = bt.createElement("template");
3385
+ return r.innerHTML = t, r;
3386
+ }
3387
+ }
3388
+ function St(n, t, e = n, r) {
3389
+ var s, i, o, a;
3390
+ if (t === wt)
3391
+ return t;
3392
+ let c = r !== void 0 ? (s = e._$Co) === null || s === void 0 ? void 0 : s[r] : e._$Cl;
3393
+ const h = Ht(t) ? void 0 : t._$litDirective$;
3394
+ return (c == null ? void 0 : c.constructor) !== h && ((i = c == null ? void 0 : c._$AO) === null || i === void 0 || i.call(c, !1), h === void 0 ? c = void 0 : (c = new h(n), c._$AT(n, e, r)), r !== void 0 ? ((o = (a = e)._$Co) !== null && o !== void 0 ? o : a._$Co = [])[r] = c : e._$Cl = c), c !== void 0 && (t = St(n, c._$AS(n, t.values), c, r)), t;
3395
+ }
3396
+ class po {
3397
+ constructor(t, e) {
3398
+ this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
3399
+ }
3400
+ get parentNode() {
3401
+ return this._$AM.parentNode;
3402
+ }
3403
+ get _$AU() {
3404
+ return this._$AM._$AU;
3405
+ }
3406
+ u(t) {
3407
+ var e;
3408
+ const { el: { content: r }, parts: s } = this._$AD, i = ((e = t == null ? void 0 : t.creationScope) !== null && e !== void 0 ? e : bt).importNode(r, !0);
3409
+ mt.currentNode = i;
3410
+ let o = mt.nextNode(), a = 0, c = 0, h = s[0];
3411
+ for (; h !== void 0; ) {
3412
+ if (a === h.index) {
3413
+ let l;
3414
+ h.type === 2 ? l = new Vt(o, o.nextSibling, this, t) : h.type === 1 ? l = new h.ctor(o, h.name, h.strings, this, t) : h.type === 6 && (l = new yo(o, this, t)), this._$AV.push(l), h = s[++c];
3415
+ }
3416
+ a !== (h == null ? void 0 : h.index) && (o = mt.nextNode(), a++);
3417
+ }
3418
+ return mt.currentNode = bt, i;
3419
+ }
3420
+ v(t) {
3421
+ let e = 0;
3422
+ for (const r of this._$AV)
3423
+ r !== void 0 && (r.strings !== void 0 ? (r._$AI(t, r, e), e += r.strings.length - 2) : r._$AI(t[e])), e++;
3424
+ }
3425
+ }
3426
+ class Vt {
3427
+ constructor(t, e, r, s) {
3428
+ var i;
3429
+ this.type = 2, this._$AH = T, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = r, this.options = s, this._$Cp = (i = s == null ? void 0 : s.isConnected) === null || i === void 0 || i;
3430
+ }
3431
+ get _$AU() {
3432
+ var t, e;
3433
+ return (e = (t = this._$AM) === null || t === void 0 ? void 0 : t._$AU) !== null && e !== void 0 ? e : this._$Cp;
3434
+ }
3435
+ get parentNode() {
3436
+ let t = this._$AA.parentNode;
3437
+ const e = this._$AM;
3438
+ return e !== void 0 && (t == null ? void 0 : t.nodeType) === 11 && (t = e.parentNode), t;
3439
+ }
3440
+ get startNode() {
3441
+ return this._$AA;
3442
+ }
3443
+ get endNode() {
3444
+ return this._$AB;
3445
+ }
3446
+ _$AI(t, e = this) {
3447
+ t = St(this, t, e), Ht(t) ? t === T || t == null || t === "" ? (this._$AH !== T && this._$AR(), this._$AH = T) : t !== this._$AH && t !== wt && this._(t) : t._$litType$ !== void 0 ? this.g(t) : t.nodeType !== void 0 ? this.$(t) : ho(t) ? this.T(t) : this._(t);
3448
+ }
3449
+ k(t) {
3450
+ return this._$AA.parentNode.insertBefore(t, this._$AB);
3451
+ }
3452
+ $(t) {
3453
+ this._$AH !== t && (this._$AR(), this._$AH = this.k(t));
3454
+ }
3455
+ _(t) {
3456
+ this._$AH !== T && Ht(this._$AH) ? this._$AA.nextSibling.data = t : this.$(bt.createTextNode(t)), this._$AH = t;
3457
+ }
3458
+ g(t) {
3459
+ var e;
3460
+ const { values: r, _$litType$: s } = t, i = typeof s == "number" ? this._$AC(t) : (s.el === void 0 && (s.el = Ut.createElement(Rr(s.h, s.h[0]), this.options)), s);
3461
+ if (((e = this._$AH) === null || e === void 0 ? void 0 : e._$AD) === i)
3462
+ this._$AH.v(r);
3463
+ else {
3464
+ const o = new po(i, this), a = o.u(this.options);
3465
+ o.v(r), this.$(a), this._$AH = o;
3466
+ }
3467
+ }
3468
+ _$AC(t) {
3469
+ let e = Jn.get(t.strings);
3470
+ return e === void 0 && Jn.set(t.strings, e = new Ut(t)), e;
3471
+ }
3472
+ T(t) {
3473
+ Tr(this._$AH) || (this._$AH = [], this._$AR());
3474
+ const e = this._$AH;
3475
+ let r, s = 0;
3476
+ for (const i of t)
3477
+ s === e.length ? e.push(r = new Vt(this.k(It()), this.k(It()), this, this.options)) : r = e[s], r._$AI(i), s++;
3478
+ s < e.length && (this._$AR(r && r._$AB.nextSibling, s), e.length = s);
3479
+ }
3480
+ _$AR(t = this._$AA.nextSibling, e) {
3481
+ var r;
3482
+ for ((r = this._$AP) === null || r === void 0 || r.call(this, !1, !0, e); t && t !== this._$AB; ) {
3483
+ const s = t.nextSibling;
3484
+ t.remove(), t = s;
3485
+ }
3486
+ }
3487
+ setConnected(t) {
3488
+ var e;
3489
+ this._$AM === void 0 && (this._$Cp = t, (e = this._$AP) === null || e === void 0 || e.call(this, t));
3490
+ }
3491
+ }
3492
+ class we {
3493
+ constructor(t, e, r, s, i) {
3494
+ this.type = 1, this._$AH = T, this._$AN = void 0, this.element = t, this.name = e, this._$AM = s, this.options = i, r.length > 2 || r[0] !== "" || r[1] !== "" ? (this._$AH = Array(r.length - 1).fill(new String()), this.strings = r) : this._$AH = T;
3495
+ }
3496
+ get tagName() {
3497
+ return this.element.tagName;
3498
+ }
3499
+ get _$AU() {
3500
+ return this._$AM._$AU;
3501
+ }
3502
+ _$AI(t, e = this, r, s) {
3503
+ const i = this.strings;
3504
+ let o = !1;
3505
+ if (i === void 0)
3506
+ t = St(this, t, e, 0), o = !Ht(t) || t !== this._$AH && t !== wt, o && (this._$AH = t);
3507
+ else {
3508
+ const a = t;
3509
+ let c, h;
3510
+ for (t = i[0], c = 0; c < i.length - 1; c++)
3511
+ h = St(this, a[r + c], e, c), h === wt && (h = this._$AH[c]), o || (o = !Ht(h) || h !== this._$AH[c]), h === T ? t = T : t !== T && (t += (h != null ? h : "") + i[c + 1]), this._$AH[c] = h;
3512
+ }
3513
+ o && !s && this.j(t);
3514
+ }
3515
+ j(t) {
3516
+ t === T ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t != null ? t : "");
3517
+ }
3518
+ }
3519
+ class go extends we {
3520
+ constructor() {
3521
+ super(...arguments), this.type = 3;
3522
+ }
3523
+ j(t) {
3524
+ this.element[this.name] = t === T ? void 0 : t;
3525
+ }
3526
+ }
3527
+ const fo = _t ? _t.emptyScript : "";
3528
+ class mo extends we {
3529
+ constructor() {
3530
+ super(...arguments), this.type = 4;
3531
+ }
3532
+ j(t) {
3533
+ t && t !== T ? this.element.setAttribute(this.name, fo) : this.element.removeAttribute(this.name);
3534
+ }
3535
+ }
3536
+ class vo extends we {
3537
+ constructor(t, e, r, s, i) {
3538
+ super(t, e, r, s, i), this.type = 5;
3539
+ }
3540
+ _$AI(t, e = this) {
3541
+ var r;
3542
+ if ((t = (r = St(this, t, e, 0)) !== null && r !== void 0 ? r : T) === wt)
3543
+ return;
3544
+ const s = this._$AH, i = t === T && s !== T || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, o = t !== T && (s === T || i);
3545
+ i && this.element.removeEventListener(this.name, this, s), o && this.element.addEventListener(this.name, this, t), this._$AH = t;
3546
+ }
3547
+ handleEvent(t) {
3548
+ var e, r;
3549
+ typeof this._$AH == "function" ? this._$AH.call((r = (e = this.options) === null || e === void 0 ? void 0 : e.host) !== null && r !== void 0 ? r : this.element, t) : this._$AH.handleEvent(t);
3550
+ }
3551
+ }
3552
+ class yo {
3553
+ constructor(t, e, r) {
3554
+ this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = r;
3555
+ }
3556
+ get _$AU() {
3557
+ return this._$AM._$AU;
3558
+ }
3559
+ _$AI(t) {
3560
+ St(this, t);
3561
+ }
3562
+ }
3563
+ const qn = de.litHtmlPolyfillSupport;
3564
+ qn == null || qn(Ut, Vt), ((Te = de.litHtmlVersions) !== null && Te !== void 0 ? Te : de.litHtmlVersions = []).push("2.8.0");
3565
+ const bo = (n, t, e) => {
3566
+ var r, s;
3567
+ const i = (r = e == null ? void 0 : e.renderBefore) !== null && r !== void 0 ? r : t;
3568
+ let o = i._$litPart$;
3569
+ if (o === void 0) {
3570
+ const a = (s = e == null ? void 0 : e.renderBefore) !== null && s !== void 0 ? s : null;
3571
+ i._$litPart$ = o = new Vt(t.insertBefore(It(), a), a, void 0, e != null ? e : {});
3572
+ }
3573
+ return o._$AI(n), o;
3574
+ };
3575
+ /**
3576
+ * @license
3577
+ * Copyright 2017 Google LLC
3578
+ * SPDX-License-Identifier: BSD-3-Clause
3579
+ */
3580
+ var Re, Ie;
3581
+ let jt = class extends At {
3582
+ constructor() {
3583
+ super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
3584
+ }
3585
+ createRenderRoot() {
3586
+ var t, e;
3587
+ const r = super.createRenderRoot();
3588
+ return (t = (e = this.renderOptions).renderBefore) !== null && t !== void 0 || (e.renderBefore = r.firstChild), r;
3589
+ }
3590
+ update(t) {
3591
+ const e = this.render();
3592
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = bo(e, this.renderRoot, this.renderOptions);
3593
+ }
3594
+ connectedCallback() {
3595
+ var t;
3596
+ super.connectedCallback(), (t = this._$Do) === null || t === void 0 || t.setConnected(!0);
3597
+ }
3598
+ disconnectedCallback() {
3599
+ var t;
3600
+ super.disconnectedCallback(), (t = this._$Do) === null || t === void 0 || t.setConnected(!1);
3601
+ }
3602
+ render() {
3603
+ return wt;
3604
+ }
3605
+ };
3606
+ jt.finalized = !0, jt._$litElement$ = !0, (Re = globalThis.litElementHydrateSupport) === null || Re === void 0 || Re.call(globalThis, { LitElement: jt });
3607
+ const Kn = globalThis.litElementPolyfillSupport;
3608
+ Kn == null || Kn({ LitElement: jt });
3609
+ ((Ie = globalThis.litElementVersions) !== null && Ie !== void 0 ? Ie : globalThis.litElementVersions = []).push("3.3.3");
3610
+ /**
3611
+ * @license
3612
+ * Copyright 2017 Google LLC
3613
+ * SPDX-License-Identifier: BSD-3-Clause
3614
+ */
3615
+ const wo = (n, t) => t.kind === "method" && t.descriptor && !("value" in t.descriptor) ? zt(st({}, t), { finisher(e) {
3616
+ e.createProperty(t.key, n);
3617
+ } }) : { kind: "field", key: Symbol(), placement: "own", descriptor: {}, originalKey: t.key, initializer() {
3618
+ typeof t.initializer == "function" && (this[t.key] = t.initializer.call(this));
3619
+ }, finisher(e) {
3620
+ e.createProperty(t.key, n);
3621
+ } }, $o = (n, t, e) => {
3622
+ t.constructor.createProperty(e, n);
3623
+ };
3624
+ function Ir(n) {
3625
+ return (t, e) => e !== void 0 ? $o(n, t, e) : wo(n, t);
3626
+ }
3627
+ /**
3628
+ * @license
3629
+ * Copyright 2017 Google LLC
3630
+ * SPDX-License-Identifier: BSD-3-Clause
3631
+ */
3632
+ function nn(n) {
3633
+ return Ir(zt(st({}, n), { state: !0 }));
3634
+ }
3635
+ /**
3636
+ * @license
3637
+ * Copyright 2021 Google LLC
3638
+ * SPDX-License-Identifier: BSD-3-Clause
3639
+ */
3640
+ var He;
3641
+ ((He = window.HTMLSlotElement) === null || He === void 0 ? void 0 : He.prototype.assignedElements) != null;
3642
+ /**
3643
+ * @license
3644
+ * Copyright 2017 Google LLC
3645
+ * SPDX-License-Identifier: BSD-3-Clause
3646
+ */
3647
+ const Oo = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 }, Eo = (n) => (...t) => ({ _$litDirective$: n, values: t });
3648
+ class Ao {
3649
+ constructor(t) {
3650
+ }
3651
+ get _$AU() {
3652
+ return this._$AM._$AU;
3653
+ }
3654
+ _$AT(t, e, r) {
3655
+ this._$Ct = t, this._$AM = e, this._$Ci = r;
3656
+ }
3657
+ _$AS(t, e) {
3658
+ return this.update(t, e);
3659
+ }
3660
+ update(t, e) {
3661
+ return this.render(...e);
3662
+ }
3663
+ }
3664
+ /**
3665
+ * @license
3666
+ * Copyright 2018 Google LLC
3667
+ * SPDX-License-Identifier: BSD-3-Clause
3668
+ */
3669
+ const xo = Eo(class extends Ao {
3670
+ constructor(n) {
3671
+ var t;
3672
+ if (super(n), n.type !== Oo.ATTRIBUTE || n.name !== "class" || ((t = n.strings) === null || t === void 0 ? void 0 : t.length) > 2)
3673
+ throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.");
3674
+ }
3675
+ render(n) {
3676
+ return " " + Object.keys(n).filter((t) => n[t]).join(" ") + " ";
3677
+ }
3678
+ update(n, [t]) {
3679
+ var e, r;
3680
+ if (this.it === void 0) {
3681
+ this.it = /* @__PURE__ */ new Set(), n.strings !== void 0 && (this.nt = new Set(n.strings.join(" ").split(/\s/).filter((i) => i !== "")));
3682
+ for (const i in t)
3683
+ t[i] && !(!((e = this.nt) === null || e === void 0) && e.has(i)) && this.it.add(i);
3684
+ return this.render(t);
3685
+ }
3686
+ const s = n.element.classList;
3687
+ this.it.forEach((i) => {
3688
+ i in t || (s.remove(i), this.it.delete(i));
3689
+ });
3690
+ for (const i in t) {
3691
+ const o = !!t[i];
3692
+ o === this.it.has(i) || !((r = this.nt) === null || r === void 0) && r.has(i) || (o ? (s.add(i), this.it.add(i)) : (s.remove(i), this.it.delete(i)));
3693
+ }
3694
+ return wt;
3695
+ }
3696
+ });
3697
+ var _o = Object.defineProperty, So = Object.getOwnPropertyDescriptor, $e = (n, t, e, r) => {
3698
+ for (var s = r > 1 ? void 0 : r ? So(t, e) : t, i = n.length - 1, o; i >= 0; i--)
3699
+ (o = n[i]) && (s = (r ? o(t, e, s) : o(s)) || s);
3700
+ return r && s && _o(t, e, s), s;
3701
+ };
3702
+ class lt extends jt {
3703
+ constructor() {
3704
+ super(...arguments), this.active = !1, this.loaded = !1;
3705
+ }
3706
+ connectedCallback() {
3707
+ return Q(this, null, function* () {
3708
+ cn(lt.prototype, this, "connectedCallback").call(this), this.icon = yield this._renderSymbol(this.symbol), this.loaded = !0;
3709
+ });
3710
+ }
3711
+ _toggleActive() {
3712
+ this.active = !this.active;
3713
+ }
3714
+ _renderSymbol(t) {
3715
+ return Q(this, null, function* () {
3716
+ const e = (r) => Q(this, null, function* () {
3717
+ return yield import("./index-9688347a.js").then((i) => i[r]);
3718
+ });
3719
+ if (t) {
3720
+ const { type: r, content: s } = t;
3721
+ switch (r) {
3722
+ case "Telia": {
3723
+ const i = yield e(s);
3724
+ return i ? Kt`<telia-icon
3725
+ class="trigger-icon"
3726
+ svg=${i.svg}
3727
+ size="lg"
3728
+ ></telia-icon>` : T;
3729
+ }
3730
+ case "FontAwesome":
3731
+ return Kt`<i class="trigger-fa-icon fa fa-${s}"></i>`;
3732
+ case "Uri":
3733
+ return Kt`<i
3734
+ class="trigger-custom-icon"
3735
+ style="background: url(${s}) no-repeat center center;background-size: contain;"
3736
+ ></i>`;
3737
+ default:
3738
+ return T;
3739
+ }
3740
+ }
3741
+ });
3742
+ }
3743
+ render() {
3744
+ return Kt`<button
3745
+ class=${xo({
3746
+ trigger: !0,
3747
+ active: this.active,
3748
+ rendered: this.loaded
3749
+ })}
3750
+ @click=${this._toggleActive}
3751
+ >
3752
+ ${this.icon}
3753
+ <span class="trigger-close">
3754
+ <svg
3755
+ width="18"
3756
+ height="9"
3757
+ viewBox="0 0 18 9"
3758
+ fill="none"
3759
+ xmlns="http://www.w3.org/2000/svg"
3760
+ >
3761
+ <path
3762
+ d="M9 9C8.81794 9.00045 8.63759 8.96634 8.46939 8.89965C8.3012 8.83295 8.14851 8.735 8.02015 8.61145L0.194523 1.12367C0.068294 0.99862 -0.00155266 0.831133 2.61958e-05 0.657285C0.00160506 0.483436 0.0744832 0.317136 0.202964 0.194202C0.331445 0.0712675 0.505249 0.00153576 0.686941 2.50649e-05C0.868634 -0.00148563 1.04368 0.0653456 1.17437 0.186125L9 7.6739L16.8256 0.186125C16.9563 0.0653456 17.1314 -0.00148563 17.3131 2.50649e-05C17.4948 0.00153576 17.6686 0.0712675 17.797 0.194202C17.9255 0.317136 17.9984 0.483436 18 0.657285C18.0016 0.831133 17.9317 0.99862 17.8055 1.12367L9.97985 8.61145C9.85149 8.735 9.6988 8.83295 9.53061 8.89965C9.36241 8.96634 9.18206 9.00045 9 9Z"
3763
+ fill="white"
3764
+ />
3765
+ </svg>
3766
+ </span>
3767
+ <span class="trigger-loader">
3768
+ <svg viewBox="25 25 50 50">
3769
+ <circle
3770
+ cx="50"
3771
+ cy="50"
3772
+ r="20"
3773
+ fill="none"
3774
+ stroke="#000"
3775
+ stroke-width="2"
3776
+ stroke-miterlimit="10"
3777
+ />
3778
+ </svg>
3779
+ </span>
3780
+ </button>`;
3781
+ }
3782
+ }
3783
+ lt.styles = [
3784
+ io`
3785
+ :host {
3786
+ --voca-rem-multiplier: 0.625;
3787
+ display: block;
3788
+ box-sizing: border-box;
3789
+ }
3790
+
3791
+ .trigger {
3792
+ position: fixed;
3793
+ transform: scale(0);
3794
+ box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
3795
+ bottom: 20px;
3796
+ right: 20px;
3797
+ z-index: 5;
3798
+ display: flex;
3799
+ align-items: center;
3800
+ justify-content: center;
3801
+ border: none;
3802
+ line-height: 55px;
3803
+ height: 55px;
3804
+ width: 55px;
3805
+ border-radius: 55px;
3806
+ cursor: pointer;
3807
+ background-color: #990ae3;
3808
+ font-family: Lato;
3809
+ text-decoration: none;
3810
+ border: 3px dashed transparent;
3811
+ box-sizing: border-box;
3812
+ transition: transform 200ms ease-out;
3813
+ }
3814
+ .trigger:hover {
3815
+ transform: scale(1.1) !important;
3816
+ }
3817
+ .trigger.rendered {
3818
+ transform: scale(1);
3819
+ }
3820
+ .trigger.active .trigger-icon {
3821
+ opacity: 0;
3822
+ transform: rotate(-180deg) scale(0);
3823
+ }
3824
+ .trigger.active .trigger-close {
3825
+ opacity: 1;
3826
+ transform: rotate(0deg) scale(1);
3827
+ }
3828
+
3829
+ .trigger-icon {
3830
+ display: inline-block;
3831
+ line-height: inherit;
3832
+ text-align: center;
3833
+ opacity: 1;
3834
+ transform: rotate(0deg) scale(1);
3835
+ transition:
3836
+ opacity 200ms ease-out,
3837
+ transform 200ms ease-out;
3838
+ color: #ffffff;
3839
+ }
3840
+ .trigger-close {
3841
+ opacity: 0;
3842
+ transition: transform 200ms ease-out;
3843
+ transform: rotate(180deg) scale(0);
3844
+ position: absolute;
3845
+ top: 0;
3846
+ bottom: 0;
3847
+ left: 0;
3848
+ right: 0;
3849
+ display: flex;
3850
+ justify-content: center;
3851
+ align-items: center;
3852
+ fill: #ffffff;
3853
+ }
3854
+ `
3855
+ ];
3856
+ $e([
3857
+ Ir({ attribute: !1 })
3858
+ ], lt.prototype, "symbol", 2);
3859
+ $e([
3860
+ nn()
3861
+ ], lt.prototype, "active", 2);
3862
+ $e([
3863
+ nn()
3864
+ ], lt.prototype, "loaded", 2);
3865
+ $e([
3866
+ nn()
3867
+ ], lt.prototype, "icon", 2);
3868
+ var vt = /* @__PURE__ */ ((n) => (n.Inline = "inline", n.Link = "link", n.Badge = "badge", n.Unsupported = "unsupported", n))(vt || {});
3869
+ const Po = (n, t) => n && t ? "both" : n ? "widgetDOM" : t ? "triggerDOM" : "none", Hr = (n) => n ? typeof n == "boolean" && n ? "link" : typeof n == "object" && !Array.isArray(n) ? "badge" : "unsupported" : "inline", Co = (n, t, e, r, s = !1) => Q(void 0, null, function* () {
3870
+ var h, l;
3871
+ const i = Po(
3088
3872
  t,
3089
3873
  e
3090
- ), o = Tn(r), a = {
3874
+ ), o = Hr(r), a = {
3091
3875
  widgetDOMElement: t ? t.cloneNode(!0) : void 0,
3092
3876
  triggerDOMElement: e ? e.cloneNode(!0) : void 0
3093
3877
  }, c = {
@@ -3102,44 +3886,49 @@ const ni = (n, t) => n && t ? "both" : n ? "widgetDOM" : t ? "triggerDOM" : "non
3102
3886
  }
3103
3887
  case "widgetDOM": {
3104
3888
  if (c.widgetDOMElement = t || document.createElement("div"), o !== "inline") {
3105
- const l = document.body.appendChild(document.createElement("a"));
3106
- o === "link" && (l.innerText = n), c.triggerDOMElement = l;
3889
+ const u = document.body.appendChild(
3890
+ document.createElement("a")
3891
+ );
3892
+ o === "link" && (u.innerText = n), c.triggerDOMElement = u;
3107
3893
  }
3108
3894
  break;
3109
3895
  }
3110
3896
  case "triggerDOM": {
3111
- const l = document.createElement("div");
3112
- c.widgetDOMElement = l, o === "inline" ? (l.id = (e == null ? void 0 : e.id) || "", s ? (l.style.display = "none", (h = e == null ? void 0 : e.parentNode) == null || h.appendChild(l), c.callback = () => {
3897
+ const u = document.createElement("div");
3898
+ c.widgetDOMElement = u, o === "inline" ? (u.id = (e == null ? void 0 : e.id) || "", s ? (u.style.display = "none", (h = e == null ? void 0 : e.parentNode) == null || h.appendChild(u), c.callback = () => {
3113
3899
  var d;
3114
3900
  (d = e == null ? void 0 : e.parentNode) == null || d.replaceChild(
3115
- l,
3901
+ u,
3116
3902
  e
3117
- ), l.style.display = (e == null ? void 0 : e.style.display) || "block";
3118
- }) : (u = e == null ? void 0 : e.parentNode) == null || u.replaceChild(
3119
- l,
3903
+ ), u.style.display = (e == null ? void 0 : e.style.display) || "block";
3904
+ }) : (l = e == null ? void 0 : e.parentNode) == null || l.replaceChild(
3905
+ u,
3120
3906
  e
3121
- ), c.cachedOriginals.widgetDOMElement = e, c.cachedOriginals.triggerDOMElement = void 0) : (c.widgetDOMElement = document.body.appendChild(l), c.triggerDOMElement = e);
3907
+ ), c.cachedOriginals.widgetDOMElement = e, c.cachedOriginals.triggerDOMElement = void 0) : (c.widgetDOMElement = document.body.appendChild(u), c.triggerDOMElement = e);
3122
3908
  break;
3123
3909
  }
3124
3910
  case "none": {
3125
- const l = document.body.appendChild(document.createElement("div"));
3126
- if (c.widgetDOMElement = l, o !== "inline") {
3127
- const d = document.body.appendChild(document.createElement("a"));
3128
- o === "link" && (d.innerText = n), c.triggerDOMElement = d;
3911
+ const u = document.body.appendChild(
3912
+ document.createElement("div")
3913
+ );
3914
+ if (c.widgetDOMElement = u, o !== "inline") {
3915
+ customElements.get("ace-widget-trigger") || customElements.define("ace-widget-trigger", lt);
3916
+ const d = document.createElement("ace-widget-trigger");
3917
+ d.symbol = r.symbol, document.body.appendChild(d), console.log("Created trigger"), c.triggerDOMElement = d;
3129
3918
  }
3130
3919
  break;
3131
3920
  }
3132
3921
  }
3133
3922
  return c;
3134
- }, si = "modals";
3135
- class ii {
3923
+ }), ko = "modals";
3924
+ class No {
3136
3925
  constructor(t, e) {
3137
3926
  this.options = e, this.unsubscribe = [], this.container = t.createChild(this), this.container.register("widgetDOMElement", this.options.widgetDOMElement), this.container.register(
3138
3927
  "triggerDOMElement",
3139
3928
  this.options.triggerDOMElement
3140
3929
  );
3141
3930
  const r = this.container.get("$widget");
3142
- this.options.widgetDOMElement.classList.add("humany-widget"), this.options.widgetDOMElement.classList.add(`humany_${r.name}`);
3931
+ this.options.widgetDOMElement.classList.add("ace-widget"), this.options.widgetDOMElement.classList.add(`ace-widget_${r.name}`);
3143
3932
  const s = t.get("widgetDOMElements") || [];
3144
3933
  t.register("widgetDOMElements", [
3145
3934
  ...s,
@@ -3151,16 +3940,16 @@ class ii {
3151
3940
  */
3152
3941
  render() {
3153
3942
  const { widgetDOMElement: t, triggerDOMElement: e } = this.options, r = this.container.get("$widget");
3154
- return t.getAttribute("data-rendered") === "true" ? Promise.resolve() : (e && this.options.triggerType === ut.Badge && ei(e), import("./render-301f6791.js").then((s) => s.default(this.container, t)).then(() => {
3155
- if (t.setAttribute("data-rendered", "true"), e && this.options.triggerType === ut.Badge) {
3943
+ return t.getAttribute("data-rendered") === "true" ? Promise.resolve() : (e && this.options.triggerType === vt.Badge && ro(e), import("./render-f8a2aadc.js").then((s) => s.default(this.container, t)).then(() => {
3944
+ if (t.setAttribute("data-rendered", "true"), e && this.options.triggerType === vt.Badge) {
3156
3945
  const i = this.options.triggerOptions.openTooltip;
3157
- Rn(e, i);
3946
+ Nr(e, i);
3158
3947
  }
3159
- nr(this.container, t);
3948
+ is(this.container, t);
3160
3949
  const s = this.container.get("$environment").widgets.all();
3161
- q(
3950
+ Y(
3162
3951
  this.container,
3163
- si,
3952
+ ko,
3164
3953
  S.Session
3165
3954
  ).then((i) => {
3166
3955
  i && i.forEach((o) => {
@@ -3178,17 +3967,17 @@ class ii {
3178
3967
  e.getAttribute("role") || e.setAttribute("role", "button");
3179
3968
  const { name: r } = this.container.get("$widget"), { label: s, symbol: i, ariaLabel: o, closedTooltip: a, openTooltip: c } = t, h = { closedTooltip: a, openTooltip: c };
3180
3969
  this.options.triggerOptions = h;
3181
- const u = Xs(e, {
3970
+ const l = eo(e, {
3182
3971
  label: s,
3183
3972
  symbol: i,
3184
3973
  ariaLabel: o,
3185
3974
  widgetName: r,
3186
3975
  tooltip: a
3187
3976
  });
3188
- this.unsubscribe.push(u);
3977
+ this.unsubscribe.push(l);
3189
3978
  }
3190
3979
  dispose() {
3191
- return Zt(this, null, function* () {
3980
+ return Q(this, null, function* () {
3192
3981
  var r, s, i, o;
3193
3982
  const { triggerDOMElement: t, widgetDOMElement: e } = this.options;
3194
3983
  this.options.cachedOriginals.widgetDOMElement && e && ((r = e.parentNode) == null || r.replaceChild(
@@ -3203,44 +3992,44 @@ class ii {
3203
3992
  });
3204
3993
  }
3205
3994
  }
3206
- const Nt = "changesets", oi = (n) => {
3995
+ const Yt = "changesets", Mo = (n) => {
3207
3996
  const t = { tags: n.tags };
3208
3997
  return n.context && typeof n.context != "function" && (t.context = n.context), n.properties && typeof n.properties != "function" && (t.properties = n.properties), n.layout && typeof n.layout != "function" && (t.layout = n.layout), t;
3209
3998
  };
3210
- class Oe {
3999
+ class rn {
3211
4000
  constructor(t, e) {
3212
4001
  this.container = t, this.storageWriter = e;
3213
4002
  }
3214
4003
  static create(t) {
3215
- return X(
4004
+ return et(
3216
4005
  t,
3217
- Nt,
3218
- k.Necessary,
4006
+ Yt,
4007
+ P.Necessary,
3219
4008
  {
3220
4009
  medium: S.Local
3221
4010
  }
3222
4011
  ).then(
3223
- (e) => new Oe(t, e)
4012
+ (e) => new rn(t, e)
3224
4013
  );
3225
4014
  }
3226
4015
  write(t, e, r, s) {
3227
- return G(this)(() => q(
4016
+ return Z(this)(() => Y(
3228
4017
  this.container,
3229
- Nt,
4018
+ Yt,
3230
4019
  S.Local
3231
4020
  ).then((i = {}) => {
3232
4021
  const { keys: o = [], items: a = {} } = i, c = o.indexOf(t);
3233
4022
  return c > -1 && o.splice(c, 1), o.push(t), a[t] = {
3234
4023
  options: s,
3235
- attributes: oi(r),
4024
+ attributes: Mo(r),
3236
4025
  rules: e.rules
3237
4026
  }, this.storageWriter({ keys: o, items: a });
3238
4027
  }));
3239
4028
  }
3240
4029
  remove(t) {
3241
- return G(this)(() => q(
4030
+ return Z(this)(() => Y(
3242
4031
  this.container,
3243
- Nt,
4032
+ Yt,
3244
4033
  S.Local
3245
4034
  ).then((e = {}) => {
3246
4035
  const { keys: r = [], items: s = {} } = e, i = r.indexOf(t);
@@ -3249,9 +4038,9 @@ class Oe {
3249
4038
  }));
3250
4039
  }
3251
4040
  load(t) {
3252
- return G(this)(() => q(
4041
+ return Z(this)(() => Y(
3253
4042
  this.container,
3254
- Nt,
4043
+ Yt,
3255
4044
  S.Local
3256
4045
  ).then((e = {}) => {
3257
4046
  const { keys: r = [], items: s = {} } = e;
@@ -3262,27 +4051,27 @@ class Oe {
3262
4051
  t.write({
3263
4052
  attributes: c,
3264
4053
  options: h,
3265
- target: new yt(t, a)
4054
+ target: new Pt(t, a)
3266
4055
  });
3267
4056
  }
3268
4057
  });
3269
4058
  }));
3270
4059
  }
3271
4060
  }
3272
- const ai = (n) => {
4061
+ const Lo = (n) => {
3273
4062
  const { container: t } = n;
3274
- return Oe.create(t).then(
4063
+ return rn.create(t).then(
3275
4064
  (e) => {
3276
- const r = t.get("$settings"), s = { localStorage: e }, i = new qt(n, s), o = cn(i, r);
4065
+ const r = t.get("$settings"), s = { localStorage: e }, i = new me(n, s), o = nr(i, r);
3277
4066
  return n.events.subscribe(
3278
4067
  "widget:state-change",
3279
4068
  (a, c) => {
3280
- c.state === nn.Deactivating && o();
4069
+ c.state === Zn.Deactivating && o();
3281
4070
  }
3282
4071
  ), i;
3283
4072
  }
3284
4073
  );
3285
- }, ci = (n) => Promise.resolve().then(() => Fs).then(
4074
+ }, Do = (n) => Promise.resolve().then(() => Ki).then(
3286
4075
  ({ RoutingService: t, HistoryMode: e }) => n.get("settings").then((r) => {
3287
4076
  const {
3288
4077
  routing: {
@@ -3302,8 +4091,8 @@ const ai = (n) => {
3302
4091
  basePath: o
3303
4092
  });
3304
4093
  })
3305
- ), hi = (n) => Promise.resolve().then(() => rs).then(({ StorageProvider: t }) => new t()), ui = (n) => Promise.resolve().then(() => me).then(({ ActionResolver: t }) => new t(n)), li = (n) => Promise.resolve().then(() => me).then(({ ComponentResolver: t }) => new t(n)), di = (n) => Promise.resolve().then(() => me).then(() => ai(n.get("$widget"))), ue = "$settings", Lt = "open", tn = "activeStickyWidget";
3306
- class Ai extends Kn {
4094
+ ), To = (n) => Promise.resolve().then(() => oi).then(({ StorageProvider: t }) => new t()), jo = (n) => Promise.resolve().then(() => Ye).then(({ ActionResolver: t }) => new t(n)), Ro = (n) => Promise.resolve().then(() => Ye).then(({ ComponentResolver: t }) => new t(n)), Io = (n) => Promise.resolve().then(() => Ye).then(() => Lo(n.get("$widget"))), Ue = "$settings", Gt = "open", Yn = "activeStickyWidget";
4095
+ class oa extends Gr {
3307
4096
  constructor(t) {
3308
4097
  super(t), this.outlets = /* @__PURE__ */ new Map(), this.activated = void 0, this.subs = [], this.handleBootstrapping = (e) => {
3309
4098
  const r = {
@@ -3319,23 +4108,23 @@ class Ai extends Kn {
3319
4108
  });
3320
4109
  }, this.container.registerAsync(
3321
4110
  "storage",
3322
- () => hi(this.container)
3323
- ), this.container.registerFactory("settings", () => q(
4111
+ () => To(this.container)
4112
+ ), this.container.registerFactory("settings", () => Y(
3324
4113
  this.container,
3325
- ue,
4114
+ Ue,
3326
4115
  S.Local
3327
- ).then((e = {}) => dt(dt({}, this.container.get("$settings")), e))), Gs(this, "load", this.handleBootstrapping), this.container.registerAsync(
4116
+ ).then((e = {}) => st(st({}, this.container.get("$settings")), e))), Xi(this, "load", this.handleBootstrapping), this.container.registerAsync(
3328
4117
  "componentResolver",
3329
- () => li(this.container)
4118
+ () => Ro(this.container)
3330
4119
  ), this.container.registerAsync(
3331
4120
  "router",
3332
- () => ci(this.container)
4121
+ () => Do(this.container)
3333
4122
  ), this.container.registerAsync(
3334
4123
  "actionResolver",
3335
- () => ui(this.container)
4124
+ () => jo(this.container)
3336
4125
  ), this.container.register("matchMedia", window.matchMedia), this.container.registerAsync(
3337
4126
  "components",
3338
- () => di(this.container)
4127
+ () => Io(this.container)
3339
4128
  );
3340
4129
  }
3341
4130
  initialize() {
@@ -3349,28 +4138,28 @@ class Ai extends Kn {
3349
4138
  var h;
3350
4139
  r.subscribe(
3351
4140
  this.widget.name,
3352
- (u, l, d) => this.onAction(l, d)
4141
+ (l, u, d) => this.onAction(u, d)
3353
4142
  );
3354
- const a = (u) => {
3355
- i.nodes.query({ type: "view" }).forEach((l) => {
3356
- i.setSwitch(l, u);
4143
+ const a = (l) => {
4144
+ i.nodes.query({ type: "view" }).forEach((u) => {
4145
+ i.setSwitch(u, l);
3357
4146
  });
3358
4147
  }, c = ((h = s.getInitialRoute()) == null ? void 0 : h.name) || "index";
3359
- return a(c), this.events.subscribe("widget:data-loaded", (u, { element: l }) => {
4148
+ return a(c), this.events.subscribe("widget:data-loaded", (l, { element: u }) => {
3360
4149
  this.widget.container.get("seoConfiguration") && this.events.dispatch("widget:preloaded-replaced", {
3361
- element: l
4150
+ element: u
3362
4151
  });
3363
4152
  }), this.events.subscribe(
3364
4153
  "router:change",
3365
- (u, { previous: l = { routeData: {} }, next: d = { routeData: {} } }) => {
3366
- const { routeData: f } = l, { routeData: g } = d, E = Object.keys(o.views).reduce(
3367
- (p, C) => typeof o.views[C].path == "undefined" ? C : p,
4154
+ (l, { previous: u = { routeData: {} }, next: d = { routeData: {} } }) => {
4155
+ const { routeData: p } = u, { routeData: b } = d, v = Object.keys(o.views).reduce(
4156
+ (g, E) => typeof o.views[E].path == "undefined" ? E : g,
3368
4157
  ""
3369
4158
  );
3370
- !g.name && E ? a(E) : a(g.name), lt(f && f.params), lt(g && g.params), this.container.getAsync("actionResolver").then((p) => {
3371
- p.action(this.widget.name, "routeChange", {
3372
- next: g,
3373
- previous: f
4159
+ !b.name && v ? a(v) : a(b.name), yt(p && p.params), yt(b && b.params), this.container.getAsync("actionResolver").then((g) => {
4160
+ g.action(this.widget.name, "routeChange", {
4161
+ next: b,
4162
+ previous: p
3374
4163
  });
3375
4164
  });
3376
4165
  }
@@ -3379,63 +4168,63 @@ class Ai extends Kn {
3379
4168
  );
3380
4169
  }
3381
4170
  attach(t = {}) {
3382
- return this.container.get("settings").then(({ trigger: e }) => {
3383
- var d, f;
4171
+ return this.container.get("settings").then((r) => Q(this, [r], function* ({ trigger: e }) {
4172
+ var p, b;
3384
4173
  const {
3385
- widgetDOMElement: r,
3386
- key: s = Pt(),
3387
- triggerDOMElement: i,
3388
- withRenderState: o
3389
- } = t, c = Tn(e) === ut.Inline && ((i == null ? void 0 : i.childElementCount) || 0) > 0, h = ri(
4174
+ widgetDOMElement: s,
4175
+ key: i = Bt(),
4176
+ triggerDOMElement: o,
4177
+ withRenderState: a
4178
+ } = t, h = Hr(e) === vt.Inline && ((o == null ? void 0 : o.childElementCount) || 0) > 0, l = yield Co(
3390
4179
  this.widget.name,
3391
- r,
3392
- i,
4180
+ s,
4181
+ o,
3393
4182
  e,
3394
- c
4183
+ h
3395
4184
  );
3396
- this.outlets.size < 1 && !o && this.setRenderState("unset");
4185
+ this.outlets.size < 1 && !a && this.setRenderState("unset");
3397
4186
  const u = () => {
3398
- const g = () => E.querySelectorAll("[data-loading=true]").length === 0, [E] = this.widget.container.get("widgetDOMElements"), p = (U, _) => {
3399
- g() && (h.callback && h.callback(), _.disconnect());
3400
- }, C = {
4187
+ const v = () => g.querySelectorAll("[data-loading=true]").length === 0, [g] = this.widget.container.get("widgetDOMElements"), E = (H, k) => {
4188
+ v() && (l.callback && l.callback(), k.disconnect());
4189
+ }, j = {
3401
4190
  attributes: !0,
3402
4191
  subtree: !0,
3403
4192
  childList: !0
3404
4193
  };
3405
- g() && h.callback && h.callback(), new MutationObserver(p).observe(E, C);
4194
+ v() && l.callback && l.callback(), new MutationObserver(E).observe(g, j);
3406
4195
  };
3407
- c && this.widget.container.getAsync("dataClient").then(({ events: g }) => {
3408
- g.subscribe(
4196
+ h && this.widget.container.getAsync("dataClient").then(({ events: v }) => {
4197
+ v.subscribe(
3409
4198
  "data-client:fetched",
3410
- (E, p) => {
3411
- p.unresolvedQueries === 0 && u();
4199
+ (g, E) => {
4200
+ E.unresolvedQueries === 0 && u();
3412
4201
  }
3413
4202
  );
3414
4203
  });
3415
- const l = this.getOrCreateViewOutlet(s, h);
3416
- if (this.outlets.set(s, l), this.widget.events.dispatch("widget:attached", {}, { bubbles: !0 }), h.triggerType === ut.Badge && e && ((d = h.triggerDOMElement) == null || d.setAttribute(
4204
+ const d = this.getOrCreateViewOutlet(i, l);
4205
+ if (this.outlets.set(i, d), this.widget.events.dispatch("widget:attached", {}, { bubbles: !0 }), l.triggerType === vt.Badge && e && ((p = l.triggerDOMElement) == null || p.setAttribute(
3417
4206
  "aria-expanded",
3418
4207
  "false"
3419
- ), l == null || l.renderBadge(e)), h.triggerType !== ut.Inline && ((f = h.triggerDOMElement) == null || f.addEventListener(
4208
+ ), d == null || d.renderBadge(e)), l.triggerType !== vt.Inline && ((b = l.triggerDOMElement) == null || b.addEventListener(
3420
4209
  "click",
3421
- (g) => {
3422
- g.preventDefault(), this.container.get("settings").then(({ trigger: E }) => {
3423
- l.render().then(() => this.renderState()).then((p) => E && E.action && E.action === "hide" ? p === z.open ? this.hide() : this.open() : p === z.open ? this.close() : this.open());
4210
+ (v) => {
4211
+ v.preventDefault(), this.container.get("settings").then(({ trigger: g }) => {
4212
+ d.render().then(() => this.renderState()).then((E) => g && g.action && g.action === "hide" ? E === F.open ? this.hide() : this.open() : E === F.open ? this.close() : this.open());
3424
4213
  });
3425
4214
  }
3426
4215
  )), this.outlets.size > 1)
3427
- return this.renderState().then((g) => {
3428
- this.triggerStateIfApplicable(g);
4216
+ return this.renderState().then((v) => {
4217
+ this.triggerStateIfApplicable(v);
3429
4218
  });
3430
- if (o)
3431
- return o === "storage" ? this.renderState().then((g) => {
3432
- if (h.triggerType === ut.Inline) {
4219
+ if (a)
4220
+ return a === "storage" ? this.renderState().then((v) => {
4221
+ if (l.triggerType === vt.Inline) {
3433
4222
  this.triggerStateIfApplicable("open");
3434
4223
  return;
3435
4224
  }
3436
- this.triggerStateIfApplicable(g);
3437
- }) : this.triggerStateIfApplicable(o);
3438
- });
4225
+ this.triggerStateIfApplicable(v);
4226
+ }) : this.triggerStateIfApplicable(a);
4227
+ }));
3439
4228
  }
3440
4229
  detach(t) {
3441
4230
  if (t) {
@@ -3469,13 +4258,13 @@ class Ai extends Kn {
3469
4258
  });
3470
4259
  }
3471
4260
  getOrCreateViewOutlet(t, e) {
3472
- return this.outlets.has(t) ? this.outlets.get(t) : new ii(this.container, e);
4261
+ return this.outlets.has(t) ? this.outlets.get(t) : new No(this.container, e);
3473
4262
  }
3474
4263
  render(t = {}) {
3475
4264
  if (process.env.NODE_ENV !== "production" && console.warn(
3476
4265
  "widget.render() is deprecated. Use widget.attach() instead."
3477
4266
  ), t.open) {
3478
- const e = Pe(dt({}, t), {
4267
+ const e = zt(st({}, t), {
3479
4268
  withRenderState: "open"
3480
4269
  /* Open */
3481
4270
  });
@@ -3492,24 +4281,24 @@ class Ai extends Kn {
3492
4281
  setSettings(t) {
3493
4282
  return Promise.all([
3494
4283
  this.container.get("settings"),
3495
- X(
4284
+ et(
3496
4285
  this.container,
3497
- ue,
3498
- k.Necessary,
4286
+ Ue,
4287
+ P.Necessary,
3499
4288
  {
3500
4289
  medium: S.Local
3501
4290
  }
3502
4291
  )
3503
4292
  ]).then(([e, r]) => Promise.resolve(t(e)).then((s) => r(s).then(() => {
3504
- const i = dt(dt({}, e), s);
4293
+ const i = st(st({}, e), s);
3505
4294
  return this.widget.events.dispatch("widget:settings-updated", i), i;
3506
4295
  })));
3507
4296
  }
3508
4297
  clearSettings() {
3509
- return X(
4298
+ return et(
3510
4299
  this.container,
3511
- ue,
3512
- k.Necessary,
4300
+ Ue,
4301
+ P.Necessary,
3513
4302
  { medium: S.Local }
3514
4303
  ).then((t) => t()).then(() => this.container.get("settings")).then((t) => {
3515
4304
  this.widget.events.dispatch("widget:settings-updated", t);
@@ -3521,18 +4310,18 @@ class Ai extends Kn {
3521
4310
  });
3522
4311
  }
3523
4312
  renderState() {
3524
- if (we(this.container))
3525
- return Promise.resolve(z.open);
3526
- const t = () => q(
4313
+ if (Xe(this.container))
4314
+ return Promise.resolve(F.open);
4315
+ const t = () => Y(
3527
4316
  this.container,
3528
- Lt,
4317
+ Gt,
3529
4318
  S.Session
3530
- ).then((r = z.closed) => r), e = () => q(
4319
+ ).then((r = F.closed) => r), e = () => Y(
3531
4320
  this.container,
3532
- Lt,
4321
+ Gt,
3533
4322
  S.Session
3534
- ).then((r = z.closed) => r);
3535
- return this.container.getAsync("router").then((r) => r.isSticky() ? e().then((s) => s === z.open ? s : t()) : t());
4323
+ ).then((r = F.closed) => r);
4324
+ return this.container.getAsync("router").then((r) => r.isSticky() ? e().then((s) => s === F.open ? s : t()) : t());
3536
4325
  }
3537
4326
  hide() {
3538
4327
  return this.outlets.size < 1 ? (process.env.NODE_ENV !== "production" && console.warn(
@@ -3561,9 +4350,9 @@ class Ai extends Kn {
3561
4350
  case "close":
3562
4351
  case "open":
3563
4352
  case "hide":
3564
- const r = t === "open" ? z.open : t === "close" ? z.closed : z.hidden;
4353
+ const r = t === "open" ? F.open : t === "close" ? F.closed : F.hidden;
3565
4354
  return this.setRenderState(r).then(() => {
3566
- this.setTriggerState(r === z.open), r !== z.hidden ? r === z.open ? this.onOpen() : this.onClose() : this.outlets.forEach(
4355
+ this.setTriggerState(r === F.open), r !== F.hidden ? r === F.open ? this.onOpen() : this.onClose() : this.outlets.forEach(
3567
4356
  (s) => {
3568
4357
  var i;
3569
4358
  return (i = s.options.triggerDOMElement) == null ? void 0 : i.setAttribute(
@@ -3578,18 +4367,18 @@ class Ai extends Kn {
3578
4367
  setRenderState(t) {
3579
4368
  const { invoke: e, events: r } = this.container.get("$widget");
3580
4369
  return Promise.all([
3581
- X(
4370
+ et(
3582
4371
  this.container,
3583
- Lt,
3584
- k.Necessary,
4372
+ Gt,
4373
+ P.Necessary,
3585
4374
  {
3586
4375
  medium: S.Session
3587
4376
  }
3588
4377
  ),
3589
- X(
4378
+ et(
3590
4379
  this.container,
3591
- Lt,
3592
- k.Necessary,
4380
+ Gt,
4381
+ P.Necessary,
3593
4382
  {
3594
4383
  medium: S.Local,
3595
4384
  duration: { minutes: 5 }
@@ -3654,23 +4443,23 @@ class Ai extends Kn {
3654
4443
  const {
3655
4444
  options: { triggerDOMElement: r, triggerOptions: s }
3656
4445
  } = e, { openTooltip: i, closedTooltip: o } = s || {};
3657
- r && (t ? Rn(r, i) : ti(r, o));
4446
+ r && (t ? Nr(r, i) : no(r, o));
3658
4447
  });
3659
4448
  }
3660
4449
  deactivate() {
3661
4450
  this.subs.forEach((e) => e());
3662
4451
  const t = [];
3663
- return this.outlets.forEach((e) => t.push(e.dispose())), q(
4452
+ return this.outlets.forEach((e) => t.push(e.dispose())), Y(
3664
4453
  this.container,
3665
- tn,
4454
+ Yn,
3666
4455
  S.Local
3667
- ).then((e) => e === this.widget.name ? X(
4456
+ ).then((e) => e === this.widget.name ? et(
3668
4457
  this.container,
3669
- tn,
3670
- k.Necessary,
4458
+ Yn,
4459
+ P.Necessary,
3671
4460
  {
3672
4461
  medium: S.Local,
3673
- scope: vt.Implementation
4462
+ scope: Ct.Implementation
3674
4463
  }
3675
4464
  ).then((r) => r()).then(() => Promise.all(t)) : Promise.all(t));
3676
4465
  }
@@ -3680,7 +4469,7 @@ class Ai extends Kn {
3680
4469
  * Copyright 2021 Google LLC
3681
4470
  * SPDX-License-Identifier: BSD-3-Clause
3682
4471
  */
3683
- let pi = class extends Event {
4472
+ let Ho = class extends Event {
3684
4473
  constructor(t, e, r) {
3685
4474
  super("context-request", { bubbles: !0, composed: !0 }), this.context = t, this.callback = e, this.subscribe = r != null && r;
3686
4475
  }
@@ -3695,7 +4484,7 @@ let pi = class extends Event {
3695
4484
  * Copyright 2021 Google LLC
3696
4485
  * SPDX-License-Identifier: BSD-3-Clause
3697
4486
  */
3698
- class en {
4487
+ class Gn {
3699
4488
  constructor(t, e, r, s) {
3700
4489
  var i;
3701
4490
  if (this.subscribe = !1, this.provided = !1, this.value = void 0, this.t = (o, a) => {
@@ -3714,22 +4503,22 @@ class en {
3714
4503
  this.unsubscribe && (this.unsubscribe(), this.unsubscribe = void 0);
3715
4504
  }
3716
4505
  dispatchRequest() {
3717
- this.host.dispatchEvent(new pi(this.context, this.t, this.subscribe));
4506
+ this.host.dispatchEvent(new Ho(this.context, this.t, this.subscribe));
3718
4507
  }
3719
4508
  }
3720
- const Li = "children", fi = "descriptor", gi = "container", Mi = "context", Di = "layout", ji = "properties";
3721
- class _i {
4509
+ const ca = "children", Uo = "descriptor", Bo = "container", ha = "context", la = "layout", ua = "properties";
4510
+ class da {
3722
4511
  constructor(t) {
3723
- (this.host = t).addController(this), new en(
4512
+ (this.host = t).addController(this), new Gn(
3724
4513
  t,
3725
- gi,
4514
+ Bo,
3726
4515
  (e) => {
3727
4516
  this._container = e, this.host.requestUpdate();
3728
4517
  },
3729
4518
  !0
3730
- ), new en(
4519
+ ), new Gn(
3731
4520
  t,
3732
- fi,
4521
+ Uo,
3733
4522
  (e) => {
3734
4523
  this._descriptor = e, this.host.requestUpdate();
3735
4524
  },
@@ -3741,37 +4530,46 @@ class _i {
3741
4530
  hostDisconnected() {
3742
4531
  }
3743
4532
  dispatch(t, e) {
3744
- return Zt(this, null, function* () {
4533
+ return Q(this, null, function* () {
3745
4534
  if (!this._container || !this._descriptor)
3746
4535
  return;
3747
- const r = yield qt.getInstance(
4536
+ const r = yield me.getInstance(
3748
4537
  this._container
3749
- ), s = new yt(r).withId(
4538
+ ), s = new Pt(r).withId(
3750
4539
  this._descriptor.id
3751
4540
  );
3752
4541
  yield r.actions(
3753
4542
  s,
3754
- this._descriptor.type || Pt()
4543
+ this._descriptor.type || Bt()
3755
4544
  ).dispatch(t, e);
3756
4545
  });
3757
4546
  }
3758
4547
  }
3759
- const Ii = (n, t, e, r, s) => n.getAsync("componentResolver").then((i) => (i.registerComponent(t, e), hn(n, t, r || (() => {
4548
+ const pa = (n, t, e, r, s) => n.getAsync("componentResolver").then((i) => (i.registerComponent(t, e), rr(n, t, r || (() => {
3760
4549
  }), t, s)));
3761
4550
  export {
3762
- _i as A,
3763
- Or as E,
3764
- Ai as W,
3765
- en as a,
3766
- Mi as b,
3767
- Li as c,
3768
- fi as d,
3769
- qt as e,
3770
- gi as f,
3771
- Ii as g,
3772
- Di as l,
3773
- z as m,
3774
- ji as p,
3775
- pi as s
4551
+ T as A,
4552
+ As as E,
4553
+ oa as W,
4554
+ Gn as a,
4555
+ jt as b,
4556
+ Bo as c,
4557
+ io as d,
4558
+ Eo as e,
4559
+ nn as f,
4560
+ Uo as g,
4561
+ ca as h,
4562
+ Ao as i,
4563
+ ua as j,
4564
+ ha as k,
4565
+ la as l,
4566
+ F as m,
4567
+ Ir as n,
4568
+ da as o,
4569
+ me as p,
4570
+ pa as q,
4571
+ Ho as s,
4572
+ Oo as t,
4573
+ Kt as x
3776
4574
  };
3777
- //# sourceMappingURL=index-8c63c0e1.js.map
4575
+ //# sourceMappingURL=index-3f142f67.js.map