techniq / layerchart

Composable Svelte chart components to build a wide range of visualizations
https://www.layerchart.com
MIT License
668 stars 12 forks source link

[Tooltip / Highlight] Radial support #112

Open techniq opened 9 months ago

techniq commented 9 months ago

With the recent addition of radial line/area charts, it would be great to support tooltips

Examples

insidesmart commented 2 months ago

Just want to say, thanks for building LayerChart. Kudos for your continuous efforts.

I am using LayerChart for all chart needs except the radial one as it is currently lacking tooltip & highlight support.

Just curious if there is a possibility to have this new PR be part of any interim releases you have planned before the simplified-charts branch is fully merged ? Would love to remove Chart.js dependency at my end (to serve just this need).

Neverthless, Great work on the simplified-charts branch / shadcn-svelte integration. Looking forward.

techniq commented 2 months ago

@insidesmart thanks for the kind words. The 2 main outstanding items to merge the new Simplified Charts is to finish radial support, particularly bisect-x/y mode (radial voronoi is done), and work through AreaChart groups. I plan to have at least radial bisect done today, but if I can find enough time, I might be able to have them both done. Then I just need to prepare for the release. My goal is to merge by EoW at the latest, and if not, push a next preview release.

Does that sound good?

techniq commented 2 months ago

Here's some examples of the voronoi support available

https://github.com/user-attachments/assets/2ec990f9-2522-41ce-a99a-b0b737d7d9c3

insidesmart commented 2 months ago

Gr8 to know about the progress and the probable release dates. For now, I have converted the radial chart to bar chart (the rotate property in tickLabelProps was helpful here) and removed Chart.js dependency. Will definitely look into all other possibilities in layerchart in the upcoming weeks. Thanks again.

techniq commented 2 months ago

Curious what kind of radial chart you were using. Could you attached a screenshot?

There are a lot of radial use cases I've been thinking about / improving.

insidesmart commented 2 months ago

I was actually using a Radial Axis chart shown here -> https://www.chartjs.org/docs/latest/axes/radial/#angle-lines

techniq commented 2 months ago

Perfect, thanks. Radar is supported and works best with voronoi tooltips imo, but bisect x/y will be supported too.

Regarding additional radial charts, I'll be tracking support here

techniq commented 2 months ago

bisect-x available in simplified charts PR (example)

https://github.com/user-attachments/assets/9a131af4-3f30-4b09-925e-5186b072d1dc