@material-ui/utils
Advanced tools
Comparing version 5.0.0-alpha.15 to 5.0.0-alpha.17
@@ -14,3 +14,5 @@ "use strict"; | ||
function isPlainObject(item) { | ||
return item && typeof item === 'object' && item.constructor === Object; | ||
return item !== null && typeof item === 'object' && // TS thinks `item is possibly null` even though this was our first guard. | ||
// @ts-expect-error | ||
item.constructor === Object; | ||
} | ||
@@ -17,0 +19,0 @@ |
import _extends from "@babel/runtime/helpers/esm/extends"; | ||
export function isPlainObject(item) { | ||
return item && typeof item === 'object' && item.constructor === Object; | ||
return item !== null && typeof item === 'object' && // TS thinks `item is possibly null` even though this was our first guard. | ||
// @ts-expect-error | ||
item.constructor === Object; | ||
} | ||
@@ -5,0 +7,0 @@ export default function deepmerge(target, source, options = { |
@@ -10,3 +10,3 @@ export default function requirePropFactory(componentNameInError) { | ||
if (typeof props[propName] !== 'undefined' && !props[requiredProp]) { | ||
return new Error(`The prop \`${propFullNameSafe}\` of ` + `\`${componentNameInError}\` must be used on \`${requiredProp}\`.`); | ||
return new Error(`The prop \`${propFullNameSafe}\` of ` + `\`${componentNameInError}\` can only be used together with the \`${requiredProp}\` prop.`); | ||
} | ||
@@ -13,0 +13,0 @@ |
@@ -1,2 +0,2 @@ | ||
/** @license Material-UI v5.0.0-alpha.15 | ||
/** @license Material-UI v5.0.0-alpha.17 | ||
* | ||
@@ -3,0 +3,0 @@ * This source code is licensed under the MIT license found in the |
import _extends from "@babel/runtime/helpers/esm/extends"; | ||
import _typeof from "@babel/runtime/helpers/esm/typeof"; | ||
export function isPlainObject(item) { | ||
return item && _typeof(item) === 'object' && item.constructor === Object; | ||
return item !== null && _typeof(item) === 'object' && // TS thinks `item is possibly null` even though this was our first guard. | ||
// @ts-expect-error | ||
item.constructor === Object; | ||
} | ||
@@ -6,0 +8,0 @@ export default function deepmerge(target, source) { |
@@ -1,2 +0,2 @@ | ||
/** @license Material-UI v5.0.0-alpha.15 | ||
/** @license Material-UI v5.0.0-alpha.17 | ||
* | ||
@@ -3,0 +3,0 @@ * This source code is licensed under the MIT license found in the |
@@ -13,3 +13,3 @@ export default function requirePropFactory(componentNameInError) { | ||
if (typeof props[propName] !== 'undefined' && !props[requiredProp]) { | ||
return new Error("The prop `".concat(propFullNameSafe, "` of ") + "`".concat(componentNameInError, "` must be used on `").concat(requiredProp, "`.")); | ||
return new Error("The prop `".concat(propFullNameSafe, "` of ") + "`".concat(componentNameInError, "` can only be used together with the `").concat(requiredProp, "` prop.")); | ||
} | ||
@@ -16,0 +16,0 @@ |
import _extends from "@babel/runtime/helpers/esm/extends"; | ||
export function isPlainObject(item) { | ||
return item && typeof item === 'object' && item.constructor === Object; | ||
return item !== null && typeof item === 'object' && // TS thinks `item is possibly null` even though this was our first guard. | ||
// @ts-expect-error | ||
item.constructor === Object; | ||
} | ||
@@ -5,0 +7,0 @@ export default function deepmerge(target, source, options = { |
@@ -1,2 +0,2 @@ | ||
/** @license Material-UI v5.0.0-alpha.15 | ||
/** @license Material-UI v5.0.0-alpha.17 | ||
* | ||
@@ -3,0 +3,0 @@ * This source code is licensed under the MIT license found in the |
@@ -10,3 +10,3 @@ export default function requirePropFactory(componentNameInError) { | ||
if (typeof props[propName] !== 'undefined' && !props[requiredProp]) { | ||
return new Error(`The prop \`${propFullNameSafe}\` of ` + `\`${componentNameInError}\` must be used on \`${requiredProp}\`.`); | ||
return new Error(`The prop \`${propFullNameSafe}\` of ` + `\`${componentNameInError}\` can only be used together with the \`${requiredProp}\` prop.`); | ||
} | ||
@@ -13,0 +13,0 @@ |
{ | ||
"name": "@material-ui/utils", | ||
"version": "5.0.0-alpha.15", | ||
"version": "5.0.0-alpha.17", | ||
"private": false, | ||
@@ -5,0 +5,0 @@ "author": "Material-UI Team", |
@@ -17,3 +17,3 @@ "use strict"; | ||
if (typeof props[propName] !== 'undefined' && !props[requiredProp]) { | ||
return new Error(`The prop \`${propFullNameSafe}\` of ` + `\`${componentNameInError}\` must be used on \`${requiredProp}\`.`); | ||
return new Error(`The prop \`${propFullNameSafe}\` of ` + `\`${componentNameInError}\` can only be used together with the \`${requiredProp}\` prop.`); | ||
} | ||
@@ -20,0 +20,0 @@ |
Sorry, the diff of this file is too big to display
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
799986
3156
0