lwc 2.45.1 → 2.45.3

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 (68) hide show
  1. package/dist/engine-dom/esm/es2017/engine-dom.js +101 -60
  2. package/dist/engine-dom/esm/es2017/engine-dom.js.map +1 -1
  3. package/dist/engine-dom/iife/es2017/engine-dom.js +101 -60
  4. package/dist/engine-dom/iife/es2017/engine-dom.js.map +1 -1
  5. package/dist/engine-dom/iife/es2017/engine-dom.min.js +1 -1
  6. package/dist/engine-dom/iife/es2017/engine-dom_debug.js +110 -58
  7. package/dist/engine-dom/iife/es2017/engine-dom_debug.js.map +1 -1
  8. package/dist/engine-dom/iife/es5/engine-dom.js +114 -62
  9. package/dist/engine-dom/iife/es5/engine-dom.js.map +1 -1
  10. package/dist/engine-dom/iife/es5/engine-dom.min.js +1 -1
  11. package/dist/engine-dom/iife/es5/engine-dom_debug.js +123 -60
  12. package/dist/engine-dom/iife/es5/engine-dom_debug.js.map +1 -1
  13. package/dist/engine-dom/umd/es2017/engine-dom.js +101 -60
  14. package/dist/engine-dom/umd/es2017/engine-dom.js.map +1 -1
  15. package/dist/engine-dom/umd/es2017/engine-dom.min.js +1 -1
  16. package/dist/engine-dom/umd/es2017/engine-dom_debug.js +110 -58
  17. package/dist/engine-dom/umd/es2017/engine-dom_debug.js.map +1 -1
  18. package/dist/engine-dom/umd/es5/engine-dom.js +114 -62
  19. package/dist/engine-dom/umd/es5/engine-dom.js.map +1 -1
  20. package/dist/engine-dom/umd/es5/engine-dom.min.js +1 -1
  21. package/dist/engine-dom/umd/es5/engine-dom_debug.js +123 -60
  22. package/dist/engine-dom/umd/es5/engine-dom_debug.js.map +1 -1
  23. package/dist/engine-server/commonjs/es2017/engine-server.js +7796 -92
  24. package/dist/engine-server/commonjs/es2017/engine-server.js.map +1 -1
  25. package/dist/engine-server/commonjs/es2017/engine-server.min.js +1 -1
  26. package/dist/engine-server/esm/es2017/engine-server.js +7795 -72
  27. package/dist/engine-server/esm/es2017/engine-server.js.map +1 -1
  28. package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js +72 -13
  29. package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js.map +1 -1
  30. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js +72 -13
  31. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js.map +1 -1
  32. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.min.js +40 -2
  33. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js +56 -6
  34. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js.map +1 -1
  35. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js +71 -12
  36. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js.map +1 -1
  37. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.min.js +39 -1
  38. package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js +43 -4
  39. package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js.map +1 -1
  40. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js +72 -13
  41. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js.map +1 -1
  42. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.min.js +40 -2
  43. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js +56 -6
  44. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js.map +1 -1
  45. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js +71 -12
  46. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js.map +1 -1
  47. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.min.js +39 -1
  48. package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js +43 -4
  49. package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js.map +1 -1
  50. package/dist/wire-service/esm/es2017/wire-service.js +10 -4
  51. package/dist/wire-service/esm/es2017/wire-service.js.map +1 -1
  52. package/dist/wire-service/iife/es2017/wire-service.js +10 -4
  53. package/dist/wire-service/iife/es2017/wire-service.js.map +1 -1
  54. package/dist/wire-service/iife/es2017/wire-service_debug.js +10 -4
  55. package/dist/wire-service/iife/es2017/wire-service_debug.js.map +1 -1
  56. package/dist/wire-service/iife/es5/wire-service.js +10 -4
  57. package/dist/wire-service/iife/es5/wire-service.js.map +1 -1
  58. package/dist/wire-service/iife/es5/wire-service_debug.js +10 -4
  59. package/dist/wire-service/iife/es5/wire-service_debug.js.map +1 -1
  60. package/dist/wire-service/umd/es2017/wire-service.js +10 -4
  61. package/dist/wire-service/umd/es2017/wire-service.js.map +1 -1
  62. package/dist/wire-service/umd/es2017/wire-service_debug.js +10 -4
  63. package/dist/wire-service/umd/es2017/wire-service_debug.js.map +1 -1
  64. package/dist/wire-service/umd/es5/wire-service.js +10 -4
  65. package/dist/wire-service/umd/es5/wire-service.js.map +1 -1
  66. package/dist/wire-service/umd/es5/wire-service_debug.js +10 -4
  67. package/dist/wire-service/umd/es5/wire-service_debug.js.map +1 -1
  68. package/package.json +7 -7
@@ -1,9 +1,11 @@
1
1
  var LWC = (function (exports) {
2
2
  'use strict';
3
3
 
4
- /* proxy-compat-disable */
5
4
  /**
6
- * Copyright (C) 2018 salesforce.com, inc.
5
+ * Copyright (C) 2023 salesforce.com, inc.
6
+ */
7
+ /**
8
+ * Copyright (C) 2023 salesforce.com, inc.
7
9
  */
8
10
  /*
9
11
  * Copyright (c) 2018, salesforce.com, inc.
@@ -46,7 +48,16 @@ var LWC = (function (exports) {
46
48
  */
47
49
  const { assign, create, defineProperties, defineProperty, freeze, getOwnPropertyDescriptor: getOwnPropertyDescriptor$1, getOwnPropertyNames: getOwnPropertyNames$1, getPrototypeOf: getPrototypeOf$1, hasOwnProperty: hasOwnProperty$1, isFrozen, keys, seal, setPrototypeOf, } = Object;
48
50
  const { isArray: isArray$1 } = Array;
49
- const { concat: ArrayConcat$1, copyWithin: ArrayCopyWithin, fill: ArrayFill, filter: ArrayFilter, find: ArrayFind, findIndex: ArrayFindIndex, indexOf: ArrayIndexOf, join: ArrayJoin, map: ArrayMap, pop: ArrayPop, push: ArrayPush$1, reduce: ArrayReduce, reverse: ArrayReverse, shift: ArrayShift, slice: ArraySlice, some: ArraySome, sort: ArraySort, splice: ArraySplice, unshift: ArrayUnshift, forEach, } = Array.prototype;
51
+ const { concat: ArrayConcat$1, copyWithin: ArrayCopyWithin, every: ArrayEvery, fill: ArrayFill, filter: ArrayFilter, find: ArrayFind, findIndex: ArrayFindIndex, includes: ArrayIncludes, indexOf: ArrayIndexOf, join: ArrayJoin, map: ArrayMap, pop: ArrayPop, push: ArrayPush$1, reduce: ArrayReduce, reverse: ArrayReverse, shift: ArrayShift, slice: ArraySlice, some: ArraySome, sort: ArraySort, splice: ArraySplice, unshift: ArrayUnshift, forEach, } = Array.prototype;
52
+ // The type of the return value of Array.prototype.every is `this is T[]`. However, once this
53
+ // Array method is pulled out of the prototype, the function is now referencing `this` where
54
+ // `this` is meaningless, resulting in a TypeScript compilation error.
55
+ //
56
+ // Exposing this helper function is the closest we can get to preserving the usage patterns
57
+ // of Array.prototype methods used elsewhere in the codebase.
58
+ function arrayEvery(arr, predicate) {
59
+ return ArrayEvery.call(arr, predicate);
60
+ }
50
61
  const { fromCharCode: StringFromCharCode } = String;
51
62
  const { charCodeAt: StringCharCodeAt, replace: StringReplace, split: StringSplit, slice: StringSlice, toLowerCase: StringToLowerCase, } = String.prototype;
52
63
  function isUndefined$1(obj) {
@@ -187,7 +198,7 @@ var LWC = (function (exports) {
187
198
  })();
188
199
  // These attributes take either an ID or a list of IDs as values.
189
200
  // This includes aria-* attributes as well as the special non-ARIA "for" attribute
190
- const ID_REFERENCING_ATTRIBUTES_SET = new Set([
201
+ const ID_REFERENCING_ATTRIBUTES_SET = /*@__PURE__*/ new Set([
191
202
  'aria-activedescendant',
192
203
  'aria-controls',
193
204
  'aria-describedby',
@@ -274,11 +285,11 @@ var LWC = (function (exports) {
274
285
  /**
275
286
  * Map associating previously transformed HTML property into HTML attribute.
276
287
  */
277
- const CACHED_PROPERTY_ATTRIBUTE_MAPPING = new Map();
288
+ const CACHED_PROPERTY_ATTRIBUTE_MAPPING = /*@__PURE__@*/ new Map();
278
289
  /**
279
290
  * Map associating previously transformed HTML attribute into HTML property.
280
291
  */
281
- const CACHED_ATTRIBUTE_PROPERTY_MAPPING = new Map();
292
+ const CACHED_ATTRIBUTE_PROPERTY_MAPPING = /*@__PURE__@*/ new Map();
282
293
  function htmlPropertyToAttribute(propName) {
283
294
  const ariaAttributeName = AriaPropNameToAttrNameMap[propName];
284
295
  if (!isUndefined$1(ariaAttributeName)) {
@@ -332,12 +343,12 @@ var LWC = (function (exports) {
332
343
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
333
344
  */
334
345
  // Increment whenever the LWC template compiler changes
335
- const LWC_VERSION = "2.45.1";
346
+ const LWC_VERSION = "2.45.3";
336
347
  const LWC_VERSION_COMMENT_REGEX = /\/\*LWC compiler v([\d.]+)\*\/\s*}/;
337
- /** version: 2.45.1 */
348
+ /** version: 2.45.3 */
338
349
 
339
350
  /**
340
- * Copyright (C) 2018 salesforce.com, inc.
351
+ * Copyright (C) 2023 salesforce.com, inc.
341
352
  */
342
353
 
343
354
  /*
@@ -412,10 +423,10 @@ var LWC = (function (exports) {
412
423
  setFeatureFlag(name, value);
413
424
  }
414
425
  }
415
- /** version: 2.45.1 */
426
+ /** version: 2.45.3 */
416
427
 
417
428
  /**
418
- * Copyright (C) 2018 salesforce.com, inc.
429
+ * Copyright (C) 2023 salesforce.com, inc.
419
430
  */
420
431
 
421
432
  /*
@@ -476,7 +487,7 @@ var LWC = (function (exports) {
476
487
  }
477
488
  }
478
489
  }
479
- /** version: 2.45.1 */
490
+ /** version: 2.45.3 */
480
491
 
481
492
  /*
482
493
  * Copyright (c) 2018, salesforce.com, inc.
@@ -490,7 +501,9 @@ var LWC = (function (exports) {
490
501
  applyAriaReflection();
491
502
  }
492
503
 
493
- /* proxy-compat-disable */
504
+ /**
505
+ * Copyright (C) 2023 salesforce.com, inc.
506
+ */
494
507
 
495
508
  /*
496
509
  * Copyright (c) 2018, salesforce.com, inc.
@@ -919,19 +932,6 @@ var LWC = (function (exports) {
919
932
  'tabIndex',
920
933
  'title',
921
934
  ];
922
- let controlledElement = null;
923
- let controlledAttributeName;
924
- function isAttributeLocked(elm, attrName) {
925
- return elm !== controlledElement || attrName !== controlledAttributeName;
926
- }
927
- function lockAttribute(_elm, _key) {
928
- controlledElement = null;
929
- controlledAttributeName = undefined;
930
- }
931
- function unlockAttribute(elm, key) {
932
- controlledElement = elm;
933
- controlledAttributeName = key;
934
- }
935
935
 
936
936
  /*
937
937
  * Copyright (c) 2018, salesforce.com, inc.
@@ -970,6 +970,7 @@ var LWC = (function (exports) {
970
970
  * SPDX-License-Identifier: MIT
971
971
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
972
972
  */
973
+ /* eslint @lwc/lwc-internal/no-production-assert: "off" */
973
974
  function generateDataDescriptor(options) {
974
975
  return assign({
975
976
  configurable: true,
@@ -1799,6 +1800,14 @@ var LWC = (function (exports) {
1799
1800
  * SPDX-License-Identifier: MIT
1800
1801
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
1801
1802
  */
1803
+ /**
1804
+ * This module is responsible for producing the ComponentDef object that is always
1805
+ * accessible via `vm.def`. This is lazily created during the creation of the first
1806
+ * instance of a component class, and shared across all instances.
1807
+ *
1808
+ * This structure can be used to synthetically create proxies, and understand the
1809
+ * shape of a component. It is also used internally to apply extra optimizations.
1810
+ */
1802
1811
  /**
1803
1812
  * This operation is called with a descriptor of an standard html property
1804
1813
  * that a Custom Element can support (including AOM properties), which
@@ -1962,15 +1971,11 @@ var LWC = (function (exports) {
1962
1971
  removeAttribute(name) {
1963
1972
  const vm = getAssociatedVM(this);
1964
1973
  const { elm, renderer: { removeAttribute }, } = vm;
1965
- unlockAttribute(elm, name);
1966
1974
  removeAttribute(elm, name);
1967
- lockAttribute();
1968
1975
  },
1969
1976
  removeAttributeNS(namespace, name) {
1970
1977
  const { elm, renderer: { removeAttribute }, } = getAssociatedVM(this);
1971
- unlockAttribute(elm, name);
1972
1978
  removeAttribute(elm, name, namespace);
1973
- lockAttribute();
1974
1979
  },
1975
1980
  getAttribute(name) {
1976
1981
  const vm = getAssociatedVM(this);
@@ -1992,9 +1997,7 @@ var LWC = (function (exports) {
1992
1997
  logError(`Failed to construct '${getComponentTag(vm)}': The result must not have attributes.`);
1993
1998
  }
1994
1999
  }
1995
- unlockAttribute(elm, name);
1996
2000
  setAttribute(elm, name, value);
1997
- lockAttribute();
1998
2001
  },
1999
2002
  setAttributeNS(namespace, name, value) {
2000
2003
  const vm = getAssociatedVM(this);
@@ -2004,9 +2007,7 @@ var LWC = (function (exports) {
2004
2007
  logError(`Failed to construct '${getComponentTag(vm)}': The result must not have attributes.`);
2005
2008
  }
2006
2009
  }
2007
- unlockAttribute(elm, name);
2008
2010
  setAttribute(elm, name, value, namespace);
2009
- lockAttribute();
2010
2011
  },
2011
2012
  getBoundingClientRect() {
2012
2013
  const vm = getAssociatedVM(this);
@@ -2388,7 +2389,7 @@ var LWC = (function (exports) {
2388
2389
  });
2389
2390
  runWithBoundaryProtection(vm, vm, noop, () => {
2390
2391
  // job
2391
- connector = new adapter(dataCallback);
2392
+ connector = new adapter(dataCallback, { tagName: vm.tagName });
2392
2393
  }, noop);
2393
2394
  const updateConnectorConfig = (config) => {
2394
2395
  // every time the config is recomputed due to tracking,
@@ -2956,6 +2957,10 @@ var LWC = (function (exports) {
2956
2957
  * SPDX-License-Identifier: MIT
2957
2958
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
2958
2959
  */
2960
+ /**
2961
+ * This module is responsible for creating the base bridge class BaseBridgeElement
2962
+ * that represents the HTMLElement extension used for any LWC inserted in the DOM.
2963
+ */
2959
2964
  // A bridge descriptor is a descriptor whose job is just to get the component instance
2960
2965
  // from the element instance, and get the value or set a new value on the component.
2961
2966
  // This means that across different elements, similar names can get the exact same
@@ -3009,14 +3014,6 @@ var LWC = (function (exports) {
3009
3014
  }
3010
3015
  return;
3011
3016
  }
3012
- if (!isAttributeLocked(this, attrName)) {
3013
- // Ignore changes triggered by the engine itself during:
3014
- // * diffing when public props are attempting to reflect to the DOM
3015
- // * component via `this.setAttribute()`, should never update the prop
3016
- // Both cases, the setAttribute call is always wrapped by the unlocking of the
3017
- // attribute to be changed
3018
- return;
3019
- }
3020
3017
  // Reflect attribute change to the corresponding property when changed from outside.
3021
3018
  this[propName] = newValue;
3022
3019
  };
@@ -3361,6 +3358,14 @@ var LWC = (function (exports) {
3361
3358
  * SPDX-License-Identifier: MIT
3362
3359
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
3363
3360
  */
3361
+ /**
3362
+ * This module is responsible for producing the ComponentDef object that is always
3363
+ * accessible via `vm.def`. This is lazily created during the creation of the first
3364
+ * instance of a component class, and shared across all instances.
3365
+ *
3366
+ * This structure can be used to synthetically create proxies, and understand the
3367
+ * shape of a component. It is also used internally to apply extra optimizations.
3368
+ */
3364
3369
  const CtorToDefMap = new WeakMap();
3365
3370
  function getCtorProto(Ctor) {
3366
3371
  let proto = getPrototypeOf$1(Ctor);
@@ -3802,7 +3807,6 @@ var LWC = (function (exports) {
3802
3807
  const cur = attrs[key];
3803
3808
  const old = oldAttrs[key];
3804
3809
  if (old !== cur) {
3805
- unlockAttribute(elm, key);
3806
3810
  if (StringCharCodeAt.call(key, 3) === ColonCharCode$1) {
3807
3811
  // Assume xml namespace
3808
3812
  setAttribute(elm, key, cur, XML_NAMESPACE);
@@ -3817,7 +3821,6 @@ var LWC = (function (exports) {
3817
3821
  else {
3818
3822
  setAttribute(elm, key, cur);
3819
3823
  }
3820
- lockAttribute();
3821
3824
  }
3822
3825
  }
3823
3826
  }
@@ -6705,6 +6708,27 @@ var LWC = (function (exports) {
6705
6708
  }
6706
6709
  return false;
6707
6710
  }
6711
+ // The validationOptOut static property can be an array of attribute names.
6712
+ // Any attribute names specified in that array will not be validated, and the
6713
+ // LWC runtime will assume that VDOM attrs and DOM attrs are in sync.
6714
+ function getValidationPredicate(optOutStaticProp) {
6715
+ if (isUndefined$1(optOutStaticProp)) {
6716
+ return (_attrName) => true;
6717
+ }
6718
+ // If validationOptOut is true, no attributes will be checked for correctness
6719
+ // and the runtime will assume VDOM attrs and DOM attrs are in sync.
6720
+ if (isTrue(optOutStaticProp)) {
6721
+ return (_attrName) => false;
6722
+ }
6723
+ // If validationOptOut is an array of strings, attributes specified in the
6724
+ // array will be "opted out". Attributes not specified in the array will still
6725
+ // be validated.
6726
+ if (isArray$1(optOutStaticProp) && arrayEvery(optOutStaticProp, isString)) {
6727
+ return (attrName) => !ArrayIncludes.call(optOutStaticProp, attrName);
6728
+ }
6729
+ logWarn('Validation opt out must be `true` or an array of attributes that should not be validated.');
6730
+ return (_attrName) => true;
6731
+ }
6708
6732
  function hydrateText(node, vnode, renderer) {
6709
6733
  var _a;
6710
6734
  if (!hasCorrectNodeType(vnode, node, 3 /* EnvNodeTypes.TEXT */, renderer)) {
@@ -6783,8 +6807,19 @@ var LWC = (function (exports) {
6783
6807
  return elm;
6784
6808
  }
6785
6809
  function hydrateCustomElement(elm, vnode, renderer) {
6810
+ const { validationOptOut } = vnode.ctor;
6811
+ const shouldValidateAttr = getValidationPredicate(validationOptOut);
6812
+ // The validationOptOut static property can be an array of attribute names.
6813
+ // Any attribute names specified in that array will not be validated, and the
6814
+ // LWC runtime will assume that VDOM attrs and DOM attrs are in sync.
6815
+ //
6816
+ // If validationOptOut is true, no attributes will be checked for correctness
6817
+ // and the runtime will assume VDOM attrs and DOM attrs are in sync.
6818
+ //
6819
+ // Therefore, if validationOptOut is falsey or an array of strings, we need to
6820
+ // examine some or all of the custom element's attributes.
6786
6821
  if (!hasCorrectNodeType(vnode, elm, 1 /* EnvNodeTypes.ELEMENT */, renderer) ||
6787
- !isMatchingElement(vnode, elm, renderer)) {
6822
+ !isMatchingElement(vnode, elm, renderer, shouldValidateAttr)) {
6788
6823
  return handleMismatch(elm, vnode, renderer);
6789
6824
  }
6790
6825
  const { sel, mode, ctor, owner } = vnode;
@@ -6815,14 +6850,12 @@ var LWC = (function (exports) {
6815
6850
  function hydrateChildren(node, children, parentNode, owner) {
6816
6851
  let hasWarned = false;
6817
6852
  let nextNode = node;
6818
- let anchor = null;
6819
6853
  const { renderer } = owner;
6820
6854
  for (let i = 0; i < children.length; i++) {
6821
6855
  const childVnode = children[i];
6822
6856
  if (!isNull(childVnode)) {
6823
6857
  if (nextNode) {
6824
6858
  nextNode = hydrateNode(nextNode, childVnode, renderer);
6825
- anchor = childVnode.elm;
6826
6859
  }
6827
6860
  else {
6828
6861
  hasMismatch = true;
@@ -6832,8 +6865,8 @@ var LWC = (function (exports) {
6832
6865
  logError(`Hydration mismatch: incorrect number of rendered nodes. Client produced more nodes than the server.`, owner);
6833
6866
  }
6834
6867
  }
6835
- mount(childVnode, parentNode, renderer, anchor);
6836
- anchor = childVnode.elm;
6868
+ mount(childVnode, parentNode, renderer, nextNode);
6869
+ nextNode = renderer.nextSibling(childVnode.elm);
6837
6870
  }
6838
6871
  }
6839
6872
  }
@@ -6878,7 +6911,7 @@ var LWC = (function (exports) {
6878
6911
  }
6879
6912
  return true;
6880
6913
  }
6881
- function isMatchingElement(vnode, elm, renderer) {
6914
+ function isMatchingElement(vnode, elm, renderer, shouldValidateAttr = () => true) {
6882
6915
  const { getProperty } = renderer;
6883
6916
  if (vnode.sel.toLowerCase() !== getProperty(elm, 'tagName').toLowerCase()) {
6884
6917
  if (process.env.NODE_ENV !== 'production') {
@@ -6886,10 +6919,14 @@ var LWC = (function (exports) {
6886
6919
  }
6887
6920
  return false;
6888
6921
  }
6889
- const hasIncompatibleAttrs = validateAttrs(vnode, elm, renderer);
6890
- const hasIncompatibleClass = validateClassAttr(vnode, elm, renderer);
6891
- const hasIncompatibleStyle = validateStyleAttr(vnode, elm, renderer);
6892
- return hasIncompatibleAttrs && hasIncompatibleClass && hasIncompatibleStyle;
6922
+ const hasCompatibleAttrs = validateAttrs(vnode, elm, renderer, shouldValidateAttr);
6923
+ const hasCompatibleClass = shouldValidateAttr('class')
6924
+ ? validateClassAttr(vnode, elm, renderer)
6925
+ : true;
6926
+ const hasCompatibleStyle = shouldValidateAttr('style')
6927
+ ? validateStyleAttr(vnode, elm, renderer)
6928
+ : true;
6929
+ return hasCompatibleAttrs && hasCompatibleClass && hasCompatibleStyle;
6893
6930
  }
6894
6931
  function attributeValuesAreEqual(vnodeValue, value) {
6895
6932
  const vnodeValueAsString = String(vnodeValue);
@@ -6904,12 +6941,15 @@ var LWC = (function (exports) {
6904
6941
  // In all other cases, the two values are not considered equal
6905
6942
  return false;
6906
6943
  }
6907
- function validateAttrs(vnode, elm, renderer) {
6944
+ function validateAttrs(vnode, elm, renderer, shouldValidateAttr) {
6908
6945
  const { data: { attrs = {} }, } = vnode;
6909
6946
  let nodesAreCompatible = true;
6910
6947
  // Validate attributes, though we could always recovery from those by running the update mods.
6911
6948
  // Note: intentionally ONLY matching vnodes.attrs to elm.attrs, in case SSR is adding extra attributes.
6912
6949
  for (const [attrName, attrValue] of Object.entries(attrs)) {
6950
+ if (!shouldValidateAttr(attrName)) {
6951
+ continue;
6952
+ }
6913
6953
  const { owner } = vnode;
6914
6954
  const { getAttribute } = renderer;
6915
6955
  const elmAttrValue = getAttribute(elm, attrName);
@@ -7333,7 +7373,7 @@ var LWC = (function (exports) {
7333
7373
  }
7334
7374
  return getReadOnlyProxy(obj);
7335
7375
  }
7336
- /* version: 2.45.1 */
7376
+ /** version: 2.45.3 */
7337
7377
 
7338
7378
  /*
7339
7379
  * Copyright (c) 2018, salesforce.com, inc.
@@ -7595,6 +7635,7 @@ var LWC = (function (exports) {
7595
7635
  * SPDX-License-Identifier: MIT
7596
7636
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
7597
7637
  */
7638
+ new WeakMap();
7598
7639
  // Creates a custom element for compat (legacy) browser environments
7599
7640
  const createCustomElementCompat = (tagName, upgradeCallback) => {
7600
7641
  const elm = document.createElement(tagName);
@@ -7721,7 +7762,7 @@ var LWC = (function (exports) {
7721
7762
  const renderer = (function (exports) {
7722
7763
 
7723
7764
  /**
7724
- * Copyright (C) 2018 salesforce.com, inc.
7765
+ * Copyright (C) 2023 salesforce.com, inc.
7725
7766
  */
7726
7767
  /*
7727
7768
  * Copyright (c) 2018, salesforce.com, inc.
@@ -7761,7 +7802,7 @@ var LWC = (function (exports) {
7761
7802
  function isNull(obj) {
7762
7803
  return obj === null;
7763
7804
  }
7764
- /** version: 2.45.1 */
7805
+ /** version: 2.45.3 */
7765
7806
 
7766
7807
  /*
7767
7808
  * Copyright (c) 2023, salesforce.com, inc.
@@ -8380,7 +8421,7 @@ var LWC = (function (exports) {
8380
8421
  });
8381
8422
  }));
8382
8423
  }
8383
- /* version: 2.45.1 */
8424
+ /** version: 2.45.3 */
8384
8425
 
8385
8426
  exports.LightningElement = LightningElement;
8386
8427
  exports.__unstable__ProfilerControl = profilerControl;