ember-source 4.8.0 → 4.8.2
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/CHANGELOG.md +8 -0
- package/build-metadata.json +3 -3
- package/dist/ember-template-compiler.js +2 -2
- package/dist/ember-template-compiler.map +1 -1
- package/dist/ember-testing.js +1 -1
- package/dist/ember-testing.map +1 -1
- package/dist/ember.debug.js +8 -4
- package/dist/ember.debug.map +1 -1
- package/dist/header/license.js +1 -1
- package/dist/packages/@ember/-internals/metal/index.js +6 -2
- package/dist/packages/ember/version.js +1 -1
- package/docs/data.json +1 -1
- package/package.json +2 -2
- package/types/preview/@ember/component/index.d.ts +9 -0
package/dist/header/license.js
CHANGED
|
@@ -1824,7 +1824,7 @@ function _getProp(obj, keyName) {
|
|
|
1824
1824
|
|
|
1825
1825
|
return value;
|
|
1826
1826
|
}
|
|
1827
|
-
function _getPath(obj, path) {
|
|
1827
|
+
function _getPath(obj, path, forSet) {
|
|
1828
1828
|
let parts = typeof path === 'string' ? path.split('.') : path;
|
|
1829
1829
|
|
|
1830
1830
|
for (let part of parts) {
|
|
@@ -1832,6 +1832,10 @@ function _getPath(obj, path) {
|
|
|
1832
1832
|
return undefined;
|
|
1833
1833
|
}
|
|
1834
1834
|
|
|
1835
|
+
if (forSet && (part === '__proto__' || part === 'constructor')) {
|
|
1836
|
+
return;
|
|
1837
|
+
}
|
|
1838
|
+
|
|
1835
1839
|
obj = _getProp(obj, part);
|
|
1836
1840
|
}
|
|
1837
1841
|
|
|
@@ -1947,7 +1951,7 @@ function _setPath(root, path, value, tolerant) {
|
|
|
1947
1951
|
let parts = path.split('.');
|
|
1948
1952
|
let keyName = parts.pop();
|
|
1949
1953
|
assert('Property set failed: You passed an empty path', keyName.trim().length > 0);
|
|
1950
|
-
let newRoot = _getPath(root, parts);
|
|
1954
|
+
let newRoot = _getPath(root, parts, true);
|
|
1951
1955
|
|
|
1952
1956
|
if (newRoot !== null && newRoot !== undefined) {
|
|
1953
1957
|
return set(newRoot, keyName, value);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default "4.8.
|
|
1
|
+
export default "4.8.2";
|
package/docs/data.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ember-source",
|
|
3
|
-
"version": "4.8.
|
|
3
|
+
"version": "4.8.2",
|
|
4
4
|
"description": "A JavaScript framework for creating ambitious web applications",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ember-addon"
|
|
@@ -178,6 +178,6 @@
|
|
|
178
178
|
]
|
|
179
179
|
}
|
|
180
180
|
},
|
|
181
|
-
"_originalVersion": "4.8.
|
|
181
|
+
"_originalVersion": "4.8.2",
|
|
182
182
|
"_versionPreviouslyCalculated": true
|
|
183
183
|
}
|
|
@@ -106,6 +106,15 @@ declare module '@ember/component' {
|
|
|
106
106
|
object: T
|
|
107
107
|
): T;
|
|
108
108
|
|
|
109
|
+
/**
|
|
110
|
+
* Takes a component class and returns the template associated with the given component class,
|
|
111
|
+
* if any, or one of its superclasses, if any, or undefined if no template association was found.
|
|
112
|
+
*
|
|
113
|
+
* @param object the component object
|
|
114
|
+
* @return the template factory of the given component
|
|
115
|
+
*/
|
|
116
|
+
export function getComponentTemplate(obj: object): TemplateFactory | undefined;
|
|
117
|
+
|
|
109
118
|
// In normal TypeScript, these built-in components are essentially opaque tokens
|
|
110
119
|
// that just need to be importable. Declaring them with unique interfaces
|
|
111
120
|
// like this, however, gives tools like Glint (that DO have a richer
|