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

visual-bug: text cuts off panel widget when project name is too long #6219

Closed
SethFalco opened this issue Jun 22, 2021 · 1 comment
Closed
Assignees
Labels
enhancement Adding or requesting a new feature.
Milestone

Comments

@SethFalco
Copy link
Contributor

SethFalco commented Jun 22, 2021

Describe the issue

When the project name is too long ("Magick Image Reader" in my case), it renders outside of the bounds of the Open Graph image.

To Reproduce the issue

Steps to reproduce the behavior:

  1. Start creating a project (or edit an existing one)
  2. Set the "project name" to something long (such as "Magick Image Reader")
  3. Head to the /widgets/{project} for the project
  4. Observe the "Panel" widget

Expected behavior

A clean image with logically placed parts, and truncation if it otherwise wouldn't fit the image well.

For example:

  • Set the text size based on the width of the text. (not the number of characters)
  • Add an ellipsis at the end. (it might look bad, but it'd look better than having text cut off)

Alternatively, specific things could be done if the text is only slightly larger:

  • Remove the word "Project"

I don't think the alternative solutions are nice, seems like it'd just overcomplicate how the image is built as it doesn't scale to any/all lengths.

Screenshots

Example of the issue on my Weblate instance:
image

Example of how GitHub handles long repository names with spaces:
image

Example of how GitHub handles long repository names without spaces:
image

Server configuration and status

Weblate installation: Docker Compose

(Omitted the rest as it's just a visual issue.)

@nijel nijel self-assigned this Jun 23, 2021
@nijel nijel added the enhancement Adding or requesting a new feature. label Jun 23, 2021
@nijel nijel added this to the 4.7.1 milestone Jun 23, 2021
@nijel nijel closed this as completed in 066c7a0 Jun 23, 2021
@github-actions
Copy link

Thank you for your report; the issue you have reported has just been fixed.

  • In case you see a problem with the fix, please comment on this issue.
  • In case you see a similar problem, please open a separate issue.
  • If you are happy with the outcome, don’t hesitate to support Weblate by making a donation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Adding or requesting a new feature.
Projects
None yet
Development

No branches or pull requests

2 participants