@everymatrix/player-elevate-card 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/general-styling-wrapper_5.cjs.entry.js +33 -78
- package/dist/cjs/{index-e1db0305.js → index-ea33d8f2.js} +129 -280
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/player-elevate-card.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/player-elevate-card/player-elevate-card.js +7 -39
- package/dist/collection/components/player-elevate-card-data/player-elevate-card-data.js +5 -2
- package/dist/collection/components/player-elevate-loyaltycard/player-elevate-loyaltycard.js +8 -41
- package/dist/collection/components/player-elevate-pointcard/player-elevate-pointcard.js +10 -51
- package/dist/esm/general-styling-wrapper_5.entry.js +33 -78
- package/dist/esm/{index-29ae3408.js → index-98f17aff.js} +129 -280
- package/dist/esm/loader.js +2 -2
- package/dist/esm/player-elevate-card.js +3 -3
- package/dist/player-elevate-card/p-17f8d580.js +2 -0
- package/dist/player-elevate-card/p-45b4751e.entry.js +1 -0
- package/dist/player-elevate-card/player-elevate-card.esm.js +1 -1
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/player-elevate-card/.stencil/packages/stencil/player-elevate-card/stencil.config.d.ts +2 -0
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/player-elevate-card/.stencil/packages/stencil/player-elevate-card/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-card/p-17e5148c.js +0 -2
- package/dist/player-elevate-card/p-33df4709.entry.js +0 -1
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/player-elevate-card/.stencil/packages/stencil/player-elevate-card/stencil.config.d.ts +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/player-elevate-card/.stencil/packages/stencil/player-elevate-card/stencil.config.dev.d.ts +0 -2
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/player-elevate-card/.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-card/.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-card/.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-card/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
|
@@ -21,23 +21,19 @@ function _interopNamespace(e) {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
const NAMESPACE = 'player-elevate-card';
|
|
24
|
-
const BUILD = /* player-elevate-card */ { 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: false, 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,
|
|
24
|
+
const BUILD = /* player-elevate-card */ { 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: false, 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: false, propMutable: false, propNumber: false, 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 };
|
|
25
25
|
|
|
26
26
|
/*
|
|
27
|
-
Stencil Client Platform v4.
|
|
27
|
+
Stencil Client Platform v4.19.2 | MIT Licensed | https://stenciljs.com
|
|
28
28
|
*/
|
|
29
29
|
var __defProp = Object.defineProperty;
|
|
30
30
|
var __export = (target, all) => {
|
|
31
31
|
for (var name in all)
|
|
32
32
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
33
33
|
};
|
|
34
|
-
|
|
35
|
-
// src/client/client-host-ref.ts
|
|
36
34
|
var hostRefs = /* @__PURE__ */ new WeakMap();
|
|
37
35
|
var getHostRef = (ref) => hostRefs.get(ref);
|
|
38
|
-
var registerInstance = (lazyInstance, hostRef) =>
|
|
39
|
-
hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
40
|
-
};
|
|
36
|
+
var registerInstance = (lazyInstance, hostRef) => hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
41
37
|
var registerHost = (hostElement, cmpMeta) => {
|
|
42
38
|
const hostRef = {
|
|
43
39
|
$flags$: 0,
|
|
@@ -50,8 +46,7 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
|
50
46
|
hostElement["s-p"] = [];
|
|
51
47
|
hostElement["s-rc"] = [];
|
|
52
48
|
}
|
|
53
|
-
|
|
54
|
-
return ref;
|
|
49
|
+
return hostRefs.set(hostElement, hostRef);
|
|
55
50
|
};
|
|
56
51
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
|
57
52
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
|
@@ -88,22 +83,16 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
88
83
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
89
84
|
/* webpackMode: "lazy" */
|
|
90
85
|
`./${bundleId}.entry.js${""}`
|
|
91
|
-
)); }).then(
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
cmpModules.set(bundleId, importedModule);
|
|
95
|
-
}
|
|
96
|
-
return importedModule[exportName];
|
|
97
|
-
},
|
|
98
|
-
(e) => {
|
|
99
|
-
consoleError(e, hostRef.$hostElement$);
|
|
86
|
+
)); }).then((importedModule) => {
|
|
87
|
+
{
|
|
88
|
+
cmpModules.set(bundleId, importedModule);
|
|
100
89
|
}
|
|
101
|
-
|
|
90
|
+
return importedModule[exportName];
|
|
91
|
+
}, consoleError);
|
|
102
92
|
};
|
|
103
93
|
|
|
104
94
|
// src/client/client-style.ts
|
|
105
95
|
var styles = /* @__PURE__ */ new Map();
|
|
106
|
-
var HYDRATED_STYLE_ID = "sty-id";
|
|
107
96
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
108
97
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
109
98
|
var win = typeof window !== "undefined" ? window : {};
|
|
@@ -183,6 +172,12 @@ var getAssetPath = (path) => {
|
|
|
183
172
|
const assetUrl = new URL(path, plt.$resourcesUrl$);
|
|
184
173
|
return assetUrl.origin !== win.location.origin ? assetUrl.href : assetUrl.pathname;
|
|
185
174
|
};
|
|
175
|
+
|
|
176
|
+
// src/utils/constants.ts
|
|
177
|
+
var EMPTY_OBJ = {};
|
|
178
|
+
|
|
179
|
+
// src/utils/helpers.ts
|
|
180
|
+
var isDef = (v) => v != null;
|
|
186
181
|
var isComplexType = (o) => {
|
|
187
182
|
o = typeof o;
|
|
188
183
|
return o === "object" || o === "function";
|
|
@@ -242,63 +237,6 @@ var unwrapErr = (result) => {
|
|
|
242
237
|
throw result.value;
|
|
243
238
|
}
|
|
244
239
|
};
|
|
245
|
-
var updateFallbackSlotVisibility = (elm) => {
|
|
246
|
-
const childNodes = elm.__childNodes || elm.childNodes;
|
|
247
|
-
if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
|
|
248
|
-
getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
|
|
249
|
-
var _a;
|
|
250
|
-
if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
|
|
251
|
-
if ((_a = getHostSlotChildNodes(slotNode, slotNode["s-sn"], false)) == null ? void 0 : _a.length) {
|
|
252
|
-
slotNode.hidden = true;
|
|
253
|
-
} else {
|
|
254
|
-
slotNode.hidden = false;
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
});
|
|
258
|
-
}
|
|
259
|
-
for (const childNode of childNodes) {
|
|
260
|
-
if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {
|
|
261
|
-
updateFallbackSlotVisibility(childNode);
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
};
|
|
265
|
-
function getHostSlotNodes(childNodes, hostName, slotName) {
|
|
266
|
-
let i2 = 0;
|
|
267
|
-
let slottedNodes = [];
|
|
268
|
-
let childNode;
|
|
269
|
-
for (; i2 < childNodes.length; i2++) {
|
|
270
|
-
childNode = childNodes[i2];
|
|
271
|
-
if (childNode["s-sr"] && childNode["s-hn"] === hostName && (slotName === void 0 || childNode["s-sn"] === slotName)) {
|
|
272
|
-
slottedNodes.push(childNode);
|
|
273
|
-
if (typeof slotName !== "undefined") return slottedNodes;
|
|
274
|
-
}
|
|
275
|
-
slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
|
|
276
|
-
}
|
|
277
|
-
return slottedNodes;
|
|
278
|
-
}
|
|
279
|
-
var getHostSlotChildNodes = (node, slotName, includeSlot = true) => {
|
|
280
|
-
const childNodes = [];
|
|
281
|
-
if (includeSlot && node["s-sr"] || !node["s-sr"]) childNodes.push(node);
|
|
282
|
-
while ((node = node.nextSibling) && node["s-sn"] === slotName) {
|
|
283
|
-
childNodes.push(node);
|
|
284
|
-
}
|
|
285
|
-
return childNodes;
|
|
286
|
-
};
|
|
287
|
-
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
288
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
289
|
-
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
290
|
-
return true;
|
|
291
|
-
}
|
|
292
|
-
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
293
|
-
return true;
|
|
294
|
-
}
|
|
295
|
-
return false;
|
|
296
|
-
}
|
|
297
|
-
if (nodeToRelocate["s-sn"] === slotName) {
|
|
298
|
-
return true;
|
|
299
|
-
}
|
|
300
|
-
return slotName === "";
|
|
301
|
-
};
|
|
302
240
|
var createTime = (fnName, tagName = "") => {
|
|
303
241
|
{
|
|
304
242
|
return () => {
|
|
@@ -484,40 +422,13 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
484
422
|
}
|
|
485
423
|
if (!appliedStyles.has(scopeId2)) {
|
|
486
424
|
{
|
|
487
|
-
styleElm =
|
|
425
|
+
styleElm = doc.createElement("style");
|
|
488
426
|
styleElm.innerHTML = style;
|
|
489
427
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
|
490
428
|
if (nonce != null) {
|
|
491
429
|
styleElm.setAttribute("nonce", nonce);
|
|
492
430
|
}
|
|
493
|
-
|
|
494
|
-
if (styleContainerNode.nodeName === "HEAD") {
|
|
495
|
-
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
496
|
-
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
497
|
-
styleContainerNode.insertBefore(
|
|
498
|
-
styleElm,
|
|
499
|
-
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
500
|
-
);
|
|
501
|
-
} else if ("host" in styleContainerNode) {
|
|
502
|
-
if (supportsConstructableStylesheets) {
|
|
503
|
-
const stylesheet = new CSSStyleSheet();
|
|
504
|
-
stylesheet.replaceSync(style);
|
|
505
|
-
styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];
|
|
506
|
-
} else {
|
|
507
|
-
const existingStyleContainer = styleContainerNode.querySelector("style");
|
|
508
|
-
if (existingStyleContainer) {
|
|
509
|
-
existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
|
|
510
|
-
} else {
|
|
511
|
-
styleContainerNode.prepend(styleElm);
|
|
512
|
-
}
|
|
513
|
-
}
|
|
514
|
-
} else {
|
|
515
|
-
styleContainerNode.append(styleElm);
|
|
516
|
-
}
|
|
517
|
-
}
|
|
518
|
-
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
519
|
-
styleContainerNode.insertBefore(styleElm, null);
|
|
520
|
-
}
|
|
431
|
+
styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector("link"));
|
|
521
432
|
}
|
|
522
433
|
if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
|
|
523
434
|
styleElm.innerHTML += SLOT_FB_CSS;
|
|
@@ -540,25 +451,23 @@ var attachStyles = (hostRef) => {
|
|
|
540
451
|
const scopeId2 = addStyle(
|
|
541
452
|
elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(),
|
|
542
453
|
cmpMeta);
|
|
543
|
-
if (
|
|
454
|
+
if (flags & 10 /* needsScopedEncapsulation */) {
|
|
544
455
|
elm["s-sc"] = scopeId2;
|
|
545
456
|
elm.classList.add(scopeId2 + "-h");
|
|
546
457
|
}
|
|
547
458
|
endAttachStyles();
|
|
548
459
|
};
|
|
549
460
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
550
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags
|
|
461
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
551
462
|
if (oldValue !== newValue) {
|
|
552
463
|
let isProp = isMemberInElement(elm, memberName);
|
|
553
464
|
let ln = memberName.toLowerCase();
|
|
554
465
|
if (memberName === "class") {
|
|
555
466
|
const classList = elm.classList;
|
|
556
467
|
const oldClasses = parseClassList(oldValue);
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
561
|
-
}
|
|
468
|
+
const newClasses = parseClassList(newValue);
|
|
469
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
470
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
562
471
|
} else if (memberName === "style") {
|
|
563
472
|
{
|
|
564
473
|
for (const prop in oldValue) {
|
|
@@ -607,13 +516,9 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
607
516
|
if (memberName === "list") {
|
|
608
517
|
isProp = false;
|
|
609
518
|
} else if (oldValue == null || elm[memberName] != n) {
|
|
610
|
-
|
|
611
|
-
elm[memberName] = n;
|
|
612
|
-
} else {
|
|
613
|
-
elm.setAttribute(memberName, n);
|
|
614
|
-
}
|
|
519
|
+
elm[memberName] = n;
|
|
615
520
|
}
|
|
616
|
-
} else
|
|
521
|
+
} else {
|
|
617
522
|
elm[memberName] = newValue;
|
|
618
523
|
}
|
|
619
524
|
} catch (e) {
|
|
@@ -635,44 +540,24 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
635
540
|
}
|
|
636
541
|
};
|
|
637
542
|
var parseClassListRegex = /\s/;
|
|
638
|
-
var parseClassList = (value) =>
|
|
639
|
-
if (typeof value === "object" && value && "baseVal" in value) {
|
|
640
|
-
value = value.baseVal;
|
|
641
|
-
}
|
|
642
|
-
if (!value || typeof value !== "string") {
|
|
643
|
-
return [];
|
|
644
|
-
}
|
|
645
|
-
return value.split(parseClassListRegex);
|
|
646
|
-
};
|
|
543
|
+
var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
|
|
647
544
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
648
545
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
649
546
|
|
|
650
547
|
// src/runtime/vdom/update-element.ts
|
|
651
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2
|
|
548
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
652
549
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
653
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
654
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
550
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
|
|
551
|
+
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
|
655
552
|
{
|
|
656
553
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
657
554
|
if (!(memberName in newVnodeAttrs)) {
|
|
658
|
-
setAccessor(
|
|
659
|
-
elm,
|
|
660
|
-
memberName,
|
|
661
|
-
oldVnodeAttrs[memberName],
|
|
662
|
-
void 0,
|
|
663
|
-
isSvgMode2,
|
|
664
|
-
newVnode.$flags$);
|
|
555
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
|
|
665
556
|
}
|
|
666
557
|
}
|
|
667
558
|
}
|
|
668
559
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
669
|
-
setAccessor(
|
|
670
|
-
elm,
|
|
671
|
-
memberName,
|
|
672
|
-
oldVnodeAttrs[memberName],
|
|
673
|
-
newVnodeAttrs[memberName],
|
|
674
|
-
isSvgMode2,
|
|
675
|
-
newVnode.$flags$);
|
|
560
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
|
|
676
561
|
}
|
|
677
562
|
};
|
|
678
563
|
function sortedAttrNames(attrNames) {
|
|
@@ -684,13 +569,16 @@ function sortedAttrNames(attrNames) {
|
|
|
684
569
|
attrNames
|
|
685
570
|
);
|
|
686
571
|
}
|
|
572
|
+
|
|
573
|
+
// src/runtime/vdom/vdom-render.ts
|
|
574
|
+
var scopeId;
|
|
687
575
|
var contentRef;
|
|
688
576
|
var hostTagName;
|
|
689
577
|
var useNativeShadowDom = false;
|
|
690
578
|
var checkSlotFallbackVisibility = false;
|
|
691
579
|
var checkSlotRelocate = false;
|
|
692
580
|
var isSvgMode = false;
|
|
693
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
581
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
694
582
|
var _a;
|
|
695
583
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
696
584
|
let i2 = 0;
|
|
@@ -700,6 +588,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
700
588
|
if (!useNativeShadowDom) {
|
|
701
589
|
checkSlotRelocate = true;
|
|
702
590
|
if (newVNode2.$tag$ === "slot") {
|
|
591
|
+
if (scopeId) {
|
|
592
|
+
parentElm.classList.add(scopeId + "-s");
|
|
593
|
+
}
|
|
703
594
|
newVNode2.$flags$ |= newVNode2.$children$ ? (
|
|
704
595
|
// slot element has fallback content
|
|
705
596
|
// still create an element that "mocks" the slot element
|
|
@@ -723,9 +614,12 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
723
614
|
{
|
|
724
615
|
updateElement(null, newVNode2, isSvgMode);
|
|
725
616
|
}
|
|
617
|
+
if (isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
618
|
+
elm.classList.add(elm["s-si"] = scopeId);
|
|
619
|
+
}
|
|
726
620
|
if (newVNode2.$children$) {
|
|
727
621
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
728
|
-
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
622
|
+
childNode = createElm(oldParentVNode, newVNode2, i2, elm);
|
|
729
623
|
if (childNode) {
|
|
730
624
|
elm.appendChild(childNode);
|
|
731
625
|
}
|
|
@@ -751,7 +645,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
751
645
|
};
|
|
752
646
|
var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
753
647
|
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
754
|
-
const oldSlotChildNodes = Array.from(parentElm.
|
|
648
|
+
const oldSlotChildNodes = Array.from(parentElm.childNodes);
|
|
755
649
|
if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
|
|
756
650
|
let node = parentElm;
|
|
757
651
|
while (node = node.nextSibling) {
|
|
@@ -763,7 +657,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
|
763
657
|
for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
|
|
764
658
|
const childNode = oldSlotChildNodes[i2];
|
|
765
659
|
if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
|
|
766
|
-
insertBefore(
|
|
660
|
+
insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));
|
|
767
661
|
childNode["s-ol"].remove();
|
|
768
662
|
childNode["s-ol"] = void 0;
|
|
769
663
|
childNode["s-sh"] = void 0;
|
|
@@ -783,7 +677,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
|
783
677
|
}
|
|
784
678
|
for (; startIdx <= endIdx; ++startIdx) {
|
|
785
679
|
if (vnodes[startIdx]) {
|
|
786
|
-
childNode = createElm(null, parentVNode, startIdx);
|
|
680
|
+
childNode = createElm(null, parentVNode, startIdx, parentElm);
|
|
787
681
|
if (childNode) {
|
|
788
682
|
vnodes[startIdx].$elm$ = childNode;
|
|
789
683
|
insertBefore(containerElm, childNode, referenceNode(before) );
|
|
@@ -869,7 +763,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
869
763
|
if (idxInOld >= 0) {
|
|
870
764
|
elmToMove = oldCh[idxInOld];
|
|
871
765
|
if (elmToMove.$tag$ !== newStartVnode.$tag$) {
|
|
872
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
|
|
766
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld, parentElm);
|
|
873
767
|
} else {
|
|
874
768
|
patch(elmToMove, newStartVnode, isInitialRender);
|
|
875
769
|
oldCh[idxInOld] = void 0;
|
|
@@ -877,16 +771,12 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
877
771
|
}
|
|
878
772
|
newStartVnode = newCh[++newStartIdx];
|
|
879
773
|
} else {
|
|
880
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
|
|
774
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx, parentElm);
|
|
881
775
|
newStartVnode = newCh[++newStartIdx];
|
|
882
776
|
}
|
|
883
777
|
if (node) {
|
|
884
778
|
{
|
|
885
|
-
insertBefore(
|
|
886
|
-
referenceNode(oldStartVnode.$elm$).parentNode,
|
|
887
|
-
node,
|
|
888
|
-
referenceNode(oldStartVnode.$elm$)
|
|
889
|
-
);
|
|
779
|
+
insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));
|
|
890
780
|
}
|
|
891
781
|
}
|
|
892
782
|
}
|
|
@@ -912,14 +802,14 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
912
802
|
if (!isInitialRender) {
|
|
913
803
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
914
804
|
}
|
|
915
|
-
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
916
|
-
leftVNode.$key$ = rightVNode.$key$;
|
|
917
|
-
}
|
|
918
805
|
return true;
|
|
919
806
|
}
|
|
920
807
|
return false;
|
|
921
808
|
};
|
|
922
|
-
var referenceNode = (node) =>
|
|
809
|
+
var referenceNode = (node) => {
|
|
810
|
+
return node && node["s-ol"] || node;
|
|
811
|
+
};
|
|
812
|
+
var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
|
|
923
813
|
var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
924
814
|
const elm = newVNode2.$elm$ = oldVNode.$elm$;
|
|
925
815
|
const oldChildren = oldVNode.$children$;
|
|
@@ -940,10 +830,7 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
940
830
|
elm.textContent = "";
|
|
941
831
|
}
|
|
942
832
|
addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);
|
|
943
|
-
} else if (
|
|
944
|
-
// don't do this on initial render as it can cause non-hydrated content to be removed
|
|
945
|
-
!isInitialRender && BUILD.updatable && oldChildren !== null
|
|
946
|
-
) {
|
|
833
|
+
} else if (oldChildren !== null) {
|
|
947
834
|
removeVnodes(oldChildren, 0, oldChildren.length - 1);
|
|
948
835
|
}
|
|
949
836
|
} else if ((defaultHolder = elm["s-cr"])) {
|
|
@@ -952,15 +839,41 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
952
839
|
elm.data = text;
|
|
953
840
|
}
|
|
954
841
|
};
|
|
842
|
+
var updateFallbackSlotVisibility = (elm) => {
|
|
843
|
+
const childNodes = elm.childNodes;
|
|
844
|
+
for (const childNode of childNodes) {
|
|
845
|
+
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
846
|
+
if (childNode["s-sr"]) {
|
|
847
|
+
const slotName = childNode["s-sn"];
|
|
848
|
+
childNode.hidden = false;
|
|
849
|
+
for (const siblingNode of childNodes) {
|
|
850
|
+
if (siblingNode !== childNode) {
|
|
851
|
+
if (siblingNode["s-hn"] !== childNode["s-hn"] || slotName !== "") {
|
|
852
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute("slot") || slotName === siblingNode["s-sn"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode["s-sn"]) {
|
|
853
|
+
childNode.hidden = true;
|
|
854
|
+
break;
|
|
855
|
+
}
|
|
856
|
+
} else {
|
|
857
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== "") {
|
|
858
|
+
childNode.hidden = true;
|
|
859
|
+
break;
|
|
860
|
+
}
|
|
861
|
+
}
|
|
862
|
+
}
|
|
863
|
+
}
|
|
864
|
+
}
|
|
865
|
+
updateFallbackSlotVisibility(childNode);
|
|
866
|
+
}
|
|
867
|
+
}
|
|
868
|
+
};
|
|
955
869
|
var relocateNodes = [];
|
|
956
870
|
var markSlotContentForRelocation = (elm) => {
|
|
957
871
|
let node;
|
|
958
872
|
let hostContentNodes;
|
|
959
873
|
let j;
|
|
960
|
-
const
|
|
961
|
-
for (const childNode of children) {
|
|
874
|
+
for (const childNode of elm.childNodes) {
|
|
962
875
|
if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
|
|
963
|
-
hostContentNodes = node.parentNode.
|
|
876
|
+
hostContentNodes = node.parentNode.childNodes;
|
|
964
877
|
const slotName = childNode["s-sn"];
|
|
965
878
|
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
|
966
879
|
node = hostContentNodes[j];
|
|
@@ -1002,10 +915,24 @@ var markSlotContentForRelocation = (elm) => {
|
|
|
1002
915
|
}
|
|
1003
916
|
}
|
|
1004
917
|
};
|
|
1005
|
-
var
|
|
1006
|
-
{
|
|
1007
|
-
|
|
918
|
+
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
919
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
920
|
+
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
921
|
+
return true;
|
|
922
|
+
}
|
|
923
|
+
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
924
|
+
return true;
|
|
925
|
+
}
|
|
926
|
+
return false;
|
|
1008
927
|
}
|
|
928
|
+
if (nodeToRelocate["s-sn"] === slotName) {
|
|
929
|
+
return true;
|
|
930
|
+
}
|
|
931
|
+
return slotName === "";
|
|
932
|
+
};
|
|
933
|
+
var insertBefore = (parent, newNode, reference) => {
|
|
934
|
+
const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
935
|
+
return inserted;
|
|
1009
936
|
};
|
|
1010
937
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1011
938
|
var _a, _b, _c, _d;
|
|
@@ -1031,7 +958,10 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1031
958
|
rootVnode.$flags$ |= 4 /* isHost */;
|
|
1032
959
|
hostRef.$vnode$ = rootVnode;
|
|
1033
960
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
1034
|
-
|
|
961
|
+
{
|
|
962
|
+
scopeId = hostElm["s-sc"];
|
|
963
|
+
}
|
|
964
|
+
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
1035
965
|
{
|
|
1036
966
|
contentRef = hostElm["s-cr"];
|
|
1037
967
|
checkSlotFallbackVisibility = false;
|
|
@@ -1059,7 +989,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1059
989
|
let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
|
|
1060
990
|
while (orgLocationNode) {
|
|
1061
991
|
let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
|
|
1062
|
-
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef ===
|
|
992
|
+
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
|
|
1063
993
|
refNode = refNode.nextSibling;
|
|
1064
994
|
while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
|
|
1065
995
|
refNode = refNode == null ? void 0 : refNode.nextSibling;
|
|
@@ -1072,15 +1002,13 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1072
1002
|
orgLocationNode = orgLocationNode.previousSibling;
|
|
1073
1003
|
}
|
|
1074
1004
|
}
|
|
1075
|
-
|
|
1076
|
-
const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
|
|
1077
|
-
if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
|
|
1005
|
+
if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {
|
|
1078
1006
|
if (nodeToRelocate !== insertBeforeNode) {
|
|
1079
1007
|
if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
|
|
1080
1008
|
nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
|
|
1081
1009
|
}
|
|
1082
1010
|
insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
|
|
1083
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */
|
|
1011
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
1084
1012
|
nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
|
|
1085
1013
|
}
|
|
1086
1014
|
}
|
|
@@ -1108,14 +1036,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1108
1036
|
// src/runtime/update-component.ts
|
|
1109
1037
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
1110
1038
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
1111
|
-
|
|
1112
|
-
new Promise(
|
|
1113
|
-
(r) => hostRef.$onRenderResolve$ = () => {
|
|
1114
|
-
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
1115
|
-
r();
|
|
1116
|
-
}
|
|
1117
|
-
)
|
|
1118
|
-
);
|
|
1039
|
+
ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
|
|
1119
1040
|
}
|
|
1120
1041
|
};
|
|
1121
1042
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -1144,12 +1065,12 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
1144
1065
|
{
|
|
1145
1066
|
hostRef.$flags$ |= 256 /* isListenReady */;
|
|
1146
1067
|
if (hostRef.$queuedListeners$) {
|
|
1147
|
-
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event
|
|
1068
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
|
|
1148
1069
|
hostRef.$queuedListeners$ = void 0;
|
|
1149
1070
|
}
|
|
1150
1071
|
}
|
|
1151
1072
|
{
|
|
1152
|
-
maybePromise = safeCall(instance, "componentWillLoad"
|
|
1073
|
+
maybePromise = safeCall(instance, "componentWillLoad");
|
|
1153
1074
|
}
|
|
1154
1075
|
}
|
|
1155
1076
|
endSchedule();
|
|
@@ -1218,7 +1139,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1218
1139
|
const instance = hostRef.$lazyInstance$ ;
|
|
1219
1140
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
|
1220
1141
|
{
|
|
1221
|
-
safeCall(instance, "componentDidRender"
|
|
1142
|
+
safeCall(instance, "componentDidRender");
|
|
1222
1143
|
}
|
|
1223
1144
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
|
1224
1145
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
|
@@ -1247,14 +1168,17 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1247
1168
|
}
|
|
1248
1169
|
};
|
|
1249
1170
|
var appDidLoad = (who) => {
|
|
1171
|
+
{
|
|
1172
|
+
addHydratedFlag(doc.documentElement);
|
|
1173
|
+
}
|
|
1250
1174
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
1251
1175
|
};
|
|
1252
|
-
var safeCall = (instance, method, arg
|
|
1176
|
+
var safeCall = (instance, method, arg) => {
|
|
1253
1177
|
if (instance && instance[method]) {
|
|
1254
1178
|
try {
|
|
1255
1179
|
return instance[method](arg);
|
|
1256
1180
|
} catch (e) {
|
|
1257
|
-
consoleError(e
|
|
1181
|
+
consoleError(e);
|
|
1258
1182
|
}
|
|
1259
1183
|
}
|
|
1260
1184
|
return void 0;
|
|
@@ -1313,68 +1237,15 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1313
1237
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
1314
1238
|
members.map(([memberName, [memberFlags]]) => {
|
|
1315
1239
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
1316
|
-
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
1317
|
-
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
1318
|
-
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
1319
|
-
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
1320
|
-
Object.defineProperty(prototype, memberName, {
|
|
1321
|
-
get() {
|
|
1322
|
-
{
|
|
1323
|
-
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
1324
|
-
return getValue(this, memberName);
|
|
1325
|
-
}
|
|
1326
|
-
const ref = getHostRef(this);
|
|
1327
|
-
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
1328
|
-
if (!instance) return;
|
|
1329
|
-
return instance[memberName];
|
|
1330
|
-
}
|
|
1331
|
-
},
|
|
1332
|
-
configurable: true,
|
|
1333
|
-
enumerable: true
|
|
1334
|
-
});
|
|
1335
|
-
}
|
|
1336
1240
|
Object.defineProperty(prototype, memberName, {
|
|
1241
|
+
get() {
|
|
1242
|
+
return getValue(this, memberName);
|
|
1243
|
+
},
|
|
1337
1244
|
set(newValue) {
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
newValue = ref.$instanceValues$.get(memberName);
|
|
1343
|
-
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1344
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1345
|
-
}
|
|
1346
|
-
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
1347
|
-
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
1348
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
1349
|
-
return;
|
|
1350
|
-
}
|
|
1351
|
-
{
|
|
1352
|
-
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
1353
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
1354
|
-
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
1355
|
-
ref.$onReadyPromise$.then(() => {
|
|
1356
|
-
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
1357
|
-
ref.$lazyInstance$[memberName] = newValue;
|
|
1358
|
-
}
|
|
1359
|
-
});
|
|
1360
|
-
}
|
|
1361
|
-
return;
|
|
1362
|
-
}
|
|
1363
|
-
const setterSetVal = () => {
|
|
1364
|
-
const currentValue = ref.$lazyInstance$[memberName];
|
|
1365
|
-
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1366
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1367
|
-
}
|
|
1368
|
-
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
1369
|
-
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
1370
|
-
};
|
|
1371
|
-
if (ref.$lazyInstance$) {
|
|
1372
|
-
setterSetVal();
|
|
1373
|
-
} else {
|
|
1374
|
-
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
1375
|
-
}
|
|
1376
|
-
}
|
|
1377
|
-
}
|
|
1245
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1246
|
+
},
|
|
1247
|
+
configurable: true,
|
|
1248
|
+
enumerable: true
|
|
1378
1249
|
});
|
|
1379
1250
|
}
|
|
1380
1251
|
});
|
|
@@ -1384,11 +1255,10 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1384
1255
|
plt.jmp(() => {
|
|
1385
1256
|
var _a2;
|
|
1386
1257
|
const propName = attrNameToPropName.get(attrName);
|
|
1387
|
-
if (this.hasOwnProperty(propName)
|
|
1258
|
+
if (this.hasOwnProperty(propName)) {
|
|
1388
1259
|
newValue = this[propName];
|
|
1389
1260
|
delete this[propName];
|
|
1390
|
-
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" &&
|
|
1391
|
-
this[propName] == newValue) {
|
|
1261
|
+
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && this[propName] == newValue) {
|
|
1392
1262
|
return;
|
|
1393
1263
|
} else if (propName == null) {
|
|
1394
1264
|
const hostRef = getHostRef(this);
|
|
@@ -1404,11 +1274,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1404
1274
|
}
|
|
1405
1275
|
return;
|
|
1406
1276
|
}
|
|
1407
|
-
|
|
1408
|
-
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1409
|
-
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
1410
|
-
this[propName] = newValue;
|
|
1411
|
-
}
|
|
1277
|
+
this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1412
1278
|
});
|
|
1413
1279
|
};
|
|
1414
1280
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1437,7 +1303,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1437
1303
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1438
1304
|
const bundleId = cmpMeta.$lazyBundleId$;
|
|
1439
1305
|
if (bundleId) {
|
|
1440
|
-
const CstrImport = loadModule(cmpMeta
|
|
1306
|
+
const CstrImport = loadModule(cmpMeta);
|
|
1441
1307
|
if (CstrImport && "then" in CstrImport) {
|
|
1442
1308
|
const endLoad = uniqueTime();
|
|
1443
1309
|
Cstr = await CstrImport;
|
|
@@ -1462,7 +1328,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1462
1328
|
try {
|
|
1463
1329
|
new Cstr(hostRef);
|
|
1464
1330
|
} catch (e) {
|
|
1465
|
-
consoleError(e
|
|
1331
|
+
consoleError(e);
|
|
1466
1332
|
}
|
|
1467
1333
|
{
|
|
1468
1334
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
|
@@ -1497,7 +1363,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1497
1363
|
schedule();
|
|
1498
1364
|
}
|
|
1499
1365
|
};
|
|
1500
|
-
var fireConnectedCallback = (instance
|
|
1366
|
+
var fireConnectedCallback = (instance) => {
|
|
1501
1367
|
};
|
|
1502
1368
|
|
|
1503
1369
|
// src/runtime/connected-callback.ts
|
|
@@ -1551,7 +1417,7 @@ var setContentReference = (elm) => {
|
|
|
1551
1417
|
contentRefElm["s-cn"] = true;
|
|
1552
1418
|
insertBefore(elm, contentRefElm, elm.firstChild);
|
|
1553
1419
|
};
|
|
1554
|
-
var disconnectInstance = (instance
|
|
1420
|
+
var disconnectInstance = (instance) => {
|
|
1555
1421
|
};
|
|
1556
1422
|
var disconnectedCallback = async (elm) => {
|
|
1557
1423
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
@@ -1566,12 +1432,6 @@ var disconnectedCallback = async (elm) => {
|
|
|
1566
1432
|
hostRef.$onReadyPromise$.then(() => disconnectInstance());
|
|
1567
1433
|
}
|
|
1568
1434
|
}
|
|
1569
|
-
if (rootAppliedStyles.has(elm)) {
|
|
1570
|
-
rootAppliedStyles.delete(elm);
|
|
1571
|
-
}
|
|
1572
|
-
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
1573
|
-
rootAppliedStyles.delete(elm.shadowRoot);
|
|
1574
|
-
}
|
|
1575
1435
|
};
|
|
1576
1436
|
|
|
1577
1437
|
// src/runtime/bootstrap-lazy.ts
|
|
@@ -1656,17 +1516,6 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1656
1516
|
}
|
|
1657
1517
|
disconnectedCallback() {
|
|
1658
1518
|
plt.jmp(() => disconnectedCallback(this));
|
|
1659
|
-
plt.raf(() => {
|
|
1660
|
-
var _a3;
|
|
1661
|
-
const hostRef = getHostRef(this);
|
|
1662
|
-
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
|
1663
|
-
if (i2 > -1) {
|
|
1664
|
-
deferredConnectedCallbacks.splice(i2, 1);
|
|
1665
|
-
}
|
|
1666
|
-
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
1667
|
-
delete hostRef.$vnode$.$elm$;
|
|
1668
|
-
}
|
|
1669
|
-
});
|
|
1670
1519
|
}
|
|
1671
1520
|
componentOnReady() {
|
|
1672
1521
|
return getHostRef(this).$onReadyPromise$;
|
|
@@ -1733,7 +1582,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
|
1733
1582
|
}
|
|
1734
1583
|
}
|
|
1735
1584
|
} catch (e) {
|
|
1736
|
-
consoleError(e
|
|
1585
|
+
consoleError(e);
|
|
1737
1586
|
}
|
|
1738
1587
|
};
|
|
1739
1588
|
var getHostListenerTarget = (elm, flags) => {
|