Siriusmart

userChrome.css

May 30th, 2022
1,211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 7.33 KB | None | 0 0
  1. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/navbar_tabs_oneliner.css made available under Mozilla Public License v. 2.0
  2. See the above repository for updates as well as full license text. */
  3.  
  4. /* Make tabs and navbar appear side-by-side tabs on right */
  5.  
  6. /* Use page_action_buttons_on_hover.css to hide page-action-buttons to save more space for the address */
  7.  
  8. /*
  9. urlbar_popup_full_width.css is VERY MUCH recommended for Firefox 71+ because of new urlbar popup
  10. */
  11.  
  12. :root[uidensity="compact"]{
  13.   --tab-block-margin: 2px !important;
  14. }
  15.  
  16. /* Modify these to change relative widths or default height */
  17. #navigator-toolbox{
  18.   --uc-navigationbar-width: 50vw;
  19.   --uc-toolbar-height: 40px;
  20.   --uc-urlbar-min-width: 30vw; /* minimum width for opened urlbar */
  21. }
  22.  
  23. #scrollbutton-up,
  24. #scrollbutton-down{ border-block-width: 2px !important; }
  25.  
  26. /* Override for other densities */
  27. :root[uidensity="compact"] #navigator-toolbox{ --uc-toolbar-height: 34px; }
  28. :root[uidensity="touch"] #navigator-toolbox{ --uc-toolbar-height: 44px; }
  29.  
  30. /* prevent urlbar overflow on narrow windows */
  31. /* Dependent on how many items are in navigation toolbar ADJUST AS NEEDED */
  32. @media screen and (max-width: 1500px){
  33.   #urlbar-container{ min-width:unset !important }
  34. }
  35.  
  36. #TabsToolbar{
  37.   margin-left: var(--uc-navigationbar-width);
  38.   --tabs-navbar-shadow-size: 0px;
  39. }
  40. #tabbrowser-tabs{
  41.   --tab-min-height: calc(var(--uc-toolbar-height) - 2 * var(--tab-block-margin,0px)) !important;
  42. }
  43.  
  44. /* This isn't useful when tabs start in the middle of the window */
  45.  
  46. .titlebar-spacer[type="pre-tabs"]{ display: none }
  47.  
  48. #navigator-toolbox > #nav-bar{
  49.   margin-right:calc(100vw - var(--uc-navigationbar-width));
  50.   margin-top: calc(0px - var(--uc-toolbar-height));
  51. }
  52.  
  53. /* Window drag space  */
  54. :root[tabsintitlebar="true"] #nav-bar{ padding-left: 24px !important }
  55.  
  56. /* Rules specific to window controls on right layout */
  57. @supports -moz-bool-pref("layout.css.osx-font-smoothing.enabled"){
  58.   .titlebar-buttonbox-container{ position: fixed; display: block; left: 0px; z-index: 3; }
  59.   :root[tabsintitlebar="true"] #nav-bar{ padding-left: 96px !important; padding-right: 0px !important; }
  60. }
  61.  
  62. /* 1px margin on touch density causes tabs to be too high */
  63. .tab-close-button{ margin-top: 0 !important }
  64.  
  65. /* Make opened urlbar overlay the toolbar */
  66. #urlbar[open]:focus-within{ min-width: var(--uc-urlbar-min-width,none) !important; }
  67.  
  68. /* Hide dropdown placeholder */
  69. #urlbar-container:not(:hover) .urlbar-history-dropmarker{ margin-inline-start: -28px; }
  70.  
  71. /* Fix customization view */
  72. #customization-panelWrapper > .panel-arrowbox > .panel-arrow{ margin-inline-end: initial !important; }
  73.  
  74.  
  75.  
  76.  
  77.  
  78.  
  79.  
  80. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/vertical_bookmarks_toolbar.css made available under Mozilla Public License v. 2.0
  81. See the above repository for updates as well as full license text. */
  82.  
  83. /* Makes bookmarks toolbar appear vertically at the left side of the window */
  84.  
  85. @-moz-document url(chrome://browser/content/browser.xhtml){
  86.  
  87.   :root:not([inDOMFullscreen]){
  88.     --uc-vertical-toolbar-width: 40px;
  89.   }
  90.  
  91.   #PersonalToolbar{
  92.     position: fixed;
  93.     display: flex;
  94.     flex-direction: column;
  95.     left: 0;
  96.     width: var(--uc-vertical-toolbar-width,0);
  97.    
  98.     /* These create a empty area to the bottom of the toolbar, which is to mask a fact that we don't know exactly how high the toolbar should be */
  99.     height: 100vh;
  100.     max-height: 100vh !important;
  101.     padding-bottom: 120px !important;
  102.   }
  103.  
  104.   #personal-bookmarks{ overflow-y: auto; scrollbar-width: none;}
  105.  
  106.   #PersonalToolbar >  #personal-bookmarks > #PlacesToolbar > hbox{ -moz-box-orient: vertical !important; }
  107.   #PersonalToolbar #PlacesToolbarItems{
  108.     display: flex;
  109.     flex-direction: column;
  110.   }
  111.   #PersonalToolbar .toolbarbutton-1{ padding-block: 10px !important }
  112.   #PersonalToolbar #PlacesToolbarItems > .bookmark-item{ padding-block: 4px !important; }
  113.  
  114.  
  115.   body > #browser,
  116.   body > #browser-bottombox,
  117.   #customization-container{
  118.     margin-left: var(--uc-vertical-toolbar-width,0);
  119.   }
  120.  
  121. }
  122.  
  123.  
  124. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/tab_close_button_always_on_hover.css made available under Mozilla Public License v. 2.0
  125. See the above repository for updates as well as full license text. */
  126.  
  127. /* Always show tab close button on hover and never otherwise */
  128. .tabbrowser-tab .tab-close-button{
  129.   display:none;
  130. }
  131. .tabbrowser-tab:not([pinned]):hover .tab-close-button{
  132.   display:-moz-box !important;
  133. }
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/minimal_text_fields.css made available under Mozilla Public License v. 2.0
  141. See the above repository for updates as well as full license text. */
  142.  
  143. :root:not([customizing]){
  144.   --toolbar-field-background-color: transparent !important;
  145.   --toolbar-field-border-color: transparent !important;
  146. }
  147.  
  148. #urlbar[open]{ background-color: var(--toolbar-bgcolor) !important; }
  149.  
  150. #urlbar,
  151. #searchbar,
  152. #search-box{
  153.   -moz-appearance: none !important;
  154.   background-color: var(--toolbar-field-background-color) !important;
  155.   color: inherit !important;
  156. }
  157.  
  158. #searchbar,
  159. #urlbar,
  160. .searchbar-textbox{
  161.   box-shadow: none !important;
  162. }
  163.  
  164. #tracking-protection-icon-container,
  165. #identity-box ~ *,
  166. .searchbar-textbox > *{
  167.   opacity: 0;
  168.   transition: opacity 150ms linear
  169. }
  170.  
  171. #urlbar .urlbar-input-box,
  172. .searchbar-textbox > moz-input-box{ opacity: 0.6 }
  173.  
  174. #identity-box ~ *:hover,
  175. #tracking-protection-icon-container:hover,
  176. #tracking-protection-icon-container ~ *:hover,
  177. #urlbar:focus-within > *,
  178. #urlbar-input-container:focus-within > *,
  179. .searchbar-textbox:hover > *,
  180. .searchbar-textbox:focus-within > *{ opacity: 1 }
  181.  
  182. #identity-box{ border: none !important }
  183.  
  184. /* #urlbar:not(:hover) #identity-box{ background-image: radial-gradient(closest-side circle at 16px, orange 10%,transparent 35% ); } */
  185. #urlbar:not(:hover) #identity-box.verifiedIdentity{ background-image: radial-gradient(closest-side circle at 16px, lime 10%,transparent 35% ); }
  186. #urlbar:not(:hover) #identity-box > *{ opacity: 0 }
  187. /*
  188. :root[title="Firefox Nightly"] #identity-box,
  189. :root[title="Mozilla Firefox"] #identity-box,
  190. */
  191. #urlbar[pageproxystate=invalid]:not([usertyping]) #identity-box,
  192. #identity-box:hover,
  193. #identity-box.chromeUI,
  194. #identity-box.verifiedDomain{
  195.   background-image: none !important;
  196. }
  197.  
  198. #identity-box > #identity-icon-labels{ transition: max-width 150ms linear !important; }
  199. #identity-box:not(:hover) > #identity-icon-labels{ max-width: 0px !important; }
  200.  
  201.  
  202.  
  203.  
  204.  
  205. /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/tab_separator_lines.css made available under Mozilla Public License v. 2.0
  206. See the above repository for updates as well as full license text. */
  207.  
  208. /* Bring back tab separator lines that were removed in Proton */
  209.  
  210. .tabbrowser-tab{
  211.   border-inline-end: 1px solid transparent !important;
  212.   border-image: 0 1 linear-gradient(
  213.     transparent 20%,
  214.     color-mix(in srgb, currentColor 20%, transparent) 20%,
  215.     color-mix(in srgb, currentColor 20%, transparent) 80%,
  216.     transparent 80%
  217.   );
  218. }
  219.  
  220. .tabbrowser-tab:hover,
  221. .tabbrowser-tab[beforehovered],
  222. .tabbrowser-tab[selected],
  223. .tabbrowser-tab[last-visible-tab],
  224. .tabbrowser-tab[beforeselected-visible]{ border-image: none !important; }
  225.  
Advertisement
Add Comment
Please, Sign In to add comment