@telia-ace/widget-runtime-flamingo 1.0.15 → 1.0.32
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/component-platform-factory.d.ts → component-platform-factory.d.ts} +0 -1
- package/{dist/context → context}/children.context.d.ts +0 -1
- package/{dist/context → context}/component-node.context.d.ts +0 -1
- package/{dist/context → context}/container.context.d.ts +0 -1
- package/{dist/context → context}/context.context.d.ts +0 -1
- package/{dist/context → context}/layout.context.d.ts +0 -1
- package/{dist/context → context}/properties.context.d.ts +0 -1
- package/{dist/controllers → controllers}/actions-controller.d.ts +0 -1
- package/{dist/core → core}/create-lit-component.d.ts +0 -1
- package/{dist/core → core}/get-render-state.d.ts +0 -1
- package/{dist/data-provider → data-provider}/data-provider.d.ts +0 -1
- package/{dist/data-provider → data-provider}/providers/guide-provider.plugin.d.ts +0 -1
- package/{dist/index-9688347a.js → index-5087564d.mjs} +1 -2
- package/index-6dd00f59.js +1 -0
- package/index-7a734709.mjs +3405 -0
- package/index-c94328c7.js +206 -0
- package/{dist/index.d.ts → index.d.ts} +0 -1
- package/index.js +1 -0
- package/{dist/index.js → index.mjs} +1 -2
- package/{dist/mixins → mixins}/widget-component.mixin.d.ts +0 -1
- package/package.json +10 -49
- package/render-42bea194.js +118 -0
- package/{dist/render-416c8c88.js → render-ad873416.mjs} +153 -160
- package/{dist/services.d.ts → services.d.ts} +0 -2
- package/{dist/ui → ui}/area.d.ts +0 -1
- package/{dist/ui → ui}/branding.d.ts +0 -1
- package/{dist/ui → ui}/get-css-props.d.ts +0 -1
- package/{dist/ui → ui}/get-layout-props.d.ts +0 -1
- package/{dist/ui → ui}/html-element-handlers.d.ts +0 -1
- package/{dist/ui → ui}/prepare-dom.d.ts +2 -2
- package/{dist/ui → ui}/render.d.ts +0 -2
- package/{dist/ui → ui}/trigger-component.d.ts +4 -2
- package/{dist/ui → ui}/view-outlet.d.ts +5 -2
- package/{dist/ui → ui}/wrapper.d.ts +0 -1
- package/{dist/widget.d.ts → widget.d.ts} +0 -1
- package/LICENSE.txt +0 -6
- package/README.md +0 -3
- package/dist/component-platform-factory.d.ts.map +0 -1
- package/dist/context/children.context.d.ts.map +0 -1
- package/dist/context/component-node.context.d.ts.map +0 -1
- package/dist/context/container.context.d.ts.map +0 -1
- package/dist/context/context.context.d.ts.map +0 -1
- package/dist/context/layout.context.d.ts.map +0 -1
- package/dist/context/properties.context.d.ts.map +0 -1
- package/dist/controllers/actions-controller.d.ts.map +0 -1
- package/dist/core/create-lit-component.d.ts.map +0 -1
- package/dist/core/get-render-state.d.ts.map +0 -1
- package/dist/data-provider/data-provider.d.ts.map +0 -1
- package/dist/data-provider/providers/guide-provider.plugin.d.ts.map +0 -1
- package/dist/index-79b338f7.js +0 -4870
- package/dist/index-79b338f7.js.map +0 -1
- package/dist/index-9688347a.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/mixins/widget-component.mixin.d.ts.map +0 -1
- package/dist/render-416c8c88.js.map +0 -1
- package/dist/services.d.ts.map +0 -1
- package/dist/ui/area.d.ts.map +0 -1
- package/dist/ui/branding.d.ts.map +0 -1
- package/dist/ui/get-css-props.d.ts.map +0 -1
- package/dist/ui/get-layout-props.d.ts.map +0 -1
- package/dist/ui/html-element-handlers.d.ts.map +0 -1
- package/dist/ui/index.d.ts +0 -2
- package/dist/ui/index.d.ts.map +0 -1
- package/dist/ui/prepare-dom.d.ts.map +0 -1
- package/dist/ui/render.d.ts.map +0 -1
- package/dist/ui/trigger-component.d.ts.map +0 -1
- package/dist/ui/view-outlet.d.ts.map +0 -1
- package/dist/ui/wrapper.d.ts.map +0 -1
- package/dist/widget.d.ts.map +0 -1
|
@@ -1,41 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
var N = Object.getOwnPropertyDescriptors;
|
|
3
|
-
var A = Object.getOwnPropertySymbols;
|
|
4
|
-
var T = Object.prototype.hasOwnProperty, W = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var P = (s, t, e) => t in s ? z(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, u = (s, t) => {
|
|
6
|
-
for (var e in t || (t = {}))
|
|
7
|
-
T.call(t, e) && P(s, e, t[e]);
|
|
8
|
-
if (A)
|
|
9
|
-
for (var e of A(t))
|
|
10
|
-
W.call(t, e) && P(s, e, t[e]);
|
|
11
|
-
return s;
|
|
12
|
-
}, x = (s, t) => E(s, N(t));
|
|
13
|
-
var d = (s, t, e) => new Promise((i, n) => {
|
|
14
|
-
var o = (h) => {
|
|
15
|
-
try {
|
|
16
|
-
a(e.next(h));
|
|
17
|
-
} catch (l) {
|
|
18
|
-
n(l);
|
|
19
|
-
}
|
|
20
|
-
}, r = (h) => {
|
|
21
|
-
try {
|
|
22
|
-
a(e.throw(h));
|
|
23
|
-
} catch (l) {
|
|
24
|
-
n(l);
|
|
25
|
-
}
|
|
26
|
-
}, a = (h) => h.done ? i(h.value) : Promise.resolve(h.value).then(o, r);
|
|
27
|
-
a((e = e.apply(s, t)).next());
|
|
28
|
-
});
|
|
29
|
-
import { i as q, t as I, e as G, A as w, s as O, a as K, c as Z, p as H, m as _, x as $, b as L, n as U, d as m, T as R, W as V, f as Q, g as B } from "./index-79b338f7.js";
|
|
1
|
+
import { i as L, t as D, e as A, A as y, s as P, a as Y, c as M, p as T, m as f, x as v, b as R, n as j, d as u, T as w, W as z, f as E, g as N } from "./index-7a734709.mjs";
|
|
30
2
|
/**
|
|
31
3
|
* @license
|
|
32
4
|
* Copyright 2017 Google LLC
|
|
33
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
34
6
|
*/
|
|
35
|
-
const
|
|
36
|
-
const { kind: n, elements:
|
|
37
|
-
return { kind: n, elements:
|
|
38
|
-
customElements.define(e,
|
|
7
|
+
const S = (s) => (t) => typeof t == "function" ? ((e, i) => (customElements.define(e, i), i))(s, t) : ((e, i) => {
|
|
8
|
+
const { kind: n, elements: r } = i;
|
|
9
|
+
return { kind: n, elements: r, finisher(o) {
|
|
10
|
+
customElements.define(e, o);
|
|
39
11
|
} };
|
|
40
12
|
})(s, t);
|
|
41
13
|
/**
|
|
@@ -43,69 +15,69 @@ const D = (s) => (t) => typeof t == "function" ? ((e, i) => (customElements.defi
|
|
|
43
15
|
* Copyright 2020 Google LLC
|
|
44
16
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
45
17
|
*/
|
|
46
|
-
const
|
|
18
|
+
const W = (s) => s === null || typeof s != "object" && typeof s != "function", q = (s) => s.strings === void 0;
|
|
47
19
|
/**
|
|
48
20
|
* @license
|
|
49
21
|
* Copyright 2017 Google LLC
|
|
50
22
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
51
23
|
*/
|
|
52
|
-
const
|
|
24
|
+
const p = (s, t) => {
|
|
53
25
|
var e, i;
|
|
54
26
|
const n = s._$AN;
|
|
55
27
|
if (n === void 0)
|
|
56
28
|
return !1;
|
|
57
|
-
for (const
|
|
58
|
-
(i = (e =
|
|
29
|
+
for (const r of n)
|
|
30
|
+
(i = (e = r)._$AO) === null || i === void 0 || i.call(e, t, !1), p(r, t);
|
|
59
31
|
return !0;
|
|
60
|
-
},
|
|
32
|
+
}, m = (s) => {
|
|
61
33
|
let t, e;
|
|
62
34
|
do {
|
|
63
35
|
if ((t = s._$AM) === void 0)
|
|
64
36
|
break;
|
|
65
37
|
e = t._$AN, e.delete(s), s = t;
|
|
66
38
|
} while ((e == null ? void 0 : e.size) === 0);
|
|
67
|
-
},
|
|
39
|
+
}, k = (s) => {
|
|
68
40
|
for (let t; t = s._$AM; s = t) {
|
|
69
41
|
let e = t._$AN;
|
|
70
42
|
if (e === void 0)
|
|
71
43
|
t._$AN = e = /* @__PURE__ */ new Set();
|
|
72
44
|
else if (e.has(s))
|
|
73
45
|
break;
|
|
74
|
-
e.add(s),
|
|
46
|
+
e.add(s), K(t);
|
|
75
47
|
}
|
|
76
48
|
};
|
|
77
|
-
function
|
|
78
|
-
this._$AN !== void 0 ? (
|
|
49
|
+
function H(s) {
|
|
50
|
+
this._$AN !== void 0 ? (m(this), this._$AM = s, k(this)) : this._$AM = s;
|
|
79
51
|
}
|
|
80
|
-
function
|
|
52
|
+
function I(s, t = !1, e = 0) {
|
|
81
53
|
const i = this._$AH, n = this._$AN;
|
|
82
54
|
if (n !== void 0 && n.size !== 0)
|
|
83
55
|
if (t)
|
|
84
56
|
if (Array.isArray(i))
|
|
85
|
-
for (let
|
|
86
|
-
|
|
57
|
+
for (let r = e; r < i.length; r++)
|
|
58
|
+
p(i[r], !1), m(i[r]);
|
|
87
59
|
else
|
|
88
|
-
i != null && (
|
|
60
|
+
i != null && (p(i, !1), m(i));
|
|
89
61
|
else
|
|
90
|
-
|
|
62
|
+
p(this, s);
|
|
91
63
|
}
|
|
92
|
-
const
|
|
64
|
+
const K = (s) => {
|
|
93
65
|
var t, e, i, n;
|
|
94
|
-
s.type ==
|
|
66
|
+
s.type == D.CHILD && ((t = (i = s)._$AP) !== null && t !== void 0 || (i._$AP = I), (e = (n = s)._$AQ) !== null && e !== void 0 || (n._$AQ = H));
|
|
95
67
|
};
|
|
96
|
-
let
|
|
68
|
+
let G = class extends L {
|
|
97
69
|
constructor() {
|
|
98
70
|
super(...arguments), this._$AN = void 0;
|
|
99
71
|
}
|
|
100
72
|
_$AT(t, e, i) {
|
|
101
|
-
super._$AT(t, e, i),
|
|
73
|
+
super._$AT(t, e, i), k(this), this.isConnected = t._$AU;
|
|
102
74
|
}
|
|
103
75
|
_$AO(t, e = !0) {
|
|
104
76
|
var i, n;
|
|
105
|
-
t !== this.isConnected && (this.isConnected = t, t ? (i = this.reconnected) === null || i === void 0 || i.call(this) : (n = this.disconnected) === null || n === void 0 || n.call(this)), e && (
|
|
77
|
+
t !== this.isConnected && (this.isConnected = t, t ? (i = this.reconnected) === null || i === void 0 || i.call(this) : (n = this.disconnected) === null || n === void 0 || n.call(this)), e && (p(this, t), m(this));
|
|
106
78
|
}
|
|
107
79
|
setValue(t) {
|
|
108
|
-
if (
|
|
80
|
+
if (q(this._$Ct))
|
|
109
81
|
this._$Ct._$AI(t, this);
|
|
110
82
|
else {
|
|
111
83
|
const e = [...this._$Ct._$AH];
|
|
@@ -122,30 +94,30 @@ let M = class extends q {
|
|
|
122
94
|
* Copyright 2020 Google LLC
|
|
123
95
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
124
96
|
*/
|
|
125
|
-
const
|
|
126
|
-
class
|
|
97
|
+
const Z = () => new U();
|
|
98
|
+
class U {
|
|
127
99
|
}
|
|
128
|
-
const
|
|
100
|
+
const $ = /* @__PURE__ */ new WeakMap(), V = A(class extends G {
|
|
129
101
|
render(s) {
|
|
130
|
-
return
|
|
102
|
+
return y;
|
|
131
103
|
}
|
|
132
104
|
update(s, [t]) {
|
|
133
105
|
var e;
|
|
134
106
|
const i = t !== this.G;
|
|
135
|
-
return i && this.G !== void 0 && this.ot(void 0), (i || this.rt !== this.lt) && (this.G = t, this.dt = (e = s.options) === null || e === void 0 ? void 0 : e.host, this.ot(this.lt = s.element)),
|
|
107
|
+
return i && this.G !== void 0 && this.ot(void 0), (i || this.rt !== this.lt) && (this.G = t, this.dt = (e = s.options) === null || e === void 0 ? void 0 : e.host, this.ot(this.lt = s.element)), y;
|
|
136
108
|
}
|
|
137
109
|
ot(s) {
|
|
138
110
|
var t;
|
|
139
111
|
if (typeof this.G == "function") {
|
|
140
112
|
const e = (t = this.dt) !== null && t !== void 0 ? t : globalThis;
|
|
141
|
-
let i =
|
|
142
|
-
i === void 0 && (i = /* @__PURE__ */ new WeakMap(),
|
|
113
|
+
let i = $.get(e);
|
|
114
|
+
i === void 0 && (i = /* @__PURE__ */ new WeakMap(), $.set(e, i)), i.get(this.G) !== void 0 && this.G.call(this.dt, void 0), i.set(this.G, s), s !== void 0 && this.G.call(this.dt, s);
|
|
143
115
|
} else
|
|
144
116
|
this.G.value = s;
|
|
145
117
|
}
|
|
146
118
|
get rt() {
|
|
147
119
|
var s, t, e;
|
|
148
|
-
return typeof this.G == "function" ? (t =
|
|
120
|
+
return typeof this.G == "function" ? (t = $.get((s = this.dt) !== null && s !== void 0 ? s : globalThis)) === null || t === void 0 ? void 0 : t.get(this.G) : (e = this.G) === null || e === void 0 ? void 0 : e.value;
|
|
149
121
|
}
|
|
150
122
|
disconnected() {
|
|
151
123
|
this.rt === this.lt && this.ot(void 0);
|
|
@@ -153,43 +125,43 @@ const b = /* @__PURE__ */ new WeakMap(), nt = G(class extends M {
|
|
|
153
125
|
reconnected() {
|
|
154
126
|
this.ot(this.lt);
|
|
155
127
|
}
|
|
156
|
-
}),
|
|
157
|
-
return yield s.get("$widget").invoke("renderState");
|
|
158
|
-
}), rt = (s, t) => d(void 0, null, function* () {
|
|
128
|
+
}), Q = async (s) => await s.get("$widget").invoke("renderState"), B = async (s, t) => {
|
|
159
129
|
const e = s.get("$widget");
|
|
160
|
-
return (
|
|
161
|
-
|
|
130
|
+
return (await s.getAsync(
|
|
131
|
+
"actionResolver"
|
|
132
|
+
)).subscribe(e.name, t);
|
|
133
|
+
}, F = (s, t, e = !1) => {
|
|
162
134
|
const i = s.reduce(
|
|
163
|
-
(
|
|
135
|
+
(o, { breakpoints: a = [], values: l }) => a.length ? t.some((g) => a.includes(g)) ? { ...o, ...l } : o : { ...o, ...l },
|
|
164
136
|
{}
|
|
165
137
|
), n = {};
|
|
166
|
-
let
|
|
167
|
-
return n.height = i.height || "", n.width = i.width || "", i.type === "floating" || i.type === "inline" && e && (n.height = "calc(100vh - 120px)"), { type:
|
|
138
|
+
let r = i.type;
|
|
139
|
+
return n.height = i.height || "", n.width = i.width || "", i.type === "floating" || i.type === "inline" && e && (n.height = "calc(100vh - 120px)"), { type: r, styles: n };
|
|
168
140
|
};
|
|
169
|
-
var
|
|
170
|
-
for (var n = i > 1 ? void 0 : i ?
|
|
171
|
-
(
|
|
172
|
-
return i && n &&
|
|
141
|
+
var J = Object.defineProperty, X = Object.getOwnPropertyDescriptor, h = (s, t, e, i) => {
|
|
142
|
+
for (var n = i > 1 ? void 0 : i ? X(t, e) : t, r = s.length - 1, o; r >= 0; r--)
|
|
143
|
+
(o = s[r]) && (n = (i ? o(t, e, n) : o(n)) || n);
|
|
144
|
+
return i && n && J(t, e, n), n;
|
|
173
145
|
};
|
|
174
|
-
let c = class extends
|
|
146
|
+
let c = class extends P {
|
|
175
147
|
constructor() {
|
|
176
|
-
super(), this._provider = new
|
|
148
|
+
super(), this._provider = new Y(this, M, void 0), this.wrapperRef = Z(), this.breakpoints = [], this.breakpointsSet = !1;
|
|
177
149
|
}
|
|
178
150
|
connectedCallback() {
|
|
179
|
-
super.connectedCallback(), this._provider.setValue(this.container), this.container && (
|
|
151
|
+
super.connectedCallback(), this._provider.setValue(this.container), this.container && (Q(this.container).then((s) => {
|
|
180
152
|
this.renderState = s;
|
|
181
|
-
}),
|
|
153
|
+
}), B(this.container, (s, t) => {
|
|
182
154
|
switch (t) {
|
|
183
155
|
case "close":
|
|
184
156
|
case "open":
|
|
185
|
-
this.renderState = t === "open" ?
|
|
157
|
+
this.renderState = t === "open" ? f.open : f.closed;
|
|
186
158
|
break;
|
|
187
159
|
case "hide":
|
|
188
|
-
this.renderState =
|
|
160
|
+
this.renderState = f.hidden;
|
|
189
161
|
}
|
|
190
162
|
}).then((s) => {
|
|
191
163
|
this._unsubscribeRenderState = s;
|
|
192
|
-
}),
|
|
164
|
+
}), T.getInstance(this.container).then(
|
|
193
165
|
(s) => {
|
|
194
166
|
this.componentPlatform = s, this.breakpoints = this.componentPlatform.breakpoints, this.breakpointsSet = !0, this._unsubscribePropChange = this.componentPlatform.events.subscribe(
|
|
195
167
|
"components:properties-changed",
|
|
@@ -208,29 +180,48 @@ let c = class extends O {
|
|
|
208
180
|
var t, e, i, n;
|
|
209
181
|
let s;
|
|
210
182
|
if (!this.entry || !this.breakpointsSet)
|
|
211
|
-
return
|
|
183
|
+
return y;
|
|
212
184
|
if (this.container && this.renderState) {
|
|
213
|
-
const [
|
|
214
|
-
|
|
185
|
+
const [r] = this.container.get("widgetDOMElements");
|
|
186
|
+
r && r.setAttribute("data-state", this.renderState);
|
|
215
187
|
}
|
|
216
188
|
if (this.container) {
|
|
217
|
-
const
|
|
218
|
-
|
|
219
|
-
|
|
189
|
+
const r = this.container.get("$settings");
|
|
190
|
+
r != null && r.layout && (s = F(
|
|
191
|
+
r.layout,
|
|
220
192
|
this.breakpoints,
|
|
221
|
-
!!
|
|
222
|
-
), s.type === "floating" ? (this.renderRoot.host.classList.add("floating"), this.renderRoot.host.classList.remove("inline")) : (this.renderRoot.host.classList.add("inline"), this.renderRoot.host.classList.remove("floating")), Object.entries(s.styles).forEach(([
|
|
223
|
-
this.renderRoot.host.style.setProperty(
|
|
193
|
+
!!r.trigger
|
|
194
|
+
), s.type === "floating" ? (this.renderRoot.host.classList.add("floating"), this.renderRoot.host.classList.remove("inline")) : (this.renderRoot.host.classList.add("inline"), this.renderRoot.host.classList.remove("floating")), Object.entries(s.styles).forEach(([o, a]) => {
|
|
195
|
+
this.renderRoot.host.style.setProperty(o, a);
|
|
224
196
|
}));
|
|
225
197
|
}
|
|
226
|
-
return this.renderState && (this.renderState ===
|
|
227
|
-
<div class="widget-container" ${
|
|
198
|
+
return this.renderState && (this.renderState === f.hidden ? ((t = this.wrapperRef.value) == null || t.classList.add("hidden"), (e = this.wrapperRef.value) == null || e.classList.remove("expanded")) : ((i = this.wrapperRef.value) == null || i.classList.remove("hidden"), (n = this.wrapperRef.value) == null || n.classList.add("expanded"))), v`
|
|
199
|
+
<div class="widget-container" ${V(this.wrapperRef)}>
|
|
228
200
|
<ace-area entry=${this.entry}></ace-area>
|
|
229
201
|
</div>
|
|
230
202
|
`;
|
|
231
203
|
}
|
|
232
204
|
};
|
|
233
|
-
c.styles =
|
|
205
|
+
c.styles = R`
|
|
206
|
+
:host {
|
|
207
|
+
--font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
|
|
208
|
+
--spacing-xs: 0.2rem;
|
|
209
|
+
--spacing-sm: 0.5rem;
|
|
210
|
+
--spacing-md: 1rem;
|
|
211
|
+
--spacing-lg: 1.2rem;
|
|
212
|
+
--spacing-xl: 1.8rem;
|
|
213
|
+
|
|
214
|
+
--primary-color: #29003e;
|
|
215
|
+
--secondary-color: #00558f;
|
|
216
|
+
--text-color: #222222;
|
|
217
|
+
--link-color: #990ae3;
|
|
218
|
+
--gray-color: #efefef;
|
|
219
|
+
--gray-dark-color: #a6a6a6;
|
|
220
|
+
|
|
221
|
+
--box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
|
|
222
|
+
--border-radius: 1rem;
|
|
223
|
+
--border-radius-sm: 0.3rem;
|
|
224
|
+
}
|
|
234
225
|
:host {
|
|
235
226
|
--voca-rem-multiplier: 0.625;
|
|
236
227
|
box-sizing: border-box;
|
|
@@ -246,7 +237,6 @@ c.styles = L`
|
|
|
246
237
|
:host(.floating) .widget-container {
|
|
247
238
|
box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
|
|
248
239
|
border-radius: 0.7rem;
|
|
249
|
-
height: 100%;
|
|
250
240
|
}
|
|
251
241
|
:host(.inline) {
|
|
252
242
|
height: 100%;
|
|
@@ -257,6 +247,9 @@ c.styles = L`
|
|
|
257
247
|
* {
|
|
258
248
|
box-sizing: border-box;
|
|
259
249
|
}
|
|
250
|
+
.widget-container {
|
|
251
|
+
height: 100%;
|
|
252
|
+
}
|
|
260
253
|
.widget-container.expanded {
|
|
261
254
|
opacity: 1;
|
|
262
255
|
animation: slideUp 0.5s;
|
|
@@ -286,33 +279,33 @@ c.styles = L`
|
|
|
286
279
|
}
|
|
287
280
|
}
|
|
288
281
|
`;
|
|
289
|
-
|
|
290
|
-
|
|
282
|
+
h([
|
|
283
|
+
j({ attribute: !1 })
|
|
291
284
|
], c.prototype, "container", 2);
|
|
292
|
-
|
|
293
|
-
|
|
285
|
+
h([
|
|
286
|
+
u()
|
|
294
287
|
], c.prototype, "componentPlatform", 2);
|
|
295
|
-
|
|
296
|
-
|
|
288
|
+
h([
|
|
289
|
+
u()
|
|
297
290
|
], c.prototype, "renderState", 2);
|
|
298
|
-
|
|
299
|
-
|
|
291
|
+
h([
|
|
292
|
+
u()
|
|
300
293
|
], c.prototype, "breakpoints", 2);
|
|
301
|
-
|
|
302
|
-
|
|
294
|
+
h([
|
|
295
|
+
u()
|
|
303
296
|
], c.prototype, "breakpointsSet", 2);
|
|
304
|
-
|
|
305
|
-
|
|
297
|
+
h([
|
|
298
|
+
u()
|
|
306
299
|
], c.prototype, "entry", 2);
|
|
307
|
-
c =
|
|
308
|
-
|
|
300
|
+
c = h([
|
|
301
|
+
S("ace-widget-wrapper")
|
|
309
302
|
], c);
|
|
310
303
|
/**
|
|
311
304
|
* @license
|
|
312
305
|
* Copyright 2021 Google LLC
|
|
313
306
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
314
307
|
*/
|
|
315
|
-
class
|
|
308
|
+
class tt {
|
|
316
309
|
constructor(t) {
|
|
317
310
|
this.G = t;
|
|
318
311
|
}
|
|
@@ -326,7 +319,7 @@ class lt {
|
|
|
326
319
|
return this.G;
|
|
327
320
|
}
|
|
328
321
|
}
|
|
329
|
-
class
|
|
322
|
+
class et {
|
|
330
323
|
constructor() {
|
|
331
324
|
this.Y = void 0, this.Z = void 0;
|
|
332
325
|
}
|
|
@@ -347,36 +340,36 @@ class dt {
|
|
|
347
340
|
* Copyright 2017 Google LLC
|
|
348
341
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
349
342
|
*/
|
|
350
|
-
const
|
|
351
|
-
class
|
|
343
|
+
const C = (s) => !W(s) && typeof s.then == "function", x = 1073741823;
|
|
344
|
+
class st extends G {
|
|
352
345
|
constructor() {
|
|
353
|
-
super(...arguments), this._$C_t =
|
|
346
|
+
super(...arguments), this._$C_t = x, this._$Cwt = [], this._$Cq = new tt(this), this._$CK = new et();
|
|
354
347
|
}
|
|
355
348
|
render(...t) {
|
|
356
349
|
var e;
|
|
357
|
-
return (e = t.find((i) => !
|
|
350
|
+
return (e = t.find((i) => !C(i))) !== null && e !== void 0 ? e : w;
|
|
358
351
|
}
|
|
359
352
|
update(t, e) {
|
|
360
353
|
const i = this._$Cwt;
|
|
361
354
|
let n = i.length;
|
|
362
355
|
this._$Cwt = e;
|
|
363
|
-
const
|
|
356
|
+
const r = this._$Cq, o = this._$CK;
|
|
364
357
|
this.isConnected || this.disconnected();
|
|
365
358
|
for (let a = 0; a < e.length && !(a > this._$C_t); a++) {
|
|
366
|
-
const
|
|
367
|
-
if (!
|
|
368
|
-
return this._$C_t = a,
|
|
369
|
-
a < n &&
|
|
370
|
-
for (;
|
|
371
|
-
|
|
372
|
-
const
|
|
373
|
-
if (
|
|
374
|
-
const
|
|
375
|
-
|
|
359
|
+
const l = e[a];
|
|
360
|
+
if (!C(l))
|
|
361
|
+
return this._$C_t = a, l;
|
|
362
|
+
a < n && l === i[a] || (this._$C_t = x, n = 0, Promise.resolve(l).then(async (g) => {
|
|
363
|
+
for (; o.get(); )
|
|
364
|
+
await o.get();
|
|
365
|
+
const d = r.deref();
|
|
366
|
+
if (d !== void 0) {
|
|
367
|
+
const _ = d._$Cwt.indexOf(l);
|
|
368
|
+
_ > -1 && _ < d._$C_t && (d._$C_t = _, d.setValue(g));
|
|
376
369
|
}
|
|
377
|
-
}))
|
|
370
|
+
}));
|
|
378
371
|
}
|
|
379
|
-
return
|
|
372
|
+
return w;
|
|
380
373
|
}
|
|
381
374
|
disconnected() {
|
|
382
375
|
this._$Cq.disconnect(), this._$CK.pause();
|
|
@@ -385,48 +378,49 @@ class pt extends M {
|
|
|
385
378
|
this._$Cq.reconnect(this), this._$CK.resume();
|
|
386
379
|
}
|
|
387
380
|
}
|
|
388
|
-
const
|
|
389
|
-
var
|
|
390
|
-
for (var n = i > 1 ? void 0 : i ?
|
|
391
|
-
(
|
|
392
|
-
return i && n &&
|
|
381
|
+
const it = A(st);
|
|
382
|
+
var nt = Object.defineProperty, rt = Object.getOwnPropertyDescriptor, ot = (s, t, e, i) => {
|
|
383
|
+
for (var n = i > 1 ? void 0 : i ? rt(t, e) : t, r = s.length - 1, o; r >= 0; r--)
|
|
384
|
+
(o = s[r]) && (n = (i ? o(t, e, n) : o(n)) || n);
|
|
385
|
+
return i && n && nt(t, e, n), n;
|
|
393
386
|
};
|
|
394
|
-
const
|
|
395
|
-
let
|
|
387
|
+
const O = z(P);
|
|
388
|
+
let b = class extends O {
|
|
396
389
|
constructor() {
|
|
397
|
-
super(...arguments), this._resolveChildComponent = (s) =>
|
|
398
|
-
const e = (
|
|
390
|
+
super(...arguments), this._resolveChildComponent = async (s) => {
|
|
391
|
+
const e = (await this.container.getAsync(
|
|
392
|
+
"componentResolver"
|
|
393
|
+
)).getComponent(s);
|
|
399
394
|
if (e.then)
|
|
400
395
|
return e.then((i) => i.default);
|
|
401
|
-
}
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
});
|
|
396
|
+
}, this._resolveAllChildren = async (s) => Promise.all(
|
|
397
|
+
s.map(async (t) => {
|
|
398
|
+
let e = customElements.get(`ace-${t.type}`);
|
|
399
|
+
return e || (e = await this._resolveChildComponent(t.type || "")), {
|
|
400
|
+
...t,
|
|
401
|
+
component: e
|
|
402
|
+
};
|
|
403
|
+
})
|
|
404
|
+
);
|
|
411
405
|
}
|
|
412
406
|
render() {
|
|
413
407
|
var s;
|
|
414
|
-
return
|
|
408
|
+
return E(this.context, this.renderRoot.host), this.renderRoot.host.style.setProperty(
|
|
415
409
|
"--width",
|
|
416
410
|
this.layout.size === "full" ? "var(--columns, 1)" : `min(${this.layout.size || "var(--columns)"}, var(--columns))`
|
|
417
411
|
), this.renderRoot.host.style.setProperty(
|
|
418
412
|
"--columns",
|
|
419
413
|
((s = this._propertiesProvider.value.columns) == null ? void 0 : s.toString()) || "1"
|
|
420
|
-
),
|
|
414
|
+
), N(
|
|
421
415
|
this.renderRoot.host,
|
|
422
416
|
this._propertiesProvider.value
|
|
423
|
-
),
|
|
424
|
-
${
|
|
417
|
+
), v`
|
|
418
|
+
${it(
|
|
425
419
|
this._resolveAllChildren(this._childrenProvider.value).then(
|
|
426
|
-
(t) =>
|
|
420
|
+
(t) => v`
|
|
427
421
|
${t.map((e) => {
|
|
428
422
|
if (e.type === "area")
|
|
429
|
-
return
|
|
423
|
+
return v`<ace-area entry=${e.id}></ace-area>`;
|
|
430
424
|
const i = new e.component();
|
|
431
425
|
return i.entry = e.id, i;
|
|
432
426
|
})}
|
|
@@ -436,9 +430,9 @@ let C = class extends j {
|
|
|
436
430
|
`;
|
|
437
431
|
}
|
|
438
432
|
};
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
433
|
+
b.styles = [
|
|
434
|
+
O.styles || [],
|
|
435
|
+
R`
|
|
442
436
|
:host {
|
|
443
437
|
height: 100%;
|
|
444
438
|
display: grid;
|
|
@@ -449,16 +443,15 @@ C.styles = [
|
|
|
449
443
|
}
|
|
450
444
|
`
|
|
451
445
|
];
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
],
|
|
455
|
-
const
|
|
446
|
+
b = ot([
|
|
447
|
+
S("ace-area")
|
|
448
|
+
], b);
|
|
449
|
+
const lt = (s, t) => {
|
|
456
450
|
setTimeout(() => {
|
|
457
451
|
const e = new c();
|
|
458
452
|
e.container = s.parent, t.appendChild(e);
|
|
459
453
|
}, 0);
|
|
460
454
|
};
|
|
461
455
|
export {
|
|
462
|
-
|
|
456
|
+
lt as default
|
|
463
457
|
};
|
|
464
|
-
//# sourceMappingURL=render-416c8c88.js.map
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { Container } from '@webprovisions/platform';
|
|
2
|
-
export declare const createRoutingService: (container: Container) => Promise<any>;
|
|
3
2
|
export declare const createStorageService: (_container: Container) => Promise<import("@telia-ace/widget-services").StorageProvider>;
|
|
4
3
|
export declare const createActionResolver: (container: Container) => Promise<import("@telia-ace/widget-core").ActionResolver>;
|
|
5
4
|
export declare const createComponentResolver: (container: Container) => Promise<import("@telia-ace/widget-core").ComponentResolver>;
|
|
6
5
|
export declare const createComponentPlatform: (container: Container) => Promise<import("@telia-ace/widget-core").ComponentPlatform>;
|
|
7
|
-
//# sourceMappingURL=services.d.ts.map
|
package/{dist/ui → ui}/area.d.ts
RENAMED
|
@@ -12,4 +12,3 @@ export declare function createTriggerElement(element: HTMLElement, options: Trig
|
|
|
12
12
|
export declare function setInactive(elements: HTMLElement | HTMLElement[], title?: string): void;
|
|
13
13
|
export declare function setLoading(elements: HTMLElement | HTMLElement[]): void;
|
|
14
14
|
export declare function setActive(elements: HTMLElement | HTMLElement[], title?: string): void;
|
|
15
|
-
//# sourceMappingURL=html-element-handlers.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ViewOutletOptions } from './view-outlet';
|
|
2
|
+
import { Container } from '@webprovisions/platform';
|
|
2
3
|
declare enum ProvidedElements {
|
|
3
4
|
None = "none",
|
|
4
5
|
WidgetDOM = "widgetDOM",
|
|
@@ -16,6 +17,5 @@ export declare const determineTriggerType: (triggerDefinition?: any) => TriggerT
|
|
|
16
17
|
type PrepareDOMElementsOutput = ViewOutletOptions & {
|
|
17
18
|
callback?: () => void;
|
|
18
19
|
};
|
|
19
|
-
export declare const prepareDOMElements: (name: string, providedWidgetElement?: HTMLElement, providedTriggerElement?: HTMLElement, triggerDefinition?: any, waitWithReplace?: boolean) => Promise<PrepareDOMElementsOutput>;
|
|
20
|
+
export declare const prepareDOMElements: (container: Container, name: string, providedWidgetElement?: HTMLElement, providedTriggerElement?: HTMLElement, triggerDefinition?: any, waitWithReplace?: boolean) => Promise<PrepareDOMElementsOutput>;
|
|
20
21
|
export {};
|
|
21
|
-
//# sourceMappingURL=prepare-dom.d.ts.map
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Container } from '@webprovisions/platform';
|
|
1
2
|
import { LitElement, nothing } from 'lit';
|
|
2
3
|
type Symbol = {
|
|
3
4
|
type: 'Uri' | 'Svg' | 'FontAwesome' | 'Text' | string;
|
|
@@ -6,13 +7,14 @@ type Symbol = {
|
|
|
6
7
|
export declare class TriggerComponent extends LitElement {
|
|
7
8
|
static styles: import("lit").CSSResult[];
|
|
8
9
|
symbol?: Symbol;
|
|
10
|
+
container?: Container;
|
|
9
11
|
active: boolean;
|
|
10
12
|
loaded: boolean;
|
|
11
13
|
icon: any;
|
|
12
14
|
connectedCallback(): Promise<void>;
|
|
13
15
|
_toggleActive(): void;
|
|
14
|
-
|
|
16
|
+
_applyBranding(): void;
|
|
17
|
+
_renderSymbol(symbol?: Symbol): Promise<import("lit").TemplateResult<1> | typeof nothing>;
|
|
15
18
|
render(): import("lit").TemplateResult<1>;
|
|
16
19
|
}
|
|
17
20
|
export {};
|
|
18
|
-
//# sourceMappingURL=trigger-component.d.ts.map
|
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
import { Symbol } from '@telia-ace/widget-ui';
|
|
2
1
|
import { Container } from '@webprovisions/platform';
|
|
3
2
|
import { TriggerType } from './prepare-dom';
|
|
3
|
+
type Symbol = {
|
|
4
|
+
type: 'Uri' | 'Svg' | 'FontAwesome' | 'Text' | string;
|
|
5
|
+
content: string;
|
|
6
|
+
};
|
|
4
7
|
export type BadgeOptions = {
|
|
5
8
|
symbol?: Symbol;
|
|
6
9
|
label?: string;
|
|
@@ -30,4 +33,4 @@ export declare class ViewOutlet {
|
|
|
30
33
|
renderBadge(options: BadgeOptions): void;
|
|
31
34
|
dispose(): Promise<void>;
|
|
32
35
|
}
|
|
33
|
-
|
|
36
|
+
export {};
|