@everymatrix/player-elevate-points-history 1.56.0 → 1.56.3
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/cjs/bonus-pagination-limits_6.cjs.entry.js +33 -106
- package/dist/cjs/{index-c3f0d8ea.js → index-ba216df9.js} +130 -281
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{player-elevate-card-items-8b7d73d2.js → player-elevate-card-items-00234afd.js} +1 -1
- package/dist/cjs/player-elevate-card.cjs.entry.js +9 -21
- package/dist/cjs/player-elevate-loyaltycard.cjs.entry.js +10 -21
- package/dist/cjs/player-elevate-points-history.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/player-elevate-points-history/player-elevate-points-history.js +5 -43
- package/dist/esm/bonus-pagination-limits_6.entry.js +33 -106
- package/dist/esm/{index-8008f845.js → index-f02f9189.js} +130 -281
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{player-elevate-card-items-81ace8b1.js → player-elevate-card-items-9e358981.js} +1 -1
- package/dist/esm/player-elevate-card.entry.js +9 -21
- package/dist/esm/player-elevate-loyaltycard.entry.js +10 -21
- package/dist/esm/player-elevate-points-history.js +3 -3
- package/dist/player-elevate-points-history/p-09fa4bcd.js +2 -0
- package/dist/player-elevate-points-history/p-2be8ce26.entry.js +1 -0
- package/dist/player-elevate-points-history/{p-1c49c46d.js → p-55a1fd32.js} +1 -1
- package/dist/player-elevate-points-history/p-63db7560.entry.js +1 -0
- package/dist/player-elevate-points-history/p-77e54a25.entry.js +1 -0
- package/dist/player-elevate-points-history/player-elevate-points-history.esm.js +1 -1
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/player-elevate-points-history/.stencil/packages/stencil/player-elevate-points-history/stencil.config.d.ts +2 -0
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/player-elevate-points-history/.stencil/packages/stencil/player-elevate-points-history/stencil.config.dev.d.ts +2 -0
- package/dist/types/stencil-public-runtime.d.ts +0 -6
- package/package.json +1 -1
- package/dist/player-elevate-points-history/p-3d707cb1.entry.js +0 -1
- package/dist/player-elevate-points-history/p-530d5612.js +0 -2
- package/dist/player-elevate-points-history/p-78e6bcdb.entry.js +0 -1
- package/dist/player-elevate-points-history/p-d7b1a6d5.entry.js +0 -1
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/player-elevate-points-history/.stencil/packages/stencil/player-elevate-points-history/stencil.config.d.ts +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/player-elevate-points-history/.stencil/packages/stencil/player-elevate-points-history/stencil.config.dev.d.ts +0 -2
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/player-elevate-points-history/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/player-elevate-points-history/.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/player-elevate-points-history/.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/player-elevate-points-history/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
|
@@ -1,21 +1,17 @@
|
|
|
1
1
|
const NAMESPACE = 'player-elevate-points-history';
|
|
2
|
-
const BUILD = /* player-elevate-points-history */ { allRenderFn: false, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, 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 = /* player-elevate-points-history */ { allRenderFn: false, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, 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: true, 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: true, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, 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);
|
|
@@ -74,22 +69,16 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
74
69
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
75
70
|
/* webpackMode: "lazy" */
|
|
76
71
|
`./${bundleId}.entry.js${""}`
|
|
77
|
-
).then(
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
cmpModules.set(bundleId, importedModule);
|
|
81
|
-
}
|
|
82
|
-
return importedModule[exportName];
|
|
83
|
-
},
|
|
84
|
-
(e) => {
|
|
85
|
-
consoleError(e, hostRef.$hostElement$);
|
|
72
|
+
).then((importedModule) => {
|
|
73
|
+
{
|
|
74
|
+
cmpModules.set(bundleId, importedModule);
|
|
86
75
|
}
|
|
87
|
-
|
|
76
|
+
return importedModule[exportName];
|
|
77
|
+
}, consoleError);
|
|
88
78
|
};
|
|
89
79
|
|
|
90
80
|
// src/client/client-style.ts
|
|
91
81
|
var styles = /* @__PURE__ */ new Map();
|
|
92
|
-
var HYDRATED_STYLE_ID = "sty-id";
|
|
93
82
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
94
83
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
95
84
|
var win = typeof window !== "undefined" ? window : {};
|
|
@@ -169,6 +158,12 @@ var getAssetPath = (path) => {
|
|
|
169
158
|
const assetUrl = new URL(path, plt.$resourcesUrl$);
|
|
170
159
|
return assetUrl.origin !== win.location.origin ? assetUrl.href : assetUrl.pathname;
|
|
171
160
|
};
|
|
161
|
+
|
|
162
|
+
// src/utils/constants.ts
|
|
163
|
+
var EMPTY_OBJ = {};
|
|
164
|
+
|
|
165
|
+
// src/utils/helpers.ts
|
|
166
|
+
var isDef = (v) => v != null;
|
|
172
167
|
var isComplexType = (o) => {
|
|
173
168
|
o = typeof o;
|
|
174
169
|
return o === "object" || o === "function";
|
|
@@ -228,63 +223,6 @@ var unwrapErr = (result) => {
|
|
|
228
223
|
throw result.value;
|
|
229
224
|
}
|
|
230
225
|
};
|
|
231
|
-
var updateFallbackSlotVisibility = (elm) => {
|
|
232
|
-
const childNodes = elm.__childNodes || elm.childNodes;
|
|
233
|
-
if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
|
|
234
|
-
getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
|
|
235
|
-
var _a;
|
|
236
|
-
if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
|
|
237
|
-
if ((_a = getHostSlotChildNodes(slotNode, slotNode["s-sn"], false)) == null ? void 0 : _a.length) {
|
|
238
|
-
slotNode.hidden = true;
|
|
239
|
-
} else {
|
|
240
|
-
slotNode.hidden = false;
|
|
241
|
-
}
|
|
242
|
-
}
|
|
243
|
-
});
|
|
244
|
-
}
|
|
245
|
-
for (const childNode of childNodes) {
|
|
246
|
-
if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {
|
|
247
|
-
updateFallbackSlotVisibility(childNode);
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
};
|
|
251
|
-
function getHostSlotNodes(childNodes, hostName, slotName) {
|
|
252
|
-
let i2 = 0;
|
|
253
|
-
let slottedNodes = [];
|
|
254
|
-
let childNode;
|
|
255
|
-
for (; i2 < childNodes.length; i2++) {
|
|
256
|
-
childNode = childNodes[i2];
|
|
257
|
-
if (childNode["s-sr"] && childNode["s-hn"] === hostName && (slotName === void 0 || childNode["s-sn"] === slotName)) {
|
|
258
|
-
slottedNodes.push(childNode);
|
|
259
|
-
if (typeof slotName !== "undefined") return slottedNodes;
|
|
260
|
-
}
|
|
261
|
-
slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
|
|
262
|
-
}
|
|
263
|
-
return slottedNodes;
|
|
264
|
-
}
|
|
265
|
-
var getHostSlotChildNodes = (node, slotName, includeSlot = true) => {
|
|
266
|
-
const childNodes = [];
|
|
267
|
-
if (includeSlot && node["s-sr"] || !node["s-sr"]) childNodes.push(node);
|
|
268
|
-
while ((node = node.nextSibling) && node["s-sn"] === slotName) {
|
|
269
|
-
childNodes.push(node);
|
|
270
|
-
}
|
|
271
|
-
return childNodes;
|
|
272
|
-
};
|
|
273
|
-
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
274
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
275
|
-
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
276
|
-
return true;
|
|
277
|
-
}
|
|
278
|
-
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
279
|
-
return true;
|
|
280
|
-
}
|
|
281
|
-
return false;
|
|
282
|
-
}
|
|
283
|
-
if (nodeToRelocate["s-sn"] === slotName) {
|
|
284
|
-
return true;
|
|
285
|
-
}
|
|
286
|
-
return slotName === "";
|
|
287
|
-
};
|
|
288
226
|
var createTime = (fnName, tagName = "") => {
|
|
289
227
|
{
|
|
290
228
|
return () => {
|
|
@@ -476,40 +414,13 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
476
414
|
}
|
|
477
415
|
if (!appliedStyles.has(scopeId2)) {
|
|
478
416
|
{
|
|
479
|
-
styleElm =
|
|
417
|
+
styleElm = doc.createElement("style");
|
|
480
418
|
styleElm.innerHTML = style;
|
|
481
419
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
|
482
420
|
if (nonce != null) {
|
|
483
421
|
styleElm.setAttribute("nonce", nonce);
|
|
484
422
|
}
|
|
485
|
-
|
|
486
|
-
if (styleContainerNode.nodeName === "HEAD") {
|
|
487
|
-
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
488
|
-
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
489
|
-
styleContainerNode.insertBefore(
|
|
490
|
-
styleElm,
|
|
491
|
-
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
492
|
-
);
|
|
493
|
-
} else if ("host" in styleContainerNode) {
|
|
494
|
-
if (supportsConstructableStylesheets) {
|
|
495
|
-
const stylesheet = new CSSStyleSheet();
|
|
496
|
-
stylesheet.replaceSync(style);
|
|
497
|
-
styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];
|
|
498
|
-
} else {
|
|
499
|
-
const existingStyleContainer = styleContainerNode.querySelector("style");
|
|
500
|
-
if (existingStyleContainer) {
|
|
501
|
-
existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
|
|
502
|
-
} else {
|
|
503
|
-
styleContainerNode.prepend(styleElm);
|
|
504
|
-
}
|
|
505
|
-
}
|
|
506
|
-
} else {
|
|
507
|
-
styleContainerNode.append(styleElm);
|
|
508
|
-
}
|
|
509
|
-
}
|
|
510
|
-
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
511
|
-
styleContainerNode.insertBefore(styleElm, null);
|
|
512
|
-
}
|
|
423
|
+
styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector("link"));
|
|
513
424
|
}
|
|
514
425
|
if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
|
|
515
426
|
styleElm.innerHTML += SLOT_FB_CSS;
|
|
@@ -532,25 +443,23 @@ var attachStyles = (hostRef) => {
|
|
|
532
443
|
const scopeId2 = addStyle(
|
|
533
444
|
elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(),
|
|
534
445
|
cmpMeta);
|
|
535
|
-
if (
|
|
446
|
+
if (flags & 10 /* needsScopedEncapsulation */) {
|
|
536
447
|
elm["s-sc"] = scopeId2;
|
|
537
448
|
elm.classList.add(scopeId2 + "-h");
|
|
538
449
|
}
|
|
539
450
|
endAttachStyles();
|
|
540
451
|
};
|
|
541
452
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
542
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags
|
|
453
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
543
454
|
if (oldValue !== newValue) {
|
|
544
455
|
let isProp = isMemberInElement(elm, memberName);
|
|
545
456
|
let ln = memberName.toLowerCase();
|
|
546
457
|
if (memberName === "class") {
|
|
547
458
|
const classList = elm.classList;
|
|
548
459
|
const oldClasses = parseClassList(oldValue);
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
553
|
-
}
|
|
460
|
+
const newClasses = parseClassList(newValue);
|
|
461
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
462
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
554
463
|
} else if (memberName === "style") {
|
|
555
464
|
{
|
|
556
465
|
for (const prop in oldValue) {
|
|
@@ -599,13 +508,9 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
599
508
|
if (memberName === "list") {
|
|
600
509
|
isProp = false;
|
|
601
510
|
} else if (oldValue == null || elm[memberName] != n) {
|
|
602
|
-
|
|
603
|
-
elm[memberName] = n;
|
|
604
|
-
} else {
|
|
605
|
-
elm.setAttribute(memberName, n);
|
|
606
|
-
}
|
|
511
|
+
elm[memberName] = n;
|
|
607
512
|
}
|
|
608
|
-
} else
|
|
513
|
+
} else {
|
|
609
514
|
elm[memberName] = newValue;
|
|
610
515
|
}
|
|
611
516
|
} catch (e) {
|
|
@@ -627,44 +532,24 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
627
532
|
}
|
|
628
533
|
};
|
|
629
534
|
var parseClassListRegex = /\s/;
|
|
630
|
-
var parseClassList = (value) =>
|
|
631
|
-
if (typeof value === "object" && value && "baseVal" in value) {
|
|
632
|
-
value = value.baseVal;
|
|
633
|
-
}
|
|
634
|
-
if (!value || typeof value !== "string") {
|
|
635
|
-
return [];
|
|
636
|
-
}
|
|
637
|
-
return value.split(parseClassListRegex);
|
|
638
|
-
};
|
|
535
|
+
var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
|
|
639
536
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
640
537
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
641
538
|
|
|
642
539
|
// src/runtime/vdom/update-element.ts
|
|
643
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2
|
|
540
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
644
541
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
645
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
646
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
542
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
|
|
543
|
+
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
|
647
544
|
{
|
|
648
545
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
649
546
|
if (!(memberName in newVnodeAttrs)) {
|
|
650
|
-
setAccessor(
|
|
651
|
-
elm,
|
|
652
|
-
memberName,
|
|
653
|
-
oldVnodeAttrs[memberName],
|
|
654
|
-
void 0,
|
|
655
|
-
isSvgMode2,
|
|
656
|
-
newVnode.$flags$);
|
|
547
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
|
|
657
548
|
}
|
|
658
549
|
}
|
|
659
550
|
}
|
|
660
551
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
661
|
-
setAccessor(
|
|
662
|
-
elm,
|
|
663
|
-
memberName,
|
|
664
|
-
oldVnodeAttrs[memberName],
|
|
665
|
-
newVnodeAttrs[memberName],
|
|
666
|
-
isSvgMode2,
|
|
667
|
-
newVnode.$flags$);
|
|
552
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
|
|
668
553
|
}
|
|
669
554
|
};
|
|
670
555
|
function sortedAttrNames(attrNames) {
|
|
@@ -676,13 +561,16 @@ function sortedAttrNames(attrNames) {
|
|
|
676
561
|
attrNames
|
|
677
562
|
);
|
|
678
563
|
}
|
|
564
|
+
|
|
565
|
+
// src/runtime/vdom/vdom-render.ts
|
|
566
|
+
var scopeId;
|
|
679
567
|
var contentRef;
|
|
680
568
|
var hostTagName;
|
|
681
569
|
var useNativeShadowDom = false;
|
|
682
570
|
var checkSlotFallbackVisibility = false;
|
|
683
571
|
var checkSlotRelocate = false;
|
|
684
572
|
var isSvgMode = false;
|
|
685
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
573
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
686
574
|
var _a;
|
|
687
575
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
688
576
|
let i2 = 0;
|
|
@@ -692,6 +580,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
692
580
|
if (!useNativeShadowDom) {
|
|
693
581
|
checkSlotRelocate = true;
|
|
694
582
|
if (newVNode2.$tag$ === "slot") {
|
|
583
|
+
if (scopeId) {
|
|
584
|
+
parentElm.classList.add(scopeId + "-s");
|
|
585
|
+
}
|
|
695
586
|
newVNode2.$flags$ |= newVNode2.$children$ ? (
|
|
696
587
|
// slot element has fallback content
|
|
697
588
|
// still create an element that "mocks" the slot element
|
|
@@ -715,9 +606,12 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
715
606
|
{
|
|
716
607
|
updateElement(null, newVNode2, isSvgMode);
|
|
717
608
|
}
|
|
609
|
+
if (isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
610
|
+
elm.classList.add(elm["s-si"] = scopeId);
|
|
611
|
+
}
|
|
718
612
|
if (newVNode2.$children$) {
|
|
719
613
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
720
|
-
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
614
|
+
childNode = createElm(oldParentVNode, newVNode2, i2, elm);
|
|
721
615
|
if (childNode) {
|
|
722
616
|
elm.appendChild(childNode);
|
|
723
617
|
}
|
|
@@ -743,7 +637,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
743
637
|
};
|
|
744
638
|
var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
745
639
|
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
746
|
-
const oldSlotChildNodes = Array.from(parentElm.
|
|
640
|
+
const oldSlotChildNodes = Array.from(parentElm.childNodes);
|
|
747
641
|
if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
|
|
748
642
|
let node = parentElm;
|
|
749
643
|
while (node = node.nextSibling) {
|
|
@@ -755,7 +649,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
|
755
649
|
for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
|
|
756
650
|
const childNode = oldSlotChildNodes[i2];
|
|
757
651
|
if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
|
|
758
|
-
insertBefore(
|
|
652
|
+
insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));
|
|
759
653
|
childNode["s-ol"].remove();
|
|
760
654
|
childNode["s-ol"] = void 0;
|
|
761
655
|
childNode["s-sh"] = void 0;
|
|
@@ -775,7 +669,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
|
775
669
|
}
|
|
776
670
|
for (; startIdx <= endIdx; ++startIdx) {
|
|
777
671
|
if (vnodes[startIdx]) {
|
|
778
|
-
childNode = createElm(null, parentVNode, startIdx);
|
|
672
|
+
childNode = createElm(null, parentVNode, startIdx, parentElm);
|
|
779
673
|
if (childNode) {
|
|
780
674
|
vnodes[startIdx].$elm$ = childNode;
|
|
781
675
|
insertBefore(containerElm, childNode, referenceNode(before) );
|
|
@@ -861,7 +755,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
861
755
|
if (idxInOld >= 0) {
|
|
862
756
|
elmToMove = oldCh[idxInOld];
|
|
863
757
|
if (elmToMove.$tag$ !== newStartVnode.$tag$) {
|
|
864
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
|
|
758
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld, parentElm);
|
|
865
759
|
} else {
|
|
866
760
|
patch(elmToMove, newStartVnode, isInitialRender);
|
|
867
761
|
oldCh[idxInOld] = void 0;
|
|
@@ -869,16 +763,12 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
869
763
|
}
|
|
870
764
|
newStartVnode = newCh[++newStartIdx];
|
|
871
765
|
} else {
|
|
872
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
|
|
766
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx, parentElm);
|
|
873
767
|
newStartVnode = newCh[++newStartIdx];
|
|
874
768
|
}
|
|
875
769
|
if (node) {
|
|
876
770
|
{
|
|
877
|
-
insertBefore(
|
|
878
|
-
referenceNode(oldStartVnode.$elm$).parentNode,
|
|
879
|
-
node,
|
|
880
|
-
referenceNode(oldStartVnode.$elm$)
|
|
881
|
-
);
|
|
771
|
+
insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));
|
|
882
772
|
}
|
|
883
773
|
}
|
|
884
774
|
}
|
|
@@ -904,14 +794,14 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
904
794
|
if (!isInitialRender) {
|
|
905
795
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
906
796
|
}
|
|
907
|
-
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
908
|
-
leftVNode.$key$ = rightVNode.$key$;
|
|
909
|
-
}
|
|
910
797
|
return true;
|
|
911
798
|
}
|
|
912
799
|
return false;
|
|
913
800
|
};
|
|
914
|
-
var referenceNode = (node) =>
|
|
801
|
+
var referenceNode = (node) => {
|
|
802
|
+
return node && node["s-ol"] || node;
|
|
803
|
+
};
|
|
804
|
+
var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
|
|
915
805
|
var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
916
806
|
const elm = newVNode2.$elm$ = oldVNode.$elm$;
|
|
917
807
|
const oldChildren = oldVNode.$children$;
|
|
@@ -932,10 +822,7 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
932
822
|
elm.textContent = "";
|
|
933
823
|
}
|
|
934
824
|
addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);
|
|
935
|
-
} else if (
|
|
936
|
-
// don't do this on initial render as it can cause non-hydrated content to be removed
|
|
937
|
-
!isInitialRender && BUILD.updatable && oldChildren !== null
|
|
938
|
-
) {
|
|
825
|
+
} else if (oldChildren !== null) {
|
|
939
826
|
removeVnodes(oldChildren, 0, oldChildren.length - 1);
|
|
940
827
|
}
|
|
941
828
|
} else if ((defaultHolder = elm["s-cr"])) {
|
|
@@ -944,15 +831,41 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
944
831
|
elm.data = text;
|
|
945
832
|
}
|
|
946
833
|
};
|
|
834
|
+
var updateFallbackSlotVisibility = (elm) => {
|
|
835
|
+
const childNodes = elm.childNodes;
|
|
836
|
+
for (const childNode of childNodes) {
|
|
837
|
+
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
838
|
+
if (childNode["s-sr"]) {
|
|
839
|
+
const slotName = childNode["s-sn"];
|
|
840
|
+
childNode.hidden = false;
|
|
841
|
+
for (const siblingNode of childNodes) {
|
|
842
|
+
if (siblingNode !== childNode) {
|
|
843
|
+
if (siblingNode["s-hn"] !== childNode["s-hn"] || slotName !== "") {
|
|
844
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute("slot") || slotName === siblingNode["s-sn"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode["s-sn"]) {
|
|
845
|
+
childNode.hidden = true;
|
|
846
|
+
break;
|
|
847
|
+
}
|
|
848
|
+
} else {
|
|
849
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== "") {
|
|
850
|
+
childNode.hidden = true;
|
|
851
|
+
break;
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
}
|
|
855
|
+
}
|
|
856
|
+
}
|
|
857
|
+
updateFallbackSlotVisibility(childNode);
|
|
858
|
+
}
|
|
859
|
+
}
|
|
860
|
+
};
|
|
947
861
|
var relocateNodes = [];
|
|
948
862
|
var markSlotContentForRelocation = (elm) => {
|
|
949
863
|
let node;
|
|
950
864
|
let hostContentNodes;
|
|
951
865
|
let j;
|
|
952
|
-
const
|
|
953
|
-
for (const childNode of children) {
|
|
866
|
+
for (const childNode of elm.childNodes) {
|
|
954
867
|
if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
|
|
955
|
-
hostContentNodes = node.parentNode.
|
|
868
|
+
hostContentNodes = node.parentNode.childNodes;
|
|
956
869
|
const slotName = childNode["s-sn"];
|
|
957
870
|
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
|
958
871
|
node = hostContentNodes[j];
|
|
@@ -994,10 +907,24 @@ var markSlotContentForRelocation = (elm) => {
|
|
|
994
907
|
}
|
|
995
908
|
}
|
|
996
909
|
};
|
|
997
|
-
var
|
|
998
|
-
{
|
|
999
|
-
|
|
910
|
+
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
911
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
912
|
+
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
913
|
+
return true;
|
|
914
|
+
}
|
|
915
|
+
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
916
|
+
return true;
|
|
917
|
+
}
|
|
918
|
+
return false;
|
|
1000
919
|
}
|
|
920
|
+
if (nodeToRelocate["s-sn"] === slotName) {
|
|
921
|
+
return true;
|
|
922
|
+
}
|
|
923
|
+
return slotName === "";
|
|
924
|
+
};
|
|
925
|
+
var insertBefore = (parent, newNode, reference) => {
|
|
926
|
+
const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
927
|
+
return inserted;
|
|
1001
928
|
};
|
|
1002
929
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1003
930
|
var _a, _b, _c, _d;
|
|
@@ -1023,7 +950,10 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1023
950
|
rootVnode.$flags$ |= 4 /* isHost */;
|
|
1024
951
|
hostRef.$vnode$ = rootVnode;
|
|
1025
952
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
1026
|
-
|
|
953
|
+
{
|
|
954
|
+
scopeId = hostElm["s-sc"];
|
|
955
|
+
}
|
|
956
|
+
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
1027
957
|
{
|
|
1028
958
|
contentRef = hostElm["s-cr"];
|
|
1029
959
|
checkSlotFallbackVisibility = false;
|
|
@@ -1051,7 +981,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1051
981
|
let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
|
|
1052
982
|
while (orgLocationNode) {
|
|
1053
983
|
let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
|
|
1054
|
-
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef ===
|
|
984
|
+
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
|
|
1055
985
|
refNode = refNode.nextSibling;
|
|
1056
986
|
while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
|
|
1057
987
|
refNode = refNode == null ? void 0 : refNode.nextSibling;
|
|
@@ -1064,15 +994,13 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1064
994
|
orgLocationNode = orgLocationNode.previousSibling;
|
|
1065
995
|
}
|
|
1066
996
|
}
|
|
1067
|
-
|
|
1068
|
-
const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
|
|
1069
|
-
if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
|
|
997
|
+
if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {
|
|
1070
998
|
if (nodeToRelocate !== insertBeforeNode) {
|
|
1071
999
|
if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
|
|
1072
1000
|
nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
|
|
1073
1001
|
}
|
|
1074
1002
|
insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
|
|
1075
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */
|
|
1003
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
1076
1004
|
nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
|
|
1077
1005
|
}
|
|
1078
1006
|
}
|
|
@@ -1100,14 +1028,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1100
1028
|
// src/runtime/update-component.ts
|
|
1101
1029
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
1102
1030
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
1103
|
-
|
|
1104
|
-
new Promise(
|
|
1105
|
-
(r) => hostRef.$onRenderResolve$ = () => {
|
|
1106
|
-
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
1107
|
-
r();
|
|
1108
|
-
}
|
|
1109
|
-
)
|
|
1110
|
-
);
|
|
1031
|
+
ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
|
|
1111
1032
|
}
|
|
1112
1033
|
};
|
|
1113
1034
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -1136,16 +1057,16 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
1136
1057
|
{
|
|
1137
1058
|
hostRef.$flags$ |= 256 /* isListenReady */;
|
|
1138
1059
|
if (hostRef.$queuedListeners$) {
|
|
1139
|
-
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event
|
|
1060
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
|
|
1140
1061
|
hostRef.$queuedListeners$ = void 0;
|
|
1141
1062
|
}
|
|
1142
1063
|
}
|
|
1143
1064
|
{
|
|
1144
|
-
maybePromise = safeCall(instance, "componentWillLoad"
|
|
1065
|
+
maybePromise = safeCall(instance, "componentWillLoad");
|
|
1145
1066
|
}
|
|
1146
1067
|
}
|
|
1147
1068
|
{
|
|
1148
|
-
maybePromise = enqueue(maybePromise, () => safeCall(instance, "componentWillRender"
|
|
1069
|
+
maybePromise = enqueue(maybePromise, () => safeCall(instance, "componentWillRender"));
|
|
1149
1070
|
}
|
|
1150
1071
|
endSchedule();
|
|
1151
1072
|
return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));
|
|
@@ -1213,7 +1134,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1213
1134
|
const instance = hostRef.$lazyInstance$ ;
|
|
1214
1135
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
|
1215
1136
|
{
|
|
1216
|
-
safeCall(instance, "componentDidRender"
|
|
1137
|
+
safeCall(instance, "componentDidRender");
|
|
1217
1138
|
}
|
|
1218
1139
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
|
1219
1140
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
|
@@ -1242,14 +1163,17 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1242
1163
|
}
|
|
1243
1164
|
};
|
|
1244
1165
|
var appDidLoad = (who) => {
|
|
1166
|
+
{
|
|
1167
|
+
addHydratedFlag(doc.documentElement);
|
|
1168
|
+
}
|
|
1245
1169
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
1246
1170
|
};
|
|
1247
|
-
var safeCall = (instance, method, arg
|
|
1171
|
+
var safeCall = (instance, method, arg) => {
|
|
1248
1172
|
if (instance && instance[method]) {
|
|
1249
1173
|
try {
|
|
1250
1174
|
return instance[method](arg);
|
|
1251
1175
|
} catch (e) {
|
|
1252
|
-
consoleError(e
|
|
1176
|
+
consoleError(e);
|
|
1253
1177
|
}
|
|
1254
1178
|
}
|
|
1255
1179
|
return void 0;
|
|
@@ -1308,68 +1232,15 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1308
1232
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
1309
1233
|
members.map(([memberName, [memberFlags]]) => {
|
|
1310
1234
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
1311
|
-
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
1312
|
-
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
1313
|
-
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
1314
|
-
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
1315
|
-
Object.defineProperty(prototype, memberName, {
|
|
1316
|
-
get() {
|
|
1317
|
-
{
|
|
1318
|
-
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
1319
|
-
return getValue(this, memberName);
|
|
1320
|
-
}
|
|
1321
|
-
const ref = getHostRef(this);
|
|
1322
|
-
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
1323
|
-
if (!instance) return;
|
|
1324
|
-
return instance[memberName];
|
|
1325
|
-
}
|
|
1326
|
-
},
|
|
1327
|
-
configurable: true,
|
|
1328
|
-
enumerable: true
|
|
1329
|
-
});
|
|
1330
|
-
}
|
|
1331
1235
|
Object.defineProperty(prototype, memberName, {
|
|
1236
|
+
get() {
|
|
1237
|
+
return getValue(this, memberName);
|
|
1238
|
+
},
|
|
1332
1239
|
set(newValue) {
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
newValue = ref.$instanceValues$.get(memberName);
|
|
1338
|
-
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1339
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1340
|
-
}
|
|
1341
|
-
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
1342
|
-
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
1343
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
1344
|
-
return;
|
|
1345
|
-
}
|
|
1346
|
-
{
|
|
1347
|
-
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
1348
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
1349
|
-
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
1350
|
-
ref.$onReadyPromise$.then(() => {
|
|
1351
|
-
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
1352
|
-
ref.$lazyInstance$[memberName] = newValue;
|
|
1353
|
-
}
|
|
1354
|
-
});
|
|
1355
|
-
}
|
|
1356
|
-
return;
|
|
1357
|
-
}
|
|
1358
|
-
const setterSetVal = () => {
|
|
1359
|
-
const currentValue = ref.$lazyInstance$[memberName];
|
|
1360
|
-
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1361
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1362
|
-
}
|
|
1363
|
-
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
1364
|
-
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
1365
|
-
};
|
|
1366
|
-
if (ref.$lazyInstance$) {
|
|
1367
|
-
setterSetVal();
|
|
1368
|
-
} else {
|
|
1369
|
-
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
1370
|
-
}
|
|
1371
|
-
}
|
|
1372
|
-
}
|
|
1240
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1241
|
+
},
|
|
1242
|
+
configurable: true,
|
|
1243
|
+
enumerable: true
|
|
1373
1244
|
});
|
|
1374
1245
|
}
|
|
1375
1246
|
});
|
|
@@ -1379,11 +1250,10 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1379
1250
|
plt.jmp(() => {
|
|
1380
1251
|
var _a2;
|
|
1381
1252
|
const propName = attrNameToPropName.get(attrName);
|
|
1382
|
-
if (this.hasOwnProperty(propName)
|
|
1253
|
+
if (this.hasOwnProperty(propName)) {
|
|
1383
1254
|
newValue = this[propName];
|
|
1384
1255
|
delete this[propName];
|
|
1385
|
-
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" &&
|
|
1386
|
-
this[propName] == newValue) {
|
|
1256
|
+
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && this[propName] == newValue) {
|
|
1387
1257
|
return;
|
|
1388
1258
|
} else if (propName == null) {
|
|
1389
1259
|
const hostRef = getHostRef(this);
|
|
@@ -1399,11 +1269,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1399
1269
|
}
|
|
1400
1270
|
return;
|
|
1401
1271
|
}
|
|
1402
|
-
|
|
1403
|
-
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1404
|
-
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
1405
|
-
this[propName] = newValue;
|
|
1406
|
-
}
|
|
1272
|
+
this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1407
1273
|
});
|
|
1408
1274
|
};
|
|
1409
1275
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1432,7 +1298,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1432
1298
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1433
1299
|
const bundleId = cmpMeta.$lazyBundleId$;
|
|
1434
1300
|
if (bundleId) {
|
|
1435
|
-
const CstrImport = loadModule(cmpMeta
|
|
1301
|
+
const CstrImport = loadModule(cmpMeta);
|
|
1436
1302
|
if (CstrImport && "then" in CstrImport) {
|
|
1437
1303
|
const endLoad = uniqueTime();
|
|
1438
1304
|
Cstr = await CstrImport;
|
|
@@ -1457,7 +1323,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1457
1323
|
try {
|
|
1458
1324
|
new Cstr(hostRef);
|
|
1459
1325
|
} catch (e) {
|
|
1460
|
-
consoleError(e
|
|
1326
|
+
consoleError(e);
|
|
1461
1327
|
}
|
|
1462
1328
|
{
|
|
1463
1329
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
|
@@ -1492,7 +1358,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1492
1358
|
schedule();
|
|
1493
1359
|
}
|
|
1494
1360
|
};
|
|
1495
|
-
var fireConnectedCallback = (instance
|
|
1361
|
+
var fireConnectedCallback = (instance) => {
|
|
1496
1362
|
};
|
|
1497
1363
|
|
|
1498
1364
|
// src/runtime/connected-callback.ts
|
|
@@ -1546,7 +1412,7 @@ var setContentReference = (elm) => {
|
|
|
1546
1412
|
contentRefElm["s-cn"] = true;
|
|
1547
1413
|
insertBefore(elm, contentRefElm, elm.firstChild);
|
|
1548
1414
|
};
|
|
1549
|
-
var disconnectInstance = (instance
|
|
1415
|
+
var disconnectInstance = (instance) => {
|
|
1550
1416
|
};
|
|
1551
1417
|
var disconnectedCallback = async (elm) => {
|
|
1552
1418
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
@@ -1561,12 +1427,6 @@ var disconnectedCallback = async (elm) => {
|
|
|
1561
1427
|
hostRef.$onReadyPromise$.then(() => disconnectInstance());
|
|
1562
1428
|
}
|
|
1563
1429
|
}
|
|
1564
|
-
if (rootAppliedStyles.has(elm)) {
|
|
1565
|
-
rootAppliedStyles.delete(elm);
|
|
1566
|
-
}
|
|
1567
|
-
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
1568
|
-
rootAppliedStyles.delete(elm.shadowRoot);
|
|
1569
|
-
}
|
|
1570
1430
|
};
|
|
1571
1431
|
|
|
1572
1432
|
// src/runtime/bootstrap-lazy.ts
|
|
@@ -1651,17 +1511,6 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1651
1511
|
}
|
|
1652
1512
|
disconnectedCallback() {
|
|
1653
1513
|
plt.jmp(() => disconnectedCallback(this));
|
|
1654
|
-
plt.raf(() => {
|
|
1655
|
-
var _a3;
|
|
1656
|
-
const hostRef = getHostRef(this);
|
|
1657
|
-
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
|
1658
|
-
if (i2 > -1) {
|
|
1659
|
-
deferredConnectedCallbacks.splice(i2, 1);
|
|
1660
|
-
}
|
|
1661
|
-
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
1662
|
-
delete hostRef.$vnode$.$elm$;
|
|
1663
|
-
}
|
|
1664
|
-
});
|
|
1665
1514
|
}
|
|
1666
1515
|
componentOnReady() {
|
|
1667
1516
|
return getHostRef(this).$onReadyPromise$;
|
|
@@ -1728,7 +1577,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
|
1728
1577
|
}
|
|
1729
1578
|
}
|
|
1730
1579
|
} catch (e) {
|
|
1731
|
-
consoleError(e
|
|
1580
|
+
consoleError(e);
|
|
1732
1581
|
}
|
|
1733
1582
|
};
|
|
1734
1583
|
var getHostListenerTarget = (elm, flags) => {
|