lwc 2.6.1 → 2.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/engine-dom/esm/es2017/engine-dom.js +590 -394
- package/dist/engine-dom/iife/es2017/engine-dom.js +590 -394
- package/dist/engine-dom/iife/es2017/engine-dom.min.js +1 -9
- package/dist/engine-dom/iife/es2017/engine-dom_debug.js +564 -370
- package/dist/engine-dom/iife/es5/engine-dom.js +648 -351
- package/dist/engine-dom/iife/es5/engine-dom.min.js +1 -9
- package/dist/engine-dom/iife/es5/engine-dom_debug.js +616 -327
- package/dist/engine-dom/umd/es2017/engine-dom.js +590 -394
- package/dist/engine-dom/umd/es2017/engine-dom.min.js +1 -9
- package/dist/engine-dom/umd/es2017/engine-dom_debug.js +564 -370
- package/dist/engine-dom/umd/es5/engine-dom.js +648 -351
- package/dist/engine-dom/umd/es5/engine-dom.min.js +1 -9
- package/dist/engine-dom/umd/es5/engine-dom_debug.js +616 -327
- package/dist/engine-server/commonjs/es2017/engine-server.js +670 -472
- package/dist/engine-server/commonjs/es2017/engine-server.min.js +1 -9
- package/dist/engine-server/esm/es2017/engine-server.js +670 -472
- package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js +74 -9
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js +74 -9
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.min.js +2 -2
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js +74 -9
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js +85 -12
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow.min.js +2 -2
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js +85 -12
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js +74 -9
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.min.js +2 -2
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js +74 -9
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js +85 -12
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow.min.js +2 -2
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js +85 -12
- package/dist/wire-service/esm/es2017/wire-service.js +2 -2
- package/dist/wire-service/iife/es2017/wire-service.js +2 -2
- package/dist/wire-service/iife/es2017/wire-service_debug.js +2 -2
- package/dist/wire-service/iife/es5/wire-service.js +11 -11
- package/dist/wire-service/iife/es5/wire-service.min.js +1 -1
- package/dist/wire-service/iife/es5/wire-service_debug.js +11 -11
- package/dist/wire-service/umd/es2017/wire-service.js +2 -2
- package/dist/wire-service/umd/es2017/wire-service_debug.js +2 -2
- package/dist/wire-service/umd/es5/wire-service.js +11 -11
- package/dist/wire-service/umd/es5/wire-service.min.js +1 -1
- package/dist/wire-service/umd/es5/wire-service_debug.js +11 -11
- package/package.json +8 -8
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
|
|
25
25
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
26
26
|
|
|
27
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
27
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
28
28
|
|
|
29
29
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
30
30
|
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
|
|
43
43
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
44
44
|
|
|
45
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
45
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
46
46
|
|
|
47
47
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
48
48
|
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
|
|
59
59
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
60
60
|
|
|
61
|
-
function _typeof(obj) { "@babel/helpers - typeof";
|
|
61
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
62
62
|
|
|
63
63
|
/* proxy-compat-disable */
|
|
64
64
|
|
|
@@ -351,7 +351,7 @@
|
|
|
351
351
|
CACHED_PROPERTY_ATTRIBUTE_MAPPING.set(propName, attributeName);
|
|
352
352
|
return attributeName;
|
|
353
353
|
}
|
|
354
|
-
/** version: 2.
|
|
354
|
+
/** version: 2.7.2 */
|
|
355
355
|
|
|
356
356
|
/*
|
|
357
357
|
* Copyright (c) 2018, salesforce.com, inc.
|
|
@@ -463,7 +463,6 @@
|
|
|
463
463
|
ENABLE_NODE_LIST_PATCH: null,
|
|
464
464
|
ENABLE_HTML_COLLECTIONS_PATCH: null,
|
|
465
465
|
ENABLE_NODE_PATCH: null,
|
|
466
|
-
ENABLE_MIXED_SHADOW_MODE: null,
|
|
467
466
|
ENABLE_WIRE_SYNC_EMIT: null
|
|
468
467
|
};
|
|
469
468
|
|
|
@@ -530,7 +529,7 @@
|
|
|
530
529
|
setFeatureFlag(name, value);
|
|
531
530
|
}
|
|
532
531
|
}
|
|
533
|
-
/** version: 2.
|
|
532
|
+
/** version: 2.7.2 */
|
|
534
533
|
|
|
535
534
|
/* proxy-compat-disable */
|
|
536
535
|
|
|
@@ -618,6 +617,249 @@
|
|
|
618
617
|
}
|
|
619
618
|
|
|
620
619
|
return styleMap;
|
|
620
|
+
} //
|
|
621
|
+
// Primitives
|
|
622
|
+
//
|
|
623
|
+
|
|
624
|
+
|
|
625
|
+
var ssr$1;
|
|
626
|
+
|
|
627
|
+
function setSsr(ssrImpl) {
|
|
628
|
+
ssr$1 = ssrImpl;
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
var isNativeShadowDefined$1;
|
|
632
|
+
|
|
633
|
+
function setIsNativeShadowDefined(isNativeShadowDefinedImpl) {
|
|
634
|
+
isNativeShadowDefined$1 = isNativeShadowDefinedImpl;
|
|
635
|
+
}
|
|
636
|
+
|
|
637
|
+
var isSyntheticShadowDefined$1;
|
|
638
|
+
|
|
639
|
+
function setIsSyntheticShadowDefined(isSyntheticShadowDefinedImpl) {
|
|
640
|
+
isSyntheticShadowDefined$1 = isSyntheticShadowDefinedImpl;
|
|
641
|
+
}
|
|
642
|
+
|
|
643
|
+
var HTMLElementExported$1;
|
|
644
|
+
|
|
645
|
+
function setHTMLElement(HTMLElementImpl) {
|
|
646
|
+
HTMLElementExported$1 = HTMLElementImpl;
|
|
647
|
+
}
|
|
648
|
+
|
|
649
|
+
var isHydrating$1;
|
|
650
|
+
|
|
651
|
+
function setIsHydrating$1(isHydratingImpl) {
|
|
652
|
+
isHydrating$1 = isHydratingImpl;
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
var insert$1;
|
|
656
|
+
|
|
657
|
+
function setInsert(insertImpl) {
|
|
658
|
+
insert$1 = insertImpl;
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
var remove$1;
|
|
662
|
+
|
|
663
|
+
function setRemove(removeImpl) {
|
|
664
|
+
remove$1 = removeImpl;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
var createElement$2;
|
|
668
|
+
|
|
669
|
+
function setCreateElement(createElementImpl) {
|
|
670
|
+
createElement$2 = createElementImpl;
|
|
671
|
+
}
|
|
672
|
+
|
|
673
|
+
var createText$1;
|
|
674
|
+
|
|
675
|
+
function setCreateText(createTextImpl) {
|
|
676
|
+
createText$1 = createTextImpl;
|
|
677
|
+
}
|
|
678
|
+
|
|
679
|
+
var createComment$1;
|
|
680
|
+
|
|
681
|
+
function setCreateComment(createCommentImpl) {
|
|
682
|
+
createComment$1 = createCommentImpl;
|
|
683
|
+
}
|
|
684
|
+
|
|
685
|
+
var nextSibling$1;
|
|
686
|
+
|
|
687
|
+
function setNextSibling(nextSiblingImpl) {
|
|
688
|
+
nextSibling$1 = nextSiblingImpl;
|
|
689
|
+
}
|
|
690
|
+
|
|
691
|
+
var attachShadow$1;
|
|
692
|
+
|
|
693
|
+
function setAttachShadow(attachShadowImpl) {
|
|
694
|
+
attachShadow$1 = attachShadowImpl;
|
|
695
|
+
}
|
|
696
|
+
|
|
697
|
+
var getProperty$1;
|
|
698
|
+
|
|
699
|
+
function setGetProperty(getPropertyImpl) {
|
|
700
|
+
getProperty$1 = getPropertyImpl;
|
|
701
|
+
}
|
|
702
|
+
|
|
703
|
+
var setProperty$1;
|
|
704
|
+
|
|
705
|
+
function setSetProperty(setPropertyImpl) {
|
|
706
|
+
setProperty$1 = setPropertyImpl;
|
|
707
|
+
}
|
|
708
|
+
|
|
709
|
+
var setText$1;
|
|
710
|
+
|
|
711
|
+
function setSetText(setTextImpl) {
|
|
712
|
+
setText$1 = setTextImpl;
|
|
713
|
+
}
|
|
714
|
+
|
|
715
|
+
var getAttribute$1;
|
|
716
|
+
|
|
717
|
+
function setGetAttribute(getAttributeImpl) {
|
|
718
|
+
getAttribute$1 = getAttributeImpl;
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
var setAttribute$1;
|
|
722
|
+
|
|
723
|
+
function setSetAttribute(setAttributeImpl) {
|
|
724
|
+
setAttribute$1 = setAttributeImpl;
|
|
725
|
+
}
|
|
726
|
+
|
|
727
|
+
var removeAttribute$1;
|
|
728
|
+
|
|
729
|
+
function setRemoveAttribute(removeAttributeImpl) {
|
|
730
|
+
removeAttribute$1 = removeAttributeImpl;
|
|
731
|
+
}
|
|
732
|
+
|
|
733
|
+
var addEventListener$1;
|
|
734
|
+
|
|
735
|
+
function setAddEventListener(addEventListenerImpl) {
|
|
736
|
+
addEventListener$1 = addEventListenerImpl;
|
|
737
|
+
}
|
|
738
|
+
|
|
739
|
+
var removeEventListener$1;
|
|
740
|
+
|
|
741
|
+
function setRemoveEventListener(removeEventListenerImpl) {
|
|
742
|
+
removeEventListener$1 = removeEventListenerImpl;
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
var dispatchEvent$1;
|
|
746
|
+
|
|
747
|
+
function setDispatchEvent(dispatchEventImpl) {
|
|
748
|
+
dispatchEvent$1 = dispatchEventImpl;
|
|
749
|
+
}
|
|
750
|
+
|
|
751
|
+
var getClassList$1;
|
|
752
|
+
|
|
753
|
+
function setGetClassList(getClassListImpl) {
|
|
754
|
+
getClassList$1 = getClassListImpl;
|
|
755
|
+
}
|
|
756
|
+
|
|
757
|
+
var setCSSStyleProperty$1;
|
|
758
|
+
|
|
759
|
+
function setSetCSSStyleProperty(setCSSStylePropertyImpl) {
|
|
760
|
+
setCSSStyleProperty$1 = setCSSStylePropertyImpl;
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
var getBoundingClientRect$1;
|
|
764
|
+
|
|
765
|
+
function setGetBoundingClientRect(getBoundingClientRectImpl) {
|
|
766
|
+
getBoundingClientRect$1 = getBoundingClientRectImpl;
|
|
767
|
+
}
|
|
768
|
+
|
|
769
|
+
var querySelector$1;
|
|
770
|
+
|
|
771
|
+
function setQuerySelector(querySelectorImpl) {
|
|
772
|
+
querySelector$1 = querySelectorImpl;
|
|
773
|
+
}
|
|
774
|
+
|
|
775
|
+
var querySelectorAll$1;
|
|
776
|
+
|
|
777
|
+
function setQuerySelectorAll(querySelectorAllImpl) {
|
|
778
|
+
querySelectorAll$1 = querySelectorAllImpl;
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
var getElementsByTagName$1;
|
|
782
|
+
|
|
783
|
+
function setGetElementsByTagName(getElementsByTagNameImpl) {
|
|
784
|
+
getElementsByTagName$1 = getElementsByTagNameImpl;
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
var getElementsByClassName$1;
|
|
788
|
+
|
|
789
|
+
function setGetElementsByClassName(getElementsByClassNameImpl) {
|
|
790
|
+
getElementsByClassName$1 = getElementsByClassNameImpl;
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
var getChildren$1;
|
|
794
|
+
|
|
795
|
+
function setGetChildren(getChildrenImpl) {
|
|
796
|
+
getChildren$1 = getChildrenImpl;
|
|
797
|
+
}
|
|
798
|
+
|
|
799
|
+
var getChildNodes$1;
|
|
800
|
+
|
|
801
|
+
function setGetChildNodes(getChildNodesImpl) {
|
|
802
|
+
getChildNodes$1 = getChildNodesImpl;
|
|
803
|
+
}
|
|
804
|
+
|
|
805
|
+
var getFirstChild$1;
|
|
806
|
+
|
|
807
|
+
function setGetFirstChild(getFirstChildImpl) {
|
|
808
|
+
getFirstChild$1 = getFirstChildImpl;
|
|
809
|
+
}
|
|
810
|
+
|
|
811
|
+
var getFirstElementChild$1;
|
|
812
|
+
|
|
813
|
+
function setGetFirstElementChild(getFirstElementChildImpl) {
|
|
814
|
+
getFirstElementChild$1 = getFirstElementChildImpl;
|
|
815
|
+
}
|
|
816
|
+
|
|
817
|
+
var getLastChild$1;
|
|
818
|
+
|
|
819
|
+
function setGetLastChild(getLastChildImpl) {
|
|
820
|
+
getLastChild$1 = getLastChildImpl;
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
var getLastElementChild$1;
|
|
824
|
+
|
|
825
|
+
function setGetLastElementChild(getLastElementChildImpl) {
|
|
826
|
+
getLastElementChild$1 = getLastElementChildImpl;
|
|
827
|
+
}
|
|
828
|
+
|
|
829
|
+
var isConnected$1;
|
|
830
|
+
|
|
831
|
+
function setIsConnected(isConnectedImpl) {
|
|
832
|
+
isConnected$1 = isConnectedImpl;
|
|
833
|
+
}
|
|
834
|
+
|
|
835
|
+
var insertGlobalStylesheet$1;
|
|
836
|
+
|
|
837
|
+
function setInsertGlobalStylesheet(insertGlobalStylesheetImpl) {
|
|
838
|
+
insertGlobalStylesheet$1 = insertGlobalStylesheetImpl;
|
|
839
|
+
}
|
|
840
|
+
|
|
841
|
+
var insertStylesheet$1;
|
|
842
|
+
|
|
843
|
+
function setInsertStylesheet(insertStylesheetImpl) {
|
|
844
|
+
insertStylesheet$1 = insertStylesheetImpl;
|
|
845
|
+
}
|
|
846
|
+
|
|
847
|
+
var assertInstanceOfHTMLElement$1;
|
|
848
|
+
|
|
849
|
+
function setAssertInstanceOfHTMLElement(assertInstanceOfHTMLElementImpl) {
|
|
850
|
+
assertInstanceOfHTMLElement$1 = assertInstanceOfHTMLElementImpl;
|
|
851
|
+
}
|
|
852
|
+
|
|
853
|
+
var defineCustomElement$1;
|
|
854
|
+
|
|
855
|
+
function setDefineCustomElement(defineCustomElementImpl) {
|
|
856
|
+
defineCustomElement$1 = defineCustomElementImpl;
|
|
857
|
+
}
|
|
858
|
+
|
|
859
|
+
var getCustomElement$1;
|
|
860
|
+
|
|
861
|
+
function setGetCustomElement(getCustomElementImpl) {
|
|
862
|
+
getCustomElement$1 = getCustomElementImpl;
|
|
621
863
|
}
|
|
622
864
|
/*
|
|
623
865
|
* Copyright (c) 2019, salesforce.com, inc.
|
|
@@ -869,8 +1111,7 @@
|
|
|
869
1111
|
|
|
870
1112
|
function createAllEventListeners(vnode) {
|
|
871
1113
|
var elm = vnode.elm,
|
|
872
|
-
on = vnode.data.on
|
|
873
|
-
renderer = vnode.owner.renderer;
|
|
1114
|
+
on = vnode.data.on;
|
|
874
1115
|
|
|
875
1116
|
if (isUndefined$1(on)) {
|
|
876
1117
|
return;
|
|
@@ -881,7 +1122,7 @@
|
|
|
881
1122
|
var name;
|
|
882
1123
|
|
|
883
1124
|
for (name in on) {
|
|
884
|
-
|
|
1125
|
+
addEventListener$1(elm, name, listener);
|
|
885
1126
|
}
|
|
886
1127
|
}
|
|
887
1128
|
|
|
@@ -1020,8 +1261,7 @@
|
|
|
1020
1261
|
var ColonCharCode = 58;
|
|
1021
1262
|
|
|
1022
1263
|
function updateAttrs(oldVnode, vnode) {
|
|
1023
|
-
var attrs = vnode.data.attrs
|
|
1024
|
-
renderer = vnode.owner.renderer;
|
|
1264
|
+
var attrs = vnode.data.attrs;
|
|
1025
1265
|
|
|
1026
1266
|
if (isUndefined$1(attrs)) {
|
|
1027
1267
|
return;
|
|
@@ -1038,8 +1278,6 @@
|
|
|
1038
1278
|
}
|
|
1039
1279
|
|
|
1040
1280
|
var elm = vnode.elm;
|
|
1041
|
-
var setAttribute = renderer.setAttribute,
|
|
1042
|
-
removeAttribute = renderer.removeAttribute;
|
|
1043
1281
|
var key;
|
|
1044
1282
|
oldAttrs = isUndefined$1(oldAttrs) ? EmptyObject : oldAttrs; // update modified attributes, add new attributes
|
|
1045
1283
|
// this routine is only useful for data-* attributes in all kind of elements
|
|
@@ -1054,14 +1292,14 @@
|
|
|
1054
1292
|
|
|
1055
1293
|
if (StringCharCodeAt.call(key, 3) === ColonCharCode) {
|
|
1056
1294
|
// Assume xml namespace
|
|
1057
|
-
setAttribute(elm, key, cur, xmlNS);
|
|
1295
|
+
setAttribute$1(elm, key, cur, xmlNS);
|
|
1058
1296
|
} else if (StringCharCodeAt.call(key, 5) === ColonCharCode) {
|
|
1059
1297
|
// Assume xlink namespace
|
|
1060
|
-
setAttribute(elm, key, cur, xlinkNS);
|
|
1061
|
-
} else if (isNull(cur)) {
|
|
1062
|
-
removeAttribute(elm, key);
|
|
1298
|
+
setAttribute$1(elm, key, cur, xlinkNS);
|
|
1299
|
+
} else if (isNull(cur) || isUndefined$1(cur)) {
|
|
1300
|
+
removeAttribute$1(elm, key);
|
|
1063
1301
|
} else {
|
|
1064
|
-
setAttribute(elm, key, cur);
|
|
1302
|
+
setAttribute$1(elm, key, cur);
|
|
1065
1303
|
}
|
|
1066
1304
|
|
|
1067
1305
|
lockAttribute();
|
|
@@ -1110,14 +1348,13 @@
|
|
|
1110
1348
|
|
|
1111
1349
|
var isFirstPatch = isUndefined$1(oldProps);
|
|
1112
1350
|
var elm = vnode.elm,
|
|
1113
|
-
sel = vnode.sel
|
|
1114
|
-
renderer = vnode.owner.renderer;
|
|
1351
|
+
sel = vnode.sel;
|
|
1115
1352
|
|
|
1116
1353
|
for (var key in props) {
|
|
1117
1354
|
var cur = props[key]; // if it is the first time this element is patched, or the current value is different to the previous value...
|
|
1118
1355
|
|
|
1119
|
-
if (isFirstPatch || cur !== (isLiveBindingProp(sel, key) ?
|
|
1120
|
-
|
|
1356
|
+
if (isFirstPatch || cur !== (isLiveBindingProp(sel, key) ? getProperty$1(elm, key) : oldProps[key])) {
|
|
1357
|
+
setProperty$1(elm, key, cur);
|
|
1121
1358
|
}
|
|
1122
1359
|
}
|
|
1123
1360
|
}
|
|
@@ -1185,15 +1422,14 @@
|
|
|
1185
1422
|
|
|
1186
1423
|
function updateClassAttribute(oldVnode, vnode) {
|
|
1187
1424
|
var elm = vnode.elm,
|
|
1188
|
-
newClass = vnode.data.className
|
|
1189
|
-
renderer = vnode.owner.renderer;
|
|
1425
|
+
newClass = vnode.data.className;
|
|
1190
1426
|
var oldClass = oldVnode.data.className;
|
|
1191
1427
|
|
|
1192
1428
|
if (oldClass === newClass) {
|
|
1193
1429
|
return;
|
|
1194
1430
|
}
|
|
1195
1431
|
|
|
1196
|
-
var classList =
|
|
1432
|
+
var classList = getClassList$1(elm);
|
|
1197
1433
|
var newClassMap = getMapFromClassName(newClass);
|
|
1198
1434
|
var oldClassMap = getMapFromClassName(oldClass);
|
|
1199
1435
|
var name;
|
|
@@ -1230,19 +1466,16 @@
|
|
|
1230
1466
|
|
|
1231
1467
|
function updateStyleAttribute(oldVnode, vnode) {
|
|
1232
1468
|
var elm = vnode.elm,
|
|
1233
|
-
newStyle = vnode.data.style
|
|
1234
|
-
renderer = vnode.owner.renderer;
|
|
1235
|
-
var setAttribute = renderer.setAttribute,
|
|
1236
|
-
removeAttribute = renderer.removeAttribute;
|
|
1469
|
+
newStyle = vnode.data.style;
|
|
1237
1470
|
|
|
1238
1471
|
if (oldVnode.data.style === newStyle) {
|
|
1239
1472
|
return;
|
|
1240
1473
|
}
|
|
1241
1474
|
|
|
1242
1475
|
if (!isString(newStyle) || newStyle === '') {
|
|
1243
|
-
removeAttribute(elm, 'style');
|
|
1476
|
+
removeAttribute$1(elm, 'style');
|
|
1244
1477
|
} else {
|
|
1245
|
-
setAttribute(elm, 'style', newStyle);
|
|
1478
|
+
setAttribute$1(elm, 'style', newStyle);
|
|
1246
1479
|
}
|
|
1247
1480
|
}
|
|
1248
1481
|
|
|
@@ -1266,14 +1499,13 @@
|
|
|
1266
1499
|
|
|
1267
1500
|
function createClassAttribute(vnode) {
|
|
1268
1501
|
var elm = vnode.elm,
|
|
1269
|
-
classMap = vnode.data.classMap
|
|
1270
|
-
renderer = vnode.owner.renderer;
|
|
1502
|
+
classMap = vnode.data.classMap;
|
|
1271
1503
|
|
|
1272
1504
|
if (isUndefined$1(classMap)) {
|
|
1273
1505
|
return;
|
|
1274
1506
|
}
|
|
1275
1507
|
|
|
1276
|
-
var classList =
|
|
1508
|
+
var classList = getClassList$1(elm);
|
|
1277
1509
|
|
|
1278
1510
|
for (var name in classMap) {
|
|
1279
1511
|
classList.add(name);
|
|
@@ -1294,8 +1526,7 @@
|
|
|
1294
1526
|
|
|
1295
1527
|
function createStyleAttribute(vnode) {
|
|
1296
1528
|
var elm = vnode.elm,
|
|
1297
|
-
styleDecls = vnode.data.styleDecls
|
|
1298
|
-
renderer = vnode.owner.renderer;
|
|
1529
|
+
styleDecls = vnode.data.styleDecls;
|
|
1299
1530
|
|
|
1300
1531
|
if (isUndefined$1(styleDecls)) {
|
|
1301
1532
|
return;
|
|
@@ -1307,7 +1538,7 @@
|
|
|
1307
1538
|
value = _styleDecls$_i[1],
|
|
1308
1539
|
important = _styleDecls$_i[2];
|
|
1309
1540
|
|
|
1310
|
-
|
|
1541
|
+
setCSSStyleProperty$1(elm, prop, value, important);
|
|
1311
1542
|
}
|
|
1312
1543
|
}
|
|
1313
1544
|
|
|
@@ -1321,15 +1552,6 @@
|
|
|
1321
1552
|
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
|
1322
1553
|
*/
|
|
1323
1554
|
|
|
1324
|
-
/**
|
|
1325
|
-
@license
|
|
1326
|
-
Copyright (c) 2015 Simon Friis Vindum.
|
|
1327
|
-
This code may only be used under the MIT License found at
|
|
1328
|
-
https://github.com/snabbdom/snabbdom/blob/master/LICENSE
|
|
1329
|
-
Code distributed by Snabbdom as part of the Snabbdom project at
|
|
1330
|
-
https://github.com/snabbdom/snabbdom/
|
|
1331
|
-
*/
|
|
1332
|
-
|
|
1333
1555
|
function isUndef(s) {
|
|
1334
1556
|
return s === undefined;
|
|
1335
1557
|
}
|
|
@@ -1417,7 +1639,7 @@
|
|
|
1417
1639
|
} else if (sameVnode(oldStartVnode, newEndVnode)) {
|
|
1418
1640
|
// Vnode moved right
|
|
1419
1641
|
patchVnode(oldStartVnode, newEndVnode);
|
|
1420
|
-
newEndVnode.hook.move(oldStartVnode, parentElm,
|
|
1642
|
+
newEndVnode.hook.move(oldStartVnode, parentElm, nextSibling$1(oldEndVnode.elm));
|
|
1421
1643
|
oldStartVnode = oldCh[++oldStartIdx];
|
|
1422
1644
|
newEndVnode = newCh[--newEndIdx];
|
|
1423
1645
|
} else if (sameVnode(oldEndVnode, newStartVnode)) {
|
|
@@ -1864,7 +2086,7 @@
|
|
|
1864
2086
|
defineProperties(proto, getLightningElementPrototypeRestrictionsDescriptors(proto));
|
|
1865
2087
|
}
|
|
1866
2088
|
/*
|
|
1867
|
-
* Copyright (c)
|
|
2089
|
+
* Copyright (c) 2018, salesforce.com, inc.
|
|
1868
2090
|
* All rights reserved.
|
|
1869
2091
|
* SPDX-License-Identifier: MIT
|
|
1870
2092
|
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
|
@@ -2800,21 +3022,18 @@
|
|
|
2800
3022
|
|
|
2801
3023
|
|
|
2802
3024
|
var LightningElement = function LightningElement() {
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
3025
|
+
// This should be as performant as possible, while any initialization should be done lazily
|
|
2806
3026
|
if (isNull(vmBeingConstructed)) {
|
|
2807
3027
|
throw new ReferenceError('Illegal constructor');
|
|
2808
3028
|
}
|
|
2809
3029
|
|
|
2810
3030
|
var vm = vmBeingConstructed;
|
|
2811
3031
|
var def = vm.def,
|
|
2812
|
-
elm = vm.elm
|
|
2813
|
-
renderer = vm.renderer;
|
|
3032
|
+
elm = vm.elm;
|
|
2814
3033
|
var bridge = def.bridge;
|
|
2815
3034
|
|
|
2816
3035
|
if (process.env.NODE_ENV !== 'production') {
|
|
2817
|
-
|
|
3036
|
+
assertInstanceOfHTMLElement$1(vm.elm, "Component creation requires a DOM element to be associated to ".concat(vm, "."));
|
|
2818
3037
|
}
|
|
2819
3038
|
|
|
2820
3039
|
var component = this;
|
|
@@ -2843,7 +3062,7 @@
|
|
|
2843
3062
|
if (vm.renderMode === 1
|
|
2844
3063
|
/* Shadow */
|
|
2845
3064
|
) {
|
|
2846
|
-
|
|
3065
|
+
doAttachShadow(vm);
|
|
2847
3066
|
} // Adding extra guard rails in DEV mode.
|
|
2848
3067
|
|
|
2849
3068
|
|
|
@@ -2855,15 +3074,14 @@
|
|
|
2855
3074
|
return this;
|
|
2856
3075
|
};
|
|
2857
3076
|
|
|
2858
|
-
function
|
|
2859
|
-
var
|
|
3077
|
+
function doAttachShadow(vm) {
|
|
3078
|
+
var _attachShadow$;
|
|
2860
3079
|
|
|
2861
3080
|
var elm = vm.elm,
|
|
2862
3081
|
mode = vm.mode,
|
|
2863
|
-
renderer = vm.renderer,
|
|
2864
3082
|
shadowMode = vm.shadowMode,
|
|
2865
3083
|
ctor = vm.def.ctor;
|
|
2866
|
-
var cmpRoot =
|
|
3084
|
+
var cmpRoot = attachShadow$1(elm, (_attachShadow$ = {}, _defineProperty(_attachShadow$, KEY__SYNTHETIC_MODE, shadowMode === 1), _defineProperty(_attachShadow$, "delegatesFocus", Boolean(ctor.delegatesFocus)), _defineProperty(_attachShadow$, "mode", mode), _attachShadow$));
|
|
2867
3085
|
vm.cmpRoot = cmpRoot;
|
|
2868
3086
|
associateVM(cmpRoot, vm);
|
|
2869
3087
|
|
|
@@ -2883,15 +3101,13 @@
|
|
|
2883
3101
|
constructor: LightningElement,
|
|
2884
3102
|
dispatchEvent: function dispatchEvent(event) {
|
|
2885
3103
|
var _getAssociatedVM = getAssociatedVM(this),
|
|
2886
|
-
elm = _getAssociatedVM.elm
|
|
2887
|
-
dispatchEvent = _getAssociatedVM.renderer.dispatchEvent;
|
|
3104
|
+
elm = _getAssociatedVM.elm;
|
|
2888
3105
|
|
|
2889
|
-
return dispatchEvent(elm, event);
|
|
3106
|
+
return dispatchEvent$1(elm, event);
|
|
2890
3107
|
},
|
|
2891
3108
|
addEventListener: function addEventListener(type, listener, options) {
|
|
2892
3109
|
var vm = getAssociatedVM(this);
|
|
2893
|
-
var elm = vm.elm
|
|
2894
|
-
addEventListener = vm.renderer.addEventListener;
|
|
3110
|
+
var elm = vm.elm;
|
|
2895
3111
|
|
|
2896
3112
|
if (process.env.NODE_ENV !== 'production') {
|
|
2897
3113
|
var _vmBeingRendered2 = getVMBeingRendered();
|
|
@@ -2902,111 +3118,99 @@
|
|
|
2902
3118
|
}
|
|
2903
3119
|
|
|
2904
3120
|
var wrappedListener = getWrappedComponentsListener(vm, listener);
|
|
2905
|
-
addEventListener(elm, type, wrappedListener, options);
|
|
3121
|
+
addEventListener$1(elm, type, wrappedListener, options);
|
|
2906
3122
|
},
|
|
2907
3123
|
removeEventListener: function removeEventListener(type, listener, options) {
|
|
2908
3124
|
var vm = getAssociatedVM(this);
|
|
2909
|
-
var elm = vm.elm
|
|
2910
|
-
removeEventListener = vm.renderer.removeEventListener;
|
|
3125
|
+
var elm = vm.elm;
|
|
2911
3126
|
var wrappedListener = getWrappedComponentsListener(vm, listener);
|
|
2912
|
-
removeEventListener(elm, type, wrappedListener, options);
|
|
3127
|
+
removeEventListener$1(elm, type, wrappedListener, options);
|
|
2913
3128
|
},
|
|
2914
3129
|
hasAttribute: function hasAttribute(name) {
|
|
2915
3130
|
var _getAssociatedVM2 = getAssociatedVM(this),
|
|
2916
|
-
elm = _getAssociatedVM2.elm
|
|
2917
|
-
getAttribute = _getAssociatedVM2.renderer.getAttribute;
|
|
3131
|
+
elm = _getAssociatedVM2.elm;
|
|
2918
3132
|
|
|
2919
|
-
return !isNull(getAttribute(elm, name));
|
|
3133
|
+
return !isNull(getAttribute$1(elm, name));
|
|
2920
3134
|
},
|
|
2921
3135
|
hasAttributeNS: function hasAttributeNS(namespace, name) {
|
|
2922
3136
|
var _getAssociatedVM3 = getAssociatedVM(this),
|
|
2923
|
-
elm = _getAssociatedVM3.elm
|
|
2924
|
-
getAttribute = _getAssociatedVM3.renderer.getAttribute;
|
|
3137
|
+
elm = _getAssociatedVM3.elm;
|
|
2925
3138
|
|
|
2926
|
-
return !isNull(getAttribute(elm, name, namespace));
|
|
3139
|
+
return !isNull(getAttribute$1(elm, name, namespace));
|
|
2927
3140
|
},
|
|
2928
3141
|
removeAttribute: function removeAttribute(name) {
|
|
2929
3142
|
var _getAssociatedVM4 = getAssociatedVM(this),
|
|
2930
|
-
elm = _getAssociatedVM4.elm
|
|
2931
|
-
removeAttribute = _getAssociatedVM4.renderer.removeAttribute;
|
|
3143
|
+
elm = _getAssociatedVM4.elm;
|
|
2932
3144
|
|
|
2933
3145
|
unlockAttribute(elm, name);
|
|
2934
|
-
removeAttribute(elm, name);
|
|
3146
|
+
removeAttribute$1(elm, name);
|
|
2935
3147
|
lockAttribute();
|
|
2936
3148
|
},
|
|
2937
3149
|
removeAttributeNS: function removeAttributeNS(namespace, name) {
|
|
2938
3150
|
var _getAssociatedVM5 = getAssociatedVM(this),
|
|
2939
|
-
elm = _getAssociatedVM5.elm
|
|
2940
|
-
removeAttribute = _getAssociatedVM5.renderer.removeAttribute;
|
|
3151
|
+
elm = _getAssociatedVM5.elm;
|
|
2941
3152
|
|
|
2942
3153
|
unlockAttribute(elm, name);
|
|
2943
|
-
removeAttribute(elm, name, namespace);
|
|
3154
|
+
removeAttribute$1(elm, name, namespace);
|
|
2944
3155
|
lockAttribute();
|
|
2945
3156
|
},
|
|
2946
3157
|
getAttribute: function getAttribute(name) {
|
|
2947
3158
|
var _getAssociatedVM6 = getAssociatedVM(this),
|
|
2948
|
-
elm = _getAssociatedVM6.elm
|
|
2949
|
-
getAttribute = _getAssociatedVM6.renderer.getAttribute;
|
|
3159
|
+
elm = _getAssociatedVM6.elm;
|
|
2950
3160
|
|
|
2951
|
-
return getAttribute(elm, name);
|
|
3161
|
+
return getAttribute$1(elm, name);
|
|
2952
3162
|
},
|
|
2953
3163
|
getAttributeNS: function getAttributeNS(namespace, name) {
|
|
2954
3164
|
var _getAssociatedVM7 = getAssociatedVM(this),
|
|
2955
|
-
elm = _getAssociatedVM7.elm
|
|
2956
|
-
getAttribute = _getAssociatedVM7.renderer.getAttribute;
|
|
3165
|
+
elm = _getAssociatedVM7.elm;
|
|
2957
3166
|
|
|
2958
|
-
return getAttribute(elm, name, namespace);
|
|
3167
|
+
return getAttribute$1(elm, name, namespace);
|
|
2959
3168
|
},
|
|
2960
3169
|
setAttribute: function setAttribute(name, value) {
|
|
2961
3170
|
var vm = getAssociatedVM(this);
|
|
2962
|
-
var elm = vm.elm
|
|
2963
|
-
setAttribute = vm.renderer.setAttribute;
|
|
3171
|
+
var elm = vm.elm;
|
|
2964
3172
|
|
|
2965
3173
|
if (process.env.NODE_ENV !== 'production') {
|
|
2966
3174
|
assert.isFalse(isBeingConstructed(vm), "Failed to construct '".concat(getComponentTag(vm), "': The result must not have attributes."));
|
|
2967
3175
|
}
|
|
2968
3176
|
|
|
2969
3177
|
unlockAttribute(elm, name);
|
|
2970
|
-
setAttribute(elm, name, value);
|
|
3178
|
+
setAttribute$1(elm, name, value);
|
|
2971
3179
|
lockAttribute();
|
|
2972
3180
|
},
|
|
2973
3181
|
setAttributeNS: function setAttributeNS(namespace, name, value) {
|
|
2974
3182
|
var vm = getAssociatedVM(this);
|
|
2975
|
-
var elm = vm.elm
|
|
2976
|
-
setAttribute = vm.renderer.setAttribute;
|
|
3183
|
+
var elm = vm.elm;
|
|
2977
3184
|
|
|
2978
3185
|
if (process.env.NODE_ENV !== 'production') {
|
|
2979
3186
|
assert.isFalse(isBeingConstructed(vm), "Failed to construct '".concat(getComponentTag(vm), "': The result must not have attributes."));
|
|
2980
3187
|
}
|
|
2981
3188
|
|
|
2982
3189
|
unlockAttribute(elm, name);
|
|
2983
|
-
setAttribute(elm, name, value, namespace);
|
|
3190
|
+
setAttribute$1(elm, name, value, namespace);
|
|
2984
3191
|
lockAttribute();
|
|
2985
3192
|
},
|
|
2986
3193
|
getBoundingClientRect: function getBoundingClientRect() {
|
|
2987
3194
|
var vm = getAssociatedVM(this);
|
|
2988
|
-
var elm = vm.elm
|
|
2989
|
-
getBoundingClientRect = vm.renderer.getBoundingClientRect;
|
|
3195
|
+
var elm = vm.elm;
|
|
2990
3196
|
|
|
2991
3197
|
if (process.env.NODE_ENV !== 'production') {
|
|
2992
3198
|
warnIfInvokedDuringConstruction(vm, 'getBoundingClientRect()');
|
|
2993
3199
|
}
|
|
2994
3200
|
|
|
2995
|
-
return getBoundingClientRect(elm);
|
|
3201
|
+
return getBoundingClientRect$1(elm);
|
|
2996
3202
|
},
|
|
2997
3203
|
|
|
2998
3204
|
get isConnected() {
|
|
2999
3205
|
var _getAssociatedVM8 = getAssociatedVM(this),
|
|
3000
|
-
elm = _getAssociatedVM8.elm
|
|
3001
|
-
isConnected = _getAssociatedVM8.renderer.isConnected;
|
|
3206
|
+
elm = _getAssociatedVM8.elm;
|
|
3002
3207
|
|
|
3003
|
-
return isConnected(elm);
|
|
3208
|
+
return isConnected$1(elm);
|
|
3004
3209
|
},
|
|
3005
3210
|
|
|
3006
3211
|
get classList() {
|
|
3007
3212
|
var vm = getAssociatedVM(this);
|
|
3008
|
-
var elm = vm.elm
|
|
3009
|
-
getClassList = vm.renderer.getClassList;
|
|
3213
|
+
var elm = vm.elm;
|
|
3010
3214
|
|
|
3011
3215
|
if (process.env.NODE_ENV !== 'production') {
|
|
3012
3216
|
// TODO [#1290]: this still fails in dev but works in production, eventually, we should
|
|
@@ -3014,7 +3218,7 @@
|
|
|
3014
3218
|
assert.isFalse(isBeingConstructed(vm), "Failed to construct ".concat(vm, ": The result must not have attributes. Adding or tampering with classname in constructor is not allowed in a web component, use connectedCallback() instead."));
|
|
3015
3219
|
}
|
|
3016
3220
|
|
|
3017
|
-
return getClassList(elm);
|
|
3221
|
+
return getClassList$1(elm);
|
|
3018
3222
|
},
|
|
3019
3223
|
|
|
3020
3224
|
get template() {
|
|
@@ -3046,25 +3250,47 @@
|
|
|
3046
3250
|
return "[object ".concat(vm.def.name, "]");
|
|
3047
3251
|
}
|
|
3048
3252
|
};
|
|
3049
|
-
var queryAndChildGetterDescriptors = create(null);
|
|
3050
|
-
|
|
3253
|
+
var queryAndChildGetterDescriptors = create(null); // The reason we don't just call `import * as renderer from '../renderer'` here is that the bundle size
|
|
3254
|
+
// is smaller if we reference each function individually. Otherwise Rollup will create one big frozen
|
|
3255
|
+
// object representing the renderer, with a lot of methods we don't actually need.
|
|
3051
3256
|
|
|
3052
|
-
var
|
|
3053
|
-
|
|
3054
|
-
|
|
3055
|
-
|
|
3257
|
+
var childGetters = ['children', 'childNodes', 'firstChild', 'firstElementChild', 'lastChild', 'lastElementChild'];
|
|
3258
|
+
|
|
3259
|
+
function getChildGetter(methodName) {
|
|
3260
|
+
switch (methodName) {
|
|
3261
|
+
case 'children':
|
|
3262
|
+
return getChildren$1;
|
|
3263
|
+
|
|
3264
|
+
case 'childNodes':
|
|
3265
|
+
return getChildNodes$1;
|
|
3266
|
+
|
|
3267
|
+
case 'firstChild':
|
|
3268
|
+
return getFirstChild$1;
|
|
3056
3269
|
|
|
3057
|
-
|
|
3270
|
+
case 'firstElementChild':
|
|
3271
|
+
return getFirstElementChild$1;
|
|
3272
|
+
|
|
3273
|
+
case 'lastChild':
|
|
3274
|
+
return getLastChild$1;
|
|
3275
|
+
|
|
3276
|
+
case 'lastElementChild':
|
|
3277
|
+
return getLastElementChild$1;
|
|
3278
|
+
}
|
|
3279
|
+
} // Generic passthrough for child getters on HTMLElement to the relevant Renderer APIs
|
|
3280
|
+
|
|
3281
|
+
|
|
3282
|
+
var _loop = function _loop() {
|
|
3283
|
+
var childGetter = _childGetters[_i9];
|
|
3284
|
+
queryAndChildGetterDescriptors[childGetter] = {
|
|
3058
3285
|
get: function get() {
|
|
3059
3286
|
var vm = getAssociatedVM(this);
|
|
3060
|
-
var elm = vm.elm
|
|
3061
|
-
renderer = vm.renderer;
|
|
3287
|
+
var elm = vm.elm;
|
|
3062
3288
|
|
|
3063
3289
|
if (process.env.NODE_ENV !== 'production') {
|
|
3064
|
-
warnIfInvokedDuringConstruction(vm,
|
|
3290
|
+
warnIfInvokedDuringConstruction(vm, childGetter);
|
|
3065
3291
|
}
|
|
3066
3292
|
|
|
3067
|
-
return
|
|
3293
|
+
return getChildGetter(childGetter)(elm);
|
|
3068
3294
|
},
|
|
3069
3295
|
configurable: true,
|
|
3070
3296
|
enumerable: true
|
|
@@ -3075,21 +3301,37 @@
|
|
|
3075
3301
|
_loop();
|
|
3076
3302
|
}
|
|
3077
3303
|
|
|
3078
|
-
var queryMethods = ['getElementsByClassName', 'getElementsByTagName', 'querySelector', 'querySelectorAll'];
|
|
3304
|
+
var queryMethods = ['getElementsByClassName', 'getElementsByTagName', 'querySelector', 'querySelectorAll'];
|
|
3305
|
+
|
|
3306
|
+
function getQueryMethod(methodName) {
|
|
3307
|
+
switch (methodName) {
|
|
3308
|
+
case 'getElementsByClassName':
|
|
3309
|
+
return getElementsByClassName$1;
|
|
3310
|
+
|
|
3311
|
+
case 'getElementsByTagName':
|
|
3312
|
+
return getElementsByTagName$1;
|
|
3313
|
+
|
|
3314
|
+
case 'querySelector':
|
|
3315
|
+
return querySelector$1;
|
|
3316
|
+
|
|
3317
|
+
case 'querySelectorAll':
|
|
3318
|
+
return querySelectorAll$1;
|
|
3319
|
+
}
|
|
3320
|
+
} // Generic passthrough for query APIs on HTMLElement to the relevant Renderer APIs
|
|
3321
|
+
|
|
3079
3322
|
|
|
3080
3323
|
var _loop2 = function _loop2() {
|
|
3081
3324
|
var queryMethod = _queryMethods[_i10];
|
|
3082
3325
|
queryAndChildGetterDescriptors[queryMethod] = {
|
|
3083
3326
|
value: function value(arg) {
|
|
3084
3327
|
var vm = getAssociatedVM(this);
|
|
3085
|
-
var elm = vm.elm
|
|
3086
|
-
renderer = vm.renderer;
|
|
3328
|
+
var elm = vm.elm;
|
|
3087
3329
|
|
|
3088
3330
|
if (process.env.NODE_ENV !== 'production') {
|
|
3089
3331
|
warnIfInvokedDuringConstruction(vm, "".concat(queryMethod, "()"));
|
|
3090
3332
|
}
|
|
3091
3333
|
|
|
3092
|
-
return
|
|
3334
|
+
return getQueryMethod(queryMethod)(elm, arg);
|
|
3093
3335
|
},
|
|
3094
3336
|
configurable: true,
|
|
3095
3337
|
enumerable: true,
|
|
@@ -3815,7 +4057,7 @@
|
|
|
3815
4057
|
return _super4.apply(this, arguments);
|
|
3816
4058
|
}
|
|
3817
4059
|
|
|
3818
|
-
return HTMLBridgeElement;
|
|
4060
|
+
return _createClass(HTMLBridgeElement);
|
|
3819
4061
|
}(SuperClass);
|
|
3820
4062
|
} else {
|
|
3821
4063
|
HTMLBridgeElement = function HTMLBridgeElement() {
|
|
@@ -4259,10 +4501,6 @@
|
|
|
4259
4501
|
|
|
4260
4502
|
assert.isTrue(Ctor.constructor, "Missing ".concat(ctorName, ".constructor, ").concat(ctorName, " should have a \"constructor\" property."));
|
|
4261
4503
|
|
|
4262
|
-
if (!runtimeFlags.ENABLE_MIXED_SHADOW_MODE) {
|
|
4263
|
-
assert.isFalse('shadowSupportMode' in Ctor, "".concat(ctorName || 'Anonymous class', " is an invalid LWC component. The shadowSupportMode static property is not available in this environment."));
|
|
4264
|
-
}
|
|
4265
|
-
|
|
4266
4504
|
if (!isUndefined$1(ctorShadowSupportMode)) {
|
|
4267
4505
|
assert.invariant(ctorShadowSupportMode === "any"
|
|
4268
4506
|
/* Any */
|
|
@@ -4498,21 +4736,20 @@
|
|
|
4498
4736
|
var token = cmpTemplate === null || cmpTemplate === void 0 ? void 0 : cmpTemplate.stylesheetToken;
|
|
4499
4737
|
|
|
4500
4738
|
if (!isUndefined$1(token) && context.hasScopedStyles) {
|
|
4501
|
-
|
|
4739
|
+
getClassList$1(elm).add(token);
|
|
4502
4740
|
}
|
|
4503
4741
|
}
|
|
4504
4742
|
|
|
4505
4743
|
function updateNodeHook(oldVnode, vnode) {
|
|
4506
4744
|
var elm = vnode.elm,
|
|
4507
|
-
text = vnode.text
|
|
4508
|
-
renderer = vnode.owner.renderer;
|
|
4745
|
+
text = vnode.text;
|
|
4509
4746
|
|
|
4510
4747
|
if (oldVnode.text !== text) {
|
|
4511
4748
|
if (process.env.NODE_ENV !== 'production') {
|
|
4512
4749
|
unlockDomMutation();
|
|
4513
4750
|
}
|
|
4514
4751
|
|
|
4515
|
-
|
|
4752
|
+
setText$1(elm, text);
|
|
4516
4753
|
|
|
4517
4754
|
if (process.env.NODE_ENV !== 'production') {
|
|
4518
4755
|
lockDomMutation();
|
|
@@ -4521,13 +4758,11 @@
|
|
|
4521
4758
|
}
|
|
4522
4759
|
|
|
4523
4760
|
function insertNodeHook(vnode, parentNode, referenceNode) {
|
|
4524
|
-
var renderer = vnode.owner.renderer;
|
|
4525
|
-
|
|
4526
4761
|
if (process.env.NODE_ENV !== 'production') {
|
|
4527
4762
|
unlockDomMutation();
|
|
4528
4763
|
}
|
|
4529
4764
|
|
|
4530
|
-
|
|
4765
|
+
insert$1(vnode.elm, parentNode, referenceNode);
|
|
4531
4766
|
|
|
4532
4767
|
if (process.env.NODE_ENV !== 'production') {
|
|
4533
4768
|
lockDomMutation();
|
|
@@ -4535,13 +4770,11 @@
|
|
|
4535
4770
|
}
|
|
4536
4771
|
|
|
4537
4772
|
function removeNodeHook(vnode, parentNode) {
|
|
4538
|
-
var renderer = vnode.owner.renderer;
|
|
4539
|
-
|
|
4540
4773
|
if (process.env.NODE_ENV !== 'production') {
|
|
4541
4774
|
unlockDomMutation();
|
|
4542
4775
|
}
|
|
4543
4776
|
|
|
4544
|
-
|
|
4777
|
+
remove$1(vnode.elm, parentNode);
|
|
4545
4778
|
|
|
4546
4779
|
if (process.env.NODE_ENV !== 'production') {
|
|
4547
4780
|
lockDomMutation();
|
|
@@ -4620,12 +4853,14 @@
|
|
|
4620
4853
|
}
|
|
4621
4854
|
|
|
4622
4855
|
function updateChildrenHook(oldVnode, vnode) {
|
|
4623
|
-
var
|
|
4624
|
-
|
|
4625
|
-
|
|
4626
|
-
|
|
4627
|
-
|
|
4628
|
-
}
|
|
4856
|
+
var elm = vnode.elm,
|
|
4857
|
+
children = vnode.children;
|
|
4858
|
+
|
|
4859
|
+
if (hasDynamicChildren(children)) {
|
|
4860
|
+
updateDynamicChildren(elm, oldVnode.children, children);
|
|
4861
|
+
} else {
|
|
4862
|
+
updateStaticChildren(elm, oldVnode.children, children);
|
|
4863
|
+
}
|
|
4629
4864
|
}
|
|
4630
4865
|
|
|
4631
4866
|
function allocateChildrenHook(vnode, vm) {
|
|
@@ -4685,8 +4920,7 @@
|
|
|
4685
4920
|
createVM(elm, def, {
|
|
4686
4921
|
mode: mode,
|
|
4687
4922
|
owner: owner,
|
|
4688
|
-
tagName: sel
|
|
4689
|
-
renderer: owner.renderer
|
|
4923
|
+
tagName: sel
|
|
4690
4924
|
});
|
|
4691
4925
|
|
|
4692
4926
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -4728,8 +4962,7 @@
|
|
|
4728
4962
|
|
|
4729
4963
|
function vnodesAndElementHaveCompatibleAttrs(vnode, elm) {
|
|
4730
4964
|
var _vnode$data$attrs = vnode.data.attrs,
|
|
4731
|
-
attrs = _vnode$data$attrs === void 0 ? {} : _vnode$data$attrs
|
|
4732
|
-
renderer = vnode.owner.renderer;
|
|
4965
|
+
attrs = _vnode$data$attrs === void 0 ? {} : _vnode$data$attrs;
|
|
4733
4966
|
var nodesAreCompatible = true; // Validate attributes, though we could always recovery from those by running the update mods.
|
|
4734
4967
|
// Note: intentionally ONLY matching vnodes.attrs to elm.attrs, in case SSR is adding extra attributes.
|
|
4735
4968
|
|
|
@@ -4738,7 +4971,7 @@
|
|
|
4738
4971
|
attrName = _Object$entries$_i[0],
|
|
4739
4972
|
attrValue = _Object$entries$_i[1];
|
|
4740
4973
|
|
|
4741
|
-
var elmAttrValue =
|
|
4974
|
+
var elmAttrValue = getAttribute$1(elm, attrName);
|
|
4742
4975
|
|
|
4743
4976
|
if (String(attrValue) !== elmAttrValue) {
|
|
4744
4977
|
logError("Mismatch hydrating element <".concat(elm.tagName.toLowerCase(), ">: attribute \"").concat(attrName, "\" has different values, expected \"").concat(attrValue, "\" but found \"").concat(elmAttrValue, "\""), vnode.owner);
|
|
@@ -4752,8 +4985,7 @@
|
|
|
4752
4985
|
function vnodesAndElementHaveCompatibleClass(vnode, elm) {
|
|
4753
4986
|
var _vnode$data = vnode.data,
|
|
4754
4987
|
className = _vnode$data.className,
|
|
4755
|
-
classMap = _vnode$data.classMap
|
|
4756
|
-
renderer = vnode.owner.renderer;
|
|
4988
|
+
classMap = _vnode$data.classMap;
|
|
4757
4989
|
var nodesAreCompatible = true;
|
|
4758
4990
|
var vnodeClassName;
|
|
4759
4991
|
|
|
@@ -4763,7 +4995,7 @@
|
|
|
4763
4995
|
vnodeClassName = className;
|
|
4764
4996
|
} else if (!isUndefined$1(classMap)) {
|
|
4765
4997
|
// classMap is used when class is set to static value.
|
|
4766
|
-
var classList =
|
|
4998
|
+
var classList = getClassList$1(elm);
|
|
4767
4999
|
var computedClassName = ''; // all classes from the vnode should be in the element.classList
|
|
4768
5000
|
|
|
4769
5001
|
for (var name in classMap) {
|
|
@@ -4791,9 +5023,8 @@
|
|
|
4791
5023
|
function vnodesAndElementHaveCompatibleStyle(vnode, elm) {
|
|
4792
5024
|
var _vnode$data2 = vnode.data,
|
|
4793
5025
|
style = _vnode$data2.style,
|
|
4794
|
-
styleDecls = _vnode$data2.styleDecls
|
|
4795
|
-
|
|
4796
|
-
var elmStyle = renderer.getAttribute(elm, 'style') || '';
|
|
5026
|
+
styleDecls = _vnode$data2.styleDecls;
|
|
5027
|
+
var elmStyle = getAttribute$1(elm, 'style') || '';
|
|
4797
5028
|
var vnodeStyle;
|
|
4798
5029
|
var nodesAreCompatible = true;
|
|
4799
5030
|
|
|
@@ -4934,12 +5165,12 @@
|
|
|
4934
5165
|
*/
|
|
4935
5166
|
|
|
4936
5167
|
|
|
4937
|
-
function getUpgradableConstructor(tagName
|
|
5168
|
+
function getUpgradableConstructor(tagName) {
|
|
4938
5169
|
// Should never get a tag with upper case letter at this point, the compiler should
|
|
4939
5170
|
// produce only tags with lowercase letters
|
|
4940
5171
|
// But, for backwards compatibility, we will lower case the tagName
|
|
4941
5172
|
tagName = tagName.toLowerCase();
|
|
4942
|
-
var CE =
|
|
5173
|
+
var CE = getCustomElement$1(tagName);
|
|
4943
5174
|
|
|
4944
5175
|
if (!isUndefined$1(CE)) {
|
|
4945
5176
|
return CE;
|
|
@@ -4950,8 +5181,8 @@
|
|
|
4950
5181
|
*/
|
|
4951
5182
|
|
|
4952
5183
|
|
|
4953
|
-
CE = /*#__PURE__*/function (
|
|
4954
|
-
_inherits(LWCUpgradableElement,
|
|
5184
|
+
CE = /*#__PURE__*/function (_HTMLElementExported$) {
|
|
5185
|
+
_inherits(LWCUpgradableElement, _HTMLElementExported$);
|
|
4955
5186
|
|
|
4956
5187
|
var _super5 = _createSuper(LWCUpgradableElement);
|
|
4957
5188
|
|
|
@@ -4969,10 +5200,10 @@
|
|
|
4969
5200
|
return _this4;
|
|
4970
5201
|
}
|
|
4971
5202
|
|
|
4972
|
-
return LWCUpgradableElement;
|
|
4973
|
-
}(
|
|
5203
|
+
return _createClass(LWCUpgradableElement);
|
|
5204
|
+
}(HTMLElementExported$1);
|
|
4974
5205
|
|
|
4975
|
-
|
|
5206
|
+
defineCustomElement$1(tagName, CE);
|
|
4976
5207
|
return CE;
|
|
4977
5208
|
}
|
|
4978
5209
|
/*
|
|
@@ -4988,8 +5219,7 @@
|
|
|
4988
5219
|
var TextHook = {
|
|
4989
5220
|
create: function create(vnode) {
|
|
4990
5221
|
var owner = vnode.owner;
|
|
4991
|
-
var
|
|
4992
|
-
var elm = renderer.createText(vnode.text);
|
|
5222
|
+
var elm = createText$1(vnode.text);
|
|
4993
5223
|
linkNodeToShadow(elm, owner);
|
|
4994
5224
|
vnode.elm = elm;
|
|
4995
5225
|
},
|
|
@@ -5021,8 +5251,7 @@
|
|
|
5021
5251
|
create: function create(vnode) {
|
|
5022
5252
|
var owner = vnode.owner,
|
|
5023
5253
|
text = vnode.text;
|
|
5024
|
-
var
|
|
5025
|
-
var elm = renderer.createComment(text);
|
|
5254
|
+
var elm = createComment$1(text);
|
|
5026
5255
|
linkNodeToShadow(elm, owner);
|
|
5027
5256
|
vnode.elm = elm;
|
|
5028
5257
|
},
|
|
@@ -5060,9 +5289,8 @@
|
|
|
5060
5289
|
var sel = vnode.sel,
|
|
5061
5290
|
owner = vnode.owner,
|
|
5062
5291
|
svg = vnode.data.svg;
|
|
5063
|
-
var renderer = owner.renderer;
|
|
5064
5292
|
var namespace = isTrue(svg) ? SVG_NAMESPACE : undefined;
|
|
5065
|
-
var elm =
|
|
5293
|
+
var elm = createElement$2(sel, namespace);
|
|
5066
5294
|
linkNodeToShadow(elm, owner);
|
|
5067
5295
|
fallbackElmHook(elm, vnode);
|
|
5068
5296
|
vnode.elm = elm;
|
|
@@ -5116,8 +5344,7 @@
|
|
|
5116
5344
|
create: function create(vnode) {
|
|
5117
5345
|
var sel = vnode.sel,
|
|
5118
5346
|
owner = vnode.owner;
|
|
5119
|
-
var
|
|
5120
|
-
var UpgradableConstructor = getUpgradableConstructor(sel, renderer);
|
|
5347
|
+
var UpgradableConstructor = getUpgradableConstructor(sel);
|
|
5121
5348
|
/**
|
|
5122
5349
|
* Note: if the upgradable constructor does not expect, or throw when we new it
|
|
5123
5350
|
* with a callback as the first argument, we could implement a more advanced
|
|
@@ -5208,8 +5435,7 @@
|
|
|
5208
5435
|
createVM(elm, def, {
|
|
5209
5436
|
mode: mode,
|
|
5210
5437
|
owner: owner,
|
|
5211
|
-
tagName: sel
|
|
5212
|
-
renderer: owner.renderer
|
|
5438
|
+
tagName: sel
|
|
5213
5439
|
});
|
|
5214
5440
|
vnode.elm = elm;
|
|
5215
5441
|
var vm = getAssociatedVM(elm);
|
|
@@ -5237,11 +5463,10 @@
|
|
|
5237
5463
|
};
|
|
5238
5464
|
|
|
5239
5465
|
function linkNodeToShadow(elm, owner) {
|
|
5240
|
-
var
|
|
5241
|
-
renderMode = owner.renderMode,
|
|
5466
|
+
var renderMode = owner.renderMode,
|
|
5242
5467
|
shadowMode = owner.shadowMode; // TODO [#1164]: this should eventually be done by the polyfill directly
|
|
5243
5468
|
|
|
5244
|
-
if (
|
|
5469
|
+
if (isSyntheticShadowDefined$1) {
|
|
5245
5470
|
if (shadowMode === 1
|
|
5246
5471
|
/* Synthetic */
|
|
5247
5472
|
|| renderMode === 0
|
|
@@ -5762,7 +5987,6 @@
|
|
|
5762
5987
|
function updateStylesheetToken(vm, template) {
|
|
5763
5988
|
var elm = vm.elm,
|
|
5764
5989
|
context = vm.context,
|
|
5765
|
-
renderer = vm.renderer,
|
|
5766
5990
|
renderMode = vm.renderMode,
|
|
5767
5991
|
shadowMode = vm.shadowMode;
|
|
5768
5992
|
var newStylesheets = template.stylesheets,
|
|
@@ -5782,11 +6006,11 @@
|
|
|
5782
6006
|
oldHasTokenInAttribute = context.hasTokenInAttribute;
|
|
5783
6007
|
|
|
5784
6008
|
if (oldHasTokenInClass) {
|
|
5785
|
-
|
|
6009
|
+
getClassList$1(elm).remove(makeHostToken(oldToken));
|
|
5786
6010
|
}
|
|
5787
6011
|
|
|
5788
6012
|
if (oldHasTokenInAttribute) {
|
|
5789
|
-
|
|
6013
|
+
removeAttribute$1(elm, makeHostToken(oldToken));
|
|
5790
6014
|
} // Apply the new template styling token to the host element, if the new template has any
|
|
5791
6015
|
// associated stylesheets. In the case of light DOM, also ensure there is at least one scoped stylesheet.
|
|
5792
6016
|
|
|
@@ -5798,12 +6022,12 @@
|
|
|
5798
6022
|
|
|
5799
6023
|
if (!isUndefined$1(newToken)) {
|
|
5800
6024
|
if (hasScopedStyles) {
|
|
5801
|
-
|
|
6025
|
+
getClassList$1(elm).add(makeHostToken(newToken));
|
|
5802
6026
|
newHasTokenInClass = true;
|
|
5803
6027
|
}
|
|
5804
6028
|
|
|
5805
6029
|
if (isSyntheticShadow) {
|
|
5806
|
-
|
|
6030
|
+
setAttribute$1(elm, makeHostToken(newToken), '');
|
|
5807
6031
|
newHasTokenInAttribute = true;
|
|
5808
6032
|
}
|
|
5809
6033
|
} // Update the styling tokens present on the context object.
|
|
@@ -5921,8 +6145,7 @@
|
|
|
5921
6145
|
}
|
|
5922
6146
|
|
|
5923
6147
|
function createStylesheet(vm, stylesheets) {
|
|
5924
|
-
var
|
|
5925
|
-
renderMode = vm.renderMode,
|
|
6148
|
+
var renderMode = vm.renderMode,
|
|
5926
6149
|
shadowMode = vm.shadowMode;
|
|
5927
6150
|
|
|
5928
6151
|
if (renderMode === 1
|
|
@@ -5931,9 +6154,9 @@
|
|
|
5931
6154
|
/* Synthetic */
|
|
5932
6155
|
) {
|
|
5933
6156
|
for (var _i17 = 0; _i17 < stylesheets.length; _i17++) {
|
|
5934
|
-
|
|
6157
|
+
insertGlobalStylesheet$1(stylesheets[_i17]);
|
|
5935
6158
|
}
|
|
5936
|
-
} else if (
|
|
6159
|
+
} else if (ssr$1 || isHydrating$1()) {
|
|
5937
6160
|
// Note: We need to ensure that during hydration, the stylesheets method is the same as those in ssr.
|
|
5938
6161
|
// This works in the client, because the stylesheets are created, and cached in the VM
|
|
5939
6162
|
// the first time the VM renders.
|
|
@@ -5947,10 +6170,10 @@
|
|
|
5947
6170
|
|
|
5948
6171
|
for (var _i18 = 0; _i18 < stylesheets.length; _i18++) {
|
|
5949
6172
|
if (isGlobal) {
|
|
5950
|
-
|
|
6173
|
+
insertGlobalStylesheet$1(stylesheets[_i18]);
|
|
5951
6174
|
} else {
|
|
5952
6175
|
// local level
|
|
5953
|
-
|
|
6176
|
+
insertStylesheet$1(stylesheets[_i18], root.cmpRoot);
|
|
5954
6177
|
}
|
|
5955
6178
|
}
|
|
5956
6179
|
}
|
|
@@ -6031,7 +6254,7 @@
|
|
|
6031
6254
|
if (isProfilerEnabled) {
|
|
6032
6255
|
currentDispatcher(opId, 0
|
|
6033
6256
|
/* Start */
|
|
6034
|
-
, vm.tagName, vm.idx);
|
|
6257
|
+
, vm.tagName, vm.idx, vm.renderMode, vm.shadowMode);
|
|
6035
6258
|
}
|
|
6036
6259
|
}
|
|
6037
6260
|
|
|
@@ -6045,7 +6268,7 @@
|
|
|
6045
6268
|
if (isProfilerEnabled) {
|
|
6046
6269
|
currentDispatcher(opId, 1
|
|
6047
6270
|
/* Stop */
|
|
6048
|
-
, vm.tagName, vm.idx);
|
|
6271
|
+
, vm.tagName, vm.idx, vm.renderMode, vm.shadowMode);
|
|
6049
6272
|
}
|
|
6050
6273
|
}
|
|
6051
6274
|
|
|
@@ -6059,7 +6282,7 @@
|
|
|
6059
6282
|
if (isProfilerEnabled) {
|
|
6060
6283
|
currentDispatcher(opId, 0
|
|
6061
6284
|
/* Start */
|
|
6062
|
-
, vm === null || vm === void 0 ? void 0 : vm.tagName, vm === null || vm === void 0 ? void 0 : vm.idx);
|
|
6285
|
+
, vm === null || vm === void 0 ? void 0 : vm.tagName, vm === null || vm === void 0 ? void 0 : vm.idx, vm === null || vm === void 0 ? void 0 : vm.renderMode, vm === null || vm === void 0 ? void 0 : vm.shadowMode);
|
|
6063
6286
|
}
|
|
6064
6287
|
}
|
|
6065
6288
|
|
|
@@ -6073,7 +6296,7 @@
|
|
|
6073
6296
|
if (isProfilerEnabled) {
|
|
6074
6297
|
currentDispatcher(opId, 1
|
|
6075
6298
|
/* Stop */
|
|
6076
|
-
, vm === null || vm === void 0 ? void 0 : vm.tagName, vm === null || vm === void 0 ? void 0 : vm.idx);
|
|
6299
|
+
, vm === null || vm === void 0 ? void 0 : vm.tagName, vm === null || vm === void 0 ? void 0 : vm.idx, vm === null || vm === void 0 ? void 0 : vm.renderMode, vm === null || vm === void 0 ? void 0 : vm.shadowMode);
|
|
6077
6300
|
}
|
|
6078
6301
|
}
|
|
6079
6302
|
/*
|
|
@@ -6612,7 +6835,6 @@
|
|
|
6612
6835
|
function createVM(elm, def, options) {
|
|
6613
6836
|
var mode = options.mode,
|
|
6614
6837
|
owner = options.owner,
|
|
6615
|
-
renderer = options.renderer,
|
|
6616
6838
|
tagName = options.tagName;
|
|
6617
6839
|
var vm = {
|
|
6618
6840
|
elm: elm,
|
|
@@ -6626,7 +6848,6 @@
|
|
|
6626
6848
|
tagName: tagName,
|
|
6627
6849
|
mode: mode,
|
|
6628
6850
|
owner: owner,
|
|
6629
|
-
renderer: renderer,
|
|
6630
6851
|
children: EmptyArray,
|
|
6631
6852
|
aChildren: EmptyArray,
|
|
6632
6853
|
velements: EmptyArray,
|
|
@@ -6680,13 +6901,10 @@
|
|
|
6680
6901
|
}
|
|
6681
6902
|
|
|
6682
6903
|
function computeShadowMode(vm) {
|
|
6683
|
-
var def = vm.def
|
|
6684
|
-
renderer = vm.renderer;
|
|
6685
|
-
var isNativeShadowDefined = renderer.isNativeShadowDefined,
|
|
6686
|
-
isSyntheticShadowDefined = renderer.isSyntheticShadowDefined;
|
|
6904
|
+
var def = vm.def;
|
|
6687
6905
|
var shadowMode;
|
|
6688
6906
|
|
|
6689
|
-
if (isSyntheticShadowDefined) {
|
|
6907
|
+
if (isSyntheticShadowDefined$1) {
|
|
6690
6908
|
if (def.renderMode === 0
|
|
6691
6909
|
/* Light */
|
|
6692
6910
|
) {
|
|
@@ -6695,7 +6913,7 @@
|
|
|
6695
6913
|
shadowMode = 0
|
|
6696
6914
|
/* Native */
|
|
6697
6915
|
;
|
|
6698
|
-
} else if (isNativeShadowDefined) {
|
|
6916
|
+
} else if (isNativeShadowDefined$1) {
|
|
6699
6917
|
if (def.shadowSupportMode === "any"
|
|
6700
6918
|
/* Any */
|
|
6701
6919
|
) {
|
|
@@ -6832,10 +7050,9 @@
|
|
|
6832
7050
|
}
|
|
6833
7051
|
|
|
6834
7052
|
function runRenderedCallback(vm) {
|
|
6835
|
-
var
|
|
6836
|
-
renderedCallback = vm.def.renderedCallback;
|
|
7053
|
+
var renderedCallback = vm.def.renderedCallback;
|
|
6837
7054
|
|
|
6838
|
-
if (isTrue(
|
|
7055
|
+
if (isTrue(ssr$1)) {
|
|
6839
7056
|
return;
|
|
6840
7057
|
}
|
|
6841
7058
|
|
|
@@ -7044,15 +7261,14 @@
|
|
|
7044
7261
|
|
|
7045
7262
|
|
|
7046
7263
|
function resetComponentRoot(vm) {
|
|
7047
|
-
var children = vm.children
|
|
7048
|
-
renderer = vm.renderer;
|
|
7264
|
+
var children = vm.children;
|
|
7049
7265
|
var rootNode = getRenderRoot(vm);
|
|
7050
7266
|
|
|
7051
7267
|
for (var _i25 = 0, _len9 = children.length; _i25 < _len9; _i25++) {
|
|
7052
7268
|
var child = children[_i25];
|
|
7053
7269
|
|
|
7054
7270
|
if (!isNull(child) && !isUndefined$1(child.elm)) {
|
|
7055
|
-
|
|
7271
|
+
remove$1(child.elm, rootNode);
|
|
7056
7272
|
}
|
|
7057
7273
|
}
|
|
7058
7274
|
|
|
@@ -7062,7 +7278,7 @@
|
|
|
7062
7278
|
}
|
|
7063
7279
|
|
|
7064
7280
|
function scheduleRehydration(vm) {
|
|
7065
|
-
if (isTrue(
|
|
7281
|
+
if (isTrue(ssr$1) || isTrue(vm.isScheduled)) {
|
|
7066
7282
|
return;
|
|
7067
7283
|
}
|
|
7068
7284
|
|
|
@@ -7245,7 +7461,7 @@
|
|
|
7245
7461
|
return _this5;
|
|
7246
7462
|
}
|
|
7247
7463
|
|
|
7248
|
-
return WireContextRegistrationEvent;
|
|
7464
|
+
return _createClass(WireContextRegistrationEvent);
|
|
7249
7465
|
}( /*#__PURE__*/_wrapNativeSuper(CustomEvent));
|
|
7250
7466
|
|
|
7251
7467
|
function createFieldDataCallback(vm, name) {
|
|
@@ -7312,7 +7528,6 @@
|
|
|
7312
7528
|
}
|
|
7313
7529
|
|
|
7314
7530
|
var elm = vm.elm,
|
|
7315
|
-
renderer = vm.renderer,
|
|
7316
7531
|
_vm$context = vm.context,
|
|
7317
7532
|
wiredConnecting = _vm$context.wiredConnecting,
|
|
7318
7533
|
wiredDisconnecting = _vm$context.wiredDisconnecting; // waiting for the component to be connected to formally request the context via the token
|
|
@@ -7335,7 +7550,7 @@
|
|
|
7335
7550
|
ArrayPush$1.call(wiredDisconnecting, disconnectCallback);
|
|
7336
7551
|
}
|
|
7337
7552
|
});
|
|
7338
|
-
|
|
7553
|
+
dispatchEvent$1(elm, contextRegistrationEvent);
|
|
7339
7554
|
});
|
|
7340
7555
|
}
|
|
7341
7556
|
|
|
@@ -7589,7 +7804,7 @@
|
|
|
7589
7804
|
hooksAreSet = true;
|
|
7590
7805
|
setSanitizeHtmlContentHook(hooks.sanitizeHtmlContent);
|
|
7591
7806
|
}
|
|
7592
|
-
/* version: 2.
|
|
7807
|
+
/* version: 2.7.2 */
|
|
7593
7808
|
|
|
7594
7809
|
/*
|
|
7595
7810
|
* Copyright (c) 2018, salesforce.com, inc.
|
|
@@ -7619,7 +7834,9 @@
|
|
|
7619
7834
|
var styleElements = create(null);
|
|
7620
7835
|
var styleSheets = create(null);
|
|
7621
7836
|
var nodesToStyleSheets = new WeakMap();
|
|
7622
|
-
var getCustomElement
|
|
7837
|
+
var getCustomElement;
|
|
7838
|
+
var defineCustomElement;
|
|
7839
|
+
var HTMLElementConstructor;
|
|
7623
7840
|
|
|
7624
7841
|
function isCustomElementRegistryAvailable() {
|
|
7625
7842
|
if (typeof customElements === 'undefined') {
|
|
@@ -7646,7 +7863,7 @@
|
|
|
7646
7863
|
return _super7.apply(this, arguments);
|
|
7647
7864
|
}
|
|
7648
7865
|
|
|
7649
|
-
return clazz;
|
|
7866
|
+
return _createClass(clazz);
|
|
7650
7867
|
}(HTMLElementAlias);
|
|
7651
7868
|
|
|
7652
7869
|
customElements.define('lwc-test-' + Math.floor(Math.random() * 1000000), clazz);
|
|
@@ -7744,152 +7961,231 @@
|
|
|
7744
7961
|
HTMLElementConstructor.prototype = HTMLElement.prototype;
|
|
7745
7962
|
}
|
|
7746
7963
|
|
|
7747
|
-
var
|
|
7964
|
+
var hydrating = false;
|
|
7748
7965
|
|
|
7749
|
-
function setIsHydrating(
|
|
7750
|
-
|
|
7966
|
+
function setIsHydrating(value) {
|
|
7967
|
+
hydrating = value;
|
|
7751
7968
|
}
|
|
7752
7969
|
|
|
7753
|
-
var
|
|
7754
|
-
ssr: false,
|
|
7755
|
-
isHydrating: function isHydrating() {
|
|
7756
|
-
return _isHydrating;
|
|
7757
|
-
},
|
|
7758
|
-
isNativeShadowDefined: _globalThis[KEY__IS_NATIVE_SHADOW_ROOT_DEFINED],
|
|
7759
|
-
isSyntheticShadowDefined: hasOwnProperty$1.call(Element.prototype, KEY__SHADOW_TOKEN),
|
|
7760
|
-
createElement: function createElement(tagName, namespace) {
|
|
7761
|
-
return isUndefined$1(namespace) ? document.createElement(tagName) : document.createElementNS(namespace, tagName);
|
|
7762
|
-
},
|
|
7763
|
-
createText: function createText(content) {
|
|
7764
|
-
return document.createTextNode(content);
|
|
7765
|
-
},
|
|
7766
|
-
createComment: function createComment(content) {
|
|
7767
|
-
return document.createComment(content);
|
|
7768
|
-
},
|
|
7769
|
-
insert: function insert(node, parent, anchor) {
|
|
7770
|
-
parent.insertBefore(node, anchor);
|
|
7771
|
-
},
|
|
7772
|
-
remove: function remove(node, parent) {
|
|
7773
|
-
parent.removeChild(node);
|
|
7774
|
-
},
|
|
7775
|
-
nextSibling: function nextSibling(node) {
|
|
7776
|
-
return node.nextSibling;
|
|
7777
|
-
},
|
|
7778
|
-
attachShadow: function attachShadow(element, options) {
|
|
7779
|
-
if (_isHydrating) {
|
|
7780
|
-
return element.shadowRoot;
|
|
7781
|
-
}
|
|
7970
|
+
var ssr = false;
|
|
7782
7971
|
|
|
7783
|
-
|
|
7784
|
-
|
|
7785
|
-
|
|
7786
|
-
node.nodeValue = content;
|
|
7787
|
-
},
|
|
7788
|
-
getProperty: function getProperty(node, key) {
|
|
7789
|
-
return node[key];
|
|
7790
|
-
},
|
|
7791
|
-
setProperty: function setProperty(node, key, value) {
|
|
7792
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
7793
|
-
if (node instanceof Element && !(key in node)) {
|
|
7794
|
-
// TODO [#1297]: Move this validation to the compiler
|
|
7795
|
-
assert.fail("Unknown public property \"".concat(key, "\" of element <").concat(node.tagName, ">. This is likely a typo on the corresponding attribute \"").concat(htmlPropertyToAttribute(key), "\"."));
|
|
7796
|
-
}
|
|
7797
|
-
}
|
|
7972
|
+
function isHydrating() {
|
|
7973
|
+
return hydrating;
|
|
7974
|
+
}
|
|
7798
7975
|
|
|
7799
|
-
|
|
7800
|
-
|
|
7801
|
-
getAttribute: function getAttribute(element, name, namespace) {
|
|
7802
|
-
return isUndefined$1(namespace) ? element.getAttribute(name) : element.getAttributeNS(namespace, name);
|
|
7803
|
-
},
|
|
7804
|
-
setAttribute: function setAttribute(element, name, value, namespace) {
|
|
7805
|
-
return isUndefined$1(namespace) ? element.setAttribute(name, value) : element.setAttributeNS(namespace, name, value);
|
|
7806
|
-
},
|
|
7807
|
-
removeAttribute: function removeAttribute(element, name, namespace) {
|
|
7808
|
-
if (isUndefined$1(namespace)) {
|
|
7809
|
-
element.removeAttribute(name);
|
|
7810
|
-
} else {
|
|
7811
|
-
element.removeAttributeNS(namespace, name);
|
|
7812
|
-
}
|
|
7813
|
-
},
|
|
7814
|
-
addEventListener: function addEventListener(target, type, callback, options) {
|
|
7815
|
-
target.addEventListener(type, callback, options);
|
|
7816
|
-
},
|
|
7817
|
-
removeEventListener: function removeEventListener(target, type, callback, options) {
|
|
7818
|
-
target.removeEventListener(type, callback, options);
|
|
7819
|
-
},
|
|
7820
|
-
dispatchEvent: function dispatchEvent(target, event) {
|
|
7821
|
-
return target.dispatchEvent(event);
|
|
7822
|
-
},
|
|
7823
|
-
getClassList: function getClassList(element) {
|
|
7824
|
-
return element.classList;
|
|
7825
|
-
},
|
|
7826
|
-
setCSSStyleProperty: function setCSSStyleProperty(element, name, value, important) {
|
|
7827
|
-
// TODO [#0]: How to avoid this type casting? Shall we use a different type interface to
|
|
7828
|
-
// represent elements in the engine?
|
|
7829
|
-
element.style.setProperty(name, value, important ? 'important' : '');
|
|
7830
|
-
},
|
|
7831
|
-
getBoundingClientRect: function getBoundingClientRect(element) {
|
|
7832
|
-
return element.getBoundingClientRect();
|
|
7833
|
-
},
|
|
7834
|
-
querySelector: function querySelector(element, selectors) {
|
|
7835
|
-
return element.querySelector(selectors);
|
|
7836
|
-
},
|
|
7837
|
-
querySelectorAll: function querySelectorAll(element, selectors) {
|
|
7838
|
-
return element.querySelectorAll(selectors);
|
|
7839
|
-
},
|
|
7840
|
-
getElementsByTagName: function getElementsByTagName(element, tagNameOrWildCard) {
|
|
7841
|
-
return element.getElementsByTagName(tagNameOrWildCard);
|
|
7842
|
-
},
|
|
7843
|
-
getElementsByClassName: function getElementsByClassName(element, names) {
|
|
7844
|
-
return element.getElementsByClassName(names);
|
|
7845
|
-
},
|
|
7846
|
-
getChildren: function getChildren(element) {
|
|
7847
|
-
return element.children;
|
|
7848
|
-
},
|
|
7849
|
-
getChildNodes: function getChildNodes(element) {
|
|
7850
|
-
return element.childNodes;
|
|
7851
|
-
},
|
|
7852
|
-
getFirstChild: function getFirstChild(element) {
|
|
7853
|
-
return element.firstChild;
|
|
7854
|
-
},
|
|
7855
|
-
getFirstElementChild: function getFirstElementChild(element) {
|
|
7856
|
-
return element.firstElementChild;
|
|
7857
|
-
},
|
|
7858
|
-
getLastChild: function getLastChild(element) {
|
|
7859
|
-
return element.lastChild;
|
|
7860
|
-
},
|
|
7861
|
-
getLastElementChild: function getLastElementChild(element) {
|
|
7862
|
-
return element.lastElementChild;
|
|
7863
|
-
},
|
|
7864
|
-
isConnected: function isConnected(node) {
|
|
7865
|
-
return node.isConnected;
|
|
7866
|
-
},
|
|
7867
|
-
insertGlobalStylesheet: function insertGlobalStylesheet(content) {
|
|
7868
|
-
if (!isUndefined$1(globalStylesheets[content])) {
|
|
7869
|
-
return;
|
|
7870
|
-
}
|
|
7976
|
+
var isNativeShadowDefined = _globalThis[KEY__IS_NATIVE_SHADOW_ROOT_DEFINED];
|
|
7977
|
+
var isSyntheticShadowDefined = hasOwnProperty$1.call(Element.prototype, KEY__SHADOW_TOKEN);
|
|
7871
7978
|
|
|
7872
|
-
|
|
7873
|
-
|
|
7874
|
-
|
|
7875
|
-
|
|
7876
|
-
|
|
7877
|
-
|
|
7878
|
-
|
|
7879
|
-
|
|
7880
|
-
|
|
7881
|
-
|
|
7882
|
-
|
|
7883
|
-
|
|
7979
|
+
function createElement$1(tagName, namespace) {
|
|
7980
|
+
return isUndefined$1(namespace) ? document.createElement(tagName) : document.createElementNS(namespace, tagName);
|
|
7981
|
+
}
|
|
7982
|
+
|
|
7983
|
+
function createText(content) {
|
|
7984
|
+
return document.createTextNode(content);
|
|
7985
|
+
}
|
|
7986
|
+
|
|
7987
|
+
function createComment(content) {
|
|
7988
|
+
return document.createComment(content);
|
|
7989
|
+
}
|
|
7990
|
+
|
|
7991
|
+
function insert(node, parent, anchor) {
|
|
7992
|
+
parent.insertBefore(node, anchor);
|
|
7993
|
+
}
|
|
7994
|
+
|
|
7995
|
+
function remove(node, parent) {
|
|
7996
|
+
parent.removeChild(node);
|
|
7997
|
+
}
|
|
7998
|
+
|
|
7999
|
+
function nextSibling(node) {
|
|
8000
|
+
return node.nextSibling;
|
|
8001
|
+
}
|
|
8002
|
+
|
|
8003
|
+
function attachShadow(element, options) {
|
|
8004
|
+
if (hydrating) {
|
|
8005
|
+
return element.shadowRoot;
|
|
8006
|
+
}
|
|
8007
|
+
|
|
8008
|
+
return element.attachShadow(options);
|
|
8009
|
+
}
|
|
8010
|
+
|
|
8011
|
+
function setText(node, content) {
|
|
8012
|
+
node.nodeValue = content;
|
|
8013
|
+
}
|
|
8014
|
+
|
|
8015
|
+
function getProperty(node, key) {
|
|
8016
|
+
return node[key];
|
|
8017
|
+
}
|
|
8018
|
+
|
|
8019
|
+
function setProperty(node, key, value) {
|
|
8020
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
8021
|
+
if (node instanceof Element && !(key in node)) {
|
|
8022
|
+
// TODO [#1297]: Move this validation to the compiler
|
|
8023
|
+
assert.fail("Unknown public property \"".concat(key, "\" of element <").concat(node.tagName, ">. This is likely a typo on the corresponding attribute \"").concat(htmlPropertyToAttribute(key), "\"."));
|
|
7884
8024
|
}
|
|
7885
|
-
}
|
|
7886
|
-
|
|
7887
|
-
|
|
7888
|
-
|
|
7889
|
-
|
|
7890
|
-
|
|
7891
|
-
|
|
7892
|
-
}
|
|
8025
|
+
}
|
|
8026
|
+
|
|
8027
|
+
node[key] = value;
|
|
8028
|
+
}
|
|
8029
|
+
|
|
8030
|
+
function getAttribute(element, name, namespace) {
|
|
8031
|
+
return isUndefined$1(namespace) ? element.getAttribute(name) : element.getAttributeNS(namespace, name);
|
|
8032
|
+
}
|
|
8033
|
+
|
|
8034
|
+
function setAttribute(element, name, value, namespace) {
|
|
8035
|
+
return isUndefined$1(namespace) ? element.setAttribute(name, value) : element.setAttributeNS(namespace, name, value);
|
|
8036
|
+
}
|
|
8037
|
+
|
|
8038
|
+
function removeAttribute(element, name, namespace) {
|
|
8039
|
+
if (isUndefined$1(namespace)) {
|
|
8040
|
+
element.removeAttribute(name);
|
|
8041
|
+
} else {
|
|
8042
|
+
element.removeAttributeNS(namespace, name);
|
|
8043
|
+
}
|
|
8044
|
+
}
|
|
8045
|
+
|
|
8046
|
+
function addEventListener(target, type, callback, options) {
|
|
8047
|
+
target.addEventListener(type, callback, options);
|
|
8048
|
+
}
|
|
8049
|
+
|
|
8050
|
+
function removeEventListener(target, type, callback, options) {
|
|
8051
|
+
target.removeEventListener(type, callback, options);
|
|
8052
|
+
}
|
|
8053
|
+
|
|
8054
|
+
function dispatchEvent(target, event) {
|
|
8055
|
+
return target.dispatchEvent(event);
|
|
8056
|
+
}
|
|
8057
|
+
|
|
8058
|
+
function getClassList(element) {
|
|
8059
|
+
return element.classList;
|
|
8060
|
+
}
|
|
8061
|
+
|
|
8062
|
+
function setCSSStyleProperty(element, name, value, important) {
|
|
8063
|
+
// TODO [#0]: How to avoid this type casting? Shall we use a different type interface to
|
|
8064
|
+
// represent elements in the engine?
|
|
8065
|
+
element.style.setProperty(name, value, important ? 'important' : '');
|
|
8066
|
+
}
|
|
8067
|
+
|
|
8068
|
+
function getBoundingClientRect(element) {
|
|
8069
|
+
return element.getBoundingClientRect();
|
|
8070
|
+
}
|
|
8071
|
+
|
|
8072
|
+
function querySelector(element, selectors) {
|
|
8073
|
+
return element.querySelector(selectors);
|
|
8074
|
+
}
|
|
8075
|
+
|
|
8076
|
+
function querySelectorAll(element, selectors) {
|
|
8077
|
+
return element.querySelectorAll(selectors);
|
|
8078
|
+
}
|
|
8079
|
+
|
|
8080
|
+
function getElementsByTagName(element, tagNameOrWildCard) {
|
|
8081
|
+
return element.getElementsByTagName(tagNameOrWildCard);
|
|
8082
|
+
}
|
|
8083
|
+
|
|
8084
|
+
function getElementsByClassName(element, names) {
|
|
8085
|
+
return element.getElementsByClassName(names);
|
|
8086
|
+
}
|
|
8087
|
+
|
|
8088
|
+
function getChildren(element) {
|
|
8089
|
+
return element.children;
|
|
8090
|
+
}
|
|
8091
|
+
|
|
8092
|
+
function getChildNodes(element) {
|
|
8093
|
+
return element.childNodes;
|
|
8094
|
+
}
|
|
8095
|
+
|
|
8096
|
+
function getFirstChild(element) {
|
|
8097
|
+
return element.firstChild;
|
|
8098
|
+
}
|
|
8099
|
+
|
|
8100
|
+
function getFirstElementChild(element) {
|
|
8101
|
+
return element.firstElementChild;
|
|
8102
|
+
}
|
|
8103
|
+
|
|
8104
|
+
function getLastChild(element) {
|
|
8105
|
+
return element.lastChild;
|
|
8106
|
+
}
|
|
8107
|
+
|
|
8108
|
+
function getLastElementChild(element) {
|
|
8109
|
+
return element.lastElementChild;
|
|
8110
|
+
}
|
|
8111
|
+
|
|
8112
|
+
function isConnected(node) {
|
|
8113
|
+
return node.isConnected;
|
|
8114
|
+
}
|
|
8115
|
+
|
|
8116
|
+
function insertGlobalStylesheet(content) {
|
|
8117
|
+
if (!isUndefined$1(globalStylesheets[content])) {
|
|
8118
|
+
return;
|
|
8119
|
+
}
|
|
8120
|
+
|
|
8121
|
+
globalStylesheets[content] = true;
|
|
8122
|
+
var elm = document.createElement('style');
|
|
8123
|
+
elm.type = 'text/css';
|
|
8124
|
+
elm.textContent = content;
|
|
8125
|
+
globalStylesheetsParentElement.appendChild(elm);
|
|
8126
|
+
}
|
|
8127
|
+
|
|
8128
|
+
function insertStylesheet(content, target) {
|
|
8129
|
+
if (supportsConstructableStyleSheets) {
|
|
8130
|
+
insertConstructableStyleSheet(content, target);
|
|
8131
|
+
} else {
|
|
8132
|
+
// Fall back to <style> element
|
|
8133
|
+
insertStyleElement(content, target);
|
|
8134
|
+
}
|
|
8135
|
+
}
|
|
8136
|
+
|
|
8137
|
+
function assertInstanceOfHTMLElement(elm, msg) {
|
|
8138
|
+
assert.invariant(elm instanceof HTMLElement, msg);
|
|
8139
|
+
}
|
|
8140
|
+
|
|
8141
|
+
var HTMLElementExported = HTMLElementConstructor;
|
|
8142
|
+
/*
|
|
8143
|
+
* Copyright (c) 2020, salesforce.com, inc.
|
|
8144
|
+
* All rights reserved.
|
|
8145
|
+
* SPDX-License-Identifier: MIT
|
|
8146
|
+
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
|
8147
|
+
*/
|
|
8148
|
+
|
|
8149
|
+
setAssertInstanceOfHTMLElement(assertInstanceOfHTMLElement);
|
|
8150
|
+
setAttachShadow(attachShadow);
|
|
8151
|
+
setCreateComment(createComment);
|
|
8152
|
+
setCreateElement(createElement$1);
|
|
8153
|
+
setCreateText(createText);
|
|
8154
|
+
setDefineCustomElement(defineCustomElement);
|
|
8155
|
+
setDispatchEvent(dispatchEvent);
|
|
8156
|
+
setGetAttribute(getAttribute);
|
|
8157
|
+
setGetBoundingClientRect(getBoundingClientRect);
|
|
8158
|
+
setGetChildNodes(getChildNodes);
|
|
8159
|
+
setGetChildren(getChildren);
|
|
8160
|
+
setGetClassList(getClassList);
|
|
8161
|
+
setGetCustomElement(getCustomElement);
|
|
8162
|
+
setGetElementsByClassName(getElementsByClassName);
|
|
8163
|
+
setGetElementsByTagName(getElementsByTagName);
|
|
8164
|
+
setGetFirstChild(getFirstChild);
|
|
8165
|
+
setGetFirstElementChild(getFirstElementChild);
|
|
8166
|
+
setGetLastChild(getLastChild);
|
|
8167
|
+
setGetLastElementChild(getLastElementChild);
|
|
8168
|
+
setGetProperty(getProperty);
|
|
8169
|
+
setHTMLElement(HTMLElementExported);
|
|
8170
|
+
setInsert(insert);
|
|
8171
|
+
setInsertGlobalStylesheet(insertGlobalStylesheet);
|
|
8172
|
+
setInsertStylesheet(insertStylesheet);
|
|
8173
|
+
setIsConnected(isConnected);
|
|
8174
|
+
setIsHydrating$1(isHydrating);
|
|
8175
|
+
setIsNativeShadowDefined(isNativeShadowDefined);
|
|
8176
|
+
setIsSyntheticShadowDefined(isSyntheticShadowDefined);
|
|
8177
|
+
setNextSibling(nextSibling);
|
|
8178
|
+
setQuerySelector(querySelector);
|
|
8179
|
+
setQuerySelectorAll(querySelectorAll);
|
|
8180
|
+
setRemove(remove);
|
|
8181
|
+
setRemoveAttribute(removeAttribute);
|
|
8182
|
+
setRemoveEventListener(removeEventListener);
|
|
8183
|
+
setSetAttribute(setAttribute);
|
|
8184
|
+
setSetCSSStyleProperty(setCSSStyleProperty);
|
|
8185
|
+
setSetProperty(setProperty);
|
|
8186
|
+
setSetText(setText);
|
|
8187
|
+
setSsr(ssr);
|
|
8188
|
+
setAddEventListener(addEventListener);
|
|
7893
8189
|
/*
|
|
7894
8190
|
* Copyright (c) 2018, salesforce.com, inc.
|
|
7895
8191
|
* All rights reserved.
|
|
@@ -7971,7 +8267,7 @@
|
|
|
7971
8267
|
throw new TypeError("\"createElement\" function expects an \"is\" option with a valid component constructor.");
|
|
7972
8268
|
}
|
|
7973
8269
|
|
|
7974
|
-
var UpgradableConstructor = getUpgradableConstructor(sel
|
|
8270
|
+
var UpgradableConstructor = getUpgradableConstructor(sel);
|
|
7975
8271
|
var wasComponentUpgraded = false; // the custom element from the registry is expecting an upgrade callback
|
|
7976
8272
|
|
|
7977
8273
|
/**
|
|
@@ -7986,8 +8282,7 @@
|
|
|
7986
8282
|
createVM(elm, def, {
|
|
7987
8283
|
tagName: sel,
|
|
7988
8284
|
mode: options.mode !== 'closed' ? 'open' : 'closed',
|
|
7989
|
-
owner: null
|
|
7990
|
-
renderer: renderer
|
|
8285
|
+
owner: null
|
|
7991
8286
|
});
|
|
7992
8287
|
ConnectingSlot.set(elm, connectRootElement);
|
|
7993
8288
|
DisconnectingSlot.set(elm, disconnectRootElement);
|
|
@@ -8012,6 +8307,10 @@
|
|
|
8012
8307
|
function hydrateComponent(element, Ctor) {
|
|
8013
8308
|
var props = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
8014
8309
|
|
|
8310
|
+
if (!(element instanceof Element)) {
|
|
8311
|
+
throw new TypeError("\"hydrateComponent\" expects a valid DOM element as the first parameter but instead received ".concat(element, "."));
|
|
8312
|
+
}
|
|
8313
|
+
|
|
8015
8314
|
if (!isFunction$1(Ctor)) {
|
|
8016
8315
|
throw new TypeError("\"hydrateComponent\" expects a valid component constructor as the second parameter but instead received ".concat(Ctor, "."));
|
|
8017
8316
|
}
|
|
@@ -8029,7 +8328,6 @@
|
|
|
8029
8328
|
createVM(element, def, {
|
|
8030
8329
|
mode: 'open',
|
|
8031
8330
|
owner: null,
|
|
8032
|
-
renderer: renderer,
|
|
8033
8331
|
tagName: element.tagName.toLowerCase()
|
|
8034
8332
|
});
|
|
8035
8333
|
|
|
@@ -8116,8 +8414,7 @@
|
|
|
8116
8414
|
createVM(_assertThisInitialized(_this6), def, {
|
|
8117
8415
|
mode: 'open',
|
|
8118
8416
|
owner: null,
|
|
8119
|
-
tagName: _this6.tagName
|
|
8120
|
-
renderer: renderer
|
|
8417
|
+
tagName: _this6.tagName
|
|
8121
8418
|
});
|
|
8122
8419
|
return _this6;
|
|
8123
8420
|
}
|
|
@@ -8190,7 +8487,7 @@
|
|
|
8190
8487
|
return false;
|
|
8191
8488
|
}
|
|
8192
8489
|
|
|
8193
|
-
if (
|
|
8490
|
+
if (isSyntheticShadowDefined) {
|
|
8194
8491
|
// TODO [#1252]: old behavior that is still used by some pieces of the platform,
|
|
8195
8492
|
// specifically, nodes inserted manually on places where `lwc:dom="manual"` directive is not
|
|
8196
8493
|
// used, will be considered global elements.
|
|
@@ -8242,7 +8539,7 @@
|
|
|
8242
8539
|
});
|
|
8243
8540
|
freeze(LightningElement);
|
|
8244
8541
|
seal(LightningElement.prototype);
|
|
8245
|
-
/* version: 2.
|
|
8542
|
+
/* version: 2.7.2 */
|
|
8246
8543
|
|
|
8247
8544
|
exports.LightningElement = LightningElement;
|
|
8248
8545
|
exports.__unstable__ProfilerControl = profilerControl;
|