mirror of
https://github.com/frappe/books.git
synced 2024-11-08 23:00:56 +00:00
chore: refactor deprecated contructor
This commit is contained in:
parent
71d55950ff
commit
ad70b64e0c
@ -300,13 +300,9 @@ export default {
|
|||||||
this.$refs.tooltip.update(event);
|
this.$refs.tooltip.update(event);
|
||||||
},
|
},
|
||||||
getSvgXY({ clientX, clientY }) {
|
getSvgXY({ clientX, clientY }) {
|
||||||
// This func is apparently deprecated, will update when removed
|
const inv = this.$refs.chartSvg.getScreenCTM().inverse();
|
||||||
const point = this.$refs.chartSvg.createSVGPoint();
|
const point = new DOMPoint(clientX, clientY);
|
||||||
point.x = clientX;
|
const { x, y } = point.matrixTransform(inv);
|
||||||
point.y = clientY;
|
|
||||||
const { x, y } = point.matrixTransform(
|
|
||||||
this.$refs.chartSvg.getScreenCTM().inverse()
|
|
||||||
);
|
|
||||||
return { x, y };
|
return { x, y };
|
||||||
},
|
},
|
||||||
getPointIndexAndCoords(x, y) {
|
getPointIndexAndCoords(x, y) {
|
||||||
|
Loading…
Reference in New Issue
Block a user