victory-core
Advanced tools
Comparing version 37.0.1 to 37.0.2
# victory-core | ||
## 37.0.2 | ||
### Patch Changes | ||
- Ensure undefined props do not overwrite defaults ([#2852](https://github.com/FormidableLabs/victory/pull/2852)) | ||
## 37.0.1 | ||
@@ -4,0 +10,0 @@ |
@@ -432,6 +432,3 @@ import _isEmpty from "lodash/isEmpty"; | ||
export const VictoryLabel = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
if (props.text === null || props.text === undefined) { | ||
@@ -438,0 +435,0 @@ return null; |
@@ -0,1 +1,2 @@ | ||
import _defaults from "lodash/defaults"; | ||
/* eslint no-magic-numbers: ["error", { "ignore": [0, 1, 2, 180] }]*/ | ||
@@ -61,6 +62,3 @@ import React from "react"; | ||
export const Arc = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
return /*#__PURE__*/React.cloneElement(props.pathComponent, { | ||
@@ -67,0 +65,0 @@ ...props.events, |
@@ -0,1 +1,2 @@ | ||
import _defaults from "lodash/defaults"; | ||
import React from "react"; | ||
@@ -22,6 +23,3 @@ import * as Helpers from "../victory-util/helpers"; | ||
export const Background = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
return props.polar ? /*#__PURE__*/React.cloneElement(props.circleComponent, { | ||
@@ -28,0 +26,0 @@ ...props.events, |
@@ -0,1 +1,2 @@ | ||
import _defaults from "lodash/defaults"; | ||
import React from "react"; | ||
@@ -34,6 +35,3 @@ import * as Helpers from "../victory-util/helpers"; | ||
export const Border = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
return /*#__PURE__*/React.cloneElement(props.rectComponent, { | ||
@@ -40,0 +38,0 @@ ...props.events, |
@@ -0,1 +1,2 @@ | ||
import _defaults from "lodash/defaults"; | ||
import React from "react"; | ||
@@ -34,6 +35,3 @@ import * as Helpers from "../victory-util/helpers"; | ||
export const LineSegment = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
return /*#__PURE__*/React.cloneElement(props.lineComponent, { | ||
@@ -40,0 +38,0 @@ ...props.events, |
@@ -0,1 +1,2 @@ | ||
import _defaults from "lodash/defaults"; | ||
import React from "react"; | ||
@@ -54,6 +55,3 @@ import * as Helpers from "../victory-util/helpers"; | ||
export const Point = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
const userProps = UserProps.getSafeUserProps(props); | ||
@@ -60,0 +58,0 @@ return /*#__PURE__*/React.cloneElement(props.pathComponent, { |
@@ -0,1 +1,2 @@ | ||
import _defaults from "lodash/defaults"; | ||
import React from "react"; | ||
@@ -33,6 +34,3 @@ import * as Helpers from "../victory-util/helpers"; | ||
export const Whisker = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
const { | ||
@@ -39,0 +37,0 @@ ariaLabel, |
@@ -442,6 +442,3 @@ "use strict"; | ||
const VictoryLabel = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
if (props.text === null || props.text === undefined) { | ||
@@ -448,0 +445,0 @@ return null; |
@@ -7,2 +7,3 @@ "use strict"; | ||
exports.Arc = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
@@ -72,6 +73,3 @@ var Helpers = _interopRequireWildcard(require("../victory-util/helpers")); | ||
const Arc = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
return /*#__PURE__*/_react.default.cloneElement(props.pathComponent, { | ||
@@ -78,0 +76,0 @@ ...props.events, |
@@ -7,2 +7,3 @@ "use strict"; | ||
exports.Background = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
@@ -32,6 +33,3 @@ var Helpers = _interopRequireWildcard(require("../victory-util/helpers")); | ||
const Background = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
return props.polar ? /*#__PURE__*/_react.default.cloneElement(props.circleComponent, { | ||
@@ -38,0 +36,0 @@ ...props.events, |
@@ -7,2 +7,3 @@ "use strict"; | ||
exports.Border = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
@@ -44,6 +45,3 @@ var Helpers = _interopRequireWildcard(require("../victory-util/helpers")); | ||
const Border = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
return /*#__PURE__*/_react.default.cloneElement(props.rectComponent, { | ||
@@ -50,0 +48,0 @@ ...props.events, |
@@ -7,2 +7,3 @@ "use strict"; | ||
exports.LineSegment = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
@@ -44,6 +45,3 @@ var Helpers = _interopRequireWildcard(require("../victory-util/helpers")); | ||
const LineSegment = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
return /*#__PURE__*/_react.default.cloneElement(props.lineComponent, { | ||
@@ -50,0 +48,0 @@ ...props.events, |
@@ -7,2 +7,3 @@ "use strict"; | ||
exports.Point = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
@@ -64,6 +65,3 @@ var Helpers = _interopRequireWildcard(require("../victory-util/helpers")); | ||
const Point = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
const userProps = UserProps.getSafeUserProps(props); | ||
@@ -70,0 +68,0 @@ return /*#__PURE__*/_react.default.cloneElement(props.pathComponent, { |
@@ -7,2 +7,3 @@ "use strict"; | ||
exports.Whisker = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
@@ -43,6 +44,3 @@ var Helpers = _interopRequireWildcard(require("../victory-util/helpers")); | ||
const Whisker = initialProps => { | ||
const props = evaluateProps({ | ||
...defaultProps, | ||
...initialProps | ||
}); | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
const { | ||
@@ -49,0 +47,0 @@ ariaLabel, |
{ | ||
"name": "victory-core", | ||
"version": "37.0.1", | ||
"version": "37.0.2", | ||
"description": "Victory Core", | ||
@@ -25,3 +25,3 @@ "keywords": [ | ||
"react-fast-compare": "^3.2.0", | ||
"victory-vendor": "^37.0.1" | ||
"victory-vendor": "^37.0.2" | ||
}, | ||
@@ -28,0 +28,0 @@ "peerDependencies": { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2536936
54683
Updatedvictory-vendor@^37.0.2