@everymatrix/casino-engagement-suite-tournament 1.52.6 → 1.53.10

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.
Files changed (23) hide show
  1. package/dist/casino-engagement-suite-tournament/casino-engagement-suite-tournament.esm.js +1 -1
  2. package/dist/casino-engagement-suite-tournament/index.esm.js +1 -1
  3. package/dist/casino-engagement-suite-tournament/p-399401c8.js +2 -0
  4. package/dist/casino-engagement-suite-tournament/p-575729c8.js +1 -0
  5. package/dist/casino-engagement-suite-tournament/{p-6d03bbf5.entry.js → p-f3795238.entry.js} +1 -1
  6. package/dist/cjs/casino-engagement-suite-progress-bar_3.cjs.entry.js +39 -13
  7. package/dist/cjs/{casino-engagement-suite-tournament-71606d08.js → casino-engagement-suite-tournament-c194e96a.js} +505 -10
  8. package/dist/cjs/casino-engagement-suite-tournament.cjs.js +2 -2
  9. package/dist/cjs/{index-4eb9b2e6.js → index-6ea4215d.js} +247 -145
  10. package/dist/cjs/index.cjs.js +2 -2
  11. package/dist/cjs/loader.cjs.js +1 -1
  12. package/dist/collection/collection-manifest.json +1 -1
  13. package/dist/collection/components/casino-engagement-suite-tournament/casino-engagement-suite-tournament.js +36 -5
  14. package/dist/esm/casino-engagement-suite-progress-bar_3.entry.js +39 -13
  15. package/dist/esm/{casino-engagement-suite-tournament-d6f0ee89.js → casino-engagement-suite-tournament-18e62f35.js} +587 -92
  16. package/dist/esm/casino-engagement-suite-tournament.js +3 -3
  17. package/dist/esm/{index-3124114b.js → index-b5adca25.js} +247 -145
  18. package/dist/esm/index.js +2 -2
  19. package/dist/esm/loader.js +2 -2
  20. package/dist/types/components/casino-engagement-suite-tournament/casino-engagement-suite-tournament.d.ts +1 -1
  21. package/package.json +1 -1
  22. package/dist/casino-engagement-suite-tournament/p-1cd75583.js +0 -2
  23. package/dist/casino-engagement-suite-tournament/p-c416546b.js +0 -1
@@ -1,17 +1,21 @@
1
1
  const NAMESPACE = 'casino-engagement-suite-tournament';
2
- const BUILD = /* casino-engagement-suite-tournament */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: true, watchCallback: true };
2
+ const BUILD = /* casino-engagement-suite-tournament */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: true, watchCallback: true };
3
3
 
4
4
  /*
5
- Stencil Client Platform v4.22.3 | MIT Licensed | https://stenciljs.com
5
+ Stencil Client Platform v4.25.1 | 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
12
14
  var hostRefs = /* @__PURE__ */ new WeakMap();
13
15
  var getHostRef = (ref) => hostRefs.get(ref);
14
- var registerInstance = (lazyInstance, hostRef) => hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
16
+ var registerInstance = (lazyInstance, hostRef) => {
17
+ hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
18
+ };
15
19
  var registerHost = (hostElement, cmpMeta) => {
16
20
  const hostRef = {
17
21
  $flags$: 0,
@@ -24,7 +28,8 @@ var registerHost = (hostElement, cmpMeta) => {
24
28
  hostElement["s-p"] = [];
25
29
  hostElement["s-rc"] = [];
26
30
  }
27
- return hostRefs.set(hostElement, hostRef);
31
+ const ref = hostRefs.set(hostElement, hostRef);
32
+ return ref;
28
33
  };
29
34
  var isMemberInElement = (elm, memberName) => memberName in elm;
30
35
  var consoleError = (e, el) => (0, console.error)(e, el);
@@ -61,16 +66,22 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
61
66
  /* webpackExclude: /\.system\.entry\.js$/ */
62
67
  /* webpackMode: "lazy" */
63
68
  `./${bundleId}.entry.js${""}`
64
- ).then((importedModule) => {
65
- {
66
- cmpModules.set(bundleId, importedModule);
69
+ ).then(
70
+ (importedModule) => {
71
+ {
72
+ cmpModules.set(bundleId, importedModule);
73
+ }
74
+ return importedModule[exportName];
75
+ },
76
+ (e) => {
77
+ consoleError(e, hostRef.$hostElement$);
67
78
  }
68
- return importedModule[exportName];
69
- }, consoleError);
79
+ );
70
80
  };
71
81
 
72
82
  // src/client/client-style.ts
73
83
  var styles = /* @__PURE__ */ new Map();
84
+ var HYDRATED_STYLE_ID = "sty-id";
74
85
  var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
75
86
  var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
76
87
  var XLINK_NS = "http://www.w3.org/1999/xlink";
@@ -145,12 +156,6 @@ var flush = () => {
145
156
  };
146
157
  var nextTick = (cb) => promiseResolve().then(cb);
147
158
  var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
148
-
149
- // src/utils/constants.ts
150
- var EMPTY_OBJ = {};
151
-
152
- // src/utils/helpers.ts
153
- var isDef = (v) => v != null;
154
159
  var isComplexType = (o) => {
155
160
  o = typeof o;
156
161
  return o === "object" || o === "function";
@@ -210,6 +215,63 @@ var unwrapErr = (result) => {
210
215
  throw result.value;
211
216
  }
212
217
  };
218
+ var updateFallbackSlotVisibility = (elm) => {
219
+ const childNodes = elm.__childNodes || elm.childNodes;
220
+ if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
221
+ getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
222
+ var _a;
223
+ if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
224
+ if ((_a = getHostSlotChildNodes(slotNode, slotNode["s-sn"], false)) == null ? void 0 : _a.length) {
225
+ slotNode.hidden = true;
226
+ } else {
227
+ slotNode.hidden = false;
228
+ }
229
+ }
230
+ });
231
+ }
232
+ for (const childNode of childNodes) {
233
+ if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {
234
+ updateFallbackSlotVisibility(childNode);
235
+ }
236
+ }
237
+ };
238
+ function getHostSlotNodes(childNodes, hostName, slotName) {
239
+ let i2 = 0;
240
+ let slottedNodes = [];
241
+ let childNode;
242
+ for (; i2 < childNodes.length; i2++) {
243
+ childNode = childNodes[i2];
244
+ if (childNode["s-sr"] && childNode["s-hn"] === hostName && (slotName === void 0 || childNode["s-sn"] === slotName)) {
245
+ slottedNodes.push(childNode);
246
+ if (typeof slotName !== "undefined") return slottedNodes;
247
+ }
248
+ slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
249
+ }
250
+ return slottedNodes;
251
+ }
252
+ var getHostSlotChildNodes = (node, slotName, includeSlot = true) => {
253
+ const childNodes = [];
254
+ if (includeSlot && node["s-sr"] || !node["s-sr"]) childNodes.push(node);
255
+ while ((node = node.nextSibling) && node["s-sn"] === slotName) {
256
+ childNodes.push(node);
257
+ }
258
+ return childNodes;
259
+ };
260
+ var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
261
+ if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
262
+ if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
263
+ return true;
264
+ }
265
+ if (nodeToRelocate.getAttribute("slot") === slotName) {
266
+ return true;
267
+ }
268
+ return false;
269
+ }
270
+ if (nodeToRelocate["s-sn"] === slotName) {
271
+ return true;
272
+ }
273
+ return slotName === "";
274
+ };
213
275
  var createTime = (fnName, tagName = "") => {
214
276
  {
215
277
  return () => {
@@ -364,7 +426,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
364
426
  }
365
427
  if (!appliedStyles.has(scopeId2)) {
366
428
  {
367
- styleElm = doc.createElement("style");
429
+ styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`) || doc.createElement("style");
368
430
  styleElm.innerHTML = style;
369
431
  const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
370
432
  if (nonce != null) {
@@ -374,7 +436,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
374
436
  if (styleContainerNode.nodeName === "HEAD") {
375
437
  const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
376
438
  const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
377
- styleContainerNode.insertBefore(styleElm, referenceNode2);
439
+ styleContainerNode.insertBefore(
440
+ styleElm,
441
+ (referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
442
+ );
378
443
  } else if ("host" in styleContainerNode) {
379
444
  if (supportsConstructableStylesheets) {
380
445
  const stylesheet = new CSSStyleSheet();
@@ -424,16 +489,18 @@ var attachStyles = (hostRef) => {
424
489
  endAttachStyles();
425
490
  };
426
491
  var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
427
- var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
492
+ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
428
493
  if (oldValue !== newValue) {
429
494
  let isProp = isMemberInElement(elm, memberName);
430
495
  let ln = memberName.toLowerCase();
431
496
  if (memberName === "class") {
432
497
  const classList = elm.classList;
433
498
  const oldClasses = parseClassList(oldValue);
434
- const newClasses = parseClassList(newValue);
435
- classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
436
- classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
499
+ let newClasses = parseClassList(newValue);
500
+ {
501
+ classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
502
+ classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
503
+ }
437
504
  } else if (memberName === "style") {
438
505
  {
439
506
  for (const prop in oldValue) {
@@ -492,7 +559,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
492
559
  elm.setAttribute(memberName, n);
493
560
  }
494
561
  }
495
- } else {
562
+ } else if (elm[memberName] !== newValue) {
496
563
  elm[memberName] = newValue;
497
564
  }
498
565
  } catch (e) {
@@ -525,24 +592,44 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
525
592
  }
526
593
  };
527
594
  var parseClassListRegex = /\s/;
528
- var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
595
+ var parseClassList = (value) => {
596
+ if (typeof value === "object" && value && "baseVal" in value) {
597
+ value = value.baseVal;
598
+ }
599
+ if (!value || typeof value !== "string") {
600
+ return [];
601
+ }
602
+ return value.split(parseClassListRegex);
603
+ };
529
604
  var CAPTURE_EVENT_SUFFIX = "Capture";
530
605
  var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
531
606
 
532
607
  // src/runtime/vdom/update-element.ts
533
- var updateElement = (oldVnode, newVnode, isSvgMode2) => {
608
+ var updateElement = (oldVnode, newVnode, isSvgMode2, isInitialRender) => {
534
609
  const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
535
- const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
536
- const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
610
+ const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};
611
+ const newVnodeAttrs = newVnode.$attrs$ || {};
537
612
  {
538
613
  for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
539
614
  if (!(memberName in newVnodeAttrs)) {
540
- setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
615
+ setAccessor(
616
+ elm,
617
+ memberName,
618
+ oldVnodeAttrs[memberName],
619
+ void 0,
620
+ isSvgMode2,
621
+ newVnode.$flags$);
541
622
  }
542
623
  }
543
624
  }
544
625
  for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
545
- setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
626
+ setAccessor(
627
+ elm,
628
+ memberName,
629
+ oldVnodeAttrs[memberName],
630
+ newVnodeAttrs[memberName],
631
+ isSvgMode2,
632
+ newVnode.$flags$);
546
633
  }
547
634
  };
548
635
  function sortedAttrNames(attrNames) {
@@ -554,16 +641,13 @@ function sortedAttrNames(attrNames) {
554
641
  attrNames
555
642
  );
556
643
  }
557
-
558
- // src/runtime/vdom/vdom-render.ts
559
- var scopeId;
560
644
  var contentRef;
561
645
  var hostTagName;
562
646
  var useNativeShadowDom = false;
563
647
  var checkSlotFallbackVisibility = false;
564
648
  var checkSlotRelocate = false;
565
649
  var isSvgMode = false;
566
- var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
650
+ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
567
651
  var _a;
568
652
  const newVNode2 = newParentVNode.$children$[childIndex];
569
653
  let i2 = 0;
@@ -573,9 +657,6 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
573
657
  if (!useNativeShadowDom) {
574
658
  checkSlotRelocate = true;
575
659
  if (newVNode2.$tag$ === "slot") {
576
- if (scopeId) {
577
- parentElm.classList.add(scopeId + "-s");
578
- }
579
660
  newVNode2.$flags$ |= newVNode2.$children$ ? (
580
661
  // slot element has fallback content
581
662
  // still create an element that "mocks" the slot element
@@ -599,14 +680,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
599
680
  {
600
681
  updateElement(null, newVNode2, isSvgMode);
601
682
  }
602
- const rootNode = elm.getRootNode();
603
- const isElementWithinShadowRoot = !rootNode.querySelector("body");
604
- if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm["s-si"] !== scopeId) {
605
- elm.classList.add(elm["s-si"] = scopeId);
606
- }
607
683
  if (newVNode2.$children$) {
608
684
  for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
609
- childNode = createElm(oldParentVNode, newVNode2, i2, elm);
685
+ childNode = createElm(oldParentVNode, newVNode2, i2);
610
686
  if (childNode) {
611
687
  elm.appendChild(childNode);
612
688
  }
@@ -632,7 +708,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
632
708
  };
633
709
  var putBackInOriginalLocation = (parentElm, recursive) => {
634
710
  plt.$flags$ |= 1 /* isTmpDisconnected */;
635
- const oldSlotChildNodes = Array.from(parentElm.childNodes);
711
+ const oldSlotChildNodes = Array.from(parentElm.__childNodes || parentElm.childNodes);
636
712
  if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
637
713
  let node = parentElm;
638
714
  while (node = node.nextSibling) {
@@ -644,7 +720,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
644
720
  for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
645
721
  const childNode = oldSlotChildNodes[i2];
646
722
  if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
647
- insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));
723
+ insertBefore(referenceNode(childNode).parentNode, childNode, referenceNode(childNode));
648
724
  childNode["s-ol"].remove();
649
725
  childNode["s-ol"] = void 0;
650
726
  childNode["s-sh"] = void 0;
@@ -664,7 +740,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
664
740
  }
665
741
  for (; startIdx <= endIdx; ++startIdx) {
666
742
  if (vnodes[startIdx]) {
667
- childNode = createElm(null, parentVNode, startIdx, parentElm);
743
+ childNode = createElm(null, parentVNode, startIdx);
668
744
  if (childNode) {
669
745
  vnodes[startIdx].$elm$ = childNode;
670
746
  insertBefore(containerElm, childNode, referenceNode(before) );
@@ -751,7 +827,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
751
827
  if (idxInOld >= 0) {
752
828
  elmToMove = oldCh[idxInOld];
753
829
  if (elmToMove.$tag$ !== newStartVnode.$tag$) {
754
- node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld, parentElm);
830
+ node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
755
831
  } else {
756
832
  patch(elmToMove, newStartVnode, isInitialRender);
757
833
  oldCh[idxInOld] = void 0;
@@ -759,12 +835,16 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
759
835
  }
760
836
  newStartVnode = newCh[++newStartIdx];
761
837
  } else {
762
- node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx, parentElm);
838
+ node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
763
839
  newStartVnode = newCh[++newStartIdx];
764
840
  }
765
841
  if (node) {
766
842
  {
767
- insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));
843
+ insertBefore(
844
+ referenceNode(oldStartVnode.$elm$).parentNode,
845
+ node,
846
+ referenceNode(oldStartVnode.$elm$)
847
+ );
768
848
  }
769
849
  }
770
850
  }
@@ -785,28 +865,19 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
785
865
  var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
786
866
  if (leftVNode.$tag$ === rightVNode.$tag$) {
787
867
  if (leftVNode.$tag$ === "slot") {
788
- if (
789
- // The component gets hydrated and no VDOM has been initialized.
790
- // Here the comparison can't happen as $name$ property is not set for `leftNode`.
791
- "$nodeId$" in leftVNode && isInitialRender && // `leftNode` is not from type HTMLComment which would cause many
792
- // hydration comments to be removed
793
- leftVNode.$elm$.nodeType !== 8
794
- ) {
795
- return false;
796
- }
797
868
  return leftVNode.$name$ === rightVNode.$name$;
798
869
  }
799
870
  if (!isInitialRender) {
800
871
  return leftVNode.$key$ === rightVNode.$key$;
801
872
  }
873
+ if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
874
+ leftVNode.$key$ = rightVNode.$key$;
875
+ }
802
876
  return true;
803
877
  }
804
878
  return false;
805
879
  };
806
- var referenceNode = (node) => {
807
- return node && node["s-ol"] || node;
808
- };
809
- var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
880
+ var referenceNode = (node) => node && node["s-ol"] || node;
810
881
  var patch = (oldVNode, newVNode2, isInitialRender = false) => {
811
882
  const elm = newVNode2.$elm$ = oldVNode.$elm$;
812
883
  const oldChildren = oldVNode.$children$;
@@ -839,41 +910,15 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
839
910
  elm.data = text;
840
911
  }
841
912
  };
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
- };
869
913
  var relocateNodes = [];
870
914
  var markSlotContentForRelocation = (elm) => {
871
915
  let node;
872
916
  let hostContentNodes;
873
917
  let j;
874
- for (const childNode of elm.childNodes) {
918
+ const children = elm.__childNodes || elm.childNodes;
919
+ for (const childNode of children) {
875
920
  if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
876
- hostContentNodes = node.parentNode.childNodes;
921
+ hostContentNodes = node.parentNode.__childNodes || node.parentNode.childNodes;
877
922
  const slotName = childNode["s-sn"];
878
923
  for (j = hostContentNodes.length - 1; j >= 0; j--) {
879
924
  node = hostContentNodes[j];
@@ -915,21 +960,6 @@ var markSlotContentForRelocation = (elm) => {
915
960
  }
916
961
  }
917
962
  };
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;
927
- }
928
- if (nodeToRelocate["s-sn"] === slotName) {
929
- return true;
930
- }
931
- return slotName === "";
932
- };
933
963
  var nullifyVNodeRefs = (vNode) => {
934
964
  {
935
965
  vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
@@ -937,8 +967,9 @@ var nullifyVNodeRefs = (vNode) => {
937
967
  }
938
968
  };
939
969
  var insertBefore = (parent, newNode, reference) => {
940
- const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
941
- return inserted;
970
+ {
971
+ return parent == null ? void 0 : parent.insertBefore(newNode, reference);
972
+ }
942
973
  };
943
974
  var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
944
975
  var _a, _b, _c, _d;
@@ -964,9 +995,6 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
964
995
  rootVnode.$flags$ |= 4 /* isHost */;
965
996
  hostRef.$vnode$ = rootVnode;
966
997
  rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
967
- {
968
- scopeId = hostElm["s-sc"];
969
- }
970
998
  useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
971
999
  {
972
1000
  contentRef = hostElm["s-cr"];
@@ -995,7 +1023,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
995
1023
  let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
996
1024
  while (orgLocationNode) {
997
1025
  let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
998
- if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
1026
+ if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === (refNode.__parentNode || refNode.parentNode)) {
999
1027
  refNode = refNode.nextSibling;
1000
1028
  while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
1001
1029
  refNode = refNode == null ? void 0 : refNode.nextSibling;
@@ -1008,13 +1036,15 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
1008
1036
  orgLocationNode = orgLocationNode.previousSibling;
1009
1037
  }
1010
1038
  }
1011
- if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {
1039
+ const parent = nodeToRelocate.__parentNode || nodeToRelocate.parentNode;
1040
+ const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
1041
+ if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
1012
1042
  if (nodeToRelocate !== insertBeforeNode) {
1013
1043
  if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
1014
1044
  nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
1015
1045
  }
1016
1046
  insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
1017
- if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
1047
+ if (nodeToRelocate.nodeType === 1 /* ElementNode */ && nodeToRelocate.tagName !== "SLOT-FB") {
1018
1048
  nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
1019
1049
  }
1020
1050
  }
@@ -1042,7 +1072,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
1042
1072
  // src/runtime/update-component.ts
1043
1073
  var attachToAncestor = (hostRef, ancestorComponent) => {
1044
1074
  if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
1045
- ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
1075
+ const index = ancestorComponent["s-p"].push(
1076
+ new Promise(
1077
+ (r) => hostRef.$onRenderResolve$ = () => {
1078
+ ancestorComponent["s-p"].splice(index - 1, 1);
1079
+ r();
1080
+ }
1081
+ )
1082
+ );
1046
1083
  }
1047
1084
  };
1048
1085
  var scheduleUpdate = (hostRef, isInitialLoad) => {
@@ -1071,12 +1108,12 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
1071
1108
  {
1072
1109
  hostRef.$flags$ |= 256 /* isListenReady */;
1073
1110
  if (hostRef.$queuedListeners$) {
1074
- hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
1111
+ hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event, elm));
1075
1112
  hostRef.$queuedListeners$ = void 0;
1076
1113
  }
1077
1114
  }
1078
1115
  {
1079
- maybePromise = safeCall(instance, "componentWillLoad");
1116
+ maybePromise = safeCall(instance, "componentWillLoad", void 0, elm);
1080
1117
  }
1081
1118
  }
1082
1119
  endSchedule();
@@ -1145,7 +1182,7 @@ var postUpdateComponent = (hostRef) => {
1145
1182
  const instance = hostRef.$lazyInstance$ ;
1146
1183
  const ancestorComponent = hostRef.$ancestorComponent$;
1147
1184
  {
1148
- safeCall(instance, "componentDidRender");
1185
+ safeCall(instance, "componentDidRender", void 0, elm);
1149
1186
  }
1150
1187
  if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
1151
1188
  hostRef.$flags$ |= 64 /* hasLoadedComponent */;
@@ -1179,12 +1216,12 @@ var appDidLoad = (who) => {
1179
1216
  }
1180
1217
  nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
1181
1218
  };
1182
- var safeCall = (instance, method, arg) => {
1219
+ var safeCall = (instance, method, arg, elm) => {
1183
1220
  if (instance && instance[method]) {
1184
1221
  try {
1185
1222
  return instance[method](arg);
1186
1223
  } catch (e) {
1187
- consoleError(e);
1224
+ consoleError(e, elm);
1188
1225
  }
1189
1226
  }
1190
1227
  return void 0;
@@ -1243,15 +1280,68 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1243
1280
  const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
1244
1281
  members.map(([memberName, [memberFlags]]) => {
1245
1282
  if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
1283
+ const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
1284
+ if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
1285
+ if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
1286
+ if (flags & 1 /* isElementConstructor */ || !origGetter) {
1287
+ Object.defineProperty(prototype, memberName, {
1288
+ get() {
1289
+ {
1290
+ if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
1291
+ return getValue(this, memberName);
1292
+ }
1293
+ const ref = getHostRef(this);
1294
+ const instance = ref ? ref.$lazyInstance$ : prototype;
1295
+ if (!instance) return;
1296
+ return instance[memberName];
1297
+ }
1298
+ },
1299
+ configurable: true,
1300
+ enumerable: true
1301
+ });
1302
+ }
1246
1303
  Object.defineProperty(prototype, memberName, {
1247
- get() {
1248
- return getValue(this, memberName);
1249
- },
1250
1304
  set(newValue) {
1251
- setValue(this, memberName, newValue, cmpMeta);
1252
- },
1253
- configurable: true,
1254
- enumerable: true
1305
+ const ref = getHostRef(this);
1306
+ if (origSetter) {
1307
+ const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
1308
+ if (typeof currentValue === "undefined" && ref.$instanceValues$.get(memberName)) {
1309
+ newValue = ref.$instanceValues$.get(memberName);
1310
+ } else if (!ref.$instanceValues$.get(memberName) && currentValue) {
1311
+ ref.$instanceValues$.set(memberName, currentValue);
1312
+ }
1313
+ origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
1314
+ newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
1315
+ setValue(this, memberName, newValue, cmpMeta);
1316
+ return;
1317
+ }
1318
+ {
1319
+ if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
1320
+ setValue(this, memberName, newValue, cmpMeta);
1321
+ if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
1322
+ ref.$onReadyPromise$.then(() => {
1323
+ if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
1324
+ ref.$lazyInstance$[memberName] = newValue;
1325
+ }
1326
+ });
1327
+ }
1328
+ return;
1329
+ }
1330
+ const setterSetVal = () => {
1331
+ const currentValue = ref.$lazyInstance$[memberName];
1332
+ if (!ref.$instanceValues$.get(memberName) && currentValue) {
1333
+ ref.$instanceValues$.set(memberName, currentValue);
1334
+ }
1335
+ ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
1336
+ setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
1337
+ };
1338
+ if (ref.$lazyInstance$) {
1339
+ setterSetVal();
1340
+ } else {
1341
+ ref.$onReadyPromise$.then(() => setterSetVal());
1342
+ }
1343
+ }
1344
+ }
1255
1345
  });
1256
1346
  }
1257
1347
  });
@@ -1261,7 +1351,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1261
1351
  plt.jmp(() => {
1262
1352
  var _a2;
1263
1353
  const propName = attrNameToPropName.get(attrName);
1264
- if (this.hasOwnProperty(propName)) {
1354
+ if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {
1265
1355
  newValue = this[propName];
1266
1356
  delete this[propName];
1267
1357
  } else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && // cast type to number to avoid TS compiler issues
@@ -1281,7 +1371,11 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1281
1371
  }
1282
1372
  return;
1283
1373
  }
1284
- this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
1374
+ const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
1375
+ newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
1376
+ if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
1377
+ this[propName] = newValue;
1378
+ }
1285
1379
  });
1286
1380
  };
1287
1381
  Cstr.observedAttributes = Array.from(
@@ -1308,9 +1402,8 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1308
1402
  let Cstr;
1309
1403
  if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
1310
1404
  hostRef.$flags$ |= 32 /* hasInitializedComponent */;
1311
- const bundleId = cmpMeta.$lazyBundleId$;
1312
- if (bundleId) {
1313
- const CstrImport = loadModule(cmpMeta);
1405
+ {
1406
+ const CstrImport = loadModule(cmpMeta, hostRef);
1314
1407
  if (CstrImport && "then" in CstrImport) {
1315
1408
  const endLoad = uniqueTime();
1316
1409
  Cstr = await CstrImport;
@@ -1335,7 +1428,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1335
1428
  try {
1336
1429
  new Cstr(hostRef);
1337
1430
  } catch (e) {
1338
- consoleError(e);
1431
+ consoleError(e, elm);
1339
1432
  }
1340
1433
  {
1341
1434
  hostRef.$flags$ &= ~8 /* isConstructingInstance */;
@@ -1344,11 +1437,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1344
1437
  hostRef.$flags$ |= 128 /* isWatchReady */;
1345
1438
  }
1346
1439
  endNewInstance();
1347
- fireConnectedCallback(hostRef.$lazyInstance$);
1348
- } else {
1349
- Cstr = elm.constructor;
1350
- const cmpTag = elm.localName;
1351
- customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);
1440
+ fireConnectedCallback(hostRef.$lazyInstance$, elm);
1352
1441
  }
1353
1442
  if (Cstr && Cstr.style) {
1354
1443
  let style;
@@ -1371,9 +1460,9 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1371
1460
  schedule();
1372
1461
  }
1373
1462
  };
1374
- var fireConnectedCallback = (instance) => {
1463
+ var fireConnectedCallback = (instance, elm) => {
1375
1464
  {
1376
- safeCall(instance, "connectedCallback");
1465
+ safeCall(instance, "connectedCallback", void 0, elm);
1377
1466
  }
1378
1467
  };
1379
1468
 
@@ -1415,9 +1504,9 @@ var connectedCallback = (elm) => {
1415
1504
  } else {
1416
1505
  addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
1417
1506
  if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
1418
- fireConnectedCallback(hostRef.$lazyInstance$);
1507
+ fireConnectedCallback(hostRef.$lazyInstance$, elm);
1419
1508
  } else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
1420
- hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$));
1509
+ hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$, elm));
1421
1510
  }
1422
1511
  }
1423
1512
  endConnected();
@@ -1430,9 +1519,9 @@ var setContentReference = (elm) => {
1430
1519
  contentRefElm["s-cn"] = true;
1431
1520
  insertBefore(elm, contentRefElm, elm.firstChild);
1432
1521
  };
1433
- var disconnectInstance = (instance) => {
1522
+ var disconnectInstance = (instance, elm) => {
1434
1523
  {
1435
- safeCall(instance, "disconnectedCallback");
1524
+ safeCall(instance, "disconnectedCallback", void 0, elm || instance);
1436
1525
  }
1437
1526
  };
1438
1527
  var disconnectedCallback = async (elm) => {
@@ -1445,11 +1534,17 @@ var disconnectedCallback = async (elm) => {
1445
1534
  }
1446
1535
  }
1447
1536
  if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
1448
- disconnectInstance(hostRef.$lazyInstance$);
1537
+ disconnectInstance(hostRef.$lazyInstance$, elm);
1449
1538
  } else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
1450
- hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$));
1539
+ hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$, elm));
1451
1540
  }
1452
1541
  }
1542
+ if (rootAppliedStyles.has(elm)) {
1543
+ rootAppliedStyles.delete(elm);
1544
+ }
1545
+ if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
1546
+ rootAppliedStyles.delete(elm.shadowRoot);
1547
+ }
1453
1548
  };
1454
1549
 
1455
1550
  // src/runtime/bootstrap-lazy.ts
@@ -1534,6 +1629,13 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
1534
1629
  }
1535
1630
  disconnectedCallback() {
1536
1631
  plt.jmp(() => disconnectedCallback(this));
1632
+ plt.raf(() => {
1633
+ var _a3;
1634
+ const hostRef = getHostRef(this);
1635
+ if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
1636
+ delete hostRef.$vnode$.$elm$;
1637
+ }
1638
+ });
1537
1639
  }
1538
1640
  componentOnReady() {
1539
1641
  return getHostRef(this).$onReadyPromise$;
@@ -1597,7 +1699,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
1597
1699
  }
1598
1700
  }
1599
1701
  } catch (e) {
1600
- consoleError(e);
1702
+ consoleError(e, hostRef.$hostElement$);
1601
1703
  }
1602
1704
  };
1603
1705
  var getHostListenerTarget = (elm, flags) => {