@telia-ace/widget-conversation-flamingo 1.0.8 → 1.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/conversation/conversation.d.ts +3 -6
- package/dist/components/conversation/conversation.d.ts.map +1 -1
- package/dist/conversation-d6641d26.js +2281 -0
- package/dist/conversation-d6641d26.js.map +1 -0
- package/dist/{index-7f99bf14.js → index-1d35e98e.js} +1170 -940
- package/dist/index-1d35e98e.js.map +1 -0
- package/dist/index.js +1 -1
- package/package.json +2 -2
- package/dist/conversation-cb14062a.js +0 -2358
- package/dist/conversation-cb14062a.js.map +0 -1
- package/dist/index-7f99bf14.js.map +0 -1
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
1
|
+
var Fn = Object.defineProperty, Kn = Object.defineProperties;
|
|
2
|
+
var Qn = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var Ot = Object.getOwnPropertySymbols;
|
|
4
|
+
var gs = Object.prototype.hasOwnProperty, ms = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var ps = (s, t, e) => t in s ? Fn(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, P = (s, t) => {
|
|
6
6
|
for (var e in t || (t = {}))
|
|
7
|
-
|
|
8
|
-
if (
|
|
9
|
-
for (var e of
|
|
10
|
-
|
|
7
|
+
gs.call(t, e) && ps(s, e, t[e]);
|
|
8
|
+
if (Ot)
|
|
9
|
+
for (var e of Ot(t))
|
|
10
|
+
ms.call(t, e) && ps(s, e, t[e]);
|
|
11
11
|
return s;
|
|
12
|
-
}, R = (s, t) =>
|
|
13
|
-
var
|
|
12
|
+
}, R = (s, t) => Kn(s, Qn(t));
|
|
13
|
+
var vs = (s, t) => {
|
|
14
14
|
var e = {};
|
|
15
15
|
for (var n in s)
|
|
16
|
-
|
|
17
|
-
if (s != null &&
|
|
18
|
-
for (var n of
|
|
19
|
-
t.indexOf(n) < 0 &&
|
|
16
|
+
gs.call(s, n) && t.indexOf(n) < 0 && (e[n] = s[n]);
|
|
17
|
+
if (s != null && Ot)
|
|
18
|
+
for (var n of Ot(s))
|
|
19
|
+
t.indexOf(n) < 0 && ms.call(s, n) && (e[n] = s[n]);
|
|
20
20
|
return e;
|
|
21
21
|
};
|
|
22
22
|
var w = (s, t, e) => new Promise((n, i) => {
|
|
@@ -35,7 +35,7 @@ var w = (s, t, e) => new Promise((n, i) => {
|
|
|
35
35
|
}, a = (c) => c.done ? n(c.value) : Promise.resolve(c.value).then(r, o);
|
|
36
36
|
a((e = e.apply(s, t)).next());
|
|
37
37
|
});
|
|
38
|
-
const
|
|
38
|
+
const ce = (s, t, e, ...n) => {
|
|
39
39
|
const i = `[${s.get("$environment").name || "webprovisions"}] ${e}`;
|
|
40
40
|
switch (t) {
|
|
41
41
|
case "info":
|
|
@@ -48,16 +48,16 @@ const ne = (s, t, e, ...n) => {
|
|
|
48
48
|
console.error(i, ...n);
|
|
49
49
|
break;
|
|
50
50
|
}
|
|
51
|
-
},
|
|
51
|
+
}, Yn = (s) => {
|
|
52
52
|
const t = s.container || s;
|
|
53
53
|
return {
|
|
54
|
-
info: (e, ...n) =>
|
|
55
|
-
warn: (e, ...n) =>
|
|
56
|
-
error: (e, ...n) =>
|
|
54
|
+
info: (e, ...n) => ce(t, "info", e, ...n),
|
|
55
|
+
warn: (e, ...n) => ce(t, "warning", e, ...n),
|
|
56
|
+
error: (e, ...n) => ce(t, "error", e, ...n)
|
|
57
57
|
};
|
|
58
58
|
};
|
|
59
|
-
var
|
|
60
|
-
const
|
|
59
|
+
var $t = /* @__PURE__ */ ((s) => (s.Implementation = "implementation", s.Widget = "widget", s))($t || {}), V = /* @__PURE__ */ ((s) => (s.Pre = "pre", s.Post = "post", s))(V || {});
|
|
60
|
+
const Zn = (s, t, e, n) => {
|
|
61
61
|
try {
|
|
62
62
|
const i = new t(e, n);
|
|
63
63
|
return {
|
|
@@ -81,23 +81,23 @@ const qn = (s, t, e, n) => {
|
|
|
81
81
|
throw i;
|
|
82
82
|
}
|
|
83
83
|
};
|
|
84
|
-
function
|
|
84
|
+
function fs(s, t) {
|
|
85
85
|
return typeof s == "undefined" ? t : s;
|
|
86
86
|
}
|
|
87
|
-
let
|
|
87
|
+
let Gn = class {
|
|
88
88
|
constructor(t = {}) {
|
|
89
89
|
this.part = t;
|
|
90
90
|
}
|
|
91
91
|
createCommand(t, e, n) {
|
|
92
92
|
let i;
|
|
93
93
|
typeof e == "function" ? i = {
|
|
94
|
-
scope:
|
|
95
|
-
stage:
|
|
94
|
+
scope: $t.Widget,
|
|
95
|
+
stage: V.Post,
|
|
96
96
|
defaultArgs: void 0,
|
|
97
97
|
handlerResolver: e
|
|
98
98
|
} : i = {
|
|
99
|
-
scope:
|
|
100
|
-
stage:
|
|
99
|
+
scope: fs(e.scope, $t.Widget),
|
|
100
|
+
stage: fs(e.stage, V.Post),
|
|
101
101
|
defaultArgs: e.defaultArgs,
|
|
102
102
|
handlerResolver: n
|
|
103
103
|
};
|
|
@@ -111,26 +111,26 @@ let Fn = class {
|
|
|
111
111
|
return this.part;
|
|
112
112
|
}
|
|
113
113
|
};
|
|
114
|
-
const
|
|
115
|
-
const t = new
|
|
114
|
+
const ln = (s) => {
|
|
115
|
+
const t = new Gn({});
|
|
116
116
|
return s(t), t.get();
|
|
117
117
|
};
|
|
118
|
-
|
|
118
|
+
ln((s) => {
|
|
119
119
|
s.createCommand(
|
|
120
120
|
"types.register",
|
|
121
|
-
{ scope:
|
|
121
|
+
{ scope: $t.Implementation, stage: V.Pre },
|
|
122
122
|
(t) => (e, n) => {
|
|
123
123
|
t.container.get("$types")[e] = n;
|
|
124
124
|
}
|
|
125
125
|
).createCommand(
|
|
126
126
|
"type",
|
|
127
|
-
{ stage:
|
|
127
|
+
{ stage: V.Pre },
|
|
128
128
|
(t) => (e) => {
|
|
129
129
|
t.container.register("$type", e);
|
|
130
130
|
}
|
|
131
131
|
).createCommand(
|
|
132
132
|
"settings",
|
|
133
|
-
{ stage:
|
|
133
|
+
{ stage: V.Pre, defaultArgs: [null] },
|
|
134
134
|
(t) => (e) => {
|
|
135
135
|
t.events.dispatch(
|
|
136
136
|
"settings:change",
|
|
@@ -140,7 +140,7 @@ sn((s) => {
|
|
|
140
140
|
}
|
|
141
141
|
).createCommand(
|
|
142
142
|
"plugin",
|
|
143
|
-
{ stage:
|
|
143
|
+
{ stage: V.Pre },
|
|
144
144
|
(t) => (e, n, i) => {
|
|
145
145
|
const { container: r } = t;
|
|
146
146
|
let o = null, a = e, c = n;
|
|
@@ -153,7 +153,7 @@ sn((s) => {
|
|
|
153
153
|
a
|
|
154
154
|
) : n;
|
|
155
155
|
try {
|
|
156
|
-
const u =
|
|
156
|
+
const u = Zn(
|
|
157
157
|
o,
|
|
158
158
|
a,
|
|
159
159
|
r,
|
|
@@ -161,7 +161,7 @@ sn((s) => {
|
|
|
161
161
|
);
|
|
162
162
|
r.get("$plugins").push(u), l && u.invoke("initialize", null);
|
|
163
163
|
} catch (u) {
|
|
164
|
-
|
|
164
|
+
Yn(t).warn("Error when initializing plugin", u);
|
|
165
165
|
}
|
|
166
166
|
};
|
|
167
167
|
t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
|
|
@@ -194,10 +194,10 @@ sn((s) => {
|
|
|
194
194
|
}
|
|
195
195
|
);
|
|
196
196
|
});
|
|
197
|
-
const
|
|
197
|
+
const Xn = ln((s) => {
|
|
198
198
|
s.createCommand(
|
|
199
199
|
"ready",
|
|
200
|
-
{ scope:
|
|
200
|
+
{ scope: $t.Implementation, stage: V.Pre },
|
|
201
201
|
(t) => (e) => {
|
|
202
202
|
const { container: n } = t, i = n.owner;
|
|
203
203
|
n.get("bootstrapping").ready ? e(i) : i.events.subscribeOnce("bootstrap:ready", () => {
|
|
@@ -205,11 +205,11 @@ const Kn = sn((s) => {
|
|
|
205
205
|
});
|
|
206
206
|
}
|
|
207
207
|
);
|
|
208
|
-
}),
|
|
209
|
-
function
|
|
210
|
-
return (s) => (
|
|
208
|
+
}), he = /* @__PURE__ */ new WeakMap();
|
|
209
|
+
function dt() {
|
|
210
|
+
return (s) => (he.has(s) || he.set(s, {}), he.get(s));
|
|
211
211
|
}
|
|
212
|
-
const
|
|
212
|
+
const le = (s, t, e, ...n) => {
|
|
213
213
|
const i = `[${s.get("$environment").name || "webprovisions"}] ${e}`;
|
|
214
214
|
switch (t) {
|
|
215
215
|
case "info":
|
|
@@ -222,46 +222,46 @@ const re = (s, t, e, ...n) => {
|
|
|
222
222
|
console.error(i, ...n);
|
|
223
223
|
break;
|
|
224
224
|
}
|
|
225
|
-
},
|
|
225
|
+
}, C = (s) => {
|
|
226
226
|
const t = s.container || s;
|
|
227
227
|
return {
|
|
228
|
-
info: (e, ...n) =>
|
|
229
|
-
warn: (e, ...n) =>
|
|
230
|
-
error: (e, ...n) =>
|
|
228
|
+
info: (e, ...n) => le(t, "info", e, ...n),
|
|
229
|
+
warn: (e, ...n) => le(t, "warning", e, ...n),
|
|
230
|
+
error: (e, ...n) => le(t, "error", e, ...n)
|
|
231
231
|
};
|
|
232
|
-
}, f =
|
|
232
|
+
}, f = dt(), Be = (() => {
|
|
233
233
|
let s = 0;
|
|
234
234
|
return () => ++s;
|
|
235
|
-
})(),
|
|
235
|
+
})(), Je = (s, t, e) => {
|
|
236
236
|
const n = f(s).touchQueue.get(t);
|
|
237
237
|
n && n.forEach((i) => {
|
|
238
238
|
i(e, s);
|
|
239
239
|
});
|
|
240
240
|
};
|
|
241
|
-
let
|
|
241
|
+
let ti = class {
|
|
242
242
|
constructor(t, e, n, i) {
|
|
243
|
-
this.key = t, this.factory = e, this.parent = n, this.container = i, this.id =
|
|
243
|
+
this.key = t, this.factory = e, this.parent = n, this.container = i, this.id = Be(), this.resolved = !1, this.constructed = !1, this.async = !0;
|
|
244
244
|
}
|
|
245
245
|
resolve() {
|
|
246
246
|
if (!this.constructed) {
|
|
247
247
|
const t = this.factory(this.parent, this.container);
|
|
248
|
-
return this.constructed = !0, this.value = Promise.resolve(t).then((e) => (this.resolved = !0,
|
|
248
|
+
return this.constructed = !0, this.value = Promise.resolve(t).then((e) => (this.resolved = !0, Je(this.container, this.key, e), e));
|
|
249
249
|
}
|
|
250
250
|
return this.value;
|
|
251
251
|
}
|
|
252
|
-
},
|
|
252
|
+
}, ei = class {
|
|
253
253
|
constructor(t, e, n, i) {
|
|
254
|
-
this.key = t, this.value = e, this.parent = n, this.container = i, this.id =
|
|
254
|
+
this.key = t, this.value = e, this.parent = n, this.container = i, this.id = Be(), this.async = !1, this.resolved = !1, this.constructed = !0, this.resolve = () => (this.resolved = !0, Je(this.container, this.key, this.value), this.value);
|
|
255
255
|
}
|
|
256
|
-
},
|
|
256
|
+
}, si = class {
|
|
257
257
|
constructor(t, e, n, i) {
|
|
258
|
-
this.key = t, this.value = e, this.parent = n, this.container = i, this.id =
|
|
258
|
+
this.key = t, this.value = e, this.parent = n, this.container = i, this.id = Be(), this.async = !1, this.resolved = !1, this.constructed = !1, this.resolve = () => {
|
|
259
259
|
this.resolved = !0, this.constructed = !0;
|
|
260
260
|
const r = this.value(this.parent, this.container);
|
|
261
|
-
return
|
|
261
|
+
return Je(this.container, this.key, this.value), r;
|
|
262
262
|
};
|
|
263
263
|
}
|
|
264
|
-
},
|
|
264
|
+
}, ni = class dn {
|
|
265
265
|
/**
|
|
266
266
|
* Creates a new instance of `Container`.
|
|
267
267
|
* @param owner The object owning this inctance.
|
|
@@ -328,8 +328,8 @@ let Qn = class {
|
|
|
328
328
|
*/
|
|
329
329
|
registerAsync(t, e) {
|
|
330
330
|
const n = f(this).resolvers.get(t);
|
|
331
|
-
n && !n.async && process.env.NODE_ENV !== "production" &&
|
|
332
|
-
const i = new
|
|
331
|
+
n && !n.async && process.env.NODE_ENV !== "production" && C(this).warn(`Mismatching resolver type. You are registering an async resolver with a key ('${t}') previously used by a non-async resolver.`);
|
|
332
|
+
const i = new ti(t, e, n, this);
|
|
333
333
|
return f(this).resolvers.set(t, i), i.id;
|
|
334
334
|
}
|
|
335
335
|
/**
|
|
@@ -339,8 +339,8 @@ let Qn = class {
|
|
|
339
339
|
*/
|
|
340
340
|
registerFactory(t, e) {
|
|
341
341
|
const n = f(this).resolvers.get(t);
|
|
342
|
-
n && n.async && process.env.NODE_ENV !== "production" &&
|
|
343
|
-
const i = new
|
|
342
|
+
n && n.async && process.env.NODE_ENV !== "production" && C(this).warn(`Mismatching resolver type. You are registering a non-async resolver with a key ('${t}') previously used by an async resolver.`);
|
|
343
|
+
const i = new si(t, e, n, this);
|
|
344
344
|
return f(this).resolvers.set(t, i), i.id;
|
|
345
345
|
}
|
|
346
346
|
/**
|
|
@@ -350,8 +350,8 @@ let Qn = class {
|
|
|
350
350
|
*/
|
|
351
351
|
register(t, e) {
|
|
352
352
|
const n = f(this).resolvers.get(t);
|
|
353
|
-
n && n.async && process.env.NODE_ENV !== "production" &&
|
|
354
|
-
const i = new
|
|
353
|
+
n && n.async && process.env.NODE_ENV !== "production" && C(this).warn(`Mismatching resolver type. You are registering a non-async resolver with a key ('${t}') previously used by an async resolver.`);
|
|
354
|
+
const i = new ei(t, e, n, this);
|
|
355
355
|
return f(this).resolvers.set(t, i), i.id;
|
|
356
356
|
}
|
|
357
357
|
/**
|
|
@@ -361,7 +361,7 @@ let Qn = class {
|
|
|
361
361
|
get(t) {
|
|
362
362
|
const e = f(this).resolvers.get(t);
|
|
363
363
|
if (e)
|
|
364
|
-
return e.async && process.env.NODE_ENV !== "production" &&
|
|
364
|
+
return e.async && process.env.NODE_ENV !== "production" && C(this).warn(`You are retrieving an async value (with key '${t}') by the non-async function 'container.get(key)'. This will not be supported in future versions. Use 'container.getAsync(key) instead.'`), e.resolve();
|
|
365
365
|
if (this.parent)
|
|
366
366
|
return this.parent.get(t);
|
|
367
367
|
}
|
|
@@ -373,7 +373,7 @@ let Qn = class {
|
|
|
373
373
|
const e = f(this).resolvers.get(t);
|
|
374
374
|
if (e) {
|
|
375
375
|
if (!e.async)
|
|
376
|
-
throw process.env.NODE_ENV !== "production" &&
|
|
376
|
+
throw process.env.NODE_ENV !== "production" && C(this).warn(`You are retrieving a non-async value (with key '${t}') by the async function 'container.getAsync(key)'.Use 'container.get(key) instead.'`), "Mismatching resolver type";
|
|
377
377
|
return e.resolve();
|
|
378
378
|
}
|
|
379
379
|
return this.parent ? this.parent.getAsync(t) : Promise.resolve(void 0);
|
|
@@ -387,10 +387,10 @@ let Qn = class {
|
|
|
387
387
|
return Promise.all(t.map((n) => this.getAsync(n).then((i) => e[n] = i))).then(() => e);
|
|
388
388
|
}
|
|
389
389
|
createChild(t, e) {
|
|
390
|
-
const n = new
|
|
390
|
+
const n = new dn(t, e, this);
|
|
391
391
|
return f(this).children.push(n), n;
|
|
392
392
|
}
|
|
393
|
-
},
|
|
393
|
+
}, ys = class {
|
|
394
394
|
/**
|
|
395
395
|
*
|
|
396
396
|
* @param type Type of event.
|
|
@@ -408,34 +408,34 @@ let Qn = class {
|
|
|
408
408
|
this.cancelable && (this.defaultPrevented = !0);
|
|
409
409
|
}
|
|
410
410
|
};
|
|
411
|
-
const
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
),
|
|
411
|
+
const N = dt(), bs = (s, t) => [].concat(
|
|
412
|
+
N(s).listenerLookup.get(t.toLowerCase()) || [],
|
|
413
|
+
N(s).listenerLookup.get("*") || []
|
|
414
|
+
), ws = (s, t, e, n) => {
|
|
415
415
|
let i, r;
|
|
416
|
-
return t instanceof
|
|
416
|
+
return t instanceof ys ? (i = t, r = t.type) : (i = new ys(t, s.target, !!e.cancelable, !!e.bubbles), r = t), { event: i, type: r, async: n };
|
|
417
417
|
};
|
|
418
|
-
let
|
|
418
|
+
let ii = class un {
|
|
419
419
|
/**
|
|
420
420
|
* Creates a new Event Manager instance.
|
|
421
421
|
* @param target The target of events dispatched from this Event Manager instance.
|
|
422
422
|
* @param parent Parent Event Manager instance.
|
|
423
423
|
*/
|
|
424
424
|
constructor(t, e) {
|
|
425
|
-
this.target = t, this.parent = e,
|
|
425
|
+
this.target = t, this.parent = e, N(this).listenerLookup = /* @__PURE__ */ new Map(), N(this).children = [];
|
|
426
426
|
}
|
|
427
427
|
/**
|
|
428
428
|
* Clears registered event listeners in this `EventManager` as well as in any children.
|
|
429
429
|
*/
|
|
430
430
|
clear() {
|
|
431
|
-
|
|
431
|
+
N(this).listenerLookup.clear(), N(this).children.forEach((t) => t.clear());
|
|
432
432
|
}
|
|
433
433
|
/**
|
|
434
434
|
* Detaches this `EventManager` instance from its parent, allowing it to be garbage-collected.
|
|
435
435
|
*/
|
|
436
436
|
detach() {
|
|
437
437
|
if (this.parent) {
|
|
438
|
-
const t =
|
|
438
|
+
const t = N(this.parent).children, e = t.indexOf(this);
|
|
439
439
|
e > -1 && t.splice(e, 1);
|
|
440
440
|
}
|
|
441
441
|
}
|
|
@@ -445,7 +445,7 @@ let Xn = class rn {
|
|
|
445
445
|
* @param listener Listener for the event.
|
|
446
446
|
*/
|
|
447
447
|
subscribe(t, e, n) {
|
|
448
|
-
const i =
|
|
448
|
+
const i = N(this).listenerLookup, r = t.toLowerCase();
|
|
449
449
|
return i.has(r) || i.set(r, []), i.get(r).push(e), () => this.unsubscribe(t, e);
|
|
450
450
|
}
|
|
451
451
|
/**
|
|
@@ -462,7 +462,7 @@ let Xn = class rn {
|
|
|
462
462
|
* @param listener Event listener to remove.
|
|
463
463
|
*/
|
|
464
464
|
unsubscribe(t, e) {
|
|
465
|
-
const n =
|
|
465
|
+
const n = N(this).listenerLookup.get(t.toLowerCase());
|
|
466
466
|
if (n) {
|
|
467
467
|
const i = n.indexOf(e);
|
|
468
468
|
i > -1 && n.splice(i, 1);
|
|
@@ -475,7 +475,7 @@ let Xn = class rn {
|
|
|
475
475
|
* @param options Optional event options used if first parameter is an event type.
|
|
476
476
|
*/
|
|
477
477
|
dispatchAsync(t, e, n = {}) {
|
|
478
|
-
const { event: i, type: r } =
|
|
478
|
+
const { event: i, type: r } = ws(this, t, n, !0), o = bs(this, r);
|
|
479
479
|
let a = 0;
|
|
480
480
|
const c = o.length;
|
|
481
481
|
let h = Promise.resolve();
|
|
@@ -492,7 +492,7 @@ let Xn = class rn {
|
|
|
492
492
|
* @param options Optional event options used if first parameter is an event type.
|
|
493
493
|
*/
|
|
494
494
|
dispatch(t, e, n = {}) {
|
|
495
|
-
const { event: i, type: r } =
|
|
495
|
+
const { event: i, type: r } = ws(this, t, n, !1), o = bs(this, r);
|
|
496
496
|
let a = 0;
|
|
497
497
|
const c = o.length;
|
|
498
498
|
let h = !1;
|
|
@@ -507,37 +507,37 @@ let Xn = class rn {
|
|
|
507
507
|
* Creates a child instance to the current Event manager.
|
|
508
508
|
*/
|
|
509
509
|
createChild(t) {
|
|
510
|
-
const e = new
|
|
511
|
-
return
|
|
510
|
+
const e = new un(t, this);
|
|
511
|
+
return N(this).children.push(e), e;
|
|
512
512
|
}
|
|
513
513
|
};
|
|
514
|
-
const
|
|
514
|
+
const St = (s, t, e) => {
|
|
515
515
|
const n = s.get("$plugins").map((i) => {
|
|
516
516
|
try {
|
|
517
517
|
return i.invoke(t, e);
|
|
518
518
|
} catch (r) {
|
|
519
|
-
|
|
519
|
+
C(s).error("An error occured when invoking a plugin.", i, r);
|
|
520
520
|
}
|
|
521
521
|
});
|
|
522
522
|
return Promise.all(n);
|
|
523
523
|
};
|
|
524
|
-
let
|
|
524
|
+
let ri = class {
|
|
525
525
|
constructor(t) {
|
|
526
526
|
this.widget = t.get("$widget"), this.events = this.widget.events, this.container = this.widget.container, this.initialized = null, this.activated = null, this.initialize = this.initialize.bind(this), this.activate = this.activate.bind(this), this.deactivate = this.deactivate.bind(this), this.invoke = this.invoke.bind(this), this.createInstance();
|
|
527
527
|
}
|
|
528
528
|
createInstance() {
|
|
529
529
|
if (!this.widget.container.get("$instance")) {
|
|
530
530
|
const t = this.widget.container.get("$types"), e = this.widget.container.get("$type");
|
|
531
|
-
!e &&
|
|
531
|
+
!e && C(this).error("Unable to create widget. No type is specified.");
|
|
532
532
|
const n = t[e];
|
|
533
|
-
!n &&
|
|
533
|
+
!n && C(this).error(`Unable to create widget. Type '${e}' is not registered.`), this.widget.events.dispatch("widget:create-instance", {}, { bubbles: !0 });
|
|
534
534
|
try {
|
|
535
535
|
this.widget.container.register(
|
|
536
536
|
"$instance",
|
|
537
537
|
new n(this.container)
|
|
538
538
|
);
|
|
539
539
|
} catch (i) {
|
|
540
|
-
|
|
540
|
+
C(this).error("Unable to create widget type.", i);
|
|
541
541
|
}
|
|
542
542
|
this.widget.events.dispatch("widget:instance-created", {}, { bubbles: !0 });
|
|
543
543
|
}
|
|
@@ -552,7 +552,7 @@ let ti = class {
|
|
|
552
552
|
return this.initialized = this.initialized || (() => {
|
|
553
553
|
const e = this.container.get("$instance"), n = e.initialize || (() => {
|
|
554
554
|
});
|
|
555
|
-
return this.initialized = Promise.resolve(n.call(e, t)).then(() =>
|
|
555
|
+
return this.initialized = Promise.resolve(n.call(e, t)).then(() => St(this.container, "initialize", t)).then(() => {
|
|
556
556
|
});
|
|
557
557
|
})();
|
|
558
558
|
}
|
|
@@ -564,7 +564,7 @@ let ti = class {
|
|
|
564
564
|
*/
|
|
565
565
|
activate(t) {
|
|
566
566
|
return (this.initialized || this.initialize()).then(() => {
|
|
567
|
-
this.activated = this.activated || (() =>
|
|
567
|
+
this.activated = this.activated || (() => St(this.container, "activate").then(() => {
|
|
568
568
|
const e = this.container.get("$instance");
|
|
569
569
|
return this.activated = e.activate(t);
|
|
570
570
|
}))();
|
|
@@ -573,7 +573,7 @@ let ti = class {
|
|
|
573
573
|
deactivate() {
|
|
574
574
|
const t = this.container.get("$instance"), e = t.deactivate || (() => {
|
|
575
575
|
});
|
|
576
|
-
return
|
|
576
|
+
return St(this.container, "deactivate").then(() => Promise.resolve(e.call(t))).then(() => {
|
|
577
577
|
this.initialized = null, this.activated = null;
|
|
578
578
|
}).then(() => {
|
|
579
579
|
});
|
|
@@ -584,7 +584,7 @@ let ti = class {
|
|
|
584
584
|
* @param args Command arguments
|
|
585
585
|
*/
|
|
586
586
|
invoke(t, ...e) {
|
|
587
|
-
return
|
|
587
|
+
return St(this.container, "invoke", { command: t, args: e }).then(() => {
|
|
588
588
|
const n = this.container.get("$instance");
|
|
589
589
|
if (n[t])
|
|
590
590
|
return n[t].apply(n, e);
|
|
@@ -594,7 +594,7 @@ let ti = class {
|
|
|
594
594
|
});
|
|
595
595
|
}
|
|
596
596
|
};
|
|
597
|
-
const
|
|
597
|
+
const rt = (s, t) => {
|
|
598
598
|
if (!t)
|
|
599
599
|
return !0;
|
|
600
600
|
if (typeof t == "string") {
|
|
@@ -606,30 +606,30 @@ const st = (s, t) => {
|
|
|
606
606
|
}
|
|
607
607
|
}
|
|
608
608
|
return t instanceof Array ? t.indexOf(s) > -1 : !1;
|
|
609
|
-
},
|
|
609
|
+
}, oi = (s, t) => {
|
|
610
610
|
if (typeof t == "function")
|
|
611
611
|
return t(s);
|
|
612
|
-
const e = typeof t == "string" ?
|
|
613
|
-
return !(!
|
|
614
|
-
},
|
|
612
|
+
const e = typeof t == "string" ? hi(t) : t;
|
|
613
|
+
return !(!rt(s.implementation.tenant || "", e.tenant || "") || !rt(s.implementation.name, e.implementation || "") || !rt(s.name, e.widget || "") || !rt(s.container.get("$type"), e.type || ""));
|
|
614
|
+
}, ai = (s, t) => {
|
|
615
615
|
if (typeof t == "function")
|
|
616
616
|
return t(s);
|
|
617
|
-
const e = typeof t == "string" ?
|
|
618
|
-
return !(!
|
|
619
|
-
},
|
|
617
|
+
const e = typeof t == "string" ? li(t) : t;
|
|
618
|
+
return !(!rt(s.tenant || "", e.tenant || "") || !rt(s.name, e.implementation || ""));
|
|
619
|
+
}, pn = (s) => (t) => oi(t, s), ci = (s) => (t) => ai(t, s), j = (s) => s instanceof Array && s.length === 1 ? s[0] : s, hi = (s) => {
|
|
620
620
|
const t = {}, e = s.split(":");
|
|
621
|
-
return e.length === 1 ? t.widget =
|
|
622
|
-
},
|
|
621
|
+
return e.length === 1 ? t.widget = j(e[0].split(",")) : e.length === 2 ? (t.implementation = j(e[0].split(",")), t.widget = j(e[1].split(","))) : (t.tenant = j(e[0].split(",")), t.implementation = j(e[1].split(",")), t.widget = j(e[2].split(","))), t;
|
|
622
|
+
}, li = (s) => {
|
|
623
623
|
const t = {}, e = s.split(":");
|
|
624
|
-
return e.length === 1 ? t.implementation =
|
|
625
|
-
},
|
|
626
|
-
function
|
|
624
|
+
return e.length === 1 ? t.implementation = j(e[0].split(",")) : (t.tenant = j(e[0].split(",")), t.implementation = j(e[1].split(","))), t;
|
|
625
|
+
}, Rt = dt(), $s = (s, t, e) => s.filter((n) => n.stage === t && pn(n.selector)(e));
|
|
626
|
+
function di(s) {
|
|
627
627
|
const t = s.container.get("$environment");
|
|
628
|
-
let e =
|
|
629
|
-
e && (e = e.filter((n) => n[0] !== s),
|
|
628
|
+
let e = Rt(t).configurationCache;
|
|
629
|
+
e && (e = e.filter((n) => n[0] !== s), Rt(t).configurationCache = e);
|
|
630
630
|
}
|
|
631
|
-
var
|
|
632
|
-
const
|
|
631
|
+
var Wt = /* @__PURE__ */ ((s) => (s.Implementation = "implementation", s.Widget = "widget", s))(Wt || {}), D = /* @__PURE__ */ ((s) => (s.Pre = "pre", s.Post = "post", s))(D || {});
|
|
632
|
+
const gn = (s, t, e) => (Object.keys(t).forEach((n) => {
|
|
633
633
|
const i = t[n];
|
|
634
634
|
if (typeof i == "function") {
|
|
635
635
|
const r = i();
|
|
@@ -642,20 +642,20 @@ const an = (s, t, e) => (Object.keys(t).forEach((n) => {
|
|
|
642
642
|
return e(a, ...o), s;
|
|
643
643
|
};
|
|
644
644
|
} else
|
|
645
|
-
s[n] =
|
|
645
|
+
s[n] = gn(
|
|
646
646
|
{},
|
|
647
647
|
i,
|
|
648
648
|
e
|
|
649
649
|
);
|
|
650
|
-
}), s),
|
|
650
|
+
}), s), ui = (s, t) => {
|
|
651
651
|
switch (t) {
|
|
652
652
|
case "implementation":
|
|
653
653
|
return s.implementation;
|
|
654
654
|
case "widget":
|
|
655
655
|
return s;
|
|
656
656
|
}
|
|
657
|
-
},
|
|
658
|
-
|
|
657
|
+
}, xs = (s, t, e, n) => (n.forEach((i) => {
|
|
658
|
+
gn(
|
|
659
659
|
s,
|
|
660
660
|
i,
|
|
661
661
|
(r, ...o) => {
|
|
@@ -663,32 +663,32 @@ const an = (s, t, e) => (Object.keys(t).forEach((n) => {
|
|
|
663
663
|
selector: t,
|
|
664
664
|
stage: r.stage,
|
|
665
665
|
handler: (c) => {
|
|
666
|
-
const h =
|
|
667
|
-
let u =
|
|
668
|
-
return u || (u =
|
|
666
|
+
const h = ui(c, r.scope), l = { container: h.container, events: h.events }, d = r.handlerResolver, p = d(l);
|
|
667
|
+
let u = Rt(e.environment).configurationCache;
|
|
668
|
+
return u || (u = Rt(e.environment).configurationCache = []), u.find((g) => g.indexOf(h) > -1 && g.indexOf(d) > -1) ? Promise.resolve() : (u.push([h, d]), Promise.resolve(p(...o)));
|
|
669
669
|
}
|
|
670
670
|
};
|
|
671
671
|
e.instructions.push(a);
|
|
672
672
|
}
|
|
673
673
|
);
|
|
674
674
|
}), s);
|
|
675
|
-
function
|
|
675
|
+
function pi(s, t) {
|
|
676
676
|
function e(n) {
|
|
677
|
-
return
|
|
677
|
+
return xs(
|
|
678
678
|
{},
|
|
679
679
|
n,
|
|
680
680
|
s,
|
|
681
681
|
t
|
|
682
682
|
);
|
|
683
683
|
}
|
|
684
|
-
return
|
|
684
|
+
return xs(
|
|
685
685
|
e,
|
|
686
686
|
"*",
|
|
687
687
|
s,
|
|
688
688
|
t
|
|
689
689
|
);
|
|
690
690
|
}
|
|
691
|
-
const
|
|
691
|
+
const gi = (s, t, e, n) => {
|
|
692
692
|
try {
|
|
693
693
|
const i = new t(e, n);
|
|
694
694
|
return {
|
|
@@ -712,23 +712,23 @@ const hi = (s, t, e, n) => {
|
|
|
712
712
|
throw i;
|
|
713
713
|
}
|
|
714
714
|
};
|
|
715
|
-
function
|
|
715
|
+
function _s(s, t) {
|
|
716
716
|
return typeof s == "undefined" ? t : s;
|
|
717
717
|
}
|
|
718
|
-
let
|
|
718
|
+
let mi = class {
|
|
719
719
|
constructor(t = {}) {
|
|
720
720
|
this.part = t;
|
|
721
721
|
}
|
|
722
722
|
createCommand(t, e, n) {
|
|
723
723
|
let i;
|
|
724
724
|
typeof e == "function" ? i = {
|
|
725
|
-
scope:
|
|
726
|
-
stage:
|
|
725
|
+
scope: Wt.Widget,
|
|
726
|
+
stage: D.Post,
|
|
727
727
|
defaultArgs: void 0,
|
|
728
728
|
handlerResolver: e
|
|
729
729
|
} : i = {
|
|
730
|
-
scope:
|
|
731
|
-
stage:
|
|
730
|
+
scope: _s(e.scope, Wt.Widget),
|
|
731
|
+
stage: _s(e.stage, D.Post),
|
|
732
732
|
defaultArgs: e.defaultArgs,
|
|
733
733
|
handlerResolver: n
|
|
734
734
|
};
|
|
@@ -742,25 +742,25 @@ let li = class {
|
|
|
742
742
|
return this.part;
|
|
743
743
|
}
|
|
744
744
|
};
|
|
745
|
-
const
|
|
746
|
-
const t = new
|
|
745
|
+
const mn = (s) => {
|
|
746
|
+
const t = new mi({});
|
|
747
747
|
return s(t), t.get();
|
|
748
|
-
},
|
|
748
|
+
}, vi = mn((s) => {
|
|
749
749
|
s.createCommand(
|
|
750
750
|
"types.register",
|
|
751
|
-
{ scope:
|
|
751
|
+
{ scope: Wt.Implementation, stage: D.Pre },
|
|
752
752
|
(t) => (e, n) => {
|
|
753
753
|
t.container.get("$types")[e] = n;
|
|
754
754
|
}
|
|
755
755
|
).createCommand(
|
|
756
756
|
"type",
|
|
757
|
-
{ stage:
|
|
757
|
+
{ stage: D.Pre },
|
|
758
758
|
(t) => (e) => {
|
|
759
759
|
t.container.register("$type", e);
|
|
760
760
|
}
|
|
761
761
|
).createCommand(
|
|
762
762
|
"settings",
|
|
763
|
-
{ stage:
|
|
763
|
+
{ stage: D.Pre, defaultArgs: [null] },
|
|
764
764
|
(t) => (e) => {
|
|
765
765
|
t.events.dispatch(
|
|
766
766
|
"settings:change",
|
|
@@ -770,7 +770,7 @@ const cn = (s) => {
|
|
|
770
770
|
}
|
|
771
771
|
).createCommand(
|
|
772
772
|
"plugin",
|
|
773
|
-
{ stage:
|
|
773
|
+
{ stage: D.Pre },
|
|
774
774
|
(t) => (e, n, i) => {
|
|
775
775
|
const { container: r } = t;
|
|
776
776
|
let o = null, a = e, c = n;
|
|
@@ -783,7 +783,7 @@ const cn = (s) => {
|
|
|
783
783
|
a
|
|
784
784
|
) : n;
|
|
785
785
|
try {
|
|
786
|
-
const u =
|
|
786
|
+
const u = gi(
|
|
787
787
|
o,
|
|
788
788
|
a,
|
|
789
789
|
r,
|
|
@@ -791,7 +791,7 @@ const cn = (s) => {
|
|
|
791
791
|
);
|
|
792
792
|
r.get("$plugins").push(u), l && u.invoke("initialize", null);
|
|
793
793
|
} catch (u) {
|
|
794
|
-
|
|
794
|
+
C(t).warn("Error when initializing plugin", u);
|
|
795
795
|
}
|
|
796
796
|
};
|
|
797
797
|
t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
|
|
@@ -823,15 +823,15 @@ const cn = (s) => {
|
|
|
823
823
|
t.container.register("csp", e);
|
|
824
824
|
}
|
|
825
825
|
);
|
|
826
|
-
}),
|
|
827
|
-
function
|
|
828
|
-
const n = [
|
|
826
|
+
}), fi = vi;
|
|
827
|
+
function yi(s, t, e = []) {
|
|
828
|
+
const n = [fi].concat(e), i = pi(
|
|
829
829
|
t,
|
|
830
830
|
n
|
|
831
831
|
);
|
|
832
832
|
s(i, t);
|
|
833
833
|
}
|
|
834
|
-
let
|
|
834
|
+
let bi = class {
|
|
835
835
|
constructor() {
|
|
836
836
|
this.tasks = [], this.current = Promise.resolve(), this.next = this.next.bind(this);
|
|
837
837
|
}
|
|
@@ -851,22 +851,22 @@ let gi = class {
|
|
|
851
851
|
});
|
|
852
852
|
}
|
|
853
853
|
};
|
|
854
|
-
const
|
|
855
|
-
function
|
|
856
|
-
return
|
|
857
|
-
const i =
|
|
854
|
+
const Nt = /* @__PURE__ */ new WeakMap();
|
|
855
|
+
function wi(s) {
|
|
856
|
+
return Nt.has(s) || Nt.set(s, new bi()), (t) => new Promise((e, n) => {
|
|
857
|
+
const i = Nt.get(s);
|
|
858
858
|
i.add(t, e, n, () => {
|
|
859
|
-
i.tasks.length ||
|
|
859
|
+
i.tasks.length || Nt.delete(s);
|
|
860
860
|
});
|
|
861
861
|
});
|
|
862
862
|
}
|
|
863
|
-
const
|
|
863
|
+
const Ps = (s) => typeof s != "undefined", gt = (s, t) => {
|
|
864
864
|
s.events.dispatch("widget:state-change", { state: t }, { bubbles: !0 }), s.state = t, s.events.dispatch("widget:state-changed", {}, { bubbles: !0 });
|
|
865
|
-
},
|
|
865
|
+
}, S = dt(), $i = (s) => {
|
|
866
866
|
const { container: t, events: e } = s;
|
|
867
|
-
t.get("$controller") || (t.register("$controller", new
|
|
867
|
+
t.get("$controller") || (t.register("$controller", new ri(t)), e.dispatch("widget:controller-created", {}, { bubbles: !0 }));
|
|
868
868
|
};
|
|
869
|
-
let
|
|
869
|
+
let xi = class {
|
|
870
870
|
/**
|
|
871
871
|
* Creates a new `Widget` instance.
|
|
872
872
|
* @param name Name of widget.
|
|
@@ -874,9 +874,9 @@ let fi = class {
|
|
|
874
874
|
* @param configuration Configuration for the widget.
|
|
875
875
|
*/
|
|
876
876
|
constructor(t, e, n) {
|
|
877
|
-
this.state = "deactivated", this.name = t, this.implementation = e, this.container = e.container.createChild(this, t), this.events = e.events.createChild(this),
|
|
877
|
+
this.state = "deactivated", this.name = t, this.implementation = e, this.container = e.container.createChild(this, t), this.events = e.events.createChild(this), S(this).subscriptions = [], n && e.configure((i) => {
|
|
878
878
|
const r = i(t);
|
|
879
|
-
|
|
879
|
+
Ps(n.type) && r.type(n.type), Ps(n.settings) && r.settings(n.settings), n.plugins && Object.keys(n.plugins).forEach((o) => {
|
|
880
880
|
var a;
|
|
881
881
|
const c = (a = n.plugins) == null ? void 0 : a[o];
|
|
882
882
|
r.plugin(o, c);
|
|
@@ -888,26 +888,26 @@ let fi = class {
|
|
|
888
888
|
* pending configuration.
|
|
889
889
|
*/
|
|
890
890
|
load() {
|
|
891
|
-
return
|
|
892
|
-
|
|
891
|
+
return wi(this)(() => {
|
|
892
|
+
S(this).deactivatedPromise = null;
|
|
893
893
|
const t = this.state === "deactivated";
|
|
894
|
-
t && (
|
|
894
|
+
t && (gt(
|
|
895
895
|
this,
|
|
896
896
|
"activating"
|
|
897
897
|
/* Activating */
|
|
898
|
-
), this.container.register("$widget", this), this.container.register("$controller", null), this.container.register("$plugins", []), this.container.register("$type", null), this.container.register("$instance", null)),
|
|
898
|
+
), this.container.register("$widget", this), this.container.register("$controller", null), this.container.register("$plugins", []), this.container.register("$type", null), this.container.register("$instance", null)), gt(
|
|
899
899
|
this,
|
|
900
900
|
"loading"
|
|
901
901
|
/* Loading */
|
|
902
902
|
);
|
|
903
|
-
const e = this.implementation.instructions, n =
|
|
903
|
+
const e = this.implementation.instructions, n = $s(e, D.Pre, this);
|
|
904
904
|
return Promise.all(n.map((i) => i.handler(this))).then(() => {
|
|
905
|
-
|
|
906
|
-
const i =
|
|
905
|
+
$i(this);
|
|
906
|
+
const i = $s(e, D.Post, this);
|
|
907
907
|
return Promise.all(i.map((r) => r.handler(this))).then(() => {
|
|
908
908
|
t && this.container.get("$controller").initialize();
|
|
909
909
|
});
|
|
910
|
-
}).then(() => (
|
|
910
|
+
}).then(() => (gt(
|
|
911
911
|
this,
|
|
912
912
|
"activated"
|
|
913
913
|
/* Activated */
|
|
@@ -919,7 +919,7 @@ let fi = class {
|
|
|
919
919
|
* @param data Activation data
|
|
920
920
|
*/
|
|
921
921
|
activate(t) {
|
|
922
|
-
|
|
922
|
+
S(this).subscriptions.push(
|
|
923
923
|
this.implementation.events.subscribe("implementation:configured", () => {
|
|
924
924
|
[
|
|
925
925
|
"activated",
|
|
@@ -929,8 +929,8 @@ let fi = class {
|
|
|
929
929
|
].indexOf(this.state) > -1 && this.load();
|
|
930
930
|
})
|
|
931
931
|
);
|
|
932
|
-
const e =
|
|
933
|
-
return e ? (process.env.NODE_ENV !== "production" &&
|
|
932
|
+
const e = S(this).activatedPromise;
|
|
933
|
+
return e ? (process.env.NODE_ENV !== "production" && C(this).warn(`Widget '${this.name}' has already been activated. The passed arguments for this activation will be discarded.`, t), e) : S(this).activatedPromise = this.load().then(() => this.container.get("$controller").activate(t));
|
|
934
934
|
}
|
|
935
935
|
/**
|
|
936
936
|
* Invokes a command on a widget. If the widget isn't activate the invocation
|
|
@@ -939,8 +939,8 @@ let fi = class {
|
|
|
939
939
|
* @param args Command arguments.
|
|
940
940
|
*/
|
|
941
941
|
invoke(t, ...e) {
|
|
942
|
-
const n =
|
|
943
|
-
return n ? i(t, ...e) : (process.env.NODE_ENV !== "production" &&
|
|
942
|
+
const n = S(this).activatedPromise, i = (r, ...o) => n.then(this.load).then(() => this.container.get("$controller").invoke(r, ...o));
|
|
943
|
+
return n ? i(t, ...e) : (process.env.NODE_ENV !== "production" && C(this).warn("You are invoking a command on a deactivated widget. The invocation will be queued until the widget is activated.", this), new Promise((r) => {
|
|
944
944
|
const o = this.events.subscribe("widget:state-changed", () => {
|
|
945
945
|
this.state === "activated" && (o(), r(i(t, ...e)));
|
|
946
946
|
});
|
|
@@ -951,12 +951,12 @@ let fi = class {
|
|
|
951
951
|
* `EventManager`.
|
|
952
952
|
*/
|
|
953
953
|
deactivate() {
|
|
954
|
-
return
|
|
954
|
+
return S(this).deactivatedPromise || (this.state === "deactivated" ? Promise.resolve() : (gt(
|
|
955
955
|
this,
|
|
956
956
|
"deactivating"
|
|
957
957
|
/* Deactivating */
|
|
958
|
-
),
|
|
959
|
-
this.events.clear(),
|
|
958
|
+
), S(this).deactivatedPromise = this.container.get("$controller").deactivate().then(() => (S(this).activatedPromise = null, S(this).subscriptions.forEach((e) => e()), S(this).subscriptions = [], this.container.clear().then(() => {
|
|
959
|
+
this.events.clear(), di(this), gt(
|
|
960
960
|
this,
|
|
961
961
|
"deactivated"
|
|
962
962
|
/* Deactivated */
|
|
@@ -964,8 +964,8 @@ let fi = class {
|
|
|
964
964
|
})))));
|
|
965
965
|
}
|
|
966
966
|
};
|
|
967
|
-
const
|
|
968
|
-
class
|
|
967
|
+
const Cs = dt();
|
|
968
|
+
let _i = class {
|
|
969
969
|
/**
|
|
970
970
|
* Creates a new Implementation instance.
|
|
971
971
|
* @param configuration Configuration for the implementation.
|
|
@@ -973,7 +973,7 @@ class yi {
|
|
|
973
973
|
* @param configurationApiExtensions Optional configuration API extensions.
|
|
974
974
|
*/
|
|
975
975
|
constructor(t, e, n = []) {
|
|
976
|
-
this.instructions = [], this.widgets = /* @__PURE__ */ new Map(), this.name = t.name, this.tenant = t.tenant, this.environment = e, this.container = e.container.createChild(this, this.name), this.events = e.events.createChild(this), this.container.register("$types", {}),
|
|
976
|
+
this.instructions = [], this.widgets = /* @__PURE__ */ new Map(), this.name = t.name, this.tenant = t.tenant, this.environment = e, this.container = e.container.createChild(this, this.name), this.events = e.events.createChild(this), this.container.register("$types", {}), Cs(this).configurationApiExtensions = n;
|
|
977
977
|
}
|
|
978
978
|
/**
|
|
979
979
|
* Loads all widgets in the implementation.
|
|
@@ -987,7 +987,7 @@ class yi {
|
|
|
987
987
|
* @param configFn Callback function for configuration.
|
|
988
988
|
*/
|
|
989
989
|
configure(t) {
|
|
990
|
-
return
|
|
990
|
+
return yi(t, this, Cs(this).configurationApiExtensions), this.events.dispatch(
|
|
991
991
|
"implementation:configured",
|
|
992
992
|
{ implementation: this },
|
|
993
993
|
{ bubbles: !0 }
|
|
@@ -999,25 +999,25 @@ class yi {
|
|
|
999
999
|
* @param configuration Widget configuration.
|
|
1000
1000
|
*/
|
|
1001
1001
|
createWidget(t, e) {
|
|
1002
|
-
const n = new
|
|
1002
|
+
const n = new xi(t, this, e);
|
|
1003
1003
|
return this.widgets.set(n.name, n), n;
|
|
1004
1004
|
}
|
|
1005
|
-
}
|
|
1006
|
-
function
|
|
1007
|
-
const n = new
|
|
1005
|
+
};
|
|
1006
|
+
function Pi(s, t, e) {
|
|
1007
|
+
const n = new _i(s, t, e);
|
|
1008
1008
|
return s.widgets && Object.keys(s.widgets).forEach((i) => {
|
|
1009
1009
|
var r;
|
|
1010
1010
|
const o = (r = s.widgets) == null ? void 0 : r[i];
|
|
1011
1011
|
n.createWidget(i, o);
|
|
1012
1012
|
}), n;
|
|
1013
1013
|
}
|
|
1014
|
-
let
|
|
1014
|
+
let As = class vn {
|
|
1015
1015
|
constructor(t, e) {
|
|
1016
1016
|
this.selectorFactory = e, typeof t == "function" ? this.resolver = t : this.resolver = () => t;
|
|
1017
1017
|
}
|
|
1018
1018
|
append(t) {
|
|
1019
1019
|
const e = typeof t == "function" ? t : () => t;
|
|
1020
|
-
return new
|
|
1020
|
+
return new vn(
|
|
1021
1021
|
() => this.all().concat(e()),
|
|
1022
1022
|
this.selectorFactory
|
|
1023
1023
|
);
|
|
@@ -1034,29 +1034,29 @@ let bs = class hn {
|
|
|
1034
1034
|
return e[0];
|
|
1035
1035
|
}
|
|
1036
1036
|
};
|
|
1037
|
-
const
|
|
1037
|
+
const qe = "#____version____#", de = dt(), Ci = (s) => s.tenant ? `${s.name}:${s.tenant}` : s.name, fn = class {
|
|
1038
1038
|
constructor(t, e = [], n = {}) {
|
|
1039
|
-
this.widgets = new
|
|
1039
|
+
this.widgets = new As(
|
|
1040
1040
|
() => {
|
|
1041
1041
|
let i = [];
|
|
1042
1042
|
return this.implementations.all().forEach((r) => {
|
|
1043
1043
|
i = i.concat(Array.from(r.widgets.values()));
|
|
1044
1044
|
}), i;
|
|
1045
1045
|
},
|
|
1046
|
-
|
|
1047
|
-
), this.implementations = new
|
|
1046
|
+
pn
|
|
1047
|
+
), this.implementations = new As([], ci), this.name = t, this.container = new ni(this, t), this.events = new ii(this), this.container.register("$version", qe), this.container.register("$environment", this), this.container.register("$environmentOptions", n), de(this).configurationApiExtensions = e;
|
|
1048
1048
|
}
|
|
1049
1049
|
/**
|
|
1050
1050
|
* Creates an implementation based on the provided configuration.
|
|
1051
1051
|
* @param config Implementation configuration.
|
|
1052
1052
|
*/
|
|
1053
1053
|
createImplementation(t) {
|
|
1054
|
-
const e =
|
|
1054
|
+
const e = Ci(t);
|
|
1055
1055
|
let n = this.implementations.find(e);
|
|
1056
1056
|
if (n)
|
|
1057
|
-
return process.env.NODE_ENV !== "production" &&
|
|
1058
|
-
const i =
|
|
1059
|
-
return n =
|
|
1057
|
+
return process.env.NODE_ENV !== "production" && C(n).warn(`Implementation "${e}" already exist on current environment.`), n;
|
|
1058
|
+
const i = de(this).configurationApiExtensions;
|
|
1059
|
+
return n = Pi(
|
|
1060
1060
|
t,
|
|
1061
1061
|
this,
|
|
1062
1062
|
i
|
|
@@ -1070,7 +1070,7 @@ const Le = "#____version____#", oe = at(), wi = (s) => s.tenant ? `${s.name}:${s
|
|
|
1070
1070
|
const { name: e, configurationApiExtensions: n } = t;
|
|
1071
1071
|
typeof e != "undefined" && e !== null && (this.name = e), n && n.forEach(
|
|
1072
1072
|
(i) => {
|
|
1073
|
-
|
|
1073
|
+
de(this).configurationApiExtensions.push(i);
|
|
1074
1074
|
}
|
|
1075
1075
|
);
|
|
1076
1076
|
}
|
|
@@ -1079,38 +1079,38 @@ const Le = "#____version____#", oe = at(), wi = (s) => s.tenant ? `${s.name}:${s
|
|
|
1079
1079
|
* @param configuration Environment configuration.
|
|
1080
1080
|
*/
|
|
1081
1081
|
static create(t = {}) {
|
|
1082
|
-
return new
|
|
1082
|
+
return new fn(
|
|
1083
1083
|
t.name || "",
|
|
1084
1084
|
t.configurationApiExtensions,
|
|
1085
1085
|
t.options
|
|
1086
1086
|
);
|
|
1087
1087
|
}
|
|
1088
1088
|
};
|
|
1089
|
-
let
|
|
1090
|
-
|
|
1091
|
-
const
|
|
1089
|
+
let yn = fn;
|
|
1090
|
+
yn.version = qe;
|
|
1091
|
+
const Qt = (s, t, ...e) => typeof t == "string" ? s(`[humany] ${t}`, ...e) : s(t, ...e), yt = class {
|
|
1092
1092
|
constructor() {
|
|
1093
|
-
this.keys = [], this.log = (t, ...e) => this.lookup(t, () =>
|
|
1093
|
+
this.keys = [], this.log = (t, ...e) => this.lookup(t, () => yt.log(...e)), this.warn = (t, ...e) => this.lookup(t, () => yt.warn(...e)), this.error = (t, ...e) => this.lookup(t, () => yt.error(...e)), this.info = (t, ...e) => this.lookup(t, () => yt.info(...e));
|
|
1094
1094
|
}
|
|
1095
1095
|
lookup(t, e) {
|
|
1096
1096
|
this.keys.indexOf(t) === -1 && (this.keys.push(t), e());
|
|
1097
1097
|
}
|
|
1098
1098
|
};
|
|
1099
|
-
let
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
const
|
|
1099
|
+
let k = yt;
|
|
1100
|
+
k.log = (...s) => Qt(console.log, ...s);
|
|
1101
|
+
k.warn = (...s) => Qt(console.warn, ...s);
|
|
1102
|
+
k.error = (...s) => Qt(console.error, ...s);
|
|
1103
|
+
k.info = (...s) => Qt(console.info, ...s);
|
|
1104
|
+
const bn = (s) => {
|
|
1105
1105
|
let t = {}, e, n;
|
|
1106
1106
|
if (typeof s != "object" || s === null)
|
|
1107
1107
|
return s;
|
|
1108
1108
|
t = Array.isArray(s) ? [] : {};
|
|
1109
1109
|
for (n in s)
|
|
1110
|
-
e = s[n], t[n] = typeof e == "object" && e !== null ?
|
|
1110
|
+
e = s[n], t[n] = typeof e == "object" && e !== null ? bn(e) : e;
|
|
1111
1111
|
return t;
|
|
1112
|
-
},
|
|
1113
|
-
function
|
|
1112
|
+
}, Ai = bn;
|
|
1113
|
+
function Es(s) {
|
|
1114
1114
|
let t = 0;
|
|
1115
1115
|
if (s.length === 0)
|
|
1116
1116
|
return t.toString();
|
|
@@ -1120,7 +1120,7 @@ function ws(s) {
|
|
|
1120
1120
|
}
|
|
1121
1121
|
return t.toString();
|
|
1122
1122
|
}
|
|
1123
|
-
let
|
|
1123
|
+
let Ei = class {
|
|
1124
1124
|
constructor(t, e) {
|
|
1125
1125
|
this.lockWarningTime = t, this.lockErrorTime = e, this.tasks = [], this.current = Promise.resolve(), this.next = this.next.bind(this);
|
|
1126
1126
|
}
|
|
@@ -1133,7 +1133,7 @@ let Ai = class {
|
|
|
1133
1133
|
if (t) {
|
|
1134
1134
|
let e;
|
|
1135
1135
|
const n = setTimeout(() => {
|
|
1136
|
-
process.env.NODE_ENV !== "production" &&
|
|
1136
|
+
process.env.NODE_ENV !== "production" && k.warn(
|
|
1137
1137
|
`A lock has exceeded ${this.lockWarningTime} ms. Waiting additional ${this.lockErrorTime} ms before rejecting the task.`,
|
|
1138
1138
|
t
|
|
1139
1139
|
), e = setTimeout(() => {
|
|
@@ -1150,28 +1150,28 @@ let Ai = class {
|
|
|
1150
1150
|
});
|
|
1151
1151
|
}
|
|
1152
1152
|
};
|
|
1153
|
-
const
|
|
1153
|
+
const Tt = /* @__PURE__ */ new WeakMap();
|
|
1154
1154
|
function At(s, t = 5e3, e = 1e3) {
|
|
1155
|
-
return
|
|
1156
|
-
const o =
|
|
1155
|
+
return Tt.has(s) || Tt.set(s, new Ei(t, e)), (n) => new Promise((i, r) => {
|
|
1156
|
+
const o = Tt.get(s);
|
|
1157
1157
|
o.add(n, i, r, () => {
|
|
1158
|
-
o.tasks.length ||
|
|
1158
|
+
o.tasks.length || Tt.delete(s);
|
|
1159
1159
|
});
|
|
1160
1160
|
});
|
|
1161
1161
|
}
|
|
1162
1162
|
const W = () => Math.floor((1 + Math.random()) * 65536).toString(16).substring(1);
|
|
1163
|
-
function
|
|
1163
|
+
function Yt() {
|
|
1164
1164
|
return W() + W() + "-" + W() + "-" + W() + "-" + W() + "-" + W() + W() + W();
|
|
1165
1165
|
}
|
|
1166
|
-
var
|
|
1166
|
+
var ki = Object.defineProperty, Oi = Object.defineProperties, Si = Object.getOwnPropertyDescriptors, ks = Object.getOwnPropertySymbols, Ni = Object.prototype.hasOwnProperty, Ti = Object.prototype.propertyIsEnumerable, Os = (s, t, e) => t in s ? ki(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, je = (s, t) => {
|
|
1167
1167
|
for (var e in t || (t = {}))
|
|
1168
|
-
|
|
1169
|
-
if (
|
|
1170
|
-
for (var e of
|
|
1171
|
-
|
|
1168
|
+
Ni.call(t, e) && Os(s, e, t[e]);
|
|
1169
|
+
if (ks)
|
|
1170
|
+
for (var e of ks(t))
|
|
1171
|
+
Ti.call(t, e) && Os(s, e, t[e]);
|
|
1172
1172
|
return s;
|
|
1173
|
-
},
|
|
1174
|
-
const
|
|
1173
|
+
}, Ii = (s, t) => Oi(s, Si(t));
|
|
1174
|
+
const ji = (s) => {
|
|
1175
1175
|
const t = [];
|
|
1176
1176
|
return [
|
|
1177
1177
|
(e, n) => {
|
|
@@ -1184,7 +1184,7 @@ const ki = (s) => {
|
|
|
1184
1184
|
}
|
|
1185
1185
|
];
|
|
1186
1186
|
};
|
|
1187
|
-
let
|
|
1187
|
+
let wn = class {
|
|
1188
1188
|
constructor(t, e = []) {
|
|
1189
1189
|
this.platform = t, this.rules = e;
|
|
1190
1190
|
}
|
|
@@ -1198,17 +1198,17 @@ let pn = class {
|
|
|
1198
1198
|
return this.rules.push({ id: t }), this;
|
|
1199
1199
|
}
|
|
1200
1200
|
select() {
|
|
1201
|
-
return new
|
|
1201
|
+
return new Mi(this.platform, this);
|
|
1202
1202
|
}
|
|
1203
1203
|
};
|
|
1204
|
-
class
|
|
1204
|
+
class Di {
|
|
1205
1205
|
constructor(t, e, n) {
|
|
1206
|
-
this.platform = t, this.node = e, this.actions = new
|
|
1206
|
+
this.platform = t, this.node = e, this.actions = new Fe(
|
|
1207
1207
|
t,
|
|
1208
|
-
new
|
|
1208
|
+
new wn(t).withId(e.id),
|
|
1209
1209
|
n
|
|
1210
1210
|
);
|
|
1211
|
-
const [i, r] =
|
|
1211
|
+
const [i, r] = ji(this.platform.events);
|
|
1212
1212
|
this.subscribe = i, this.unsubscribe = r;
|
|
1213
1213
|
}
|
|
1214
1214
|
properties(t) {
|
|
@@ -1237,9 +1237,9 @@ class Si {
|
|
|
1237
1237
|
this.unsubscribe(), this.actions.dispose();
|
|
1238
1238
|
}
|
|
1239
1239
|
}
|
|
1240
|
-
let
|
|
1240
|
+
let Mi = class {
|
|
1241
1241
|
constructor(t, e, n = !0) {
|
|
1242
|
-
this.platform = t, this.target = e, this.clearOnDispose = n, this.removes = [], this.actions = new
|
|
1242
|
+
this.platform = t, this.target = e, this.clearOnDispose = n, this.removes = [], this.actions = new Fe(this.platform, this.target);
|
|
1243
1243
|
}
|
|
1244
1244
|
writeProperties(t, e) {
|
|
1245
1245
|
this.removes.push(
|
|
@@ -1277,12 +1277,12 @@ let Ni = class {
|
|
|
1277
1277
|
}), this.actions.dispose();
|
|
1278
1278
|
}
|
|
1279
1279
|
};
|
|
1280
|
-
const
|
|
1280
|
+
const Li = (s, t, e) => {
|
|
1281
1281
|
const n = s.concat(), i = (r, o, a) => {
|
|
1282
1282
|
let c = !0;
|
|
1283
1283
|
if (n.length) {
|
|
1284
1284
|
const h = n.shift(), l = (d, p) => (c = !1, i(d, Object.assign({}, o, p), a));
|
|
1285
|
-
return Promise.resolve(h(r, l, a)).then((d) =>
|
|
1285
|
+
return Promise.resolve(h(r, l, a)).then((d) => Ii(je({}, d), {
|
|
1286
1286
|
cancelled: c
|
|
1287
1287
|
}));
|
|
1288
1288
|
}
|
|
@@ -1290,7 +1290,7 @@ const Ti = (s, t, e) => {
|
|
|
1290
1290
|
};
|
|
1291
1291
|
return i(t, {}, e);
|
|
1292
1292
|
};
|
|
1293
|
-
class
|
|
1293
|
+
class Fe {
|
|
1294
1294
|
constructor(t, e, n) {
|
|
1295
1295
|
this.platform = t, this.target = e, this.ns = n, this.subscriptions = [], this.create = this.create.bind(this);
|
|
1296
1296
|
}
|
|
@@ -1322,12 +1322,12 @@ class Ue {
|
|
|
1322
1322
|
), 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);
|
|
1323
1323
|
return Promise.all(
|
|
1324
1324
|
a.map((h) => {
|
|
1325
|
-
const l = new
|
|
1325
|
+
const l = new Di(
|
|
1326
1326
|
this.platform,
|
|
1327
1327
|
h,
|
|
1328
1328
|
this.ns
|
|
1329
1329
|
);
|
|
1330
|
-
return
|
|
1330
|
+
return Li(c, e, l).then((d) => {
|
|
1331
1331
|
const { data: p = {}, options: u, cancelled: g } = d;
|
|
1332
1332
|
return Promise.resolve(
|
|
1333
1333
|
g ? {} : o.fn(p, u, l)
|
|
@@ -1361,7 +1361,7 @@ class Ue {
|
|
|
1361
1361
|
this.subscriptions.forEach((t) => t());
|
|
1362
1362
|
}
|
|
1363
1363
|
}
|
|
1364
|
-
|
|
1364
|
+
mn((s) => {
|
|
1365
1365
|
s.createCommand("components", (t) => (e) => {
|
|
1366
1366
|
t.events.subscribeOnce("components:platform-created", (n, { platform: i }) => {
|
|
1367
1367
|
e.handlers && e.handlers.forEach(([r, o]) => {
|
|
@@ -1370,9 +1370,9 @@ cn((s) => {
|
|
|
1370
1370
|
});
|
|
1371
1371
|
});
|
|
1372
1372
|
});
|
|
1373
|
-
class
|
|
1373
|
+
class Ss {
|
|
1374
1374
|
constructor(t, e) {
|
|
1375
|
-
this.events = t, this.tags = [], this.children = {}, this.changesets = [], this.mountCount = 0, this.id =
|
|
1375
|
+
this.events = t, this.tags = [], this.children = {}, this.changesets = [], this.mountCount = 0, this.id = Yt(), this.type = e, this.attributes = {
|
|
1376
1376
|
context: {},
|
|
1377
1377
|
properties: {},
|
|
1378
1378
|
layout: {},
|
|
@@ -1381,7 +1381,7 @@ class Ps {
|
|
|
1381
1381
|
}
|
|
1382
1382
|
mount(t, e) {
|
|
1383
1383
|
let n = t.get("mounted-nodes");
|
|
1384
|
-
return n || (n = /* @__PURE__ */ new Map(), t.register("mounted-nodes", n)), n.has(this) ? (process.env.NODE_ENV !== "production" &&
|
|
1384
|
+
return n || (n = /* @__PURE__ */ new Map(), t.register("mounted-nodes", n)), n.has(this) ? (process.env.NODE_ENV !== "production" && k.error("Trying to mount an already mounted component node.", this), () => {
|
|
1385
1385
|
}) : (this.events.dispatch("components:node-mounted", { node: this }), this.mountCount === 0 && (this.mountCount = this.mountCount + 1, this.events.dispatch("components:node-enter", { node: this })), () => {
|
|
1386
1386
|
n.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 });
|
|
1387
1387
|
});
|
|
@@ -1455,50 +1455,50 @@ class Ps {
|
|
|
1455
1455
|
}), delete t.parent;
|
|
1456
1456
|
}
|
|
1457
1457
|
}
|
|
1458
|
-
const
|
|
1458
|
+
const $n = (s, t, e) => {
|
|
1459
1459
|
for (let n = 0, i = s.length; n < i && e(s[n]) !== !0; n++) {
|
|
1460
1460
|
const r = t[s[n].id] || "default", o = s[n].getChildren(r);
|
|
1461
|
-
|
|
1461
|
+
$n(o, t, e);
|
|
1462
1462
|
}
|
|
1463
|
-
},
|
|
1463
|
+
}, Ke = (s, t, e) => {
|
|
1464
1464
|
if (e(s) !== !0) {
|
|
1465
1465
|
const n = t[s.id] || "default", i = s.children[n];
|
|
1466
|
-
|
|
1466
|
+
$n(i, t, e);
|
|
1467
1467
|
}
|
|
1468
|
-
},
|
|
1468
|
+
}, ue = (s, t) => {
|
|
1469
1469
|
const e = [];
|
|
1470
|
-
return
|
|
1470
|
+
return Ke(s, t, (n) => {
|
|
1471
1471
|
e.push(n);
|
|
1472
1472
|
}), e;
|
|
1473
|
-
},
|
|
1473
|
+
}, Ri = (s, t, e) => {
|
|
1474
1474
|
let n;
|
|
1475
|
-
return
|
|
1475
|
+
return Ke(s, t, (i) => {
|
|
1476
1476
|
if (e(i))
|
|
1477
1477
|
return n = i, !0;
|
|
1478
1478
|
}), n;
|
|
1479
1479
|
};
|
|
1480
|
-
|
|
1480
|
+
class Wi {
|
|
1481
1481
|
constructor(t, e, n) {
|
|
1482
1482
|
this.root = t, this.switches = e, this.all = [], this.visible = [], this.detached = [], n.subscribe("components:node-appended", (i, r) => {
|
|
1483
|
-
this.all.push(r.node), this.visible =
|
|
1483
|
+
this.all.push(r.node), this.visible = ue(t, e);
|
|
1484
1484
|
}), n.subscribe("components:node-removed", (i, r) => {
|
|
1485
1485
|
let o = this.all.indexOf(r.node);
|
|
1486
|
-
o > -1 && this.all.splice(o, 1), o = this.visible.indexOf(r.node), o > -1 && this.visible.splice(o, 1), this.visible =
|
|
1486
|
+
o > -1 && this.all.splice(o, 1), o = this.visible.indexOf(r.node), o > -1 && this.visible.splice(o, 1), this.visible = ue(t, e);
|
|
1487
1487
|
}), n.subscribe("components:node-switched", (i, r) => {
|
|
1488
|
-
this.visible =
|
|
1488
|
+
this.visible = ue(t, e);
|
|
1489
1489
|
});
|
|
1490
1490
|
}
|
|
1491
1491
|
query(t = {}) {
|
|
1492
1492
|
const e = [];
|
|
1493
|
-
return
|
|
1493
|
+
return Ke(this.root, this.switches, (n) => {
|
|
1494
1494
|
Object.keys(t).every((i) => t[i] === n[i]) && e.push(n);
|
|
1495
1495
|
}), e;
|
|
1496
1496
|
}
|
|
1497
1497
|
get(t) {
|
|
1498
|
-
return
|
|
1498
|
+
return Ri(this.root, this.switches, (e) => e.id === t) || this.detached.find((e) => e.id === t);
|
|
1499
1499
|
}
|
|
1500
|
-
}
|
|
1501
|
-
class
|
|
1500
|
+
}
|
|
1501
|
+
let zi = class {
|
|
1502
1502
|
constructor() {
|
|
1503
1503
|
this.handlers = /* @__PURE__ */ new Map();
|
|
1504
1504
|
}
|
|
@@ -1508,50 +1508,50 @@ class Di {
|
|
|
1508
1508
|
get(t) {
|
|
1509
1509
|
return this.handlers.get(t);
|
|
1510
1510
|
}
|
|
1511
|
-
}
|
|
1512
|
-
const
|
|
1511
|
+
};
|
|
1512
|
+
const Hi = (s) => {
|
|
1513
1513
|
let t = s, e = 0;
|
|
1514
1514
|
for (; t.parent; )
|
|
1515
1515
|
e = e + 1, t = t.parent;
|
|
1516
1516
|
return e;
|
|
1517
|
-
},
|
|
1517
|
+
}, Ui = (s) => s.map(([t, e]) => [Hi(t), t, e]).sort(([t], [e]) => t - e).map(([, t, e]) => [t, e]), pe = (s) => s instanceof Date ? !1 : s && typeof s == "object" && !Array.isArray(s), T = (s, ...t) => {
|
|
1518
1518
|
if (!t.length)
|
|
1519
1519
|
return s;
|
|
1520
1520
|
const e = t.shift();
|
|
1521
|
-
if (
|
|
1521
|
+
if (pe(s) && pe(e))
|
|
1522
1522
|
for (const n in e)
|
|
1523
|
-
|
|
1524
|
-
return
|
|
1525
|
-
},
|
|
1523
|
+
pe(e[n]) ? (s[n] || Object.assign(s, { [n]: {} }), T(s[n], e[n])) : Object.assign(s, { [n]: e[n] });
|
|
1524
|
+
return T(s, ...t);
|
|
1525
|
+
}, Vi = (s, t) => !s || s === "all" ? !0 : s.some((e) => t.indexOf(e) > -1), Bi = (s, t) => {
|
|
1526
1526
|
let e = [], n = [], i;
|
|
1527
1527
|
const r = () => {
|
|
1528
1528
|
process.env.NODE_ENV !== "production" && console.time("state-processor.flush");
|
|
1529
|
-
const a = /* @__PURE__ */ new Map(), c =
|
|
1529
|
+
const a = /* @__PURE__ */ new Map(), c = Ui(e.map((l, d) => [l, n[d]])), h = (l, d) => {
|
|
1530
1530
|
var p;
|
|
1531
|
-
const u = a.get(l) || {}, g = d.context && !u.context, m = d.properties && !u.properties,
|
|
1531
|
+
const u = a.get(l) || {}, g = d.context && !u.context, m = d.properties && !u.properties, A = d.layout && !u.layout;
|
|
1532
1532
|
a.set(l, {
|
|
1533
1533
|
context: u.context || g,
|
|
1534
1534
|
properties: u.properties || m,
|
|
1535
|
-
layout: u.layout ||
|
|
1536
|
-
}), m && (l.attributes.properties = {}),
|
|
1537
|
-
const
|
|
1535
|
+
layout: u.layout || A
|
|
1536
|
+
}), m && (l.attributes.properties = {}), A && (l.attributes.layout = {}), g && (l.attributes.context = T({}, (p = l.parent) == null ? void 0 : p.attributes.context));
|
|
1537
|
+
const L = [], ut = [], pt = [];
|
|
1538
1538
|
if (l.changesets.forEach((b) => {
|
|
1539
|
-
const [v,
|
|
1540
|
-
|
|
1539
|
+
const [v, J] = b;
|
|
1540
|
+
Vi(J.breakpoints, s.breakpoints) && (m && (typeof v.properties == "function" ? L.push(
|
|
1541
1541
|
v.properties
|
|
1542
|
-
) :
|
|
1543
|
-
}),
|
|
1544
|
-
|
|
1545
|
-
}),
|
|
1546
|
-
|
|
1547
|
-
}),
|
|
1548
|
-
|
|
1542
|
+
) : T(l.attributes.properties, v.properties)), A && (typeof v.layout == "function" ? ut.push(v.layout) : T(l.attributes.layout, v.layout)), g && (typeof v.context == "function" ? pt.push(v.context) : T(l.attributes.context, v.context)));
|
|
1543
|
+
}), L.forEach((b) => {
|
|
1544
|
+
T(l.attributes.properties, b(l.attributes.properties));
|
|
1545
|
+
}), ut.forEach((b) => {
|
|
1546
|
+
T(l.attributes.layout, b(l.attributes.layout));
|
|
1547
|
+
}), pt.forEach((b) => {
|
|
1548
|
+
T(l.attributes.context, b(l.attributes.context));
|
|
1549
1549
|
}), g || d.recursive) {
|
|
1550
1550
|
const b = s.getBranch(l), v = d.recursive ? d : {
|
|
1551
1551
|
context: !!g
|
|
1552
1552
|
};
|
|
1553
|
-
l.getChildren(b).forEach((
|
|
1554
|
-
h(
|
|
1553
|
+
l.getChildren(b).forEach((J) => {
|
|
1554
|
+
h(J, v);
|
|
1555
1555
|
});
|
|
1556
1556
|
}
|
|
1557
1557
|
};
|
|
@@ -1570,12 +1570,12 @@ const Mi = (s) => {
|
|
|
1570
1570
|
return e.push(a), n.push(c), o();
|
|
1571
1571
|
};
|
|
1572
1572
|
};
|
|
1573
|
-
let
|
|
1573
|
+
let Ji = class {
|
|
1574
1574
|
constructor(t, e = {}) {
|
|
1575
|
-
this.providers = e, this.breakpoints = [], this.actionsState = { handlers: [], watchers: [] }, this.switches = {}, this.changesets = [], this.subscriptions = [], this.customComponentHandler = new
|
|
1576
|
-
const n = new
|
|
1577
|
-
n.name = `root-${t.name}`, this.nodes = new
|
|
1578
|
-
const i = this.processNode =
|
|
1575
|
+
this.providers = e, this.breakpoints = [], this.actionsState = { handlers: [], watchers: [] }, this.switches = {}, this.changesets = [], this.subscriptions = [], this.customComponentHandler = new zi(), this.events = t.events.createChild(this);
|
|
1576
|
+
const n = new Ss(this.events, "root");
|
|
1577
|
+
n.name = `root-${t.name}`, this.nodes = new Wi(n, this.switches, this.events);
|
|
1578
|
+
const i = this.processNode = Bi(this, (r) => {
|
|
1579
1579
|
const o = Array.from(r.keys());
|
|
1580
1580
|
process.env.NODE_ENV !== "production" && console.info(`STATE PROCESSOR: ${o.length} node(s) processed:
|
|
1581
1581
|
${o.map(
|
|
@@ -1680,17 +1680,17 @@ ${o.map(
|
|
|
1680
1680
|
* @param type Type of node.
|
|
1681
1681
|
*/
|
|
1682
1682
|
createNode(t, e = {}) {
|
|
1683
|
-
const n = new
|
|
1683
|
+
const n = new Ss(this.events, t);
|
|
1684
1684
|
return e.detached && this.nodes.detached.push(n), n;
|
|
1685
1685
|
}
|
|
1686
1686
|
components() {
|
|
1687
|
-
return new
|
|
1687
|
+
return new wn(this);
|
|
1688
1688
|
}
|
|
1689
1689
|
actions(t, e) {
|
|
1690
|
-
return new
|
|
1690
|
+
return new Fe(this, t, e);
|
|
1691
1691
|
}
|
|
1692
1692
|
write(t) {
|
|
1693
|
-
const { provider: e, target: n, attributes: i, options: r = {}, removable: o } = t, a = t.key ||
|
|
1693
|
+
const { provider: e, target: n, attributes: i, options: r = {}, removable: o } = t, a = t.key || Yt(), c = { changeset: [i, r], target: n, removes: [] };
|
|
1694
1694
|
if (e) {
|
|
1695
1695
|
const h = this.providers[e];
|
|
1696
1696
|
h.write(a, n, i, r), c.removes.push(() => {
|
|
@@ -1721,12 +1721,12 @@ ${o.map(
|
|
|
1721
1721
|
this.subscriptions.forEach((t) => t());
|
|
1722
1722
|
}
|
|
1723
1723
|
};
|
|
1724
|
-
const
|
|
1724
|
+
const qi = "#____version____#", xn = class extends yn {
|
|
1725
1725
|
constructor(t, e = []) {
|
|
1726
1726
|
super(t, e, {
|
|
1727
1727
|
transformPluginSettings: (n, i, r) => {
|
|
1728
1728
|
const o = r.get("$settings"), a = o.plugins && i ? o.plugins[i] || {} : {};
|
|
1729
|
-
return
|
|
1729
|
+
return je(je({}, a), n);
|
|
1730
1730
|
}
|
|
1731
1731
|
});
|
|
1732
1732
|
}
|
|
@@ -1749,10 +1749,10 @@ const Li = "#____version____#", mn = class extends dn {
|
|
|
1749
1749
|
* @param configuration Runtime configuration.
|
|
1750
1750
|
*/
|
|
1751
1751
|
static create(t = {}) {
|
|
1752
|
-
const e = [
|
|
1752
|
+
const e = [Xn].concat(
|
|
1753
1753
|
t.configurationApiExtensions || []
|
|
1754
1754
|
);
|
|
1755
|
-
return new
|
|
1755
|
+
return new xn("humany", e);
|
|
1756
1756
|
}
|
|
1757
1757
|
/**
|
|
1758
1758
|
* Creates a widget runtime based on provided configuration and retains configuration handlers
|
|
@@ -1777,24 +1777,24 @@ const Li = "#____version____#", mn = class extends dn {
|
|
|
1777
1777
|
return !!(t && typeof t == "object" && t.container && typeof t.container.get == "function" && t.container.get("$environment") === t && t.container.owner === t);
|
|
1778
1778
|
}
|
|
1779
1779
|
};
|
|
1780
|
-
let
|
|
1781
|
-
|
|
1782
|
-
var
|
|
1780
|
+
let Fi = xn;
|
|
1781
|
+
Fi.version = `${qi} (${qe})`;
|
|
1782
|
+
var Ki = Object.defineProperty, Ns = Object.getOwnPropertySymbols, Qi = Object.prototype.hasOwnProperty, Yi = Object.prototype.propertyIsEnumerable, Ts = (s, t, e) => t in s ? Ki(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, st = (s, t) => {
|
|
1783
1783
|
for (var e in t || (t = {}))
|
|
1784
|
-
|
|
1785
|
-
if (
|
|
1786
|
-
for (var e of
|
|
1787
|
-
|
|
1784
|
+
Qi.call(t, e) && Ts(s, e, t[e]);
|
|
1785
|
+
if (Ns)
|
|
1786
|
+
for (var e of Ns(t))
|
|
1787
|
+
Yi.call(t, e) && Ts(s, e, t[e]);
|
|
1788
1788
|
return s;
|
|
1789
|
-
},
|
|
1790
|
-
const
|
|
1789
|
+
}, _ = /* @__PURE__ */ ((s) => (s.Cookie = "cookie", s.Local = "local", s.Session = "session", s))(_ || {}), Zt = /* @__PURE__ */ ((s) => (s.Tenant = "tenant", s.Implementation = "implementation", s.Widget = "widget", s))(Zt || {}), x = /* @__PURE__ */ ((s) => (s.Necessary = "necessary", s.Functional = "functional", s.Analytical = "analytical", s.Marketing = "marketing", s))(x || {});
|
|
1790
|
+
const Gt = (s, t, e, n = {}) => Is(s, e).then((i) => (process.env.NODE_ENV !== "production" && i && k.warn(
|
|
1791
1791
|
`createStorageWriter: Attempted to create storage writer using unallowed category.
|
|
1792
1792
|
Key: ${t}
|
|
1793
1793
|
Category: ${JSON.stringify(e)}
|
|
1794
1794
|
Options: ${JSON.stringify(n)}`
|
|
1795
|
-
), (r) => (
|
|
1795
|
+
), (r) => (Ye(s), Is(s, e).then((o) => {
|
|
1796
1796
|
if (o) {
|
|
1797
|
-
process.env.NODE_ENV !== "production" &&
|
|
1797
|
+
process.env.NODE_ENV !== "production" && k.warn(
|
|
1798
1798
|
`storageWriter: Attempted to write to storage using unallowed category.
|
|
1799
1799
|
Key: ${t}
|
|
1800
1800
|
Category: ${JSON.stringify(e)}
|
|
@@ -1804,103 +1804,103 @@ const Ft = (s, t, e, n = {}) => Es(s, e).then((i) => (process.env.NODE_ENV !== "
|
|
|
1804
1804
|
return;
|
|
1805
1805
|
}
|
|
1806
1806
|
const {
|
|
1807
|
-
scope: a =
|
|
1808
|
-
medium: c =
|
|
1807
|
+
scope: a = Zt.Widget,
|
|
1808
|
+
medium: c = _.Session,
|
|
1809
1809
|
duration: h
|
|
1810
|
-
} = n, l =
|
|
1811
|
-
return l[a][t] =
|
|
1812
|
-
})))),
|
|
1810
|
+
} = n, l = Gi();
|
|
1811
|
+
return l[a][t] = Cn(r, e, h), c === _.Cookie ? nr(s, l) : rr(s, c, l);
|
|
1812
|
+
})))), K = (s, t, e = _.Session) => (Ye(s), typeof t == "undefined" ? (process.env.NODE_ENV !== "production" && k.warn("readStorage: Undefined key passed when reading storage. ", t, e), Promise.resolve(void 0)) : e === _.Cookie ? sr(s).then((n) => Me(n, t)) : ir(s, e).then((n) => Me(n, t))), ot = (s) => !!Object.entries(s).filter(([t, e]) => typeof e != "undefined").length, ge = (s) => Object.entries(s).filter(([t, e]) => typeof e != "undefined").forEach(([t, { value: e }]) => {
|
|
1813
1813
|
typeof e == "undefined" && delete s[t];
|
|
1814
|
-
}),
|
|
1814
|
+
}), _n = (s, t) => {
|
|
1815
1815
|
const e = {
|
|
1816
|
-
tenant:
|
|
1817
|
-
implementation:
|
|
1818
|
-
widget:
|
|
1816
|
+
tenant: st(st({}, s.tenant), t.tenant),
|
|
1817
|
+
implementation: st(st({}, s.implementation), t.implementation),
|
|
1818
|
+
widget: st(st({}, s.widget), t.widget)
|
|
1819
1819
|
};
|
|
1820
|
-
return
|
|
1821
|
-
},
|
|
1820
|
+
return ge(e.tenant), ge(e.implementation), ge(e.widget), e;
|
|
1821
|
+
}, Zi = (s) => Object.entries(s).reduce((t, e) => {
|
|
1822
1822
|
const [n, i] = e;
|
|
1823
1823
|
return Object.entries(i).forEach((r) => {
|
|
1824
1824
|
const [o, { expiration: a }] = r;
|
|
1825
1825
|
a && t.push(a);
|
|
1826
1826
|
}), t;
|
|
1827
|
-
}, []).slice().sort((t, e) => new Date(e).valueOf() - new Date(t).valueOf()).shift() ||
|
|
1827
|
+
}, []).slice().sort((t, e) => new Date(e).valueOf() - new Date(t).valueOf()).shift() || Ze(), Xt = (s) => {
|
|
1828
1828
|
const {
|
|
1829
1829
|
name: t,
|
|
1830
1830
|
implementation: { name: e, tenant: n }
|
|
1831
1831
|
} = s.get("$widget");
|
|
1832
1832
|
return [
|
|
1833
1833
|
`humany_${n}`,
|
|
1834
|
-
`humany_${
|
|
1835
|
-
`humany_${
|
|
1834
|
+
`humany_${Es(n + e)}`,
|
|
1835
|
+
`humany_${Es(n + e + t)}`
|
|
1836
1836
|
];
|
|
1837
|
-
},
|
|
1837
|
+
}, me = (s) => {
|
|
1838
1838
|
const t = new RegExp(`(?:^|;)\\s?${s}=(.*?)(?:;|$)`, "i"), e = document.cookie.match(t);
|
|
1839
1839
|
return e && e[1] && JSON.parse(e[1]) || void 0;
|
|
1840
|
-
},
|
|
1840
|
+
}, ve = (s, t, e) => {
|
|
1841
1841
|
const n = `${s}=${JSON.stringify(t).trim()}`, i = `expires=${new Date(e).toUTCString()}`, r = "path=/", o = "SameSite=None;Secure";
|
|
1842
1842
|
return document.cookie = `${n}; ${i}; ${r}; ${o}`;
|
|
1843
|
-
},
|
|
1844
|
-
const [t, e, n] =
|
|
1843
|
+
}, Qe = (s) => {
|
|
1844
|
+
const [t, e, n] = Xt(s), i = me(t) || {}, r = me(e) || {}, o = me(n) || {};
|
|
1845
1845
|
return {
|
|
1846
1846
|
tenant: i,
|
|
1847
1847
|
implementation: r,
|
|
1848
1848
|
widget: o
|
|
1849
1849
|
};
|
|
1850
|
-
},
|
|
1851
|
-
const e =
|
|
1852
|
-
|
|
1850
|
+
}, Pn = (s, t) => {
|
|
1851
|
+
const e = Qe(s), n = _n(e, t), [i, r, o] = Xt(s), { tenant: a, implementation: c, widget: h } = n, l = Zi(t), d = Ze({ days: -1 });
|
|
1852
|
+
ve(i, a, ot(a) ? l : d), ve(
|
|
1853
1853
|
r,
|
|
1854
1854
|
c,
|
|
1855
|
-
|
|
1856
|
-
),
|
|
1857
|
-
},
|
|
1858
|
-
const [e, n, i] =
|
|
1855
|
+
ot(c) ? l : d
|
|
1856
|
+
), ve(o, h, ot(h) ? l : d);
|
|
1857
|
+
}, zt = (s, t) => {
|
|
1858
|
+
const [e, n, i] = Xt(s), r = t.getItem(e) || "{}", o = t.getItem(n) || "{}", a = t.getItem(i) || "{}";
|
|
1859
1859
|
return {
|
|
1860
1860
|
tenant: JSON.parse(r),
|
|
1861
1861
|
implementation: JSON.parse(o),
|
|
1862
1862
|
widget: JSON.parse(a)
|
|
1863
1863
|
};
|
|
1864
|
-
},
|
|
1865
|
-
const n =
|
|
1866
|
-
|
|
1867
|
-
},
|
|
1864
|
+
}, De = (s, t, e) => {
|
|
1865
|
+
const n = zt(s, t), i = _n(n, e), [r, o, a] = Xt(s), { tenant: c, implementation: h, widget: l } = i;
|
|
1866
|
+
ot(c) ? t.setItem(r, JSON.stringify(c)) : t.removeItem(r), ot(h) ? t.setItem(o, JSON.stringify(h)) : t.removeItem(o), ot(l) ? t.setItem(a, JSON.stringify(l)) : t.removeItem(a);
|
|
1867
|
+
}, Gi = () => ({ tenant: {}, implementation: {}, widget: {} }), Xi = (s) => s ? !!s && /* @__PURE__ */ new Date() > new Date(s) : !1, Me = (s, t) => {
|
|
1868
1868
|
const e = s.widget[t] || s.implementation[t] || s.tenant[t];
|
|
1869
1869
|
return e == null ? void 0 : e.value;
|
|
1870
|
-
},
|
|
1870
|
+
}, Cn = (s, t, e) => e ? {
|
|
1871
1871
|
value: s,
|
|
1872
1872
|
category: t,
|
|
1873
|
-
expiration: typeof e == "object" ?
|
|
1873
|
+
expiration: typeof e == "object" ? Ze(e) : e
|
|
1874
1874
|
} : {
|
|
1875
1875
|
value: s,
|
|
1876
1876
|
category: t
|
|
1877
|
-
},
|
|
1878
|
-
const e =
|
|
1877
|
+
}, tr = (s, t) => {
|
|
1878
|
+
const e = Ai(s);
|
|
1879
1879
|
return Object.entries(e).forEach(([n, i]) => {
|
|
1880
1880
|
Object.entries(i).forEach(([r, o]) => {
|
|
1881
1881
|
const { expiration: a, category: c } = o;
|
|
1882
|
-
(
|
|
1882
|
+
(Xi(a) || er(t, c)) && (i[r] = Cn(void 0, c, a));
|
|
1883
1883
|
});
|
|
1884
1884
|
}), e;
|
|
1885
|
-
},
|
|
1886
|
-
(e = [
|
|
1887
|
-
),
|
|
1888
|
-
const t =
|
|
1885
|
+
}, Is = (s, t) => K(s, "storagePolicy", _.Cookie).then(
|
|
1886
|
+
(e = [x.Necessary]) => !!t && e.indexOf(t) === -1
|
|
1887
|
+
), er = (s = [x.Necessary], t) => !!t && s.indexOf(t) === -1, Ye = (s) => {
|
|
1888
|
+
const t = Qe(s), e = zt(s, window.localStorage), n = zt(s, sessionStorage), i = Me(t, "storagePolicy"), [r, o, a] = [
|
|
1889
1889
|
t,
|
|
1890
1890
|
e,
|
|
1891
1891
|
n
|
|
1892
|
-
].map((c) =>
|
|
1893
|
-
|
|
1894
|
-
},
|
|
1892
|
+
].map((c) => tr(c, i));
|
|
1893
|
+
Pn(s, r), De(s, window.localStorage, o), De(s, window.sessionStorage, a);
|
|
1894
|
+
}, Ze = (s = { days: 30 }) => {
|
|
1895
1895
|
const { days: t = 0, hours: e = 0, minutes: n = 0, seconds: i = 0 } = s, r = /* @__PURE__ */ new Date();
|
|
1896
1896
|
return r.setTime(r.getTime() + e * 60 * 60 * 1e3), r.setTime(r.getTime() + t * 24 * 60 * 60 * 1e3), r.setTime(r.getTime() + n * 60 * 1e3), r.setTime(r.getTime() + i * 1e3), r.toISOString();
|
|
1897
|
-
},
|
|
1898
|
-
const e = t ===
|
|
1899
|
-
return At(e)(() =>
|
|
1900
|
-
},
|
|
1901
|
-
const n = t ===
|
|
1902
|
-
return At(n)(() =>
|
|
1903
|
-
},
|
|
1897
|
+
}, sr = (s) => At(document)(() => Qe(s)), nr = (s, t) => At(document)(() => Pn(s, t)), ir = (s, t) => {
|
|
1898
|
+
const e = t === _.Local ? window.localStorage : window.sessionStorage;
|
|
1899
|
+
return At(e)(() => zt(s, e));
|
|
1900
|
+
}, rr = (s, t, e) => {
|
|
1901
|
+
const n = t === _.Local ? window.localStorage : window.sessionStorage;
|
|
1902
|
+
return At(n)(() => De(s, n, e));
|
|
1903
|
+
}, fe = (s, t, e, ...n) => {
|
|
1904
1904
|
const i = `[${s.get("$environment").name || "webprovisions"}] ${e}`;
|
|
1905
1905
|
switch (t) {
|
|
1906
1906
|
case "info":
|
|
@@ -1913,16 +1913,16 @@ const Ft = (s, t, e, n = {}) => Es(s, e).then((i) => (process.env.NODE_ENV !== "
|
|
|
1913
1913
|
console.error(i, ...n);
|
|
1914
1914
|
break;
|
|
1915
1915
|
}
|
|
1916
|
-
},
|
|
1916
|
+
}, or = (s) => {
|
|
1917
1917
|
const t = s.container || s;
|
|
1918
1918
|
return {
|
|
1919
|
-
info: (e, ...n) =>
|
|
1920
|
-
warn: (e, ...n) =>
|
|
1921
|
-
error: (e, ...n) =>
|
|
1919
|
+
info: (e, ...n) => fe(t, "info", e, ...n),
|
|
1920
|
+
warn: (e, ...n) => fe(t, "warning", e, ...n),
|
|
1921
|
+
error: (e, ...n) => fe(t, "error", e, ...n)
|
|
1922
1922
|
};
|
|
1923
1923
|
};
|
|
1924
|
-
var
|
|
1925
|
-
const
|
|
1924
|
+
var Ht = /* @__PURE__ */ ((s) => (s.Implementation = "implementation", s.Widget = "widget", s))(Ht || {}), Q = /* @__PURE__ */ ((s) => (s.Pre = "pre", s.Post = "post", s))(Q || {});
|
|
1925
|
+
const ar = (s, t, e, n) => {
|
|
1926
1926
|
try {
|
|
1927
1927
|
const i = new t(e, n);
|
|
1928
1928
|
return {
|
|
@@ -1946,23 +1946,23 @@ const sr = (s, t, e, n) => {
|
|
|
1946
1946
|
throw i;
|
|
1947
1947
|
}
|
|
1948
1948
|
};
|
|
1949
|
-
function
|
|
1949
|
+
function js(s, t) {
|
|
1950
1950
|
return typeof s == "undefined" ? t : s;
|
|
1951
1951
|
}
|
|
1952
|
-
let
|
|
1952
|
+
let cr = class {
|
|
1953
1953
|
constructor(t = {}) {
|
|
1954
1954
|
this.part = t;
|
|
1955
1955
|
}
|
|
1956
1956
|
createCommand(t, e, n) {
|
|
1957
1957
|
let i;
|
|
1958
1958
|
typeof e == "function" ? i = {
|
|
1959
|
-
scope:
|
|
1960
|
-
stage:
|
|
1959
|
+
scope: Ht.Widget,
|
|
1960
|
+
stage: Q.Post,
|
|
1961
1961
|
defaultArgs: void 0,
|
|
1962
1962
|
handlerResolver: e
|
|
1963
1963
|
} : i = {
|
|
1964
|
-
scope:
|
|
1965
|
-
stage:
|
|
1964
|
+
scope: js(e.scope, Ht.Widget),
|
|
1965
|
+
stage: js(e.stage, Q.Post),
|
|
1966
1966
|
defaultArgs: e.defaultArgs,
|
|
1967
1967
|
handlerResolver: n
|
|
1968
1968
|
};
|
|
@@ -1976,26 +1976,26 @@ let nr = class {
|
|
|
1976
1976
|
return this.part;
|
|
1977
1977
|
}
|
|
1978
1978
|
};
|
|
1979
|
-
const
|
|
1980
|
-
const t = new
|
|
1979
|
+
const An = (s) => {
|
|
1980
|
+
const t = new cr({});
|
|
1981
1981
|
return s(t), t.get();
|
|
1982
1982
|
};
|
|
1983
|
-
|
|
1983
|
+
An((s) => {
|
|
1984
1984
|
s.createCommand(
|
|
1985
1985
|
"types.register",
|
|
1986
|
-
{ scope:
|
|
1986
|
+
{ scope: Ht.Implementation, stage: Q.Pre },
|
|
1987
1987
|
(t) => (e, n) => {
|
|
1988
1988
|
t.container.get("$types")[e] = n;
|
|
1989
1989
|
}
|
|
1990
1990
|
).createCommand(
|
|
1991
1991
|
"type",
|
|
1992
|
-
{ stage:
|
|
1992
|
+
{ stage: Q.Pre },
|
|
1993
1993
|
(t) => (e) => {
|
|
1994
1994
|
t.container.register("$type", e);
|
|
1995
1995
|
}
|
|
1996
1996
|
).createCommand(
|
|
1997
1997
|
"settings",
|
|
1998
|
-
{ stage:
|
|
1998
|
+
{ stage: Q.Pre, defaultArgs: [null] },
|
|
1999
1999
|
(t) => (e) => {
|
|
2000
2000
|
t.events.dispatch(
|
|
2001
2001
|
"settings:change",
|
|
@@ -2005,7 +2005,7 @@ bn((s) => {
|
|
|
2005
2005
|
}
|
|
2006
2006
|
).createCommand(
|
|
2007
2007
|
"plugin",
|
|
2008
|
-
{ stage:
|
|
2008
|
+
{ stage: Q.Pre },
|
|
2009
2009
|
(t) => (e, n, i) => {
|
|
2010
2010
|
const { container: r } = t;
|
|
2011
2011
|
let o = null, a = e, c = n;
|
|
@@ -2018,7 +2018,7 @@ bn((s) => {
|
|
|
2018
2018
|
a
|
|
2019
2019
|
) : n;
|
|
2020
2020
|
try {
|
|
2021
|
-
const u =
|
|
2021
|
+
const u = ar(
|
|
2022
2022
|
o,
|
|
2023
2023
|
a,
|
|
2024
2024
|
r,
|
|
@@ -2026,7 +2026,7 @@ bn((s) => {
|
|
|
2026
2026
|
);
|
|
2027
2027
|
r.get("$plugins").push(u), l && u.invoke("initialize", null);
|
|
2028
2028
|
} catch (u) {
|
|
2029
|
-
|
|
2029
|
+
or(t).warn("Error when initializing plugin", u);
|
|
2030
2030
|
}
|
|
2031
2031
|
};
|
|
2032
2032
|
t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
|
|
@@ -2059,12 +2059,12 @@ bn((s) => {
|
|
|
2059
2059
|
}
|
|
2060
2060
|
);
|
|
2061
2061
|
});
|
|
2062
|
-
|
|
2062
|
+
An((s) => {
|
|
2063
2063
|
s.createCommand("storage", (t) => (e = {}) => {
|
|
2064
2064
|
const { consent: n } = e;
|
|
2065
2065
|
if (typeof n != "undefined") {
|
|
2066
2066
|
if (typeof n != "number" && typeof n != "string" && !Array.isArray(n)) {
|
|
2067
|
-
process.env.NODE_ENV !== "production" &&
|
|
2067
|
+
process.env.NODE_ENV !== "production" && k.warn(
|
|
2068
2068
|
`storagePolicyConfigurationApi: passed consent is not valid. Consent either has to be a number, a string, an array of strings or an array of numbers.
|
|
2069
2069
|
Passed consent: ${JSON.stringify(n)}`
|
|
2070
2070
|
);
|
|
@@ -2073,37 +2073,37 @@ bn((s) => {
|
|
|
2073
2073
|
if (Array.isArray(n) && !n.every(
|
|
2074
2074
|
(r) => typeof r == "number" || typeof r == "string"
|
|
2075
2075
|
)) {
|
|
2076
|
-
process.env.NODE_ENV !== "production" &&
|
|
2076
|
+
process.env.NODE_ENV !== "production" && k.warn(
|
|
2077
2077
|
`storagePolicyConfigurationApi: passed consent is not valid. Consent either has to be a number, a string, an array of strings or an array of numbers.
|
|
2078
2078
|
Passed consent: ${JSON.stringify(n)}`
|
|
2079
2079
|
);
|
|
2080
2080
|
return;
|
|
2081
2081
|
}
|
|
2082
2082
|
const i = [
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2083
|
+
x.Necessary,
|
|
2084
|
+
x.Functional,
|
|
2085
|
+
x.Analytical,
|
|
2086
|
+
x.Marketing
|
|
2087
2087
|
].filter((r, o, a) => typeof n == "number" ? n > o : typeof n == "string" ? a.indexOf(n) + 1 > o : Array.isArray(n) ? n.findIndex((c) => c === o + 1 || c === r) > -1 : !0);
|
|
2088
|
-
return i.indexOf(
|
|
2089
|
-
`storagePolicyConfigurationApi: passed consent does not include category: '${
|
|
2088
|
+
return i.indexOf(x.Necessary) === -1 && (process.env.NODE_ENV !== "production" && k.warn(
|
|
2089
|
+
`storagePolicyConfigurationApi: passed consent does not include category: '${x.Necessary}'. Consent has to atleast include the '${x.Necessary}' category.
|
|
2090
2090
|
Passed consent: ${JSON.stringify(n)}`
|
|
2091
|
-
), i.unshift(
|
|
2091
|
+
), i.unshift(x.Necessary)), Gt(
|
|
2092
2092
|
t.container,
|
|
2093
2093
|
"storagePolicy",
|
|
2094
|
-
|
|
2094
|
+
x.Necessary,
|
|
2095
2095
|
{
|
|
2096
|
-
medium:
|
|
2097
|
-
scope:
|
|
2096
|
+
medium: _.Cookie,
|
|
2097
|
+
scope: Zt.Tenant,
|
|
2098
2098
|
duration: { days: 365 }
|
|
2099
2099
|
}
|
|
2100
2100
|
).then((r) => r(i)).then(() => {
|
|
2101
|
-
|
|
2101
|
+
Ye(t.container), t.events.dispatch("storage:policy-changed", i);
|
|
2102
2102
|
});
|
|
2103
2103
|
}
|
|
2104
2104
|
});
|
|
2105
2105
|
});
|
|
2106
|
-
class
|
|
2106
|
+
class hr {
|
|
2107
2107
|
constructor(t) {
|
|
2108
2108
|
this.controller = t, this.cache = /* @__PURE__ */ new Map(), this.subscriptions = [];
|
|
2109
2109
|
const { events: e } = t.container.get("$widget"), n = e.subscribe("data-client:fetched", (i, r) => {
|
|
@@ -2114,7 +2114,7 @@ class ir {
|
|
|
2114
2114
|
getConversationLogs() {
|
|
2115
2115
|
return this.controller.messages.reduce(
|
|
2116
2116
|
(e, n) => {
|
|
2117
|
-
const i =
|
|
2117
|
+
const i = te(n), { content: r, type: o, sender: a, timestamp: c } = i.content, h = this.parseEntry(r, o, a, c);
|
|
2118
2118
|
return h && e.push(h), e;
|
|
2119
2119
|
},
|
|
2120
2120
|
[]
|
|
@@ -2160,7 +2160,7 @@ class ir {
|
|
|
2160
2160
|
return t;
|
|
2161
2161
|
}
|
|
2162
2162
|
createAlias(t, e) {
|
|
2163
|
-
return t ===
|
|
2163
|
+
return t === Et.System ? "system" : (e == null ? void 0 : e.name) || "Me";
|
|
2164
2164
|
}
|
|
2165
2165
|
handleContactMethod(t) {
|
|
2166
2166
|
if (!this.cache.has(t))
|
|
@@ -2210,25 +2210,25 @@ ${e}` : t.length ? `${t} ${e}` : e;
|
|
|
2210
2210
|
});
|
|
2211
2211
|
}
|
|
2212
2212
|
}
|
|
2213
|
-
class
|
|
2213
|
+
class Le {
|
|
2214
2214
|
constructor(t, e) {
|
|
2215
2215
|
this.provider = t, this.print = (n, i) => {
|
|
2216
2216
|
const r = {
|
|
2217
2217
|
name: this.name,
|
|
2218
2218
|
avatar: this.avatar,
|
|
2219
2219
|
id: this.id
|
|
2220
|
-
}, o =
|
|
2220
|
+
}, o = te(n, i);
|
|
2221
2221
|
return this.provider.createEntry(
|
|
2222
2222
|
o.key,
|
|
2223
2223
|
o.content,
|
|
2224
|
-
|
|
2224
|
+
Et.Agent,
|
|
2225
2225
|
r,
|
|
2226
2226
|
o.timestamp
|
|
2227
2227
|
);
|
|
2228
2228
|
}, this.typing = () => this.provider.setTypingState({
|
|
2229
2229
|
name: this.name,
|
|
2230
2230
|
avatar: this.avatar
|
|
2231
|
-
}), this.id = e.id ||
|
|
2231
|
+
}), this.id = e.id || Yt(), this.name = e.name, this.avatar = e.avatar;
|
|
2232
2232
|
}
|
|
2233
2233
|
update(t) {
|
|
2234
2234
|
var i;
|
|
@@ -2238,19 +2238,19 @@ class Te {
|
|
|
2238
2238
|
});
|
|
2239
2239
|
}
|
|
2240
2240
|
}
|
|
2241
|
-
class
|
|
2241
|
+
class Ge {
|
|
2242
2242
|
constructor(t, e, n) {
|
|
2243
2243
|
this.name = t, this.controller = n, this.subscriptions = [], this.user = n == null ? void 0 : n.user, this.options = {
|
|
2244
2244
|
silent: !1
|
|
2245
2245
|
};
|
|
2246
2246
|
}
|
|
2247
2247
|
static create(t, e, n) {
|
|
2248
|
-
return new
|
|
2248
|
+
return new Ge(t, e, n);
|
|
2249
2249
|
}
|
|
2250
2250
|
createAgent(t = {}) {
|
|
2251
2251
|
var e;
|
|
2252
2252
|
if (this.controller) {
|
|
2253
|
-
const n = this.controller.getAgentById(t.id), i = n ? new
|
|
2253
|
+
const n = this.controller.getAgentById(t.id), i = n ? new Le(this, P(P({}, n), t)) : new Le(this, t);
|
|
2254
2254
|
return n || (e = this.controller) == null || e.events.dispatch("conversation:agent-created", {
|
|
2255
2255
|
agent: i
|
|
2256
2256
|
}), i;
|
|
@@ -2313,8 +2313,8 @@ class Fe {
|
|
|
2313
2313
|
}
|
|
2314
2314
|
}
|
|
2315
2315
|
}
|
|
2316
|
-
const
|
|
2317
|
-
class
|
|
2316
|
+
const En = (s) => `conversation-${s}`;
|
|
2317
|
+
class lr {
|
|
2318
2318
|
constructor() {
|
|
2319
2319
|
this._locking = Promise.resolve(), this._locks = 0;
|
|
2320
2320
|
}
|
|
@@ -2331,14 +2331,14 @@ class rr {
|
|
|
2331
2331
|
return this._locking = this._locking.then(() => e), n;
|
|
2332
2332
|
}
|
|
2333
2333
|
}
|
|
2334
|
-
class
|
|
2334
|
+
class dr {
|
|
2335
2335
|
constructor(t, e, n) {
|
|
2336
|
-
this.container = t, this.enabled = n, this.locker = new
|
|
2336
|
+
this.container = t, this.enabled = n, this.locker = new lr(), this.initialStoredAgents = [], this.sessionStorageKey = En(e.id), e.onStarted(() => w(this, null, function* () {
|
|
2337
2337
|
if (e.messages.length > 0)
|
|
2338
2338
|
return;
|
|
2339
2339
|
const { agents: i } = yield this.read(), r = [];
|
|
2340
2340
|
i && i.forEach((a) => {
|
|
2341
|
-
const c = e.providerIndex(a.providerName), h = c > -1 ? e.registeredProviders[c] : e.createProvider(a.providerName), l = new
|
|
2341
|
+
const c = e.providerIndex(a.providerName), h = c > -1 ? e.registeredProviders[c] : e.createProvider(a.providerName), l = new Le(h, {
|
|
2342
2342
|
name: a.name,
|
|
2343
2343
|
avatar: a.avatar,
|
|
2344
2344
|
id: a.id
|
|
@@ -2417,10 +2417,10 @@ class or {
|
|
|
2417
2417
|
if (!this.enabled)
|
|
2418
2418
|
return;
|
|
2419
2419
|
const i = yield this.locker.lock();
|
|
2420
|
-
return
|
|
2420
|
+
return Gt(
|
|
2421
2421
|
this.container,
|
|
2422
2422
|
this.sessionStorageKey,
|
|
2423
|
-
|
|
2423
|
+
x.Necessary
|
|
2424
2424
|
).then((r) => w(this, null, function* () {
|
|
2425
2425
|
if (n === "add") {
|
|
2426
2426
|
const o = yield this.read();
|
|
@@ -2449,28 +2449,28 @@ class or {
|
|
|
2449
2449
|
}
|
|
2450
2450
|
read() {
|
|
2451
2451
|
return w(this, null, function* () {
|
|
2452
|
-
return
|
|
2452
|
+
return K(this.container, this.sessionStorageKey).then((t) => t || {
|
|
2453
2453
|
messages: [],
|
|
2454
2454
|
agents: []
|
|
2455
2455
|
});
|
|
2456
2456
|
});
|
|
2457
2457
|
}
|
|
2458
2458
|
}
|
|
2459
|
-
class
|
|
2459
|
+
class ur {
|
|
2460
2460
|
constructor(t) {
|
|
2461
2461
|
this.controller = t, this.print = (e, n) => {
|
|
2462
|
-
const i =
|
|
2462
|
+
const i = te(e, n);
|
|
2463
2463
|
return this.controller.createEntry(
|
|
2464
2464
|
i.key,
|
|
2465
2465
|
i.content,
|
|
2466
|
-
|
|
2466
|
+
Et.User,
|
|
2467
2467
|
void 0,
|
|
2468
2468
|
i.timestamp
|
|
2469
2469
|
);
|
|
2470
2470
|
};
|
|
2471
2471
|
}
|
|
2472
2472
|
}
|
|
2473
|
-
const
|
|
2473
|
+
const Re = (s, t, e) => w(void 0, null, function* () {
|
|
2474
2474
|
const n = yield s.getAsync("conversation"), i = yield s.getAsync("components"), r = n.controllers.find((o) => o.conversation.id === t);
|
|
2475
2475
|
if (r) {
|
|
2476
2476
|
const o = [...r.conversation.providers];
|
|
@@ -2488,7 +2488,7 @@ const Ie = (s, t, e) => w(void 0, null, function* () {
|
|
|
2488
2488
|
});
|
|
2489
2489
|
}
|
|
2490
2490
|
});
|
|
2491
|
-
class
|
|
2491
|
+
class pr {
|
|
2492
2492
|
constructor(t) {
|
|
2493
2493
|
this.writer = t;
|
|
2494
2494
|
}
|
|
@@ -2503,25 +2503,25 @@ class cr {
|
|
|
2503
2503
|
return typeof t == "string" ? { body: t } : t.length > -1 && typeof t == "object" ? { items: t } : t;
|
|
2504
2504
|
}
|
|
2505
2505
|
}
|
|
2506
|
-
var
|
|
2507
|
-
const
|
|
2508
|
-
let e, n = (t == null ? void 0 : t.key) ||
|
|
2506
|
+
var Et = /* @__PURE__ */ ((s) => (s.User = "user", s.Agent = "agent", s.System = "system", s))(Et || {});
|
|
2507
|
+
const te = (s, t) => {
|
|
2508
|
+
let e, n = (t == null ? void 0 : t.key) || Yt(), i = Date.now();
|
|
2509
2509
|
return Array.isArray(s) && s.length > -1 ? typeof s[0] == "string" ? e = { items: [s] } : e = { items: s } : typeof s == "string" ? e = { body: s } : (s = s || {}, s.type ? e = P({}, s) : (e = {
|
|
2510
2510
|
body: s.body,
|
|
2511
2511
|
actions: s.actions,
|
|
2512
2512
|
title: s.title
|
|
2513
2513
|
}, s.key && (n = s.key), s.timestamp && (i = s.timestamp), s.form, s.timestamp === null && (i = null))), { content: e, key: n, timestamp: i };
|
|
2514
|
-
},
|
|
2514
|
+
}, Ds = (s, t) => {
|
|
2515
2515
|
if (!t)
|
|
2516
2516
|
return;
|
|
2517
2517
|
const e = JSON.stringify(t), n = s.findIndex((i) => e === JSON.stringify(i));
|
|
2518
2518
|
if (n > -1)
|
|
2519
2519
|
return s.splice(n, 1);
|
|
2520
2520
|
};
|
|
2521
|
-
class
|
|
2521
|
+
class gr {
|
|
2522
2522
|
constructor(t, e, n) {
|
|
2523
|
-
this.container = t, this.id = e, this.formHandlers = {}, this.user = new
|
|
2524
|
-
const o =
|
|
2523
|
+
this.container = t, this.id = e, this.formHandlers = {}, this.user = new ur(this), this.providers = [], this.active = !1, this.queuedProviders = [], this.registeredProviders = [], this.loaders = 0, this.componentMounted = !1, this.messages = [], this.typingActors = [], this.print = (r) => {
|
|
2524
|
+
const o = te(r);
|
|
2525
2525
|
return this.createEntry(
|
|
2526
2526
|
o.key,
|
|
2527
2527
|
o.content,
|
|
@@ -2531,7 +2531,7 @@ class hr {
|
|
|
2531
2531
|
);
|
|
2532
2532
|
};
|
|
2533
2533
|
const i = t.get("$widget");
|
|
2534
|
-
this.events = i.events.createChild(this), this.store = new
|
|
2534
|
+
this.events = i.events.createChild(this), this.store = new dr(t, this, n.rehydrate), this.conversationHistory = new hr(this);
|
|
2535
2535
|
}
|
|
2536
2536
|
setInitialStorage(t) {
|
|
2537
2537
|
this.store.setInitialData(t);
|
|
@@ -2552,7 +2552,7 @@ class hr {
|
|
|
2552
2552
|
const e = this.providerIndex(t);
|
|
2553
2553
|
if (e > -1)
|
|
2554
2554
|
return this.registeredProviders[e];
|
|
2555
|
-
const n =
|
|
2555
|
+
const n = Ge.create(t, this.container, this);
|
|
2556
2556
|
return this.registeredProviders.push(n), n;
|
|
2557
2557
|
}
|
|
2558
2558
|
providerIndex(t) {
|
|
@@ -2596,14 +2596,14 @@ class hr {
|
|
|
2596
2596
|
changeProvider(t) {
|
|
2597
2597
|
this.registeredProviders.find(
|
|
2598
2598
|
(n) => n.name === t
|
|
2599
|
-
) &&
|
|
2599
|
+
) && Re(this.container, this.id, t);
|
|
2600
2600
|
}
|
|
2601
2601
|
queueProviders(t) {
|
|
2602
2602
|
this.queuedProviders = t;
|
|
2603
2603
|
}
|
|
2604
2604
|
onCompleteProvider() {
|
|
2605
2605
|
const t = this.queuedProviders.pop();
|
|
2606
|
-
t &&
|
|
2606
|
+
t && Re(this.container, this.id, t);
|
|
2607
2607
|
}
|
|
2608
2608
|
getComponentMountedState() {
|
|
2609
2609
|
return this.componentMounted;
|
|
@@ -2619,10 +2619,10 @@ class hr {
|
|
|
2619
2619
|
sender: i || null,
|
|
2620
2620
|
timestamp: r || r === null ? r : Date.now()
|
|
2621
2621
|
};
|
|
2622
|
-
this.messages.push(o), o.type === "agent" &&
|
|
2623
|
-
const a = new
|
|
2622
|
+
this.messages.push(o), o.type === "agent" && Ds(this.typingActors, i);
|
|
2623
|
+
const a = new pr((c) => {
|
|
2624
2624
|
if (c !== null) {
|
|
2625
|
-
const h = c, { timestamp: l = void 0 } = h, d =
|
|
2625
|
+
const h = c, { timestamp: l = void 0 } = h, d = vs(h, ["timestamp"]);
|
|
2626
2626
|
o.content = d, l && (o.timestamp = l);
|
|
2627
2627
|
} else {
|
|
2628
2628
|
const l = this.messages.indexOf(o);
|
|
@@ -2648,7 +2648,7 @@ class hr {
|
|
|
2648
2648
|
}
|
|
2649
2649
|
setTypingState(t, e) {
|
|
2650
2650
|
return this.typingActors.indexOf(t) === -1 && (this.typingActors.push(t), this.update()), () => {
|
|
2651
|
-
|
|
2651
|
+
Ds(this.typingActors, t), this.update();
|
|
2652
2652
|
};
|
|
2653
2653
|
}
|
|
2654
2654
|
/**
|
|
@@ -2671,17 +2671,17 @@ class hr {
|
|
|
2671
2671
|
return this.conversationHistory.getConversationLogs();
|
|
2672
2672
|
}
|
|
2673
2673
|
}
|
|
2674
|
-
const
|
|
2674
|
+
const mr = (s, t) => {
|
|
2675
2675
|
const e = s.split("_contact");
|
|
2676
2676
|
return t.widgets.get(e[0]);
|
|
2677
|
-
},
|
|
2678
|
-
const t = s.get("$widget"), { name: e, implementation: n } = s.get("$widget"), i = e.indexOf("_contact") > -1 ?
|
|
2677
|
+
}, Xe = (s) => {
|
|
2678
|
+
const t = s.get("$widget"), { name: e, implementation: n } = s.get("$widget"), i = e.indexOf("_contact") > -1 ? mr(e, n) : t, { data: r } = s.get("$settings"), { trigger: o } = i.container.get("$settings"), a = `${e.replace("_contact-method", "").replace("_contact", "")}_contact-method`, c = n.widgets.get(a);
|
|
2679
2679
|
return c && !o ? { chatWidget: c, mainWidget: i, data: r } : { mainWidget: i, data: r };
|
|
2680
|
-
},
|
|
2681
|
-
const { chatWidget: t } =
|
|
2680
|
+
}, vr = (s) => {
|
|
2681
|
+
const { chatWidget: t } = Xe(s);
|
|
2682
2682
|
return !!t;
|
|
2683
|
-
},
|
|
2684
|
-
const { mainWidget: n, data: i, chatWidget: r } =
|
|
2683
|
+
}, Ms = (s, t, e) => {
|
|
2684
|
+
const { mainWidget: n, data: i, chatWidget: r } = Xe(s);
|
|
2685
2685
|
return r ? r.state === "activated" ? r.invoke("open").then(() => {
|
|
2686
2686
|
r.container.getAsync("conversation").then((o) => {
|
|
2687
2687
|
o.navigateToConversationIfActive(t.id);
|
|
@@ -2719,30 +2719,30 @@ const lr = (s, t) => {
|
|
|
2719
2719
|
key: "contact-method",
|
|
2720
2720
|
triggerDOMElement: e,
|
|
2721
2721
|
withRenderState: "open"
|
|
2722
|
-
})).then(() => (
|
|
2722
|
+
})).then(() => (Gt(
|
|
2723
2723
|
r.container,
|
|
2724
2724
|
"activeStickyWidget",
|
|
2725
|
-
|
|
2725
|
+
x.Necessary,
|
|
2726
2726
|
{
|
|
2727
|
-
medium:
|
|
2728
|
-
scope:
|
|
2727
|
+
medium: _.Local,
|
|
2728
|
+
scope: Zt.Implementation
|
|
2729
2729
|
}
|
|
2730
2730
|
).then((o) => o(r.name)), r.container.getAsync("conversation").then((o) => {
|
|
2731
2731
|
o.setConversationEndedBehavior(
|
|
2732
|
-
|
|
2732
|
+
Ut.Deactivate
|
|
2733
2733
|
);
|
|
2734
2734
|
}).then(() => !1))) : (n.container.getAsync("conversation").then((o) => o.navigateToConversationIfActive(t.id).then(
|
|
2735
2735
|
() => o.setConversationEndedBehavior(
|
|
2736
|
-
|
|
2736
|
+
Ut.Navigate
|
|
2737
2737
|
)
|
|
2738
2738
|
)), !r);
|
|
2739
|
-
},
|
|
2740
|
-
const { mainWidget: n, chatWidget: i } =
|
|
2739
|
+
}, fr = (s, t, e = "conversation") => {
|
|
2740
|
+
const { mainWidget: n, chatWidget: i } = Xe(s);
|
|
2741
2741
|
return i ? i.container.getAsync("router").then((r) => {
|
|
2742
2742
|
r.navigate(e, { id: t.id });
|
|
2743
2743
|
}) : n.container.getAsync("conversation").then((r) => {
|
|
2744
2744
|
var o;
|
|
2745
|
-
(o = r.setConversationEndedBehavior(
|
|
2745
|
+
(o = r.setConversationEndedBehavior(Ut.Navigate)) == null || o.then(() => {
|
|
2746
2746
|
n.container.getAsync("router").then((a) => {
|
|
2747
2747
|
n.container.getAsync("components").then((c) => {
|
|
2748
2748
|
const h = c.components().ofType("conversation");
|
|
@@ -2760,26 +2760,26 @@ const lr = (s, t) => {
|
|
|
2760
2760
|
});
|
|
2761
2761
|
});
|
|
2762
2762
|
});
|
|
2763
|
-
},
|
|
2764
|
-
var
|
|
2765
|
-
class
|
|
2763
|
+
}, mt = "conversations";
|
|
2764
|
+
var Ut = /* @__PURE__ */ ((s) => (s.Deactivate = "deactivate", s.Navigate = "navigate", s.None = "none", s))(Ut || {});
|
|
2765
|
+
class ts {
|
|
2766
2766
|
constructor(t, e) {
|
|
2767
2767
|
this.container = t, this.components = e, this.controllers = [], this.providers = [], this.disposeProviders = {}, this.subscriptions = [], this.storageWriter = null, this.router = null, this.buttonQuery = null, this.sessionInfo = null;
|
|
2768
2768
|
const n = t.get("$widget");
|
|
2769
2769
|
this.events = n.events.createChild(this);
|
|
2770
2770
|
}
|
|
2771
2771
|
initialize() {
|
|
2772
|
-
|
|
2772
|
+
Gt(
|
|
2773
2773
|
this.container,
|
|
2774
|
-
|
|
2775
|
-
|
|
2774
|
+
mt,
|
|
2775
|
+
x.Necessary,
|
|
2776
2776
|
{
|
|
2777
|
-
medium:
|
|
2777
|
+
medium: _.Local
|
|
2778
2778
|
}
|
|
2779
|
-
).then((t) => this.storageWriter = t),
|
|
2779
|
+
).then((t) => this.storageWriter = t), K(
|
|
2780
2780
|
this.container,
|
|
2781
|
-
|
|
2782
|
-
|
|
2781
|
+
mt,
|
|
2782
|
+
_.Local
|
|
2783
2783
|
).then((t) => {
|
|
2784
2784
|
this.buttonQuery = this.components.components().ofType("conversation-return-button"), t && (this.sessionInfo = t, t.id && t.route && this.writeToComponents({ active: !0, alert: { show: !1 } }));
|
|
2785
2785
|
}), this.container.getAsync("router").then((t) => this.router = t), this.events.subscribe("conversation:ended", (t, e) => {
|
|
@@ -2802,14 +2802,14 @@ class Qe {
|
|
|
2802
2802
|
static getInstance(t, e = "conversation") {
|
|
2803
2803
|
return At(t)(() => t.getAsync(e).then((n) => {
|
|
2804
2804
|
let i = n;
|
|
2805
|
-
return i ||
|
|
2805
|
+
return i || Ji.getInstance(t).then((r) => (i = new ts(t, r), i.initialize(), t.registerAsync(e, () => i), i));
|
|
2806
2806
|
}));
|
|
2807
2807
|
}
|
|
2808
2808
|
navigateToConversationIfActive(t) {
|
|
2809
|
-
return
|
|
2809
|
+
return K(
|
|
2810
2810
|
this.container,
|
|
2811
|
-
|
|
2812
|
-
|
|
2811
|
+
mt,
|
|
2812
|
+
_.Local
|
|
2813
2813
|
).then((e) => {
|
|
2814
2814
|
var n;
|
|
2815
2815
|
if (e && e.id === t && e.route) {
|
|
@@ -2819,10 +2819,10 @@ class Qe {
|
|
|
2819
2819
|
});
|
|
2820
2820
|
}
|
|
2821
2821
|
setConversationEndedBehavior(t) {
|
|
2822
|
-
return
|
|
2822
|
+
return K(
|
|
2823
2823
|
this.container,
|
|
2824
|
-
|
|
2825
|
-
|
|
2824
|
+
mt,
|
|
2825
|
+
_.Local
|
|
2826
2826
|
).then((e) => {
|
|
2827
2827
|
let n = e;
|
|
2828
2828
|
return n ? n.conversationEndedBehavior = t : n = { conversationEndedBehavior: t }, this.sessionInfo = n, this.storageWriter && this.storageWriter(this.sessionInfo) || Promise.resolve();
|
|
@@ -2830,9 +2830,9 @@ class Qe {
|
|
|
2830
2830
|
}
|
|
2831
2831
|
createController(t, e) {
|
|
2832
2832
|
return w(this, null, function* () {
|
|
2833
|
-
const n =
|
|
2833
|
+
const n = En(t), { agents: i } = (yield K(this.container, n)) || { agents: [] }, r = this.controllers.findIndex((a) => a.conversation.id === t);
|
|
2834
2834
|
let o;
|
|
2835
|
-
return r > -1 ? o = this.controllers[r].conversation : o = new
|
|
2835
|
+
return r > -1 ? o = this.controllers[r].conversation : o = new gr(this.container, t, e), o.setInitialStorage({ agents: i || [] }), o;
|
|
2836
2836
|
});
|
|
2837
2837
|
}
|
|
2838
2838
|
registerProvider(t, e) {
|
|
@@ -2913,10 +2913,10 @@ class Qe {
|
|
|
2913
2913
|
n && (this.disposeProviders[t.name] || (this.disposeProviders[t.name] = []), this.disposeProviders[t.name].push(n));
|
|
2914
2914
|
}
|
|
2915
2915
|
getComponentRoute() {
|
|
2916
|
-
return
|
|
2916
|
+
return K(
|
|
2917
2917
|
this.container,
|
|
2918
|
-
|
|
2919
|
-
|
|
2918
|
+
mt,
|
|
2919
|
+
_.Local
|
|
2920
2920
|
).then((t) => t == null ? void 0 : t.route);
|
|
2921
2921
|
}
|
|
2922
2922
|
dispose() {
|
|
@@ -2930,33 +2930,33 @@ class Qe {
|
|
|
2930
2930
|
}
|
|
2931
2931
|
static handleContactMethodClick(t, e, n, i) {
|
|
2932
2932
|
return w(this, null, function* () {
|
|
2933
|
-
if (
|
|
2933
|
+
if (vr(e)) {
|
|
2934
2934
|
t.preventDefault();
|
|
2935
2935
|
let r = document.getElementById("humany-dynamic-anchor");
|
|
2936
|
-
r || (r = document.createElement("a"), r.setAttribute("href", "#"), r.id = "humany-dynamic-anchor", document.body.appendChild(r)),
|
|
2936
|
+
r || (r = document.createElement("a"), r.setAttribute("href", "#"), r.id = "humany-dynamic-anchor", document.body.appendChild(r)), Ms(e, n, r);
|
|
2937
2937
|
}
|
|
2938
|
-
|
|
2938
|
+
Ms(e, n);
|
|
2939
2939
|
});
|
|
2940
2940
|
}
|
|
2941
2941
|
static handleContactMethodSubmit(t, e) {
|
|
2942
2942
|
return w(this, null, function* () {
|
|
2943
2943
|
var n, i;
|
|
2944
|
-
return (i = (n = e == null ? void 0 : e.body.form.meta) == null ? void 0 : n.conversation) != null && i.id ?
|
|
2944
|
+
return (i = (n = e == null ? void 0 : e.body.form.meta) == null ? void 0 : n.conversation) != null && i.id ? Re(
|
|
2945
2945
|
t,
|
|
2946
2946
|
e.body.form.meta.conversation.id,
|
|
2947
2947
|
e.clientName
|
|
2948
|
-
) :
|
|
2948
|
+
) : fr(t, e);
|
|
2949
2949
|
});
|
|
2950
2950
|
}
|
|
2951
2951
|
}
|
|
2952
|
-
var
|
|
2952
|
+
var yr = Object.defineProperty, br = Object.defineProperties, wr = Object.getOwnPropertyDescriptors, Ls = Object.getOwnPropertySymbols, $r = Object.getPrototypeOf, xr = Object.prototype.hasOwnProperty, _r = Object.prototype.propertyIsEnumerable, Pr = Reflect.get, Rs = (s, t, e) => t in s ? yr(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, es = (s, t) => {
|
|
2953
2953
|
for (var e in t || (t = {}))
|
|
2954
|
-
|
|
2955
|
-
if (
|
|
2956
|
-
for (var e of
|
|
2957
|
-
|
|
2954
|
+
xr.call(t, e) && Rs(s, e, t[e]);
|
|
2955
|
+
if (Ls)
|
|
2956
|
+
for (var e of Ls(t))
|
|
2957
|
+
_r.call(t, e) && Rs(s, e, t[e]);
|
|
2958
2958
|
return s;
|
|
2959
|
-
},
|
|
2959
|
+
}, ss = (s, t) => br(s, wr(t)), Cr = (s, t, e) => Pr($r(s), e, t), at = (s, t, e) => new Promise((n, i) => {
|
|
2960
2960
|
var r = (c) => {
|
|
2961
2961
|
try {
|
|
2962
2962
|
a(e.next(c));
|
|
@@ -2972,7 +2972,7 @@ var pr = Object.defineProperty, gr = Object.defineProperties, mr = Object.getOwn
|
|
|
2972
2972
|
}, a = (c) => c.done ? n(c.value) : Promise.resolve(c.value).then(r, o);
|
|
2973
2973
|
a((e = e.apply(s, t)).next());
|
|
2974
2974
|
});
|
|
2975
|
-
const
|
|
2975
|
+
const ye = (s, t, e, ...n) => {
|
|
2976
2976
|
const i = `[${s.get("$environment").name || "webprovisions"}] ${e}`;
|
|
2977
2977
|
switch (t) {
|
|
2978
2978
|
case "info":
|
|
@@ -2985,16 +2985,16 @@ const pe = (s, t, e, ...n) => {
|
|
|
2985
2985
|
console.error(i, ...n);
|
|
2986
2986
|
break;
|
|
2987
2987
|
}
|
|
2988
|
-
},
|
|
2988
|
+
}, Ar = (s) => {
|
|
2989
2989
|
const t = s.container || s;
|
|
2990
2990
|
return {
|
|
2991
|
-
info: (e, ...n) =>
|
|
2992
|
-
warn: (e, ...n) =>
|
|
2993
|
-
error: (e, ...n) =>
|
|
2991
|
+
info: (e, ...n) => ye(t, "info", e, ...n),
|
|
2992
|
+
warn: (e, ...n) => ye(t, "warning", e, ...n),
|
|
2993
|
+
error: (e, ...n) => ye(t, "error", e, ...n)
|
|
2994
2994
|
};
|
|
2995
2995
|
};
|
|
2996
|
-
var
|
|
2997
|
-
const
|
|
2996
|
+
var Vt = /* @__PURE__ */ ((s) => (s.Implementation = "implementation", s.Widget = "widget", s))(Vt || {}), Y = /* @__PURE__ */ ((s) => (s.Pre = "pre", s.Post = "post", s))(Y || {});
|
|
2997
|
+
const Er = (s, t, e, n) => {
|
|
2998
2998
|
try {
|
|
2999
2999
|
const i = new t(e, n);
|
|
3000
3000
|
return {
|
|
@@ -3018,23 +3018,23 @@ const Ar = (s, t, e, n) => {
|
|
|
3018
3018
|
throw i;
|
|
3019
3019
|
}
|
|
3020
3020
|
};
|
|
3021
|
-
function
|
|
3021
|
+
function Ws(s, t) {
|
|
3022
3022
|
return typeof s == "undefined" ? t : s;
|
|
3023
3023
|
}
|
|
3024
|
-
let
|
|
3024
|
+
let kr = class {
|
|
3025
3025
|
constructor(s = {}) {
|
|
3026
3026
|
this.part = s;
|
|
3027
3027
|
}
|
|
3028
3028
|
createCommand(s, t, e) {
|
|
3029
3029
|
let n;
|
|
3030
3030
|
typeof t == "function" ? n = {
|
|
3031
|
-
scope:
|
|
3032
|
-
stage:
|
|
3031
|
+
scope: Vt.Widget,
|
|
3032
|
+
stage: Y.Post,
|
|
3033
3033
|
defaultArgs: void 0,
|
|
3034
3034
|
handlerResolver: t
|
|
3035
3035
|
} : n = {
|
|
3036
|
-
scope:
|
|
3037
|
-
stage:
|
|
3036
|
+
scope: Ws(t.scope, Vt.Widget),
|
|
3037
|
+
stage: Ws(t.stage, Y.Post),
|
|
3038
3038
|
defaultArgs: t.defaultArgs,
|
|
3039
3039
|
handlerResolver: e
|
|
3040
3040
|
};
|
|
@@ -3048,26 +3048,26 @@ let Pr = class {
|
|
|
3048
3048
|
return this.part;
|
|
3049
3049
|
}
|
|
3050
3050
|
};
|
|
3051
|
-
const
|
|
3052
|
-
const t = new
|
|
3051
|
+
const ns = (s) => {
|
|
3052
|
+
const t = new kr({});
|
|
3053
3053
|
return s(t), t.get();
|
|
3054
3054
|
};
|
|
3055
|
-
|
|
3055
|
+
ns((s) => {
|
|
3056
3056
|
s.createCommand(
|
|
3057
3057
|
"types.register",
|
|
3058
|
-
{ scope:
|
|
3058
|
+
{ scope: Vt.Implementation, stage: Y.Pre },
|
|
3059
3059
|
(t) => (e, n) => {
|
|
3060
3060
|
t.container.get("$types")[e] = n;
|
|
3061
3061
|
}
|
|
3062
3062
|
).createCommand(
|
|
3063
3063
|
"type",
|
|
3064
|
-
{ stage:
|
|
3064
|
+
{ stage: Y.Pre },
|
|
3065
3065
|
(t) => (e) => {
|
|
3066
3066
|
t.container.register("$type", e);
|
|
3067
3067
|
}
|
|
3068
3068
|
).createCommand(
|
|
3069
3069
|
"settings",
|
|
3070
|
-
{ stage:
|
|
3070
|
+
{ stage: Y.Pre, defaultArgs: [null] },
|
|
3071
3071
|
(t) => (e) => {
|
|
3072
3072
|
t.events.dispatch(
|
|
3073
3073
|
"settings:change",
|
|
@@ -3077,7 +3077,7 @@ Ye((s) => {
|
|
|
3077
3077
|
}
|
|
3078
3078
|
).createCommand(
|
|
3079
3079
|
"plugin",
|
|
3080
|
-
{ stage:
|
|
3080
|
+
{ stage: Y.Pre },
|
|
3081
3081
|
(t) => (e, n, i) => {
|
|
3082
3082
|
const { container: r } = t;
|
|
3083
3083
|
let o = null, a = e, c = n;
|
|
@@ -3090,7 +3090,7 @@ Ye((s) => {
|
|
|
3090
3090
|
a
|
|
3091
3091
|
) : n;
|
|
3092
3092
|
try {
|
|
3093
|
-
const u =
|
|
3093
|
+
const u = Er(
|
|
3094
3094
|
o,
|
|
3095
3095
|
a,
|
|
3096
3096
|
r,
|
|
@@ -3098,7 +3098,7 @@ Ye((s) => {
|
|
|
3098
3098
|
);
|
|
3099
3099
|
r.get("$plugins").push(u), l && u.invoke("initialize", null);
|
|
3100
3100
|
} catch (u) {
|
|
3101
|
-
|
|
3101
|
+
Ar(t).warn("Error when initializing plugin", u);
|
|
3102
3102
|
}
|
|
3103
3103
|
};
|
|
3104
3104
|
t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
|
|
@@ -3131,29 +3131,29 @@ Ye((s) => {
|
|
|
3131
3131
|
}
|
|
3132
3132
|
);
|
|
3133
3133
|
});
|
|
3134
|
-
const
|
|
3134
|
+
const ee = (s, t, ...e) => typeof t == "string" ? s(`[humany] ${t}`, ...e) : s(t, ...e), bt = class {
|
|
3135
3135
|
constructor() {
|
|
3136
|
-
this.keys = [], this.log = (s, ...t) => this.lookup(s, () =>
|
|
3136
|
+
this.keys = [], this.log = (s, ...t) => this.lookup(s, () => bt.log(...t)), this.warn = (s, ...t) => this.lookup(s, () => bt.warn(...t)), this.error = (s, ...t) => this.lookup(s, () => bt.error(...t)), this.info = (s, ...t) => this.lookup(s, () => bt.info(...t));
|
|
3137
3137
|
}
|
|
3138
3138
|
lookup(s, t) {
|
|
3139
3139
|
this.keys.indexOf(s) === -1 && (this.keys.push(s), t());
|
|
3140
3140
|
}
|
|
3141
3141
|
};
|
|
3142
|
-
let O =
|
|
3143
|
-
O.log = (...s) =>
|
|
3144
|
-
O.warn = (...s) =>
|
|
3145
|
-
O.error = (...s) =>
|
|
3146
|
-
O.info = (...s) =>
|
|
3147
|
-
const
|
|
3142
|
+
let O = bt;
|
|
3143
|
+
O.log = (...s) => ee(console.log, ...s);
|
|
3144
|
+
O.warn = (...s) => ee(console.warn, ...s);
|
|
3145
|
+
O.error = (...s) => ee(console.error, ...s);
|
|
3146
|
+
O.info = (...s) => ee(console.info, ...s);
|
|
3147
|
+
const kn = (s) => {
|
|
3148
3148
|
let t = {}, e, n;
|
|
3149
3149
|
if (typeof s != "object" || s === null)
|
|
3150
3150
|
return s;
|
|
3151
3151
|
t = Array.isArray(s) ? [] : {};
|
|
3152
3152
|
for (n in s)
|
|
3153
|
-
e = s[n], t[n] = typeof e == "object" && e !== null ?
|
|
3153
|
+
e = s[n], t[n] = typeof e == "object" && e !== null ? kn(e) : e;
|
|
3154
3154
|
return t;
|
|
3155
|
-
},
|
|
3156
|
-
function
|
|
3155
|
+
}, Or = kn;
|
|
3156
|
+
function zs(s) {
|
|
3157
3157
|
let t = 0;
|
|
3158
3158
|
if (s.length === 0)
|
|
3159
3159
|
return t.toString();
|
|
@@ -3163,7 +3163,7 @@ function Is(s) {
|
|
|
3163
3163
|
}
|
|
3164
3164
|
return t.toString();
|
|
3165
3165
|
}
|
|
3166
|
-
let
|
|
3166
|
+
let Sr = class {
|
|
3167
3167
|
constructor(s, t) {
|
|
3168
3168
|
this.lockWarningTime = s, this.lockErrorTime = t, this.tasks = [], this.current = Promise.resolve(), this.next = this.next.bind(this);
|
|
3169
3169
|
}
|
|
@@ -3193,28 +3193,28 @@ let _r = class {
|
|
|
3193
3193
|
});
|
|
3194
3194
|
}
|
|
3195
3195
|
};
|
|
3196
|
-
const
|
|
3197
|
-
function
|
|
3198
|
-
return
|
|
3199
|
-
const o =
|
|
3196
|
+
const It = /* @__PURE__ */ new WeakMap();
|
|
3197
|
+
function se(s, t = 5e3, e = 1e3) {
|
|
3198
|
+
return It.has(s) || It.set(s, new Sr(t, e)), (n) => new Promise((i, r) => {
|
|
3199
|
+
const o = It.get(s);
|
|
3200
3200
|
o.add(n, i, r, () => {
|
|
3201
|
-
o.tasks.length ||
|
|
3201
|
+
o.tasks.length || It.delete(s);
|
|
3202
3202
|
});
|
|
3203
3203
|
});
|
|
3204
3204
|
}
|
|
3205
|
-
const
|
|
3206
|
-
function
|
|
3207
|
-
return
|
|
3205
|
+
const z = () => Math.floor((1 + Math.random()) * 65536).toString(16).substring(1);
|
|
3206
|
+
function ne() {
|
|
3207
|
+
return z() + z() + "-" + z() + "-" + z() + "-" + z() + "-" + z() + z() + z();
|
|
3208
3208
|
}
|
|
3209
|
-
var
|
|
3209
|
+
var Nr = Object.defineProperty, Tr = Object.defineProperties, Ir = Object.getOwnPropertyDescriptors, Hs = Object.getOwnPropertySymbols, jr = Object.prototype.hasOwnProperty, Dr = Object.prototype.propertyIsEnumerable, Us = (s, t, e) => t in s ? Nr(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, Mr = (s, t) => {
|
|
3210
3210
|
for (var e in t || (t = {}))
|
|
3211
|
-
|
|
3212
|
-
if (
|
|
3213
|
-
for (var e of
|
|
3214
|
-
|
|
3211
|
+
jr.call(t, e) && Us(s, e, t[e]);
|
|
3212
|
+
if (Hs)
|
|
3213
|
+
for (var e of Hs(t))
|
|
3214
|
+
Dr.call(t, e) && Us(s, e, t[e]);
|
|
3215
3215
|
return s;
|
|
3216
|
-
},
|
|
3217
|
-
const
|
|
3216
|
+
}, Lr = (s, t) => Tr(s, Ir(t));
|
|
3217
|
+
const Rr = (s) => {
|
|
3218
3218
|
const t = [];
|
|
3219
3219
|
return [
|
|
3220
3220
|
(e, n) => {
|
|
@@ -3227,7 +3227,7 @@ const Ir = (s) => {
|
|
|
3227
3227
|
}
|
|
3228
3228
|
];
|
|
3229
3229
|
};
|
|
3230
|
-
let
|
|
3230
|
+
let ie = class {
|
|
3231
3231
|
constructor(s, t = []) {
|
|
3232
3232
|
this.platform = s, this.rules = t;
|
|
3233
3233
|
}
|
|
@@ -3241,16 +3241,16 @@ let Xt = class {
|
|
|
3241
3241
|
return this.rules.push({ id: s }), this;
|
|
3242
3242
|
}
|
|
3243
3243
|
select() {
|
|
3244
|
-
return new
|
|
3244
|
+
return new Wr(this.platform, this);
|
|
3245
3245
|
}
|
|
3246
|
-
},
|
|
3246
|
+
}, On = class {
|
|
3247
3247
|
constructor(s, t, e) {
|
|
3248
|
-
this.platform = s, this.node = t, this.actions = new
|
|
3248
|
+
this.platform = s, this.node = t, this.actions = new is(
|
|
3249
3249
|
s,
|
|
3250
|
-
new
|
|
3250
|
+
new ie(s).withId(t.id),
|
|
3251
3251
|
e
|
|
3252
3252
|
);
|
|
3253
|
-
const [n, i] =
|
|
3253
|
+
const [n, i] = Rr(this.platform.events);
|
|
3254
3254
|
this.subscribe = n, this.unsubscribe = i;
|
|
3255
3255
|
}
|
|
3256
3256
|
properties(s) {
|
|
@@ -3279,9 +3279,9 @@ let Xt = class {
|
|
|
3279
3279
|
this.unsubscribe(), this.actions.dispose();
|
|
3280
3280
|
}
|
|
3281
3281
|
};
|
|
3282
|
-
class
|
|
3282
|
+
class Wr {
|
|
3283
3283
|
constructor(t, e, n = !0) {
|
|
3284
|
-
this.platform = t, this.target = e, this.clearOnDispose = n, this.removes = [], this.actions = new
|
|
3284
|
+
this.platform = t, this.target = e, this.clearOnDispose = n, this.removes = [], this.actions = new is(this.platform, this.target);
|
|
3285
3285
|
}
|
|
3286
3286
|
writeProperties(t, e) {
|
|
3287
3287
|
this.removes.push(
|
|
@@ -3319,12 +3319,12 @@ class jr {
|
|
|
3319
3319
|
}), this.actions.dispose();
|
|
3320
3320
|
}
|
|
3321
3321
|
}
|
|
3322
|
-
const
|
|
3322
|
+
const zr = (s, t, e) => {
|
|
3323
3323
|
const n = s.concat(), i = (r, o, a) => {
|
|
3324
3324
|
let c = !0;
|
|
3325
3325
|
if (n.length) {
|
|
3326
3326
|
const h = n.shift(), l = (d, p) => (c = !1, i(d, Object.assign({}, o, p), a));
|
|
3327
|
-
return Promise.resolve(h(r, l, a)).then((d) =>
|
|
3327
|
+
return Promise.resolve(h(r, l, a)).then((d) => Lr(Mr({}, d), {
|
|
3328
3328
|
cancelled: c
|
|
3329
3329
|
}));
|
|
3330
3330
|
}
|
|
@@ -3332,7 +3332,7 @@ const Dr = (s, t, e) => {
|
|
|
3332
3332
|
};
|
|
3333
3333
|
return i(t, {}, e);
|
|
3334
3334
|
};
|
|
3335
|
-
let
|
|
3335
|
+
let is = class {
|
|
3336
3336
|
constructor(s, t, e) {
|
|
3337
3337
|
this.platform = s, this.target = t, this.ns = e, this.subscriptions = [], this.create = this.create.bind(this);
|
|
3338
3338
|
}
|
|
@@ -3364,12 +3364,12 @@ let Ze = class {
|
|
|
3364
3364
|
), a = this.platform.actionsState.watchers.filter((c) => c.key === s && (!c.ns || !this.ns || c.ns === this.ns) && o.some((h) => c.target.match(h))).map((c) => c.fn);
|
|
3365
3365
|
return Promise.all(
|
|
3366
3366
|
o.map((c) => {
|
|
3367
|
-
const h = new
|
|
3367
|
+
const h = new On(
|
|
3368
3368
|
this.platform,
|
|
3369
3369
|
c,
|
|
3370
3370
|
this.ns
|
|
3371
3371
|
);
|
|
3372
|
-
return
|
|
3372
|
+
return zr(a, t, h).then((l) => {
|
|
3373
3373
|
const { data: d = {}, options: p, cancelled: u } = l;
|
|
3374
3374
|
return Promise.resolve(
|
|
3375
3375
|
u ? {} : r.fn(d, p, h)
|
|
@@ -3403,7 +3403,7 @@ let Ze = class {
|
|
|
3403
3403
|
this.subscriptions.forEach((s) => s());
|
|
3404
3404
|
}
|
|
3405
3405
|
};
|
|
3406
|
-
|
|
3406
|
+
ns((s) => {
|
|
3407
3407
|
s.createCommand("components", (t) => (e) => {
|
|
3408
3408
|
t.events.subscribeOnce("components:platform-created", (n, { platform: i }) => {
|
|
3409
3409
|
e.handlers && e.handlers.forEach(([r, o]) => {
|
|
@@ -3412,9 +3412,9 @@ Ye((s) => {
|
|
|
3412
3412
|
});
|
|
3413
3413
|
});
|
|
3414
3414
|
});
|
|
3415
|
-
let
|
|
3415
|
+
let Vs = class {
|
|
3416
3416
|
constructor(s, t) {
|
|
3417
|
-
this.events = s, this.tags = [], this.children = {}, this.changesets = [], this.mountCount = 0, this.id =
|
|
3417
|
+
this.events = s, this.tags = [], this.children = {}, this.changesets = [], this.mountCount = 0, this.id = ne(), this.type = t, this.attributes = {
|
|
3418
3418
|
context: {},
|
|
3419
3419
|
properties: {},
|
|
3420
3420
|
layout: {},
|
|
@@ -3497,49 +3497,49 @@ let Ms = class {
|
|
|
3497
3497
|
}), delete s.parent;
|
|
3498
3498
|
}
|
|
3499
3499
|
};
|
|
3500
|
-
const
|
|
3500
|
+
const Sn = (s, t, e) => {
|
|
3501
3501
|
for (let n = 0, i = s.length; n < i && e(s[n]) !== !0; n++) {
|
|
3502
3502
|
const r = t[s[n].id] || "default", o = s[n].getChildren(r);
|
|
3503
|
-
|
|
3503
|
+
Sn(o, t, e);
|
|
3504
3504
|
}
|
|
3505
|
-
},
|
|
3505
|
+
}, rs = (s, t, e) => {
|
|
3506
3506
|
if (e(s) !== !0) {
|
|
3507
3507
|
const n = t[s.id] || "default", i = s.children[n];
|
|
3508
|
-
|
|
3508
|
+
Sn(i, t, e);
|
|
3509
3509
|
}
|
|
3510
|
-
},
|
|
3510
|
+
}, be = (s, t) => {
|
|
3511
3511
|
const e = [];
|
|
3512
|
-
return
|
|
3512
|
+
return rs(s, t, (n) => {
|
|
3513
3513
|
e.push(n);
|
|
3514
3514
|
}), e;
|
|
3515
|
-
},
|
|
3515
|
+
}, Hr = (s, t, e) => {
|
|
3516
3516
|
let n;
|
|
3517
|
-
return
|
|
3517
|
+
return rs(s, t, (i) => {
|
|
3518
3518
|
if (e(i))
|
|
3519
3519
|
return n = i, !0;
|
|
3520
3520
|
}), n;
|
|
3521
3521
|
};
|
|
3522
|
-
let
|
|
3522
|
+
let Ur = class {
|
|
3523
3523
|
constructor(s, t, e) {
|
|
3524
3524
|
this.root = s, this.switches = t, this.all = [], this.visible = [], this.detached = [], e.subscribe("components:node-appended", (n, i) => {
|
|
3525
|
-
this.all.push(i.node), this.visible =
|
|
3525
|
+
this.all.push(i.node), this.visible = be(s, t);
|
|
3526
3526
|
}), e.subscribe("components:node-removed", (n, i) => {
|
|
3527
3527
|
let r = this.all.indexOf(i.node);
|
|
3528
|
-
r > -1 && this.all.splice(r, 1), r = this.visible.indexOf(i.node), r > -1 && this.visible.splice(r, 1), this.visible =
|
|
3528
|
+
r > -1 && this.all.splice(r, 1), r = this.visible.indexOf(i.node), r > -1 && this.visible.splice(r, 1), this.visible = be(s, t);
|
|
3529
3529
|
}), e.subscribe("components:node-switched", (n, i) => {
|
|
3530
|
-
this.visible =
|
|
3530
|
+
this.visible = be(s, t);
|
|
3531
3531
|
});
|
|
3532
3532
|
}
|
|
3533
3533
|
query(s = {}) {
|
|
3534
3534
|
const t = [];
|
|
3535
|
-
return
|
|
3535
|
+
return rs(this.root, this.switches, (e) => {
|
|
3536
3536
|
Object.keys(s).every((n) => s[n] === e[n]) && t.push(e);
|
|
3537
3537
|
}), t;
|
|
3538
3538
|
}
|
|
3539
3539
|
get(s) {
|
|
3540
|
-
return
|
|
3540
|
+
return Hr(this.root, this.switches, (t) => t.id === s) || this.detached.find((t) => t.id === s);
|
|
3541
3541
|
}
|
|
3542
|
-
},
|
|
3542
|
+
}, Vr = class {
|
|
3543
3543
|
constructor() {
|
|
3544
3544
|
this.handlers = /* @__PURE__ */ new Map();
|
|
3545
3545
|
}
|
|
@@ -3550,49 +3550,49 @@ let Rr = class {
|
|
|
3550
3550
|
return this.handlers.get(s);
|
|
3551
3551
|
}
|
|
3552
3552
|
};
|
|
3553
|
-
const
|
|
3553
|
+
const Br = (s) => {
|
|
3554
3554
|
let t = s, e = 0;
|
|
3555
3555
|
for (; t.parent; )
|
|
3556
3556
|
e = e + 1, t = t.parent;
|
|
3557
3557
|
return e;
|
|
3558
|
-
},
|
|
3558
|
+
}, Jr = (s) => s.map(([t, e]) => [Br(t), t, e]).sort(([t], [e]) => t - e).map(([, t, e]) => [t, e]), we = (s) => s instanceof Date ? !1 : s && typeof s == "object" && !Array.isArray(s), I = (s, ...t) => {
|
|
3559
3559
|
if (!t.length)
|
|
3560
3560
|
return s;
|
|
3561
3561
|
const e = t.shift();
|
|
3562
|
-
if (
|
|
3562
|
+
if (we(s) && we(e))
|
|
3563
3563
|
for (const n in e)
|
|
3564
|
-
|
|
3565
|
-
return
|
|
3566
|
-
},
|
|
3564
|
+
we(e[n]) ? (s[n] || Object.assign(s, { [n]: {} }), I(s[n], e[n])) : Object.assign(s, { [n]: e[n] });
|
|
3565
|
+
return I(s, ...t);
|
|
3566
|
+
}, qr = (s, t) => !s || s === "all" ? !0 : s.some((e) => t.indexOf(e) > -1), Fr = (s, t) => {
|
|
3567
3567
|
let e = [], n = [], i;
|
|
3568
3568
|
const r = () => {
|
|
3569
3569
|
process.env.NODE_ENV !== "production" && console.time("state-processor.flush");
|
|
3570
|
-
const a = /* @__PURE__ */ new Map(), c =
|
|
3570
|
+
const a = /* @__PURE__ */ new Map(), c = Jr(e.map((l, d) => [l, n[d]])), h = (l, d) => {
|
|
3571
3571
|
var p;
|
|
3572
|
-
const u = a.get(l) || {}, g = d.context && !u.context, m = d.properties && !u.properties,
|
|
3572
|
+
const u = a.get(l) || {}, g = d.context && !u.context, m = d.properties && !u.properties, A = d.layout && !u.layout;
|
|
3573
3573
|
a.set(l, {
|
|
3574
3574
|
context: u.context || g,
|
|
3575
3575
|
properties: u.properties || m,
|
|
3576
|
-
layout: u.layout ||
|
|
3577
|
-
}), m && (l.attributes.properties = {}),
|
|
3578
|
-
const
|
|
3576
|
+
layout: u.layout || A
|
|
3577
|
+
}), m && (l.attributes.properties = {}), A && (l.attributes.layout = {}), g && (l.attributes.context = I({}, (p = l.parent) == null ? void 0 : p.attributes.context));
|
|
3578
|
+
const L = [], ut = [], pt = [];
|
|
3579
3579
|
if (l.changesets.forEach((b) => {
|
|
3580
|
-
const [v,
|
|
3581
|
-
|
|
3580
|
+
const [v, J] = b;
|
|
3581
|
+
qr(J.breakpoints, s.breakpoints) && (m && (typeof v.properties == "function" ? L.push(
|
|
3582
3582
|
v.properties
|
|
3583
|
-
) :
|
|
3584
|
-
}),
|
|
3585
|
-
|
|
3586
|
-
}),
|
|
3587
|
-
|
|
3588
|
-
}),
|
|
3589
|
-
|
|
3583
|
+
) : I(l.attributes.properties, v.properties)), A && (typeof v.layout == "function" ? ut.push(v.layout) : I(l.attributes.layout, v.layout)), g && (typeof v.context == "function" ? pt.push(v.context) : I(l.attributes.context, v.context)));
|
|
3584
|
+
}), L.forEach((b) => {
|
|
3585
|
+
I(l.attributes.properties, b(l.attributes.properties));
|
|
3586
|
+
}), ut.forEach((b) => {
|
|
3587
|
+
I(l.attributes.layout, b(l.attributes.layout));
|
|
3588
|
+
}), pt.forEach((b) => {
|
|
3589
|
+
I(l.attributes.context, b(l.attributes.context));
|
|
3590
3590
|
}), g || d.recursive) {
|
|
3591
3591
|
const b = s.getBranch(l), v = d.recursive ? d : {
|
|
3592
3592
|
context: !!g
|
|
3593
3593
|
};
|
|
3594
|
-
l.getChildren(b).forEach((
|
|
3595
|
-
h(
|
|
3594
|
+
l.getChildren(b).forEach((J) => {
|
|
3595
|
+
h(J, v);
|
|
3596
3596
|
});
|
|
3597
3597
|
}
|
|
3598
3598
|
};
|
|
@@ -3611,12 +3611,12 @@ const Hr = (s) => {
|
|
|
3611
3611
|
return e.push(a), n.push(c), o();
|
|
3612
3612
|
};
|
|
3613
3613
|
};
|
|
3614
|
-
let
|
|
3614
|
+
let os = class {
|
|
3615
3615
|
constructor(s, t = {}) {
|
|
3616
|
-
this.providers = t, this.breakpoints = [], this.actionsState = { handlers: [], watchers: [] }, this.switches = {}, this.changesets = [], this.subscriptions = [], this.customComponentHandler = new
|
|
3617
|
-
const e = new
|
|
3618
|
-
e.name = `root-${s.name}`, this.nodes = new
|
|
3619
|
-
const n = this.processNode =
|
|
3616
|
+
this.providers = t, this.breakpoints = [], this.actionsState = { handlers: [], watchers: [] }, this.switches = {}, this.changesets = [], this.subscriptions = [], this.customComponentHandler = new Vr(), this.events = s.events.createChild(this);
|
|
3617
|
+
const e = new Vs(this.events, "root");
|
|
3618
|
+
e.name = `root-${s.name}`, this.nodes = new Ur(e, this.switches, this.events);
|
|
3619
|
+
const n = this.processNode = Fr(this, (i) => {
|
|
3620
3620
|
const r = Array.from(i.keys());
|
|
3621
3621
|
process.env.NODE_ENV !== "production" && console.info(`STATE PROCESSOR: ${r.length} node(s) processed:
|
|
3622
3622
|
${r.map(
|
|
@@ -3721,17 +3721,17 @@ ${r.map(
|
|
|
3721
3721
|
* @param type Type of node.
|
|
3722
3722
|
*/
|
|
3723
3723
|
createNode(s, t = {}) {
|
|
3724
|
-
const e = new
|
|
3724
|
+
const e = new Vs(this.events, s);
|
|
3725
3725
|
return t.detached && this.nodes.detached.push(e), e;
|
|
3726
3726
|
}
|
|
3727
3727
|
components() {
|
|
3728
|
-
return new
|
|
3728
|
+
return new ie(this);
|
|
3729
3729
|
}
|
|
3730
3730
|
actions(s, t) {
|
|
3731
|
-
return new
|
|
3731
|
+
return new is(this, s, t);
|
|
3732
3732
|
}
|
|
3733
3733
|
write(s) {
|
|
3734
|
-
const { provider: t, target: e, attributes: n, options: i = {}, removable: r } = s, o = s.key ||
|
|
3734
|
+
const { provider: t, target: e, attributes: n, options: i = {}, removable: r } = s, o = s.key || ne(), a = { changeset: [n, i], target: e, removes: [] };
|
|
3735
3735
|
if (t) {
|
|
3736
3736
|
const c = this.providers[t];
|
|
3737
3737
|
c.write(o, e, n, i), a.removes.push(() => {
|
|
@@ -3762,16 +3762,21 @@ ${r.map(
|
|
|
3762
3762
|
this.subscriptions.forEach((s) => s());
|
|
3763
3763
|
}
|
|
3764
3764
|
};
|
|
3765
|
-
const
|
|
3765
|
+
const Bs = (s, t) => ({
|
|
3766
|
+
id: s.id,
|
|
3767
|
+
type: s.type,
|
|
3768
|
+
name: s.name,
|
|
3769
|
+
branch: t || "default"
|
|
3770
|
+
}), Kr = (s, t, e, n = ne(), i = {}) => s.getAsync("components").then((r) => {
|
|
3766
3771
|
let o;
|
|
3767
3772
|
if (typeof t == "string") {
|
|
3768
|
-
const h = new
|
|
3773
|
+
const h = new ie(r);
|
|
3769
3774
|
h.ofType(t), o = h;
|
|
3770
3775
|
} else
|
|
3771
3776
|
o = t;
|
|
3772
3777
|
const a = {}, c = (h) => {
|
|
3773
3778
|
const l = a[h.id];
|
|
3774
|
-
return l ? Promise.resolve(l.controller) :
|
|
3779
|
+
return l ? Promise.resolve(l.controller) : os.getInstance(s).then((d) => new On(d, h, n));
|
|
3775
3780
|
};
|
|
3776
3781
|
r.events.subscribe(
|
|
3777
3782
|
"components:node-enter",
|
|
@@ -3794,20 +3799,20 @@ const Vr = (s, t, e, n = Gt(), i = {}) => s.getAsync("components").then((r) => {
|
|
|
3794
3799
|
);
|
|
3795
3800
|
});
|
|
3796
3801
|
process.env.NODE_ENV;
|
|
3797
|
-
var
|
|
3802
|
+
var Qr = Object.defineProperty, Js = Object.getOwnPropertySymbols, Yr = Object.prototype.hasOwnProperty, Zr = Object.prototype.propertyIsEnumerable, qs = (s, t, e) => t in s ? Qr(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, nt = (s, t) => {
|
|
3798
3803
|
for (var e in t || (t = {}))
|
|
3799
|
-
|
|
3800
|
-
if (
|
|
3801
|
-
for (var e of
|
|
3802
|
-
|
|
3804
|
+
Yr.call(t, e) && qs(s, e, t[e]);
|
|
3805
|
+
if (Js)
|
|
3806
|
+
for (var e of Js(t))
|
|
3807
|
+
Zr.call(t, e) && qs(s, e, t[e]);
|
|
3803
3808
|
return s;
|
|
3804
|
-
},
|
|
3805
|
-
const
|
|
3809
|
+
}, M = /* @__PURE__ */ ((s) => (s.Cookie = "cookie", s.Local = "local", s.Session = "session", s))(M || {}), as = /* @__PURE__ */ ((s) => (s.Tenant = "tenant", s.Implementation = "implementation", s.Widget = "widget", s))(as || {}), E = /* @__PURE__ */ ((s) => (s.Necessary = "necessary", s.Functional = "functional", s.Analytical = "analytical", s.Marketing = "marketing", s))(E || {});
|
|
3810
|
+
const Gr = (s, t, e, n = {}) => Fs(s, e).then((i) => (process.env.NODE_ENV !== "production" && i && O.warn(
|
|
3806
3811
|
`createStorageWriter: Attempted to create storage writer using unallowed category.
|
|
3807
3812
|
Key: ${t}
|
|
3808
3813
|
Category: ${JSON.stringify(e)}
|
|
3809
3814
|
Options: ${JSON.stringify(n)}`
|
|
3810
|
-
), (r) => (
|
|
3815
|
+
), (r) => (hs(s), Fs(s, e).then((o) => {
|
|
3811
3816
|
if (o) {
|
|
3812
3817
|
process.env.NODE_ENV !== "production" && O.warn(
|
|
3813
3818
|
`storageWriter: Attempted to write to storage using unallowed category.
|
|
@@ -3819,103 +3824,103 @@ const Fr = (s, t, e, n = {}) => Hs(s, e).then((i) => (process.env.NODE_ENV !== "
|
|
|
3819
3824
|
return;
|
|
3820
3825
|
}
|
|
3821
3826
|
const {
|
|
3822
|
-
scope: a =
|
|
3823
|
-
medium: c =
|
|
3827
|
+
scope: a = as.Widget,
|
|
3828
|
+
medium: c = M.Session,
|
|
3824
3829
|
duration: h
|
|
3825
|
-
} = n, l =
|
|
3826
|
-
return l[a][t] =
|
|
3827
|
-
})))),
|
|
3830
|
+
} = n, l = eo();
|
|
3831
|
+
return l[a][t] = In(r, e, h), c === M.Cookie ? oo(s, l) : co(s, c, l);
|
|
3832
|
+
})))), Xr = (s, t, e = M.Session) => (hs(s), typeof t == "undefined" ? (process.env.NODE_ENV !== "production" && O.warn("readStorage: Undefined key passed when reading storage. ", t, e), Promise.resolve(void 0)) : e === M.Cookie ? ro(s).then((n) => ze(n, t)) : ao(s, e).then((n) => ze(n, t))), ct = (s) => !!Object.entries(s).filter(([t, e]) => typeof e != "undefined").length, $e = (s) => Object.entries(s).filter(([t, e]) => typeof e != "undefined").forEach(([t, { value: e }]) => {
|
|
3828
3833
|
typeof e == "undefined" && delete s[t];
|
|
3829
|
-
}),
|
|
3834
|
+
}), Nn = (s, t) => {
|
|
3830
3835
|
const e = {
|
|
3831
|
-
tenant:
|
|
3832
|
-
implementation:
|
|
3833
|
-
widget:
|
|
3836
|
+
tenant: nt(nt({}, s.tenant), t.tenant),
|
|
3837
|
+
implementation: nt(nt({}, s.implementation), t.implementation),
|
|
3838
|
+
widget: nt(nt({}, s.widget), t.widget)
|
|
3834
3839
|
};
|
|
3835
|
-
return
|
|
3836
|
-
},
|
|
3840
|
+
return $e(e.tenant), $e(e.implementation), $e(e.widget), e;
|
|
3841
|
+
}, to = (s) => Object.entries(s).reduce((t, e) => {
|
|
3837
3842
|
const [n, i] = e;
|
|
3838
3843
|
return Object.entries(i).forEach((r) => {
|
|
3839
3844
|
const [o, { expiration: a }] = r;
|
|
3840
3845
|
a && t.push(a);
|
|
3841
3846
|
}), t;
|
|
3842
|
-
}, []).slice().sort((t, e) => new Date(e).valueOf() - new Date(t).valueOf()).shift() ||
|
|
3847
|
+
}, []).slice().sort((t, e) => new Date(e).valueOf() - new Date(t).valueOf()).shift() || ls(), re = (s) => {
|
|
3843
3848
|
const {
|
|
3844
3849
|
name: t,
|
|
3845
3850
|
implementation: { name: e, tenant: n }
|
|
3846
3851
|
} = s.get("$widget");
|
|
3847
3852
|
return [
|
|
3848
3853
|
`humany_${n}`,
|
|
3849
|
-
`humany_${
|
|
3850
|
-
`humany_${
|
|
3854
|
+
`humany_${zs(n + e)}`,
|
|
3855
|
+
`humany_${zs(n + e + t)}`
|
|
3851
3856
|
];
|
|
3852
|
-
},
|
|
3857
|
+
}, xe = (s) => {
|
|
3853
3858
|
const t = new RegExp(`(?:^|;)\\s?${s}=(.*?)(?:;|$)`, "i"), e = document.cookie.match(t);
|
|
3854
3859
|
return e && e[1] && JSON.parse(e[1]) || void 0;
|
|
3855
|
-
},
|
|
3860
|
+
}, _e = (s, t, e) => {
|
|
3856
3861
|
const n = `${s}=${JSON.stringify(t).trim()}`, i = `expires=${new Date(e).toUTCString()}`, r = "path=/", o = "SameSite=None;Secure";
|
|
3857
3862
|
return document.cookie = `${n}; ${i}; ${r}; ${o}`;
|
|
3858
|
-
},
|
|
3859
|
-
const [t, e, n] =
|
|
3863
|
+
}, cs = (s) => {
|
|
3864
|
+
const [t, e, n] = re(s), i = xe(t) || {}, r = xe(e) || {}, o = xe(n) || {};
|
|
3860
3865
|
return {
|
|
3861
3866
|
tenant: i,
|
|
3862
3867
|
implementation: r,
|
|
3863
3868
|
widget: o
|
|
3864
3869
|
};
|
|
3865
|
-
},
|
|
3866
|
-
const e =
|
|
3867
|
-
|
|
3870
|
+
}, Tn = (s, t) => {
|
|
3871
|
+
const e = cs(s), n = Nn(e, t), [i, r, o] = re(s), { tenant: a, implementation: c, widget: h } = n, l = to(t), d = ls({ days: -1 });
|
|
3872
|
+
_e(i, a, ct(a) ? l : d), _e(
|
|
3868
3873
|
r,
|
|
3869
3874
|
c,
|
|
3870
|
-
|
|
3871
|
-
),
|
|
3872
|
-
},
|
|
3873
|
-
const [e, n, i] =
|
|
3875
|
+
ct(c) ? l : d
|
|
3876
|
+
), _e(o, h, ct(h) ? l : d);
|
|
3877
|
+
}, Bt = (s, t) => {
|
|
3878
|
+
const [e, n, i] = re(s), r = t.getItem(e) || "{}", o = t.getItem(n) || "{}", a = t.getItem(i) || "{}";
|
|
3874
3879
|
return {
|
|
3875
3880
|
tenant: JSON.parse(r),
|
|
3876
3881
|
implementation: JSON.parse(o),
|
|
3877
3882
|
widget: JSON.parse(a)
|
|
3878
3883
|
};
|
|
3879
|
-
},
|
|
3880
|
-
const n =
|
|
3881
|
-
|
|
3882
|
-
},
|
|
3884
|
+
}, We = (s, t, e) => {
|
|
3885
|
+
const n = Bt(s, t), i = Nn(n, e), [r, o, a] = re(s), { tenant: c, implementation: h, widget: l } = i;
|
|
3886
|
+
ct(c) ? t.setItem(r, JSON.stringify(c)) : t.removeItem(r), ct(h) ? t.setItem(o, JSON.stringify(h)) : t.removeItem(o), ct(l) ? t.setItem(a, JSON.stringify(l)) : t.removeItem(a);
|
|
3887
|
+
}, eo = () => ({ tenant: {}, implementation: {}, widget: {} }), so = (s) => s ? !!s && /* @__PURE__ */ new Date() > new Date(s) : !1, ze = (s, t) => {
|
|
3883
3888
|
const e = s.widget[t] || s.implementation[t] || s.tenant[t];
|
|
3884
3889
|
return e == null ? void 0 : e.value;
|
|
3885
|
-
},
|
|
3890
|
+
}, In = (s, t, e) => e ? {
|
|
3886
3891
|
value: s,
|
|
3887
3892
|
category: t,
|
|
3888
|
-
expiration: typeof e == "object" ?
|
|
3893
|
+
expiration: typeof e == "object" ? ls(e) : e
|
|
3889
3894
|
} : {
|
|
3890
3895
|
value: s,
|
|
3891
3896
|
category: t
|
|
3892
|
-
},
|
|
3893
|
-
const e =
|
|
3897
|
+
}, no = (s, t) => {
|
|
3898
|
+
const e = Or(s);
|
|
3894
3899
|
return Object.entries(e).forEach(([n, i]) => {
|
|
3895
3900
|
Object.entries(i).forEach(([r, o]) => {
|
|
3896
3901
|
const { expiration: a, category: c } = o;
|
|
3897
|
-
(
|
|
3902
|
+
(so(a) || io(t, c)) && (i[r] = In(void 0, c, a));
|
|
3898
3903
|
});
|
|
3899
3904
|
}), e;
|
|
3900
|
-
},
|
|
3905
|
+
}, Fs = (s, t) => Xr(s, "storagePolicy", M.Cookie).then(
|
|
3901
3906
|
(e = [E.Necessary]) => !!t && e.indexOf(t) === -1
|
|
3902
|
-
),
|
|
3903
|
-
const t =
|
|
3907
|
+
), io = (s = [E.Necessary], t) => !!t && s.indexOf(t) === -1, hs = (s) => {
|
|
3908
|
+
const t = cs(s), e = Bt(s, window.localStorage), n = Bt(s, sessionStorage), i = ze(t, "storagePolicy"), [r, o, a] = [
|
|
3904
3909
|
t,
|
|
3905
3910
|
e,
|
|
3906
3911
|
n
|
|
3907
|
-
].map((c) =>
|
|
3908
|
-
|
|
3909
|
-
},
|
|
3912
|
+
].map((c) => no(c, i));
|
|
3913
|
+
Tn(s, r), We(s, window.localStorage, o), We(s, window.sessionStorage, a);
|
|
3914
|
+
}, ls = (s = { days: 30 }) => {
|
|
3910
3915
|
const { days: t = 0, hours: e = 0, minutes: n = 0, seconds: i = 0 } = s, r = /* @__PURE__ */ new Date();
|
|
3911
3916
|
return r.setTime(r.getTime() + e * 60 * 60 * 1e3), r.setTime(r.getTime() + t * 24 * 60 * 60 * 1e3), r.setTime(r.getTime() + n * 60 * 1e3), r.setTime(r.getTime() + i * 1e3), r.toISOString();
|
|
3912
|
-
},
|
|
3913
|
-
const e = t ===
|
|
3914
|
-
return
|
|
3915
|
-
},
|
|
3916
|
-
const n = t ===
|
|
3917
|
-
return
|
|
3918
|
-
},
|
|
3917
|
+
}, ro = (s) => se(document)(() => cs(s)), oo = (s, t) => se(document)(() => Tn(s, t)), ao = (s, t) => {
|
|
3918
|
+
const e = t === M.Local ? window.localStorage : window.sessionStorage;
|
|
3919
|
+
return se(e)(() => Bt(s, e));
|
|
3920
|
+
}, co = (s, t, e) => {
|
|
3921
|
+
const n = t === M.Local ? window.localStorage : window.sessionStorage;
|
|
3922
|
+
return se(n)(() => We(s, n, e));
|
|
3923
|
+
}, Pe = (s, t, e, ...n) => {
|
|
3919
3924
|
const i = `[${s.get("$environment").name || "webprovisions"}] ${e}`;
|
|
3920
3925
|
switch (t) {
|
|
3921
3926
|
case "info":
|
|
@@ -3928,16 +3933,16 @@ const Fr = (s, t, e, n = {}) => Hs(s, e).then((i) => (process.env.NODE_ENV !== "
|
|
|
3928
3933
|
console.error(i, ...n);
|
|
3929
3934
|
break;
|
|
3930
3935
|
}
|
|
3931
|
-
},
|
|
3936
|
+
}, ho = (s) => {
|
|
3932
3937
|
const t = s.container || s;
|
|
3933
3938
|
return {
|
|
3934
|
-
info: (e, ...n) =>
|
|
3935
|
-
warn: (e, ...n) =>
|
|
3936
|
-
error: (e, ...n) =>
|
|
3939
|
+
info: (e, ...n) => Pe(t, "info", e, ...n),
|
|
3940
|
+
warn: (e, ...n) => Pe(t, "warning", e, ...n),
|
|
3941
|
+
error: (e, ...n) => Pe(t, "error", e, ...n)
|
|
3937
3942
|
};
|
|
3938
3943
|
};
|
|
3939
|
-
var
|
|
3940
|
-
const
|
|
3944
|
+
var Jt = /* @__PURE__ */ ((s) => (s.Implementation = "implementation", s.Widget = "widget", s))(Jt || {}), Z = /* @__PURE__ */ ((s) => (s.Pre = "pre", s.Post = "post", s))(Z || {});
|
|
3945
|
+
const lo = (s, t, e, n) => {
|
|
3941
3946
|
try {
|
|
3942
3947
|
const i = new t(e, n);
|
|
3943
3948
|
return {
|
|
@@ -3961,23 +3966,23 @@ const ro = (s, t, e, n) => {
|
|
|
3961
3966
|
throw i;
|
|
3962
3967
|
}
|
|
3963
3968
|
};
|
|
3964
|
-
function
|
|
3969
|
+
function Ks(s, t) {
|
|
3965
3970
|
return typeof s == "undefined" ? t : s;
|
|
3966
3971
|
}
|
|
3967
|
-
let
|
|
3972
|
+
let uo = class {
|
|
3968
3973
|
constructor(s = {}) {
|
|
3969
3974
|
this.part = s;
|
|
3970
3975
|
}
|
|
3971
3976
|
createCommand(s, t, e) {
|
|
3972
3977
|
let n;
|
|
3973
3978
|
typeof t == "function" ? n = {
|
|
3974
|
-
scope:
|
|
3975
|
-
stage:
|
|
3979
|
+
scope: Jt.Widget,
|
|
3980
|
+
stage: Z.Post,
|
|
3976
3981
|
defaultArgs: void 0,
|
|
3977
3982
|
handlerResolver: t
|
|
3978
3983
|
} : n = {
|
|
3979
|
-
scope:
|
|
3980
|
-
stage:
|
|
3984
|
+
scope: Ks(t.scope, Jt.Widget),
|
|
3985
|
+
stage: Ks(t.stage, Z.Post),
|
|
3981
3986
|
defaultArgs: t.defaultArgs,
|
|
3982
3987
|
handlerResolver: e
|
|
3983
3988
|
};
|
|
@@ -3991,26 +3996,26 @@ let oo = class {
|
|
|
3991
3996
|
return this.part;
|
|
3992
3997
|
}
|
|
3993
3998
|
};
|
|
3994
|
-
const
|
|
3995
|
-
const t = new
|
|
3999
|
+
const jn = (s) => {
|
|
4000
|
+
const t = new uo({});
|
|
3996
4001
|
return s(t), t.get();
|
|
3997
4002
|
};
|
|
3998
|
-
|
|
4003
|
+
jn((s) => {
|
|
3999
4004
|
s.createCommand(
|
|
4000
4005
|
"types.register",
|
|
4001
|
-
{ scope:
|
|
4006
|
+
{ scope: Jt.Implementation, stage: Z.Pre },
|
|
4002
4007
|
(t) => (e, n) => {
|
|
4003
4008
|
t.container.get("$types")[e] = n;
|
|
4004
4009
|
}
|
|
4005
4010
|
).createCommand(
|
|
4006
4011
|
"type",
|
|
4007
|
-
{ stage:
|
|
4012
|
+
{ stage: Z.Pre },
|
|
4008
4013
|
(t) => (e) => {
|
|
4009
4014
|
t.container.register("$type", e);
|
|
4010
4015
|
}
|
|
4011
4016
|
).createCommand(
|
|
4012
4017
|
"settings",
|
|
4013
|
-
{ stage:
|
|
4018
|
+
{ stage: Z.Pre, defaultArgs: [null] },
|
|
4014
4019
|
(t) => (e) => {
|
|
4015
4020
|
t.events.dispatch(
|
|
4016
4021
|
"settings:change",
|
|
@@ -4020,7 +4025,7 @@ Sn((s) => {
|
|
|
4020
4025
|
}
|
|
4021
4026
|
).createCommand(
|
|
4022
4027
|
"plugin",
|
|
4023
|
-
{ stage:
|
|
4028
|
+
{ stage: Z.Pre },
|
|
4024
4029
|
(t) => (e, n, i) => {
|
|
4025
4030
|
const { container: r } = t;
|
|
4026
4031
|
let o = null, a = e, c = n;
|
|
@@ -4033,7 +4038,7 @@ Sn((s) => {
|
|
|
4033
4038
|
a
|
|
4034
4039
|
) : n;
|
|
4035
4040
|
try {
|
|
4036
|
-
const u =
|
|
4041
|
+
const u = lo(
|
|
4037
4042
|
o,
|
|
4038
4043
|
a,
|
|
4039
4044
|
r,
|
|
@@ -4041,7 +4046,7 @@ Sn((s) => {
|
|
|
4041
4046
|
);
|
|
4042
4047
|
r.get("$plugins").push(u), l && u.invoke("initialize", null);
|
|
4043
4048
|
} catch (u) {
|
|
4044
|
-
|
|
4049
|
+
ho(t).warn("Error when initializing plugin", u);
|
|
4045
4050
|
}
|
|
4046
4051
|
};
|
|
4047
4052
|
t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
|
|
@@ -4074,7 +4079,7 @@ Sn((s) => {
|
|
|
4074
4079
|
}
|
|
4075
4080
|
);
|
|
4076
4081
|
});
|
|
4077
|
-
|
|
4082
|
+
jn((s) => {
|
|
4078
4083
|
s.createCommand("storage", (t) => (e = {}) => {
|
|
4079
4084
|
const { consent: n } = e;
|
|
4080
4085
|
if (typeof n != "undefined") {
|
|
@@ -4103,22 +4108,22 @@ Sn((s) => {
|
|
|
4103
4108
|
return i.indexOf(E.Necessary) === -1 && (process.env.NODE_ENV !== "production" && O.warn(
|
|
4104
4109
|
`storagePolicyConfigurationApi: passed consent does not include category: '${E.Necessary}'. Consent has to atleast include the '${E.Necessary}' category.
|
|
4105
4110
|
Passed consent: ${JSON.stringify(n)}`
|
|
4106
|
-
), i.unshift(E.Necessary)),
|
|
4111
|
+
), i.unshift(E.Necessary)), Gr(
|
|
4107
4112
|
t.container,
|
|
4108
4113
|
"storagePolicy",
|
|
4109
4114
|
E.Necessary,
|
|
4110
4115
|
{
|
|
4111
|
-
medium:
|
|
4112
|
-
scope:
|
|
4116
|
+
medium: M.Cookie,
|
|
4117
|
+
scope: as.Tenant,
|
|
4113
4118
|
duration: { days: 365 }
|
|
4114
4119
|
}
|
|
4115
4120
|
).then((r) => r(i)).then(() => {
|
|
4116
|
-
|
|
4121
|
+
hs(t.container), t.events.dispatch("storage:policy-changed", i);
|
|
4117
4122
|
});
|
|
4118
4123
|
}
|
|
4119
4124
|
});
|
|
4120
4125
|
});
|
|
4121
|
-
function
|
|
4126
|
+
function Dn(s) {
|
|
4122
4127
|
if (s.__esModule)
|
|
4123
4128
|
return s;
|
|
4124
4129
|
var t = s.default;
|
|
@@ -4145,9 +4150,9 @@ function Nn(s) {
|
|
|
4145
4150
|
});
|
|
4146
4151
|
}), e;
|
|
4147
4152
|
}
|
|
4148
|
-
var
|
|
4153
|
+
var Mn = function() {
|
|
4149
4154
|
};
|
|
4150
|
-
process.env.NODE_ENV !== "production" && (
|
|
4155
|
+
process.env.NODE_ENV !== "production" && (Mn = function(s, t, e) {
|
|
4151
4156
|
var n = arguments.length;
|
|
4152
4157
|
e = new Array(n > 2 ? n - 2 : 0);
|
|
4153
4158
|
for (var i = 2; i < n; i++)
|
|
@@ -4171,22 +4176,22 @@ process.env.NODE_ENV !== "production" && (Tn = function(s, t, e) {
|
|
|
4171
4176
|
}
|
|
4172
4177
|
}
|
|
4173
4178
|
});
|
|
4174
|
-
var
|
|
4175
|
-
|
|
4176
|
-
function
|
|
4179
|
+
var po = Mn, go = po;
|
|
4180
|
+
mo(go);
|
|
4181
|
+
function mo(s) {
|
|
4177
4182
|
return s && s.__esModule ? s : { default: s };
|
|
4178
4183
|
}
|
|
4179
|
-
function
|
|
4184
|
+
function jt(s) {
|
|
4180
4185
|
return s.charAt(0) === "/";
|
|
4181
4186
|
}
|
|
4182
|
-
function
|
|
4187
|
+
function Ce(s, t) {
|
|
4183
4188
|
for (var e = t, n = e + 1, i = s.length; n < i; e += 1, n += 1)
|
|
4184
4189
|
s[e] = s[n];
|
|
4185
4190
|
s.pop();
|
|
4186
4191
|
}
|
|
4187
|
-
function
|
|
4188
|
-
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", e = s && s.split("/") || [], n = t && t.split("/") || [], i = s &&
|
|
4189
|
-
if (s &&
|
|
4192
|
+
function vo(s) {
|
|
4193
|
+
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", e = s && s.split("/") || [], n = t && t.split("/") || [], i = s && jt(s), r = t && jt(t), o = i || r;
|
|
4194
|
+
if (s && jt(s) ? n = e : e.length && (n.pop(), n = n.concat(e)), !n.length)
|
|
4190
4195
|
return "/";
|
|
4191
4196
|
var a = void 0;
|
|
4192
4197
|
if (n.length) {
|
|
@@ -4196,59 +4201,59 @@ function lo(s) {
|
|
|
4196
4201
|
a = !1;
|
|
4197
4202
|
for (var h = 0, l = n.length; l >= 0; l--) {
|
|
4198
4203
|
var d = n[l];
|
|
4199
|
-
d === "." ?
|
|
4204
|
+
d === "." ? Ce(n, l) : d === ".." ? (Ce(n, l), h++) : h && (Ce(n, l), h--);
|
|
4200
4205
|
}
|
|
4201
4206
|
if (!o)
|
|
4202
4207
|
for (; h--; h)
|
|
4203
4208
|
n.unshift("..");
|
|
4204
|
-
o && n[0] !== "" && (!n[0] || !
|
|
4209
|
+
o && n[0] !== "" && (!n[0] || !jt(n[0])) && n.unshift("");
|
|
4205
4210
|
var p = n.join("/");
|
|
4206
4211
|
return a && p.substr(-1) !== "/" && (p += "/"), p;
|
|
4207
4212
|
}
|
|
4208
|
-
const
|
|
4213
|
+
const fo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
4209
4214
|
__proto__: null,
|
|
4210
|
-
default:
|
|
4211
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
4212
|
-
var
|
|
4215
|
+
default: vo
|
|
4216
|
+
}, Symbol.toStringTag, { value: "Module" })), yo = /* @__PURE__ */ Dn(fo);
|
|
4217
|
+
var Qs = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(s) {
|
|
4213
4218
|
return typeof s;
|
|
4214
4219
|
} : function(s) {
|
|
4215
4220
|
return s && typeof Symbol == "function" && s.constructor === Symbol && s !== Symbol.prototype ? "symbol" : typeof s;
|
|
4216
4221
|
};
|
|
4217
|
-
function
|
|
4222
|
+
function Mt(s, t) {
|
|
4218
4223
|
if (s === t)
|
|
4219
4224
|
return !0;
|
|
4220
4225
|
if (s == null || t == null)
|
|
4221
4226
|
return !1;
|
|
4222
4227
|
if (Array.isArray(s))
|
|
4223
4228
|
return Array.isArray(t) && s.length === t.length && s.every(function(c, h) {
|
|
4224
|
-
return
|
|
4229
|
+
return Mt(c, t[h]);
|
|
4225
4230
|
});
|
|
4226
|
-
var e = typeof s == "undefined" ? "undefined" :
|
|
4231
|
+
var e = typeof s == "undefined" ? "undefined" : Qs(s), n = typeof t == "undefined" ? "undefined" : Qs(t);
|
|
4227
4232
|
if (e !== n)
|
|
4228
4233
|
return !1;
|
|
4229
4234
|
if (e === "object") {
|
|
4230
4235
|
var i = s.valueOf(), r = t.valueOf();
|
|
4231
4236
|
if (i !== s || r !== t)
|
|
4232
|
-
return
|
|
4237
|
+
return Mt(i, r);
|
|
4233
4238
|
var o = Object.keys(s), a = Object.keys(t);
|
|
4234
4239
|
return o.length !== a.length ? !1 : o.every(function(c) {
|
|
4235
|
-
return
|
|
4240
|
+
return Mt(s[c], t[c]);
|
|
4236
4241
|
});
|
|
4237
4242
|
}
|
|
4238
4243
|
return !1;
|
|
4239
4244
|
}
|
|
4240
|
-
const
|
|
4245
|
+
const bo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
4241
4246
|
__proto__: null,
|
|
4242
|
-
default:
|
|
4243
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
4244
|
-
var
|
|
4245
|
-
|
|
4246
|
-
var
|
|
4247
|
-
|
|
4248
|
-
function
|
|
4247
|
+
default: Mt
|
|
4248
|
+
}, Symbol.toStringTag, { value: "Module" })), wo = /* @__PURE__ */ Dn(bo);
|
|
4249
|
+
var $o = yo;
|
|
4250
|
+
Ln($o);
|
|
4251
|
+
var xo = wo;
|
|
4252
|
+
Ln(xo);
|
|
4253
|
+
function Ln(s) {
|
|
4249
4254
|
return s && s.__esModule ? s : { default: s };
|
|
4250
4255
|
}
|
|
4251
|
-
|
|
4256
|
+
ns((s) => {
|
|
4252
4257
|
s.createCommand("routing", (t) => (e) => {
|
|
4253
4258
|
const n = {
|
|
4254
4259
|
mode: e.mode
|
|
@@ -4256,7 +4261,7 @@ Ye((s) => {
|
|
|
4256
4261
|
e.basePath && (n.basePath = e.basePath), t.container.register("routingSettings", n);
|
|
4257
4262
|
});
|
|
4258
4263
|
});
|
|
4259
|
-
const
|
|
4264
|
+
const Ae = (s, t, e, ...n) => {
|
|
4260
4265
|
const i = `[${s.get("$environment").name || "webprovisions"}] ${e}`;
|
|
4261
4266
|
switch (t) {
|
|
4262
4267
|
case "info":
|
|
@@ -4269,16 +4274,16 @@ const $e = (s, t, e, ...n) => {
|
|
|
4269
4274
|
console.error(i, ...n);
|
|
4270
4275
|
break;
|
|
4271
4276
|
}
|
|
4272
|
-
},
|
|
4277
|
+
}, _o = (s) => {
|
|
4273
4278
|
const t = s.container || s;
|
|
4274
4279
|
return {
|
|
4275
|
-
info: (e, ...n) =>
|
|
4276
|
-
warn: (e, ...n) =>
|
|
4277
|
-
error: (e, ...n) =>
|
|
4280
|
+
info: (e, ...n) => Ae(t, "info", e, ...n),
|
|
4281
|
+
warn: (e, ...n) => Ae(t, "warning", e, ...n),
|
|
4282
|
+
error: (e, ...n) => Ae(t, "error", e, ...n)
|
|
4278
4283
|
};
|
|
4279
4284
|
};
|
|
4280
|
-
var
|
|
4281
|
-
const
|
|
4285
|
+
var xt = /* @__PURE__ */ ((s) => (s.Implementation = "implementation", s.Widget = "widget", s))(xt || {}), B = /* @__PURE__ */ ((s) => (s.Pre = "pre", s.Post = "post", s))(B || {});
|
|
4286
|
+
const Po = (s, t, e, n) => {
|
|
4282
4287
|
try {
|
|
4283
4288
|
const i = new t(e, n);
|
|
4284
4289
|
return {
|
|
@@ -4302,23 +4307,23 @@ const bo = (s, t, e, n) => {
|
|
|
4302
4307
|
throw i;
|
|
4303
4308
|
}
|
|
4304
4309
|
};
|
|
4305
|
-
function
|
|
4310
|
+
function Ys(s, t) {
|
|
4306
4311
|
return typeof s == "undefined" ? t : s;
|
|
4307
4312
|
}
|
|
4308
|
-
class
|
|
4313
|
+
class Co {
|
|
4309
4314
|
constructor(t = {}) {
|
|
4310
4315
|
this.part = t;
|
|
4311
4316
|
}
|
|
4312
4317
|
createCommand(t, e, n) {
|
|
4313
4318
|
let i;
|
|
4314
4319
|
typeof e == "function" ? i = {
|
|
4315
|
-
scope:
|
|
4316
|
-
stage:
|
|
4320
|
+
scope: xt.Widget,
|
|
4321
|
+
stage: B.Post,
|
|
4317
4322
|
defaultArgs: void 0,
|
|
4318
4323
|
handlerResolver: e
|
|
4319
4324
|
} : i = {
|
|
4320
|
-
scope:
|
|
4321
|
-
stage:
|
|
4325
|
+
scope: Ys(e.scope, xt.Widget),
|
|
4326
|
+
stage: Ys(e.stage, B.Post),
|
|
4322
4327
|
defaultArgs: e.defaultArgs,
|
|
4323
4328
|
handlerResolver: n
|
|
4324
4329
|
};
|
|
@@ -4332,26 +4337,26 @@ class wo {
|
|
|
4332
4337
|
return this.part;
|
|
4333
4338
|
}
|
|
4334
4339
|
}
|
|
4335
|
-
const
|
|
4336
|
-
const t = new
|
|
4340
|
+
const Rn = (s) => {
|
|
4341
|
+
const t = new Co({});
|
|
4337
4342
|
return s(t), t.get();
|
|
4338
4343
|
};
|
|
4339
|
-
|
|
4344
|
+
Rn((s) => {
|
|
4340
4345
|
s.createCommand(
|
|
4341
4346
|
"types.register",
|
|
4342
|
-
{ scope:
|
|
4347
|
+
{ scope: xt.Implementation, stage: B.Pre },
|
|
4343
4348
|
(t) => (e, n) => {
|
|
4344
4349
|
t.container.get("$types")[e] = n;
|
|
4345
4350
|
}
|
|
4346
4351
|
).createCommand(
|
|
4347
4352
|
"type",
|
|
4348
|
-
{ stage:
|
|
4353
|
+
{ stage: B.Pre },
|
|
4349
4354
|
(t) => (e) => {
|
|
4350
4355
|
t.container.register("$type", e);
|
|
4351
4356
|
}
|
|
4352
4357
|
).createCommand(
|
|
4353
4358
|
"settings",
|
|
4354
|
-
{ stage:
|
|
4359
|
+
{ stage: B.Pre, defaultArgs: [null] },
|
|
4355
4360
|
(t) => (e) => {
|
|
4356
4361
|
t.events.dispatch(
|
|
4357
4362
|
"settings:change",
|
|
@@ -4361,7 +4366,7 @@ jn((s) => {
|
|
|
4361
4366
|
}
|
|
4362
4367
|
).createCommand(
|
|
4363
4368
|
"plugin",
|
|
4364
|
-
{ stage:
|
|
4369
|
+
{ stage: B.Pre },
|
|
4365
4370
|
(t) => (e, n, i) => {
|
|
4366
4371
|
const { container: r } = t;
|
|
4367
4372
|
let o = null, a = e, c = n;
|
|
@@ -4374,7 +4379,7 @@ jn((s) => {
|
|
|
4374
4379
|
a
|
|
4375
4380
|
) : n;
|
|
4376
4381
|
try {
|
|
4377
|
-
const u =
|
|
4382
|
+
const u = Po(
|
|
4378
4383
|
o,
|
|
4379
4384
|
a,
|
|
4380
4385
|
r,
|
|
@@ -4382,7 +4387,7 @@ jn((s) => {
|
|
|
4382
4387
|
);
|
|
4383
4388
|
r.get("$plugins").push(u), l && u.invoke("initialize", null);
|
|
4384
4389
|
} catch (u) {
|
|
4385
|
-
|
|
4390
|
+
_o(t).warn("Error when initializing plugin", u);
|
|
4386
4391
|
}
|
|
4387
4392
|
};
|
|
4388
4393
|
t.container.get("$instance") ? h(!0) : t.events.subscribeOnce("widget:instance-created", () => h(!1));
|
|
@@ -4415,10 +4420,10 @@ jn((s) => {
|
|
|
4415
4420
|
}
|
|
4416
4421
|
);
|
|
4417
4422
|
});
|
|
4418
|
-
|
|
4423
|
+
Rn((s) => {
|
|
4419
4424
|
s.createCommand(
|
|
4420
4425
|
"ready",
|
|
4421
|
-
{ scope:
|
|
4426
|
+
{ scope: xt.Implementation, stage: B.Pre },
|
|
4422
4427
|
(t) => (e) => {
|
|
4423
4428
|
const { container: n } = t, i = n.owner;
|
|
4424
4429
|
n.get("bootstrapping").ready ? e(i) : i.events.subscribeOnce("bootstrap:ready", () => {
|
|
@@ -4432,19 +4437,19 @@ jn((s) => {
|
|
|
4432
4437
|
* Copyright 2019 Google LLC
|
|
4433
4438
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
4434
4439
|
*/
|
|
4435
|
-
const
|
|
4436
|
-
let
|
|
4440
|
+
const Lt = window, ds = Lt.ShadowRoot && (Lt.ShadyCSS === void 0 || Lt.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, us = Symbol(), Zs = /* @__PURE__ */ new WeakMap();
|
|
4441
|
+
let Wn = class {
|
|
4437
4442
|
constructor(s, t, e) {
|
|
4438
|
-
if (this._$cssResult$ = !0, e !==
|
|
4443
|
+
if (this._$cssResult$ = !0, e !== us)
|
|
4439
4444
|
throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
4440
4445
|
this.cssText = s, this.t = t;
|
|
4441
4446
|
}
|
|
4442
4447
|
get styleSheet() {
|
|
4443
4448
|
let s = this.o;
|
|
4444
4449
|
const t = this.t;
|
|
4445
|
-
if (
|
|
4450
|
+
if (ds && s === void 0) {
|
|
4446
4451
|
const e = t !== void 0 && t.length === 1;
|
|
4447
|
-
e && (s =
|
|
4452
|
+
e && (s = Zs.get(t)), s === void 0 && ((this.o = s = new CSSStyleSheet()).replaceSync(this.cssText), e && Zs.set(t, s));
|
|
4448
4453
|
}
|
|
4449
4454
|
return s;
|
|
4450
4455
|
}
|
|
@@ -4452,7 +4457,7 @@ let Dn = class {
|
|
|
4452
4457
|
return this.cssText;
|
|
4453
4458
|
}
|
|
4454
4459
|
};
|
|
4455
|
-
const
|
|
4460
|
+
const Ao = (s) => new Wn(typeof s == "string" ? s : s + "", void 0, us), zn = (s, ...t) => {
|
|
4456
4461
|
const e = s.length === 1 ? s[0] : t.reduce((n, i, r) => n + ((o) => {
|
|
4457
4462
|
if (o._$cssResult$ === !0)
|
|
4458
4463
|
return o.cssText;
|
|
@@ -4460,28 +4465,28 @@ const $o = (s) => new Dn(typeof s == "string" ? s : s + "", void 0, is), Ao = (s
|
|
|
4460
4465
|
return o;
|
|
4461
4466
|
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.");
|
|
4462
4467
|
})(i) + s[r + 1], s[0]);
|
|
4463
|
-
return new
|
|
4464
|
-
},
|
|
4465
|
-
|
|
4466
|
-
const n = document.createElement("style"), i =
|
|
4468
|
+
return new Wn(e, s, us);
|
|
4469
|
+
}, Eo = (s, t) => {
|
|
4470
|
+
ds ? s.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet) : t.forEach((e) => {
|
|
4471
|
+
const n = document.createElement("style"), i = Lt.litNonce;
|
|
4467
4472
|
i !== void 0 && n.setAttribute("nonce", i), n.textContent = e.cssText, s.appendChild(n);
|
|
4468
4473
|
});
|
|
4469
|
-
},
|
|
4474
|
+
}, Gs = ds ? (s) => s : (s) => s instanceof CSSStyleSheet ? ((t) => {
|
|
4470
4475
|
let e = "";
|
|
4471
4476
|
for (const n of t.cssRules)
|
|
4472
4477
|
e += n.cssText;
|
|
4473
|
-
return
|
|
4478
|
+
return Ao(e);
|
|
4474
4479
|
})(s) : s;
|
|
4475
4480
|
/**
|
|
4476
4481
|
* @license
|
|
4477
4482
|
* Copyright 2017 Google LLC
|
|
4478
4483
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
4479
4484
|
*/
|
|
4480
|
-
var
|
|
4481
|
-
const
|
|
4485
|
+
var Ee;
|
|
4486
|
+
const qt = window, Xs = qt.trustedTypes, ko = Xs ? Xs.emptyScript : "", tn = qt.reactiveElementPolyfillSupport, He = { toAttribute(s, t) {
|
|
4482
4487
|
switch (t) {
|
|
4483
4488
|
case Boolean:
|
|
4484
|
-
s = s ?
|
|
4489
|
+
s = s ? ko : null;
|
|
4485
4490
|
break;
|
|
4486
4491
|
case Object:
|
|
4487
4492
|
case Array:
|
|
@@ -4506,8 +4511,8 @@ const Ut = window, Js = Ut.trustedTypes, xo = Js ? Js.emptyScript : "", qs = Ut.
|
|
|
4506
4511
|
}
|
|
4507
4512
|
}
|
|
4508
4513
|
return e;
|
|
4509
|
-
} },
|
|
4510
|
-
let
|
|
4514
|
+
} }, Hn = (s, t) => t !== s && (t == t || s == s), ke = { attribute: !0, type: String, converter: He, reflect: !1, hasChanged: Hn }, Ue = "finalized";
|
|
4515
|
+
let it = class extends HTMLElement {
|
|
4511
4516
|
constructor() {
|
|
4512
4517
|
super(), this._$Ei = /* @__PURE__ */ new Map(), this.isUpdatePending = !1, this.hasUpdated = !1, this._$El = null, this._$Eu();
|
|
4513
4518
|
}
|
|
@@ -4523,7 +4528,7 @@ let et = class extends HTMLElement {
|
|
|
4523
4528
|
n !== void 0 && (this._$Ev.set(n, e), s.push(n));
|
|
4524
4529
|
}), s;
|
|
4525
4530
|
}
|
|
4526
|
-
static createProperty(s, t =
|
|
4531
|
+
static createProperty(s, t = ke) {
|
|
4527
4532
|
if (t.state && (t.attribute = !1), this.finalize(), this.elementProperties.set(s, t), !t.noAccessor && !this.prototype.hasOwnProperty(s)) {
|
|
4528
4533
|
const e = typeof s == "symbol" ? Symbol() : "__" + s, n = this.getPropertyDescriptor(s, e, t);
|
|
4529
4534
|
n !== void 0 && Object.defineProperty(this.prototype, s, n);
|
|
@@ -4538,12 +4543,12 @@ let et = class extends HTMLElement {
|
|
|
4538
4543
|
}, configurable: !0, enumerable: !0 };
|
|
4539
4544
|
}
|
|
4540
4545
|
static getPropertyOptions(s) {
|
|
4541
|
-
return this.elementProperties.get(s) ||
|
|
4546
|
+
return this.elementProperties.get(s) || ke;
|
|
4542
4547
|
}
|
|
4543
4548
|
static finalize() {
|
|
4544
|
-
if (this.hasOwnProperty(
|
|
4549
|
+
if (this.hasOwnProperty(Ue))
|
|
4545
4550
|
return !1;
|
|
4546
|
-
this[
|
|
4551
|
+
this[Ue] = !0;
|
|
4547
4552
|
const s = Object.getPrototypeOf(this);
|
|
4548
4553
|
if (s.finalize(), s.h !== void 0 && (this.h = [...s.h]), this.elementProperties = new Map(s.elementProperties), this._$Ev = /* @__PURE__ */ new Map(), this.hasOwnProperty("properties")) {
|
|
4549
4554
|
const t = this.properties, e = [...Object.getOwnPropertyNames(t), ...Object.getOwnPropertySymbols(t)];
|
|
@@ -4557,9 +4562,9 @@ let et = class extends HTMLElement {
|
|
|
4557
4562
|
if (Array.isArray(s)) {
|
|
4558
4563
|
const e = new Set(s.flat(1 / 0).reverse());
|
|
4559
4564
|
for (const n of e)
|
|
4560
|
-
t.unshift(
|
|
4565
|
+
t.unshift(Gs(n));
|
|
4561
4566
|
} else
|
|
4562
|
-
s !== void 0 && t.push(
|
|
4567
|
+
s !== void 0 && t.push(Gs(s));
|
|
4563
4568
|
return t;
|
|
4564
4569
|
}
|
|
4565
4570
|
static _$Ep(s, t) {
|
|
@@ -4586,7 +4591,7 @@ let et = class extends HTMLElement {
|
|
|
4586
4591
|
createRenderRoot() {
|
|
4587
4592
|
var s;
|
|
4588
4593
|
const t = (s = this.shadowRoot) !== null && s !== void 0 ? s : this.attachShadow(this.constructor.shadowRootOptions);
|
|
4589
|
-
return
|
|
4594
|
+
return Eo(t, this.constructor.elementStyles), t;
|
|
4590
4595
|
}
|
|
4591
4596
|
connectedCallback() {
|
|
4592
4597
|
var s;
|
|
@@ -4607,11 +4612,11 @@ let et = class extends HTMLElement {
|
|
|
4607
4612
|
attributeChangedCallback(s, t, e) {
|
|
4608
4613
|
this._$AK(s, e);
|
|
4609
4614
|
}
|
|
4610
|
-
_$EO(s, t, e =
|
|
4615
|
+
_$EO(s, t, e = ke) {
|
|
4611
4616
|
var n;
|
|
4612
4617
|
const i = this.constructor._$Ep(s, e);
|
|
4613
4618
|
if (i !== void 0 && e.reflect === !0) {
|
|
4614
|
-
const r = (((n = e.converter) === null || n === void 0 ? void 0 : n.toAttribute) !== void 0 ? e.converter :
|
|
4619
|
+
const r = (((n = e.converter) === null || n === void 0 ? void 0 : n.toAttribute) !== void 0 ? e.converter : He).toAttribute(t, e.type);
|
|
4615
4620
|
this._$El = s, r == null ? this.removeAttribute(i) : this.setAttribute(i, r), this._$El = null;
|
|
4616
4621
|
}
|
|
4617
4622
|
}
|
|
@@ -4619,16 +4624,16 @@ let et = class extends HTMLElement {
|
|
|
4619
4624
|
var e;
|
|
4620
4625
|
const n = this.constructor, i = n._$Ev.get(s);
|
|
4621
4626
|
if (i !== void 0 && this._$El !== i) {
|
|
4622
|
-
const r = n.getPropertyOptions(i), o = typeof r.converter == "function" ? { fromAttribute: r.converter } : ((e = r.converter) === null || e === void 0 ? void 0 : e.fromAttribute) !== void 0 ? r.converter :
|
|
4627
|
+
const r = n.getPropertyOptions(i), o = typeof r.converter == "function" ? { fromAttribute: r.converter } : ((e = r.converter) === null || e === void 0 ? void 0 : e.fromAttribute) !== void 0 ? r.converter : He;
|
|
4623
4628
|
this._$El = i, this[i] = o.fromAttribute(t, r.type), this._$El = null;
|
|
4624
4629
|
}
|
|
4625
4630
|
}
|
|
4626
4631
|
requestUpdate(s, t, e) {
|
|
4627
4632
|
let n = !0;
|
|
4628
|
-
s !== void 0 && (((e = e || this.constructor.getPropertyOptions(s)).hasChanged ||
|
|
4633
|
+
s !== void 0 && (((e = e || this.constructor.getPropertyOptions(s)).hasChanged || Hn)(this[s], t) ? (this._$AL.has(s) || this._$AL.set(s, t), e.reflect === !0 && this._$El !== s && (this._$EC === void 0 && (this._$EC = /* @__PURE__ */ new Map()), this._$EC.set(s, e))) : n = !1), !this.isUpdatePending && n && (this._$E_ = this._$Ej());
|
|
4629
4634
|
}
|
|
4630
4635
|
_$Ej() {
|
|
4631
|
-
return
|
|
4636
|
+
return at(this, null, function* () {
|
|
4632
4637
|
this.isUpdatePending = !0;
|
|
4633
4638
|
try {
|
|
4634
4639
|
yield this._$E_;
|
|
@@ -4688,94 +4693,94 @@ let et = class extends HTMLElement {
|
|
|
4688
4693
|
firstUpdated(s) {
|
|
4689
4694
|
}
|
|
4690
4695
|
};
|
|
4691
|
-
|
|
4696
|
+
it[Ue] = !0, it.elementProperties = /* @__PURE__ */ new Map(), it.elementStyles = [], it.shadowRootOptions = { mode: "open" }, tn == null || tn({ ReactiveElement: it }), ((Ee = qt.reactiveElementVersions) !== null && Ee !== void 0 ? Ee : qt.reactiveElementVersions = []).push("1.6.3");
|
|
4692
4697
|
/**
|
|
4693
4698
|
* @license
|
|
4694
4699
|
* Copyright 2017 Google LLC
|
|
4695
4700
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
4696
4701
|
*/
|
|
4697
|
-
var
|
|
4698
|
-
const
|
|
4699
|
-
\f\r]`,
|
|
4700
|
-
\f\r"'\`<>=]|("|')|))|$)`, "g"),
|
|
4701
|
-
function
|
|
4702
|
+
var Oe;
|
|
4703
|
+
const Ft = window, ht = Ft.trustedTypes, en = ht ? ht.createPolicy("lit-html", { createHTML: (s) => s }) : void 0, Ve = "$lit$", H = `lit$${(Math.random() + "").slice(9)}$`, Un = "?" + H, Oo = `<${Un}>`, X = document, _t = () => X.createComment(""), Pt = (s) => s === null || typeof s != "object" && typeof s != "function", Vn = Array.isArray, So = (s) => Vn(s) || typeof (s == null ? void 0 : s[Symbol.iterator]) == "function", Se = `[
|
|
4704
|
+
\f\r]`, vt = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, sn = /-->/g, nn = />/g, q = RegExp(`>|${Se}(?:([^\\s"'>=/]+)(${Se}*=${Se}*(?:[^
|
|
4705
|
+
\f\r"'\`<>=]|("|')|))|$)`, "g"), rn = /'/g, on = /"/g, Bn = /^(?:script|style|textarea|title)$/i, No = (s) => (t, ...e) => ({ _$litType$: s, strings: t, values: e }), Dt = No(1), tt = Symbol.for("lit-noChange"), y = Symbol.for("lit-nothing"), an = /* @__PURE__ */ new WeakMap(), G = X.createTreeWalker(X, 129, null, !1);
|
|
4706
|
+
function Jn(s, t) {
|
|
4702
4707
|
if (!Array.isArray(s) || !s.hasOwnProperty("raw"))
|
|
4703
4708
|
throw Error("invalid template strings array");
|
|
4704
|
-
return
|
|
4709
|
+
return en !== void 0 ? en.createHTML(t) : t;
|
|
4705
4710
|
}
|
|
4706
|
-
const
|
|
4711
|
+
const To = (s, t) => {
|
|
4707
4712
|
const e = s.length - 1, n = [];
|
|
4708
|
-
let i, r = t === 2 ? "<svg>" : "", o =
|
|
4713
|
+
let i, r = t === 2 ? "<svg>" : "", o = vt;
|
|
4709
4714
|
for (let a = 0; a < e; a++) {
|
|
4710
4715
|
const c = s[a];
|
|
4711
4716
|
let h, l, d = -1, p = 0;
|
|
4712
4717
|
for (; p < c.length && (o.lastIndex = p, l = o.exec(c), l !== null); )
|
|
4713
|
-
p = o.lastIndex, o ===
|
|
4714
|
-
const u = o ===
|
|
4715
|
-
r += o ===
|
|
4718
|
+
p = o.lastIndex, o === vt ? l[1] === "!--" ? o = sn : l[1] !== void 0 ? o = nn : l[2] !== void 0 ? (Bn.test(l[2]) && (i = RegExp("</" + l[2], "g")), o = q) : l[3] !== void 0 && (o = q) : o === q ? l[0] === ">" ? (o = i != null ? i : vt, d = -1) : l[1] === void 0 ? d = -2 : (d = o.lastIndex - l[2].length, h = l[1], o = l[3] === void 0 ? q : l[3] === '"' ? on : rn) : o === on || o === rn ? o = q : o === sn || o === nn ? o = vt : (o = q, i = void 0);
|
|
4719
|
+
const u = o === q && s[a + 1].startsWith("/>") ? " " : "";
|
|
4720
|
+
r += o === vt ? c + Oo : d >= 0 ? (n.push(h), c.slice(0, d) + Ve + c.slice(d) + H + u) : c + H + (d === -2 ? (n.push(void 0), a) : u);
|
|
4716
4721
|
}
|
|
4717
|
-
return [
|
|
4722
|
+
return [Jn(s, r + (s[e] || "<?>") + (t === 2 ? "</svg>" : "")), n];
|
|
4718
4723
|
};
|
|
4719
|
-
class
|
|
4724
|
+
class Ct {
|
|
4720
4725
|
constructor({ strings: t, _$litType$: e }, n) {
|
|
4721
4726
|
let i;
|
|
4722
4727
|
this.parts = [];
|
|
4723
4728
|
let r = 0, o = 0;
|
|
4724
|
-
const a = t.length - 1, c = this.parts, [h, l] =
|
|
4725
|
-
if (this.el =
|
|
4729
|
+
const a = t.length - 1, c = this.parts, [h, l] = To(t, e);
|
|
4730
|
+
if (this.el = Ct.createElement(h, n), G.currentNode = this.el.content, e === 2) {
|
|
4726
4731
|
const d = this.el.content, p = d.firstChild;
|
|
4727
4732
|
p.remove(), d.append(...p.childNodes);
|
|
4728
4733
|
}
|
|
4729
|
-
for (; (i =
|
|
4734
|
+
for (; (i = G.nextNode()) !== null && c.length < a; ) {
|
|
4730
4735
|
if (i.nodeType === 1) {
|
|
4731
4736
|
if (i.hasAttributes()) {
|
|
4732
4737
|
const d = [];
|
|
4733
4738
|
for (const p of i.getAttributeNames())
|
|
4734
|
-
if (p.endsWith(
|
|
4739
|
+
if (p.endsWith(Ve) || p.startsWith(H)) {
|
|
4735
4740
|
const u = l[o++];
|
|
4736
4741
|
if (d.push(p), u !== void 0) {
|
|
4737
|
-
const g = i.getAttribute(u.toLowerCase() +
|
|
4738
|
-
c.push({ type: 1, index: r, name: m[2], strings: g, ctor: m[1] === "." ?
|
|
4742
|
+
const g = i.getAttribute(u.toLowerCase() + Ve).split(H), m = /([.?@])?(.*)/.exec(u);
|
|
4743
|
+
c.push({ type: 1, index: r, name: m[2], strings: g, ctor: m[1] === "." ? jo : m[1] === "?" ? Mo : m[1] === "@" ? Lo : oe });
|
|
4739
4744
|
} else
|
|
4740
4745
|
c.push({ type: 6, index: r });
|
|
4741
4746
|
}
|
|
4742
4747
|
for (const p of d)
|
|
4743
4748
|
i.removeAttribute(p);
|
|
4744
4749
|
}
|
|
4745
|
-
if (
|
|
4746
|
-
const d = i.textContent.split(
|
|
4750
|
+
if (Bn.test(i.tagName)) {
|
|
4751
|
+
const d = i.textContent.split(H), p = d.length - 1;
|
|
4747
4752
|
if (p > 0) {
|
|
4748
|
-
i.textContent =
|
|
4753
|
+
i.textContent = ht ? ht.emptyScript : "";
|
|
4749
4754
|
for (let u = 0; u < p; u++)
|
|
4750
|
-
i.append(d[u],
|
|
4751
|
-
i.append(d[p],
|
|
4755
|
+
i.append(d[u], _t()), G.nextNode(), c.push({ type: 2, index: ++r });
|
|
4756
|
+
i.append(d[p], _t());
|
|
4752
4757
|
}
|
|
4753
4758
|
}
|
|
4754
4759
|
} else if (i.nodeType === 8)
|
|
4755
|
-
if (i.data ===
|
|
4760
|
+
if (i.data === Un)
|
|
4756
4761
|
c.push({ type: 2, index: r });
|
|
4757
4762
|
else {
|
|
4758
4763
|
let d = -1;
|
|
4759
|
-
for (; (d = i.data.indexOf(
|
|
4760
|
-
c.push({ type: 7, index: r }), d +=
|
|
4764
|
+
for (; (d = i.data.indexOf(H, d + 1)) !== -1; )
|
|
4765
|
+
c.push({ type: 7, index: r }), d += H.length - 1;
|
|
4761
4766
|
}
|
|
4762
4767
|
r++;
|
|
4763
4768
|
}
|
|
4764
4769
|
}
|
|
4765
4770
|
static createElement(t, e) {
|
|
4766
|
-
const n =
|
|
4771
|
+
const n = X.createElement("template");
|
|
4767
4772
|
return n.innerHTML = t, n;
|
|
4768
4773
|
}
|
|
4769
4774
|
}
|
|
4770
|
-
function
|
|
4775
|
+
function lt(s, t, e = s, n) {
|
|
4771
4776
|
var i, r, o, a;
|
|
4772
|
-
if (t ===
|
|
4777
|
+
if (t === tt)
|
|
4773
4778
|
return t;
|
|
4774
4779
|
let c = n !== void 0 ? (i = e._$Co) === null || i === void 0 ? void 0 : i[n] : e._$Cl;
|
|
4775
|
-
const h =
|
|
4776
|
-
return (c == null ? void 0 : c.constructor) !== h && ((r = c == null ? void 0 : c._$AO) === null || r === void 0 || r.call(c, !1), h === void 0 ? c = void 0 : (c = new h(s), c._$AT(s, e, n)), n !== void 0 ? ((o = (a = e)._$Co) !== null && o !== void 0 ? o : a._$Co = [])[n] = c : e._$Cl = c), c !== void 0 && (t =
|
|
4780
|
+
const h = Pt(t) ? void 0 : t._$litDirective$;
|
|
4781
|
+
return (c == null ? void 0 : c.constructor) !== h && ((r = c == null ? void 0 : c._$AO) === null || r === void 0 || r.call(c, !1), h === void 0 ? c = void 0 : (c = new h(s), c._$AT(s, e, n)), n !== void 0 ? ((o = (a = e)._$Co) !== null && o !== void 0 ? o : a._$Co = [])[n] = c : e._$Cl = c), c !== void 0 && (t = lt(s, c._$AS(s, t.values), c, n)), t;
|
|
4777
4782
|
}
|
|
4778
|
-
class
|
|
4783
|
+
class Io {
|
|
4779
4784
|
constructor(t, e) {
|
|
4780
4785
|
this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
|
|
4781
4786
|
}
|
|
@@ -4787,17 +4792,17 @@ class ko {
|
|
|
4787
4792
|
}
|
|
4788
4793
|
u(t) {
|
|
4789
4794
|
var e;
|
|
4790
|
-
const { el: { content: n }, parts: i } = this._$AD, r = ((e = t == null ? void 0 : t.creationScope) !== null && e !== void 0 ? e :
|
|
4791
|
-
|
|
4792
|
-
let o =
|
|
4795
|
+
const { el: { content: n }, parts: i } = this._$AD, r = ((e = t == null ? void 0 : t.creationScope) !== null && e !== void 0 ? e : X).importNode(n, !0);
|
|
4796
|
+
G.currentNode = r;
|
|
4797
|
+
let o = G.nextNode(), a = 0, c = 0, h = i[0];
|
|
4793
4798
|
for (; h !== void 0; ) {
|
|
4794
4799
|
if (a === h.index) {
|
|
4795
4800
|
let l;
|
|
4796
|
-
h.type === 2 ? l = new
|
|
4801
|
+
h.type === 2 ? l = new kt(o, o.nextSibling, this, t) : h.type === 1 ? l = new h.ctor(o, h.name, h.strings, this, t) : h.type === 6 && (l = new Ro(o, this, t)), this._$AV.push(l), h = i[++c];
|
|
4797
4802
|
}
|
|
4798
|
-
a !== (h == null ? void 0 : h.index) && (o =
|
|
4803
|
+
a !== (h == null ? void 0 : h.index) && (o = G.nextNode(), a++);
|
|
4799
4804
|
}
|
|
4800
|
-
return
|
|
4805
|
+
return G.currentNode = X, r;
|
|
4801
4806
|
}
|
|
4802
4807
|
v(t) {
|
|
4803
4808
|
let e = 0;
|
|
@@ -4805,7 +4810,7 @@ class ko {
|
|
|
4805
4810
|
n !== void 0 && (n.strings !== void 0 ? (n._$AI(t, n, e), e += n.strings.length - 2) : n._$AI(t[e])), e++;
|
|
4806
4811
|
}
|
|
4807
4812
|
}
|
|
4808
|
-
class
|
|
4813
|
+
class kt {
|
|
4809
4814
|
constructor(t, e, n, i) {
|
|
4810
4815
|
var r;
|
|
4811
4816
|
this.type = 2, this._$AH = y, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = n, this.options = i, this._$Cp = (r = i == null ? void 0 : i.isConnected) === null || r === void 0 || r;
|
|
@@ -4826,7 +4831,7 @@ class xt {
|
|
|
4826
4831
|
return this._$AB;
|
|
4827
4832
|
}
|
|
4828
4833
|
_$AI(t, e = this) {
|
|
4829
|
-
t =
|
|
4834
|
+
t = lt(this, t, e), Pt(t) ? t === y || t == null || t === "" ? (this._$AH !== y && this._$AR(), this._$AH = y) : t !== this._$AH && t !== tt && this._(t) : t._$litType$ !== void 0 ? this.g(t) : t.nodeType !== void 0 ? this.$(t) : So(t) ? this.T(t) : this._(t);
|
|
4830
4835
|
}
|
|
4831
4836
|
k(t) {
|
|
4832
4837
|
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
@@ -4835,28 +4840,28 @@ class xt {
|
|
|
4835
4840
|
this._$AH !== t && (this._$AR(), this._$AH = this.k(t));
|
|
4836
4841
|
}
|
|
4837
4842
|
_(t) {
|
|
4838
|
-
this._$AH !== y &&
|
|
4843
|
+
this._$AH !== y && Pt(this._$AH) ? this._$AA.nextSibling.data = t : this.$(X.createTextNode(t)), this._$AH = t;
|
|
4839
4844
|
}
|
|
4840
4845
|
g(t) {
|
|
4841
4846
|
var e;
|
|
4842
|
-
const { values: n, _$litType$: i } = t, r = typeof i == "number" ? this._$AC(t) : (i.el === void 0 && (i.el =
|
|
4847
|
+
const { values: n, _$litType$: i } = t, r = typeof i == "number" ? this._$AC(t) : (i.el === void 0 && (i.el = Ct.createElement(Jn(i.h, i.h[0]), this.options)), i);
|
|
4843
4848
|
if (((e = this._$AH) === null || e === void 0 ? void 0 : e._$AD) === r)
|
|
4844
4849
|
this._$AH.v(n);
|
|
4845
4850
|
else {
|
|
4846
|
-
const o = new
|
|
4851
|
+
const o = new Io(r, this), a = o.u(this.options);
|
|
4847
4852
|
o.v(n), this.$(a), this._$AH = o;
|
|
4848
4853
|
}
|
|
4849
4854
|
}
|
|
4850
4855
|
_$AC(t) {
|
|
4851
|
-
let e =
|
|
4852
|
-
return e === void 0 &&
|
|
4856
|
+
let e = an.get(t.strings);
|
|
4857
|
+
return e === void 0 && an.set(t.strings, e = new Ct(t)), e;
|
|
4853
4858
|
}
|
|
4854
4859
|
T(t) {
|
|
4855
|
-
|
|
4860
|
+
Vn(this._$AH) || (this._$AH = [], this._$AR());
|
|
4856
4861
|
const e = this._$AH;
|
|
4857
4862
|
let n, i = 0;
|
|
4858
4863
|
for (const r of t)
|
|
4859
|
-
i === e.length ? e.push(n = new
|
|
4864
|
+
i === e.length ? e.push(n = new kt(this.k(_t()), this.k(_t()), this, this.options)) : n = e[i], n._$AI(r), i++;
|
|
4860
4865
|
i < e.length && (this._$AR(n && n._$AB.nextSibling, i), e.length = i);
|
|
4861
4866
|
}
|
|
4862
4867
|
_$AR(t = this._$AA.nextSibling, e) {
|
|
@@ -4871,7 +4876,7 @@ class xt {
|
|
|
4871
4876
|
this._$AM === void 0 && (this._$Cp = t, (e = this._$AP) === null || e === void 0 || e.call(this, t));
|
|
4872
4877
|
}
|
|
4873
4878
|
}
|
|
4874
|
-
class
|
|
4879
|
+
class oe {
|
|
4875
4880
|
constructor(t, e, n, i, r) {
|
|
4876
4881
|
this.type = 1, this._$AH = y, this._$AN = void 0, this.element = t, this.name = e, this._$AM = i, this.options = r, n.length > 2 || n[0] !== "" || n[1] !== "" ? (this._$AH = Array(n.length - 1).fill(new String()), this.strings = n) : this._$AH = y;
|
|
4877
4882
|
}
|
|
@@ -4885,12 +4890,12 @@ class ee {
|
|
|
4885
4890
|
const r = this.strings;
|
|
4886
4891
|
let o = !1;
|
|
4887
4892
|
if (r === void 0)
|
|
4888
|
-
t =
|
|
4893
|
+
t = lt(this, t, e, 0), o = !Pt(t) || t !== this._$AH && t !== tt, o && (this._$AH = t);
|
|
4889
4894
|
else {
|
|
4890
4895
|
const a = t;
|
|
4891
4896
|
let c, h;
|
|
4892
4897
|
for (t = r[0], c = 0; c < r.length - 1; c++)
|
|
4893
|
-
h =
|
|
4898
|
+
h = lt(this, a[n + c], e, c), h === tt && (h = this._$AH[c]), o || (o = !Pt(h) || h !== this._$AH[c]), h === y ? t = y : t !== y && (t += (h != null ? h : "") + r[c + 1]), this._$AH[c] = h;
|
|
4894
4899
|
}
|
|
4895
4900
|
o && !i && this.j(t);
|
|
4896
4901
|
}
|
|
@@ -4898,7 +4903,7 @@ class ee {
|
|
|
4898
4903
|
t === y ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t != null ? t : "");
|
|
4899
4904
|
}
|
|
4900
4905
|
}
|
|
4901
|
-
class
|
|
4906
|
+
class jo extends oe {
|
|
4902
4907
|
constructor() {
|
|
4903
4908
|
super(...arguments), this.type = 3;
|
|
4904
4909
|
}
|
|
@@ -4906,22 +4911,22 @@ class So extends ee {
|
|
|
4906
4911
|
this.element[this.name] = t === y ? void 0 : t;
|
|
4907
4912
|
}
|
|
4908
4913
|
}
|
|
4909
|
-
const
|
|
4910
|
-
class
|
|
4914
|
+
const Do = ht ? ht.emptyScript : "";
|
|
4915
|
+
class Mo extends oe {
|
|
4911
4916
|
constructor() {
|
|
4912
4917
|
super(...arguments), this.type = 4;
|
|
4913
4918
|
}
|
|
4914
4919
|
j(t) {
|
|
4915
|
-
t && t !== y ? this.element.setAttribute(this.name,
|
|
4920
|
+
t && t !== y ? this.element.setAttribute(this.name, Do) : this.element.removeAttribute(this.name);
|
|
4916
4921
|
}
|
|
4917
4922
|
}
|
|
4918
|
-
class
|
|
4923
|
+
class Lo extends oe {
|
|
4919
4924
|
constructor(t, e, n, i, r) {
|
|
4920
4925
|
super(t, e, n, i, r), this.type = 5;
|
|
4921
4926
|
}
|
|
4922
4927
|
_$AI(t, e = this) {
|
|
4923
4928
|
var n;
|
|
4924
|
-
if ((t = (n =
|
|
4929
|
+
if ((t = (n = lt(this, t, e, 0)) !== null && n !== void 0 ? n : y) === tt)
|
|
4925
4930
|
return;
|
|
4926
4931
|
const i = this._$AH, r = t === y && i !== y || t.capture !== i.capture || t.once !== i.once || t.passive !== i.passive, o = t !== y && (i === y || r);
|
|
4927
4932
|
r && this.element.removeEventListener(this.name, this, i), o && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
@@ -4931,7 +4936,7 @@ class Io extends ee {
|
|
|
4931
4936
|
typeof this._$AH == "function" ? this._$AH.call((n = (e = this.options) === null || e === void 0 ? void 0 : e.host) !== null && n !== void 0 ? n : this.element, t) : this._$AH.handleEvent(t);
|
|
4932
4937
|
}
|
|
4933
4938
|
}
|
|
4934
|
-
class
|
|
4939
|
+
class Ro {
|
|
4935
4940
|
constructor(t, e, n) {
|
|
4936
4941
|
this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = n;
|
|
4937
4942
|
}
|
|
@@ -4939,18 +4944,18 @@ class jo {
|
|
|
4939
4944
|
return this._$AM._$AU;
|
|
4940
4945
|
}
|
|
4941
4946
|
_$AI(t) {
|
|
4942
|
-
|
|
4947
|
+
lt(this, t);
|
|
4943
4948
|
}
|
|
4944
4949
|
}
|
|
4945
|
-
const
|
|
4946
|
-
|
|
4947
|
-
const
|
|
4950
|
+
const cn = Ft.litHtmlPolyfillSupport;
|
|
4951
|
+
cn == null || cn(Ct, kt), ((Oe = Ft.litHtmlVersions) !== null && Oe !== void 0 ? Oe : Ft.litHtmlVersions = []).push("2.8.0");
|
|
4952
|
+
const Wo = (s, t, e) => {
|
|
4948
4953
|
var n, i;
|
|
4949
4954
|
const r = (n = e == null ? void 0 : e.renderBefore) !== null && n !== void 0 ? n : t;
|
|
4950
4955
|
let o = r._$litPart$;
|
|
4951
4956
|
if (o === void 0) {
|
|
4952
4957
|
const a = (i = e == null ? void 0 : e.renderBefore) !== null && i !== void 0 ? i : null;
|
|
4953
|
-
r._$litPart$ = o = new
|
|
4958
|
+
r._$litPart$ = o = new kt(t.insertBefore(_t(), a), a, void 0, e != null ? e : {});
|
|
4954
4959
|
}
|
|
4955
4960
|
return o._$AI(s), o;
|
|
4956
4961
|
};
|
|
@@ -4959,8 +4964,8 @@ const Do = (s, t, e) => {
|
|
|
4959
4964
|
* Copyright 2017 Google LLC
|
|
4960
4965
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
4961
4966
|
*/
|
|
4962
|
-
var
|
|
4963
|
-
let
|
|
4967
|
+
var Ne, Te;
|
|
4968
|
+
let wt = class extends it {
|
|
4964
4969
|
constructor() {
|
|
4965
4970
|
super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
|
|
4966
4971
|
}
|
|
@@ -4971,7 +4976,7 @@ let vt = class extends et {
|
|
|
4971
4976
|
}
|
|
4972
4977
|
update(s) {
|
|
4973
4978
|
const t = this.render();
|
|
4974
|
-
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(s), this._$Do =
|
|
4979
|
+
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(s), this._$Do = Wo(t, this.renderRoot, this.renderOptions);
|
|
4975
4980
|
}
|
|
4976
4981
|
connectedCallback() {
|
|
4977
4982
|
var s;
|
|
@@ -4982,76 +4987,94 @@ let vt = class extends et {
|
|
|
4982
4987
|
super.disconnectedCallback(), (s = this._$Do) === null || s === void 0 || s.setConnected(!1);
|
|
4983
4988
|
}
|
|
4984
4989
|
render() {
|
|
4985
|
-
return
|
|
4990
|
+
return tt;
|
|
4986
4991
|
}
|
|
4987
4992
|
};
|
|
4988
|
-
|
|
4989
|
-
const
|
|
4990
|
-
|
|
4991
|
-
((
|
|
4993
|
+
wt.finalized = !0, wt._$litElement$ = !0, (Ne = globalThis.litElementHydrateSupport) === null || Ne === void 0 || Ne.call(globalThis, { LitElement: wt });
|
|
4994
|
+
const hn = globalThis.litElementPolyfillSupport;
|
|
4995
|
+
hn == null || hn({ LitElement: wt });
|
|
4996
|
+
((Te = globalThis.litElementVersions) !== null && Te !== void 0 ? Te : globalThis.litElementVersions = []).push("3.3.3");
|
|
4992
4997
|
/**
|
|
4993
4998
|
* @license
|
|
4994
4999
|
* Copyright 2017 Google LLC
|
|
4995
5000
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
4996
5001
|
*/
|
|
4997
|
-
const
|
|
5002
|
+
const zo = (s, t) => t.kind === "method" && t.descriptor && !("value" in t.descriptor) ? ss(es({}, t), { finisher(e) {
|
|
4998
5003
|
e.createProperty(t.key, s);
|
|
4999
5004
|
} }) : { kind: "field", key: Symbol(), placement: "own", descriptor: {}, originalKey: t.key, initializer() {
|
|
5000
5005
|
typeof t.initializer == "function" && (this[t.key] = t.initializer.call(this));
|
|
5001
5006
|
}, finisher(e) {
|
|
5002
5007
|
e.createProperty(t.key, s);
|
|
5003
|
-
} },
|
|
5008
|
+
} }, Ho = (s, t, e) => {
|
|
5004
5009
|
t.constructor.createProperty(e, s);
|
|
5005
5010
|
};
|
|
5006
|
-
function
|
|
5007
|
-
return (t, e) => e !== void 0 ?
|
|
5011
|
+
function Kt(s) {
|
|
5012
|
+
return (t, e) => e !== void 0 ? Ho(s, t, e) : zo(s, t);
|
|
5008
5013
|
}
|
|
5009
5014
|
/**
|
|
5010
5015
|
* @license
|
|
5011
5016
|
* Copyright 2017 Google LLC
|
|
5012
5017
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5013
5018
|
*/
|
|
5014
|
-
function
|
|
5015
|
-
return
|
|
5019
|
+
function U(s) {
|
|
5020
|
+
return Kt(ss(es({}, s), { state: !0 }));
|
|
5016
5021
|
}
|
|
5022
|
+
/**
|
|
5023
|
+
* @license
|
|
5024
|
+
* Copyright 2017 Google LLC
|
|
5025
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
5026
|
+
*/
|
|
5027
|
+
const Uo = ({ finisher: s, descriptor: t }) => (e, n) => {
|
|
5028
|
+
var i;
|
|
5029
|
+
if (n === void 0) {
|
|
5030
|
+
const r = (i = e.originalKey) !== null && i !== void 0 ? i : e.key, o = t != null ? { kind: "method", placement: "prototype", key: r, descriptor: t(e.key) } : ss(es({}, e), { key: r });
|
|
5031
|
+
return s != null && (o.finisher = function(a) {
|
|
5032
|
+
s(a, r);
|
|
5033
|
+
}), o;
|
|
5034
|
+
}
|
|
5035
|
+
{
|
|
5036
|
+
const r = e.constructor;
|
|
5037
|
+
t !== void 0 && Object.defineProperty(e, n, t(n)), s == null || s(r, n);
|
|
5038
|
+
}
|
|
5039
|
+
};
|
|
5017
5040
|
/**
|
|
5018
5041
|
* @license
|
|
5019
5042
|
* Copyright 2021 Google LLC
|
|
5020
5043
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5021
5044
|
*/
|
|
5022
|
-
var
|
|
5023
|
-
((
|
|
5045
|
+
var Ie;
|
|
5046
|
+
((Ie = window.HTMLSlotElement) === null || Ie === void 0 ? void 0 : Ie.prototype.assignedElements) != null;
|
|
5024
5047
|
/**
|
|
5025
5048
|
* @license
|
|
5026
5049
|
* Copyright 2017 Google LLC
|
|
5027
5050
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5028
5051
|
*/
|
|
5029
|
-
const
|
|
5030
|
-
class
|
|
5031
|
-
constructor(
|
|
5052
|
+
const Vo = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 }, Bo = (s) => (...t) => ({ _$litDirective$: s, values: t });
|
|
5053
|
+
let Jo = class {
|
|
5054
|
+
constructor(s) {
|
|
5032
5055
|
}
|
|
5033
5056
|
get _$AU() {
|
|
5034
5057
|
return this._$AM._$AU;
|
|
5035
5058
|
}
|
|
5036
|
-
_$AT(t, e
|
|
5037
|
-
this._$Ct =
|
|
5059
|
+
_$AT(s, t, e) {
|
|
5060
|
+
this._$Ct = s, this._$AM = t, this._$Ci = e;
|
|
5038
5061
|
}
|
|
5039
|
-
_$AS(
|
|
5040
|
-
return this.update(
|
|
5062
|
+
_$AS(s, t) {
|
|
5063
|
+
return this.update(s, t);
|
|
5041
5064
|
}
|
|
5042
|
-
update(
|
|
5043
|
-
return this.render(...
|
|
5065
|
+
update(s, t) {
|
|
5066
|
+
return this.render(...t);
|
|
5044
5067
|
}
|
|
5045
|
-
}
|
|
5068
|
+
};
|
|
5046
5069
|
/**
|
|
5047
5070
|
* @license
|
|
5048
5071
|
* Copyright 2018 Google LLC
|
|
5049
5072
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5050
5073
|
*/
|
|
5051
|
-
const
|
|
5074
|
+
const qo = Bo(class extends Jo {
|
|
5052
5075
|
constructor(s) {
|
|
5053
5076
|
var t;
|
|
5054
|
-
if (super(s), s.type !==
|
|
5077
|
+
if (super(s), s.type !== Vo.ATTRIBUTE || s.name !== "class" || ((t = s.strings) === null || t === void 0 ? void 0 : t.length) > 2)
|
|
5055
5078
|
throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.");
|
|
5056
5079
|
}
|
|
5057
5080
|
render(s) {
|
|
@@ -5073,29 +5096,29 @@ const Lo = Ho(class extends zo {
|
|
|
5073
5096
|
const o = !!t[r];
|
|
5074
5097
|
o === this.it.has(r) || !((n = this.nt) === null || n === void 0) && n.has(r) || (o ? (i.add(r), this.it.add(r)) : (i.remove(r), this.it.delete(r)));
|
|
5075
5098
|
}
|
|
5076
|
-
return
|
|
5099
|
+
return tt;
|
|
5077
5100
|
}
|
|
5078
5101
|
});
|
|
5079
|
-
var
|
|
5080
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
5102
|
+
var Fo = Object.defineProperty, Ko = Object.getOwnPropertyDescriptor, ae = (s, t, e, n) => {
|
|
5103
|
+
for (var i = n > 1 ? void 0 : n ? Ko(t, e) : t, r = s.length - 1, o; r >= 0; r--)
|
|
5081
5104
|
(o = s[r]) && (i = (n ? o(t, e, i) : o(i)) || i);
|
|
5082
|
-
return n && i &&
|
|
5105
|
+
return n && i && Fo(t, e, i), i;
|
|
5083
5106
|
};
|
|
5084
|
-
class
|
|
5107
|
+
class et extends wt {
|
|
5085
5108
|
constructor() {
|
|
5086
5109
|
super(...arguments), this.active = !1, this.loaded = !1;
|
|
5087
5110
|
}
|
|
5088
5111
|
connectedCallback() {
|
|
5089
|
-
return
|
|
5090
|
-
|
|
5112
|
+
return at(this, null, function* () {
|
|
5113
|
+
Cr(et.prototype, this, "connectedCallback").call(this), this.icon = yield this._renderSymbol(this.symbol), this.loaded = !0;
|
|
5091
5114
|
});
|
|
5092
5115
|
}
|
|
5093
5116
|
_toggleActive() {
|
|
5094
5117
|
this.active = !this.active;
|
|
5095
5118
|
}
|
|
5096
5119
|
_renderSymbol(t) {
|
|
5097
|
-
return
|
|
5098
|
-
const e = (n) =>
|
|
5120
|
+
return at(this, null, function* () {
|
|
5121
|
+
const e = (n) => at(this, null, function* () {
|
|
5099
5122
|
return yield import("./index-9688347a-02584d39.js").then((i) => i[n]);
|
|
5100
5123
|
});
|
|
5101
5124
|
if (t) {
|
|
@@ -5103,16 +5126,16 @@ class G extends vt {
|
|
|
5103
5126
|
switch (n) {
|
|
5104
5127
|
case "Telia": {
|
|
5105
5128
|
const r = yield e(i);
|
|
5106
|
-
return r ?
|
|
5129
|
+
return r ? Dt`<telia-icon
|
|
5107
5130
|
class="trigger-icon"
|
|
5108
5131
|
svg=${r.svg}
|
|
5109
5132
|
size="lg"
|
|
5110
5133
|
></telia-icon>` : y;
|
|
5111
5134
|
}
|
|
5112
5135
|
case "FontAwesome":
|
|
5113
|
-
return
|
|
5136
|
+
return Dt`<i class="trigger-fa-icon fa fa-${i}"></i>`;
|
|
5114
5137
|
case "Uri":
|
|
5115
|
-
return
|
|
5138
|
+
return Dt`<i
|
|
5116
5139
|
class="trigger-custom-icon"
|
|
5117
5140
|
style="background: url(${i}) no-repeat center center;background-size: contain;"
|
|
5118
5141
|
></i>`;
|
|
@@ -5123,8 +5146,8 @@ class G extends vt {
|
|
|
5123
5146
|
});
|
|
5124
5147
|
}
|
|
5125
5148
|
render() {
|
|
5126
|
-
return
|
|
5127
|
-
class=${
|
|
5149
|
+
return Dt`<button
|
|
5150
|
+
class=${qo({
|
|
5128
5151
|
trigger: !0,
|
|
5129
5152
|
active: this.active,
|
|
5130
5153
|
rendered: this.loaded
|
|
@@ -5162,8 +5185,8 @@ class G extends vt {
|
|
|
5162
5185
|
</button>`;
|
|
5163
5186
|
}
|
|
5164
5187
|
}
|
|
5165
|
-
|
|
5166
|
-
|
|
5188
|
+
et.styles = [
|
|
5189
|
+
zn`
|
|
5167
5190
|
:host {
|
|
5168
5191
|
--voca-rem-multiplier: 0.625;
|
|
5169
5192
|
display: block;
|
|
@@ -5235,24 +5258,24 @@ G.styles = [
|
|
|
5235
5258
|
}
|
|
5236
5259
|
`
|
|
5237
5260
|
];
|
|
5238
|
-
|
|
5239
|
-
|
|
5240
|
-
],
|
|
5241
|
-
|
|
5242
|
-
|
|
5243
|
-
],
|
|
5244
|
-
|
|
5245
|
-
|
|
5246
|
-
],
|
|
5247
|
-
|
|
5248
|
-
|
|
5249
|
-
],
|
|
5261
|
+
ae([
|
|
5262
|
+
Kt({ attribute: !1 })
|
|
5263
|
+
], et.prototype, "symbol", 2);
|
|
5264
|
+
ae([
|
|
5265
|
+
U()
|
|
5266
|
+
], et.prototype, "active", 2);
|
|
5267
|
+
ae([
|
|
5268
|
+
U()
|
|
5269
|
+
], et.prototype, "loaded", 2);
|
|
5270
|
+
ae([
|
|
5271
|
+
U()
|
|
5272
|
+
], et.prototype, "icon", 2);
|
|
5250
5273
|
/**
|
|
5251
5274
|
* @license
|
|
5252
5275
|
* Copyright 2021 Google LLC
|
|
5253
5276
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5254
5277
|
*/
|
|
5255
|
-
let
|
|
5278
|
+
let qn = class extends Event {
|
|
5256
5279
|
constructor(s, t, e) {
|
|
5257
5280
|
super("context-request", { bubbles: !0, composed: !0 }), this.context = s, this.callback = t, this.subscribe = e != null && e;
|
|
5258
5281
|
}
|
|
@@ -5267,16 +5290,16 @@ let Bo = class extends Event {
|
|
|
5267
5290
|
* Copyright 2021 Google LLC
|
|
5268
5291
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5269
5292
|
*/
|
|
5270
|
-
class
|
|
5271
|
-
constructor(t, e, n
|
|
5272
|
-
var
|
|
5273
|
-
if (this.subscribe = !1, this.provided = !1, this.value = void 0, this.t = (
|
|
5274
|
-
this.unsubscribe && (this.unsubscribe !==
|
|
5275
|
-
}, this.host =
|
|
5276
|
-
const
|
|
5277
|
-
this.context =
|
|
5293
|
+
let Qo = class {
|
|
5294
|
+
constructor(s, t, e, n) {
|
|
5295
|
+
var i;
|
|
5296
|
+
if (this.subscribe = !1, this.provided = !1, this.value = void 0, this.t = (r, o) => {
|
|
5297
|
+
this.unsubscribe && (this.unsubscribe !== o && (this.provided = !1, this.unsubscribe()), this.subscribe || this.unsubscribe()), this.value = r, this.host.requestUpdate(), this.provided && !this.subscribe || (this.provided = !0, this.callback && this.callback(r, o)), this.unsubscribe = o;
|
|
5298
|
+
}, this.host = s, t.context !== void 0) {
|
|
5299
|
+
const r = t;
|
|
5300
|
+
this.context = r.context, this.callback = r.callback, this.subscribe = (i = r.subscribe) !== null && i !== void 0 && i;
|
|
5278
5301
|
} else
|
|
5279
|
-
this.context =
|
|
5302
|
+
this.context = t, this.callback = e, this.subscribe = n != null && n;
|
|
5280
5303
|
this.host.addController(this);
|
|
5281
5304
|
}
|
|
5282
5305
|
hostConnected() {
|
|
@@ -5286,70 +5309,279 @@ class en {
|
|
|
5286
5309
|
this.unsubscribe && (this.unsubscribe(), this.unsubscribe = void 0);
|
|
5287
5310
|
}
|
|
5288
5311
|
dispatchRequest() {
|
|
5289
|
-
this.host.dispatchEvent(new
|
|
5312
|
+
this.host.dispatchEvent(new qn(this.context, this.t, this.subscribe));
|
|
5313
|
+
}
|
|
5314
|
+
};
|
|
5315
|
+
/**
|
|
5316
|
+
* @license
|
|
5317
|
+
* Copyright 2021 Google LLC
|
|
5318
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
5319
|
+
*/
|
|
5320
|
+
class Yo {
|
|
5321
|
+
constructor(t) {
|
|
5322
|
+
this.subscriptions = /* @__PURE__ */ new Map(), this.updateObservers = () => {
|
|
5323
|
+
for (const [e, { disposer: n }] of this.subscriptions)
|
|
5324
|
+
e(this.o, n);
|
|
5325
|
+
}, t !== void 0 && (this.value = t);
|
|
5326
|
+
}
|
|
5327
|
+
get value() {
|
|
5328
|
+
return this.o;
|
|
5329
|
+
}
|
|
5330
|
+
set value(t) {
|
|
5331
|
+
this.setValue(t);
|
|
5332
|
+
}
|
|
5333
|
+
setValue(t, e = !1) {
|
|
5334
|
+
const n = e || !Object.is(t, this.o);
|
|
5335
|
+
this.o = t, n && this.updateObservers();
|
|
5336
|
+
}
|
|
5337
|
+
addCallback(t, e, n) {
|
|
5338
|
+
if (!n)
|
|
5339
|
+
return void t(this.value);
|
|
5340
|
+
this.subscriptions.has(t) || this.subscriptions.set(t, { disposer: () => {
|
|
5341
|
+
this.subscriptions.delete(t);
|
|
5342
|
+
}, consumerHost: e });
|
|
5343
|
+
const { disposer: i } = this.subscriptions.get(t);
|
|
5344
|
+
t(this.value, i);
|
|
5345
|
+
}
|
|
5346
|
+
clearCallbacks() {
|
|
5347
|
+
this.subscriptions.clear();
|
|
5290
5348
|
}
|
|
5291
5349
|
}
|
|
5292
|
-
|
|
5293
|
-
|
|
5350
|
+
/**
|
|
5351
|
+
* @license
|
|
5352
|
+
* Copyright 2021 Google LLC
|
|
5353
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
5354
|
+
*/
|
|
5355
|
+
class Zo extends Event {
|
|
5294
5356
|
constructor(t) {
|
|
5295
|
-
(this.
|
|
5296
|
-
|
|
5297
|
-
|
|
5298
|
-
|
|
5299
|
-
|
|
5300
|
-
|
|
5301
|
-
|
|
5302
|
-
|
|
5303
|
-
|
|
5304
|
-
|
|
5305
|
-
(
|
|
5306
|
-
|
|
5307
|
-
|
|
5308
|
-
|
|
5309
|
-
|
|
5357
|
+
super("context-provider", { bubbles: !0, composed: !0 }), this.context = t;
|
|
5358
|
+
}
|
|
5359
|
+
}
|
|
5360
|
+
class ft extends Yo {
|
|
5361
|
+
constructor(t, e, n) {
|
|
5362
|
+
super(e.context !== void 0 ? e.initialValue : n), this.onContextRequest = (i) => {
|
|
5363
|
+
const r = i.composedPath()[0];
|
|
5364
|
+
i.context === this.context && r !== this.host && (i.stopPropagation(), this.addCallback(i.callback, r, i.subscribe));
|
|
5365
|
+
}, this.onProviderRequest = (i) => {
|
|
5366
|
+
const r = i.composedPath()[0];
|
|
5367
|
+
if (i.context === this.context && r !== this.host) {
|
|
5368
|
+
for (const [o, { consumerHost: a }] of this.subscriptions)
|
|
5369
|
+
a.dispatchEvent(new qn(this.context, o, !0));
|
|
5370
|
+
i.stopPropagation();
|
|
5371
|
+
}
|
|
5372
|
+
}, this.host = t, e.context !== void 0 ? this.context = e.context : this.context = e, this.attachListeners(), this.host.addController(this);
|
|
5373
|
+
}
|
|
5374
|
+
attachListeners() {
|
|
5375
|
+
this.host.addEventListener("context-request", this.onContextRequest), this.host.addEventListener("context-provider", this.onProviderRequest);
|
|
5376
|
+
}
|
|
5377
|
+
hostConnected() {
|
|
5378
|
+
this.host.dispatchEvent(new Zo(this.context));
|
|
5379
|
+
}
|
|
5380
|
+
}
|
|
5381
|
+
/**
|
|
5382
|
+
* @license
|
|
5383
|
+
* Copyright 2022 Google LLC
|
|
5384
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
5385
|
+
*/
|
|
5386
|
+
function Go({ context: s, subscribe: t }) {
|
|
5387
|
+
return Uo({ finisher: (e, n) => {
|
|
5388
|
+
e.addInitializer((i) => {
|
|
5389
|
+
new Qo(i, { context: s, callback: (r) => {
|
|
5390
|
+
i[n] = r;
|
|
5391
|
+
}, subscribe: t });
|
|
5392
|
+
});
|
|
5393
|
+
} });
|
|
5394
|
+
}
|
|
5395
|
+
const Xo = "children", ta = "descriptor", ea = "container", sa = "context", na = "layout", ia = "properties";
|
|
5396
|
+
class ra {
|
|
5397
|
+
constructor(t) {
|
|
5398
|
+
(this.host = t).addController(this);
|
|
5310
5399
|
}
|
|
5311
5400
|
hostConnected() {
|
|
5312
5401
|
}
|
|
5313
5402
|
hostDisconnected() {
|
|
5314
5403
|
}
|
|
5404
|
+
setDescriptor(t) {
|
|
5405
|
+
this._descriptor = t;
|
|
5406
|
+
}
|
|
5407
|
+
setContainer(t) {
|
|
5408
|
+
this._container = t;
|
|
5409
|
+
}
|
|
5315
5410
|
dispatch(t, e) {
|
|
5316
|
-
return
|
|
5411
|
+
return at(this, null, function* () {
|
|
5317
5412
|
if (!this._container || !this._descriptor)
|
|
5318
5413
|
return;
|
|
5319
|
-
const n = yield
|
|
5414
|
+
const n = yield os.getInstance(
|
|
5320
5415
|
this._container
|
|
5321
|
-
), i = new
|
|
5416
|
+
), i = new ie(n).withId(
|
|
5322
5417
|
this._descriptor.id
|
|
5323
5418
|
);
|
|
5324
5419
|
yield n.actions(
|
|
5325
5420
|
i,
|
|
5326
|
-
this._descriptor.type ||
|
|
5421
|
+
this._descriptor.type || ne()
|
|
5327
5422
|
).dispatch(t, e);
|
|
5328
5423
|
});
|
|
5329
5424
|
}
|
|
5330
5425
|
}
|
|
5331
|
-
const
|
|
5332
|
-
}), t, i))),
|
|
5426
|
+
const oa = (s, t, e, n, i) => s.getAsync("componentResolver").then((r) => (r.registerComponent(t, e), Kr(s, t, n || (() => {
|
|
5427
|
+
}), t, i))), $ = (s, t, e) => {
|
|
5428
|
+
s && e.style.setProperty(t, s);
|
|
5429
|
+
}, aa = (s, t) => {
|
|
5430
|
+
var e, n, i, r, o, a, c, h, l, d, p;
|
|
5431
|
+
$((e = s.colors) == null ? void 0 : e.primary, "--primary-color", t), $((n = s.colors) == null ? void 0 : n.secondary, "--secondary-color", t), $((i = s.colors) == null ? void 0 : i.text, "--text-color", t), $((r = s.colors) == null ? void 0 : r.link, "--link-color", t), $((o = s.colors) == null ? void 0 : o.gray, "--gray-color", t), $((a = s.colors) == null ? void 0 : a.grayDark, "--gray-dark-color", t), $((c = s.spacing) == null ? void 0 : c.xs, "--spacing-xs", t), $((h = s.spacing) == null ? void 0 : h.sm, "--spacing-sm", t), $((l = s.spacing) == null ? void 0 : l.md, "--spacing-md", t), $((d = s.spacing) == null ? void 0 : d.lg, "--spacing-lg", t), $((p = s.spacing) == null ? void 0 : p.xl, "--spacing-xl", t), $(s.boxShadow, "--box-shadow", t), $(s.borderRadius, "--border-radius", t), $(s.borderRadiusSm, "--border-radius-sm", t), $(s.fontFamily, "--font-family", t);
|
|
5432
|
+
}, ca = (s) => {
|
|
5433
|
+
const t = {};
|
|
5434
|
+
return Object.keys(s).forEach((e) => {
|
|
5435
|
+
e.indexOf("css-") > -1 && (t[e] = s[e]);
|
|
5436
|
+
}), t;
|
|
5437
|
+
}, ha = (s, t) => {
|
|
5438
|
+
const e = ca(t);
|
|
5439
|
+
Object.entries(e).forEach(([n, i]) => {
|
|
5440
|
+
s.style.setProperty(n.replace("css-", ""), i);
|
|
5441
|
+
});
|
|
5442
|
+
};
|
|
5443
|
+
var la = Object.defineProperty, da = Object.getOwnPropertyDescriptor, F = (s, t, e, n) => {
|
|
5444
|
+
for (var i = n > 1 ? void 0 : n ? da(t, e) : t, r = s.length - 1, o; r >= 0; r--)
|
|
5445
|
+
(o = s[r]) && (i = (n ? o(t, e, i) : o(i)) || i);
|
|
5446
|
+
return n && i && la(t, e, i), i;
|
|
5447
|
+
};
|
|
5448
|
+
const ja = (s) => {
|
|
5449
|
+
var t;
|
|
5450
|
+
class e extends s {
|
|
5451
|
+
constructor() {
|
|
5452
|
+
super(...arguments), this.entry = "", this._descriptorProvider = new ft(
|
|
5453
|
+
this,
|
|
5454
|
+
ta,
|
|
5455
|
+
void 0
|
|
5456
|
+
), this._childrenProvider = new ft(this, Xo, []), this._propertiesProvider = new ft(this, ia, {}), this._contextProvider = new ft(this, sa, {}), this._layoutProvider = new ft(this, na, {}), this.actions = new ra(this), this.context = {}, this.layout = {}, this.properties = {};
|
|
5457
|
+
}
|
|
5458
|
+
connectedCallback() {
|
|
5459
|
+
super.connectedCallback(), this.container && (this.actions.setContainer(this.container), os.getInstance(this.container).then(
|
|
5460
|
+
(i) => at(this, null, function* () {
|
|
5461
|
+
var r;
|
|
5462
|
+
const o = i.nodes.get(this.entry);
|
|
5463
|
+
if (o) {
|
|
5464
|
+
this._propertyChangeListener = i.events.subscribe(
|
|
5465
|
+
"components:properties-changed",
|
|
5466
|
+
(l, d) => {
|
|
5467
|
+
o.id === d.node.id && this._setProperties(d.node.attributes.properties);
|
|
5468
|
+
}
|
|
5469
|
+
), this._contextChangeListener = i.events.subscribe(
|
|
5470
|
+
"components:context-changed",
|
|
5471
|
+
(l, d) => {
|
|
5472
|
+
o.id === d.node.id && this._setContext(d.node.attributes.context);
|
|
5473
|
+
}
|
|
5474
|
+
), this._layoutChangeListener = i.events.subscribe(
|
|
5475
|
+
"components:layout-changed",
|
|
5476
|
+
(l, d) => {
|
|
5477
|
+
o.id === d.node.id && this._setLayout(d.node.attributes.layout);
|
|
5478
|
+
}
|
|
5479
|
+
);
|
|
5480
|
+
const a = "default";
|
|
5481
|
+
this._unmountNode = o.mount(this.container), this._setDescriptor(Bs(o, a)), this._setProperties(o.attributes.properties), this._setContext(o.attributes.context), this._setLayout(this.layout);
|
|
5482
|
+
const c = o.getChildren(a).map((l) => Bs(l));
|
|
5483
|
+
this._childrenProvider.setValue(c);
|
|
5484
|
+
const h = (yield this.container.getAsync("componentResolver")).getComponent(
|
|
5485
|
+
((r = this.descriptor) == null ? void 0 : r.type) || ""
|
|
5486
|
+
);
|
|
5487
|
+
h.then && h.then((l) => {
|
|
5488
|
+
this.component = l.default;
|
|
5489
|
+
});
|
|
5490
|
+
}
|
|
5491
|
+
})
|
|
5492
|
+
));
|
|
5493
|
+
}
|
|
5494
|
+
disconnectedCallback() {
|
|
5495
|
+
super.disconnectedCallback(), this._propertyChangeListener && this._propertyChangeListener(), this._contextChangeListener && this._contextChangeListener(), this._layoutChangeListener && this._layoutChangeListener(), this._unmountNode && this._unmountNode();
|
|
5496
|
+
}
|
|
5497
|
+
updated() {
|
|
5498
|
+
aa(this.context, this.renderRoot.host), this.renderRoot.host.style.setProperty(
|
|
5499
|
+
"--width",
|
|
5500
|
+
this.layout.size === "full" ? "var(--columns, 1)" : `min(${this.layout.size || "var(--columns)"}, var(--columns))`
|
|
5501
|
+
), ha(this.renderRoot.host, this.properties);
|
|
5502
|
+
}
|
|
5503
|
+
_setProperties(i) {
|
|
5504
|
+
this._propertiesProvider.setValue(i), this.properties = i;
|
|
5505
|
+
}
|
|
5506
|
+
_setContext(i) {
|
|
5507
|
+
this._contextProvider.setValue(i), this.context = i;
|
|
5508
|
+
}
|
|
5509
|
+
_setLayout(i) {
|
|
5510
|
+
this._layoutProvider.setValue(i), this.layout = i;
|
|
5511
|
+
}
|
|
5512
|
+
_setDescriptor(i) {
|
|
5513
|
+
this.descriptor = i, this._descriptorProvider.setValue(i), this.actions.setDescriptor(i);
|
|
5514
|
+
}
|
|
5515
|
+
}
|
|
5516
|
+
return e.styles = [
|
|
5517
|
+
(t = s.styles) != null ? t : [],
|
|
5518
|
+
zn`
|
|
5519
|
+
:host {
|
|
5520
|
+
--font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
|
|
5521
|
+
--spacing-xs: 0.2rem;
|
|
5522
|
+
--spacing-sm: 0.5rem;
|
|
5523
|
+
--spacing-md: 1rem;
|
|
5524
|
+
--spacing-lg: 1.2rem;
|
|
5525
|
+
--spacing-xl: 1.8rem;
|
|
5526
|
+
|
|
5527
|
+
--primary-color: #29003e;
|
|
5528
|
+
--secondary-color: #00558f;
|
|
5529
|
+
--text-color: #222222;
|
|
5530
|
+
--link-color: #990ae3;
|
|
5531
|
+
--gray-color: #efefef;
|
|
5532
|
+
--gray-dark-color: #a6a6a6;
|
|
5533
|
+
|
|
5534
|
+
--box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
|
|
5535
|
+
--border-radius: 1rem;
|
|
5536
|
+
--border-radius-sm: 0.3rem;
|
|
5537
|
+
|
|
5538
|
+
font-family: var(--font-family);
|
|
5539
|
+
grid-column: span var(--width);
|
|
5540
|
+
max-width: 100%;
|
|
5541
|
+
overflow: hidden;
|
|
5542
|
+
box-sizing: border-box;
|
|
5543
|
+
display: block;
|
|
5544
|
+
}
|
|
5545
|
+
* {
|
|
5546
|
+
box-sizing: border-box;
|
|
5547
|
+
}
|
|
5548
|
+
`
|
|
5549
|
+
], F([
|
|
5550
|
+
Go({ context: ea }),
|
|
5551
|
+
Kt({ attribute: !1 })
|
|
5552
|
+
], e.prototype, "container", 2), F([
|
|
5553
|
+
Kt()
|
|
5554
|
+
], e.prototype, "entry", 2), F([
|
|
5555
|
+
U()
|
|
5556
|
+
], e.prototype, "descriptor", 2), F([
|
|
5557
|
+
U()
|
|
5558
|
+
], e.prototype, "component", 2), F([
|
|
5559
|
+
U()
|
|
5560
|
+
], e.prototype, "context", 2), F([
|
|
5561
|
+
U()
|
|
5562
|
+
], e.prototype, "layout", 2), F([
|
|
5563
|
+
U()
|
|
5564
|
+
], e.prototype, "properties", 2), e;
|
|
5565
|
+
}, ua = (s, t) => s.reduce((e, n, i) => {
|
|
5333
5566
|
var o, a;
|
|
5334
5567
|
const r = R(P({}, n), {
|
|
5335
5568
|
content: [R(P({}, n.content), { key: n.key })]
|
|
5336
5569
|
});
|
|
5337
|
-
if (e.length > 0 && n.type !==
|
|
5570
|
+
if (e.length > 0 && n.type !== Et.System) {
|
|
5338
5571
|
const c = e[e.length - 1];
|
|
5339
5572
|
if ((!t && t !== 0 || Math.abs(c.timestamp - n.timestamp) < t) && ((o = c.sender) == null ? void 0 : o.name) === ((a = n.sender) == null ? void 0 : a.name) && c.type === n.type)
|
|
5340
5573
|
return c.timestamp = n.timestamp, c.content.push(R(P({}, n.content), { key: n.key })), e;
|
|
5341
5574
|
}
|
|
5342
5575
|
return e.push(r), e;
|
|
5343
|
-
}, []),
|
|
5344
|
-
|
|
5345
|
-
return Fo(
|
|
5576
|
+
}, []), Da = (s) => w(void 0, null, function* () {
|
|
5577
|
+
return oa(
|
|
5346
5578
|
s,
|
|
5347
5579
|
"conversation",
|
|
5348
|
-
import("./conversation-
|
|
5349
|
-
(
|
|
5350
|
-
const { rehydrate: i = !1 } =
|
|
5580
|
+
import("./conversation-d6641d26.js"),
|
|
5581
|
+
(t) => w(void 0, null, function* () {
|
|
5582
|
+
const e = yield s.getAsync("router"), n = yield ts.getInstance(s), { rehydrate: i = !1 } = t.properties(), o = e.getRouteData().params.id || t.node.name || "component", a = yield n.createController(o, { rehydrate: i }), c = n.registerController(
|
|
5351
5583
|
a,
|
|
5352
|
-
|
|
5584
|
+
t
|
|
5353
5585
|
), h = 3 * 60 * 1e3, l = (u) => {
|
|
5354
5586
|
const { providers: g = [] } = u;
|
|
5355
5587
|
if (g) {
|
|
@@ -5358,52 +5590,52 @@ const Fo = (s, t, e, n, i) => s.getAsync("componentResolver").then((r) => (r.reg
|
|
|
5358
5590
|
}
|
|
5359
5591
|
};
|
|
5360
5592
|
l(
|
|
5361
|
-
|
|
5593
|
+
t.properties(l)
|
|
5362
5594
|
), a.setComponentMountedState(!0);
|
|
5363
5595
|
const d = (u) => {
|
|
5364
|
-
const { loading: g, typingActors: m, messages:
|
|
5365
|
-
|
|
5596
|
+
const { loading: g, typingActors: m, messages: A } = u;
|
|
5597
|
+
t.writeProperties({
|
|
5366
5598
|
loading: g,
|
|
5367
5599
|
typingActors: m,
|
|
5368
|
-
messages:
|
|
5600
|
+
messages: ua(A, h)
|
|
5369
5601
|
});
|
|
5370
5602
|
};
|
|
5371
|
-
d(a.getMessageStream()), c && (
|
|
5603
|
+
d(a.getMessageStream()), c && (t.writeProperties({
|
|
5372
5604
|
conversationControllerId: a.id
|
|
5373
|
-
}),
|
|
5605
|
+
}), t.actions.create("user-submit", (u, g) => {
|
|
5374
5606
|
if (g) {
|
|
5375
|
-
const { preventDefault: m, validationPromise:
|
|
5607
|
+
const { preventDefault: m, validationPromise: A } = g;
|
|
5376
5608
|
if (m) {
|
|
5377
|
-
|
|
5378
|
-
|
|
5609
|
+
A && A().then((L) => {
|
|
5610
|
+
L && a.user.print(L);
|
|
5379
5611
|
});
|
|
5380
5612
|
return;
|
|
5381
5613
|
}
|
|
5382
5614
|
}
|
|
5383
5615
|
a.user.print(u.text);
|
|
5384
|
-
}),
|
|
5385
|
-
}),
|
|
5386
|
-
}),
|
|
5387
|
-
}),
|
|
5388
|
-
}),
|
|
5389
|
-
|
|
5616
|
+
}), t.actions.create("user-typing", (u, g) => {
|
|
5617
|
+
}), t.actions.create("form", (u, g) => {
|
|
5618
|
+
}), t.actions.create("action", (u, g) => {
|
|
5619
|
+
}), t.actions.create("overlay-mounted", (u, g) => {
|
|
5620
|
+
}), t.actions.create("show-overlay", (u, g) => {
|
|
5621
|
+
t.writeProperties({
|
|
5390
5622
|
overlay: { conversation: !1, secondary: !1 }
|
|
5391
5623
|
});
|
|
5392
|
-
}),
|
|
5393
|
-
|
|
5624
|
+
}), t.actions.create("hide-overlay", (u, g) => {
|
|
5625
|
+
t.writeProperties({
|
|
5394
5626
|
overlay: null
|
|
5395
5627
|
});
|
|
5396
|
-
}),
|
|
5628
|
+
}), t.actions.create(
|
|
5397
5629
|
"show-overlay-conversation",
|
|
5398
5630
|
(u, g) => {
|
|
5399
|
-
|
|
5631
|
+
t.writeProperties({
|
|
5400
5632
|
overlay: { conversation: !0, secondary: !1 }
|
|
5401
5633
|
});
|
|
5402
5634
|
}
|
|
5403
|
-
),
|
|
5635
|
+
), t.actions.create(
|
|
5404
5636
|
"hide-overlay-conversation",
|
|
5405
5637
|
(u, g) => {
|
|
5406
|
-
|
|
5638
|
+
t.writeProperties({
|
|
5407
5639
|
overlay: { conversation: !1, secondary: !1 }
|
|
5408
5640
|
});
|
|
5409
5641
|
}
|
|
@@ -5420,21 +5652,19 @@ const Fo = (s, t, e, n, i) => s.getAsync("componentResolver").then((r) => (r.reg
|
|
|
5420
5652
|
})
|
|
5421
5653
|
);
|
|
5422
5654
|
});
|
|
5423
|
-
var
|
|
5424
|
-
const
|
|
5655
|
+
var pa = /* @__PURE__ */ ((s) => (s.LinkList = "link-list", s.Separator = "separator", s.ButtonList = "button-list", s.ItemList = "item-list", s.Text = "text", s.HTML = "html", s.VideoRequest = "video-request", s))(pa || {});
|
|
5656
|
+
const Ma = (s, t, e) => w(void 0, null, function* () {
|
|
5425
5657
|
yield e;
|
|
5426
5658
|
});
|
|
5427
5659
|
export {
|
|
5428
|
-
|
|
5429
|
-
|
|
5430
|
-
|
|
5431
|
-
|
|
5432
|
-
|
|
5433
|
-
|
|
5434
|
-
|
|
5435
|
-
|
|
5436
|
-
|
|
5437
|
-
va as m,
|
|
5438
|
-
ya as r
|
|
5660
|
+
Et as C,
|
|
5661
|
+
ja as D,
|
|
5662
|
+
ts as a,
|
|
5663
|
+
Ut as b,
|
|
5664
|
+
Da as c,
|
|
5665
|
+
gr as d,
|
|
5666
|
+
pr as e,
|
|
5667
|
+
pa as f,
|
|
5668
|
+
Ma as r
|
|
5439
5669
|
};
|
|
5440
|
-
//# sourceMappingURL=index-
|
|
5670
|
+
//# sourceMappingURL=index-1d35e98e.js.map
|