lwc 2.23.5 → 2.24.0

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 (39) hide show
  1. package/dist/engine-dom/esm/es2017/engine-dom.js +216 -69
  2. package/dist/engine-dom/iife/es2017/engine-dom.js +216 -69
  3. package/dist/engine-dom/iife/es2017/engine-dom.min.js +1 -1
  4. package/dist/engine-dom/iife/es2017/engine-dom_debug.js +194 -67
  5. package/dist/engine-dom/iife/es5/engine-dom.js +494 -313
  6. package/dist/engine-dom/iife/es5/engine-dom.min.js +1 -1
  7. package/dist/engine-dom/iife/es5/engine-dom_debug.js +463 -299
  8. package/dist/engine-dom/umd/es2017/engine-dom.js +216 -69
  9. package/dist/engine-dom/umd/es2017/engine-dom.min.js +1 -1
  10. package/dist/engine-dom/umd/es2017/engine-dom_debug.js +194 -67
  11. package/dist/engine-dom/umd/es5/engine-dom.js +494 -313
  12. package/dist/engine-dom/umd/es5/engine-dom.min.js +1 -1
  13. package/dist/engine-dom/umd/es5/engine-dom_debug.js +463 -299
  14. package/dist/engine-server/commonjs/es2017/engine-server.js +124 -16
  15. package/dist/engine-server/commonjs/es2017/engine-server.min.js +1 -1
  16. package/dist/engine-server/esm/es2017/engine-server.js +124 -16
  17. package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js +205 -168
  18. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js +205 -168
  19. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.min.js +2 -2
  20. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js +195 -158
  21. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js +25 -11
  22. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.min.js +2 -2
  23. package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js +25 -11
  24. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js +205 -168
  25. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.min.js +2 -2
  26. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js +195 -158
  27. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js +25 -11
  28. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.min.js +2 -2
  29. package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js +25 -11
  30. package/dist/wire-service/esm/es2017/wire-service.js +2 -2
  31. package/dist/wire-service/iife/es2017/wire-service.js +2 -2
  32. package/dist/wire-service/iife/es2017/wire-service_debug.js +2 -2
  33. package/dist/wire-service/iife/es5/wire-service.js +2 -2
  34. package/dist/wire-service/iife/es5/wire-service_debug.js +2 -2
  35. package/dist/wire-service/umd/es2017/wire-service.js +2 -2
  36. package/dist/wire-service/umd/es2017/wire-service_debug.js +2 -2
  37. package/dist/wire-service/umd/es5/wire-service.js +2 -2
  38. package/dist/wire-service/umd/es5/wire-service_debug.js +2 -2
  39. package/package.json +7 -7
@@ -87,7 +87,7 @@
87
87
  const KEY__SHADOW_TOKEN = '$shadowToken$';
88
88
  const KEY__SHADOW_TOKEN_PRIVATE = '$$ShadowTokenKey$$';
89
89
  const KEY__SYNTHETIC_MODE = '$$lwc-synthetic-mode';
90
- /** version: 2.23.5 */
90
+ /** version: 2.24.0 */
91
91
 
92
92
  /*
93
93
  * Copyright (c) 2018, salesforce.com, inc.
@@ -401,7 +401,7 @@
401
401
  Object.defineProperty(_globalThis, 'lwcRuntimeFlags', { value: create(null) });
402
402
  }
403
403
  const lwcRuntimeFlags = _globalThis.lwcRuntimeFlags;
404
- /** version: 2.23.5 */
404
+ /** version: 2.24.0 */
405
405
 
406
406
  /*
407
407
  * Copyright (c) 2018, salesforce.com, inc.
@@ -479,191 +479,228 @@
479
479
  * SPDX-License-Identifier: MIT
480
480
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
481
481
  */
482
- // when finding a slot in the DOM, we can fold it if it is contained
483
482
  // inside another slot.
483
+
484
484
  function foldSlotElement(slot) {
485
- let parent = parentElementGetter.call(slot);
486
- while (!isNull(parent) && isSlotElement(parent)) {
487
- slot = parent;
488
- parent = parentElementGetter.call(slot);
489
- }
490
- return slot;
485
+ let parent = parentElementGetter.call(slot);
486
+
487
+ while (!isNull(parent) && isSlotElement(parent)) {
488
+ slot = parent;
489
+ parent = parentElementGetter.call(slot);
490
+ }
491
+
492
+ return slot;
491
493
  }
494
+
492
495
  function isNodeSlotted(host, node) {
493
- const hostKey = getNodeKey(host);
494
- // this routine assumes that the node is coming from a different shadow (it is not owned by the host)
495
- // just in case the provided node is not an element
496
- let currentElement = node instanceof Element ? node : parentElementGetter.call(node);
497
- while (!isNull(currentElement) && currentElement !== host) {
498
- const elmOwnerKey = getNodeNearestOwnerKey(currentElement);
499
- const parent = parentElementGetter.call(currentElement);
500
- if (elmOwnerKey === hostKey) {
501
- // we have reached an element inside the host's template, and only if
502
- // that element is an slot, then the node is considered slotted
503
- return isSlotElement(currentElement);
504
- }
505
- else if (parent === host) {
506
- return false;
507
- }
508
- else if (!isNull(parent) && getNodeNearestOwnerKey(parent) !== elmOwnerKey) {
509
- // we are crossing a boundary of some sort since the elm and its parent
510
- // have different owner key. for slotted elements, this is possible
511
- // if the parent happens to be a slot.
512
- if (isSlotElement(parent)) {
513
- /**
514
- * the slot parent might be allocated inside another slot, think of:
515
- * <x-root> (<--- root element)
516
- * <x-parent> (<--- own by x-root)
517
- * <x-child> (<--- own by x-root)
518
- * <slot> (<--- own by x-child)
519
- * <slot> (<--- own by x-parent)
520
- * <div> (<--- own by x-root)
521
- *
522
- * while checking if x-parent has the div slotted, we need to traverse
523
- * up, but when finding the first slot, we skip that one in favor of the
524
- * most outer slot parent before jumping into its corresponding host.
525
- */
526
- currentElement = getNodeOwner(foldSlotElement(parent));
527
- if (!isNull(currentElement)) {
528
- if (currentElement === host) {
529
- // the slot element is a top level element inside the shadow
530
- // of a host that was allocated into host in question
531
- return true;
532
- }
533
- else if (getNodeNearestOwnerKey(currentElement) === hostKey) {
534
- // the slot element is an element inside the shadow
535
- // of a host that was allocated into host in question
536
- return true;
537
- }
538
- }
539
- }
540
- else {
541
- return false;
542
- }
543
- }
544
- else {
545
- currentElement = parent;
496
+
497
+ const hostKey = getNodeKey(host); // this routine assumes that the node is coming from a different shadow (it is not owned by the host)
498
+ // just in case the provided node is not an element
499
+
500
+ let currentElement = node instanceof Element ? node : parentElementGetter.call(node);
501
+
502
+ while (!isNull(currentElement) && currentElement !== host) {
503
+ const elmOwnerKey = getNodeNearestOwnerKey(currentElement);
504
+ const parent = parentElementGetter.call(currentElement);
505
+
506
+ if (elmOwnerKey === hostKey) {
507
+ // we have reached an element inside the host's template, and only if
508
+ // that element is an slot, then the node is considered slotted
509
+ return isSlotElement(currentElement);
510
+ } else if (parent === host) {
511
+ return false;
512
+ } else if (!isNull(parent) && getNodeNearestOwnerKey(parent) !== elmOwnerKey) {
513
+ // we are crossing a boundary of some sort since the elm and its parent
514
+ // have different owner key. for slotted elements, this is possible
515
+ // if the parent happens to be a slot.
516
+ if (isSlotElement(parent)) {
517
+ /**
518
+ * the slot parent might be allocated inside another slot, think of:
519
+ * <x-root> (<--- root element)
520
+ * <x-parent> (<--- own by x-root)
521
+ * <x-child> (<--- own by x-root)
522
+ * <slot> (<--- own by x-child)
523
+ * <slot> (<--- own by x-parent)
524
+ * <div> (<--- own by x-root)
525
+ *
526
+ * while checking if x-parent has the div slotted, we need to traverse
527
+ * up, but when finding the first slot, we skip that one in favor of the
528
+ * most outer slot parent before jumping into its corresponding host.
529
+ */
530
+ currentElement = getNodeOwner(foldSlotElement(parent));
531
+
532
+ if (!isNull(currentElement)) {
533
+ if (currentElement === host) {
534
+ // the slot element is a top level element inside the shadow
535
+ // of a host that was allocated into host in question
536
+ return true;
537
+ } else if (getNodeNearestOwnerKey(currentElement) === hostKey) {
538
+ // the slot element is an element inside the shadow
539
+ // of a host that was allocated into host in question
540
+ return true;
541
+ }
546
542
  }
543
+ } else {
544
+ return false;
545
+ }
546
+ } else {
547
+ currentElement = parent;
547
548
  }
548
- return false;
549
+ }
550
+
551
+ return false;
549
552
  }
553
+
550
554
  function getNodeOwner(node) {
551
- if (!(node instanceof _Node)) {
552
- return null;
553
- }
554
- const ownerKey = getNodeNearestOwnerKey(node);
555
- if (isUndefined(ownerKey)) {
556
- return null;
557
- }
558
- let nodeOwner = node;
559
- // At this point, node is a valid node with owner identity, now we need to find the owner node
560
- // search for a custom element with a VM that owns the first element with owner identity attached to it
561
- while (!isNull(nodeOwner) && getNodeKey(nodeOwner) !== ownerKey) {
562
- nodeOwner = parentNodeGetter.call(nodeOwner);
563
- }
564
- if (isNull(nodeOwner)) {
565
- return null;
566
- }
567
- return nodeOwner;
555
+ if (!(node instanceof _Node)) {
556
+ return null;
557
+ }
558
+
559
+ const ownerKey = getNodeNearestOwnerKey(node);
560
+
561
+ if (isUndefined(ownerKey)) {
562
+ return null;
563
+ }
564
+
565
+ let nodeOwner = node; // At this point, node is a valid node with owner identity, now we need to find the owner node
566
+ // search for a custom element with a VM that owns the first element with owner identity attached to it
567
+
568
+ while (!isNull(nodeOwner) && getNodeKey(nodeOwner) !== ownerKey) {
569
+ nodeOwner = parentNodeGetter.call(nodeOwner);
570
+ }
571
+
572
+ if (isNull(nodeOwner)) {
573
+ return null;
574
+ }
575
+
576
+ return nodeOwner;
568
577
  }
569
578
  function isSyntheticSlotElement(node) {
570
- return isSlotElement(node) && isNodeShadowed(node);
579
+ return isSlotElement(node) && isNodeShadowed(node);
571
580
  }
572
581
  function isSlotElement(node) {
573
- return node instanceof HTMLSlotElement;
582
+ return node instanceof HTMLSlotElement;
574
583
  }
575
584
  function isNodeOwnedBy(owner, node) {
576
- const ownerKey = getNodeNearestOwnerKey(node);
577
- return isUndefined(ownerKey) || getNodeKey(owner) === ownerKey;
585
+
586
+ const ownerKey = getNodeNearestOwnerKey(node);
587
+
588
+ if (isUndefined(ownerKey)) {
589
+ if (lwcRuntimeFlags.ENABLE_LIGHT_GET_ROOT_NODE_PATCH) {
590
+ // in case of root level light DOM element slotting into a synthetic shadow
591
+ const host = parentNodeGetter.call(node);
592
+
593
+ if (!isNull(host) && isSyntheticSlotElement(host)) {
594
+ return false;
595
+ }
596
+ } // in case of manually inserted elements
597
+
598
+
599
+ return true;
600
+ }
601
+
602
+ return getNodeKey(owner) === ownerKey;
578
603
  }
579
604
  function shadowRootChildNodes(root) {
580
- const elm = getHost(root);
581
- return getAllMatches(elm, arrayFromCollection(childNodesGetter.call(elm)));
605
+ const elm = getHost(root);
606
+ return getAllMatches(elm, arrayFromCollection(childNodesGetter.call(elm)));
582
607
  }
583
608
  function getAllSlottedMatches(host, nodeList) {
584
- const filteredAndPatched = [];
585
- for (let i = 0, len = nodeList.length; i < len; i += 1) {
586
- const node = nodeList[i];
587
- if (!isNodeOwnedBy(host, node) && isNodeSlotted(host, node)) {
588
- ArrayPush.call(filteredAndPatched, node);
589
- }
609
+ const filteredAndPatched = [];
610
+
611
+ for (let i = 0, len = nodeList.length; i < len; i += 1) {
612
+ const node = nodeList[i];
613
+
614
+ if (!isNodeOwnedBy(host, node) && isNodeSlotted(host, node)) {
615
+ ArrayPush.call(filteredAndPatched, node);
590
616
  }
591
- return filteredAndPatched;
617
+ }
618
+
619
+ return filteredAndPatched;
592
620
  }
593
621
  function getFirstSlottedMatch(host, nodeList) {
594
- for (let i = 0, len = nodeList.length; i < len; i += 1) {
595
- const node = nodeList[i];
596
- if (!isNodeOwnedBy(host, node) && isNodeSlotted(host, node)) {
597
- return node;
598
- }
622
+ for (let i = 0, len = nodeList.length; i < len; i += 1) {
623
+ const node = nodeList[i];
624
+
625
+ if (!isNodeOwnedBy(host, node) && isNodeSlotted(host, node)) {
626
+ return node;
599
627
  }
600
- return null;
628
+ }
629
+
630
+ return null;
601
631
  }
602
632
  function getAllMatches(owner, nodeList) {
603
- const filteredAndPatched = [];
604
- for (let i = 0, len = nodeList.length; i < len; i += 1) {
605
- const node = nodeList[i];
606
- const isOwned = isNodeOwnedBy(owner, node);
607
- if (isOwned) {
608
- // Patch querySelector, querySelectorAll, etc
609
- // if element is owned by VM
610
- ArrayPush.call(filteredAndPatched, node);
611
- }
633
+ const filteredAndPatched = [];
634
+
635
+ for (let i = 0, len = nodeList.length; i < len; i += 1) {
636
+ const node = nodeList[i];
637
+ const isOwned = isNodeOwnedBy(owner, node);
638
+
639
+ if (isOwned) {
640
+ // Patch querySelector, querySelectorAll, etc
641
+ // if element is owned by VM
642
+ ArrayPush.call(filteredAndPatched, node);
612
643
  }
613
- return filteredAndPatched;
644
+ }
645
+
646
+ return filteredAndPatched;
614
647
  }
615
648
  function getFirstMatch(owner, nodeList) {
616
- for (let i = 0, len = nodeList.length; i < len; i += 1) {
617
- if (isNodeOwnedBy(owner, nodeList[i])) {
618
- return nodeList[i];
619
- }
649
+ for (let i = 0, len = nodeList.length; i < len; i += 1) {
650
+ if (isNodeOwnedBy(owner, nodeList[i])) {
651
+ return nodeList[i];
620
652
  }
621
- return null;
653
+ }
654
+
655
+ return null;
622
656
  }
623
657
  function shadowRootQuerySelector(root, selector) {
624
- const elm = getHost(root);
625
- const nodeList = arrayFromCollection(querySelectorAll$1.call(elm, selector));
626
- return getFirstMatch(elm, nodeList);
658
+ const elm = getHost(root);
659
+ const nodeList = arrayFromCollection(querySelectorAll$1.call(elm, selector));
660
+ return getFirstMatch(elm, nodeList);
627
661
  }
628
662
  function shadowRootQuerySelectorAll(root, selector) {
629
- const elm = getHost(root);
630
- const nodeList = querySelectorAll$1.call(elm, selector);
631
- return getAllMatches(elm, arrayFromCollection(nodeList));
663
+ const elm = getHost(root);
664
+ const nodeList = querySelectorAll$1.call(elm, selector);
665
+ return getAllMatches(elm, arrayFromCollection(nodeList));
632
666
  }
633
667
  function getFilteredChildNodes(node) {
634
- if (!isSyntheticShadowHost(node) && !isSlotElement(node)) {
635
- // regular element - fast path
636
- const children = childNodesGetter.call(node);
637
- return arrayFromCollection(children);
638
- }
639
- if (isSyntheticShadowHost(node)) {
640
- // we need to get only the nodes that were slotted
641
- const slots = arrayFromCollection(querySelectorAll$1.call(node, 'slot'));
642
- const resolver = getShadowRootResolver(getShadowRoot(node));
643
- // Typescript is inferring the wrong function type for this particular
644
- // overloaded method: https://github.com/Microsoft/TypeScript/issues/27972
645
- // @ts-ignore type-mismatch
646
- return ArrayReduce.call(slots, (seed, slot) => {
647
- if (resolver === getShadowRootResolver(slot)) {
648
- ArrayPush.apply(seed, getFilteredSlotAssignedNodes(slot));
649
- }
650
- return seed;
651
- }, []);
652
- }
653
- else {
654
- // slot element
655
- const children = arrayFromCollection(childNodesGetter.call(node));
656
- const resolver = getShadowRootResolver(node);
657
- return ArrayFilter.call(children, (child) => resolver === getShadowRootResolver(child));
658
- }
668
+ if (!isSyntheticShadowHost(node) && !isSlotElement(node)) {
669
+ // regular element - fast path
670
+ const children = childNodesGetter.call(node);
671
+ return arrayFromCollection(children);
672
+ }
673
+
674
+ if (isSyntheticShadowHost(node)) {
675
+ // we need to get only the nodes that were slotted
676
+ const slots = arrayFromCollection(querySelectorAll$1.call(node, 'slot'));
677
+ const resolver = getShadowRootResolver(getShadowRoot(node)); // Typescript is inferring the wrong function type for this particular
678
+ // overloaded method: https://github.com/Microsoft/TypeScript/issues/27972
679
+ // @ts-ignore type-mismatch
680
+
681
+ return ArrayReduce.call(slots, (seed, slot) => {
682
+ if (resolver === getShadowRootResolver(slot)) {
683
+ ArrayPush.apply(seed, getFilteredSlotAssignedNodes(slot));
684
+ }
685
+
686
+ return seed;
687
+ }, []);
688
+ } else {
689
+ // slot element
690
+ const children = arrayFromCollection(childNodesGetter.call(node));
691
+ const resolver = getShadowRootResolver(node);
692
+ return ArrayFilter.call(children, child => resolver === getShadowRootResolver(child));
693
+ }
659
694
  }
660
695
  function getFilteredSlotAssignedNodes(slot) {
661
- const owner = getNodeOwner(slot);
662
- if (isNull(owner)) {
663
- return [];
664
- }
665
- const childNodes = arrayFromCollection(childNodesGetter.call(slot));
666
- return ArrayFilter.call(childNodes, (child) => !isNodeShadowed(child) || !isNodeOwnedBy(owner, child));
696
+ const owner = getNodeOwner(slot);
697
+
698
+ if (isNull(owner)) {
699
+ return [];
700
+ }
701
+
702
+ const childNodes = arrayFromCollection(childNodesGetter.call(slot));
703
+ return ArrayFilter.call(childNodes, child => !isNodeShadowed(child) || !isNodeOwnedBy(owner, child));
667
704
  }
668
705
 
669
706
  /*
@@ -3797,11 +3834,11 @@
3797
3834
  // element with shadowRoot attached
3798
3835
  const owner = getNodeOwner(this);
3799
3836
 
3800
- if (isNull(owner)) {
3801
- return null;
3802
- } else if (getNodeKey(this)) {
3837
+ if (!isUndefined(getNodeKey(this))) {
3803
3838
  // it is a custom element, and we should then filter by slotted elements
3804
3839
  return getFirstSlottedMatch(this, nodeList);
3840
+ } else if (isNull(owner)) {
3841
+ return null;
3805
3842
  } else {
3806
3843
  // regular element, we should then filter by ownership
3807
3844
  return getFirstMatch(owner, nodeList);
@@ -3848,11 +3885,11 @@
3848
3885
  // element with shadowRoot attached
3849
3886
  const owner = getNodeOwner(context);
3850
3887
 
3851
- if (isNull(owner)) {
3852
- filtered = [];
3853
- } else if (getNodeKey(context)) {
3888
+ if (!isUndefined(getNodeKey(context))) {
3854
3889
  // it is a custom element, and we should then filter by slotted elements
3855
3890
  filtered = getAllSlottedMatches(context, unfilteredNodes);
3891
+ } else if (isNull(owner)) {
3892
+ filtered = [];
3856
3893
  } else {
3857
3894
  // regular element, we should then filter by ownership
3858
3895
  filtered = getAllMatches(owner, unfilteredNodes);
@@ -4934,6 +4971,6 @@
4934
4971
  },
4935
4972
  configurable: true,
4936
4973
  });
4937
- /** version: 2.23.5 */
4974
+ /** version: 2.24.0 */
4938
4975
 
4939
4976
  })();
@@ -199,7 +199,7 @@
199
199
  var hasNativeSymbolSupport = /*@__PURE__*/function () {
200
200
  return Symbol('x').toString() === 'Symbol(x)';
201
201
  }();
202
- /** version: 2.23.5 */
202
+ /** version: 2.24.0 */
203
203
 
204
204
  /*
205
205
  * Copyright (c) 2018, salesforce.com, inc.
@@ -548,7 +548,7 @@
548
548
  }
549
549
 
550
550
  var lwcRuntimeFlags = _globalThis.lwcRuntimeFlags;
551
- /** version: 2.23.5 */
551
+ /** version: 2.24.0 */
552
552
 
553
553
  /*
554
554
  * Copyright (c) 2018, salesforce.com, inc.
@@ -631,7 +631,6 @@
631
631
  * SPDX-License-Identifier: MIT
632
632
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
633
633
  */
634
- // when finding a slot in the DOM, we can fold it if it is contained
635
634
  // inside another slot.
636
635
 
637
636
 
@@ -751,7 +750,22 @@
751
750
  }
752
751
 
753
752
  var ownerKey = getNodeNearestOwnerKey(node);
754
- return isUndefined(ownerKey) || getNodeKey(owner) === ownerKey;
753
+
754
+ if (isUndefined(ownerKey)) {
755
+ if (lwcRuntimeFlags.ENABLE_LIGHT_GET_ROOT_NODE_PATCH) {
756
+ // in case of root level light DOM element slotting into a synthetic shadow
757
+ var host = parentNodeGetter.call(node);
758
+
759
+ if (!isNull(host) && isSyntheticSlotElement(host)) {
760
+ return false;
761
+ }
762
+ } // in case of manually inserted elements
763
+
764
+
765
+ return true;
766
+ }
767
+
768
+ return getNodeKey(owner) === ownerKey;
755
769
  }
756
770
 
757
771
  function shadowRootChildNodes(root) {
@@ -4360,11 +4374,11 @@
4360
4374
  // element with shadowRoot attached
4361
4375
  var owner = getNodeOwner(this);
4362
4376
 
4363
- if (isNull(owner)) {
4364
- return null;
4365
- } else if (getNodeKey(this)) {
4377
+ if (!isUndefined(getNodeKey(this))) {
4366
4378
  // it is a custom element, and we should then filter by slotted elements
4367
4379
  return getFirstSlottedMatch(this, nodeList);
4380
+ } else if (isNull(owner)) {
4381
+ return null;
4368
4382
  } else {
4369
4383
  // regular element, we should then filter by ownership
4370
4384
  return getFirstMatch(owner, nodeList);
@@ -4420,11 +4434,11 @@
4420
4434
  // element with shadowRoot attached
4421
4435
  var owner = getNodeOwner(context);
4422
4436
 
4423
- if (isNull(owner)) {
4424
- filtered = [];
4425
- } else if (getNodeKey(context)) {
4437
+ if (!isUndefined(getNodeKey(context))) {
4426
4438
  // it is a custom element, and we should then filter by slotted elements
4427
4439
  filtered = getAllSlottedMatches(context, unfilteredNodes);
4440
+ } else if (isNull(owner)) {
4441
+ filtered = [];
4428
4442
  } else {
4429
4443
  // regular element, we should then filter by ownership
4430
4444
  filtered = getAllMatches(owner, unfilteredNodes);
@@ -5668,6 +5682,6 @@
5668
5682
  }));
5669
5683
  });
5670
5684
  }
5671
- /** version: 2.23.5 */
5685
+ /** version: 2.24.0 */
5672
5686
 
5673
5687
  })();