lwc 2.3.3 → 2.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/engine-dom/esm/es2017/engine-dom.js +360 -198
  2. package/dist/engine-dom/iife/es2017/engine-dom.js +360 -198
  3. package/dist/engine-dom/iife/es2017/engine-dom.min.js +2 -2
  4. package/dist/engine-dom/iife/es2017/engine-dom_debug.js +361 -168
  5. package/dist/engine-dom/iife/es5/engine-dom.js +371 -218
  6. package/dist/engine-dom/iife/es5/engine-dom.min.js +2 -2
  7. package/dist/engine-dom/iife/es5/engine-dom_debug.js +370 -186
  8. package/dist/engine-dom/umd/es2017/engine-dom.js +360 -198
  9. package/dist/engine-dom/umd/es2017/engine-dom.min.js +2 -2
  10. package/dist/engine-dom/umd/es2017/engine-dom_debug.js +361 -168
  11. package/dist/engine-dom/umd/es5/engine-dom.js +371 -218
  12. package/dist/engine-dom/umd/es5/engine-dom.min.js +2 -2
  13. package/dist/engine-dom/umd/es5/engine-dom_debug.js +370 -186
  14. package/dist/engine-server/commonjs/es2017/engine-server.js +304 -205
  15. package/dist/engine-server/commonjs/es2017/engine-server.min.js +2 -2
  16. package/dist/engine-server/esm/es2017/engine-server.js +304 -205
  17. package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js +29 -16
  18. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js +29 -16
  19. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.min.js +2 -2
  20. package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js +29 -16
  21. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js +31 -16
  22. package/dist/synthetic-shadow/iife/es5/synthetic-shadow.min.js +2 -2
  23. package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js +31 -16
  24. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js +29 -16
  25. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.min.js +2 -2
  26. package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js +29 -16
  27. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js +31 -16
  28. package/dist/synthetic-shadow/umd/es5/synthetic-shadow.min.js +2 -2
  29. package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js +31 -16
  30. package/dist/wire-service/esm/es2017/wire-service.js +2 -2
  31. package/dist/wire-service/iife/es2017/wire-service.js +2 -2
  32. package/dist/wire-service/iife/es2017/wire-service_debug.js +2 -2
  33. package/dist/wire-service/iife/es5/wire-service.js +3 -3
  34. package/dist/wire-service/iife/es5/wire-service.min.js +1 -1
  35. package/dist/wire-service/iife/es5/wire-service_debug.js +3 -3
  36. package/dist/wire-service/umd/es2017/wire-service.js +2 -2
  37. package/dist/wire-service/umd/es2017/wire-service_debug.js +2 -2
  38. package/dist/wire-service/umd/es5/wire-service.js +3 -3
  39. package/dist/wire-service/umd/es5/wire-service.min.js +1 -1
  40. package/dist/wire-service/umd/es5/wire-service_debug.js +3 -3
  41. package/package.json +8 -8
@@ -30,7 +30,7 @@
30
30
 
31
31
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf2(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf2(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
32
32
 
33
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
33
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
34
34
 
35
35
  function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
36
36
 
@@ -152,6 +152,10 @@
152
152
  return obj === false;
153
153
  }
154
154
 
155
+ function isBoolean(obj) {
156
+ return typeof obj === 'boolean';
157
+ }
158
+
155
159
  function isFunction$1(obj) {
156
160
  return typeof obj === 'function';
157
161
  }
@@ -291,6 +295,7 @@
291
295
  var KEY__SHADOW_RESOLVER = '$shadowResolver$';
292
296
  var KEY__SHADOW_TOKEN = '$shadowToken$';
293
297
  var KEY__SYNTHETIC_MODE = '$$lwc-synthetic-mode';
298
+ var KEY__SCOPED_CSS = '$scoped$';
294
299
  /**
295
300
  * Map composed of properties to attributes not following the HTML property to attribute mapping
296
301
  * convention.
@@ -339,7 +344,7 @@
339
344
  CACHED_PROPERTY_ATTRIBUTE_MAPPING.set(propName, attributeName);
340
345
  return attributeName;
341
346
  }
342
- /** version: 2.3.3 */
347
+ /** version: 2.5.0 */
343
348
 
344
349
  /*
345
350
  * Copyright (c) 2018, salesforce.com, inc.
@@ -442,19 +447,33 @@
442
447
  */
443
448
 
444
449
 
450
+ var features = {
451
+ ENABLE_REACTIVE_SETTER: null,
452
+ ENABLE_HMR: null,
453
+ ENABLE_INNER_OUTER_TEXT_PATCH: null,
454
+ ENABLE_ELEMENT_PATCH: null,
455
+ ENABLE_NODE_LIST_PATCH: null,
456
+ ENABLE_HTML_COLLECTIONS_PATCH: null,
457
+ ENABLE_NODE_PATCH: null,
458
+ ENABLE_NON_COMPOSED_EVENTS_LEAKAGE: null,
459
+ ENABLE_MIXED_SHADOW_MODE: null,
460
+ ENABLE_WIRE_SYNC_EMIT: null
461
+ };
462
+
445
463
  if (!_globalThis.lwcRuntimeFlags) {
446
464
  Object.defineProperty(_globalThis, 'lwcRuntimeFlags', {
447
465
  value: create(null)
448
466
  });
449
467
  }
450
468
 
451
- var runtimeFlags = _globalThis.lwcRuntimeFlags; // This function is not supported for use within components and is meant for
452
- // configuring runtime feature flags during app initialization.
469
+ var runtimeFlags = _globalThis.lwcRuntimeFlags;
470
+ /**
471
+ * Set the value at runtime of a given feature flag. This method only be invoked once per feature
472
+ * flag. It is meant to be used during the app initialization.
473
+ */
453
474
 
454
475
  function setFeatureFlag(name, value) {
455
- var isBoolean = isTrue(value) || isFalse(value);
456
-
457
- if (!isBoolean) {
476
+ if (!isBoolean(value)) {
458
477
  var message = "Failed to set the value \"".concat(value, "\" for the runtime feature flag \"").concat(name, "\". Runtime feature flags can only be set to a boolean value.");
459
478
 
460
479
  {
@@ -464,9 +483,12 @@
464
483
  }
465
484
  }
466
485
 
467
- if (isUndefined$1(featureFlagLookup[name])) {
468
- // eslint-disable-next-line no-console
469
- console.warn("Failed to set the value \"".concat(value, "\" for the runtime feature flag \"").concat(name, "\" because it is undefined. Possible reasons are that 1) it was misspelled or 2) it was removed from the @lwc/features package."));
486
+ if (isUndefined$1(features[name])) {
487
+ var availableFlags = keys(features).map(function (name) {
488
+ return "\"".concat(name, "\"");
489
+ }).join(', '); // eslint-disable-next-line no-console
490
+
491
+ console.warn("Failed to set the value \"".concat(value, "\" for the runtime feature flag \"").concat(name, "\" because it is undefined. Available flags: ").concat(availableFlags, "."));
470
492
  return;
471
493
  }
472
494
 
@@ -480,34 +502,20 @@
480
502
  return;
481
503
  }
482
504
 
483
- Object.defineProperty(runtimeFlags, name, {
505
+ defineProperty(runtimeFlags, name, {
484
506
  value: value
485
507
  });
486
508
  }
487
- } // This function is exposed to components to facilitate testing so we add a
488
- // check to make sure it is not invoked in production.
509
+ }
510
+ /**
511
+ * Set the value at runtime of a given feature flag. This method should only be used for testing
512
+ * purposes. It is a no-op when invoked in production mode.
513
+ */
489
514
 
490
515
 
491
516
  function setFeatureFlagForTest(name, value) {
492
517
  }
493
-
494
- var featureFlagLookup = {
495
- ENABLE_REACTIVE_SETTER: null,
496
- ENABLE_HMR: null,
497
- // Flag to toggle on/off the enforcement of innerText/outerText shadow dom semantic in elements when using synthetic shadow.
498
- // Note: Once active, elements outside the lwc boundary are controlled by the ENABLE_ELEMENT_PATCH flag.
499
- ENABLE_INNER_OUTER_TEXT_PATCH: null,
500
- // Flags to toggle on/off the enforcement of shadow dom semantic in element/node outside lwc boundary when using synthetic shadow.
501
- ENABLE_ELEMENT_PATCH: null,
502
- ENABLE_NODE_LIST_PATCH: null,
503
- ENABLE_HTML_COLLECTIONS_PATCH: null,
504
- ENABLE_NODE_PATCH: null,
505
- // Disables the fix for #2121 where non-composed events are visible outside of their shadow root.
506
- ENABLE_NON_COMPOSED_EVENTS_LEAKAGE: null,
507
- ENABLE_LIGHT_DOM_COMPONENTS: null,
508
- ENABLE_MIXED_SHADOW_MODE: null
509
- };
510
- /** version: 2.3.3 */
518
+ /** version: 2.5.0 */
511
519
 
512
520
  /* proxy-compat-disable */
513
521
 
@@ -518,6 +526,7 @@
518
526
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
519
527
  */
520
528
 
529
+
521
530
  var nextTickCallbackQueue = [];
522
531
  var SPACE_CHAR = 32;
523
532
  var EmptyObject = seal(create(null));
@@ -2213,12 +2222,6 @@
2213
2222
  associateVM(component, vm);
2214
2223
  associateVM(elm, vm);
2215
2224
 
2216
- if (!runtimeFlags.ENABLE_LIGHT_DOM_COMPONENTS) {
2217
- assert.isTrue(def.renderMode !== 0
2218
- /* Light */
2219
- , "".concat(def.name || 'Anonymous class', " is an invalid LWC component. Light DOM components are not available in this environment."));
2220
- }
2221
-
2222
2225
  if (vm.renderMode === 1
2223
2226
  /* Shadow */
2224
2227
  ) {
@@ -2239,7 +2242,7 @@
2239
2242
  var cmpRoot = renderer.attachShadow(elm, (_renderer$attachShado = {}, _defineProperty(_renderer$attachShado, KEY__SYNTHETIC_MODE, shadowMode === 1), _defineProperty(_renderer$attachShado, "delegatesFocus", Boolean(ctor.delegatesFocus)), _defineProperty(_renderer$attachShado, "mode", mode), _renderer$attachShado));
2240
2243
  vm.cmpRoot = cmpRoot;
2241
2244
  associateVM(cmpRoot, vm);
2242
- } // @ts-ignore
2245
+ }
2243
2246
 
2244
2247
 
2245
2248
  LightningElement.prototype = {
@@ -3296,6 +3299,17 @@
3296
3299
 
3297
3300
  function setElementShadowToken(elm, token) {
3298
3301
  elm.$shadowToken$ = token;
3302
+ } // Set the scope token class for *.scoped.css styles
3303
+
3304
+
3305
+ function setScopeTokenClassIfNecessary(elm, owner) {
3306
+ var cmpTemplate = owner.cmpTemplate,
3307
+ context = owner.context;
3308
+ var token = cmpTemplate === null || cmpTemplate === void 0 ? void 0 : cmpTemplate.stylesheetToken;
3309
+
3310
+ if (!isUndefined$1(token) && context.hasScopedStyles) {
3311
+ owner.renderer.getClassList(elm).add(token);
3312
+ }
3299
3313
  }
3300
3314
 
3301
3315
  function updateNodeHook(oldVnode, vnode) {
@@ -3336,12 +3350,13 @@
3336
3350
 
3337
3351
  function fallbackElmHook(elm, vnode) {
3338
3352
  var owner = vnode.owner;
3353
+ setScopeTokenClassIfNecessary(elm, owner);
3339
3354
 
3340
3355
  if (owner.shadowMode === 1
3341
3356
  /* Synthetic */
3342
3357
  ) {
3343
3358
  var context = vnode.data.context;
3344
- var shadowAttribute = owner.context.shadowAttribute;
3359
+ var stylesheetToken = owner.context.stylesheetToken;
3345
3360
 
3346
3361
  if (!isUndefined$1(context) && !isUndefined$1(context.lwc) && context.lwc.dom === "manual"
3347
3362
  /* manual */
@@ -3352,7 +3367,7 @@
3352
3367
  // into each element from the template, so they can be styled accordingly.
3353
3368
 
3354
3369
 
3355
- setElementShadowToken(elm, shadowAttribute);
3370
+ setElementShadowToken(elm, stylesheetToken);
3356
3371
  }
3357
3372
  }
3358
3373
 
@@ -3417,14 +3432,15 @@
3417
3432
  mode = vnode.mode,
3418
3433
  ctor = vnode.ctor,
3419
3434
  owner = vnode.owner;
3435
+ setScopeTokenClassIfNecessary(elm, owner);
3420
3436
 
3421
3437
  if (owner.shadowMode === 1
3422
3438
  /* Synthetic */
3423
3439
  ) {
3424
- var shadowAttribute = owner.context.shadowAttribute; // when running in synthetic shadow mode, we need to set the shadowToken value
3440
+ var stylesheetToken = owner.context.stylesheetToken; // when running in synthetic shadow mode, we need to set the shadowToken value
3425
3441
  // into each element from the template, so they can be styled accordingly.
3426
3442
 
3427
- setElementShadowToken(elm, shadowAttribute);
3443
+ setElementShadowToken(elm, stylesheetToken);
3428
3444
  }
3429
3445
 
3430
3446
  var def = getComponentInternalDef(ctor);
@@ -3701,12 +3717,18 @@
3701
3717
  };
3702
3718
 
3703
3719
  function linkNodeToShadow(elm, owner) {
3704
- var shadowMode = owner.shadowMode; // TODO [#1164]: this should eventually be done by the polyfill directly
3720
+ var renderer = owner.renderer,
3721
+ renderMode = owner.renderMode,
3722
+ shadowMode = owner.shadowMode; // TODO [#1164]: this should eventually be done by the polyfill directly
3705
3723
 
3706
- if (shadowMode === 1
3707
- /* Synthetic */
3708
- ) {
3709
- elm[KEY__SHADOW_RESOLVER] = getRenderRoot(owner)[KEY__SHADOW_RESOLVER];
3724
+ if (renderer.isSyntheticShadowDefined) {
3725
+ if (shadowMode === 1
3726
+ /* Synthetic */
3727
+ || renderMode === 0
3728
+ /* Light */
3729
+ ) {
3730
+ elm[KEY__SHADOW_RESOLVER] = getRenderRoot(owner)[KEY__SHADOW_RESOLVER];
3731
+ }
3710
3732
  }
3711
3733
  }
3712
3734
 
@@ -3934,13 +3956,10 @@
3934
3956
  }
3935
3957
 
3936
3958
  var idx = vmBeingRendered.idx,
3937
- renderMode = vmBeingRendered.renderMode,
3938
3959
  shadowMode = vmBeingRendered.shadowMode;
3939
3960
 
3940
3961
  if (shadowMode === 1
3941
3962
  /* Synthetic */
3942
- && renderMode === 1
3943
- /* Shadow */
3944
3963
  ) {
3945
3964
  return StringReplace.call(id, /\S+/g, function (id) {
3946
3965
  return "".concat(id, "-").concat(idx);
@@ -3965,13 +3984,10 @@
3965
3984
  }
3966
3985
 
3967
3986
  var idx = vmBeingRendered.idx,
3968
- renderMode = vmBeingRendered.renderMode,
3969
3987
  shadowMode = vmBeingRendered.shadowMode; // Apply transformation only for fragment-only-urls, and only in shadow DOM
3970
3988
 
3971
3989
  if (shadowMode === 1
3972
3990
  /* Synthetic */
3973
- && renderMode === 1
3974
- /* Shadow */
3975
3991
  && /^#/.test(url)) {
3976
3992
  return "".concat(url, "-").concat(idx);
3977
3993
  }
@@ -4064,6 +4080,10 @@
4064
4080
  * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
4065
4081
  */
4066
4082
 
4083
+ function makeHostToken(token) {
4084
+ return "".concat(token, "-host");
4085
+ }
4086
+
4067
4087
  function createInlineStyleVNode(content) {
4068
4088
  return h('style', {
4069
4089
  key: 'style',
@@ -4073,49 +4093,86 @@
4073
4093
  }, [t(content)]);
4074
4094
  }
4075
4095
 
4076
- function updateSyntheticShadowAttributes(vm, template) {
4096
+ function updateStylesheetToken(vm, template) {
4077
4097
  var elm = vm.elm,
4078
4098
  context = vm.context,
4079
4099
  renderer = vm.renderer,
4080
- renderMode = vm.renderMode;
4100
+ renderMode = vm.renderMode,
4101
+ shadowMode = vm.shadowMode;
4081
4102
  var newStylesheets = template.stylesheets,
4082
- newStylesheetTokens = template.stylesheetTokens;
4083
- var newTokens; // Reset the styling token applied to the host element.
4103
+ newStylesheetToken = template.stylesheetToken;
4104
+ var isSyntheticShadow = renderMode === 1
4105
+ /* Shadow */
4106
+ && shadowMode === 1
4107
+ /* Synthetic */
4108
+ ;
4109
+ var hasScopedStyles = context.hasScopedStyles;
4110
+ var newToken;
4111
+ var newHasTokenInClass;
4112
+ var newHasTokenInAttribute; // Reset the styling token applied to the host element.
4113
+
4114
+ var oldToken = context.stylesheetToken,
4115
+ oldHasTokenInClass = context.hasTokenInClass,
4116
+ oldHasTokenInAttribute = context.hasTokenInAttribute;
4084
4117
 
4085
- var oldHostAttribute = context.hostAttribute;
4118
+ if (oldHasTokenInClass) {
4119
+ renderer.getClassList(elm).remove(makeHostToken(oldToken));
4120
+ }
4086
4121
 
4087
- if (!isUndefined$1(oldHostAttribute)) {
4088
- renderer.removeAttribute(elm, oldHostAttribute);
4122
+ if (oldHasTokenInAttribute) {
4123
+ renderer.removeAttribute(elm, makeHostToken(oldToken));
4089
4124
  } // Apply the new template styling token to the host element, if the new template has any
4090
- // associated stylesheets.
4125
+ // associated stylesheets. In the case of light DOM, also ensure there is at least one scoped stylesheet.
4091
4126
 
4092
4127
 
4093
- if (!isUndefined$1(newStylesheets) && newStylesheets.length !== 0 && renderMode === 1
4094
- /* Shadow */
4095
- ) {
4096
- newTokens = newStylesheetTokens;
4097
- }
4128
+ if (!isUndefined$1(newStylesheets) && newStylesheets.length !== 0) {
4129
+ newToken = newStylesheetToken;
4130
+ } // Set the new styling token on the host element
4098
4131
 
4099
- if (!isUndefined$1(newTokens)) {
4100
- renderer.setAttribute(elm, newTokens.hostAttribute, '');
4132
+
4133
+ if (!isUndefined$1(newToken)) {
4134
+ if (hasScopedStyles) {
4135
+ renderer.getClassList(elm).add(makeHostToken(newToken));
4136
+ newHasTokenInClass = true;
4137
+ }
4138
+
4139
+ if (isSyntheticShadow) {
4140
+ renderer.setAttribute(elm, makeHostToken(newToken), '');
4141
+ newHasTokenInAttribute = true;
4142
+ }
4101
4143
  } // Update the styling tokens present on the context object.
4102
4144
 
4103
4145
 
4104
- context.hostAttribute = newTokens === null || newTokens === void 0 ? void 0 : newTokens.hostAttribute;
4105
- context.shadowAttribute = newTokens === null || newTokens === void 0 ? void 0 : newTokens.shadowAttribute;
4146
+ context.stylesheetToken = newToken;
4147
+ context.hasTokenInClass = newHasTokenInClass;
4148
+ context.hasTokenInAttribute = newHasTokenInAttribute;
4106
4149
  }
4107
4150
 
4108
- function evaluateStylesheetsContent(stylesheets, hostSelector, shadowSelector, nativeShadow) {
4151
+ function evaluateStylesheetsContent(stylesheets, stylesheetToken, vm) {
4109
4152
  var content = [];
4110
4153
 
4111
4154
  for (var _i12 = 0; _i12 < stylesheets.length; _i12++) {
4112
4155
  var stylesheet = stylesheets[_i12];
4113
4156
 
4114
4157
  if (isArray$1(stylesheet)) {
4115
- ArrayPush$1.apply(content, evaluateStylesheetsContent(stylesheet, hostSelector, shadowSelector, nativeShadow));
4158
+ ArrayPush$1.apply(content, evaluateStylesheetsContent(stylesheet, stylesheetToken, vm));
4116
4159
  } else {
4117
-
4118
- ArrayPush$1.call(content, stylesheet(hostSelector, shadowSelector, nativeShadow));
4160
+ // native shadow DOM. Synthetic shadow DOM never uses `:host`.
4161
+
4162
+
4163
+ var isScopedCss = stylesheet[KEY__SCOPED_CSS];
4164
+ var useActualHostSelector = vm.renderMode === 0
4165
+ /* Light */
4166
+ ? !isScopedCss : vm.shadowMode === 0
4167
+ /* Native */
4168
+ ; // Apply the scope token only if the stylesheet itself is scoped, or if we're rendering synthetic shadow.
4169
+
4170
+ var scopeToken = isScopedCss || vm.shadowMode === 1
4171
+ /* Synthetic */
4172
+ && vm.renderMode === 1
4173
+ /* Shadow */
4174
+ ? stylesheetToken : undefined;
4175
+ ArrayPush$1.call(content, stylesheet(useActualHostSelector, scopeToken));
4119
4176
  }
4120
4177
  }
4121
4178
 
@@ -4124,34 +4181,35 @@
4124
4181
 
4125
4182
  function getStylesheetsContent(vm, template) {
4126
4183
  var stylesheets = template.stylesheets,
4127
- stylesheetTokens = template.stylesheetTokens;
4128
- var renderMode = vm.renderMode,
4129
- shadowMode = vm.shadowMode;
4184
+ stylesheetToken = template.stylesheetToken;
4130
4185
  var content = [];
4131
4186
 
4132
4187
  if (!isUndefined$1(stylesheets) && stylesheets.length !== 0) {
4133
- var hostSelector;
4134
- var shadowSelector; // Scoping with the tokens is only necessary for synthetic shadow. For both
4135
- // light DOM elements and native shadow, we just render the CSS as-is.
4188
+ content = evaluateStylesheetsContent(stylesheets, stylesheetToken, vm);
4189
+ }
4190
+
4191
+ return content;
4192
+ } // It might be worth caching this to avoid doing the lookup repeatedly, but
4193
+ // perf testing has not shown it to be a huge improvement yet:
4194
+ // https://github.com/salesforce/lwc/pull/2460#discussion_r691208892
4195
+
4196
+
4197
+ function getNearestNativeShadowComponent(vm) {
4198
+ var owner = vm;
4136
4199
 
4137
- if (renderMode === 1
4200
+ while (!isNull(owner)) {
4201
+ if (owner.renderMode === 1
4138
4202
  /* Shadow */
4139
- && shadowMode === 1
4140
- /* Synthetic */
4141
- && !isUndefined$1(stylesheetTokens)) {
4142
- hostSelector = "[".concat(stylesheetTokens.hostAttribute, "]");
4143
- shadowSelector = "[".concat(stylesheetTokens.shadowAttribute, "]");
4144
- } else {
4145
- hostSelector = '';
4146
- shadowSelector = '';
4203
+ && owner.shadowMode === 0
4204
+ /* Native */
4205
+ ) {
4206
+ return owner;
4147
4207
  }
4148
4208
 
4149
- content = evaluateStylesheetsContent(stylesheets, hostSelector, shadowSelector, shadowMode === 0
4150
- /* Native */
4151
- );
4209
+ owner = owner.owner;
4152
4210
  }
4153
4211
 
4154
- return content;
4212
+ return owner;
4155
4213
  }
4156
4214
 
4157
4215
  function createStylesheet(vm, stylesheets) {
@@ -4167,13 +4225,26 @@
4167
4225
  for (var _i13 = 0; _i13 < stylesheets.length; _i13++) {
4168
4226
  renderer.insertGlobalStylesheet(stylesheets[_i13]);
4169
4227
  }
4170
-
4171
- return null;
4172
- } else {
4173
- // native shadow or light DOM
4228
+ } else if (renderer.ssr) {
4229
+ // native shadow or light DOM, SSR
4174
4230
  var combinedStylesheetContent = ArrayJoin.call(stylesheets, '\n');
4175
4231
  return createInlineStyleVNode(combinedStylesheetContent);
4232
+ } else {
4233
+ // native shadow or light DOM, DOM renderer
4234
+ var root = getNearestNativeShadowComponent(vm);
4235
+ var isGlobal = isNull(root);
4236
+
4237
+ for (var _i14 = 0; _i14 < stylesheets.length; _i14++) {
4238
+ if (isGlobal) {
4239
+ renderer.insertGlobalStylesheet(stylesheets[_i14]);
4240
+ } else {
4241
+ // local level
4242
+ renderer.insertStylesheet(stylesheets[_i14], root.cmpRoot);
4243
+ }
4244
+ }
4176
4245
  }
4246
+
4247
+ return null;
4177
4248
  }
4178
4249
  /** Indicates if operations should be logged by the profiler. */
4179
4250
 
@@ -4290,8 +4361,7 @@
4290
4361
  context = vm.context,
4291
4362
  cmpSlots = vm.cmpSlots,
4292
4363
  cmpTemplate = vm.cmpTemplate,
4293
- tro = vm.tro,
4294
- shadowMode = vm.shadowMode;
4364
+ tro = vm.tro;
4295
4365
  tro.observe(function () {
4296
4366
  // Reset the cache memoizer for template when needed.
4297
4367
  if (html !== cmpTemplate) {
@@ -4313,15 +4383,12 @@
4313
4383
 
4314
4384
  vm.cmpTemplate = html; // Create a brand new template cache for the swapped templated.
4315
4385
 
4316
- context.tplCache = create(null); // Update the synthetic shadow attributes on the host element if necessary.
4386
+ context.tplCache = create(null); // Set the computeHasScopedStyles property in the context, to avoid recomputing it repeatedly.
4317
4387
 
4318
- if (shadowMode === 1
4319
- /* Synthetic */
4320
- ) {
4321
- updateSyntheticShadowAttributes(vm, html);
4322
- } // Evaluate, create stylesheet and cache the produced VNode for future
4323
- // re-rendering.
4388
+ context.hasScopedStyles = computeHasScopedStyles(html); // Update the scoping token on the host element.
4324
4389
 
4390
+ updateStylesheetToken(vm, html); // Evaluate, create stylesheet and cache the produced VNode for future
4391
+ // re-rendering.
4325
4392
 
4326
4393
  var stylesheetsContent = getStylesheetsContent(vm, html);
4327
4394
  context.styleVNode = stylesheetsContent.length === 0 ? null : createStylesheet(vm, stylesheetsContent);
@@ -4352,6 +4419,20 @@
4352
4419
 
4353
4420
  return vnodes;
4354
4421
  }
4422
+
4423
+ function computeHasScopedStyles(template) {
4424
+ var stylesheets = template.stylesheets;
4425
+
4426
+ if (!isUndefined$1(stylesheets)) {
4427
+ for (var _i15 = 0; _i15 < stylesheets.length; _i15++) {
4428
+ if (isTrue(stylesheets[_i15][KEY__SCOPED_CSS])) {
4429
+ return true;
4430
+ }
4431
+ }
4432
+ }
4433
+
4434
+ return false;
4435
+ }
4355
4436
  /*
4356
4437
  * Copyright (c) 2018, salesforce.com, inc.
4357
4438
  * All rights reserved.
@@ -4380,12 +4461,9 @@
4380
4461
  var component = vm.component,
4381
4462
  callHook = vm.callHook,
4382
4463
  owner = vm.owner;
4383
- var result;
4384
4464
  runWithBoundaryProtection(vm, owner, noop, function () {
4385
- // job
4386
- result = callHook(component, fn, args);
4465
+ callHook(component, fn, args);
4387
4466
  }, noop);
4388
- return result;
4389
4467
  }
4390
4468
 
4391
4469
  function invokeComponentConstructor(vm, Ctor) {
@@ -4450,29 +4528,6 @@
4450
4528
  return renderInvocationSuccessful ? evaluateTemplate(vm, html) : [];
4451
4529
  }
4452
4530
 
4453
- function invokeComponentRenderedCallback(vm) {
4454
- var renderedCallback = vm.def.renderedCallback,
4455
- component = vm.component,
4456
- callHook = vm.callHook,
4457
- owner = vm.owner;
4458
-
4459
- if (!isUndefined$1(renderedCallback)) {
4460
- runWithBoundaryProtection(vm, owner, function () {
4461
- logOperationStart(4
4462
- /* RenderedCallback */
4463
- , vm);
4464
- }, function () {
4465
- // job
4466
- callHook(component, renderedCallback);
4467
- }, function () {
4468
- // post
4469
- logOperationEnd(4
4470
- /* RenderedCallback */
4471
- , vm);
4472
- });
4473
- }
4474
- }
4475
-
4476
4531
  function invokeEventListener(vm, fn, thisValue, event) {
4477
4532
  var callHook = vm.callHook,
4478
4533
  owner = vm.owner;
@@ -4571,8 +4626,8 @@
4571
4626
 
4572
4627
  function register(service) {
4573
4628
 
4574
- for (var _i14 = 0; _i14 < hooks.length; ++_i14) {
4575
- var hookName = hooks[_i14];
4629
+ for (var _i16 = 0; _i16 < hooks.length; ++_i16) {
4630
+ var hookName = hooks[_i16];
4576
4631
 
4577
4632
  if (hookName in service) {
4578
4633
  var l = Services[hookName];
@@ -4592,8 +4647,8 @@
4592
4647
  def = vm.def,
4593
4648
  context = vm.context;
4594
4649
 
4595
- for (var _i15 = 0, _len6 = cbs.length; _i15 < _len6; ++_i15) {
4596
- cbs[_i15].call(undefined, component, {}, def, context);
4650
+ for (var _i17 = 0, _len6 = cbs.length; _i17 < _len6; ++_i17) {
4651
+ cbs[_i17].call(undefined, component, {}, def, context);
4597
4652
  }
4598
4653
  }
4599
4654
  /*
@@ -4604,7 +4659,6 @@
4604
4659
  */
4605
4660
 
4606
4661
 
4607
- var isNativeShadowRootDefined = _globalThis[KEY__IS_NATIVE_SHADOW_ROOT_DEFINED];
4608
4662
  var idx = 0;
4609
4663
  /** The internal slot used to associate different objects the engine manipulates with the VM */
4610
4664
 
@@ -4687,27 +4741,23 @@
4687
4741
  resetComponentStateWhenRemoved(vm);
4688
4742
  }
4689
4743
 
4744
+ function getNearestShadowAncestor(vm) {
4745
+ var ancestor = vm.owner;
4746
+
4747
+ while (!isNull(ancestor) && ancestor.renderMode === 0
4748
+ /* Light */
4749
+ ) {
4750
+ ancestor = ancestor.owner;
4751
+ }
4752
+
4753
+ return ancestor;
4754
+ }
4755
+
4690
4756
  function createVM(elm, def, options) {
4691
4757
  var mode = options.mode,
4692
4758
  owner = options.owner,
4693
4759
  renderer = options.renderer,
4694
4760
  tagName = options.tagName;
4695
- var shadowMode;
4696
-
4697
- if (renderer.syntheticShadow) {
4698
- shadowMode = def.shadowSupportMode === "any"
4699
- /* Any */
4700
- && isNativeShadowRootDefined ? 0
4701
- /* Native */
4702
- : 1
4703
- /* Synthetic */
4704
- ;
4705
- } else {
4706
- shadowMode = 0
4707
- /* Native */
4708
- ;
4709
- }
4710
-
4711
4761
  var vm = {
4712
4762
  elm: elm,
4713
4763
  def: def,
@@ -4730,10 +4780,12 @@
4730
4780
  oar: create(null),
4731
4781
  cmpTemplate: null,
4732
4782
  renderMode: def.renderMode,
4733
- shadowMode: shadowMode,
4783
+ shadowMode: null,
4734
4784
  context: {
4735
- hostAttribute: undefined,
4736
- shadowAttribute: undefined,
4785
+ stylesheetToken: undefined,
4786
+ hasTokenInClass: undefined,
4787
+ hasTokenInAttribute: undefined,
4788
+ hasScopedStyles: undefined,
4737
4789
  styleVNode: null,
4738
4790
  tplCache: EmptyObject,
4739
4791
  wiredConnecting: EmptyArray,
@@ -4746,18 +4798,77 @@
4746
4798
  setHook: setHook,
4747
4799
  getHook: getHook
4748
4800
  };
4801
+ vm.shadowMode = computeShadowMode(vm);
4749
4802
  vm.tro = getTemplateReactiveObserver(vm);
4750
4803
 
4751
4804
 
4752
4805
  invokeComponentConstructor(vm, def.ctor); // Initializing the wire decorator per instance only when really needed
4753
4806
 
4754
- if (isFalse(renderer.ssr) && hasWireAdapters(vm)) {
4807
+ if (hasWireAdapters(vm)) {
4755
4808
  installWireAdapters(vm);
4756
4809
  }
4757
4810
 
4758
4811
  return vm;
4759
4812
  }
4760
4813
 
4814
+ function computeShadowMode(vm) {
4815
+ var def = vm.def,
4816
+ renderer = vm.renderer;
4817
+ var isNativeShadowDefined = renderer.isNativeShadowDefined,
4818
+ isSyntheticShadowDefined = renderer.isSyntheticShadowDefined;
4819
+ var shadowMode;
4820
+
4821
+ if (isSyntheticShadowDefined) {
4822
+ if (def.renderMode === 0
4823
+ /* Light */
4824
+ ) {
4825
+ // ShadowMode.Native implies "not synthetic shadow" which is consistent with how
4826
+ // everything defaults to native when the synthetic shadow polyfill is unavailable.
4827
+ shadowMode = 0
4828
+ /* Native */
4829
+ ;
4830
+ } else if (isNativeShadowDefined) {
4831
+ if (def.shadowSupportMode === "any"
4832
+ /* Any */
4833
+ ) {
4834
+ shadowMode = 0
4835
+ /* Native */
4836
+ ;
4837
+ } else {
4838
+ var shadowAncestor = getNearestShadowAncestor(vm);
4839
+
4840
+ if (!isNull(shadowAncestor) && shadowAncestor.shadowMode === 0
4841
+ /* Native */
4842
+ ) {
4843
+ // Transitive support for native Shadow DOM. A component in native mode
4844
+ // transitively opts all of its descendants into native.
4845
+ shadowMode = 0
4846
+ /* Native */
4847
+ ;
4848
+ } else {
4849
+ // Synthetic if neither this component nor any of its ancestors are configured
4850
+ // to be native.
4851
+ shadowMode = 1
4852
+ /* Synthetic */
4853
+ ;
4854
+ }
4855
+ }
4856
+ } else {
4857
+ // Synthetic if there is no native Shadow DOM support.
4858
+ shadowMode = 1
4859
+ /* Synthetic */
4860
+ ;
4861
+ }
4862
+ } else {
4863
+ // Native if the synthetic shadow polyfill is unavailable.
4864
+ shadowMode = 0
4865
+ /* Native */
4866
+ ;
4867
+ }
4868
+
4869
+ return shadowMode;
4870
+ }
4871
+
4761
4872
  function associateVM(obj, vm) {
4762
4873
  ViewModelReflection.set(obj, vm);
4763
4874
  }
@@ -4821,7 +4932,10 @@
4821
4932
  }
4822
4933
 
4823
4934
  function runRenderedCallback(vm) {
4824
- if (isTrue(vm.renderer.ssr)) {
4935
+ var renderer = vm.renderer,
4936
+ renderedCallback = vm.def.renderedCallback;
4937
+
4938
+ if (isTrue(renderer.ssr)) {
4825
4939
  return;
4826
4940
  }
4827
4941
 
@@ -4831,7 +4945,15 @@
4831
4945
  invokeServiceHook(vm, rendered);
4832
4946
  }
4833
4947
 
4834
- invokeComponentRenderedCallback(vm);
4948
+ if (!isUndefined$1(renderedCallback)) {
4949
+ logOperationStart(4
4950
+ /* RenderedCallback */
4951
+ , vm);
4952
+ invokeComponentCallback(vm, renderedCallback);
4953
+ logOperationEnd(4
4954
+ /* RenderedCallback */
4955
+ , vm);
4956
+ }
4835
4957
  }
4836
4958
 
4837
4959
  var rehydrateQueue = [];
@@ -4846,19 +4968,19 @@
4846
4968
  });
4847
4969
  rehydrateQueue = []; // reset to a new queue
4848
4970
 
4849
- for (var _i16 = 0, _len7 = vms.length; _i16 < _len7; _i16 += 1) {
4850
- var vm = vms[_i16];
4971
+ for (var _i18 = 0, _len7 = vms.length; _i18 < _len7; _i18 += 1) {
4972
+ var vm = vms[_i18];
4851
4973
 
4852
4974
  try {
4853
4975
  rehydrate(vm);
4854
4976
  } catch (error) {
4855
- if (_i16 + 1 < _len7) {
4977
+ if (_i18 + 1 < _len7) {
4856
4978
  // pieces of the queue are still pending to be rehydrated, those should have priority
4857
4979
  if (rehydrateQueue.length === 0) {
4858
4980
  addCallbackToNextTick(flushRehydrationQueue);
4859
4981
  }
4860
4982
 
4861
- ArrayUnshift.apply(rehydrateQueue, ArraySlice.call(vms, _i16 + 1));
4983
+ ArrayUnshift.apply(rehydrateQueue, ArraySlice.call(vms, _i18 + 1));
4862
4984
  } // we need to end the measure before throwing.
4863
4985
 
4864
4986
 
@@ -4957,8 +5079,8 @@
4957
5079
  var vCustomElementCollection = vm.velements; // Reporting disconnection for every child in inverse order since they are
4958
5080
  // inserted in reserved order.
4959
5081
 
4960
- for (var _i17 = vCustomElementCollection.length - 1; _i17 >= 0; _i17 -= 1) {
4961
- var elm = vCustomElementCollection[_i17].elm; // There are two cases where the element could be undefined:
5082
+ for (var _i19 = vCustomElementCollection.length - 1; _i19 >= 0; _i19 -= 1) {
5083
+ var elm = vCustomElementCollection[_i19].elm; // There are two cases where the element could be undefined:
4962
5084
  // * when there is an error during the construction phase, and an error
4963
5085
  // boundary picks it, there is a possibility that the VCustomElement
4964
5086
  // is not properly initialized, and therefore is should be ignored.
@@ -4992,8 +5114,8 @@
4992
5114
 
4993
5115
 
4994
5116
  function recursivelyDisconnectChildren(vnodes) {
4995
- for (var _i18 = 0, _len8 = vnodes.length; _i18 < _len8; _i18 += 1) {
4996
- var vnode = vnodes[_i18];
5117
+ for (var _i20 = 0, _len8 = vnodes.length; _i20 < _len8; _i20 += 1) {
5118
+ var vnode = vnodes[_i20];
4997
5119
 
4998
5120
  if (!isNull(vnode) && isArray$1(vnode.children) && !isUndefined$1(vnode.elm)) {
4999
5121
  // vnode is a VElement with children
@@ -5017,8 +5139,8 @@
5017
5139
  renderer = vm.renderer;
5018
5140
  var rootNode = getRenderRoot(vm);
5019
5141
 
5020
- for (var _i19 = 0, _len9 = children.length; _i19 < _len9; _i19++) {
5021
- var child = children[_i19];
5142
+ for (var _i21 = 0, _len9 = children.length; _i21 < _len9; _i21++) {
5143
+ var child = children[_i21];
5022
5144
 
5023
5145
  if (!isNull(child) && !isUndefined$1(child.elm)) {
5024
5146
  renderer.remove(child.elm, rootNode);
@@ -5063,8 +5185,8 @@
5063
5185
  var oldSlots = vm.cmpSlots;
5064
5186
  var cmpSlots = vm.cmpSlots = create(null);
5065
5187
 
5066
- for (var _i20 = 0, _len10 = children.length; _i20 < _len10; _i20 += 1) {
5067
- var vnode = children[_i20];
5188
+ for (var _i22 = 0, _len10 = children.length; _i22 < _len10; _i22 += 1) {
5189
+ var vnode = children[_i22];
5068
5190
 
5069
5191
  if (isNull(vnode)) {
5070
5192
  continue;
@@ -5094,8 +5216,8 @@
5094
5216
  return;
5095
5217
  }
5096
5218
 
5097
- for (var _i21 = 0, _len11 = oldKeys.length; _i21 < _len11; _i21 += 1) {
5098
- var key = oldKeys[_i21];
5219
+ for (var _i23 = 0, _len11 = oldKeys.length; _i23 < _len11; _i23 += 1) {
5220
+ var key = oldKeys[_i23];
5099
5221
 
5100
5222
  if (isUndefined$1(cmpSlots[key]) || oldSlots[key].length !== cmpSlots[key].length) {
5101
5223
  markComponentAsDirty(vm);
@@ -5413,11 +5535,14 @@
5413
5535
  ArrayPush$1.call(wiredConnecting, function () {
5414
5536
  connector.connect();
5415
5537
 
5416
- if (hasDynamicParams) {
5417
- Promise.resolve().then(computeConfigAndUpdate);
5418
- } else {
5419
- computeConfigAndUpdate();
5538
+ if (!runtimeFlags.ENABLE_WIRE_SYNC_EMIT) {
5539
+ if (hasDynamicParams) {
5540
+ Promise.resolve().then(computeConfigAndUpdate);
5541
+ return;
5542
+ }
5420
5543
  }
5544
+
5545
+ computeConfigAndUpdate();
5421
5546
  });
5422
5547
  ArrayPush$1.call(wiredDisconnecting, function () {
5423
5548
  connector.disconnect();
@@ -5431,8 +5556,8 @@
5431
5556
  function connectWireAdapters(vm) {
5432
5557
  var wiredConnecting = vm.context.wiredConnecting;
5433
5558
 
5434
- for (var _i22 = 0, _len12 = wiredConnecting.length; _i22 < _len12; _i22 += 1) {
5435
- wiredConnecting[_i22]();
5559
+ for (var _i24 = 0, _len12 = wiredConnecting.length; _i24 < _len12; _i24 += 1) {
5560
+ wiredConnecting[_i24]();
5436
5561
  }
5437
5562
  }
5438
5563
 
@@ -5440,8 +5565,8 @@
5440
5565
  var wiredDisconnecting = vm.context.wiredDisconnecting;
5441
5566
  runWithBoundaryProtection(vm, vm, noop, function () {
5442
5567
  // job
5443
- for (var _i23 = 0, _len13 = wiredDisconnecting.length; _i23 < _len13; _i23 += 1) {
5444
- wiredDisconnecting[_i23]();
5568
+ for (var _i25 = 0, _len13 = wiredDisconnecting.length; _i25 < _len13; _i25 += 1) {
5569
+ wiredDisconnecting[_i25]();
5445
5570
  }
5446
5571
  }, noop);
5447
5572
  }
@@ -5510,7 +5635,7 @@
5510
5635
 
5511
5636
  return reactiveMembrane.getReadOnlyProxy(obj);
5512
5637
  }
5513
- /* version: 2.3.3 */
5638
+ /* version: 2.5.0 */
5514
5639
 
5515
5640
  /*
5516
5641
  * Copyright (c) 2018, salesforce.com, inc.
@@ -5523,6 +5648,10 @@
5523
5648
  var globalStylesheets = create(null);
5524
5649
 
5525
5650
  var globalStylesheetsParentElement = document.head || document.body || document;
5651
+ var supportsConstructableStyleSheets = isFunction$1(CSSStyleSheet.prototype.replaceSync);
5652
+ var styleElements = create(null);
5653
+ var styleSheets = create(null);
5654
+ var nodesToStyleSheets = new WeakMap();
5526
5655
  var getCustomElement, defineCustomElement, HTMLElementConstructor;
5527
5656
 
5528
5657
  function isCustomElementRegistryAvailable() {
@@ -5561,6 +5690,52 @@
5561
5690
  }
5562
5691
  }
5563
5692
 
5693
+ function insertConstructableStyleSheet(content, target) {
5694
+ // It's important for CSSStyleSheets to be unique based on their content, so that
5695
+ // `shadowRoot.adoptedStyleSheets.includes(sheet)` works.
5696
+ var styleSheet = styleSheets[content];
5697
+
5698
+ if (isUndefined$1(styleSheet)) {
5699
+ styleSheet = new CSSStyleSheet();
5700
+ styleSheet.replaceSync(content);
5701
+ styleSheets[content] = styleSheet;
5702
+ }
5703
+
5704
+ if (!target.adoptedStyleSheets.includes(styleSheet)) {
5705
+ target.adoptedStyleSheets = [].concat(_toConsumableArray(target.adoptedStyleSheets), [styleSheet]);
5706
+ }
5707
+ }
5708
+
5709
+ function insertStyleElement(content, target) {
5710
+ // Avoid inserting duplicate `<style>`s
5711
+ var sheets = nodesToStyleSheets.get(target);
5712
+
5713
+ if (isUndefined$1(sheets)) {
5714
+ sheets = create(null);
5715
+ nodesToStyleSheets.set(target, sheets);
5716
+ }
5717
+
5718
+ if (sheets[content]) {
5719
+ return;
5720
+ }
5721
+
5722
+ sheets[content] = true; // This `<style>` may be repeated multiple times in the DOM, so cache it. It's a bit
5723
+ // faster to call `cloneNode()` on an existing node than to recreate it every time.
5724
+
5725
+ var elm = styleElements[content];
5726
+
5727
+ if (isUndefined$1(elm)) {
5728
+ elm = document.createElement('style');
5729
+ elm.type = 'text/css';
5730
+ elm.textContent = content;
5731
+ styleElements[content] = elm;
5732
+ } else {
5733
+ elm = elm.cloneNode(true);
5734
+ }
5735
+
5736
+ target.appendChild(elm);
5737
+ }
5738
+
5564
5739
  if (isCustomElementRegistryAvailable()) {
5565
5740
  getCustomElement = customElements.get.bind(customElements);
5566
5741
  defineCustomElement = customElements.define.bind(customElements);
@@ -5604,7 +5779,8 @@
5604
5779
 
5605
5780
  var renderer = {
5606
5781
  ssr: false,
5607
- syntheticShadow: hasOwnProperty$1.call(Element.prototype, KEY__SHADOW_TOKEN),
5782
+ isNativeShadowDefined: _globalThis[KEY__IS_NATIVE_SHADOW_ROOT_DEFINED],
5783
+ isSyntheticShadowDefined: hasOwnProperty$1.call(Element.prototype, KEY__SHADOW_TOKEN),
5608
5784
  createElement: function createElement(tagName, namespace) {
5609
5785
  return isUndefined$1(namespace) ? document.createElement(tagName) : document.createElementNS(namespace, tagName);
5610
5786
  },
@@ -5695,6 +5871,14 @@
5695
5871
  elm.textContent = content;
5696
5872
  globalStylesheetsParentElement.appendChild(elm);
5697
5873
  },
5874
+ insertStylesheet: function insertStylesheet(content, target) {
5875
+ if (supportsConstructableStyleSheets) {
5876
+ insertConstructableStyleSheet(content, target);
5877
+ } else {
5878
+ // Fall back to <style> element
5879
+ insertStyleElement(content, target);
5880
+ }
5881
+ },
5698
5882
  assertInstanceOfHTMLElement: function assertInstanceOfHTMLElement(elm, msg) {
5699
5883
  assert.invariant(elm instanceof HTMLElement, msg);
5700
5884
  },
@@ -5929,7 +6113,7 @@
5929
6113
  return false;
5930
6114
  }
5931
6115
 
5932
- if (renderer.syntheticShadow) {
6116
+ if (renderer.isSyntheticShadowDefined) {
5933
6117
  // TODO [#1252]: old behavior that is still used by some pieces of the platform,
5934
6118
  // specifically, nodes inserted manually on places where `lwc:dom="manual"` directive is not
5935
6119
  // used, will be considered global elements.
@@ -5981,7 +6165,7 @@
5981
6165
  });
5982
6166
  freeze(LightningElement);
5983
6167
  seal(LightningElement.prototype);
5984
- /* version: 2.3.3 */
6168
+ /* version: 2.5.0 */
5985
6169
 
5986
6170
  exports.LightningElement = LightningElement;
5987
6171
  exports.__unstable__ProfilerControl = profilerControl;