Advertisement
Guest User

Tree Style Tabs w/ auto-hide tweaks FF 04/24

a guest
Apr 7th, 2024
368
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.88 KB | Source Code | 0 0
  1. /* Tree Style Tabs w/ auto-hide tweaks FF 04/24 */
  2.  
  3. /* - - - userChrome.css - - - */
  4.  
  5. #titlebar {
  6. appearance: none !important;
  7. height: 0px;
  8. }
  9.  
  10. #titlebar > #toolbar-menubar {
  11. margin-top: 0px;
  12. }
  13.  
  14. #TabsToolbar {
  15. min-width: 0 !important;
  16. min-height: 0 !important;
  17. }
  18.  
  19. #TabsToolbar > .titlebar-buttonbox-container {
  20. display: block;
  21. position: absolute;
  22. top: 12px;
  23. left: 0px;
  24. }
  25.  
  26. #sidebar-header {
  27. visibility: collapse !important;
  28. }
  29.  
  30. /* Sidebar sliding auto-reveal */
  31.  
  32. /* Sidebar min and max width removal */
  33. #sidebar {
  34. max-width: none !important;
  35. min-width: 0px !important;
  36. }
  37.  
  38. /* Hide splitter */
  39. #sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] + #sidebar-splitter {
  40. display: none !important;
  41. }
  42. /* Hide sidebar header */
  43. #sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] #sidebar-header {
  44. visibility: collapse;
  45. }
  46.  
  47. /* Shrink sidebar until hovered */
  48. :root {
  49. --thin-tab-width: 30px;
  50. --wide-tab-width: 300px;
  51. }
  52.  
  53. #sidebar-box:not([sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"]) {
  54. min-width: var(--wide-tab-width) !important;
  55. max-width: none !important;
  56. }
  57.  
  58. #sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] {
  59. overflow: hidden !important;
  60. position: relative !important;
  61. transition: all 300ms !important;
  62. /*transition: all 0ms 0s !important;*/
  63. min-width: var(--thin-tab-width) !important;
  64. max-width: var(--thin-tab-width) !important;
  65. z-index: 2;
  66. }
  67.  
  68. #sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"]:hover,
  69. #sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] #sidebar {
  70. /*transition-delay: 0s !important;*/
  71. transition: all 300ms !important;
  72. min-width: var(--wide-tab-width) !important;
  73. max-width: var(--wide-tab-width) !important;
  74. z-index: 1;
  75. }
  76.  
  77. #sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"]:hover {
  78. margin-right: calc((var(--wide-tab-width) - var(--thin-tab-width)) * -1) !important;
  79. }
  80.  
  81.  
  82.  
  83. /* - - - tree style tabs preferences "extra rules" - - - */
  84.  
  85. /* Hide border on tab bar, force its state to 'scroll', adjust margin-left for width of scrollbar. */
  86. #tabbar {
  87. border: 0;
  88. scrollbar-width: none;
  89. overflow: scroll !important;
  90. margin-top: 0 !important;
  91. }
  92.  
  93. /* Include 'reveal' animation ... stagers by level */
  94. #tabbar .tab {
  95. transition: 0.1s margin-top, 0.2s 0.1s margin-left, 0.2s 0.1s visibility;
  96. }
  97.  
  98. /* delay transitions on open */
  99. #tabbar:not(:hover) .tab {
  100. transition-delay: 0s;
  101. margin-left: 0;
  102. }
  103.  
  104. /* animate twisty reveal */
  105. #tabbar .tab .twisty {
  106. transition: 0.2s margin;
  107. }
  108.  
  109. /* general tabs */
  110. .tab {
  111. background-color: transparent;
  112. }
  113. .tab,
  114. .tab.pinned {
  115. height: 2.8em;
  116. }
  117.  
  118. /* Push tab labels slightly to the right so they're completely hidden in collapsed state, but still look fine while expanded. */
  119. .tab .label {
  120. margin-left: 1em;
  121. }
  122.  
  123. /* fix closebox */
  124. .tab .closebox {
  125. margin-left: 0;
  126. }
  127.  
  128. .tab .counter {
  129. margin-left: auto;
  130. display: inline-block !important;
  131. }
  132.  
  133. /* Hide .twisty and adjust margins so favicons have 7px on left. */
  134. #tabbar:not(:hover) .tab .twisty {
  135. visibility: hidden;
  136. margin-left: -12px;
  137. transition-delay: 0s;
  138. }
  139.  
  140.  
  141. /* hide closebox unless needed */
  142. .tab:not(:hover) .closebox {
  143. visibility: hidden;
  144. }
  145.  
  146. /* Hide sound playing/muted button. */
  147. .sound-button {
  148. margin-left: 0;
  149. display: inline-block;
  150. visibility: collapse;
  151. }
  152.  
  153. .tab.audible .sound-button {
  154. visibility: visible;
  155. margin-left: 0.25em;
  156. }
  157.  
  158. .tab:not([data-child-ids]) .counter {
  159. /* visibility: hidden; */
  160. }
  161.  
  162. tab-item:not(.subtree-collapsed) .counter {
  163. visibility: hidden;
  164. }
  165.  
  166. /* Hide 'new tab' button. */
  167. .newtab-button {
  168. display: none;
  169. }
  170.  
  171. /* active tab */
  172. .tab.active {
  173. background-color: rgba(255, 255, 255, 0.05) !important;
  174. box-shadow: inset 3px 0 0 #ffffff99 !important;
  175. }
  176. .tab:hover,
  177. .tab.active:hover {
  178. background-color: inherit;
  179. }
  180. .tab.active .label {
  181. font-weight: bold;
  182. color: #f4f4f4 !important;
  183. }
  184. .tab .label,
  185. .tab.active .label {
  186. border-bottom: 1px solid transparent;
  187. }
  188. .tab:hover .label,
  189. .tab.active:hover .label {
  190. border-bottom: 1px dotted;
  191. min-width: 0 !important;
  192. flex-shrink: 1 !important;
  193. flex-grow: unset !important;
  194. }
  195.  
  196. /* pending / unloaded tabs */
  197. .tab.discarded {
  198. background-color: #1d1d1d;
  199. }
  200. .tab.discarded .label {
  201. color: #efefefCC !important;
  202. }
  203. .tab.discarded:hover .label {
  204. color: #efefef !important;
  205. }
  206.  
  207. /* Adjust style for tab that has sound playing. */
  208. .tab.sound-playing .favicon::after,
  209. .tab.muted .favicon::after {
  210. content: '🔊';
  211. z-index: var(--favicon-base-z-index);
  212. position: absolute;
  213. font-size: 0.5em;
  214. bottom: -0.35em;
  215. right: -0.7em;
  216. }
  217.  
  218. /* Adjust style for tab that is muted. */
  219. .tab.muted .favicon::after {
  220. content: '🔇';
  221. }
  222.  
  223.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement