Skip to content

[v13] Fix the top bar going outside the window#33822

Merged
gzdunek merged 4 commits intobranch/v13from
bot/backport-33752-branch/v13
Oct 24, 2023
Merged

[v13] Fix the top bar going outside the window#33822
gzdunek merged 4 commits intobranch/v13from
bot/backport-33752-branch/v13

Conversation

@gzdunek
Copy link
Copy Markdown
Contributor

@gzdunek gzdunek commented Oct 23, 2023

Backport #33752 to branch/v13

Changelog: Fix the top bar breaking layout when the window is narrow in Connect.

@gzdunek gzdunek enabled auto-merge October 23, 2023 17:11
@gzdunek gzdunek added this pull request to the merge queue Oct 23, 2023
@gzdunek gzdunek removed this pull request from the merge queue due to a manual request Oct 23, 2023
@gzdunek
Copy link
Copy Markdown
Contributor Author

gzdunek commented Oct 23, 2023

Weird, gap seems to be not applied when minWidth: 0 is set on the central element:

image

I thought that it may be caused by the 0 value, but minWidth: 1px looks almost the same. I think I will just increase a bit the min window width to solve this.

@ravicious
Copy link
Copy Markdown
Member

ravicious commented Oct 24, 2023

The gap is being applied, it's the central elements' children that overflow, making it appear as if the gap wasn't applied. You can verify this by adding overflow: hidden to the central element.

Ultimately, I think that min-width: 0 is just a band-aid. AFAIK the real problem is that the top bar contents overflows its parent. The issue might be several flexbox layers deep, we might be able to find it eventually or rewrite the top bar to use grid for everything, if it actually makes it easier to manage this.

For now I agree that the increase of min width of the window seems to be a good enough solution.

The top bar overflowing:

Screen.Recording.2023-10-24.at.11.13.40.mov

@gzdunek
Copy link
Copy Markdown
Contributor Author

gzdunek commented Oct 24, 2023

Ultimately, I think that min-width: 0 is just a band-aid. AFAIK the real problem is that the top bar contents overflows its parent. The issue might be several flexbox layers deep, we might be able to find it eventually or rewrite the top bar to use grid for everything, if it actually makes it easier to manage this.

Eh, I thought that min-width: 0 is a perfect fix for that overflowing child.

I will increase the min window width from 400 to 430px.

@gzdunek gzdunek enabled auto-merge October 24, 2023 16:56
@gzdunek gzdunek added this pull request to the merge queue Oct 24, 2023
Merged via the queue into branch/v13 with commit fe2af50 Oct 24, 2023
@gzdunek gzdunek deleted the bot/backport-33752-branch/v13 branch October 24, 2023 17:19
@fheinecke fheinecke mentioned this pull request Oct 24, 2023
@ravicious
Copy link
Copy Markdown
Member

Was this extra change needed only for v13?

@gzdunek
Copy link
Copy Markdown
Contributor Author

gzdunek commented Oct 30, 2023

Yes, for v14 I already increased the min-width.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants