victory-voronoi-container
Advanced tools
Comparing version 30.0.0 to 30.1.0
@@ -237,7 +237,12 @@ import _pick from "lodash/pick"; | ||
childName = _points$.childName, | ||
eventKey = _points$.eventKey, | ||
style = _points$.style, | ||
continuous = _points$.continuous, | ||
datum = _objectWithoutProperties(_points$, ["childName", "style", "continuous"]); | ||
datum = _objectWithoutProperties(_points$, ["childName", "eventKey", "style", "continuous"]); | ||
var name = props.name === childName ? childName : "".concat(props.name, "-").concat(childName); | ||
var labelProps = _defaults({ | ||
key: "".concat(name, "-").concat(eventKey, "-voronoi-tooltip"), | ||
id: "".concat(name, "-").concat(eventKey, "-voronoi-tooltip"), | ||
active: true, | ||
@@ -277,8 +282,3 @@ flyoutStyle: this.getStyle(props, points, "flyout")[0], | ||
value: function getChildren(props) { | ||
var children = React.Children.toArray(props.children); | ||
return _toConsumableArray(children).concat([this.getTooltip(props)]).map(function (component, i) { | ||
return component ? React.cloneElement(component, { | ||
key: i | ||
}) : null; | ||
}); | ||
return _toConsumableArray(React.Children.toArray(props.children)).concat([this.getTooltip(props)]); | ||
} | ||
@@ -285,0 +285,0 @@ }]); |
@@ -259,7 +259,11 @@ "use strict"; | ||
childName = _points$.childName, | ||
eventKey = _points$.eventKey, | ||
style = _points$.style, | ||
continuous = _points$.continuous, | ||
datum = _objectWithoutProperties(_points$, ["childName", "style", "continuous"]); | ||
datum = _objectWithoutProperties(_points$, ["childName", "eventKey", "style", "continuous"]); | ||
var name = props.name === childName ? childName : "".concat(props.name, "-").concat(childName); | ||
var labelProps = (0, _defaults2.default)({ | ||
key: "".concat(name, "-").concat(eventKey, "-voronoi-tooltip"), | ||
id: "".concat(name, "-").concat(eventKey, "-voronoi-tooltip"), | ||
active: true, | ||
@@ -298,9 +302,3 @@ flyoutStyle: this.getStyle(props, points, "flyout")[0], | ||
value: function getChildren(props) { | ||
var children = _react.default.Children.toArray(props.children); | ||
return _toConsumableArray(children).concat([this.getTooltip(props)]).map(function (component, i) { | ||
return component ? _react.default.cloneElement(component, { | ||
key: i | ||
}) : null; | ||
}); | ||
return _toConsumableArray(_react.default.Children.toArray(props.children)).concat([this.getTooltip(props)]); | ||
} | ||
@@ -307,0 +305,0 @@ }]); |
{ | ||
"name": "victory-voronoi-container", | ||
"version": "30.0.0", | ||
"description": "Chart Component for Victory", | ||
"version": "30.1.0", | ||
"description": "Interactive Voronoi Mouseover Component for Victory", | ||
"keywords": [ | ||
"data visualization", | ||
"React", | ||
"d3", | ||
"charting" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/formidablelabs/victory.git" | ||
}, | ||
"homepage": "https://formidable.com/open-source/victory", | ||
"main": "lib/index.js", | ||
@@ -13,4 +24,5 @@ "module": "es/index.js", | ||
"lodash": "^4.17.5", | ||
"victory-core": "^30.0.0", | ||
"victory-tooltip": "^30.0.0" | ||
"prop-types": "^15.5.8", | ||
"victory-core": "^30.1.0", | ||
"victory-tooltip": "^30.1.0" | ||
}, | ||
@@ -17,0 +29,0 @@ "scripts": { |
@@ -204,6 +204,8 @@ import PropTypes from "prop-types"; | ||
// eslint-disable-next-line no-unused-vars | ||
const { childName, style, continuous, ...datum } = points[0]; | ||
const { childName, eventKey, style, continuous, ...datum } = points[0]; | ||
const name = props.name === childName ? childName : `${props.name}-${childName}`; | ||
const labelProps = defaults( | ||
{ | ||
key: `${name}-${eventKey}-voronoi-tooltip`, | ||
id: `${name}-${eventKey}-voronoi-tooltip`, | ||
active: true, | ||
@@ -239,6 +241,3 @@ flyoutStyle: this.getStyle(props, points, "flyout")[0], | ||
getChildren(props) { | ||
const children = React.Children.toArray(props.children); | ||
return [...children, this.getTooltip(props)].map((component, i) => { | ||
return component ? React.cloneElement(component, { key: i }) : null; | ||
}); | ||
return [...React.Children.toArray(props.children), this.getTooltip(props)]; | ||
} | ||
@@ -245,0 +244,0 @@ }; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
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
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
1309013
23836
1
5
18
+ Addedprop-types@^15.5.8
Updatedvictory-core@^30.1.0
Updatedvictory-tooltip@^30.1.0