Re: [csswg-drafts] [css-ui-4] Ellipsizing of text in middle of string (#3937)

> > There might be cases, in which you'd want to do block-level middle-cropping.
> 
> Would there? on single line ellipsis, doing it it the middle makes sense to me, but on multiline, it seems a lot less useful. Maybe I'm just short on imagination. Do you have examples of when you'd want that?

Well, the cases are not as strong as the single-line cases, I guess. Though the principle stays the same, i.e. cases, in which you care more about the ending than the middle of the contents.

One use case could be the Inspector panel within browser DevTools, which shows the text contents of the elements. When they span over many lines, it gets quickly hard to skim over the HTML structure. Those could limit the contents to a specific number of lines but crop them in the middle of the contents, so it's easy to skim over them.

Example:
![Long texts in Inspector](https://user-images.githubusercontent.com/958943/58591587-e9a9b880-8266-11e9-8fce-6b945098de6e.png)

Could be shrinked to someting like in this mockup:

![Cropped long texts in Inspector](https://user-images.githubusercontent.com/958943/58591600-f3cbb700-8266-11e9-8cca-dc601fd9ea0f.png)

Sebastian

-- 
GitHub Notification of comment by SebastianZ
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/3937#issuecomment-497111331 using your GitHub account

Received on Wednesday, 29 May 2019 21:13:27 UTC