搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

Learn More

Trying to set my tab close button to the left

more options

I am using theme called WhiteSur to imitate Safari, as that is the browser layout I prefer. However, this doesn't change the position of the close tab button and leaves it on the right hand side. I found a way to change it, using the code .tabbrowser-tab .tab-close-button {

 margin-left: -5px !important;
 margin-right: 2.5px !important;

} Unfortunately, this doesn't change based on the size of the tab, so if I set it to a size that is good for only having 1 tab, it will look bad or be off the screen for the other amounts of tabs. Is there a way to detect the width of the tab or the amount of tabs open and dynamically set the margins based off of this? So I could set it as (width-of-tab)-x and that would always keep the close tab button in the same spot, regardless of tab size. Thanks!

I am using theme called WhiteSur to imitate Safari, as that is the browser layout I prefer. However, this doesn't change the position of the close tab button and leaves it on the right hand side. I found a way to change it, using the code .tabbrowser-tab .tab-close-button { margin-left: -5px !important; margin-right: 2.5px !important; } Unfortunately, this doesn't change based on the size of the tab, so if I set it to a size that is good for only having 1 tab, it will look bad or be off the screen for the other amounts of tabs. Is there a way to detect the width of the tab or the amount of tabs open and dynamically set the margins based off of this? So I could set it as (width-of-tab)-x and that would always keep the close tab button in the same spot, regardless of tab size. Thanks!

所有回复 (4)

more options

You can use the order property to slide the close button to the first position in the tab. Strange things were happening when I hover the button, so everything after the first line was intended to address that:

/* Move tab close button to left side of tab */
.tabbrowser-tab .tab-close-button {
  order: -1;
  /* Prevent movement when hovering */
  width: 24px !important;
  padding-left: 6px !important;
  margin-left: -4px !important;
  margin-right: 0 !important;
}

有帮助吗?

more options

So I tried that, and you can see what I got in the screenshot below. The x is centered instead of on the left. It's progress since its centered regardless but still not quite what I want. I tried playing with some of the values, but I wasn't able to put it on the left instead of the center. Any ideas?

有帮助吗?

more options

Sorry, I tested with zero other modifications. You seem to have some other rules changing your tabs.

(I should add: I run Windows, so I don't use Safari.)

由jscher2000 - Support Volunteer于修改

有帮助吗?

more options

Is it this one? It has a file for moving the close button to the left, but there is a bug with it since, reportedly, Firefox 113. You may want to follow up with the developer and see whether any progress is expected:

有帮助吗?

我要提问

您需要登录才能回复。如果您还没账号,可以提出新问题