victory-zoom-container
Advanced tools
Comparing version 36.5.0 to 36.5.1
@@ -15,3 +15,3 @@ import * as React from "react"; | ||
domain: { x: DomainTuple; y: DomainTuple }, | ||
props: VictoryZoomContainerProps | ||
props: VictoryZoomContainerProps, | ||
) => void; | ||
@@ -18,0 +18,0 @@ zoomDimension?: ZoomDimensionType; |
export { zoomContainerMixin, default as VictoryZoomContainer } from "./victory-zoom-container"; | ||
export { default as ZoomHelpers, RawZoomHelpers } from "./zoom-helpers"; | ||
export { default as ZoomHelpers, RawZoomHelpers } from "./zoom-helpers"; | ||
//# sourceMappingURL=index.js.map |
@@ -272,2 +272,3 @@ import _isFunction from "lodash/isFunction"; | ||
}; | ||
export default zoomContainerMixin(VictoryContainer); | ||
export default zoomContainerMixin(VictoryContainer); | ||
//# sourceMappingURL=victory-zoom-container.js.map |
@@ -404,2 +404,3 @@ import _delay from "lodash/delay"; | ||
}) | ||
}; | ||
}; | ||
//# sourceMappingURL=zoom-helpers.js.map |
@@ -15,3 +15,3 @@ import * as React from "react"; | ||
domain: { x: DomainTuple; y: DomainTuple }, | ||
props: VictoryZoomContainerProps | ||
props: VictoryZoomContainerProps, | ||
) => void; | ||
@@ -18,0 +18,0 @@ zoomDimension?: ZoomDimensionType; |
@@ -37,2 +37,3 @@ "use strict"; | ||
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; } | ||
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; } | ||
//# sourceMappingURL=index.js.map |
@@ -293,2 +293,3 @@ "use strict"; | ||
exports.default = _default; | ||
exports.default = _default; | ||
//# sourceMappingURL=victory-zoom-container.js.map |
@@ -421,2 +421,3 @@ "use strict"; | ||
}; | ||
exports.default = _default; | ||
exports.default = _default; | ||
//# sourceMappingURL=zoom-helpers.js.map |
{ | ||
"name": "victory-zoom-container", | ||
"version": "36.5.0", | ||
"version": "36.5.1", | ||
"description": "Interactive Zoom Component for Victory", | ||
@@ -24,3 +24,3 @@ "keywords": [ | ||
"prop-types": "^15.8.1", | ||
"victory-core": "^36.5.0" | ||
"victory-core": "^36.5.1" | ||
}, | ||
@@ -34,3 +34,3 @@ "peerDependencies": { | ||
"sideEffects": false, | ||
"gitHead": "7cecba921f751c3decc8215f7e866f51d11203c1" | ||
"gitHead": "fbe60407533cd7a6da4f8155d2ef8e189583c5a2" | ||
} |
@@ -15,3 +15,3 @@ import * as React from "react"; | ||
domain: { x: DomainTuple; y: DomainTuple }, | ||
props: VictoryZoomContainerProps | ||
props: VictoryZoomContainerProps, | ||
) => void; | ||
@@ -18,0 +18,0 @@ zoomDimension?: ZoomDimensionType; |
export { | ||
zoomContainerMixin, | ||
default as VictoryZoomContainer | ||
default as VictoryZoomContainer, | ||
} from "./victory-zoom-container"; | ||
export { default as ZoomHelpers, RawZoomHelpers } from "./zoom-helpers"; |
@@ -9,3 +9,3 @@ import PropTypes from "prop-types"; | ||
Data, | ||
PropTypes as CustomPropTypes | ||
PropTypes as CustomPropTypes, | ||
} from "victory-core"; | ||
@@ -28,3 +28,3 @@ | ||
x: PropTypes.number, | ||
y: PropTypes.number | ||
y: PropTypes.number, | ||
}), | ||
@@ -35,4 +35,4 @@ onZoomDomainChange: PropTypes.func, | ||
x: CustomPropTypes.domain, | ||
y: CustomPropTypes.domain | ||
}) | ||
y: CustomPropTypes.domain, | ||
}), | ||
}; | ||
@@ -45,3 +45,3 @@ | ||
allowZoom: true, | ||
zoomActive: false | ||
zoomActive: false, | ||
}; | ||
@@ -101,5 +101,5 @@ | ||
? {} | ||
: { onWheel: ZoomHelpers.onWheel }) | ||
} | ||
} | ||
: { onWheel: ZoomHelpers.onWheel }), | ||
}, | ||
}, | ||
]; | ||
@@ -124,3 +124,3 @@ }; | ||
radius: polar ? radius : undefined, | ||
...clipContainerComponent.props | ||
...clipContainerComponent.props, | ||
}); | ||
@@ -140,3 +140,3 @@ return React.Children.toArray(children).map((child) => { | ||
x: originalDomain.x, | ||
y: [0, domain.y[1]] | ||
y: [0, domain.y[1]], | ||
}; | ||
@@ -173,3 +173,3 @@ } | ||
let startIndex = data.findIndex( | ||
(d) => d[dimension] >= domain[dimension][0] | ||
(d) => d[dimension] >= domain[dimension][0], | ||
); | ||
@@ -202,3 +202,3 @@ let endIndex = data.findIndex((d) => d[dimension] > domain[dimension][1]); | ||
props.cachedZoomDomain, | ||
props.domain | ||
props.domain, | ||
); | ||
@@ -224,3 +224,3 @@ let domain; | ||
...zoomDomain, | ||
[props.zoomDimension]: newDomain[props.zoomDimension] | ||
[props.zoomDimension]: newDomain[props.zoomDimension], | ||
}; | ||
@@ -233,3 +233,3 @@ } | ||
domain: newDomain, | ||
data: this.downsampleZoomData(props, child, newDomain) | ||
data: this.downsampleZoomData(props, child, newDomain), | ||
} | ||
@@ -236,0 +236,0 @@ : { domain: newDomain }; |
@@ -44,7 +44,7 @@ /*eslint no-magic-numbers: ["error", { "ignore": [-1, 0, 1, 2, 1000] }]*/ | ||
factor, | ||
percent | ||
percent, | ||
); | ||
const newDomain = [ | ||
newMin > fromBound && newMin < toBound ? newMin : fromBound, | ||
newMax < toBound && newMax > fromBound ? newMax : toBound | ||
newMax < toBound && newMax > fromBound ? newMax : toBound, | ||
]; | ||
@@ -80,3 +80,3 @@ const domain = | ||
minExtent > from && minExtent < to ? minExtent : from, | ||
maxExtent < to && maxExtent > from ? maxExtent : +from + extent / 2 | ||
maxExtent < to && maxExtent > from ? maxExtent : +from + extent / 2, | ||
]; | ||
@@ -107,3 +107,3 @@ }, | ||
x: props.scale.x.domain(originalDomain.x), | ||
y: props.scale.y.domain(originalDomain.y) | ||
y: props.scale.y.domain(originalDomain.y), | ||
}; | ||
@@ -185,8 +185,8 @@ return Selection.getDataCoordinates(props, originalScale, x, y); | ||
zoomDimension, | ||
childComponents | ||
) | ||
childComponents, | ||
), | ||
} | ||
: { | ||
x: Wrapper.getDomainFromChildren(props, "x", childComponents), | ||
y: Wrapper.getDomainFromChildren(props, "y", childComponents) | ||
y: Wrapper.getDomainFromChildren(props, "y", childComponents), | ||
}; | ||
@@ -213,6 +213,6 @@ } | ||
parentSVG, | ||
parentControlledProps: ["domain"] | ||
parentControlledProps: ["domain"], | ||
}; | ||
} | ||
} | ||
}, | ||
}, | ||
]; | ||
@@ -230,4 +230,4 @@ }, | ||
return { panning: false }; | ||
} | ||
} | ||
}, | ||
}, | ||
]; | ||
@@ -245,4 +245,4 @@ }, | ||
return { panning: false }; | ||
} | ||
} | ||
}, | ||
}, | ||
]; | ||
@@ -261,3 +261,3 @@ }, | ||
zoomDimension, | ||
horizontal | ||
horizontal, | ||
} = targetProps; | ||
@@ -280,3 +280,3 @@ const parentSVG = targetProps.parentSVG || Selection.getParentSVG(evt); | ||
? originalDomain.y | ||
: this.pan(lastDomain.y, originalDomain.y, dy) | ||
: this.pan(lastDomain.y, originalDomain.y, dy), | ||
}; | ||
@@ -295,3 +295,3 @@ const resumeAnimation = this.handleAnimation(ctx); | ||
cachedZoomDomain: zoomDomain, | ||
zoomActive | ||
zoomActive, | ||
}; | ||
@@ -302,3 +302,3 @@ | ||
currentDomain, | ||
defaults({}, mutatedProps, targetProps) | ||
defaults({}, mutatedProps, targetProps), | ||
); | ||
@@ -310,4 +310,4 @@ } | ||
callback: resumeAnimation, | ||
mutation: () => mutatedProps | ||
} | ||
mutation: () => mutatedProps, | ||
}, | ||
]; | ||
@@ -335,3 +335,3 @@ } | ||
? lastDomain.y | ||
: this.scale(y, evt, targetProps, "y") | ||
: this.scale(y, evt, targetProps, "y"), | ||
}; | ||
@@ -352,3 +352,3 @@ const resumeAnimation = this.handleAnimation(ctx); | ||
panning: false, | ||
zoomActive | ||
zoomActive, | ||
}; | ||
@@ -359,3 +359,3 @@ | ||
currentDomain, | ||
defaults({}, mutatedProps, targetProps) | ||
defaults({}, mutatedProps, targetProps), | ||
); | ||
@@ -368,6 +368,6 @@ } | ||
callback: resumeAnimation, | ||
mutation: () => mutatedProps | ||
} | ||
mutation: () => mutatedProps, | ||
}, | ||
]; | ||
} | ||
}, | ||
}; | ||
@@ -385,3 +385,3 @@ | ||
16, // eslint-disable-line no-magic-numbers | ||
{ leading: true, trailing: false } | ||
{ leading: true, trailing: false }, | ||
), | ||
@@ -391,4 +391,4 @@ onWheel: throttle( | ||
16, // eslint-disable-line no-magic-numbers | ||
{ leading: true, trailing: false } | ||
) | ||
{ leading: true, trailing: false }, | ||
), | ||
}; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
923627
17513
3
Updatedvictory-core@^36.5.1