Skip to content

Commit

Permalink
feat(tooltip): miniprogram support xTip. Closed #460.
Browse files Browse the repository at this point in the history
  • Loading branch information
simaQ committed Dec 20, 2018
1 parent 5a4b3b9 commit d037e73
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/component/tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -177,8 +177,9 @@ class Tooltip {
setXTipPosition(pos) {
const { showXTip, canvas, plotRange, xTipBox, crosshairsShapeY } = this;
if (showXTip) {
const el = canvas.get('el');
const canvasHeight = Util.getHeight(el);
// const el = canvas.get('el');
// const canvasHeight = Util.getHeight(el);
const canvasHeight = canvas.get('height');
const xTipWidth = xTipBox.getWidth();
const xTipHeight = xTipBox.getHeight();
let posX = pos - (xTipWidth / 2);
Expand Down

0 comments on commit d037e73

Please sign in to comment.