mirror of
https://github.com/samsonjs/spirit-tracker.git
synced 2026-04-27 15:07:43 +00:00
UX Improvements
This commit is contained in:
parent
95abc44d36
commit
a4f68eef3f
1 changed files with 7 additions and 1 deletions
|
|
@ -176,8 +176,14 @@ const StaticMarkerLinesPlugin = {
|
||||||
ctx.globalAlpha = 0.95;
|
ctx.globalAlpha = 0.95;
|
||||||
ctx.fillStyle = String(m?.labelColor || labelColor);
|
ctx.fillStyle = String(m?.labelColor || labelColor);
|
||||||
ctx.textBaseline = "middle";
|
ctx.textBaseline = "middle";
|
||||||
|
|
||||||
|
const axisX = y.left; // actual y-axis pixel
|
||||||
|
|
||||||
ctx.textAlign = "right";
|
ctx.textAlign = "right";
|
||||||
ctx.fillText(text, left - axisInset, py);
|
ctx.textBaseline = "middle";
|
||||||
|
ctx.fillText(text, axisX - axisInset, py);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue