Guest User

Untitled

a guest
Dec 1st, 2024
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.77 KB | None | 0 0
  1. :root {
  2. /* delay before expanding tabs, set to '0' for no delay */
  3. --delay: 0.5s;
  4. --transition-time: 0.2s;
  5. --positionX1: 48px; /* '48px' for left, '0px' for right sidebar */
  6. --positionX2: absolute; /* 'absolute' for left, 'none' for right sidebar */
  7. /* width of the collapsed sidebar in fullscreen mode ('1px' or '48px') */
  8. --fullscreen-sidebar-width: 1px;
  9. }
  10.  
  11. /* macOS specific styles */
  12. @media (-moz-platform: macos) {
  13. #TabsToolbar:not([customizing="true"]) {
  14. visibility: collapse !important;
  15. }
  16.  
  17. :root:not([customizing="true"]) #nav-bar:not([inFullscreen]) {
  18. padding-left: 80px !important;
  19. }
  20.  
  21. :root:not([customizing="true"]) #TabsToolbar .titlebar-buttonbox-container {
  22. visibility: visible !important;
  23. position: absolute;
  24. top: 12px;
  25. left: 0px;
  26. display: block;
  27. }
  28. }
  29.  
  30. /* Linux/GTK specific styles */
  31. @media (-moz-gtk-csd-available),
  32. (-moz-platform: linux) {
  33. .browser-toolbar:not(.titlebar-color){ /* Fixes wrong coloring applied with --toolbar-bgcolor by Firefox (#101) */
  34. background-color: transparent !important;
  35. box-shadow: none !important;
  36. }
  37.  
  38. #TabsToolbar:not([customizing="true"]) {
  39. visibility: collapse !important;
  40. }
  41.  
  42. #toolbar-menubar {
  43. padding-top: 0px !important;
  44. }
  45.  
  46. /* Fixes issue in FF 123 where minimize, close, and maximize buttons no longer work. */
  47. :root[tabsintitlebar] #titlebar {
  48. will-change: auto !important;
  49. }
  50.  
  51. :root:not([customizing="true"]) #toolbar-menubar[inactive]+#TabsToolbar .titlebar-buttonbox-container {
  52. visibility: visible !important;
  53. position: absolute;
  54. top: var(--uc-win-ctrl-vertical-offset);
  55. display: block;
  56. z-index: 101;
  57. }
  58.  
  59. /* enable rounded top corners */
  60. :root[tabsintitlebar][sizemode="normal"]:not([gtktiledwindow="true"]):not([customizing="true"]) #nav-bar {
  61. border-top-left-radius: env(-moz-gtk-csd-titlebar-radius);
  62. border-top-right-radius: env(-moz-gtk-csd-titlebar-radius);
  63. }
  64.  
  65. /* window control padding values (these don't change the size of the actual buttons, only the padding for the navbar) */
  66. :root[tabsintitlebar]:not([customizing="true"]) {
  67. /* default button/padding size based on adw-gtk3 theme */
  68. --uc-win-ctrl-btn-width: 38px;
  69. --uc-win-ctrl-padding: 12px;
  70. /* vertical offset from the top of the window, calculation: (1/2 * (NAVBAR_HEIGHT - BUTTON_HEIGHT)) */
  71. --uc-win-ctrl-vertical-offset: 8px;
  72. /* extra window drag space */
  73. --uc-win-ctrl-drag-space: 20px;
  74. }
  75.  
  76. :root[tabsintitlebar][lwtheme]:not([customizing="true"]) {
  77. /* seperate values for when using a theme, based on the Firefox defaults */
  78. --uc-win-ctrl-btn-width: 30px;
  79. --uc-win-ctrl-padding: 12px;
  80. /* vertical offset from the top of the window, calculation: (1/2 * (NAVBAR_HEIGHT - BUTTON_HEIGHT)) */
  81. --uc-win-ctrl-vertical-offset: 5px;
  82. /* extra window drag space */
  83. --uc-win-ctrl-drag-space: 20px;
  84. }
  85.  
  86. /* setting the padding value for all button combinations */
  87. @media (-moz-gtk-csd-minimize-button),
  88. (-moz-gtk-csd-maximize-button),
  89. (-moz-gtk-csd-close-button) {
  90. #nav-bar {
  91. --uc-navbar-padding: calc(var(--uc-win-ctrl-btn-width) * 1);
  92. }
  93. }
  94.  
  95. @media (-moz-gtk-csd-minimize-button) and (-moz-gtk-csd-maximize-button),
  96. (-moz-gtk-csd-minimize-button) and (-moz-gtk-csd-close-button),
  97. (-moz-gtk-csd-maximize-button) and (-moz-gtk-csd-close-button) {
  98. #nav-bar {
  99. --uc-navbar-padding: calc(var(--uc-win-ctrl-btn-width) * 2);
  100. }
  101. }
  102.  
  103. @media (-moz-gtk-csd-minimize-button) and (-moz-gtk-csd-maximize-button) and (-moz-gtk-csd-close-button) {
  104. #nav-bar {
  105. --uc-navbar-padding: calc(var(--uc-win-ctrl-btn-width) * 3);
  106. }
  107. }
  108.  
  109. /* only applies padding/positioning if there is 1 or more buttons */
  110. @media (-moz-gtk-csd-minimize-button),
  111. (-moz-gtk-csd-maximize-button),
  112. (-moz-gtk-csd-close-button) {
  113. /* window controls on the right */
  114. @media not (-moz-gtk-csd-reversed-placement) {
  115. #nav-bar {
  116. padding-inline: 0 calc(var(--uc-navbar-padding, 0) + var(--uc-win-ctrl-padding) + var(--uc-win-ctrl-drag-space)) !important;
  117. }
  118.  
  119. .titlebar-buttonbox-container {
  120. right: 0;
  121. }
  122. }
  123.  
  124. /* window controls on the left */
  125. @media (-moz-gtk-csd-reversed-placement) {
  126. #nav-bar {
  127. padding-inline: calc(var(--uc-navbar-padding, 0) + var(--uc-win-ctrl-padding) + var(--uc-win-ctrl-drag-space)) 0 !important;
  128. }
  129.  
  130. .titlebar-buttonbox-container {
  131. left: 0;
  132. }
  133. }
  134. }
  135.  
  136. /* Hide window buttons in fullscreen */
  137. #navigator-toolbox[style*="margin-top: -"] .titlebar-buttonbox-container,
  138. [inDOMFullscreen="true"] .titlebar-buttonbox-container {
  139. transform: translateY(-100px)
  140. }
  141.  
  142.  
  143. }
  144.  
  145. /* Windows specific styles */
  146. @media (-moz-platform: windows),
  147. (-moz-platform: windows-win10) {
  148. /* Hide main tabs toolbar */
  149. :root[tabsintitlebar]{
  150. --uc-window-control-width: 137px; /* Space at the right of nav-bar for window controls */
  151. /* --uc-window-drag-space-width: 24px; */ /* To add extra window drag space in nav-bar */
  152. }
  153.  
  154. #nav-bar{
  155. border-inline: var(--uc-window-drag-space-width,80px) solid var(--toolbar-bgcolor) ;
  156. border-inline-style: solid !important;
  157. border-right-width: calc(var(--uc-window-control-width,0px) + var(--uc-window-drag-space-width,0px));
  158.  
  159. padding-top: .5px !important; /* This makes it possible to drag the maximized window. */
  160. margin-left: -80px; /* Removes the space left when hiding .titlebar-buttonbox-container */
  161. }
  162.  
  163. #back-button {
  164. margin-top: -.5px !important;
  165. }
  166.  
  167. #forward-button {
  168. margin-top: -.5px !important;
  169. }
  170.  
  171. #reload-button {
  172. margin-top: -.5px !important;
  173. }
  174.  
  175. #PanelUI-button {
  176. margin-top: -.5px !important;
  177. }
  178.  
  179. #nav-bar-overflow-button{
  180. margin-top: -.5px !important;
  181. }
  182.  
  183. :root {
  184. --uc-toolbar-height: 32px;
  185. --chrome-content-separator-color: none !important;
  186. }
  187.  
  188. :root:not([uidensity="compact"]) {
  189. --uc-toolbar-height: 38px;
  190. }
  191.  
  192. #TabsToolbar {
  193. visibility: collapse !important;
  194. }
  195.  
  196. /* Hide the Windows controls on the left side. */
  197. #TabsToolbar .titlebar-buttonbox-container {
  198. visibility: hidden !important;
  199. }
  200. /* Line up the Windows controls with the rest of the icons in the toolbar. */
  201. :root:not([sizemode="maximized"]) .titlebar-buttonbox-container {
  202. margin-top: 3px;
  203. }
  204.  
  205.  
  206. :root:not([inFullscreen]) #nav-bar {
  207. margin-top: calc(0px - var(--uc-toolbar-height));
  208. z-index: 2;
  209. }
  210.  
  211. #toolbar-menubar {
  212. min-height: unset !important;
  213. height: var(--uc-toolbar-height) !important;
  214. position: relative;
  215. }
  216.  
  217. /* For a rounded button design, uncomment both lines in .titlebar-buttonbox. */
  218. .titlebar-buttonbox {
  219. z-index: 3 !important;
  220. /* padding-right:3px; */
  221. }
  222.  
  223. .titlebar-buttonbox * {
  224. /* border-radius: 5px; */
  225. width: 35px;
  226. height: 38px;
  227. pointer-events: auto;
  228. }
  229.  
  230. #titlebar {
  231. z-index: 3;
  232. pointer-events: none;
  233. }
  234.  
  235. #main-menubar {
  236. -moz-box-flex: 1;
  237. background-color: var(--toolbar-bgcolor,--toolbar-non-lwt-bgcolor);
  238. background-clip: padding-box;
  239. border-right: 30px solid transparent;
  240. border-image: linear-gradient(to left, transparent, var(--toolbar-bgcolor,--toolbar-non-lwt-bgcolor) 30px) 20 / 30px;
  241. }
  242.  
  243. #toolbar-menubar:not([inactive]) {
  244. z-index: 2;
  245. }
  246.  
  247. #toolbar-menubar[inactive] > #menubar-items {
  248. opacity: 0;
  249. pointer-events: none;
  250. margin-left: var(--uc-window-drag-space-width,0px);
  251. }
  252.  
  253. :root[inFullscreen] #nav-bar {
  254. border-right: none !important;
  255. }
  256. }
  257.  
  258.  
  259. /* General styles */
  260. #browser {
  261. position: relative;
  262. }
  263.  
  264. #nav-bar, #urlbar {
  265. z-index: 100;
  266. }
  267.  
  268. #sidebar-box:not([lwt-sidebar]){
  269. appearance: unset !important;
  270. }
  271.  
  272. #sidebar-box[sidebarcommand*="tabcenter"] {
  273. z-index: 1;
  274. }
  275.  
  276. #sidebar-box[sidebarcommand*="tabcenter"] #sidebar-header {
  277. visibility: collapse;
  278. display: none;
  279. }
  280.  
  281. #main-window:not([chromehidden~="toolbar"]) [sidebarcommand*="tabcenter"] #sidebar,
  282. #main-window:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:not([hidden="true"]) {
  283. display: block !important;
  284. min-width: 48px !important;
  285. max-width: 48px !important;
  286. width: 48px;
  287. }
  288.  
  289. #main-window:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:not([hidden]) {
  290. display: block;
  291. position: var(--positionX2);
  292. min-width: 48px;
  293. max-width: 48px;
  294. overflow: hidden;
  295. border-right: 1px solid var(--sidebar-border-color);
  296. z-index: 1;
  297. top: 0;
  298. bottom: 0;
  299. }
  300.  
  301. #main-window[inFullscreen]:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:not([hidden]):not(:hover) {
  302. min-width: var(--fullscreen-sidebar-width) !important;
  303. max-width: var(--fullscreen-sidebar-width) !important;
  304. }
  305.  
  306. #main-window:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:hover #sidebar,
  307. #main-window:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:hover {
  308. min-width: 10vw !important;
  309. width: 30vw !important;
  310. max-width: 200px !important;
  311. z-index: 1 !important;
  312. transition: all var(--transition-time) ease var(--delay);
  313. }
  314.  
  315. /* used for delay function */
  316. #sidebar-box[sidebarcommand*="tabcenter"]:not(:hover) #sidebar,
  317. #sidebar-box[sidebarcommand*="tabcenter"]:not(:hover) {
  318. transition: all var(--transition-time) ease 0s;
  319. }
  320.  
  321. @media (width >= 1200px) {
  322. #main-window:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:hover #sidebar,
  323. #main-window:not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:hover {
  324. max-width: 250px !important;
  325. }
  326. }
  327.  
  328. [sidebarcommand*="tabcenter"] ~ #sidebar-splitter {
  329. display: none;
  330. }
  331.  
  332. [sidebarcommand*="tabcenter"] #sidebar {
  333. max-height: 100%;
  334. height: 100%;
  335. }
  336.  
  337. #main-window:not([inFullscreen]):not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:not([hidden]) ~ #appcontent {
  338. margin-left: var(--positionX1);
  339. }
  340.  
  341. #main-window[inFullscreen]:not([inDOMFullscreen]):not([chromehidden~="toolbar"]) #sidebar-box[sidebarcommand*="tabcenter"]:not([hidden]) ~ #appcontent {
  342. margin-left: var(--fullscreen-sidebar-width);
  343. }
  344.  
  345. #main-window[inFullscreen] #sidebar {
  346. height: 100vh;
  347. }
  348.  
  349. [sidebarcommand*="tabcenter"] #sidebar-header {
  350. background: #0C0C0D;
  351. border-bottom: none !important;
  352. }
  353.  
  354. [sidebarcommand*="tabcenter"] ~ #sidebar-splitter {
  355. border-right-color: #0C0C0D !important;
  356. border-left-color: #0C0C0D !important;
  357. }
  358.  
  359. [sidebarcommand*="tabcenter"] #sidebar-switcher-target,
  360. [sidebarcommand*="tabcenter"] #sidebar-close {
  361. filter: invert(100%);
  362. }
  363.  
  364. @media (max-width: 630px) {
  365. #urlbar-container {
  366. min-width: 100% !important;
  367. }
  368.  
  369. #menubar-items {
  370. display: none !important;
  371. }
  372. }
  373.  
  374. /* Up the z-index of the top bar so that the bookmarks toolbar is above the sidebar. */
  375. #navigator-toolbox {
  376. z-index: 2 !important;
  377. }
  378.  
  379. /* Hide the bookmark star button in the search bar */
  380. #star-button-box {
  381. display: none !important;
  382. }
  383.  
Add Comment
Please, Sign In to add comment