Skip to content

Fix dropdown item overflow for long filenames

Thomas Hutterer requested to merge 418047-fix-overflow into master

What does this MR do and why?

This is a small fix follow-up to !134133 (merged) where this dropdown was migrated to a GlDisclosureDropdown as part of the Pajamas Migration Day.

In the new component, for long filenames, the dropdown item's text was overflowing it's flexbox parent, first shrinking the icon, then pushing it out of bound.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After
image image

How to set up and validate locally

  • In any project, go to Code > Commits and pick any commit.
  • To fake some really long filenames, you can edit the dropdownItems function in the changed file, changing the text: to any string.
  • Compare overflow behavior between this MR and master.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #418047 (closed)

Edited by Thomas Hutterer

Merge request reports