@everymatrix/casino-engagement-suite-tournament 1.56.0 → 1.56.2
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/casino-engagement-suite-tournament/casino-engagement-suite-tournament.esm.js +1 -1
- package/dist/casino-engagement-suite-tournament/index.esm.js +1 -1
- package/dist/casino-engagement-suite-tournament/p-36511cf5.js +15 -0
- package/dist/casino-engagement-suite-tournament/{p-69ef97d1.entry.js → p-6e87f006.entry.js} +1 -1
- package/dist/casino-engagement-suite-tournament/p-7dd52ef4.js +2 -0
- package/dist/cjs/casino-engagement-suite-progress-bar_3.cjs.entry.js +13 -39
- package/dist/cjs/{casino-engagement-suite-tournament-19a1c3b7.js → casino-engagement-suite-tournament-dea6117d.js} +12 -31
- package/dist/cjs/casino-engagement-suite-tournament.cjs.js +2 -2
- package/dist/cjs/{index-79c59362.js → index-9b5a5304.js} +136 -287
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/casino-engagement-suite-tournament/casino-engagement-suite-tournament.js +4 -35
- package/dist/esm/casino-engagement-suite-progress-bar_3.entry.js +13 -39
- package/dist/esm/{casino-engagement-suite-tournament-f2131da2.js → casino-engagement-suite-tournament-520e74da.js} +12 -31
- package/dist/esm/casino-engagement-suite-tournament.js +3 -3
- package/dist/esm/{index-bc18616b.js → index-e8e1e68e.js} +136 -287
- package/dist/esm/index.js +2 -2
- package/dist/esm/loader.js +2 -2
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/packages/stencil/casino-engagement-suite-tournament/stencil.config.d.ts +2 -0
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/packages/stencil/casino-engagement-suite-tournament/stencil.config.dev.d.ts +2 -0
- package/dist/types/components/casino-engagement-suite-tournament/casino-engagement-suite-tournament.d.ts +7 -2
- package/dist/types/stencil-public-runtime.d.ts +0 -6
- package/dist/types/utils/api.apdater.d.ts +30 -2
- package/package.json +1 -1
- package/dist/casino-engagement-suite-tournament/p-00972ad5.js +0 -2
- package/dist/casino-engagement-suite-tournament/p-c1d0b870.js +0 -1
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/packages/stencil/casino-engagement-suite-tournament/stencil.config.d.ts +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/packages/stencil/casino-engagement-suite-tournament/stencil.config.dev.d.ts +0 -2
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/tools/plugins/vite-chunk-plugin.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-tournament/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
|
@@ -1,21 +1,17 @@
|
|
|
1
1
|
const NAMESPACE = 'casino-engagement-suite-tournament';
|
|
2
|
-
const BUILD = /* casino-engagement-suite-tournament */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false,
|
|
2
|
+
const BUILD = /* casino-engagement-suite-tournament */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: true, watchCallback: true };
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
|
-
Stencil Client Platform v4.
|
|
5
|
+
Stencil Client Platform v4.19.2 | MIT Licensed | https://stenciljs.com
|
|
6
6
|
*/
|
|
7
7
|
var __defProp = Object.defineProperty;
|
|
8
8
|
var __export = (target, all) => {
|
|
9
9
|
for (var name in all)
|
|
10
10
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
11
|
};
|
|
12
|
-
|
|
13
|
-
// src/client/client-host-ref.ts
|
|
14
12
|
var hostRefs = /* @__PURE__ */ new WeakMap();
|
|
15
13
|
var getHostRef = (ref) => hostRefs.get(ref);
|
|
16
|
-
var registerInstance = (lazyInstance, hostRef) =>
|
|
17
|
-
hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
18
|
-
};
|
|
14
|
+
var registerInstance = (lazyInstance, hostRef) => hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
19
15
|
var registerHost = (hostElement, cmpMeta) => {
|
|
20
16
|
const hostRef = {
|
|
21
17
|
$flags$: 0,
|
|
@@ -28,8 +24,7 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
|
28
24
|
hostElement["s-p"] = [];
|
|
29
25
|
hostElement["s-rc"] = [];
|
|
30
26
|
}
|
|
31
|
-
|
|
32
|
-
return ref;
|
|
27
|
+
return hostRefs.set(hostElement, hostRef);
|
|
33
28
|
};
|
|
34
29
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
|
35
30
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
|
@@ -66,22 +61,16 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
66
61
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
67
62
|
/* webpackMode: "lazy" */
|
|
68
63
|
`./${bundleId}.entry.js${""}`
|
|
69
|
-
).then(
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
cmpModules.set(bundleId, importedModule);
|
|
73
|
-
}
|
|
74
|
-
return importedModule[exportName];
|
|
75
|
-
},
|
|
76
|
-
(e) => {
|
|
77
|
-
consoleError(e, hostRef.$hostElement$);
|
|
64
|
+
).then((importedModule) => {
|
|
65
|
+
{
|
|
66
|
+
cmpModules.set(bundleId, importedModule);
|
|
78
67
|
}
|
|
79
|
-
|
|
68
|
+
return importedModule[exportName];
|
|
69
|
+
}, consoleError);
|
|
80
70
|
};
|
|
81
71
|
|
|
82
72
|
// src/client/client-style.ts
|
|
83
73
|
var styles = /* @__PURE__ */ new Map();
|
|
84
|
-
var HYDRATED_STYLE_ID = "sty-id";
|
|
85
74
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
86
75
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
87
76
|
var XLINK_NS = "http://www.w3.org/1999/xlink";
|
|
@@ -156,6 +145,12 @@ var flush = () => {
|
|
|
156
145
|
};
|
|
157
146
|
var nextTick = (cb) => promiseResolve().then(cb);
|
|
158
147
|
var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
|
|
148
|
+
|
|
149
|
+
// src/utils/constants.ts
|
|
150
|
+
var EMPTY_OBJ = {};
|
|
151
|
+
|
|
152
|
+
// src/utils/helpers.ts
|
|
153
|
+
var isDef = (v) => v != null;
|
|
159
154
|
var isComplexType = (o) => {
|
|
160
155
|
o = typeof o;
|
|
161
156
|
return o === "object" || o === "function";
|
|
@@ -215,63 +210,6 @@ var unwrapErr = (result) => {
|
|
|
215
210
|
throw result.value;
|
|
216
211
|
}
|
|
217
212
|
};
|
|
218
|
-
var updateFallbackSlotVisibility = (elm) => {
|
|
219
|
-
const childNodes = elm.__childNodes || elm.childNodes;
|
|
220
|
-
if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
|
|
221
|
-
getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
|
|
222
|
-
var _a;
|
|
223
|
-
if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
|
|
224
|
-
if ((_a = getHostSlotChildNodes(slotNode, slotNode["s-sn"], false)) == null ? void 0 : _a.length) {
|
|
225
|
-
slotNode.hidden = true;
|
|
226
|
-
} else {
|
|
227
|
-
slotNode.hidden = false;
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
});
|
|
231
|
-
}
|
|
232
|
-
for (const childNode of childNodes) {
|
|
233
|
-
if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {
|
|
234
|
-
updateFallbackSlotVisibility(childNode);
|
|
235
|
-
}
|
|
236
|
-
}
|
|
237
|
-
};
|
|
238
|
-
function getHostSlotNodes(childNodes, hostName, slotName) {
|
|
239
|
-
let i2 = 0;
|
|
240
|
-
let slottedNodes = [];
|
|
241
|
-
let childNode;
|
|
242
|
-
for (; i2 < childNodes.length; i2++) {
|
|
243
|
-
childNode = childNodes[i2];
|
|
244
|
-
if (childNode["s-sr"] && childNode["s-hn"] === hostName && (slotName === void 0 || childNode["s-sn"] === slotName)) {
|
|
245
|
-
slottedNodes.push(childNode);
|
|
246
|
-
if (typeof slotName !== "undefined") return slottedNodes;
|
|
247
|
-
}
|
|
248
|
-
slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
|
|
249
|
-
}
|
|
250
|
-
return slottedNodes;
|
|
251
|
-
}
|
|
252
|
-
var getHostSlotChildNodes = (node, slotName, includeSlot = true) => {
|
|
253
|
-
const childNodes = [];
|
|
254
|
-
if (includeSlot && node["s-sr"] || !node["s-sr"]) childNodes.push(node);
|
|
255
|
-
while ((node = node.nextSibling) && node["s-sn"] === slotName) {
|
|
256
|
-
childNodes.push(node);
|
|
257
|
-
}
|
|
258
|
-
return childNodes;
|
|
259
|
-
};
|
|
260
|
-
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
261
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
262
|
-
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
263
|
-
return true;
|
|
264
|
-
}
|
|
265
|
-
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
266
|
-
return true;
|
|
267
|
-
}
|
|
268
|
-
return false;
|
|
269
|
-
}
|
|
270
|
-
if (nodeToRelocate["s-sn"] === slotName) {
|
|
271
|
-
return true;
|
|
272
|
-
}
|
|
273
|
-
return slotName === "";
|
|
274
|
-
};
|
|
275
213
|
var createTime = (fnName, tagName = "") => {
|
|
276
214
|
{
|
|
277
215
|
return () => {
|
|
@@ -426,40 +364,13 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
426
364
|
}
|
|
427
365
|
if (!appliedStyles.has(scopeId2)) {
|
|
428
366
|
{
|
|
429
|
-
styleElm =
|
|
367
|
+
styleElm = doc.createElement("style");
|
|
430
368
|
styleElm.innerHTML = style;
|
|
431
369
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
|
432
370
|
if (nonce != null) {
|
|
433
371
|
styleElm.setAttribute("nonce", nonce);
|
|
434
372
|
}
|
|
435
|
-
|
|
436
|
-
if (styleContainerNode.nodeName === "HEAD") {
|
|
437
|
-
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
438
|
-
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
439
|
-
styleContainerNode.insertBefore(
|
|
440
|
-
styleElm,
|
|
441
|
-
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
442
|
-
);
|
|
443
|
-
} else if ("host" in styleContainerNode) {
|
|
444
|
-
if (supportsConstructableStylesheets) {
|
|
445
|
-
const stylesheet = new CSSStyleSheet();
|
|
446
|
-
stylesheet.replaceSync(style);
|
|
447
|
-
styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];
|
|
448
|
-
} else {
|
|
449
|
-
const existingStyleContainer = styleContainerNode.querySelector("style");
|
|
450
|
-
if (existingStyleContainer) {
|
|
451
|
-
existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
|
|
452
|
-
} else {
|
|
453
|
-
styleContainerNode.prepend(styleElm);
|
|
454
|
-
}
|
|
455
|
-
}
|
|
456
|
-
} else {
|
|
457
|
-
styleContainerNode.append(styleElm);
|
|
458
|
-
}
|
|
459
|
-
}
|
|
460
|
-
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
461
|
-
styleContainerNode.insertBefore(styleElm, null);
|
|
462
|
-
}
|
|
373
|
+
styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector("link"));
|
|
463
374
|
}
|
|
464
375
|
if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
|
|
465
376
|
styleElm.innerHTML += SLOT_FB_CSS;
|
|
@@ -482,25 +393,23 @@ var attachStyles = (hostRef) => {
|
|
|
482
393
|
const scopeId2 = addStyle(
|
|
483
394
|
elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(),
|
|
484
395
|
cmpMeta);
|
|
485
|
-
if (
|
|
396
|
+
if (flags & 10 /* needsScopedEncapsulation */) {
|
|
486
397
|
elm["s-sc"] = scopeId2;
|
|
487
398
|
elm.classList.add(scopeId2 + "-h");
|
|
488
399
|
}
|
|
489
400
|
endAttachStyles();
|
|
490
401
|
};
|
|
491
402
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
492
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags
|
|
403
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
493
404
|
if (oldValue !== newValue) {
|
|
494
405
|
let isProp = isMemberInElement(elm, memberName);
|
|
495
406
|
let ln = memberName.toLowerCase();
|
|
496
407
|
if (memberName === "class") {
|
|
497
408
|
const classList = elm.classList;
|
|
498
409
|
const oldClasses = parseClassList(oldValue);
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
503
|
-
}
|
|
410
|
+
const newClasses = parseClassList(newValue);
|
|
411
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
412
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
504
413
|
} else if (memberName === "style") {
|
|
505
414
|
{
|
|
506
415
|
for (const prop in oldValue) {
|
|
@@ -553,13 +462,9 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
553
462
|
if (memberName === "list") {
|
|
554
463
|
isProp = false;
|
|
555
464
|
} else if (oldValue == null || elm[memberName] != n) {
|
|
556
|
-
|
|
557
|
-
elm[memberName] = n;
|
|
558
|
-
} else {
|
|
559
|
-
elm.setAttribute(memberName, n);
|
|
560
|
-
}
|
|
465
|
+
elm[memberName] = n;
|
|
561
466
|
}
|
|
562
|
-
} else
|
|
467
|
+
} else {
|
|
563
468
|
elm[memberName] = newValue;
|
|
564
469
|
}
|
|
565
470
|
} catch (e) {
|
|
@@ -592,44 +497,24 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
592
497
|
}
|
|
593
498
|
};
|
|
594
499
|
var parseClassListRegex = /\s/;
|
|
595
|
-
var parseClassList = (value) =>
|
|
596
|
-
if (typeof value === "object" && value && "baseVal" in value) {
|
|
597
|
-
value = value.baseVal;
|
|
598
|
-
}
|
|
599
|
-
if (!value || typeof value !== "string") {
|
|
600
|
-
return [];
|
|
601
|
-
}
|
|
602
|
-
return value.split(parseClassListRegex);
|
|
603
|
-
};
|
|
500
|
+
var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
|
|
604
501
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
605
502
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
606
503
|
|
|
607
504
|
// src/runtime/vdom/update-element.ts
|
|
608
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2
|
|
505
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
609
506
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
610
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
611
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
507
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
|
|
508
|
+
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
|
612
509
|
{
|
|
613
510
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
614
511
|
if (!(memberName in newVnodeAttrs)) {
|
|
615
|
-
setAccessor(
|
|
616
|
-
elm,
|
|
617
|
-
memberName,
|
|
618
|
-
oldVnodeAttrs[memberName],
|
|
619
|
-
void 0,
|
|
620
|
-
isSvgMode2,
|
|
621
|
-
newVnode.$flags$);
|
|
512
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
|
|
622
513
|
}
|
|
623
514
|
}
|
|
624
515
|
}
|
|
625
516
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
626
|
-
setAccessor(
|
|
627
|
-
elm,
|
|
628
|
-
memberName,
|
|
629
|
-
oldVnodeAttrs[memberName],
|
|
630
|
-
newVnodeAttrs[memberName],
|
|
631
|
-
isSvgMode2,
|
|
632
|
-
newVnode.$flags$);
|
|
517
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
|
|
633
518
|
}
|
|
634
519
|
};
|
|
635
520
|
function sortedAttrNames(attrNames) {
|
|
@@ -641,13 +526,16 @@ function sortedAttrNames(attrNames) {
|
|
|
641
526
|
attrNames
|
|
642
527
|
);
|
|
643
528
|
}
|
|
529
|
+
|
|
530
|
+
// src/runtime/vdom/vdom-render.ts
|
|
531
|
+
var scopeId;
|
|
644
532
|
var contentRef;
|
|
645
533
|
var hostTagName;
|
|
646
534
|
var useNativeShadowDom = false;
|
|
647
535
|
var checkSlotFallbackVisibility = false;
|
|
648
536
|
var checkSlotRelocate = false;
|
|
649
537
|
var isSvgMode = false;
|
|
650
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
538
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
651
539
|
var _a;
|
|
652
540
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
653
541
|
let i2 = 0;
|
|
@@ -657,6 +545,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
657
545
|
if (!useNativeShadowDom) {
|
|
658
546
|
checkSlotRelocate = true;
|
|
659
547
|
if (newVNode2.$tag$ === "slot") {
|
|
548
|
+
if (scopeId) {
|
|
549
|
+
parentElm.classList.add(scopeId + "-s");
|
|
550
|
+
}
|
|
660
551
|
newVNode2.$flags$ |= newVNode2.$children$ ? (
|
|
661
552
|
// slot element has fallback content
|
|
662
553
|
// still create an element that "mocks" the slot element
|
|
@@ -680,9 +571,12 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
680
571
|
{
|
|
681
572
|
updateElement(null, newVNode2, isSvgMode);
|
|
682
573
|
}
|
|
574
|
+
if (isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
575
|
+
elm.classList.add(elm["s-si"] = scopeId);
|
|
576
|
+
}
|
|
683
577
|
if (newVNode2.$children$) {
|
|
684
578
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
685
|
-
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
579
|
+
childNode = createElm(oldParentVNode, newVNode2, i2, elm);
|
|
686
580
|
if (childNode) {
|
|
687
581
|
elm.appendChild(childNode);
|
|
688
582
|
}
|
|
@@ -708,7 +602,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
708
602
|
};
|
|
709
603
|
var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
710
604
|
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
711
|
-
const oldSlotChildNodes = Array.from(parentElm.
|
|
605
|
+
const oldSlotChildNodes = Array.from(parentElm.childNodes);
|
|
712
606
|
if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
|
|
713
607
|
let node = parentElm;
|
|
714
608
|
while (node = node.nextSibling) {
|
|
@@ -720,7 +614,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
|
720
614
|
for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
|
|
721
615
|
const childNode = oldSlotChildNodes[i2];
|
|
722
616
|
if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
|
|
723
|
-
insertBefore(
|
|
617
|
+
insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));
|
|
724
618
|
childNode["s-ol"].remove();
|
|
725
619
|
childNode["s-ol"] = void 0;
|
|
726
620
|
childNode["s-sh"] = void 0;
|
|
@@ -740,7 +634,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
|
740
634
|
}
|
|
741
635
|
for (; startIdx <= endIdx; ++startIdx) {
|
|
742
636
|
if (vnodes[startIdx]) {
|
|
743
|
-
childNode = createElm(null, parentVNode, startIdx);
|
|
637
|
+
childNode = createElm(null, parentVNode, startIdx, parentElm);
|
|
744
638
|
if (childNode) {
|
|
745
639
|
vnodes[startIdx].$elm$ = childNode;
|
|
746
640
|
insertBefore(containerElm, childNode, referenceNode(before) );
|
|
@@ -827,7 +721,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
827
721
|
if (idxInOld >= 0) {
|
|
828
722
|
elmToMove = oldCh[idxInOld];
|
|
829
723
|
if (elmToMove.$tag$ !== newStartVnode.$tag$) {
|
|
830
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
|
|
724
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld, parentElm);
|
|
831
725
|
} else {
|
|
832
726
|
patch(elmToMove, newStartVnode, isInitialRender);
|
|
833
727
|
oldCh[idxInOld] = void 0;
|
|
@@ -835,16 +729,12 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
835
729
|
}
|
|
836
730
|
newStartVnode = newCh[++newStartIdx];
|
|
837
731
|
} else {
|
|
838
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
|
|
732
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx, parentElm);
|
|
839
733
|
newStartVnode = newCh[++newStartIdx];
|
|
840
734
|
}
|
|
841
735
|
if (node) {
|
|
842
736
|
{
|
|
843
|
-
insertBefore(
|
|
844
|
-
referenceNode(oldStartVnode.$elm$).parentNode,
|
|
845
|
-
node,
|
|
846
|
-
referenceNode(oldStartVnode.$elm$)
|
|
847
|
-
);
|
|
737
|
+
insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));
|
|
848
738
|
}
|
|
849
739
|
}
|
|
850
740
|
}
|
|
@@ -870,14 +760,14 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
870
760
|
if (!isInitialRender) {
|
|
871
761
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
872
762
|
}
|
|
873
|
-
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
874
|
-
leftVNode.$key$ = rightVNode.$key$;
|
|
875
|
-
}
|
|
876
763
|
return true;
|
|
877
764
|
}
|
|
878
765
|
return false;
|
|
879
766
|
};
|
|
880
|
-
var referenceNode = (node) =>
|
|
767
|
+
var referenceNode = (node) => {
|
|
768
|
+
return node && node["s-ol"] || node;
|
|
769
|
+
};
|
|
770
|
+
var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
|
|
881
771
|
var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
882
772
|
const elm = newVNode2.$elm$ = oldVNode.$elm$;
|
|
883
773
|
const oldChildren = oldVNode.$children$;
|
|
@@ -898,10 +788,7 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
898
788
|
elm.textContent = "";
|
|
899
789
|
}
|
|
900
790
|
addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);
|
|
901
|
-
} else if (
|
|
902
|
-
// don't do this on initial render as it can cause non-hydrated content to be removed
|
|
903
|
-
!isInitialRender && BUILD.updatable && oldChildren !== null
|
|
904
|
-
) {
|
|
791
|
+
} else if (oldChildren !== null) {
|
|
905
792
|
removeVnodes(oldChildren, 0, oldChildren.length - 1);
|
|
906
793
|
}
|
|
907
794
|
} else if ((defaultHolder = elm["s-cr"])) {
|
|
@@ -910,15 +797,41 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
910
797
|
elm.data = text;
|
|
911
798
|
}
|
|
912
799
|
};
|
|
800
|
+
var updateFallbackSlotVisibility = (elm) => {
|
|
801
|
+
const childNodes = elm.childNodes;
|
|
802
|
+
for (const childNode of childNodes) {
|
|
803
|
+
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
804
|
+
if (childNode["s-sr"]) {
|
|
805
|
+
const slotName = childNode["s-sn"];
|
|
806
|
+
childNode.hidden = false;
|
|
807
|
+
for (const siblingNode of childNodes) {
|
|
808
|
+
if (siblingNode !== childNode) {
|
|
809
|
+
if (siblingNode["s-hn"] !== childNode["s-hn"] || slotName !== "") {
|
|
810
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute("slot") || slotName === siblingNode["s-sn"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode["s-sn"]) {
|
|
811
|
+
childNode.hidden = true;
|
|
812
|
+
break;
|
|
813
|
+
}
|
|
814
|
+
} else {
|
|
815
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== "") {
|
|
816
|
+
childNode.hidden = true;
|
|
817
|
+
break;
|
|
818
|
+
}
|
|
819
|
+
}
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
}
|
|
823
|
+
updateFallbackSlotVisibility(childNode);
|
|
824
|
+
}
|
|
825
|
+
}
|
|
826
|
+
};
|
|
913
827
|
var relocateNodes = [];
|
|
914
828
|
var markSlotContentForRelocation = (elm) => {
|
|
915
829
|
let node;
|
|
916
830
|
let hostContentNodes;
|
|
917
831
|
let j;
|
|
918
|
-
const
|
|
919
|
-
for (const childNode of children) {
|
|
832
|
+
for (const childNode of elm.childNodes) {
|
|
920
833
|
if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
|
|
921
|
-
hostContentNodes = node.parentNode.
|
|
834
|
+
hostContentNodes = node.parentNode.childNodes;
|
|
922
835
|
const slotName = childNode["s-sn"];
|
|
923
836
|
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
|
924
837
|
node = hostContentNodes[j];
|
|
@@ -960,6 +873,21 @@ var markSlotContentForRelocation = (elm) => {
|
|
|
960
873
|
}
|
|
961
874
|
}
|
|
962
875
|
};
|
|
876
|
+
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
877
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
878
|
+
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
879
|
+
return true;
|
|
880
|
+
}
|
|
881
|
+
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
882
|
+
return true;
|
|
883
|
+
}
|
|
884
|
+
return false;
|
|
885
|
+
}
|
|
886
|
+
if (nodeToRelocate["s-sn"] === slotName) {
|
|
887
|
+
return true;
|
|
888
|
+
}
|
|
889
|
+
return slotName === "";
|
|
890
|
+
};
|
|
963
891
|
var nullifyVNodeRefs = (vNode) => {
|
|
964
892
|
{
|
|
965
893
|
vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
|
|
@@ -967,9 +895,8 @@ var nullifyVNodeRefs = (vNode) => {
|
|
|
967
895
|
}
|
|
968
896
|
};
|
|
969
897
|
var insertBefore = (parent, newNode, reference) => {
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
}
|
|
898
|
+
const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
899
|
+
return inserted;
|
|
973
900
|
};
|
|
974
901
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
975
902
|
var _a, _b, _c, _d;
|
|
@@ -995,7 +922,10 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
995
922
|
rootVnode.$flags$ |= 4 /* isHost */;
|
|
996
923
|
hostRef.$vnode$ = rootVnode;
|
|
997
924
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
998
|
-
|
|
925
|
+
{
|
|
926
|
+
scopeId = hostElm["s-sc"];
|
|
927
|
+
}
|
|
928
|
+
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
999
929
|
{
|
|
1000
930
|
contentRef = hostElm["s-cr"];
|
|
1001
931
|
checkSlotFallbackVisibility = false;
|
|
@@ -1023,7 +953,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1023
953
|
let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
|
|
1024
954
|
while (orgLocationNode) {
|
|
1025
955
|
let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
|
|
1026
|
-
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef ===
|
|
956
|
+
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
|
|
1027
957
|
refNode = refNode.nextSibling;
|
|
1028
958
|
while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
|
|
1029
959
|
refNode = refNode == null ? void 0 : refNode.nextSibling;
|
|
@@ -1036,15 +966,13 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1036
966
|
orgLocationNode = orgLocationNode.previousSibling;
|
|
1037
967
|
}
|
|
1038
968
|
}
|
|
1039
|
-
|
|
1040
|
-
const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
|
|
1041
|
-
if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
|
|
969
|
+
if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {
|
|
1042
970
|
if (nodeToRelocate !== insertBeforeNode) {
|
|
1043
971
|
if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
|
|
1044
972
|
nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
|
|
1045
973
|
}
|
|
1046
974
|
insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
|
|
1047
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */
|
|
975
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
1048
976
|
nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
|
|
1049
977
|
}
|
|
1050
978
|
}
|
|
@@ -1072,14 +1000,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1072
1000
|
// src/runtime/update-component.ts
|
|
1073
1001
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
1074
1002
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
1075
|
-
|
|
1076
|
-
new Promise(
|
|
1077
|
-
(r) => hostRef.$onRenderResolve$ = () => {
|
|
1078
|
-
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
1079
|
-
r();
|
|
1080
|
-
}
|
|
1081
|
-
)
|
|
1082
|
-
);
|
|
1003
|
+
ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
|
|
1083
1004
|
}
|
|
1084
1005
|
};
|
|
1085
1006
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -1108,12 +1029,12 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
1108
1029
|
{
|
|
1109
1030
|
hostRef.$flags$ |= 256 /* isListenReady */;
|
|
1110
1031
|
if (hostRef.$queuedListeners$) {
|
|
1111
|
-
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event
|
|
1032
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
|
|
1112
1033
|
hostRef.$queuedListeners$ = void 0;
|
|
1113
1034
|
}
|
|
1114
1035
|
}
|
|
1115
1036
|
{
|
|
1116
|
-
maybePromise = safeCall(instance, "componentWillLoad"
|
|
1037
|
+
maybePromise = safeCall(instance, "componentWillLoad");
|
|
1117
1038
|
}
|
|
1118
1039
|
}
|
|
1119
1040
|
endSchedule();
|
|
@@ -1182,7 +1103,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1182
1103
|
const instance = hostRef.$lazyInstance$ ;
|
|
1183
1104
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
|
1184
1105
|
{
|
|
1185
|
-
safeCall(instance, "componentDidRender"
|
|
1106
|
+
safeCall(instance, "componentDidRender");
|
|
1186
1107
|
}
|
|
1187
1108
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
|
1188
1109
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
|
@@ -1211,14 +1132,17 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1211
1132
|
}
|
|
1212
1133
|
};
|
|
1213
1134
|
var appDidLoad = (who) => {
|
|
1135
|
+
{
|
|
1136
|
+
addHydratedFlag(doc.documentElement);
|
|
1137
|
+
}
|
|
1214
1138
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
1215
1139
|
};
|
|
1216
|
-
var safeCall = (instance, method, arg
|
|
1140
|
+
var safeCall = (instance, method, arg) => {
|
|
1217
1141
|
if (instance && instance[method]) {
|
|
1218
1142
|
try {
|
|
1219
1143
|
return instance[method](arg);
|
|
1220
1144
|
} catch (e) {
|
|
1221
|
-
consoleError(e
|
|
1145
|
+
consoleError(e);
|
|
1222
1146
|
}
|
|
1223
1147
|
}
|
|
1224
1148
|
return void 0;
|
|
@@ -1277,68 +1201,15 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1277
1201
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
1278
1202
|
members.map(([memberName, [memberFlags]]) => {
|
|
1279
1203
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
1280
|
-
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
1281
|
-
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
1282
|
-
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
1283
|
-
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
1284
|
-
Object.defineProperty(prototype, memberName, {
|
|
1285
|
-
get() {
|
|
1286
|
-
{
|
|
1287
|
-
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
1288
|
-
return getValue(this, memberName);
|
|
1289
|
-
}
|
|
1290
|
-
const ref = getHostRef(this);
|
|
1291
|
-
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
1292
|
-
if (!instance) return;
|
|
1293
|
-
return instance[memberName];
|
|
1294
|
-
}
|
|
1295
|
-
},
|
|
1296
|
-
configurable: true,
|
|
1297
|
-
enumerable: true
|
|
1298
|
-
});
|
|
1299
|
-
}
|
|
1300
1204
|
Object.defineProperty(prototype, memberName, {
|
|
1205
|
+
get() {
|
|
1206
|
+
return getValue(this, memberName);
|
|
1207
|
+
},
|
|
1301
1208
|
set(newValue) {
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
newValue = ref.$instanceValues$.get(memberName);
|
|
1307
|
-
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1308
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1309
|
-
}
|
|
1310
|
-
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
1311
|
-
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
1312
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
1313
|
-
return;
|
|
1314
|
-
}
|
|
1315
|
-
{
|
|
1316
|
-
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
1317
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
1318
|
-
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
1319
|
-
ref.$onReadyPromise$.then(() => {
|
|
1320
|
-
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
1321
|
-
ref.$lazyInstance$[memberName] = newValue;
|
|
1322
|
-
}
|
|
1323
|
-
});
|
|
1324
|
-
}
|
|
1325
|
-
return;
|
|
1326
|
-
}
|
|
1327
|
-
const setterSetVal = () => {
|
|
1328
|
-
const currentValue = ref.$lazyInstance$[memberName];
|
|
1329
|
-
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1330
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1331
|
-
}
|
|
1332
|
-
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
1333
|
-
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
1334
|
-
};
|
|
1335
|
-
if (ref.$lazyInstance$) {
|
|
1336
|
-
setterSetVal();
|
|
1337
|
-
} else {
|
|
1338
|
-
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
1339
|
-
}
|
|
1340
|
-
}
|
|
1341
|
-
}
|
|
1209
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1210
|
+
},
|
|
1211
|
+
configurable: true,
|
|
1212
|
+
enumerable: true
|
|
1342
1213
|
});
|
|
1343
1214
|
}
|
|
1344
1215
|
});
|
|
@@ -1348,11 +1219,10 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1348
1219
|
plt.jmp(() => {
|
|
1349
1220
|
var _a2;
|
|
1350
1221
|
const propName = attrNameToPropName.get(attrName);
|
|
1351
|
-
if (this.hasOwnProperty(propName)
|
|
1222
|
+
if (this.hasOwnProperty(propName)) {
|
|
1352
1223
|
newValue = this[propName];
|
|
1353
1224
|
delete this[propName];
|
|
1354
|
-
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" &&
|
|
1355
|
-
this[propName] == newValue) {
|
|
1225
|
+
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && this[propName] == newValue) {
|
|
1356
1226
|
return;
|
|
1357
1227
|
} else if (propName == null) {
|
|
1358
1228
|
const hostRef = getHostRef(this);
|
|
@@ -1368,11 +1238,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1368
1238
|
}
|
|
1369
1239
|
return;
|
|
1370
1240
|
}
|
|
1371
|
-
|
|
1372
|
-
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1373
|
-
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
1374
|
-
this[propName] = newValue;
|
|
1375
|
-
}
|
|
1241
|
+
this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1376
1242
|
});
|
|
1377
1243
|
};
|
|
1378
1244
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1401,7 +1267,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1401
1267
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1402
1268
|
const bundleId = cmpMeta.$lazyBundleId$;
|
|
1403
1269
|
if (bundleId) {
|
|
1404
|
-
const CstrImport = loadModule(cmpMeta
|
|
1270
|
+
const CstrImport = loadModule(cmpMeta);
|
|
1405
1271
|
if (CstrImport && "then" in CstrImport) {
|
|
1406
1272
|
const endLoad = uniqueTime();
|
|
1407
1273
|
Cstr = await CstrImport;
|
|
@@ -1426,7 +1292,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1426
1292
|
try {
|
|
1427
1293
|
new Cstr(hostRef);
|
|
1428
1294
|
} catch (e) {
|
|
1429
|
-
consoleError(e
|
|
1295
|
+
consoleError(e);
|
|
1430
1296
|
}
|
|
1431
1297
|
{
|
|
1432
1298
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
|
@@ -1435,7 +1301,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1435
1301
|
hostRef.$flags$ |= 128 /* isWatchReady */;
|
|
1436
1302
|
}
|
|
1437
1303
|
endNewInstance();
|
|
1438
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
1304
|
+
fireConnectedCallback(hostRef.$lazyInstance$);
|
|
1439
1305
|
} else {
|
|
1440
1306
|
Cstr = elm.constructor;
|
|
1441
1307
|
const cmpTag = elm.localName;
|
|
@@ -1462,9 +1328,9 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1462
1328
|
schedule();
|
|
1463
1329
|
}
|
|
1464
1330
|
};
|
|
1465
|
-
var fireConnectedCallback = (instance
|
|
1331
|
+
var fireConnectedCallback = (instance) => {
|
|
1466
1332
|
{
|
|
1467
|
-
safeCall(instance, "connectedCallback"
|
|
1333
|
+
safeCall(instance, "connectedCallback");
|
|
1468
1334
|
}
|
|
1469
1335
|
};
|
|
1470
1336
|
|
|
@@ -1506,9 +1372,9 @@ var connectedCallback = (elm) => {
|
|
|
1506
1372
|
} else {
|
|
1507
1373
|
addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
|
|
1508
1374
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1509
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
1375
|
+
fireConnectedCallback(hostRef.$lazyInstance$);
|
|
1510
1376
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1511
|
-
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance
|
|
1377
|
+
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$));
|
|
1512
1378
|
}
|
|
1513
1379
|
}
|
|
1514
1380
|
endConnected();
|
|
@@ -1521,9 +1387,9 @@ var setContentReference = (elm) => {
|
|
|
1521
1387
|
contentRefElm["s-cn"] = true;
|
|
1522
1388
|
insertBefore(elm, contentRefElm, elm.firstChild);
|
|
1523
1389
|
};
|
|
1524
|
-
var disconnectInstance = (instance
|
|
1390
|
+
var disconnectInstance = (instance) => {
|
|
1525
1391
|
{
|
|
1526
|
-
safeCall(instance, "disconnectedCallback"
|
|
1392
|
+
safeCall(instance, "disconnectedCallback");
|
|
1527
1393
|
}
|
|
1528
1394
|
};
|
|
1529
1395
|
var disconnectedCallback = async (elm) => {
|
|
@@ -1536,17 +1402,11 @@ var disconnectedCallback = async (elm) => {
|
|
|
1536
1402
|
}
|
|
1537
1403
|
}
|
|
1538
1404
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1539
|
-
disconnectInstance(hostRef.$lazyInstance
|
|
1405
|
+
disconnectInstance(hostRef.$lazyInstance$);
|
|
1540
1406
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1541
|
-
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance
|
|
1407
|
+
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$));
|
|
1542
1408
|
}
|
|
1543
1409
|
}
|
|
1544
|
-
if (rootAppliedStyles.has(elm)) {
|
|
1545
|
-
rootAppliedStyles.delete(elm);
|
|
1546
|
-
}
|
|
1547
|
-
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
1548
|
-
rootAppliedStyles.delete(elm.shadowRoot);
|
|
1549
|
-
}
|
|
1550
1410
|
};
|
|
1551
1411
|
|
|
1552
1412
|
// src/runtime/bootstrap-lazy.ts
|
|
@@ -1631,17 +1491,6 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1631
1491
|
}
|
|
1632
1492
|
disconnectedCallback() {
|
|
1633
1493
|
plt.jmp(() => disconnectedCallback(this));
|
|
1634
|
-
plt.raf(() => {
|
|
1635
|
-
var _a3;
|
|
1636
|
-
const hostRef = getHostRef(this);
|
|
1637
|
-
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
|
1638
|
-
if (i2 > -1) {
|
|
1639
|
-
deferredConnectedCallbacks.splice(i2, 1);
|
|
1640
|
-
}
|
|
1641
|
-
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
1642
|
-
delete hostRef.$vnode$.$elm$;
|
|
1643
|
-
}
|
|
1644
|
-
});
|
|
1645
1494
|
}
|
|
1646
1495
|
componentOnReady() {
|
|
1647
1496
|
return getHostRef(this).$onReadyPromise$;
|
|
@@ -1705,7 +1554,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
|
1705
1554
|
}
|
|
1706
1555
|
}
|
|
1707
1556
|
} catch (e) {
|
|
1708
|
-
consoleError(e
|
|
1557
|
+
consoleError(e);
|
|
1709
1558
|
}
|
|
1710
1559
|
};
|
|
1711
1560
|
var getHostListenerTarget = (elm, flags) => {
|