@telia-ace/widget-runtime-flamingo 1.0.10 → 1.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +0,0 @@
1
- {"version":3,"file":"node.mixin.d.ts","sourceRoot":"","sources":["../../src/mixins/node.mixin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AACjC,OAAO,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAExD,OAAO,EAAE,eAAe,EAAW,MAAM,mBAAmB,CAAC;AAC7D,OAAO,EACL,SAAS,EAEV,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EACL,mBAAmB,EAIpB,MAAM,wBAAwB,CAAC;AAGhC,KAAK,WAAW,CAAC,CAAC,GAAG,EAAE,IAAI,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;AAGrD,MAAM,CAAC,OAAO,OAAO,kBAAkB;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,mBAAmB,CAAC;IACjC,SAAS,CAAC,EAAE,GAAG,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC5B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC7B,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,gBAAgB,EAAE,eAAe,CAAC,OAAO,UAAU,CAAC,CAAC;IACrD,mBAAmB,EAAE,eAAe,CAAC,OAAO,aAAa,CAAC,CAAC;IAC3D,iBAAiB,EAAE,eAAe,CAAC,OAAO,eAAe,CAAC,CAAC;CAC5D;AAED,eAAO,MAAM,SAAS,2FA6IrB,CAAC"}
@@ -1,618 +0,0 @@
1
- var q = Object.defineProperty, W = Object.defineProperties;
2
- var Y = Object.getOwnPropertyDescriptors;
3
- var E = Object.getOwnPropertySymbols;
4
- var U = Object.prototype.hasOwnProperty, F = Object.prototype.propertyIsEnumerable;
5
- var z = (e, t, s) => t in e ? q(e, t, { enumerable: !0, configurable: !0, writable: !0, value: s }) : e[t] = s, f = (e, t) => {
6
- for (var s in t || (t = {}))
7
- U.call(t, s) && z(e, s, t[s]);
8
- if (E)
9
- for (var s of E(t))
10
- F.call(t, s) && z(e, s, t[s]);
11
- return e;
12
- }, D = (e, t) => W(e, Y(t));
13
- var y = (e, t, s) => new Promise((i, o) => {
14
- var r = (c) => {
15
- try {
16
- a(s.next(c));
17
- } catch (h) {
18
- o(h);
19
- }
20
- }, n = (c) => {
21
- try {
22
- a(s.throw(c));
23
- } catch (h) {
24
- o(h);
25
- }
26
- }, a = (c) => c.done ? i(c.value) : Promise.resolve(c.value).then(r, n);
27
- a((s = s.apply(e, t)).next());
28
- });
29
- import { s as Q, a as B, i as K, t as J, e as X, A as w, b as k, c as V, p as N, m as x, x as _, d as O, n as C, f as u, g as Z, h as tt, j as et, k as st, l as ot, E as G } from "./index-4d519c2d.js";
30
- /**
31
- * @license
32
- * Copyright 2017 Google LLC
33
- * SPDX-License-Identifier: BSD-3-Clause
34
- */
35
- const S = (e) => (t) => typeof t == "function" ? ((s, i) => (customElements.define(s, i), i))(e, t) : ((s, i) => {
36
- const { kind: o, elements: r } = i;
37
- return { kind: o, elements: r, finisher(n) {
38
- customElements.define(s, n);
39
- } };
40
- })(e, t);
41
- /**
42
- * @license
43
- * Copyright 2017 Google LLC
44
- * SPDX-License-Identifier: BSD-3-Clause
45
- */
46
- const it = ({ finisher: e, descriptor: t }) => (s, i) => {
47
- var o;
48
- if (i === void 0) {
49
- const r = (o = s.originalKey) !== null && o !== void 0 ? o : s.key, n = t != null ? { kind: "method", placement: "prototype", key: r, descriptor: t(s.key) } : D(f({}, s), { key: r });
50
- return e != null && (n.finisher = function(a) {
51
- e(a, r);
52
- }), n;
53
- }
54
- {
55
- const r = s.constructor;
56
- t !== void 0 && Object.defineProperty(s, i, t(i)), e == null || e(r, i);
57
- }
58
- };
59
- /**
60
- * @license
61
- * Copyright 2021 Google LLC
62
- * SPDX-License-Identifier: BSD-3-Clause
63
- */
64
- let rt = class {
65
- constructor(t) {
66
- this.subscriptions = /* @__PURE__ */ new Map(), this.updateObservers = () => {
67
- for (const [s, { disposer: i }] of this.subscriptions)
68
- s(this.o, i);
69
- }, t !== void 0 && (this.value = t);
70
- }
71
- get value() {
72
- return this.o;
73
- }
74
- set value(t) {
75
- this.setValue(t);
76
- }
77
- setValue(t, s = !1) {
78
- const i = s || !Object.is(t, this.o);
79
- this.o = t, i && this.updateObservers();
80
- }
81
- addCallback(t, s, i) {
82
- if (!i)
83
- return void t(this.value);
84
- this.subscriptions.has(t) || this.subscriptions.set(t, { disposer: () => {
85
- this.subscriptions.delete(t);
86
- }, consumerHost: s });
87
- const { disposer: o } = this.subscriptions.get(t);
88
- t(this.value, o);
89
- }
90
- clearCallbacks() {
91
- this.subscriptions.clear();
92
- }
93
- };
94
- /**
95
- * @license
96
- * Copyright 2021 Google LLC
97
- * SPDX-License-Identifier: BSD-3-Clause
98
- */
99
- class nt extends Event {
100
- constructor(t) {
101
- super("context-provider", { bubbles: !0, composed: !0 }), this.context = t;
102
- }
103
- }
104
- let g = class extends rt {
105
- constructor(t, s, i) {
106
- super(s.context !== void 0 ? s.initialValue : i), this.onContextRequest = (o) => {
107
- const r = o.composedPath()[0];
108
- o.context === this.context && r !== this.host && (o.stopPropagation(), this.addCallback(o.callback, r, o.subscribe));
109
- }, this.onProviderRequest = (o) => {
110
- const r = o.composedPath()[0];
111
- if (o.context === this.context && r !== this.host) {
112
- for (const [n, { consumerHost: a }] of this.subscriptions)
113
- a.dispatchEvent(new Q(this.context, n, !0));
114
- o.stopPropagation();
115
- }
116
- }, this.host = t, s.context !== void 0 ? this.context = s.context : this.context = s, this.attachListeners(), this.host.addController(this);
117
- }
118
- attachListeners() {
119
- this.host.addEventListener("context-request", this.onContextRequest), this.host.addEventListener("context-provider", this.onProviderRequest);
120
- }
121
- hostConnected() {
122
- this.host.dispatchEvent(new nt(this.context));
123
- }
124
- };
125
- /**
126
- * @license
127
- * Copyright 2022 Google LLC
128
- * SPDX-License-Identifier: BSD-3-Clause
129
- */
130
- function at({ context: e, subscribe: t }) {
131
- return it({ finisher: (s, i) => {
132
- s.addInitializer((o) => {
133
- new B(o, { context: e, callback: (r) => {
134
- o[i] = r;
135
- }, subscribe: t });
136
- });
137
- } });
138
- }
139
- /**
140
- * @license
141
- * Copyright 2020 Google LLC
142
- * SPDX-License-Identifier: BSD-3-Clause
143
- */
144
- const ct = (e) => e.strings === void 0;
145
- /**
146
- * @license
147
- * Copyright 2017 Google LLC
148
- * SPDX-License-Identifier: BSD-3-Clause
149
- */
150
- const m = (e, t) => {
151
- var s, i;
152
- const o = e._$AN;
153
- if (o === void 0)
154
- return !1;
155
- for (const r of o)
156
- (i = (s = r)._$AO) === null || i === void 0 || i.call(s, t, !1), m(r, t);
157
- return !0;
158
- }, $ = (e) => {
159
- let t, s;
160
- do {
161
- if ((t = e._$AM) === void 0)
162
- break;
163
- s = t._$AN, s.delete(e), e = t;
164
- } while ((s == null ? void 0 : s.size) === 0);
165
- }, M = (e) => {
166
- for (let t; t = e._$AM; e = t) {
167
- let s = t._$AN;
168
- if (s === void 0)
169
- t._$AN = s = /* @__PURE__ */ new Set();
170
- else if (s.has(e))
171
- break;
172
- s.add(e), dt(t);
173
- }
174
- };
175
- function ht(e) {
176
- this._$AN !== void 0 ? ($(this), this._$AM = e, M(this)) : this._$AM = e;
177
- }
178
- function lt(e, t = !1, s = 0) {
179
- const i = this._$AH, o = this._$AN;
180
- if (o !== void 0 && o.size !== 0)
181
- if (t)
182
- if (Array.isArray(i))
183
- for (let r = s; r < i.length; r++)
184
- m(i[r], !1), $(i[r]);
185
- else
186
- i != null && (m(i, !1), $(i));
187
- else
188
- m(this, e);
189
- }
190
- const dt = (e) => {
191
- var t, s, i, o;
192
- e.type == J.CHILD && ((t = (i = e)._$AP) !== null && t !== void 0 || (i._$AP = lt), (s = (o = e)._$AQ) !== null && s !== void 0 || (o._$AQ = ht));
193
- };
194
- class pt extends K {
195
- constructor() {
196
- super(...arguments), this._$AN = void 0;
197
- }
198
- _$AT(t, s, i) {
199
- super._$AT(t, s, i), M(this), this.isConnected = t._$AU;
200
- }
201
- _$AO(t, s = !0) {
202
- var i, o;
203
- t !== this.isConnected && (this.isConnected = t, t ? (i = this.reconnected) === null || i === void 0 || i.call(this) : (o = this.disconnected) === null || o === void 0 || o.call(this)), s && (m(this, t), $(this));
204
- }
205
- setValue(t) {
206
- if (ct(this._$Ct))
207
- this._$Ct._$AI(t, this);
208
- else {
209
- const s = [...this._$Ct._$AH];
210
- s[this._$Ci] = t, this._$Ct._$AI(s, this, 0);
211
- }
212
- }
213
- disconnected() {
214
- }
215
- reconnected() {
216
- }
217
- }
218
- /**
219
- * @license
220
- * Copyright 2020 Google LLC
221
- * SPDX-License-Identifier: BSD-3-Clause
222
- */
223
- const ut = () => new ft();
224
- class ft {
225
- }
226
- const P = /* @__PURE__ */ new WeakMap(), vt = X(class extends pt {
227
- render(e) {
228
- return w;
229
- }
230
- update(e, [t]) {
231
- var s;
232
- const i = t !== this.G;
233
- return i && this.G !== void 0 && this.ot(void 0), (i || this.rt !== this.lt) && (this.G = t, this.dt = (s = e.options) === null || s === void 0 ? void 0 : s.host, this.ot(this.lt = e.element)), w;
234
- }
235
- ot(e) {
236
- var t;
237
- if (typeof this.G == "function") {
238
- const s = (t = this.dt) !== null && t !== void 0 ? t : globalThis;
239
- let i = P.get(s);
240
- i === void 0 && (i = /* @__PURE__ */ new WeakMap(), P.set(s, i)), i.get(this.G) !== void 0 && this.G.call(this.dt, void 0), i.set(this.G, e), e !== void 0 && this.G.call(this.dt, e);
241
- } else
242
- this.G.value = e;
243
- }
244
- get rt() {
245
- var e, t, s;
246
- return typeof this.G == "function" ? (t = P.get((e = this.dt) !== null && e !== void 0 ? e : globalThis)) === null || t === void 0 ? void 0 : t.get(this.G) : (s = this.G) === null || s === void 0 ? void 0 : s.value;
247
- }
248
- disconnected() {
249
- this.rt === this.lt && this.ot(void 0);
250
- }
251
- reconnected() {
252
- this.ot(this.lt);
253
- }
254
- }), bt = (e) => y(void 0, null, function* () {
255
- return yield e.get("$widget").invoke("renderState");
256
- }), gt = (e, t) => y(void 0, null, function* () {
257
- const s = e.get("$widget");
258
- return (yield e.getAsync("actionResolver")).subscribe(s.name, t);
259
- }), mt = (e, t, s = !1) => {
260
- const i = e.reduce(
261
- (n, { breakpoints: a = [], values: c }) => a.length ? t.some((h) => a.includes(h)) ? f(f({}, n), c) : n : f(f({}, n), c),
262
- {}
263
- ), o = {};
264
- let r = i.type;
265
- return o.height = i.height || "", o.width = i.width || "", i.type === "floating" || i.type === "inline" && s && (o.height = "calc(100vh - 120px)"), { type: r, styles: o };
266
- };
267
- var yt = Object.defineProperty, xt = Object.getOwnPropertyDescriptor, v = (e, t, s, i) => {
268
- for (var o = i > 1 ? void 0 : i ? xt(t, s) : t, r = e.length - 1, n; r >= 0; r--)
269
- (n = e[r]) && (o = (i ? n(t, s, o) : n(o)) || o);
270
- return i && o && yt(t, s, o), o;
271
- };
272
- let p = class extends k {
273
- constructor() {
274
- super(), this._provider = new g(this, V, void 0), this.wrapperRef = ut(), this.breakpoints = [], this.breakpointsSet = !1;
275
- }
276
- connectedCallback() {
277
- super.connectedCallback(), this._provider.setValue(this.container), this.container && (bt(this.container).then((e) => {
278
- this.renderState = e;
279
- }), gt(this.container, (e, t) => {
280
- switch (t) {
281
- case "close":
282
- case "open":
283
- this.renderState = t === "open" ? x.open : x.closed;
284
- break;
285
- case "hide":
286
- this.renderState = x.hidden;
287
- }
288
- }).then((e) => {
289
- this._unsubscribeRenderState = e;
290
- }), N.getInstance(this.container).then(
291
- (e) => {
292
- this.componentPlatform = e, this.breakpoints = this.componentPlatform.breakpoints, this.breakpointsSet = !0, this._unsubscribePropChange = this.componentPlatform.events.subscribe(
293
- "components:properties-changed",
294
- (t, s) => {
295
- var i, o;
296
- ((i = s == null ? void 0 : s.node) == null ? void 0 : i.type) === "root" && (this.breakpoints = (o = this.componentPlatform) != null && o.breakpoints ? [...this.componentPlatform.breakpoints] : []);
297
- }
298
- ), this.entry = this.componentPlatform.nodes.root.children.default[0].id || void 0;
299
- }
300
- ));
301
- }
302
- disconnectedCallback() {
303
- super.disconnectedCallback(), this._unsubscribeRenderState && this._unsubscribeRenderState(), this._unsubscribePropChange && this._unsubscribePropChange();
304
- }
305
- render() {
306
- var t, s, i, o;
307
- let e;
308
- if (!this.entry || !this.breakpointsSet)
309
- return w;
310
- if (this.container && this.renderState) {
311
- const [r] = this.container.get("widgetDOMElements");
312
- r && r.setAttribute("data-state", this.renderState);
313
- }
314
- if (this.container) {
315
- const r = this.container.get("$settings");
316
- r != null && r.layout && (e = mt(
317
- r.layout,
318
- this.breakpoints,
319
- !!r.trigger
320
- ), e.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(e.styles).forEach(([n, a]) => {
321
- this.renderRoot.host.style.setProperty(n, a);
322
- }));
323
- }
324
- return this.renderState && (this.renderState === x.hidden ? ((t = this.wrapperRef.value) == null || t.classList.add("hidden"), (s = this.wrapperRef.value) == null || s.classList.remove("expanded")) : ((i = this.wrapperRef.value) == null || i.classList.remove("hidden"), (o = this.wrapperRef.value) == null || o.classList.add("expanded"))), _`
325
- <div class="widget-container" ${vt(this.wrapperRef)}>
326
- <ace-area entry=${this.entry}></ace-area>
327
- <!-- <widget-component entry=${this.entry}></widget-component> -->
328
- </div>
329
- `;
330
- }
331
- };
332
- p.styles = O`
333
- :host {
334
- --voca-rem-multiplier: 0.625;
335
- box-sizing: border-box;
336
- display: block;
337
- }
338
-
339
- :host(.floating) {
340
- position: fixed;
341
- z-index: 6;
342
- inset: auto 20px 95px auto;
343
- max-height: calc(100vh - 120px);
344
- }
345
- :host(.floating) .widget-container {
346
- box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
347
- border-radius: 0.7rem;
348
- }
349
- :host(.inline) {
350
- position: fixed;
351
- inset: 0 0 0 0;
352
- }
353
-
354
- * {
355
- box-sizing: border-box;
356
- }
357
- .widget-container.expanded {
358
- opacity: 1;
359
- animation: slideUp 0.5s;
360
- }
361
- .widget-container.hidden {
362
- opacity: 0;
363
- animation: slideDown 0.5s;
364
- }
365
- @keyframes slideDown {
366
- from {
367
- transform: translateY(0);
368
- opacity: 1;
369
- }
370
- to {
371
- transform: translateY(100%);
372
- opacity: 0;
373
- }
374
- }
375
- @keyframes slideUp {
376
- from {
377
- transform: translateY(100%);
378
- opacity: 0;
379
- }
380
- to {
381
- transform: translateY(0);
382
- opacity: 1;
383
- }
384
- }
385
- `;
386
- v([
387
- C({ attribute: !1 })
388
- ], p.prototype, "container", 2);
389
- v([
390
- u()
391
- ], p.prototype, "componentPlatform", 2);
392
- v([
393
- u()
394
- ], p.prototype, "renderState", 2);
395
- v([
396
- u()
397
- ], p.prototype, "breakpoints", 2);
398
- v([
399
- u()
400
- ], p.prototype, "breakpointsSet", 2);
401
- v([
402
- u()
403
- ], p.prototype, "entry", 2);
404
- p = v([
405
- S("wrapper-component")
406
- ], p);
407
- var _t = Object.defineProperty, wt = Object.getOwnPropertyDescriptor, b = (e, t, s, i) => {
408
- for (var o = i > 1 ? void 0 : i ? wt(t, s) : t, r = e.length - 1, n; r >= 0; r--)
409
- (n = e[r]) && (o = (i ? n(t, s, o) : n(o)) || o);
410
- return i && o && _t(t, s, o), o;
411
- };
412
- const H = (e) => {
413
- class t extends e {
414
- constructor() {
415
- super(...arguments), this.entry = "", this._descriptorProvider = new g(
416
- this,
417
- Z,
418
- void 0
419
- ), this._childrenProvider = new g(this, tt, []), this._propertiesProvider = new g(this, et, {}), this._contextProvider = new g(this, st, {}), this._layoutProvider = new g(this, ot, {}), this.context = {}, this.layout = {};
420
- }
421
- connectedCallback() {
422
- super.connectedCallback(), this.container && N.getInstance(this.container).then(
423
- (i) => y(this, null, function* () {
424
- const o = i.nodes.get(this.entry);
425
- if (o) {
426
- this._propertyChangeListener = i.events.subscribe(
427
- "components:properties-changed",
428
- (h, l) => {
429
- o.id === l.node.id && this._propertiesProvider.setValue(
430
- l.node.attributes.properties
431
- );
432
- }
433
- ), this._contextChangeListener = i.events.subscribe(
434
- "components:context-changed",
435
- (h, l) => {
436
- console.log("context changed!", l), o.id === l.node.id && (this._contextProvider.setValue(
437
- l.node.attributes.context
438
- ), this.context = f({}, l.node.attributes.context));
439
- }
440
- ), this._layoutChangeListener = i.events.subscribe(
441
- "components:layout-changed",
442
- (h, l) => {
443
- console.log("layout changed!", l), o.id === l.node.id && (this._layoutProvider.setValue(l.node.attributes.layout), this.layout = f({}, l.node.attributes.layout));
444
- }
445
- );
446
- const r = "default";
447
- this.descriptor = G(o, r), this._unmountNode = o.mount(this.container), this._descriptorProvider.setValue(this.descriptor), this._propertiesProvider.setValue(
448
- o.attributes.properties
449
- ), this._contextProvider.setValue(o.attributes.context), this.context = o.attributes.context, this.layout = o.attributes.layout, this._layoutProvider.setValue(this.layout);
450
- const n = o.getChildren(r).map((h) => G(h));
451
- this._childrenProvider.setValue(n);
452
- const c = (yield this.container.getAsync("componentResolver")).getComponent(
453
- this.descriptor.type || ""
454
- );
455
- c.then && c.then((h) => {
456
- this.component = h.default;
457
- });
458
- }
459
- })
460
- );
461
- }
462
- disconnectedCallback() {
463
- super.disconnectedCallback(), this._propertyChangeListener && this._propertyChangeListener(), this._contextChangeListener && this._contextChangeListener(), this._layoutChangeListener && this._layoutChangeListener(), this._unmountNode && this._unmountNode();
464
- }
465
- }
466
- return b([
467
- at({ context: V }),
468
- C({ attribute: !1 })
469
- ], t.prototype, "container", 2), b([
470
- C()
471
- ], t.prototype, "entry", 2), b([
472
- u()
473
- ], t.prototype, "descriptor", 2), b([
474
- u()
475
- ], t.prototype, "component", 2), b([
476
- u()
477
- ], t.prototype, "context", 2), b([
478
- u()
479
- ], t.prototype, "layout", 2), t;
480
- }, d = (e, t, s) => {
481
- e && s.style.setProperty(t, e);
482
- }, T = (e, t) => {
483
- var s, i, o, r, n, a, c, h, l, L, j;
484
- console.log("Map branding", e, t), d((s = e.colors) == null ? void 0 : s.primary, "--primary-color", t), d((i = e.colors) == null ? void 0 : i.secondary, "--secondary-color", t), d((o = e.colors) == null ? void 0 : o.text, "--text-color", t), d((r = e.colors) == null ? void 0 : r.link, "--link-color", t), d((n = e.colors) == null ? void 0 : n.gray, "--gray-color", t), d((a = e.colors) == null ? void 0 : a.grayDark, "--gray-dark-color", t), d((c = e.spacing) == null ? void 0 : c.xs, "--spacing-xs", t), d((h = e.spacing) == null ? void 0 : h.sm, "--spacing-sm", t), d((l = e.spacing) == null ? void 0 : l.md, "--spacing-md", t), d((L = e.spacing) == null ? void 0 : L.lg, "--spacing-lg", t), d((j = e.spacing) == null ? void 0 : j.xl, "--spacing-xl", t), d(e.boxShadow, "--box-shadow", t), d(e.borderRadius, "--border-radius", t), d(e.borderRadiusSm, "--border-radius-sm", t), d(e.fontFamily, "--font-family", t);
485
- }, $t = (e) => {
486
- const t = {};
487
- return Object.keys(e).forEach((s) => {
488
- s.indexOf("css-") > -1 && (t[s] = e[s]);
489
- }), t;
490
- }, I = (e, t) => {
491
- const s = $t(t);
492
- Object.entries(s).forEach(([i, o]) => {
493
- e.style.setProperty(i.replace("css-", ""), o);
494
- });
495
- };
496
- var Pt = Object.defineProperty, Ct = Object.getOwnPropertyDescriptor, At = (e, t, s, i) => {
497
- for (var o = i > 1 ? void 0 : i ? Ct(t, s) : t, r = e.length - 1, n; r >= 0; r--)
498
- (n = e[r]) && (o = (i ? n(t, s, o) : n(o)) || o);
499
- return i && o && Pt(t, s, o), o;
500
- };
501
- let A = class extends H(k) {
502
- render() {
503
- if (!this.component)
504
- return w;
505
- const e = new this.component(), t = this._contextProvider.value;
506
- return T(t, this.renderRoot.host), this.renderRoot.host.style.setProperty(
507
- "--width",
508
- this.layout.size === "full" ? "var(--columns, 1)" : `min(${this.layout.size || "var(--columns)"}, var(--columns))`
509
- ), I(
510
- this.renderRoot.host,
511
- this._propertiesProvider.value
512
- ), e;
513
- }
514
- };
515
- A.styles = O`
516
- :host {
517
- grid-column: span var(--width);
518
- max-width: 100%;
519
- overflow: hidden;
520
- box-sizing: border-box;
521
- display: block;
522
-
523
- --font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
524
- --spacing-xs: 0.2rem;
525
- --spacing-sm: 0.5rem;
526
- --spacing-md: 1rem;
527
- --spacing-lg: 1.2rem;
528
- --spacing-xl: 1.8rem;
529
-
530
- --primary-color: #29003e;
531
- --secondary-color: #00558f;
532
- --text-color: #222222;
533
- --link-color: #990ae3;
534
- --gray-color: #efefef;
535
- --gray-dark-color: #a6a6a6;
536
-
537
- --box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
538
- --border-radius: 1rem;
539
- --border-radius-sm: 0.3rem;
540
- }
541
- * {
542
- box-sizing: border-box;
543
- }
544
- `;
545
- A = At([
546
- S("widget-component")
547
- ], A);
548
- var Rt = Object.defineProperty, kt = Object.getOwnPropertyDescriptor, Ot = (e, t, s, i) => {
549
- for (var o = i > 1 ? void 0 : i ? kt(t, s) : t, r = e.length - 1, n; r >= 0; r--)
550
- (n = e[r]) && (o = (i ? n(t, s, o) : n(o)) || o);
551
- return i && o && Rt(t, s, o), o;
552
- };
553
- let R = class extends H(k) {
554
- render() {
555
- var e, t;
556
- return ((e = this.descriptor) == null ? void 0 : e.name) === "root-area" && console.log("AREA:render:", this.context), T(this.context, this.renderRoot.host), this.renderRoot.host.style.setProperty(
557
- "--width",
558
- this.layout.size === "full" ? "var(--columns, 1)" : `min(${this.layout.size || "var(--columns)"}, var(--columns))`
559
- ), this.renderRoot.host.style.setProperty(
560
- "--columns",
561
- ((t = this._propertiesProvider.value.columns) == null ? void 0 : t.toString()) || "1"
562
- ), I(
563
- this.renderRoot.host,
564
- this._propertiesProvider.value
565
- ), _`
566
- ${this._childrenProvider.value.map(
567
- (s) => s.type === "area" ? _`<ace-area entry=${s.id}></ace-area>` : _`<widget-component entry=${s.id}></widget-component>`
568
- )}
569
- `;
570
- }
571
- };
572
- R.styles = O`
573
- :host {
574
- grid-column: span var(--width);
575
- max-width: 100%;
576
- overflow: hidden;
577
- box-sizing: border-box;
578
-
579
- height: 100%;
580
- display: grid;
581
- justify-content: center;
582
- grid-auto-rows: max-content;
583
- grid-template-rows: auto;
584
- grid-template-columns: repeat(var(--columns), 1fr);
585
-
586
- --font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
587
- --spacing-xs: 0.2rem;
588
- --spacing-sm: 0.5rem;
589
- --spacing-md: 1rem;
590
- --spacing-lg: 1.2rem;
591
- --spacing-xl: 1.8rem;
592
-
593
- --primary-color: #29003e;
594
- --secondary-color: #00558f;
595
- --text-color: #222222;
596
- --link-color: #990ae3;
597
- --gray-color: #efefef;
598
- --gray-dark-color: #a6a6a6;
599
-
600
- --box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
601
- --border-radius: 1rem;
602
- --border-radius-sm: 0.3rem;
603
- }
604
- * {
605
- box-sizing: border-box;
606
- }
607
- `;
608
- R = Ot([
609
- S("ace-area")
610
- ], R);
611
- const zt = (e, t) => {
612
- const s = new p();
613
- s.container = e, t.appendChild(s);
614
- };
615
- export {
616
- zt as default
617
- };
618
- //# sourceMappingURL=render-6c71b694.js.map