scottbedard / svelte-heatmap

A light weight and customizable version of GitHub's contribution graph
MIT License
148 stars 18 forks source link

Add tooltips #141

Open jfix opened 3 years ago

jfix commented 3 years ago

Me again ;-)

Similar to the Github activity heatmap I'd like to suggest to make it possible to show tooltips with some user-definable contents (based on the data attributes for each day, maybe). I've found tippy and a Svelte integration. I've done some basic testing to see how this works with SVG, it does.

However, I am at a loss as to how to combine your component and this one. As a Svelte newbie, I'd appreciate a pointer so that I could maybe provide a PR, or if this doesn't make sense, an idea on how to combine the two components.

JohnRSim commented 3 years ago

Don't really need tippy but I'd say update Cell.svelte pass through any extra value. From the heat map and add your hover, tap to it.

I'm going to need this soon so will be sending across a PR example.

Folyd commented 3 years ago

Hi guys, I have submitted a tooltip prototype implementation without tippyjs, See #258. Not perfect yet, feel free to give it a look.

Neo-Desktop commented 3 years ago

hey @scottbedard is this something you can merge in?

tweinreich commented 1 year ago

Since this repo is probably dead, I want to share my fork including SVG-native tooltips. Feel free to use it and please let me know if there is a fork that is still being maintained.