{"version":"1.0","type":"rich","title":"Tooltip demo","description":"This demo showcases a reusable tooltip function for D3 v5 that positions an HTML tooltip relative to a target element without occluding it. The tooltip accepts either static HTML strings or JavaScript functions to populate its content, with customizable anchoring and automatic clamping to keep it within the viewport. Two hoverable divs demonstrate the tooltip in action, while the underlying `showTooltip` and `hideTooltip` functions handle positioning, click-outside dismissal, and timed hiding via `window.setTimeout`. The tooltip div is styled with CSS and positioned absolutely using the `getBoundingClientRect` API.","provider_name":"VizHub AI Studio","provider_url":"https://next.vizhub.com","html":"<iframe src=\"https://next.vizhub.com/viz/gist-b7fce6bf42ff4e910f6695bd48e8a132?mode=embed\" width=\"960\" height=\"300\" scrolling=\"no\" frameborder=\"1\"></iframe>","width":960,"height":300,"cache_age":3600}