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

Clamp the string when there are no spaces #45

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

JoaoRPF
Copy link

@JoaoRPF JoaoRPF commented Mar 27, 2019

This issue is mentioned here: #39

This is a solution specific to when the component is using letters based mode.

@JoaoRPF
Copy link
Author

JoaoRPF commented Mar 27, 2019

@xiaody please review and reach to me if there is any doubt 😄

@xiaody
Copy link
Owner

xiaody commented Mar 28, 2019

Thanks @JoaoRPF I have just commented the issue.
I think it's unnecessary for this component to clamp the width. If you still have trouble with the latest version, feel free to comment more.

@JoaoRPF
Copy link
Author

JoaoRPF commented Mar 28, 2019

I tried your solution (in #39), by adding a overflow-wrap: "break-word" to the style but it did not solve my problem (as shown in the attached image).
ellipsis

@JoaoRPF
Copy link
Author

JoaoRPF commented Mar 28, 2019

I solved it by adding

overflow-wrap: "break-word",
word-break: "break-word",
word-wrap: "break-word"

I think different browsers use different properties.
I'm still having the problem of getting to the next line (if only one word, i want to do the ellipsis in the first line, not in the second). But at least, is doing the ellipsis in the second 😃

Check here for more details: https://css-tricks.com/snippets/css/prevent-long-urls-from-breaking-out-of-container/

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

Successfully merging this pull request may close these issues.

2 participants