@everymatrix/casino-game-thumb-view 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-game-thumb-view/casino-game-thumb-view.esm.js +1 -1
- package/dist/casino-game-thumb-view/{p-600af885.entry.js → p-0f03c743.entry.js} +1 -1
- package/dist/casino-game-thumb-view/p-358a4af8.entry.js +7 -0
- package/dist/casino-game-thumb-view/p-4ece4698.js +8 -0
- package/dist/casino-game-thumb-view/p-74a4ae4a.entry.js +1 -0
- package/dist/casino-game-thumb-view/p-a0c26052.entry.js +1 -0
- package/dist/casino-game-thumb-view/p-b5a64db5.js +2 -0
- package/dist/casino-game-thumb-view/p-d6ec6d6a.entry.js +1 -0
- package/dist/casino-game-thumb-view/p-fd38189d.entry.js +1 -0
- package/dist/cjs/casino-extrainfo-baccarat.cjs.entry.js +5 -1
- package/dist/cjs/casino-extrainfo-blackjack.cjs.entry.js +6 -1
- package/dist/cjs/casino-extrainfo-roulette.cjs.entry.js +4 -4
- package/dist/cjs/casino-game-thumb-view.cjs.js +2 -2
- package/dist/cjs/casino-game-thumb-view_2.cjs.entry.js +41 -52
- package/dist/cjs/casino-game-thumbnail-betlimit_2.cjs.entry.js +8 -3
- package/dist/cjs/casino-normal-game-thumbnail.cjs.entry.js +2 -1
- package/dist/cjs/{index-b36c6933.js → index-81c5b70d.js} +136 -289
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{utils-c4ed3adc.js → utils-21e506f8.js} +365 -368
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/casino-extrainfo-baccarat/casino-extrainfo-baccarat.js +4 -4
- package/dist/collection/components/casino-extrainfo-blackjack/casino-extrainfo-blackjack.js +7 -2
- package/dist/collection/components/casino-extrainfo-roulette/casino-extrainfo-roulette.js +3 -5
- package/dist/collection/components/casino-game-thumb-view/casino-game-thumb-view.js +33 -99
- package/dist/collection/components/casino-game-thumbnail-betlimit/casino-game-thumbnail-betlimit.js +3 -5
- package/dist/collection/components/casino-game-thumbnail-extrainfo/casino-game-thumbnail-extrainfo.js +4 -3
- package/dist/collection/components/casino-game-thumbnail-overlay/casino-game-thumbnail-overlay.js +6 -27
- package/dist/collection/components/casino-normal-game-thumbnail/casino-normal-game-thumbnail.js +3 -2
- package/dist/esm/casino-extrainfo-baccarat.entry.js +5 -1
- package/dist/esm/casino-extrainfo-blackjack.entry.js +6 -1
- package/dist/esm/casino-extrainfo-roulette.entry.js +4 -4
- package/dist/esm/casino-game-thumb-view.js +3 -3
- package/dist/esm/casino-game-thumb-view_2.entry.js +41 -52
- package/dist/esm/casino-game-thumbnail-betlimit_2.entry.js +8 -3
- package/dist/esm/casino-normal-game-thumbnail.entry.js +2 -1
- package/dist/esm/{index-23b4a4c5.js → index-8058a16f.js} +136 -289
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{utils-090ac2e9.js → utils-d11d0845.js} +365 -368
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/casino-game-thumb-view/.stencil/packages/stencil/casino-game-thumb-view/stencil.config.d.ts +2 -0
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/casino-game-thumb-view/.stencil/packages/stencil/casino-game-thumb-view/stencil.config.dev.d.ts +2 -0
- package/dist/types/stencil-public-runtime.d.ts +0 -6
- package/package.json +1 -1
- package/dist/casino-game-thumb-view/p-13741d4d.js +0 -2
- package/dist/casino-game-thumb-view/p-53ba085b.entry.js +0 -1
- package/dist/casino-game-thumb-view/p-b13b5c25.entry.js +0 -1
- package/dist/casino-game-thumb-view/p-c6ee2783.entry.js +0 -1
- package/dist/casino-game-thumb-view/p-d2580653.js +0 -8
- package/dist/casino-game-thumb-view/p-dd797f50.entry.js +0 -7
- package/dist/casino-game-thumb-view/p-ee2bdcce.entry.js +0 -1
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-game-thumb-view/.stencil/packages/stencil/casino-game-thumb-view/stencil.config.d.ts +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-game-thumb-view/.stencil/packages/stencil/casino-game-thumb-view/stencil.config.dev.d.ts +0 -2
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-game-thumb-view/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-game-thumb-view/.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-game-thumb-view/.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-game-thumb-view/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
@@ -1,25 +1,17 @@
|
|
1
1
|
const NAMESPACE = 'casino-game-thumb-view';
|
2
|
-
const BUILD = /* casino-game-thumb-view */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: false, 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: true, hostListenerTargetParent: false, hostListenerTargetWindow: false, 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: true, mode: false,
|
2
|
+
const BUILD = /* casino-game-thumb-view */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: false, 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: true, hostListenerTargetParent: false, hostListenerTargetWindow: false, 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: true, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: false, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: true, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: true, 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/utils/constants.ts
|
14
|
-
var SVG_NS = "http://www.w3.org/2000/svg";
|
15
|
-
var HTML_NS = "http://www.w3.org/1999/xhtml";
|
16
|
-
|
17
|
-
// src/client/client-host-ref.ts
|
18
12
|
var hostRefs = /* @__PURE__ */ new WeakMap();
|
19
13
|
var getHostRef = (ref) => hostRefs.get(ref);
|
20
|
-
var registerInstance = (lazyInstance, hostRef) =>
|
21
|
-
hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
22
|
-
};
|
14
|
+
var registerInstance = (lazyInstance, hostRef) => hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
23
15
|
var registerHost = (hostElement, cmpMeta) => {
|
24
16
|
const hostRef = {
|
25
17
|
$flags$: 0,
|
@@ -35,8 +27,7 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
35
27
|
hostElement["s-p"] = [];
|
36
28
|
hostElement["s-rc"] = [];
|
37
29
|
}
|
38
|
-
|
39
|
-
return ref;
|
30
|
+
return hostRefs.set(hostElement, hostRef);
|
40
31
|
};
|
41
32
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
42
33
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
@@ -93,22 +84,16 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
93
84
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
94
85
|
/* webpackMode: "lazy" */
|
95
86
|
`./${bundleId}.entry.js${""}`
|
96
|
-
).then(
|
97
|
-
|
98
|
-
|
99
|
-
cmpModules.set(bundleId, importedModule);
|
100
|
-
}
|
101
|
-
return importedModule[exportName];
|
102
|
-
},
|
103
|
-
(e) => {
|
104
|
-
consoleError(e, hostRef.$hostElement$);
|
87
|
+
).then((importedModule) => {
|
88
|
+
{
|
89
|
+
cmpModules.set(bundleId, importedModule);
|
105
90
|
}
|
106
|
-
|
91
|
+
return importedModule[exportName];
|
92
|
+
}, consoleError);
|
107
93
|
};
|
108
94
|
|
109
95
|
// src/client/client-style.ts
|
110
96
|
var styles = /* @__PURE__ */ new Map();
|
111
|
-
var HYDRATED_STYLE_ID = "sty-id";
|
112
97
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
113
98
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
114
99
|
var XLINK_NS = "http://www.w3.org/1999/xlink";
|
@@ -183,6 +168,14 @@ var flush = () => {
|
|
183
168
|
};
|
184
169
|
var nextTick = (cb) => promiseResolve().then(cb);
|
185
170
|
var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
|
171
|
+
|
172
|
+
// src/utils/constants.ts
|
173
|
+
var EMPTY_OBJ = {};
|
174
|
+
var SVG_NS = "http://www.w3.org/2000/svg";
|
175
|
+
var HTML_NS = "http://www.w3.org/1999/xhtml";
|
176
|
+
|
177
|
+
// src/utils/helpers.ts
|
178
|
+
var isDef = (v) => v != null;
|
186
179
|
var isComplexType = (o) => {
|
187
180
|
o = typeof o;
|
188
181
|
return o === "object" || o === "function";
|
@@ -242,63 +235,6 @@ var unwrapErr = (result) => {
|
|
242
235
|
throw result.value;
|
243
236
|
}
|
244
237
|
};
|
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
238
|
var createTime = (fnName, tagName = "") => {
|
303
239
|
{
|
304
240
|
return () => {
|
@@ -490,40 +426,13 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
490
426
|
}
|
491
427
|
if (!appliedStyles.has(scopeId2)) {
|
492
428
|
{
|
493
|
-
styleElm =
|
429
|
+
styleElm = doc.createElement("style");
|
494
430
|
styleElm.innerHTML = style;
|
495
431
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
496
432
|
if (nonce != null) {
|
497
433
|
styleElm.setAttribute("nonce", nonce);
|
498
434
|
}
|
499
|
-
|
500
|
-
if (styleContainerNode.nodeName === "HEAD") {
|
501
|
-
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
502
|
-
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
503
|
-
styleContainerNode.insertBefore(
|
504
|
-
styleElm,
|
505
|
-
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
506
|
-
);
|
507
|
-
} else if ("host" in styleContainerNode) {
|
508
|
-
if (supportsConstructableStylesheets) {
|
509
|
-
const stylesheet = new CSSStyleSheet();
|
510
|
-
stylesheet.replaceSync(style);
|
511
|
-
styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];
|
512
|
-
} else {
|
513
|
-
const existingStyleContainer = styleContainerNode.querySelector("style");
|
514
|
-
if (existingStyleContainer) {
|
515
|
-
existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
|
516
|
-
} else {
|
517
|
-
styleContainerNode.prepend(styleElm);
|
518
|
-
}
|
519
|
-
}
|
520
|
-
} else {
|
521
|
-
styleContainerNode.append(styleElm);
|
522
|
-
}
|
523
|
-
}
|
524
|
-
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
525
|
-
styleContainerNode.insertBefore(styleElm, null);
|
526
|
-
}
|
435
|
+
styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector("link"));
|
527
436
|
}
|
528
437
|
if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
|
529
438
|
styleElm.innerHTML += SLOT_FB_CSS;
|
@@ -546,25 +455,23 @@ var attachStyles = (hostRef) => {
|
|
546
455
|
const scopeId2 = addStyle(
|
547
456
|
elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(),
|
548
457
|
cmpMeta);
|
549
|
-
if (
|
458
|
+
if (flags & 10 /* needsScopedEncapsulation */) {
|
550
459
|
elm["s-sc"] = scopeId2;
|
551
460
|
elm.classList.add(scopeId2 + "-h");
|
552
461
|
}
|
553
462
|
endAttachStyles();
|
554
463
|
};
|
555
464
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
556
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags
|
465
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
557
466
|
if (oldValue !== newValue) {
|
558
467
|
let isProp = isMemberInElement(elm, memberName);
|
559
468
|
let ln = memberName.toLowerCase();
|
560
469
|
if (memberName === "class") {
|
561
470
|
const classList = elm.classList;
|
562
471
|
const oldClasses = parseClassList(oldValue);
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
567
|
-
}
|
472
|
+
const newClasses = parseClassList(newValue);
|
473
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
474
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
568
475
|
} else if (memberName === "style") {
|
569
476
|
{
|
570
477
|
for (const prop in oldValue) {
|
@@ -617,13 +524,9 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
617
524
|
if (memberName === "list") {
|
618
525
|
isProp = false;
|
619
526
|
} else if (oldValue == null || elm[memberName] != n) {
|
620
|
-
|
621
|
-
elm[memberName] = n;
|
622
|
-
} else {
|
623
|
-
elm.setAttribute(memberName, n);
|
624
|
-
}
|
527
|
+
elm[memberName] = n;
|
625
528
|
}
|
626
|
-
} else
|
529
|
+
} else {
|
627
530
|
elm[memberName] = newValue;
|
628
531
|
}
|
629
532
|
} catch (e) {
|
@@ -656,44 +559,24 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
656
559
|
}
|
657
560
|
};
|
658
561
|
var parseClassListRegex = /\s/;
|
659
|
-
var parseClassList = (value) =>
|
660
|
-
if (typeof value === "object" && value && "baseVal" in value) {
|
661
|
-
value = value.baseVal;
|
662
|
-
}
|
663
|
-
if (!value || typeof value !== "string") {
|
664
|
-
return [];
|
665
|
-
}
|
666
|
-
return value.split(parseClassListRegex);
|
667
|
-
};
|
562
|
+
var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
|
668
563
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
669
564
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
670
565
|
|
671
566
|
// src/runtime/vdom/update-element.ts
|
672
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2
|
567
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
673
568
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
674
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
675
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
569
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
|
570
|
+
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
676
571
|
{
|
677
572
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
678
573
|
if (!(memberName in newVnodeAttrs)) {
|
679
|
-
setAccessor(
|
680
|
-
elm,
|
681
|
-
memberName,
|
682
|
-
oldVnodeAttrs[memberName],
|
683
|
-
void 0,
|
684
|
-
isSvgMode2,
|
685
|
-
newVnode.$flags$);
|
574
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
|
686
575
|
}
|
687
576
|
}
|
688
577
|
}
|
689
578
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
690
|
-
setAccessor(
|
691
|
-
elm,
|
692
|
-
memberName,
|
693
|
-
oldVnodeAttrs[memberName],
|
694
|
-
newVnodeAttrs[memberName],
|
695
|
-
isSvgMode2,
|
696
|
-
newVnode.$flags$);
|
579
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
|
697
580
|
}
|
698
581
|
};
|
699
582
|
function sortedAttrNames(attrNames) {
|
@@ -705,13 +588,16 @@ function sortedAttrNames(attrNames) {
|
|
705
588
|
attrNames
|
706
589
|
);
|
707
590
|
}
|
591
|
+
|
592
|
+
// src/runtime/vdom/vdom-render.ts
|
593
|
+
var scopeId;
|
708
594
|
var contentRef;
|
709
595
|
var hostTagName;
|
710
596
|
var useNativeShadowDom = false;
|
711
597
|
var checkSlotFallbackVisibility = false;
|
712
598
|
var checkSlotRelocate = false;
|
713
599
|
var isSvgMode = false;
|
714
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
600
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
715
601
|
var _a;
|
716
602
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
717
603
|
let i2 = 0;
|
@@ -721,6 +607,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
721
607
|
if (!useNativeShadowDom) {
|
722
608
|
checkSlotRelocate = true;
|
723
609
|
if (newVNode2.$tag$ === "slot") {
|
610
|
+
if (scopeId) {
|
611
|
+
parentElm.classList.add(scopeId + "-s");
|
612
|
+
}
|
724
613
|
newVNode2.$flags$ |= newVNode2.$children$ ? (
|
725
614
|
// slot element has fallback content
|
726
615
|
// still create an element that "mocks" the slot element
|
@@ -751,9 +640,12 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
751
640
|
{
|
752
641
|
updateElement(null, newVNode2, isSvgMode);
|
753
642
|
}
|
643
|
+
if (isDef(scopeId) && elm["s-si"] !== scopeId) {
|
644
|
+
elm.classList.add(elm["s-si"] = scopeId);
|
645
|
+
}
|
754
646
|
if (newVNode2.$children$) {
|
755
647
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
756
|
-
childNode = createElm(oldParentVNode, newVNode2, i2);
|
648
|
+
childNode = createElm(oldParentVNode, newVNode2, i2, elm);
|
757
649
|
if (childNode) {
|
758
650
|
elm.appendChild(childNode);
|
759
651
|
}
|
@@ -786,7 +678,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
786
678
|
};
|
787
679
|
var putBackInOriginalLocation = (parentElm, recursive) => {
|
788
680
|
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
789
|
-
const oldSlotChildNodes = Array.from(parentElm.
|
681
|
+
const oldSlotChildNodes = Array.from(parentElm.childNodes);
|
790
682
|
if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
|
791
683
|
let node = parentElm;
|
792
684
|
while (node = node.nextSibling) {
|
@@ -798,7 +690,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
798
690
|
for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
|
799
691
|
const childNode = oldSlotChildNodes[i2];
|
800
692
|
if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
|
801
|
-
insertBefore(
|
693
|
+
insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));
|
802
694
|
childNode["s-ol"].remove();
|
803
695
|
childNode["s-ol"] = void 0;
|
804
696
|
childNode["s-sh"] = void 0;
|
@@ -818,7 +710,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
818
710
|
}
|
819
711
|
for (; startIdx <= endIdx; ++startIdx) {
|
820
712
|
if (vnodes[startIdx]) {
|
821
|
-
childNode = createElm(null, parentVNode, startIdx);
|
713
|
+
childNode = createElm(null, parentVNode, startIdx, parentElm);
|
822
714
|
if (childNode) {
|
823
715
|
vnodes[startIdx].$elm$ = childNode;
|
824
716
|
insertBefore(containerElm, childNode, referenceNode(before) );
|
@@ -905,7 +797,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
905
797
|
if (idxInOld >= 0) {
|
906
798
|
elmToMove = oldCh[idxInOld];
|
907
799
|
if (elmToMove.$tag$ !== newStartVnode.$tag$) {
|
908
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
|
800
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld, parentElm);
|
909
801
|
} else {
|
910
802
|
patch(elmToMove, newStartVnode, isInitialRender);
|
911
803
|
oldCh[idxInOld] = void 0;
|
@@ -913,16 +805,12 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
913
805
|
}
|
914
806
|
newStartVnode = newCh[++newStartIdx];
|
915
807
|
} else {
|
916
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
|
808
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx, parentElm);
|
917
809
|
newStartVnode = newCh[++newStartIdx];
|
918
810
|
}
|
919
811
|
if (node) {
|
920
812
|
{
|
921
|
-
insertBefore(
|
922
|
-
referenceNode(oldStartVnode.$elm$).parentNode,
|
923
|
-
node,
|
924
|
-
referenceNode(oldStartVnode.$elm$)
|
925
|
-
);
|
813
|
+
insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));
|
926
814
|
}
|
927
815
|
}
|
928
816
|
}
|
@@ -948,14 +836,14 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
948
836
|
if (!isInitialRender) {
|
949
837
|
return leftVNode.$key$ === rightVNode.$key$;
|
950
838
|
}
|
951
|
-
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
952
|
-
leftVNode.$key$ = rightVNode.$key$;
|
953
|
-
}
|
954
839
|
return true;
|
955
840
|
}
|
956
841
|
return false;
|
957
842
|
};
|
958
|
-
var referenceNode = (node) =>
|
843
|
+
var referenceNode = (node) => {
|
844
|
+
return node && node["s-ol"] || node;
|
845
|
+
};
|
846
|
+
var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
|
959
847
|
var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
960
848
|
const elm = newVNode2.$elm$ = oldVNode.$elm$;
|
961
849
|
const oldChildren = oldVNode.$children$;
|
@@ -979,10 +867,7 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
979
867
|
elm.textContent = "";
|
980
868
|
}
|
981
869
|
addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);
|
982
|
-
} else if (
|
983
|
-
// don't do this on initial render as it can cause non-hydrated content to be removed
|
984
|
-
!isInitialRender && BUILD.updatable && oldChildren !== null
|
985
|
-
) {
|
870
|
+
} else if (oldChildren !== null) {
|
986
871
|
removeVnodes(oldChildren, 0, oldChildren.length - 1);
|
987
872
|
}
|
988
873
|
if (isSvgMode && tag === "svg") {
|
@@ -994,15 +879,41 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
994
879
|
elm.data = text;
|
995
880
|
}
|
996
881
|
};
|
882
|
+
var updateFallbackSlotVisibility = (elm) => {
|
883
|
+
const childNodes = elm.childNodes;
|
884
|
+
for (const childNode of childNodes) {
|
885
|
+
if (childNode.nodeType === 1 /* ElementNode */) {
|
886
|
+
if (childNode["s-sr"]) {
|
887
|
+
const slotName = childNode["s-sn"];
|
888
|
+
childNode.hidden = false;
|
889
|
+
for (const siblingNode of childNodes) {
|
890
|
+
if (siblingNode !== childNode) {
|
891
|
+
if (siblingNode["s-hn"] !== childNode["s-hn"] || slotName !== "") {
|
892
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute("slot") || slotName === siblingNode["s-sn"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode["s-sn"]) {
|
893
|
+
childNode.hidden = true;
|
894
|
+
break;
|
895
|
+
}
|
896
|
+
} else {
|
897
|
+
if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== "") {
|
898
|
+
childNode.hidden = true;
|
899
|
+
break;
|
900
|
+
}
|
901
|
+
}
|
902
|
+
}
|
903
|
+
}
|
904
|
+
}
|
905
|
+
updateFallbackSlotVisibility(childNode);
|
906
|
+
}
|
907
|
+
}
|
908
|
+
};
|
997
909
|
var relocateNodes = [];
|
998
910
|
var markSlotContentForRelocation = (elm) => {
|
999
911
|
let node;
|
1000
912
|
let hostContentNodes;
|
1001
913
|
let j;
|
1002
|
-
const
|
1003
|
-
for (const childNode of children) {
|
914
|
+
for (const childNode of elm.childNodes) {
|
1004
915
|
if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
|
1005
|
-
hostContentNodes = node.parentNode.
|
916
|
+
hostContentNodes = node.parentNode.childNodes;
|
1006
917
|
const slotName = childNode["s-sn"];
|
1007
918
|
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
1008
919
|
node = hostContentNodes[j];
|
@@ -1044,6 +955,21 @@ var markSlotContentForRelocation = (elm) => {
|
|
1044
955
|
}
|
1045
956
|
}
|
1046
957
|
};
|
958
|
+
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
959
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
960
|
+
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
961
|
+
return true;
|
962
|
+
}
|
963
|
+
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
964
|
+
return true;
|
965
|
+
}
|
966
|
+
return false;
|
967
|
+
}
|
968
|
+
if (nodeToRelocate["s-sn"] === slotName) {
|
969
|
+
return true;
|
970
|
+
}
|
971
|
+
return slotName === "";
|
972
|
+
};
|
1047
973
|
var nullifyVNodeRefs = (vNode) => {
|
1048
974
|
{
|
1049
975
|
vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
|
@@ -1051,9 +977,8 @@ var nullifyVNodeRefs = (vNode) => {
|
|
1051
977
|
}
|
1052
978
|
};
|
1053
979
|
var insertBefore = (parent, newNode, reference) => {
|
1054
|
-
|
1055
|
-
|
1056
|
-
}
|
980
|
+
const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
981
|
+
return inserted;
|
1057
982
|
};
|
1058
983
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
1059
984
|
var _a, _b, _c, _d;
|
@@ -1073,7 +998,10 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1073
998
|
rootVnode.$flags$ |= 4 /* isHost */;
|
1074
999
|
hostRef.$vnode$ = rootVnode;
|
1075
1000
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
1076
|
-
|
1001
|
+
{
|
1002
|
+
scopeId = hostElm["s-sc"];
|
1003
|
+
}
|
1004
|
+
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
1077
1005
|
{
|
1078
1006
|
contentRef = hostElm["s-cr"];
|
1079
1007
|
checkSlotFallbackVisibility = false;
|
@@ -1101,7 +1029,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1101
1029
|
let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
|
1102
1030
|
while (orgLocationNode) {
|
1103
1031
|
let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
|
1104
|
-
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef ===
|
1032
|
+
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
|
1105
1033
|
refNode = refNode.nextSibling;
|
1106
1034
|
while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
|
1107
1035
|
refNode = refNode == null ? void 0 : refNode.nextSibling;
|
@@ -1114,15 +1042,13 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1114
1042
|
orgLocationNode = orgLocationNode.previousSibling;
|
1115
1043
|
}
|
1116
1044
|
}
|
1117
|
-
|
1118
|
-
const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
|
1119
|
-
if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
|
1045
|
+
if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {
|
1120
1046
|
if (nodeToRelocate !== insertBeforeNode) {
|
1121
1047
|
if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
|
1122
1048
|
nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
|
1123
1049
|
}
|
1124
1050
|
insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
|
1125
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */
|
1051
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
1126
1052
|
nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
|
1127
1053
|
}
|
1128
1054
|
}
|
@@ -1150,14 +1076,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1150
1076
|
// src/runtime/update-component.ts
|
1151
1077
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
1152
1078
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
1153
|
-
|
1154
|
-
new Promise(
|
1155
|
-
(r) => hostRef.$onRenderResolve$ = () => {
|
1156
|
-
ancestorComponent["s-p"].splice(index - 1, 1);
|
1157
|
-
r();
|
1158
|
-
}
|
1159
|
-
)
|
1160
|
-
);
|
1079
|
+
ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
|
1161
1080
|
}
|
1162
1081
|
};
|
1163
1082
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
@@ -1186,16 +1105,16 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
1186
1105
|
{
|
1187
1106
|
hostRef.$flags$ |= 256 /* isListenReady */;
|
1188
1107
|
if (hostRef.$queuedListeners$) {
|
1189
|
-
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event
|
1108
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
|
1190
1109
|
hostRef.$queuedListeners$ = void 0;
|
1191
1110
|
}
|
1192
1111
|
}
|
1193
1112
|
{
|
1194
|
-
maybePromise = safeCall(instance, "componentWillLoad"
|
1113
|
+
maybePromise = safeCall(instance, "componentWillLoad");
|
1195
1114
|
}
|
1196
1115
|
}
|
1197
1116
|
{
|
1198
|
-
maybePromise = enqueue(maybePromise, () => safeCall(instance, "componentWillRender"
|
1117
|
+
maybePromise = enqueue(maybePromise, () => safeCall(instance, "componentWillRender"));
|
1199
1118
|
}
|
1200
1119
|
endSchedule();
|
1201
1120
|
return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));
|
@@ -1263,7 +1182,7 @@ var postUpdateComponent = (hostRef) => {
|
|
1263
1182
|
const instance = hostRef.$lazyInstance$ ;
|
1264
1183
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
1265
1184
|
{
|
1266
|
-
safeCall(instance, "componentDidRender"
|
1185
|
+
safeCall(instance, "componentDidRender");
|
1267
1186
|
}
|
1268
1187
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
1269
1188
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
@@ -1271,7 +1190,7 @@ var postUpdateComponent = (hostRef) => {
|
|
1271
1190
|
addHydratedFlag(elm);
|
1272
1191
|
}
|
1273
1192
|
{
|
1274
|
-
safeCall(instance, "componentDidLoad"
|
1193
|
+
safeCall(instance, "componentDidLoad");
|
1275
1194
|
}
|
1276
1195
|
endPostUpdate();
|
1277
1196
|
{
|
@@ -1298,14 +1217,17 @@ var postUpdateComponent = (hostRef) => {
|
|
1298
1217
|
}
|
1299
1218
|
};
|
1300
1219
|
var appDidLoad = (who) => {
|
1220
|
+
{
|
1221
|
+
addHydratedFlag(doc.documentElement);
|
1222
|
+
}
|
1301
1223
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
1302
1224
|
};
|
1303
|
-
var safeCall = (instance, method, arg
|
1225
|
+
var safeCall = (instance, method, arg) => {
|
1304
1226
|
if (instance && instance[method]) {
|
1305
1227
|
try {
|
1306
1228
|
return instance[method](arg);
|
1307
1229
|
} catch (e) {
|
1308
|
-
consoleError(e
|
1230
|
+
consoleError(e);
|
1309
1231
|
}
|
1310
1232
|
}
|
1311
1233
|
return void 0;
|
@@ -1364,68 +1286,15 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
1364
1286
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
1365
1287
|
members.map(([memberName, [memberFlags]]) => {
|
1366
1288
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
1367
|
-
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
1368
|
-
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
1369
|
-
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
1370
|
-
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
1371
|
-
Object.defineProperty(prototype, memberName, {
|
1372
|
-
get() {
|
1373
|
-
{
|
1374
|
-
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
1375
|
-
return getValue(this, memberName);
|
1376
|
-
}
|
1377
|
-
const ref = getHostRef(this);
|
1378
|
-
const instance = ref ? ref.$lazyInstance$ : prototype;
|
1379
|
-
if (!instance) return;
|
1380
|
-
return instance[memberName];
|
1381
|
-
}
|
1382
|
-
},
|
1383
|
-
configurable: true,
|
1384
|
-
enumerable: true
|
1385
|
-
});
|
1386
|
-
}
|
1387
1289
|
Object.defineProperty(prototype, memberName, {
|
1290
|
+
get() {
|
1291
|
+
return getValue(this, memberName);
|
1292
|
+
},
|
1388
1293
|
set(newValue) {
|
1389
|
-
|
1390
|
-
|
1391
|
-
|
1392
|
-
|
1393
|
-
newValue = ref.$instanceValues$.get(memberName);
|
1394
|
-
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
1395
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
1396
|
-
}
|
1397
|
-
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
1398
|
-
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
1399
|
-
setValue(this, memberName, newValue, cmpMeta);
|
1400
|
-
return;
|
1401
|
-
}
|
1402
|
-
{
|
1403
|
-
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
1404
|
-
setValue(this, memberName, newValue, cmpMeta);
|
1405
|
-
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
1406
|
-
ref.$onReadyPromise$.then(() => {
|
1407
|
-
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
1408
|
-
ref.$lazyInstance$[memberName] = newValue;
|
1409
|
-
}
|
1410
|
-
});
|
1411
|
-
}
|
1412
|
-
return;
|
1413
|
-
}
|
1414
|
-
const setterSetVal = () => {
|
1415
|
-
const currentValue = ref.$lazyInstance$[memberName];
|
1416
|
-
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
1417
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
1418
|
-
}
|
1419
|
-
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
1420
|
-
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
1421
|
-
};
|
1422
|
-
if (ref.$lazyInstance$) {
|
1423
|
-
setterSetVal();
|
1424
|
-
} else {
|
1425
|
-
ref.$onReadyPromise$.then(() => setterSetVal());
|
1426
|
-
}
|
1427
|
-
}
|
1428
|
-
}
|
1294
|
+
setValue(this, memberName, newValue, cmpMeta);
|
1295
|
+
},
|
1296
|
+
configurable: true,
|
1297
|
+
enumerable: true
|
1429
1298
|
});
|
1430
1299
|
} else if (flags & 1 /* isElementConstructor */ && memberFlags & 64 /* Method */) {
|
1431
1300
|
Object.defineProperty(prototype, memberName, {
|
@@ -1446,11 +1315,10 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
1446
1315
|
plt.jmp(() => {
|
1447
1316
|
var _a2;
|
1448
1317
|
const propName = attrNameToPropName.get(attrName);
|
1449
|
-
if (this.hasOwnProperty(propName)
|
1318
|
+
if (this.hasOwnProperty(propName)) {
|
1450
1319
|
newValue = this[propName];
|
1451
1320
|
delete this[propName];
|
1452
|
-
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" &&
|
1453
|
-
this[propName] == newValue) {
|
1321
|
+
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && this[propName] == newValue) {
|
1454
1322
|
return;
|
1455
1323
|
} else if (propName == null) {
|
1456
1324
|
const hostRef = getHostRef(this);
|
@@ -1466,11 +1334,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
1466
1334
|
}
|
1467
1335
|
return;
|
1468
1336
|
}
|
1469
|
-
|
1470
|
-
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
1471
|
-
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
1472
|
-
this[propName] = newValue;
|
1473
|
-
}
|
1337
|
+
this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
1474
1338
|
});
|
1475
1339
|
};
|
1476
1340
|
Cstr.observedAttributes = Array.from(
|
@@ -1495,7 +1359,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
1495
1359
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
1496
1360
|
const bundleId = cmpMeta.$lazyBundleId$;
|
1497
1361
|
if (bundleId) {
|
1498
|
-
const CstrImport = loadModule(cmpMeta
|
1362
|
+
const CstrImport = loadModule(cmpMeta);
|
1499
1363
|
if (CstrImport && "then" in CstrImport) {
|
1500
1364
|
const endLoad = uniqueTime();
|
1501
1365
|
Cstr = await CstrImport;
|
@@ -1520,7 +1384,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
1520
1384
|
try {
|
1521
1385
|
new Cstr(hostRef);
|
1522
1386
|
} catch (e) {
|
1523
|
-
consoleError(e
|
1387
|
+
consoleError(e);
|
1524
1388
|
}
|
1525
1389
|
{
|
1526
1390
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
@@ -1555,7 +1419,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
1555
1419
|
schedule();
|
1556
1420
|
}
|
1557
1421
|
};
|
1558
|
-
var fireConnectedCallback = (instance
|
1422
|
+
var fireConnectedCallback = (instance) => {
|
1559
1423
|
};
|
1560
1424
|
|
1561
1425
|
// src/runtime/connected-callback.ts
|
@@ -1609,9 +1473,9 @@ var setContentReference = (elm) => {
|
|
1609
1473
|
contentRefElm["s-cn"] = true;
|
1610
1474
|
insertBefore(elm, contentRefElm, elm.firstChild);
|
1611
1475
|
};
|
1612
|
-
var disconnectInstance = (instance
|
1476
|
+
var disconnectInstance = (instance) => {
|
1613
1477
|
{
|
1614
|
-
safeCall(instance, "disconnectedCallback"
|
1478
|
+
safeCall(instance, "disconnectedCallback");
|
1615
1479
|
}
|
1616
1480
|
};
|
1617
1481
|
var disconnectedCallback = async (elm) => {
|
@@ -1624,17 +1488,11 @@ var disconnectedCallback = async (elm) => {
|
|
1624
1488
|
}
|
1625
1489
|
}
|
1626
1490
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
1627
|
-
disconnectInstance(hostRef.$lazyInstance
|
1491
|
+
disconnectInstance(hostRef.$lazyInstance$);
|
1628
1492
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
1629
|
-
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance
|
1493
|
+
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$));
|
1630
1494
|
}
|
1631
1495
|
}
|
1632
|
-
if (rootAppliedStyles.has(elm)) {
|
1633
|
-
rootAppliedStyles.delete(elm);
|
1634
|
-
}
|
1635
|
-
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
1636
|
-
rootAppliedStyles.delete(elm.shadowRoot);
|
1637
|
-
}
|
1638
1496
|
};
|
1639
1497
|
|
1640
1498
|
// src/runtime/bootstrap-lazy.ts
|
@@ -1716,17 +1574,6 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
1716
1574
|
}
|
1717
1575
|
disconnectedCallback() {
|
1718
1576
|
plt.jmp(() => disconnectedCallback(this));
|
1719
|
-
plt.raf(() => {
|
1720
|
-
var _a3;
|
1721
|
-
const hostRef = getHostRef(this);
|
1722
|
-
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
1723
|
-
if (i2 > -1) {
|
1724
|
-
deferredConnectedCallbacks.splice(i2, 1);
|
1725
|
-
}
|
1726
|
-
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
1727
|
-
delete hostRef.$vnode$.$elm$;
|
1728
|
-
}
|
1729
|
-
});
|
1730
1577
|
}
|
1731
1578
|
componentOnReady() {
|
1732
1579
|
return getHostRef(this).$onReadyPromise$;
|
@@ -1790,7 +1637,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
1790
1637
|
}
|
1791
1638
|
}
|
1792
1639
|
} catch (e) {
|
1793
|
-
consoleError(e
|
1640
|
+
consoleError(e);
|
1794
1641
|
}
|
1795
1642
|
};
|
1796
1643
|
var getHostListenerTarget = (elm, flags) => {
|