Skip to content

Making tooltips longer? #8152

Answered by kamilkrzyskow
paulmmoloney asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @paulmmoloney,
you can add max-width: <value> and max-height to your CSS selector above to increase the allowed width and height of the tooltip container.

[role=tooltip] > .md-tooltip2__inner {
  font-size: 0.7rem;
  color: blue;
  font-weight: normal;
  max-width: 50vw;
  max-height: 100vw;
}

Tough if the content is too long it might still go out of the users view port, and tooltips aren't designed for scrollable content.
In that case consider switching to footnotes or annotations for providing additional info.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by kamilkrzyskow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants