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

Text eliding with ellipsis on datagrid text renderer #105

Merged
merged 3 commits into from
Aug 24, 2020

Conversation

nmichaud
Copy link
Contributor

This PR (phosphorjs/phosphor#341) was sitting latent on the phosphor repo - I ported it over to lumino. I removed the optionality of eliding text - I feel like in almost all cases it looks better visually, although if you feel otherwise i can add the option back. I also improved the margins around the text a bit for easier readability.

@blink1073
Copy link
Contributor

cc @ellisonbg thoughts on this one?

@nmichaud
Copy link
Contributor Author

This is what it looks like for the datagrid example:
image

@ellisonbg
Copy link
Contributor

ellisonbg commented Aug 20, 2020 via email

@nmichaud
Copy link
Contributor Author

nmichaud commented Aug 20, 2020

Can we make it configurable whether the ellipsis is at the beginning or end of the cell? The type of content will determine which is more optimal.

Yeah, that could be done as a ConfigOption on the renderer. Curious though - what type of content have you seen where ellipsis at the beginning was better?

Edit: unless you are thinking of right-to-left languages.

@nmichaud
Copy link
Contributor Author

Here's how it looks:
image

@blink1073 blink1073 merged commit 5cedb5d into jupyterlab:master Aug 24, 2020
@blink1073
Copy link
Contributor

blink1073 commented Aug 24, 2020

Released as part of @lumino/datagrid: 0.13.0 => 0.14.0

@vidartf
Copy link
Member

vidartf commented Aug 25, 2020

Curious though - what type of content have you seen where ellipsis at the beginning was better?

File paths could be one :)

@nmichaud nmichaud deleted the feature/text-eliding branch April 30, 2021 17:04
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 17, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants