Advertisement
Guest User

Untitled

a guest
Feb 7th, 2025
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 15.09 KB | None | 0 0
  1. /* stops flash of white when new tab https://old.reddit.com/r/firefox/comments/177vdm5/firefox_flashed_white_pages_every_time_i_click_on/k4wb8lh/ */
  2. body,
  3. html,
  4. .browserContainer,
  5. #mainPopupSet,
  6. #main-window,
  7. #tabbrowser-tabbox,
  8. #tabbrowser-tabpanels {
  9. background-color: #141414 !important;
  10. }
  11.  
  12.  
  13. /* Firefox Quantum userChrome.css tweaks ************************************************/
  14. /* Github: https://github.com/aris-t2/customcssforfx ************************************/
  15. /****************************************************************************************/
  16.  
  17.  
  18. @import "./tabs_below_navigation_toolbar.css";
  19.  
  20.  
  21. /* space above tabs toolbar */
  22. #main-window[tabsintitlebar][sizemode="maximized"] * #titlebar {
  23. margin-top: -8px !important;
  24. }
  25.  
  26. /* space for menubar above navigation toolbar (Firefox titlebar) */
  27. #main-window[tabsintitlebar]:not([sizemode="fullscreen"]) #nav-bar {
  28. margin-top: 26px !important;
  29. }
  30. #main-window[tabsintitlebar][sizemode="maximized"]:not([sizemode="fullscreen"]) #nav-bar {
  31. margin-top: 26px !important;
  32. }
  33.  
  34. /* add 'drag' feature to space above navigation toolbar */
  35. #main-window[tabsintitlebar] #navigator-toolbox,
  36. #main-window[tabsintitlebar] #nav-bar {
  37. -moz-window-dragging: drag !important;
  38. }
  39.  
  40. /* move menubar to the top and extend its with to full window width */
  41. #toolbar-menubar {
  42. position: fixed !important;
  43.  
  44. width: 100vw !important;
  45. -moz-window-dragging: drag !important;
  46. }
  47.  
  48. /* move menubars / tab toolbars caption buttons to windows top right position */
  49. #main-window[tabsintitlebar]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container {
  50. position: fixed !important;
  51. right: 0 !important;
  52. visibility: visible !important;
  53. display: block !important;
  54. }
  55.  
  56. /* menubar postion after moving to the top */
  57. #toolbar-menubar {
  58. top: 0px !important;
  59. }
  60.  
  61. /* Linux/macOS */
  62. /* space above navigation toolbar (OS titlebar) */
  63. /* set to '0', if no menubar is used */
  64. #main-window:not([tabsintitlebar]):not([sizemode="fullscreen"]) #nav-bar {
  65. margin-top: 28px !important;
  66. }
  67.  
  68. /* menubar postion in maximized mode after moving to the top */
  69. #main-window[tabsintitlebar][sizemode="maximized"] #toolbar-menubar {
  70. top: 0px !important;
  71. }
  72.  
  73. /* caption button position in maximized mode after moving to the top */
  74. #main-window[tabsintitlebar]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container,
  75. #main-window[tabsintitlebar][sizemode="maximized"]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container {
  76. top: 0px !important; /* used to be -14*/
  77. }
  78.  
  79. /* Windows */
  80. @media (-moz-os-version:windows-win10), (-moz-os-version:windows-win8), (-moz-os-version:windows-win7) {
  81. /* set to '0', if no menubar is used */
  82. #main-window:not([tabsintitlebar]):not([sizemode="fullscreen"]) #nav-bar {
  83. margin-top: 18px !important;
  84. }
  85. /* set to '2', if no menubar is used */
  86. #main-window[tabsintitlebar][sizemode="maximized"]:not([sizemode="fullscreen"]) #nav-bar {
  87. margin-top: 34px !important;
  88. }
  89. #main-window[tabsintitlebar][sizemode="maximized"] #toolbar-menubar {
  90. top: 5px !important;
  91. }
  92. #main-window[tabsintitlebar]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container {
  93. top: 0px !important;
  94. }
  95. #main-window[tabsintitlebar][sizemode="maximized"]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container {
  96. top: 5px !important;
  97. }
  98. }
  99.  
  100. /* hide line above navigation toolbar appearing in some cases */
  101. #main-window:not([tabsintitlebar]) #nav-bar,
  102. #main-window:not([tabsintitlebar]) #navigator-toolbox {
  103. border-top: 0 !important;
  104. box-shadow: unset !important;
  105. }
  106.  
  107. /* force buttons on menubar being very small to not break the toolbar */
  108. #toolbar-menubar toolbaritem > toolbarbutton .toolbarbutton-icon,
  109. #toolbar-menubar > toolbarpaletteitem toolbarbutton .toolbarbutton-icon,
  110. #toolbar-menubar > toolbarbutton .toolbarbutton-icon {
  111. padding: 0px 0px !important;
  112. height: 16px !important;
  113. width: 16px !important;
  114. }
  115. #toolbar-menubar toolbaritem > toolbarbutton,
  116. #toolbar-menubar > toolbarpaletteitem toolbarbutton,
  117. #toolbar-menubar > toolbarbutton {
  118. position: relative !important;
  119. padding: 0px 0px !important;
  120. margin: 0px 0px !important;
  121. }
  122. #toolbar-menubar toolbaritem > toolbarbutton .toolbarbutton-icon,
  123. #TabsToolbar-customization-target > toolbarpaletteitem toolbarbutton .toolbarbutton-icon,
  124. #TabsToolbar-customization-target > toolbarbutton .toolbarbutton-icon {
  125. padding: unset !important;
  126. height: unset !important;
  127. width: unset !important;
  128. }
  129.  
  130. /* make sure button icon colors set correctly */
  131. #main-window:not(:-moz-lwtheme) #TabsToolbar-customization-target toolbarbutton .toolbarbutton-icon,
  132. #main-window:not([style*='--lwt-header-image']):-moz-lwtheme:-moz-lwtheme-darktext #TabsToolbar-customization-target toolbarbutton .toolbarbutton-icon {
  133. fill: var(--classic_squared_tabs_new_tab_icon_color) !important;
  134. color: var(--classic_squared_tabs_new_tab_icon_color) !important;
  135. }
  136.  
  137. /* tweaks for fullscreen mode */
  138. #main-window[tabsintitlebar][sizemode="fullscreen"] * #TabsToolbar {
  139. -moz-padding-start: 0px !important;
  140. }
  141. /* tweaks for fullscreen mode */
  142. #main-window[tabsintitlebar][sizemode="fullscreen"]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container,
  143. #main-window[tabsintitlebar][sizemode="fullscreen"] #toolbar-menubar[autohide="true"] ~ #TabsToolbar .titlebar-buttonbox-container,
  144. #main-window[tabsintitlebar][sizemode="fullscreen"] #navigator-toolbox #PanelUI-button,
  145. #main-window #TabsToolbar #window-controls {
  146. display: none !important;
  147. }
  148.  
  149. /* hide non-required items */
  150. #TabsToolbar #window-controls,
  151. #TabsToolbar *[type="caption-buttons"],
  152. #TabsToolbar *[type="pre-tabs"],
  153. #TabsToolbar *[type="post-tabs"] {
  154. display: none !important;
  155. }
  156.  
  157. /* Windows 7 extra tweaks */
  158. @media (-moz-os-version: windows-win7) {
  159. @media all and (-moz-windows-compositor) {
  160. #main-window[tabsintitlebar]:not([inDOMFullscreen="true"]) * .titlebar-buttonbox-container {
  161. display: none !important;
  162. }
  163. }
  164. @media not all and (-moz-windows-compositor) {
  165. #main-window[tabsintitlebar]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container {
  166. top: -8px !important;
  167. }
  168. #main-window[tabsintitlebar][sizemode="maximized"]:not([inDOMFullscreen="true"]) .titlebar-buttonbox-container {
  169. top: 0px !important;
  170. }
  171. }
  172. }
  173.  
  174. /* Windows 10 extra tweaks */
  175. @media (-moz-os-version: windows-win10) {
  176. #main-window:not([tabsintitlebar]) menubar > menu:not(:-moz-lwtheme):hover:not([disabled="true"]),
  177. #main-window:not([tabsintitlebar]) menubar > menu:not(:-moz-lwtheme)[_moz-menuactive="true"]:not([disabled="true"]) {
  178. background-color: Highlight !important;
  179. color: HighlightText !important;
  180. }
  181. }
  182.  
  183. /* disable Mozillas tab jumping nonsense when moving tabs */
  184. #navigator-toolbox[movingtab] > #titlebar > #TabsToolbar {
  185. padding-bottom: unset !important;
  186. }
  187. #navigator-toolbox[movingtab] #tabbrowser-tabs {
  188. padding-bottom: unset !important;
  189. margin-bottom: unset !important;
  190. }
  191. #navigator-toolbox[movingtab] > #nav-bar {
  192. margin-top: unset !important;
  193. }
  194.  
  195.  
  196. /* remove 'dragging tab' margin/padding nonsense */
  197. #TabsToolbar[movingtab] {
  198. padding-bottom: unset !important;
  199. }
  200.  
  201. #TabsToolbar[movingtab] + #nav-bar {
  202. margin-top: unset !important;
  203. }
  204.  
  205. /* tabs bottom end? */
  206.  
  207. /* remove blue line on current tab */
  208. #TabsToolbar .tabbrowser-tab[selected] .tab-line {
  209. display: none !important;
  210. }
  211.  
  212. /* remove line on hover above tabs */
  213. #TabsToolbar .tabbrowser-tab .tab-line {
  214. display: none !important;
  215. }
  216.  
  217. /* removes X sign on tabs */
  218. .tab-close-button
  219. {
  220. display: none !important
  221. }
  222.  
  223. /* remove New Tab button */
  224. .tabs-newtab-button {
  225. display:none !important;
  226. }
  227.  
  228. /* remove search magnifying glass */
  229.  
  230. .searchbar-search-button > .searchbar-search-icon
  231. {
  232. display: none !important;
  233. }
  234.  
  235. /* magnifying glass url */
  236.  
  237. #urlbar[pageproxystate="invalid"] > #identity-box > #identity-icon {
  238. display: none !important;
  239. }
  240. /* remove placeholder text */
  241. .searchbar-textbox::placeholder,#urlbar-input::placeholder { opacity: 0 !important; }
  242.  
  243. /* move searchbar text to the right */
  244. .searchbar-textbox, .textbox-input
  245. {
  246. padding-left: 16px !important;
  247. }
  248. /* remove blue loading flash */
  249. .tab-loading-burst{
  250. display: none !important;
  251. }
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258. /* remove ping pong dot loading tab icon */
  259. .tab-throbber[busy]::before {
  260. background-image: url("chrome://global/skin/icons/loading.png") !important;
  261. animation: unset !important;
  262. }
  263. .tab-throbber[busy]:not([progress])::before {
  264. /* Grays the blue during "Connecting" state */
  265. filter: grayscale(100%);
  266. }
  267. @media (min-resolution: 2dppx) {
  268. .tab-throbber[busy]::before {
  269. background-image: url("chrome://global/skin/icons/[email protected]") !important;
  270. }
  271. }
  272.  
  273. @media (-moz-windows-accent-color-in-titlebar){
  274. :root[tabsintitlebar]:-moz-lwtheme:not(:-moz-window-inactive){
  275. background-color: var(--lwt-accent-color) !important;
  276. color: var(--lwt-text-color) !important;
  277. }
  278. }
  279.  
  280. /* removes url/adress bar forward go button */
  281. .urlbar-go-button, #urlbar-go-button
  282. {
  283. display:none !important;
  284. }
  285.  
  286. /* remove forward go button from search bar */
  287. .search-go-container
  288. {
  289. display:none !important;
  290. }
  291.  
  292. /* search popdown*/
  293. #PopupSearchAutoComplete{ --panel-background: #2a2a2a !important; }
  294.  
  295.  
  296.  
  297.  
  298.  
  299. /* remove New Tab button */
  300. #tabs-newtab-button {
  301. display:none !important;
  302. }
  303.  
  304. /* URL BUTTONS DISPLAY NONE HERE MULTIPLE */
  305. #pageActionButton
  306. {
  307. display: none !important;
  308. }
  309.  
  310. #pageAction-urlbar-jid1-xufzosoflzsoxg_jetpack
  311. {
  312. display: none !important;
  313. }
  314.  
  315. #pageAction-urlbar-brief_mozdev_org
  316. {
  317. display: none !important;
  318. }
  319.  
  320. #star-button
  321. {
  322. display: none !important;
  323. }
  324.  
  325. #pocket-button
  326. {
  327. display: none !important;
  328. }
  329.  
  330. #pageActionSeparator
  331. {
  332. display: none !important;
  333. }
  334.  
  335. /* */
  336.  
  337. /* Remove Hambuger button */
  338. #PanelUI-menu-button
  339. {
  340. display:none !important
  341. }
  342.  
  343.  
  344. /* remove forward button */
  345. #forward-button{
  346. display: none !important;
  347. }
  348.  
  349. /* Title bar on hover only */
  350. .titlebar-buttonbox {
  351. opacity: 0 !important; }
  352.  
  353. .titlebar-buttonbox:hover {
  354. opacity: 1 !important; }
  355.  
  356.  
  357.  
  358.  
  359.  
  360.  
  361.  
  362.  
  363. /* Flip the position of the icons in the identity box */
  364. #identity-box { direction: rtl; }
  365.  
  366. /* Hide info icon for sites that don't have permissions */
  367. #urlbar :not(.grantedPermissions) #identity-icon {
  368. visibility: collapse !important;
  369. transition: 300ms !important; /* Animate icon hiding */
  370. opacity: 0 !important; /* Make icons transparent */
  371. -moz-margin-end: -1.1em !important; /* Hide icons by offsetting them */
  372. }
  373.  
  374. /* Show info icon on identity-box hover */
  375. #identity-box:hover #identity-icon {
  376. visibility: visible !important;
  377. transition: 300ms !important; /* Animate icon showing */
  378. opacity: 1 !important; /* Make icons opaque */
  379. -moz-margin-end: initial !important; /* Use initial margins to show icons */
  380. }
  381.  
  382. /* background color search */
  383. .searchbar-textbox
  384. {
  385. background-color: #2a2a2a !important;
  386. }
  387.  
  388. /* background color url */
  389. #urlbar-background
  390. {
  391. background-color: #2a2a2a !important;
  392. }
  393.  
  394. /* Translate language button */
  395. #pageAction-urlbar-_036a55b4-5e72-4d05-a06c-cba2dfcc134a_
  396. {
  397. display:none !important;
  398. }
  399.  
  400. /* changes color of current tab */
  401. .tab-background[selected="true"] {
  402. background-attachment: none !important;
  403. background-color: #414146 !important;
  404. background-image: none !important;
  405. background-position: none !important;
  406. background-repeat: none !important;
  407. background-size: none !important;
  408. }
  409.  
  410.  
  411. /* removes blue border url bar */
  412. #urlbar[focused="true"] > #urlbar-background{
  413. border:none !important;
  414. outline:none !important;
  415.  
  416. }
  417.  
  418. /* removes blue border search bar */
  419. #searchbar:focus-within{
  420. border:none !important;
  421. outline:none !important;
  422.  
  423. }
  424.  
  425.  
  426. /* remove google search display and change search settings */
  427. .search-one-offs > .search-setting-button,
  428. #PopupSearchAutoComplete > .search-panel-header{ display: none }
  429.  
  430.  
  431. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/compact_urlbar_megabar.css made available under Mozilla Public License v. 2.0
  432. See the above repository for updates as well as full license text. */
  433.  
  434.  
  435.  
  436.  
  437. #urlbar[breakout]:not([open]){ bottom: calc((var(--urlbar-toolbar-height) - var(--urlbar-height)) / 2) !important; }
  438. .urlbarView{ margin-inline: 0 !important; width: auto !important; }
  439. .urlbarView-row{ padding: 0 2px !important; }
  440. .urlbarView-row-inner{ padding-inline-start: 4px !important; }
  441. #urlbar-background{ animation: none !important; }
  442. #urlbar-input-container{ padding: 0 !important; height: 100% !important; }
  443. #identity-box{ padding-block: var(--urlbar-icon-padding) }
  444. .urlbarView > .search-one-offs:not([hidden]){ padding-block: 0px !important; }
  445.  
  446.  
  447.  
  448.  
  449. /* Remove firefox suggest */
  450. .urlbarView-row[label="Firefox Suggest"]::before{ display: none !important; }
  451. .urlbarView-row[label="Firefox Suggest"]{ margin-top: 0 !important; }
  452.  
  453.  
  454. toolbarbutton#alltabs-button.toolbarbutton-1.chromeclass-toolbar-additional.tabs-alltabs-button
  455. {
  456. display:none !important;
  457. }
  458.  
  459. #private-browsing-indicator-with-label > label:nth-child(2)
  460. {
  461. display:none !important;
  462. }
  463.  
  464.  
  465.  
  466.  
  467.  
  468.  
  469. #nav-bar-customization-target
  470. {
  471. background-color:#1c1b22 !important;
  472. }
  473.  
  474. hbox.titlebar-spacer
  475. {
  476. display:none !important;
  477. }
  478.  
  479. hbox.titlebar-spacer {
  480. width: 0 !important;
  481. }
  482.  
  483.  
  484. #navigator-toolbox {
  485. border-bottom: 0px !important; /*https://old.reddit.com/r/FirefoxCSS/comments/1fv6mfe/any_way_to_remove_this_line_below_the_tabs_showed/ */
  486. }
  487.  
  488.  
  489.  
  490.  
  491. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/tabs_on_bottom_v2.css made available under Mozilla Public License v. 2.0
  492. See the above repository for updates as well as full license text. */
  493.  
  494. /* This reorders toolbar to place tabs below other toolbars. Requires Firefox 133+ */
  495.  
  496. @media (-moz-bool-pref: "userchrome.force-window-controls-on-left.enabled"){
  497. #nav-bar > .titlebar-buttonbox-container{
  498. order: -1 !important;
  499. > .titlebar-buttonbox{
  500. flex-direction: row-reverse;
  501. }
  502. }
  503. }
  504. @media not (-moz-bool-pref: "sidebar.verticalTabs"){
  505. .global-notificationbox,
  506. #tab-notification-deck,
  507. #TabsToolbar{
  508. order: 1;
  509. }
  510. #TabsToolbar > :is(.titlebar-spacer,.titlebar-buttonbox-container){
  511. display: none;
  512. }
  513. :root[sizemode="fullscreen"] #nav-bar > .titlebar-buttonbox-container{
  514. display: flex !important;
  515. }
  516. :root:is([tabsintitlebar],[customtitlebar]) #toolbar-menubar:not([autohide="false"]) ~ #nav-bar{
  517. > .titlebar-buttonbox-container{
  518. display: flex !important;
  519. }
  520. :root[sizemode="normal"] & {
  521. > .titlebar-spacer{
  522. display: flex !important;
  523. }
  524. }
  525. :root[sizemode="maximized"] & {
  526. > .titlebar-spacer[type="post-tabs"]{
  527. display: flex !important;
  528. }
  529. @media (-moz-bool-pref: "userchrome.force-window-controls-on-left.enabled"),
  530. (-moz-gtk-csd-reversed-placement),
  531. (-moz-platform: macos){
  532. > .titlebar-spacer[type="post-tabs"]{
  533. display: none !important;
  534. }
  535. > .titlebar-spacer[type="pre-tabs"]{
  536. display: flex !important;
  537. }
  538. }
  539. }
  540. }
  541. }
  542.  
  543. .private-browsing-indicator-label
  544. {
  545. display: none !important;
  546. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement