project-nv / night-vision

Highly customizable charting library, created for professional traders
https://nightvision.dev
MIT License
250 stars 58 forks source link

Custom HTML tooltips #85

Closed nchanged closed 1 year ago

nchanged commented 1 year ago

Description

Custom HTML tooltips

Suggested solution

chart.events.on('app:cursor-changed', (e) => {});

there should be a method which would allow getting the current candle under the cursor. Would be nice to have that candle coordinates relative to the main div object so it's easier to place something on top of it.

Alternative

No response

Additional context

No response

Validations

C451 commented 1 year ago

Although you supposed to use an overlay for that, I've added a method in cursor event

C451 commented 1 year ago

https://github.com/project-nv/night-vision/commit/2667bd25b6f88d750ac340422cf520bc3a5e6801