lwc 2.45.2 → 2.45.4

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 +49 -50
  2. package/dist/engine-dom/esm/es2017/engine-dom.js.map +1 -1
  3. package/dist/engine-dom/iife/es2017/engine-dom.js +49 -50
  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 +55 -48
  7. package/dist/engine-dom/iife/es2017/engine-dom_debug.js.map +1 -1
  8. package/dist/engine-dom/iife/es5/engine-dom.js +55 -54
  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 +61 -52
  12. package/dist/engine-dom/iife/es5/engine-dom_debug.js.map +1 -1
  13. package/dist/engine-dom/umd/es2017/engine-dom.js +49 -50
  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 +55 -48
  17. package/dist/engine-dom/umd/es2017/engine-dom_debug.js.map +1 -1
  18. package/dist/engine-dom/umd/es5/engine-dom.js +55 -54
  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 +61 -52
  22. package/dist/engine-dom/umd/es5/engine-dom_debug.js.map +1 -1
  23. package/dist/engine-server/commonjs/es2017/engine-server.js +7798 -89
  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 +7797 -69
  27. package/dist/engine-server/esm/es2017/engine-server.js.map +1 -1
  28. package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js +73 -11
  29. package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js.map +1 -1
  30. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js +73 -11
  31. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js.map +1 -1
  32. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.min.js +39 -1
  33. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js +57 -4
  34. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js.map +1 -1
  35. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js +73 -11
  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 +44 -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 +73 -11
  41. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js.map +1 -1
  42. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.min.js +39 -1
  43. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js +57 -4
  44. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js.map +1 -1
  45. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js +73 -11
  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 +44 -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 +12 -4
  51. package/dist/wire-service/esm/es2017/wire-service.js.map +1 -1
  52. package/dist/wire-service/iife/es2017/wire-service.js +12 -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 +12 -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 +12 -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 +12 -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 +12 -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 +12 -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 +12 -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 +12 -4
  67. package/dist/wire-service/umd/es5/wire-service_debug.js.map +1 -1
  68. package/package.json +7 -7
@@ -31,7 +31,11 @@ var LWC = (function (exports) {
31
31
  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); }
32
32
  /* proxy-compat-disable */
33
33
  /**
34
- * Copyright (C) 2018 salesforce.com, inc.
34
+ * Copyright (C) 2023 salesforce.com, inc.
35
+ */
36
+ /* proxy-compat-disable */
37
+ /**
38
+ * Copyright (C) 2023 salesforce.com, inc.
35
39
  */
36
40
  /*
37
41
  * Copyright (c) 2018, salesforce.com, inc.
@@ -215,7 +219,7 @@ var LWC = (function (exports) {
215
219
  AriaPropNameToAttrNameMap = _ref.AriaPropNameToAttrNameMap;
216
220
  // These attributes take either an ID or a list of IDs as values.
217
221
  // This includes aria-* attributes as well as the special non-ARIA "for" attribute
218
- var ID_REFERENCING_ATTRIBUTES_SET = new Set(['aria-activedescendant', 'aria-controls', 'aria-describedby', 'aria-details', 'aria-errormessage', 'aria-flowto', 'aria-labelledby', 'aria-owns', 'for']);
222
+ var ID_REFERENCING_ATTRIBUTES_SET = /*@__PURE__*/new Set(['aria-activedescendant', 'aria-controls', 'aria-describedby', 'aria-details', 'aria-errormessage', 'aria-flowto', 'aria-labelledby', 'aria-owns', 'for']);
219
223
 
220
224
  /*
221
225
  * Copyright (c) 2018, salesforce.com, inc.
@@ -278,11 +282,11 @@ var LWC = (function (exports) {
278
282
  /**
279
283
  * Map associating previously transformed HTML property into HTML attribute.
280
284
  */
281
- var CACHED_PROPERTY_ATTRIBUTE_MAPPING = new Map();
285
+ var CACHED_PROPERTY_ATTRIBUTE_MAPPING = /*@__PURE__@*/new Map();
282
286
  /**
283
287
  * Map associating previously transformed HTML attribute into HTML property.
284
288
  */
285
- var CACHED_ATTRIBUTE_PROPERTY_MAPPING = new Map();
289
+ var CACHED_ATTRIBUTE_PROPERTY_MAPPING = /*@__PURE__@*/new Map();
286
290
  function htmlPropertyToAttribute(propName) {
287
291
  var ariaAttributeName = AriaPropNameToAttrNameMap[propName];
288
292
  if (!isUndefined$1(ariaAttributeName)) {
@@ -338,12 +342,13 @@ var LWC = (function (exports) {
338
342
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
339
343
  */
340
344
  // Increment whenever the LWC template compiler changes
341
- var LWC_VERSION = "2.45.2";
345
+ var LWC_VERSION = "2.45.4";
342
346
  var LWC_VERSION_COMMENT_REGEX = /\/\*LWC compiler v([\d.]+)\*\/\s*}/;
343
- /** version: 2.45.2 */
347
+ /** version: 2.45.4 */
344
348
 
349
+ /* proxy-compat-disable */
345
350
  /**
346
- * Copyright (C) 2018 salesforce.com, inc.
351
+ * Copyright (C) 2023 salesforce.com, inc.
347
352
  */
348
353
 
349
354
  /*
@@ -420,10 +425,11 @@ var LWC = (function (exports) {
420
425
  setFeatureFlag(name, value);
421
426
  }
422
427
  }
423
- /** version: 2.45.2 */
428
+ /** version: 2.45.4 */
424
429
 
430
+ /* proxy-compat-disable */
425
431
  /**
426
- * Copyright (C) 2018 salesforce.com, inc.
432
+ * Copyright (C) 2023 salesforce.com, inc.
427
433
  */
428
434
 
429
435
  /*
@@ -484,7 +490,7 @@ var LWC = (function (exports) {
484
490
  }
485
491
  }
486
492
  }
487
- /** version: 2.45.2 */
493
+ /** version: 2.45.4 */
488
494
 
489
495
  /*
490
496
  * Copyright (c) 2018, salesforce.com, inc.
@@ -499,6 +505,9 @@ var LWC = (function (exports) {
499
505
  }
500
506
 
501
507
  /* proxy-compat-disable */
508
+ /**
509
+ * Copyright (C) 2023 salesforce.com, inc.
510
+ */
502
511
 
503
512
  /*
504
513
  * Copyright (c) 2018, salesforce.com, inc.
@@ -951,19 +960,6 @@ var LWC = (function (exports) {
951
960
  */
952
961
  // These properties get added to LWCElement.prototype publicProps automatically
953
962
  var defaultDefHTMLPropertyNames = ['accessKey', 'dir', 'draggable', 'hidden', 'id', 'lang', 'spellcheck', 'tabIndex', 'title'];
954
- var controlledElement = null;
955
- var controlledAttributeName;
956
- function isAttributeLocked(elm, attrName) {
957
- return elm !== controlledElement || attrName !== controlledAttributeName;
958
- }
959
- function lockAttribute(_elm, _key) {
960
- controlledElement = null;
961
- controlledAttributeName = undefined;
962
- }
963
- function unlockAttribute(elm, key) {
964
- controlledElement = elm;
965
- controlledAttributeName = key;
966
- }
967
963
 
968
964
  /*
969
965
  * Copyright (c) 2018, salesforce.com, inc.
@@ -1002,6 +998,7 @@ var LWC = (function (exports) {
1002
998
  * SPDX-License-Identifier: MIT
1003
999
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
1004
1000
  */
1001
+ /* eslint @lwc/lwc-internal/no-production-assert: "off" */
1005
1002
  function generateDataDescriptor(options) {
1006
1003
  return assign({
1007
1004
  configurable: true,
@@ -1947,6 +1944,14 @@ var LWC = (function (exports) {
1947
1944
  * SPDX-License-Identifier: MIT
1948
1945
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
1949
1946
  */
1947
+ /**
1948
+ * This module is responsible for producing the ComponentDef object that is always
1949
+ * accessible via `vm.def`. This is lazily created during the creation of the first
1950
+ * instance of a component class, and shared across all instances.
1951
+ *
1952
+ * This structure can be used to synthetically create proxies, and understand the
1953
+ * shape of a component. It is also used internally to apply extra optimizations.
1954
+ */
1950
1955
  /**
1951
1956
  * This operation is called with a descriptor of an standard html property
1952
1957
  * that a Custom Element can support (including AOM properties), which
@@ -2123,17 +2128,13 @@ var LWC = (function (exports) {
2123
2128
  var vm = getAssociatedVM(this);
2124
2129
  var elm = vm.elm,
2125
2130
  removeAttribute = vm.renderer.removeAttribute;
2126
- unlockAttribute(elm, name);
2127
2131
  removeAttribute(elm, name);
2128
- lockAttribute();
2129
2132
  },
2130
2133
  removeAttributeNS: function removeAttributeNS(namespace, name) {
2131
2134
  var _getAssociatedVM = getAssociatedVM(this),
2132
2135
  elm = _getAssociatedVM.elm,
2133
2136
  removeAttribute = _getAssociatedVM.renderer.removeAttribute;
2134
- unlockAttribute(elm, name);
2135
2137
  removeAttribute(elm, name, namespace);
2136
- lockAttribute();
2137
2138
  },
2138
2139
  getAttribute: function getAttribute(name) {
2139
2140
  var vm = getAssociatedVM(this);
@@ -2156,9 +2157,7 @@ var LWC = (function (exports) {
2156
2157
  logError("Failed to construct '".concat(getComponentTag(vm), "': The result must not have attributes."));
2157
2158
  }
2158
2159
  }
2159
- unlockAttribute(elm, name);
2160
2160
  setAttribute(elm, name, value);
2161
- lockAttribute();
2162
2161
  },
2163
2162
  setAttributeNS: function setAttributeNS(namespace, name, value) {
2164
2163
  var vm = getAssociatedVM(this);
@@ -2169,9 +2168,7 @@ var LWC = (function (exports) {
2169
2168
  logError("Failed to construct '".concat(getComponentTag(vm), "': The result must not have attributes."));
2170
2169
  }
2171
2170
  }
2172
- unlockAttribute(elm, name);
2173
2171
  setAttribute(elm, name, value, namespace);
2174
- lockAttribute();
2175
2172
  },
2176
2173
  getBoundingClientRect: function getBoundingClientRect() {
2177
2174
  var vm = getAssociatedVM(this);
@@ -2571,7 +2568,9 @@ var LWC = (function (exports) {
2571
2568
  });
2572
2569
  runWithBoundaryProtection(vm, vm, noop, function () {
2573
2570
  // job
2574
- connector = new adapter(dataCallback);
2571
+ connector = new adapter(dataCallback, {
2572
+ tagName: vm.tagName
2573
+ });
2575
2574
  }, noop);
2576
2575
  var updateConnectorConfig = function updateConnectorConfig(config) {
2577
2576
  // every time the config is recomputed due to tracking,
@@ -3161,6 +3160,10 @@ var LWC = (function (exports) {
3161
3160
  * SPDX-License-Identifier: MIT
3162
3161
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
3163
3162
  */
3163
+ /**
3164
+ * This module is responsible for creating the base bridge class BaseBridgeElement
3165
+ * that represents the HTMLElement extension used for any LWC inserted in the DOM.
3166
+ */
3164
3167
  // A bridge descriptor is a descriptor whose job is just to get the component instance
3165
3168
  // from the element instance, and get the value or set a new value on the component.
3166
3169
  // This means that across different elements, similar names can get the exact same
@@ -3215,14 +3218,6 @@ var LWC = (function (exports) {
3215
3218
  }
3216
3219
  return;
3217
3220
  }
3218
- if (!isAttributeLocked(this, attrName)) {
3219
- // Ignore changes triggered by the engine itself during:
3220
- // * diffing when public props are attempting to reflect to the DOM
3221
- // * component via `this.setAttribute()`, should never update the prop
3222
- // Both cases, the setAttribute call is always wrapped by the unlocking of the
3223
- // attribute to be changed
3224
- return;
3225
- }
3226
3221
  // Reflect attribute change to the corresponding property when changed from outside.
3227
3222
  this[propName] = newValue;
3228
3223
  };
@@ -3637,6 +3632,14 @@ var LWC = (function (exports) {
3637
3632
  * SPDX-License-Identifier: MIT
3638
3633
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
3639
3634
  */
3635
+ /**
3636
+ * This module is responsible for producing the ComponentDef object that is always
3637
+ * accessible via `vm.def`. This is lazily created during the creation of the first
3638
+ * instance of a component class, and shared across all instances.
3639
+ *
3640
+ * This structure can be used to synthetically create proxies, and understand the
3641
+ * shape of a component. It is also used internally to apply extra optimizations.
3642
+ */
3640
3643
  var CtorToDefMap = new WeakMap();
3641
3644
  function getCtorProto(Ctor) {
3642
3645
  var proto = getPrototypeOf$1(Ctor);
@@ -3835,9 +3838,9 @@ var LWC = (function (exports) {
3835
3838
  };
3836
3839
  }
3837
3840
  var publicMethods = {};
3838
- for (var _key2 in methods) {
3841
+ for (var _key in methods) {
3839
3842
  // avoid leaking the reference to the public method descriptors
3840
- publicMethods[_key2] = methods[_key2].value;
3843
+ publicMethods[_key] = methods[_key].value;
3841
3844
  }
3842
3845
  return {
3843
3846
  ctor: ctor,
@@ -4096,7 +4099,6 @@ var LWC = (function (exports) {
4096
4099
  var cur = attrs[key];
4097
4100
  var old = oldAttrs[key];
4098
4101
  if (old !== cur) {
4099
- unlockAttribute(elm, key);
4100
4102
  if (StringCharCodeAt.call(key, 3) === ColonCharCode$1) {
4101
4103
  // Assume xml namespace
4102
4104
  setAttribute(elm, key, cur, XML_NAMESPACE);
@@ -4108,7 +4110,6 @@ var LWC = (function (exports) {
4108
4110
  } else {
4109
4111
  setAttribute(elm, key, cur);
4110
4112
  }
4111
- lockAttribute();
4112
4113
  }
4113
4114
  }
4114
4115
  }
@@ -5769,8 +5770,8 @@ var LWC = (function (exports) {
5769
5770
  }
5770
5771
  function buildParseFragmentFn(createFragmentFn) {
5771
5772
  return function (strings) {
5772
- for (var _len3 = arguments.length, keys = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
5773
- keys[_key3 - 1] = arguments[_key3];
5773
+ for (var _len3 = arguments.length, keys = new Array(_len3 > 1 ? _len3 - 1 : 0), _key2 = 1; _key2 < _len3; _key2++) {
5774
+ keys[_key2 - 1] = arguments[_key2];
5774
5775
  }
5775
5776
  var cache = create(null);
5776
5777
  return function () {
@@ -7187,14 +7188,12 @@ var LWC = (function (exports) {
7187
7188
  function hydrateChildren(node, children, parentNode, owner) {
7188
7189
  var hasWarned = false;
7189
7190
  var nextNode = node;
7190
- var anchor = null;
7191
7191
  var renderer = owner.renderer;
7192
7192
  for (var _i36 = 0; _i36 < children.length; _i36++) {
7193
7193
  var childVnode = children[_i36];
7194
7194
  if (!isNull(childVnode)) {
7195
7195
  if (nextNode) {
7196
7196
  nextNode = hydrateNode(nextNode, childVnode, renderer);
7197
- anchor = childVnode.elm;
7198
7197
  } else {
7199
7198
  hasMismatch = true;
7200
7199
  if (process.env.NODE_ENV !== 'production') {
@@ -7203,8 +7202,8 @@ var LWC = (function (exports) {
7203
7202
  logError("Hydration mismatch: incorrect number of rendered nodes. Client produced more nodes than the server.", owner);
7204
7203
  }
7205
7204
  }
7206
- mount(childVnode, parentNode, renderer, anchor);
7207
- anchor = childVnode.elm;
7205
+ mount(childVnode, parentNode, renderer, nextNode);
7206
+ nextNode = renderer.nextSibling(childVnode.elm);
7208
7207
  }
7209
7208
  }
7210
7209
  }
@@ -7742,7 +7741,7 @@ var LWC = (function (exports) {
7742
7741
  }
7743
7742
  return getReadOnlyProxy(obj);
7744
7743
  }
7745
- /* version: 2.45.2 */
7744
+ /** version: 2.45.4 */
7746
7745
 
7747
7746
  /*
7748
7747
  * Copyright (c) 2018, salesforce.com, inc.
@@ -8002,6 +8001,7 @@ var LWC = (function (exports) {
8002
8001
  * SPDX-License-Identifier: MIT
8003
8002
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
8004
8003
  */
8004
+ new WeakMap();
8005
8005
  // Creates a custom element for compat (legacy) browser environments
8006
8006
  var createCustomElementCompat = function createCustomElementCompat(tagName, upgradeCallback) {
8007
8007
  var elm = document.createElement(tagName);
@@ -8128,8 +8128,9 @@ var LWC = (function (exports) {
8128
8128
  */
8129
8129
  function rendererFactory(baseRenderer) {
8130
8130
  var renderer = function (exports) {
8131
+ /* proxy-compat-disable */
8131
8132
  /**
8132
- * Copyright (C) 2018 salesforce.com, inc.
8133
+ * Copyright (C) 2023 salesforce.com, inc.
8133
8134
  */
8134
8135
  /*
8135
8136
  * Copyright (c) 2018, salesforce.com, inc.
@@ -8168,7 +8169,7 @@ var LWC = (function (exports) {
8168
8169
  function isNull(obj) {
8169
8170
  return obj === null;
8170
8171
  }
8171
- /** version: 2.45.2 */
8172
+ /** version: 2.45.4 */
8172
8173
 
8173
8174
  /*
8174
8175
  * Copyright (c) 2023, salesforce.com, inc.
@@ -8810,7 +8811,7 @@ var LWC = (function (exports) {
8810
8811
  });
8811
8812
  });
8812
8813
  }
8813
- /* version: 2.45.2 */
8814
+ /** version: 2.45.4 */
8814
8815
 
8815
8816
  exports.LightningElement = LightningElement;
8816
8817
  exports.__unstable__ProfilerControl = profilerControl;