@lwc/synthetic-shadow 6.0.0 → 6.1.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/index.cjs.js +12 -25
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +12 -25
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/**
|
2
|
-
* Copyright (
|
2
|
+
* Copyright (c) 2024 Salesforce, Inc.
|
3
3
|
*/
|
4
4
|
if (!globalThis.lwcRuntimeFlags) {
|
5
5
|
Object.defineProperty(globalThis, 'lwcRuntimeFlags', { value: Object.create(null) });
|
@@ -8,7 +8,7 @@ if (!lwcRuntimeFlags.ENABLE_FORCE_SHADOW_MIGRATE_MODE) {
|
|
8
8
|
'use strict';
|
9
9
|
|
10
10
|
/**
|
11
|
-
* Copyright (
|
11
|
+
* Copyright (c) 2024 Salesforce, Inc.
|
12
12
|
*/
|
13
13
|
/*
|
14
14
|
* Copyright (c) 2018, salesforce.com, inc.
|
@@ -89,18 +89,6 @@ function toString(obj) {
|
|
89
89
|
}
|
90
90
|
}
|
91
91
|
|
92
|
-
/*
|
93
|
-
* Copyright (c) 2018, salesforce.com, inc.
|
94
|
-
* All rights reserved.
|
95
|
-
* SPDX-License-Identifier: MIT
|
96
|
-
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
97
|
-
*/
|
98
|
-
// See browser support for globalThis:
|
99
|
-
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/globalThis#browser_compatibility
|
100
|
-
/* istanbul ignore next */
|
101
|
-
// @ts-ignore
|
102
|
-
const _globalThis = typeof globalThis === 'object' ? globalThis : window;
|
103
|
-
|
104
92
|
/*
|
105
93
|
* Copyright (c) 2023, Salesforce.com, inc.
|
106
94
|
* All rights reserved.
|
@@ -119,16 +107,15 @@ const KEY__LEGACY_SHADOW_TOKEN_PRIVATE = '$$LegacyShadowTokenKey$$';
|
|
119
107
|
const KEY__SYNTHETIC_MODE = '$$lwc-synthetic-mode';
|
120
108
|
const KEY__NATIVE_GET_ELEMENT_BY_ID = '$nativeGetElementById$';
|
121
109
|
const KEY__NATIVE_QUERY_SELECTOR_ALL = '$nativeQuerySelectorAll$';
|
122
|
-
/** version: 6.
|
110
|
+
/** version: 6.1.0 */
|
123
111
|
|
124
112
|
/**
|
125
|
-
* Copyright (
|
113
|
+
* Copyright (c) 2024 Salesforce, Inc.
|
126
114
|
*/
|
127
|
-
|
128
|
-
|
129
|
-
Object.defineProperty(_globalThis, 'lwcRuntimeFlags', { value: create(null) });
|
115
|
+
if (!globalThis.lwcRuntimeFlags) {
|
116
|
+
Object.defineProperty(globalThis, 'lwcRuntimeFlags', { value: create(null) });
|
130
117
|
}
|
131
|
-
/** version: 6.
|
118
|
+
/** version: 6.1.0 */
|
132
119
|
|
133
120
|
/*
|
134
121
|
* Copyright (c) 2018, salesforce.com, inc.
|
@@ -1702,15 +1689,15 @@ defineProperty(_Node.prototype, KEY__SHADOW_RESOLVER, {
|
|
1702
1689
|
});
|
1703
1690
|
// The isUndefined check is because two copies of synthetic shadow may be loaded on the same page, and this
|
1704
1691
|
// would throw an error if we tried to redefine it. Plus the whole point is to expose the native method.
|
1705
|
-
if (isUndefined(
|
1706
|
-
defineProperty(
|
1692
|
+
if (isUndefined(globalThis[KEY__NATIVE_GET_ELEMENT_BY_ID])) {
|
1693
|
+
defineProperty(globalThis, KEY__NATIVE_GET_ELEMENT_BY_ID, {
|
1707
1694
|
value: getElementById,
|
1708
1695
|
configurable: true,
|
1709
1696
|
});
|
1710
1697
|
}
|
1711
1698
|
// See note above.
|
1712
|
-
if (isUndefined(
|
1713
|
-
defineProperty(
|
1699
|
+
if (isUndefined(globalThis[KEY__NATIVE_QUERY_SELECTOR_ALL])) {
|
1700
|
+
defineProperty(globalThis, KEY__NATIVE_QUERY_SELECTOR_ALL, {
|
1714
1701
|
value: querySelectorAll,
|
1715
1702
|
configurable: true,
|
1716
1703
|
});
|
@@ -4264,6 +4251,6 @@ defineProperty(Element.prototype, '$domManual$', {
|
|
4264
4251
|
},
|
4265
4252
|
configurable: true,
|
4266
4253
|
});
|
4267
|
-
/** version: 6.
|
4254
|
+
/** version: 6.1.0 */
|
4268
4255
|
}
|
4269
4256
|
//# sourceMappingURL=index.cjs.js.map
|