@everymatrix/player-elevate-card 1.53.0 → 1.53.11

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/cjs/general-styling-wrapper_5.cjs.entry.js +78 -32
  2. package/dist/cjs/{index-fcb2d8d9.js → index-4decce07.js} +240 -138
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/player-elevate-card.cjs.js +2 -2
  5. package/dist/collection/collection-manifest.json +1 -1
  6. package/dist/collection/components/player-elevate-card/player-elevate-card.js +39 -7
  7. package/dist/collection/components/player-elevate-card-data/player-elevate-card-data.js +2 -5
  8. package/dist/collection/components/player-elevate-loyaltycard/player-elevate-loyaltycard.js +39 -7
  9. package/dist/collection/components/player-elevate-pointcard/player-elevate-pointcard.js +51 -10
  10. package/dist/esm/general-styling-wrapper_5.entry.js +78 -32
  11. package/dist/esm/{index-94328d47.js → index-932d5ca0.js} +240 -138
  12. package/dist/esm/loader.js +2 -2
  13. package/dist/esm/player-elevate-card.js +3 -3
  14. package/dist/player-elevate-card/p-371d393e.entry.js +1 -0
  15. package/dist/player-elevate-card/p-46c78d03.js +2 -0
  16. package/dist/player-elevate-card/player-elevate-card.esm.js +1 -1
  17. 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 +2 -0
  18. 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 +2 -0
  19. package/package.json +1 -1
  20. package/dist/player-elevate-card/p-49062db1.entry.js +0 -1
  21. package/dist/player-elevate-card/p-8dfd18ff.js +0 -2
  22. package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/player-elevate-card/.stencil/packages/stencil/player-elevate-card/stencil.config.d.ts +0 -2
  23. 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 +0 -2
@@ -1,17 +1,21 @@
1
1
  const NAMESPACE = 'player-elevate-card';
2
- 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 };
2
+ 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, modernPropertyDecls: 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 };
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 win = typeof window !== "undefined" ? window : {};
@@ -150,12 +161,6 @@ var getAssetPath = (path) => {
150
161
  const assetUrl = new URL(path, plt.$resourcesUrl$);
151
162
  return assetUrl.origin !== win.location.origin ? assetUrl.href : assetUrl.pathname;
152
163
  };
153
-
154
- // src/utils/constants.ts
155
- var EMPTY_OBJ = {};
156
-
157
- // src/utils/helpers.ts
158
- var isDef = (v) => v != null;
159
164
  var isComplexType = (o) => {
160
165
  o = typeof o;
161
166
  return o === "object" || o === "function";
@@ -215,6 +220,63 @@ var unwrapErr = (result) => {
215
220
  throw result.value;
216
221
  }
217
222
  };
223
+ var updateFallbackSlotVisibility = (elm) => {
224
+ const childNodes = elm.__childNodes || elm.childNodes;
225
+ if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
226
+ getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
227
+ var _a;
228
+ if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
229
+ if ((_a = getHostSlotChildNodes(slotNode, slotNode["s-sn"], false)) == null ? void 0 : _a.length) {
230
+ slotNode.hidden = true;
231
+ } else {
232
+ slotNode.hidden = false;
233
+ }
234
+ }
235
+ });
236
+ }
237
+ for (const childNode of childNodes) {
238
+ if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {
239
+ updateFallbackSlotVisibility(childNode);
240
+ }
241
+ }
242
+ };
243
+ function getHostSlotNodes(childNodes, hostName, slotName) {
244
+ let i2 = 0;
245
+ let slottedNodes = [];
246
+ let childNode;
247
+ for (; i2 < childNodes.length; i2++) {
248
+ childNode = childNodes[i2];
249
+ if (childNode["s-sr"] && childNode["s-hn"] === hostName && (slotName === void 0 || childNode["s-sn"] === slotName)) {
250
+ slottedNodes.push(childNode);
251
+ if (typeof slotName !== "undefined") return slottedNodes;
252
+ }
253
+ slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
254
+ }
255
+ return slottedNodes;
256
+ }
257
+ var getHostSlotChildNodes = (node, slotName, includeSlot = true) => {
258
+ const childNodes = [];
259
+ if (includeSlot && node["s-sr"] || !node["s-sr"]) childNodes.push(node);
260
+ while ((node = node.nextSibling) && node["s-sn"] === slotName) {
261
+ childNodes.push(node);
262
+ }
263
+ return childNodes;
264
+ };
265
+ var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
266
+ if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
267
+ if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
268
+ return true;
269
+ }
270
+ if (nodeToRelocate.getAttribute("slot") === slotName) {
271
+ return true;
272
+ }
273
+ return false;
274
+ }
275
+ if (nodeToRelocate["s-sn"] === slotName) {
276
+ return true;
277
+ }
278
+ return slotName === "";
279
+ };
218
280
  var createTime = (fnName, tagName = "") => {
219
281
  {
220
282
  return () => {
@@ -400,7 +462,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
400
462
  }
401
463
  if (!appliedStyles.has(scopeId2)) {
402
464
  {
403
- styleElm = doc.createElement("style");
465
+ styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`) || doc.createElement("style");
404
466
  styleElm.innerHTML = style;
405
467
  const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
406
468
  if (nonce != null) {
@@ -410,7 +472,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
410
472
  if (styleContainerNode.nodeName === "HEAD") {
411
473
  const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
412
474
  const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
413
- styleContainerNode.insertBefore(styleElm, referenceNode2);
475
+ styleContainerNode.insertBefore(
476
+ styleElm,
477
+ (referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
478
+ );
414
479
  } else if ("host" in styleContainerNode) {
415
480
  if (supportsConstructableStylesheets) {
416
481
  const stylesheet = new CSSStyleSheet();
@@ -460,16 +525,18 @@ var attachStyles = (hostRef) => {
460
525
  endAttachStyles();
461
526
  };
462
527
  var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
463
- var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
528
+ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
464
529
  if (oldValue !== newValue) {
465
530
  let isProp = isMemberInElement(elm, memberName);
466
531
  let ln = memberName.toLowerCase();
467
532
  if (memberName === "class") {
468
533
  const classList = elm.classList;
469
534
  const oldClasses = parseClassList(oldValue);
470
- const newClasses = parseClassList(newValue);
471
- classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
472
- classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
535
+ let newClasses = parseClassList(newValue);
536
+ {
537
+ classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
538
+ classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
539
+ }
473
540
  } else if (memberName === "style") {
474
541
  {
475
542
  for (const prop in oldValue) {
@@ -524,7 +591,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
524
591
  elm.setAttribute(memberName, n);
525
592
  }
526
593
  }
527
- } else {
594
+ } else if (elm[memberName] !== newValue) {
528
595
  elm[memberName] = newValue;
529
596
  }
530
597
  } catch (e) {
@@ -546,24 +613,44 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
546
613
  }
547
614
  };
548
615
  var parseClassListRegex = /\s/;
549
- var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
616
+ var parseClassList = (value) => {
617
+ if (typeof value === "object" && value && "baseVal" in value) {
618
+ value = value.baseVal;
619
+ }
620
+ if (!value || typeof value !== "string") {
621
+ return [];
622
+ }
623
+ return value.split(parseClassListRegex);
624
+ };
550
625
  var CAPTURE_EVENT_SUFFIX = "Capture";
551
626
  var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
552
627
 
553
628
  // src/runtime/vdom/update-element.ts
554
- var updateElement = (oldVnode, newVnode, isSvgMode2) => {
629
+ var updateElement = (oldVnode, newVnode, isSvgMode2, isInitialRender) => {
555
630
  const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
556
- const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
557
- const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
631
+ const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};
632
+ const newVnodeAttrs = newVnode.$attrs$ || {};
558
633
  {
559
634
  for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
560
635
  if (!(memberName in newVnodeAttrs)) {
561
- setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
636
+ setAccessor(
637
+ elm,
638
+ memberName,
639
+ oldVnodeAttrs[memberName],
640
+ void 0,
641
+ isSvgMode2,
642
+ newVnode.$flags$);
562
643
  }
563
644
  }
564
645
  }
565
646
  for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
566
- setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
647
+ setAccessor(
648
+ elm,
649
+ memberName,
650
+ oldVnodeAttrs[memberName],
651
+ newVnodeAttrs[memberName],
652
+ isSvgMode2,
653
+ newVnode.$flags$);
567
654
  }
568
655
  };
569
656
  function sortedAttrNames(attrNames) {
@@ -575,16 +662,13 @@ function sortedAttrNames(attrNames) {
575
662
  attrNames
576
663
  );
577
664
  }
578
-
579
- // src/runtime/vdom/vdom-render.ts
580
- var scopeId;
581
665
  var contentRef;
582
666
  var hostTagName;
583
667
  var useNativeShadowDom = false;
584
668
  var checkSlotFallbackVisibility = false;
585
669
  var checkSlotRelocate = false;
586
670
  var isSvgMode = false;
587
- var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
671
+ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
588
672
  var _a;
589
673
  const newVNode2 = newParentVNode.$children$[childIndex];
590
674
  let i2 = 0;
@@ -594,9 +678,6 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
594
678
  if (!useNativeShadowDom) {
595
679
  checkSlotRelocate = true;
596
680
  if (newVNode2.$tag$ === "slot") {
597
- if (scopeId) {
598
- parentElm.classList.add(scopeId + "-s");
599
- }
600
681
  newVNode2.$flags$ |= newVNode2.$children$ ? (
601
682
  // slot element has fallback content
602
683
  // still create an element that "mocks" the slot element
@@ -620,14 +701,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
620
701
  {
621
702
  updateElement(null, newVNode2, isSvgMode);
622
703
  }
623
- const rootNode = elm.getRootNode();
624
- const isElementWithinShadowRoot = !rootNode.querySelector("body");
625
- if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm["s-si"] !== scopeId) {
626
- elm.classList.add(elm["s-si"] = scopeId);
627
- }
628
704
  if (newVNode2.$children$) {
629
705
  for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
630
- childNode = createElm(oldParentVNode, newVNode2, i2, elm);
706
+ childNode = createElm(oldParentVNode, newVNode2, i2);
631
707
  if (childNode) {
632
708
  elm.appendChild(childNode);
633
709
  }
@@ -653,7 +729,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
653
729
  };
654
730
  var putBackInOriginalLocation = (parentElm, recursive) => {
655
731
  plt.$flags$ |= 1 /* isTmpDisconnected */;
656
- const oldSlotChildNodes = Array.from(parentElm.childNodes);
732
+ const oldSlotChildNodes = Array.from(parentElm.__childNodes || parentElm.childNodes);
657
733
  if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
658
734
  let node = parentElm;
659
735
  while (node = node.nextSibling) {
@@ -665,7 +741,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
665
741
  for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
666
742
  const childNode = oldSlotChildNodes[i2];
667
743
  if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
668
- insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));
744
+ insertBefore(referenceNode(childNode).parentNode, childNode, referenceNode(childNode));
669
745
  childNode["s-ol"].remove();
670
746
  childNode["s-ol"] = void 0;
671
747
  childNode["s-sh"] = void 0;
@@ -685,7 +761,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
685
761
  }
686
762
  for (; startIdx <= endIdx; ++startIdx) {
687
763
  if (vnodes[startIdx]) {
688
- childNode = createElm(null, parentVNode, startIdx, parentElm);
764
+ childNode = createElm(null, parentVNode, startIdx);
689
765
  if (childNode) {
690
766
  vnodes[startIdx].$elm$ = childNode;
691
767
  insertBefore(containerElm, childNode, referenceNode(before) );
@@ -771,7 +847,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
771
847
  if (idxInOld >= 0) {
772
848
  elmToMove = oldCh[idxInOld];
773
849
  if (elmToMove.$tag$ !== newStartVnode.$tag$) {
774
- node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld, parentElm);
850
+ node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
775
851
  } else {
776
852
  patch(elmToMove, newStartVnode, isInitialRender);
777
853
  oldCh[idxInOld] = void 0;
@@ -779,12 +855,16 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
779
855
  }
780
856
  newStartVnode = newCh[++newStartIdx];
781
857
  } else {
782
- node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx, parentElm);
858
+ node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
783
859
  newStartVnode = newCh[++newStartIdx];
784
860
  }
785
861
  if (node) {
786
862
  {
787
- insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));
863
+ insertBefore(
864
+ referenceNode(oldStartVnode.$elm$).parentNode,
865
+ node,
866
+ referenceNode(oldStartVnode.$elm$)
867
+ );
788
868
  }
789
869
  }
790
870
  }
@@ -805,28 +885,19 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
805
885
  var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
806
886
  if (leftVNode.$tag$ === rightVNode.$tag$) {
807
887
  if (leftVNode.$tag$ === "slot") {
808
- if (
809
- // The component gets hydrated and no VDOM has been initialized.
810
- // Here the comparison can't happen as $name$ property is not set for `leftNode`.
811
- "$nodeId$" in leftVNode && isInitialRender && // `leftNode` is not from type HTMLComment which would cause many
812
- // hydration comments to be removed
813
- leftVNode.$elm$.nodeType !== 8
814
- ) {
815
- return false;
816
- }
817
888
  return leftVNode.$name$ === rightVNode.$name$;
818
889
  }
819
890
  if (!isInitialRender) {
820
891
  return leftVNode.$key$ === rightVNode.$key$;
821
892
  }
893
+ if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
894
+ leftVNode.$key$ = rightVNode.$key$;
895
+ }
822
896
  return true;
823
897
  }
824
898
  return false;
825
899
  };
826
- var referenceNode = (node) => {
827
- return node && node["s-ol"] || node;
828
- };
829
- var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
900
+ var referenceNode = (node) => node && node["s-ol"] || node;
830
901
  var patch = (oldVNode, newVNode2, isInitialRender = false) => {
831
902
  const elm = newVNode2.$elm$ = oldVNode.$elm$;
832
903
  const oldChildren = oldVNode.$children$;
@@ -859,41 +930,15 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
859
930
  elm.data = text;
860
931
  }
861
932
  };
862
- var updateFallbackSlotVisibility = (elm) => {
863
- const childNodes = elm.childNodes;
864
- for (const childNode of childNodes) {
865
- if (childNode.nodeType === 1 /* ElementNode */) {
866
- if (childNode["s-sr"]) {
867
- const slotName = childNode["s-sn"];
868
- childNode.hidden = false;
869
- for (const siblingNode of childNodes) {
870
- if (siblingNode !== childNode) {
871
- if (siblingNode["s-hn"] !== childNode["s-hn"] || slotName !== "") {
872
- if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute("slot") || slotName === siblingNode["s-sn"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode["s-sn"]) {
873
- childNode.hidden = true;
874
- break;
875
- }
876
- } else {
877
- if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== "") {
878
- childNode.hidden = true;
879
- break;
880
- }
881
- }
882
- }
883
- }
884
- }
885
- updateFallbackSlotVisibility(childNode);
886
- }
887
- }
888
- };
889
933
  var relocateNodes = [];
890
934
  var markSlotContentForRelocation = (elm) => {
891
935
  let node;
892
936
  let hostContentNodes;
893
937
  let j;
894
- for (const childNode of elm.childNodes) {
938
+ const children = elm.__childNodes || elm.childNodes;
939
+ for (const childNode of children) {
895
940
  if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
896
- hostContentNodes = node.parentNode.childNodes;
941
+ hostContentNodes = node.parentNode.__childNodes || node.parentNode.childNodes;
897
942
  const slotName = childNode["s-sn"];
898
943
  for (j = hostContentNodes.length - 1; j >= 0; j--) {
899
944
  node = hostContentNodes[j];
@@ -935,24 +980,10 @@ var markSlotContentForRelocation = (elm) => {
935
980
  }
936
981
  }
937
982
  };
938
- var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
939
- if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
940
- if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
941
- return true;
942
- }
943
- if (nodeToRelocate.getAttribute("slot") === slotName) {
944
- return true;
945
- }
946
- return false;
947
- }
948
- if (nodeToRelocate["s-sn"] === slotName) {
949
- return true;
950
- }
951
- return slotName === "";
952
- };
953
983
  var insertBefore = (parent, newNode, reference) => {
954
- const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
955
- return inserted;
984
+ {
985
+ return parent == null ? void 0 : parent.insertBefore(newNode, reference);
986
+ }
956
987
  };
957
988
  var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
958
989
  var _a, _b, _c, _d;
@@ -978,9 +1009,6 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
978
1009
  rootVnode.$flags$ |= 4 /* isHost */;
979
1010
  hostRef.$vnode$ = rootVnode;
980
1011
  rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
981
- {
982
- scopeId = hostElm["s-sc"];
983
- }
984
1012
  useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
985
1013
  {
986
1014
  contentRef = hostElm["s-cr"];
@@ -1009,7 +1037,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
1009
1037
  let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
1010
1038
  while (orgLocationNode) {
1011
1039
  let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
1012
- if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
1040
+ if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === (refNode.__parentNode || refNode.parentNode)) {
1013
1041
  refNode = refNode.nextSibling;
1014
1042
  while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
1015
1043
  refNode = refNode == null ? void 0 : refNode.nextSibling;
@@ -1022,13 +1050,15 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
1022
1050
  orgLocationNode = orgLocationNode.previousSibling;
1023
1051
  }
1024
1052
  }
1025
- if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {
1053
+ const parent = nodeToRelocate.__parentNode || nodeToRelocate.parentNode;
1054
+ const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
1055
+ if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
1026
1056
  if (nodeToRelocate !== insertBeforeNode) {
1027
1057
  if (!nodeToRelocate["s-hn"] && nodeToRelocate["s-ol"]) {
1028
1058
  nodeToRelocate["s-hn"] = nodeToRelocate["s-ol"].parentNode.nodeName;
1029
1059
  }
1030
1060
  insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
1031
- if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
1061
+ if (nodeToRelocate.nodeType === 1 /* ElementNode */ && nodeToRelocate.tagName !== "SLOT-FB") {
1032
1062
  nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
1033
1063
  }
1034
1064
  }
@@ -1056,7 +1086,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
1056
1086
  // src/runtime/update-component.ts
1057
1087
  var attachToAncestor = (hostRef, ancestorComponent) => {
1058
1088
  if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
1059
- ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
1089
+ const index = ancestorComponent["s-p"].push(
1090
+ new Promise(
1091
+ (r) => hostRef.$onRenderResolve$ = () => {
1092
+ ancestorComponent["s-p"].splice(index - 1, 1);
1093
+ r();
1094
+ }
1095
+ )
1096
+ );
1060
1097
  }
1061
1098
  };
1062
1099
  var scheduleUpdate = (hostRef, isInitialLoad) => {
@@ -1085,12 +1122,12 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
1085
1122
  {
1086
1123
  hostRef.$flags$ |= 256 /* isListenReady */;
1087
1124
  if (hostRef.$queuedListeners$) {
1088
- hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
1125
+ hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event, elm));
1089
1126
  hostRef.$queuedListeners$ = void 0;
1090
1127
  }
1091
1128
  }
1092
1129
  {
1093
- maybePromise = safeCall(instance, "componentWillLoad");
1130
+ maybePromise = safeCall(instance, "componentWillLoad", void 0, elm);
1094
1131
  }
1095
1132
  }
1096
1133
  endSchedule();
@@ -1159,7 +1196,7 @@ var postUpdateComponent = (hostRef) => {
1159
1196
  const instance = hostRef.$lazyInstance$ ;
1160
1197
  const ancestorComponent = hostRef.$ancestorComponent$;
1161
1198
  {
1162
- safeCall(instance, "componentDidRender");
1199
+ safeCall(instance, "componentDidRender", void 0, elm);
1163
1200
  }
1164
1201
  if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
1165
1202
  hostRef.$flags$ |= 64 /* hasLoadedComponent */;
@@ -1193,12 +1230,12 @@ var appDidLoad = (who) => {
1193
1230
  }
1194
1231
  nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
1195
1232
  };
1196
- var safeCall = (instance, method, arg) => {
1233
+ var safeCall = (instance, method, arg, elm) => {
1197
1234
  if (instance && instance[method]) {
1198
1235
  try {
1199
1236
  return instance[method](arg);
1200
1237
  } catch (e) {
1201
- consoleError(e);
1238
+ consoleError(e, elm);
1202
1239
  }
1203
1240
  }
1204
1241
  return void 0;
@@ -1257,15 +1294,68 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1257
1294
  const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
1258
1295
  members.map(([memberName, [memberFlags]]) => {
1259
1296
  if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
1297
+ const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
1298
+ if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
1299
+ if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
1300
+ if (flags & 1 /* isElementConstructor */ || !origGetter) {
1301
+ Object.defineProperty(prototype, memberName, {
1302
+ get() {
1303
+ {
1304
+ if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
1305
+ return getValue(this, memberName);
1306
+ }
1307
+ const ref = getHostRef(this);
1308
+ const instance = ref ? ref.$lazyInstance$ : prototype;
1309
+ if (!instance) return;
1310
+ return instance[memberName];
1311
+ }
1312
+ },
1313
+ configurable: true,
1314
+ enumerable: true
1315
+ });
1316
+ }
1260
1317
  Object.defineProperty(prototype, memberName, {
1261
- get() {
1262
- return getValue(this, memberName);
1263
- },
1264
1318
  set(newValue) {
1265
- setValue(this, memberName, newValue, cmpMeta);
1266
- },
1267
- configurable: true,
1268
- enumerable: true
1319
+ const ref = getHostRef(this);
1320
+ if (origSetter) {
1321
+ const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
1322
+ if (typeof currentValue === "undefined" && ref.$instanceValues$.get(memberName)) {
1323
+ newValue = ref.$instanceValues$.get(memberName);
1324
+ } else if (!ref.$instanceValues$.get(memberName) && currentValue) {
1325
+ ref.$instanceValues$.set(memberName, currentValue);
1326
+ }
1327
+ origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
1328
+ newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
1329
+ setValue(this, memberName, newValue, cmpMeta);
1330
+ return;
1331
+ }
1332
+ {
1333
+ if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
1334
+ setValue(this, memberName, newValue, cmpMeta);
1335
+ if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
1336
+ ref.$onReadyPromise$.then(() => {
1337
+ if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
1338
+ ref.$lazyInstance$[memberName] = newValue;
1339
+ }
1340
+ });
1341
+ }
1342
+ return;
1343
+ }
1344
+ const setterSetVal = () => {
1345
+ const currentValue = ref.$lazyInstance$[memberName];
1346
+ if (!ref.$instanceValues$.get(memberName) && currentValue) {
1347
+ ref.$instanceValues$.set(memberName, currentValue);
1348
+ }
1349
+ ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
1350
+ setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
1351
+ };
1352
+ if (ref.$lazyInstance$) {
1353
+ setterSetVal();
1354
+ } else {
1355
+ ref.$onReadyPromise$.then(() => setterSetVal());
1356
+ }
1357
+ }
1358
+ }
1269
1359
  });
1270
1360
  }
1271
1361
  });
@@ -1275,7 +1365,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1275
1365
  plt.jmp(() => {
1276
1366
  var _a2;
1277
1367
  const propName = attrNameToPropName.get(attrName);
1278
- if (this.hasOwnProperty(propName)) {
1368
+ if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {
1279
1369
  newValue = this[propName];
1280
1370
  delete this[propName];
1281
1371
  } else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && // cast type to number to avoid TS compiler issues
@@ -1295,7 +1385,11 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1295
1385
  }
1296
1386
  return;
1297
1387
  }
1298
- this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
1388
+ const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
1389
+ newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
1390
+ if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
1391
+ this[propName] = newValue;
1392
+ }
1299
1393
  });
1300
1394
  };
1301
1395
  Cstr.observedAttributes = Array.from(
@@ -1322,9 +1416,8 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1322
1416
  let Cstr;
1323
1417
  if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
1324
1418
  hostRef.$flags$ |= 32 /* hasInitializedComponent */;
1325
- const bundleId = cmpMeta.$lazyBundleId$;
1326
- if (bundleId) {
1327
- const CstrImport = loadModule(cmpMeta);
1419
+ {
1420
+ const CstrImport = loadModule(cmpMeta, hostRef);
1328
1421
  if (CstrImport && "then" in CstrImport) {
1329
1422
  const endLoad = uniqueTime();
1330
1423
  Cstr = await CstrImport;
@@ -1349,7 +1442,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1349
1442
  try {
1350
1443
  new Cstr(hostRef);
1351
1444
  } catch (e) {
1352
- consoleError(e);
1445
+ consoleError(e, elm);
1353
1446
  }
1354
1447
  {
1355
1448
  hostRef.$flags$ &= ~8 /* isConstructingInstance */;
@@ -1358,10 +1451,6 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1358
1451
  hostRef.$flags$ |= 128 /* isWatchReady */;
1359
1452
  }
1360
1453
  endNewInstance();
1361
- } else {
1362
- Cstr = elm.constructor;
1363
- const cmpTag = elm.localName;
1364
- customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);
1365
1454
  }
1366
1455
  if (Cstr && Cstr.style) {
1367
1456
  let style;
@@ -1384,7 +1473,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1384
1473
  schedule();
1385
1474
  }
1386
1475
  };
1387
- var fireConnectedCallback = (instance) => {
1476
+ var fireConnectedCallback = (instance, elm) => {
1388
1477
  };
1389
1478
 
1390
1479
  // src/runtime/connected-callback.ts
@@ -1438,7 +1527,7 @@ var setContentReference = (elm) => {
1438
1527
  contentRefElm["s-cn"] = true;
1439
1528
  insertBefore(elm, contentRefElm, elm.firstChild);
1440
1529
  };
1441
- var disconnectInstance = (instance) => {
1530
+ var disconnectInstance = (instance, elm) => {
1442
1531
  };
1443
1532
  var disconnectedCallback = async (elm) => {
1444
1533
  if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
@@ -1453,6 +1542,12 @@ var disconnectedCallback = async (elm) => {
1453
1542
  hostRef.$onReadyPromise$.then(() => disconnectInstance());
1454
1543
  }
1455
1544
  }
1545
+ if (rootAppliedStyles.has(elm)) {
1546
+ rootAppliedStyles.delete(elm);
1547
+ }
1548
+ if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
1549
+ rootAppliedStyles.delete(elm.shadowRoot);
1550
+ }
1456
1551
  };
1457
1552
 
1458
1553
  // src/runtime/bootstrap-lazy.ts
@@ -1537,6 +1632,13 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
1537
1632
  }
1538
1633
  disconnectedCallback() {
1539
1634
  plt.jmp(() => disconnectedCallback(this));
1635
+ plt.raf(() => {
1636
+ var _a3;
1637
+ const hostRef = getHostRef(this);
1638
+ if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
1639
+ delete hostRef.$vnode$.$elm$;
1640
+ }
1641
+ });
1540
1642
  }
1541
1643
  componentOnReady() {
1542
1644
  return getHostRef(this).$onReadyPromise$;
@@ -1603,7 +1705,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
1603
1705
  }
1604
1706
  }
1605
1707
  } catch (e) {
1606
- consoleError(e);
1708
+ consoleError(e, hostRef.$hostElement$);
1607
1709
  }
1608
1710
  };
1609
1711
  var getHostListenerTarget = (elm, flags) => {