Một corner case curious cho bạn. Khoảng năm trước, Firefox Quantum giới thiệu radical changes cách hoạt động, lớn nhất switch sang WebExtensions. Move này làm nhiều extensions friendly, powerful không work, bao gồm range tab management addons. Upside, Firefox cũng带来 integrated tab pinning feature. Nó work nice. Nhưng.
Pinned tabs detach từ tab bar và position themselves bên trái, somewhat như typical desktop quicklaunch icon area. So far so good, nhưng corner case ở đây! Hiện ra, pinned tabs relative narrow, nghĩa là quick stab 'n' open action không quite possible. Bạn cần accurate positioning mouse cursor, và đó could slow you down. Không seem có trivial option thay đổi width pinned tabs. Hence guide này.
Làm pinned tabs rộng hơn
Tôi first encounter Firefox UI customization hồi trước khi chúng ta merrily và thoroughly discuss Linux Plasma desktop HD scaling. Tôi dùng several manual overrides tăng UI size, vì không possible native solutions desktop environment, hoặc rather possible nhưng không pretty. Giờ chúng ta dùng approach tương tự làm pinned tabs nicer.
Firefox UI overrides available qua file userChrome.css trong Firefox profile directory. File này chứa CSS declarations dictate browser looks, rất như Web page. Bạn đổi fonts, colors, borders, margins, padding, anything. Tất nhiên, cần understanding syntax, và aware different classes Firefox dùng cho interface. Typical Windows path:
C:\Users\(your user name)\AppData\Roaming\Mozilla\Firefox\Profiles\
(profile)\chrome\userChrome.css
Typical Linux path:
~/.mozilla/firefox/(profile)/chrome/userChrome.css
Với pinned tabs, chúng ta add:
/* Tabs */
.tabbrowser-tab[pinned] {
padding-left: 20px;
padding-right: 20px;
}
Code trên add padding left và right của pinned "icon", làm pinned tabs wider và accessible hơn - centered VÀ symmetric - 20 pixels. Bạn cũng có thể chỉ tăng width tabs, nhưng thì icons align left, và bạn có empty space nhiều right, looks wrong. Làm OCD pixies explode. Dùng uniform left right padding làm nice, elegant fix.
Và in a way, that's it. Bob's your uncle!
Kết luận
Vậy là xong. Yêu cầu OCD met và satisfied. Firefox Quantum vẫn retain fair degree customization, dù less accessible ordinary users. Tôi hope functionality remains, vì đó là distinctive advantage Firefox over other browsers. Quite a bit lost với move WebExtensions, shame thấy flexible, modular browser turn into static, lifeless shell no edge over competitors.
Nếu bạn muốn dùng Firefox pinned tabs, bạn cũng có improved accessibility option. Làm tabs rộng hơn turns chúng consistent và in line với tab bar, cộng dễ hit với quick mouse actions. Hơn nữa, dùng userChrome.css overrides, bạn có thể further improvements browser UI layout. Tăng vertical spacing hoặc padding, ví dụ. Hy vọng guide nhỏ hữu ích. See you around.
Chào.