lwc 2.41.3 → 2.43.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.
- package/dist/engine-dom/esm/es2017/engine-dom.js +41 -24
- package/dist/engine-dom/esm/es2017/engine-dom.js.map +1 -1
- package/dist/engine-dom/iife/es2017/engine-dom.js +41 -23
- package/dist/engine-dom/iife/es2017/engine-dom.js.map +1 -1
- package/dist/engine-dom/iife/es2017/engine-dom.min.js +1 -1
- package/dist/engine-dom/iife/es2017/engine-dom_debug.js +32 -16
- package/dist/engine-dom/iife/es2017/engine-dom_debug.js.map +1 -1
- package/dist/engine-dom/iife/es5/engine-dom.js +42 -24
- package/dist/engine-dom/iife/es5/engine-dom.js.map +1 -1
- package/dist/engine-dom/iife/es5/engine-dom.min.js +1 -1
- package/dist/engine-dom/iife/es5/engine-dom_debug.js +34 -18
- package/dist/engine-dom/iife/es5/engine-dom_debug.js.map +1 -1
- package/dist/engine-dom/umd/es2017/engine-dom.js +41 -23
- package/dist/engine-dom/umd/es2017/engine-dom.js.map +1 -1
- package/dist/engine-dom/umd/es2017/engine-dom.min.js +1 -1
- package/dist/engine-dom/umd/es2017/engine-dom_debug.js +32 -16
- package/dist/engine-dom/umd/es2017/engine-dom_debug.js.map +1 -1
- package/dist/engine-dom/umd/es5/engine-dom.js +42 -24
- package/dist/engine-dom/umd/es5/engine-dom.js.map +1 -1
- package/dist/engine-dom/umd/es5/engine-dom.min.js +1 -1
- package/dist/engine-dom/umd/es5/engine-dom_debug.js +34 -18
- package/dist/engine-dom/umd/es5/engine-dom_debug.js.map +1 -1
- package/dist/engine-server/commonjs/es2017/engine-server.js +37 -14
- package/dist/engine-server/commonjs/es2017/engine-server.js.map +1 -1
- package/dist/engine-server/commonjs/es2017/engine-server.min.js +1 -1
- package/dist/engine-server/esm/es2017/engine-server.js +37 -15
- package/dist/engine-server/esm/es2017/engine-server.js.map +1 -1
- package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js +3 -3
- package/dist/synthetic-shadow/esm/es2017/synthetic-shadow.js.map +1 -1
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js +3 -3
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow.js.map +1 -1
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js +3 -3
- package/dist/synthetic-shadow/iife/es2017/synthetic-shadow_debug.js.map +1 -1
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js +3 -3
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow.js.map +1 -1
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js +3 -3
- package/dist/synthetic-shadow/iife/es5/synthetic-shadow_debug.js.map +1 -1
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js +3 -3
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow.js.map +1 -1
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js +3 -3
- package/dist/synthetic-shadow/umd/es2017/synthetic-shadow_debug.js.map +1 -1
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js +3 -3
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow.js.map +1 -1
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js +3 -3
- package/dist/synthetic-shadow/umd/es5/synthetic-shadow_debug.js.map +1 -1
- package/dist/wire-service/esm/es2017/wire-service.js +2 -2
- package/dist/wire-service/esm/es2017/wire-service.js.map +1 -1
- package/dist/wire-service/iife/es2017/wire-service.js +2 -2
- package/dist/wire-service/iife/es2017/wire-service.js.map +1 -1
- package/dist/wire-service/iife/es2017/wire-service_debug.js +2 -2
- package/dist/wire-service/iife/es2017/wire-service_debug.js.map +1 -1
- package/dist/wire-service/iife/es5/wire-service.js +2 -2
- package/dist/wire-service/iife/es5/wire-service.js.map +1 -1
- package/dist/wire-service/iife/es5/wire-service_debug.js +2 -2
- package/dist/wire-service/iife/es5/wire-service_debug.js.map +1 -1
- package/dist/wire-service/umd/es2017/wire-service.js +2 -2
- package/dist/wire-service/umd/es2017/wire-service.js.map +1 -1
- package/dist/wire-service/umd/es2017/wire-service_debug.js +2 -2
- package/dist/wire-service/umd/es2017/wire-service_debug.js.map +1 -1
- package/dist/wire-service/umd/es5/wire-service.js +2 -2
- package/dist/wire-service/umd/es5/wire-service.js.map +1 -1
- package/dist/wire-service/umd/es5/wire-service_debug.js +2 -2
- package/dist/wire-service/umd/es5/wire-service_debug.js.map +1 -1
- package/package.json +7 -7
|
@@ -444,9 +444,9 @@ function htmlEscape(str, attrMode = false) {
|
|
|
444
444
|
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
|
445
445
|
*/
|
|
446
446
|
// Increment whenever the LWC template compiler changes
|
|
447
|
-
const LWC_VERSION = "2.
|
|
447
|
+
const LWC_VERSION = "2.43.0";
|
|
448
448
|
const LWC_VERSION_COMMENT_REGEX = /\/\*LWC compiler v([\d.]+)\*\/\s*}/;
|
|
449
|
-
/** version: 2.
|
|
449
|
+
/** version: 2.43.0 */
|
|
450
450
|
|
|
451
451
|
/**
|
|
452
452
|
* Copyright (C) 2018 salesforce.com, inc.
|
|
@@ -524,7 +524,7 @@ function setFeatureFlagForTest(name, value) {
|
|
|
524
524
|
setFeatureFlag(name, value);
|
|
525
525
|
}
|
|
526
526
|
}
|
|
527
|
-
/** version: 2.
|
|
527
|
+
/** version: 2.43.0 */
|
|
528
528
|
|
|
529
529
|
/*
|
|
530
530
|
* Copyright (c) 2020, salesforce.com, inc.
|
|
@@ -620,9 +620,16 @@ function applyAriaReflection(prototype = Element.prototype) {
|
|
|
620
620
|
}
|
|
621
621
|
}
|
|
622
622
|
}
|
|
623
|
-
/** version: 2.
|
|
623
|
+
/** version: 2.43.0 */
|
|
624
624
|
|
|
625
625
|
/* proxy-compat-disable */
|
|
626
|
+
/**
|
|
627
|
+
* Report to the current dispatcher, if there is one.
|
|
628
|
+
* @param reportingEventId
|
|
629
|
+
* @param payload - data to report
|
|
630
|
+
*/
|
|
631
|
+
function report(reportingEventId, payload) {
|
|
632
|
+
}
|
|
626
633
|
|
|
627
634
|
/*
|
|
628
635
|
* Copyright (c) 2018, salesforce.com, inc.
|
|
@@ -3534,6 +3541,15 @@ function evaluateStylesheetsContent(stylesheets, stylesheetToken, vm) {
|
|
|
3534
3541
|
// the stylesheet, while internally, we have a replacement for it.
|
|
3535
3542
|
stylesheet = getStyleOrSwappedStyle(stylesheet);
|
|
3536
3543
|
}
|
|
3544
|
+
// Check that this stylesheet was generated by our compiler
|
|
3545
|
+
if (!isStylesheetRegistered(stylesheet)) {
|
|
3546
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
3547
|
+
logWarnOnce(`TypeError: Unexpected LWC stylesheet content found for component <${vm.tagName.toLowerCase()}>.`);
|
|
3548
|
+
}
|
|
3549
|
+
report("UnexpectedStylesheetContent" /* ReportingEventId.UnexpectedStylesheetContent */, {
|
|
3550
|
+
tagName: vm.tagName.toLowerCase(),
|
|
3551
|
+
});
|
|
3552
|
+
}
|
|
3537
3553
|
const isScopedCss = stylesheet[KEY__SCOPED_CSS];
|
|
3538
3554
|
if (lwcRuntimeFlags.DISABLE_LIGHT_DOM_UNSCOPED_CSS &&
|
|
3539
3555
|
!isScopedCss &&
|
|
@@ -3622,6 +3638,18 @@ function createStylesheet(vm, stylesheets) {
|
|
|
3622
3638
|
}
|
|
3623
3639
|
return null;
|
|
3624
3640
|
}
|
|
3641
|
+
const signedStylesheetSet = new Set();
|
|
3642
|
+
/**
|
|
3643
|
+
* INTERNAL: This function can only be invoked by compiled code. The compiler
|
|
3644
|
+
* will prevent this function from being imported by userland code.
|
|
3645
|
+
*/
|
|
3646
|
+
function registerStylesheet(stylesheet) {
|
|
3647
|
+
signedStylesheetSet.add(stylesheet);
|
|
3648
|
+
return stylesheet;
|
|
3649
|
+
}
|
|
3650
|
+
function isStylesheetRegistered(stylesheet) {
|
|
3651
|
+
return signedStylesheetSet.has(stylesheet);
|
|
3652
|
+
}
|
|
3625
3653
|
|
|
3626
3654
|
/*
|
|
3627
3655
|
* Copyright (c) 2018, salesforce.com, inc.
|
|
@@ -5279,18 +5307,12 @@ function getVMBeingRendered() {
|
|
|
5279
5307
|
function setVMBeingRendered(vm) {
|
|
5280
5308
|
vmBeingRendered = vm;
|
|
5281
5309
|
}
|
|
5282
|
-
function validateSlots(vm
|
|
5310
|
+
function validateSlots(vm) {
|
|
5283
5311
|
assertNotProd(); // this method should never leak to prod
|
|
5284
5312
|
const { cmpSlots } = vm;
|
|
5285
|
-
const { slots = EmptyArray } = html;
|
|
5286
5313
|
for (const slotName in cmpSlots.slotAssignments) {
|
|
5287
5314
|
// eslint-disable-next-line @lwc/lwc-internal/no-production-assert
|
|
5288
5315
|
assert.isTrue(isArray$1(cmpSlots.slotAssignments[slotName]), `Slots can only be set to an array, instead received ${toString$1(cmpSlots.slotAssignments[slotName])} for slot "${slotName}" in ${vm}.`);
|
|
5289
|
-
if (slotName !== '' && ArrayIndexOf.call(slots, slotName) === -1) {
|
|
5290
|
-
// TODO [#1297]: this should never really happen because the compiler should always validate
|
|
5291
|
-
// eslint-disable-next-line @lwc/lwc-internal/no-production-assert
|
|
5292
|
-
logError(`Ignoring unknown provided slot name "${slotName}" in ${vm}. Check for a typo on the slot attribute.`, vm);
|
|
5293
|
-
}
|
|
5294
5316
|
}
|
|
5295
5317
|
}
|
|
5296
5318
|
function validateLightDomTemplate(template, vm) {
|
|
@@ -5404,7 +5426,7 @@ function evaluateTemplate(vm, html) {
|
|
|
5404
5426
|
}
|
|
5405
5427
|
if (process.env.NODE_ENV !== 'production') {
|
|
5406
5428
|
// validating slots in every rendering since the allocated content might change over time
|
|
5407
|
-
validateSlots(vm
|
|
5429
|
+
validateSlots(vm);
|
|
5408
5430
|
// add the VM to the list of host VMs that can be re-rendered if html is swapped
|
|
5409
5431
|
setActiveVM(vm);
|
|
5410
5432
|
}
|
|
@@ -6345,7 +6367,7 @@ function readonly(obj) {
|
|
|
6345
6367
|
}
|
|
6346
6368
|
return getReadOnlyProxy(obj);
|
|
6347
6369
|
}
|
|
6348
|
-
/* version: 2.
|
|
6370
|
+
/* version: 2.43.0 */
|
|
6349
6371
|
|
|
6350
6372
|
/*
|
|
6351
6373
|
* Copyright (c) 2020, salesforce.com, inc.
|
|
@@ -6880,7 +6902,7 @@ seal(LightningElement.prototype);
|
|
|
6880
6902
|
function createElement() {
|
|
6881
6903
|
throw new Error('createElement is not supported in @lwc/engine-server, only @lwc/engine-dom.');
|
|
6882
6904
|
}
|
|
6883
|
-
/* version: 2.
|
|
6905
|
+
/* version: 2.43.0 */
|
|
6884
6906
|
|
|
6885
6907
|
exports.LightningElement = LightningElement;
|
|
6886
6908
|
exports.api = api$1;
|
|
@@ -6895,6 +6917,7 @@ exports.readonly = readonly;
|
|
|
6895
6917
|
exports.register = register;
|
|
6896
6918
|
exports.registerComponent = registerComponent;
|
|
6897
6919
|
exports.registerDecorators = registerDecorators;
|
|
6920
|
+
exports.registerStylesheet = registerStylesheet;
|
|
6898
6921
|
exports.registerTemplate = registerTemplate;
|
|
6899
6922
|
exports.renderComponent = renderComponent;
|
|
6900
6923
|
exports.renderer = renderer;
|