Add: Option - Centered tab label

This commit is contained in:
alstjr7375 2022-03-21 13:11:44 +09:00
parent 22dd20b07e
commit c91303e08e
3 changed files with 30 additions and 0 deletions

View file

@ -0,0 +1,24 @@
/* Based on https://github.com/MrOtherGuy/firefox-csshacks/blob/master/chrome/centered_tab_label.css */
.tab-label-container {
display: grid;
justify-content: safe center;
align-items: safe center;
}
.tab-label,
.tab-secondary-label {
overflow: hidden;
}
.tabbrowser-tab[selected]:not(:hover) .tab-label-container:not([textoverflow]),
.tabbrowser-tab:not(:hover,[pinned]) .tab-label-container:not([textoverflow]) {
margin-inline-end: 5px;
}
@include Option("userChrome.tab.close_button_at_hover") {
#tabbrowser-tabs[closebuttons="activetab"] .tabbrowser-tab:not(:hover,[pinned]) .tab-label-container:not([textoverflow]) {
margin-inline-end: 1px;
}
#tabbrowser-tabs[closebuttons="activetab"] .tabbrowser-tab:not([selected]):not(:hover, [pinned]) .tab-label-container:not([textoverflow]) {
margin-inline-end: 19px;
}
}

View file

@ -37,3 +37,8 @@
@include Option("userChrome.tab.crashed") {
@import "crashed_tab";
}
/*= Tab Label - Make to Center ===============================================*/
@include Option("userChrome.tab.centered_label") {
@import "centered_label";
}

View file

@ -65,6 +65,7 @@ user_pref("userChrome.tab.bottom_rounded_corner", true);
// user_pref("userChrome.tab.always_show_tab_icon", true);
// user_pref("userChrome.tab.always_show_close_button_at_hover", true); // Need close_button_at_hover
// user_pref("userChrome.tab.sound_show_label", true); // Need remove sound_hide_label
// user_pref("userChrome.tab.centered_label", true);
// == Theme Default Settings ===================================================
// -- User Chrome --------------------------------------------------------------