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

Tab separator changes width when the last tab is created or closed #839

Closed
jianglai opened this issue Oct 5, 2024 · 6 comments
Closed
Labels
bug Something isn't working

Comments

@jianglai
Copy link
Contributor

jianglai commented Oct 5, 2024

Describe the bug
The vertical lines between tabs have a slightly smaller width, than then one that separates the last tab and the + new tab button.

As a result, when a new tab is created, the last tab's width suddenly increases (as the separator between it and the + button shrinks to become the separator between tabs). Similarly, when closing the last tab, the separator grows in width, and the second-to-last tab suddenly shrinks in size as it becomes the last tab.

The effect is pretty subtle, but hopefully the screen recording that I provided should explain it.

I only tested this when using the stock Firefox layout, where tabs are on top and of equal size, and the + button is next to the last open tab.

To Reproduce
Click on the + button to create a new tab.
Or
Have at least two tabs open, and close the last tab.

Expected behavior
When creating a new tab, the last open tab's width doesn't change.
And
When closing the last tab, the second-to-last tab's width doesn't change.

Screenshots

Screencast.From.2024-10-05.08-49-16.mp4
Screencast.From.2024-10-05.08-52-14.mp4

Setup information

  • OS: Arch
  • Installation method: AUR
  • Firefox version: 131.0
  • Theme version: v131
  • Optional features enabled: gnomeTheme.normalWidthTabs, gnomeTheme.tabsAsHeaderbar
@jianglai jianglai added the bug Something isn't working label Oct 5, 2024
@rafaelmardojai
Copy link
Owner

rafaelmardojai commented Dec 2, 2024

Honestly I can't see any separator.

@rafaelmardojai
Copy link
Owner

Ok, I think I now understand the issue 😅, the fix should be easy.

@jianglai
Copy link
Contributor Author

Thanks! That did fix the issue. However I noticed something else quite subtle (but visually annoying), which I'm not sure is present or not before the fix.

When I have multiple tab open, closing the last tab works as expected, but closing one of the tabs in the middle cause the first tab's width to change. For example, in the video below, closing the third tab causes the first tab's width to increase a bit, and closing the (now) third tab again causes the first tab's width to decrease a bit.

Screencast.From.2024-12-23.20-21-03.trimmed.mp4

@rafaelmardojai
Copy link
Owner

Yes, looks like the Firefox tab closing mechanic doesn't expects the tab having box-sizing: content-box; for its calculations.

@jianglai
Copy link
Contributor Author

Is there an easy fix for this? If not, it seems like the old behavior is better.

@rafaelmardojai
Copy link
Owner

Is there an easy fix for this? If not, it seems like the old behavior is better.

Tried a few things but looks like is not posible, might be related to problems like #174 that happen when you mess with the tabs sizing. Will revert the previous fix.

rafaelmardojai added a commit that referenced this issue Dec 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants