Skip to content

fix(ui5-bar): prevent midContent from overlapping start and endContent on overflow #11294

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

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hinzzx
Copy link
Contributor

@hinzzx hinzzx commented Apr 9, 2025

Previously when the content inside the <ui5-bar> component, especially a long text in the midContent slot, was provided the content was overlapping the startContent and endContent, especially when the bar was resized or contained limited space.

2025-04-09_15-41-31

The reason behind this was that while all three content containers were using flex, they allowed the middle content (midContent) to grow too much.

Now the startContent and endContent set to flex: 0 0 auto to maintain their natural size and prevent shrinking past their content.

  • midContent set to flex: 1 1 auto to take up remaining space and shrink if needed.
  • min-width: 0 on midContent to allow truncation.
  • Added overflow: hidden to .ui5-bar-root so any overflowing content would be clipped rather than spill outside the bar (just like in UI5);

2025-04-09_15-45-32

Fixes: #11028

@ilhan007
Copy link
Member

Reabase with the main, chromedriver has bene updated and some failing tests have been fixed

@hinzzx hinzzx requested a review from unazko April 14, 2025 05:54
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.

[ui5-bar]: Buttons in startContent and endContent are cut off when there is long title
2 participants