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

Tooltip width calculated wrong. #60

Open
DennisPiskovatskov opened this issue Dec 17, 2020 · 2 comments
Open

Tooltip width calculated wrong. #60

DennisPiskovatskov opened this issue Dec 17, 2020 · 2 comments

Comments

@DennisPiskovatskov
Copy link

DennisPiskovatskov commented Dec 17, 2020

Expected behaviour

The tooltip background has to be expanded.

Actual behaviour

Only the part of the tooltip background is "black". Please see attached image.

Live demo with steps to reproduce

Have a look this picture: https://drive.google.com/file/d/1u6i4JXNU3AdsRHF9X9sa-iYcZEoGIh_K/view?usp=sharing

Product version

"sunburst-chart": "^1.11.2",

Affected browser(s)

Chrome, Version 87.0.4280.88 (Official Build) (64-bit)

@DennisPiskovatskov
Copy link
Author

DennisPiskovatskov commented Dec 17, 2020

.sunburst-tooltip {
display: none;
position: absolute;
max-width: 320px; // <---- The problem is here!
white-space: nowrap;
padding: 5px;
border-radius: 3px;
font: 12px sans-serif;
color: #eee;
background: rgba(0,0,0,0.65);
pointer-events: none;
}

@vasturiano
Copy link
Owner

@DennisPiskovatskov thanks for reaching out.

To adapt this to your use case, you can override the styling from your app.
Basically you'd need to add a css rule like:

.sunburst-tooltip {
  max-width: 1000px !important;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants