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 simple does not allow word-wrap: break-word; #529

Closed
tw15egan opened this issue Jan 26, 2018 · 4 comments
Closed

Tooltip simple does not allow word-wrap: break-word; #529

tw15egan opened this issue Jan 26, 2018 · 4 comments
Assignees

Comments

@tw15egan
Copy link
Contributor

@mandie12 commented on Fri Jan 26 2018

screen shot 2018-01-26 at 11 46 52

Tooltip simple does not allow word-wrap: break-word; on Chrome


@tw15egan commented on Fri Jan 26 2018

Can you try white-space: pre on the :before element? And make sure you have a space after the period. This should then format correctly.

@feliperyba
Copy link

Hey, I'm having the same issue with the Data Table component.
In fact I tried in many others components and the issue is also present in all of then.

wrap-problem-datatable

@alisonjoseph alisonjoseph self-assigned this Mar 1, 2018
@alisonjoseph
Copy link
Member

Hi @feliperyba, thanks for commenting! Do you mind making a new issue explaining your issue/use-case in more detail? I believe it is un-related to the tooltip bug. Thanks! 😄

@alisonjoseph
Copy link
Member

@tw15egan I don't think there's a simple way to fix this without setting a width on the tooltip which wouldn't work for shorter content. Even if we add white-space: pre that will only work for someone who can specifically format the text with line breaks.

I suppose we could use javascript to calculate character length and set a width / change a class if it's over a certain amount of characters but seems like overkill for the simple tooltip when we have the regular tooltip already?

@tw15egan
Copy link
Contributor Author

tw15egan commented Mar 1, 2018

@alisonjoseph I agree, not sure this will work for simple tooltip. I think the recommended course of action would be to use the regular tooltip for situations like this, or override the css and set a width on the end-user side (as we can't, because then it will break for other users).

I'm going to close this as and recommend setting a width , or using the regular tooltip component

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

4 participants