Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v5 beta 5: autofit,tooltip interaction broken after resize #4533

Closed
sspilleman opened this issue Dec 28, 2022 · 1 comment · Fixed by #4582
Closed

v5 beta 5: autofit,tooltip interaction broken after resize #4533

sspilleman opened this issue Dec 28, 2022 · 1 comment · Fixed by #4582
Assignees
Milestone

Comments

@sspilleman
Copy link

Hi,

Im using:

const chart = new Chart({ container, autoFit: true });
chart.interaction({ type: "tooltip" });
<div bind:this={container} style="width: 100%;height: 100%;" />

The parent container is responsive and resizes when I resize the browser

.parent {
  aspect-ratio: 4/2;
}

The tooltip works great when the chart is loaded and the content indeed fits the parent div seamlessly. After I resize the browser the chart resizes perfectly to the resized parent... Great! However, after the resize, the tooltip stops working when I hover the chart. I also tried hovering the entire chart area but it really doesn't show anymore, even after resizing to the initial size.

What is causing it to break?

Thank you,

Sander

@pearmini
Copy link
Member

OK, I'll figure it out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants