Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/hide_tabs_toolbar_osx.css made available under Mozilla Public License v. 2.0
- See the above repository for updates as well as full license text. */
- /* Hides tabs toolbar - OSX only */
- /* IMPORTANT */
- /*
- Get window_control_placeholder_support.css
- Window controls will be all wrong without it
- */
- :root{ --uc-toolbar-height: 32px; }
- :root:not([uidensity="compact"]){ --uc-toolbar-height: 34px }
- #TabsToolbar > *{ visibility: collapse !important }
- #TabsToolbar > .titlebar-buttonbox-container{
- visibility: visible !important;
- height:var(--uc-toolbar-height) !important;
- }
- #nav-bar{
- margin-top: calc(0px - var(--uc-toolbar-height));
- }
- :root[inFullscreen] #navigator-toolbox{ margin-top: 11px }
- /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/autohide_tabstoolbar_v2.css made available under Mozilla Public License v. 2.0
- See the above repository for updates as well as full license text. */
- /* Requires Firefox 133 */
- :root{
- --uc-tabs-hide-animation-duration: 48ms;
- --uc-tabs-hide-animation-delay: 48ms;
- }
- @media (-moz-bool-pref: "sidebar.verticalTabs"),
- -moz-pref("sidebar.verticalTabs"){
- #sidebar-main{
- overflow: visible !important;
- max-width: var(--tab-collapsed-width) !important;
- z-index: var(--browser-area-z-index-toolbox-while-animating);
- transition: z-index 0s linear var(--uc-tabs-hide-duration);
- background: inherit;
- }
- sidebar-main{
- --tab-pinned-horizontal-count: 5; /* This needs to match whatever is used in sidebar-main.css - currently 5 */
- background: inherit;
- overflow: hidden;
- min-width: var(--tab-collapsed-width);
- transition: min-width var(--uc-tabs-hide-animation-duration) ease-out var(--uc-tabs-hide-animation-delay);
- border-inline: 0.01px solid var(--chrome-content-separator-color);
- border-inline-width: 0 0.01px;
- &[positionend]{
- transition-property: min-width, transform;
- border-inline-width: 0.01px 0;
- }
- }
- sidebar-main:hover{
- min-width: calc(var(--tab-pinned-horizontal-count) * var(--tab-pinned-min-width-expanded) + 2 * var(--tab-pinned-container-margin-inline-expanded) + 1px);
- transition-delay: 0ms !important;
- &[positionend]{
- transform: translateX(calc(var(--tab-collapsed-width) - 100%));
- }
- }
- }
- @media not (-moz-bool-pref: "sidebar.verticalTabs"),
- not -moz-pref("sidebar.verticalTabs"){
- :root:not([customizing],[chromehidden~="menubar"]) #navigator-toolbox:hover,
- :root:not([customizing],[chromehidden~="menubar"]) #TabsToolbar{
- margin-bottom: calc(0px - 2 * var(--tab-block-margin) - var(--tab-min-height));
- }
- #navigator-toolbox{
- transition: margin-bottom var(--uc-tabs-hide-animation-duration) ease-out var(--uc-tabs-hide-animation-delay) !important;
- --browser-area-z-index-toolbox: 3;
- }
- #TabsToolbar:not([customizing]){
- visibility: hidden;
- transition: visibility 0ms linear var(--uc-tabs-hide-animation-delay),
- margin-bottom var(--uc-tabs-hide-animation-duration) ease-out var(--uc-tabs-hide-animation-delay) !important;
- }
- #navigator-toolbox:is(:hover,[movingtab]){
- transition-delay: 0s !important;
- > #TabsToolbar{
- visibility: visible;
- margin-bottom: 0px;
- transition-delay: 18ms, 0ms !important;
- }
- }
- @media (-moz-bool-pref: "userchrome.autohidetabs.show-while-inactive.enabled"),
- -moz-pref("userchrome.autohidetabs.show-while-inactive.enabled"){
- #navigator-toolbox:-moz-window-inactive{
- margin-bottom: calc(0px - 2 * var(--tab-block-margin) - var(--tab-min-height));
- > #TabsToolbar{
- visibility: visible;
- margin-bottom: 0px;
- }
- }
- }
- /* These rules make sure that height of tabs toolbar doesn't exceed tab-min-height */
- #tabbrowser-tabs:not([secondarytext-unsupported]) .tab-label-container{
- max-height: var(--tab-min-height);
- }
- .tab-label{ line-height: 20px !important; }
- :root[uidensity="compact"] .tab-label{ line-height: 18px !important; }
- }
- /* Hide sidebar */
- /* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/autohide_sidebar.css made available under Mozilla Public License v. 2.0
- See the above repository for updates as well as full license text. */
- /* Show sidebar only when the cursor is over it.
- The border controlling sidebar width will be removed so you'll need to modify
- these values to change width.
- By default the internal layout of sidebar changes when hovered, but this can
- be changed by setting pref "userchrome.autohide-sidebar.static-layout.enabled" to true
- */
- /* Note: If you want only *some* sidebar to be auto-hidden, then you can use [sidebarcommand] attribute selector.
- For example, to only affect Sidebery's sidebar replace all instances of #sidebar-box with
- #sidebar-box[sidebarcommand="_3c078156-979c-498b-8990-85f7987dd929_-sidebar-action"].
- To find the sidebarcommand value for any other sidebar, open that sidebar and use Browser Toolbox to inspect it.
- See: https://firefox-source-docs.mozilla.org/devtools-user/browser_toolbox/index.html
- */
- :where(#main-window) #browser{
- --uc-sidebar-width: 5px;
- --uc-sidebar-hover-width: 350px;
- }
- #main-window[sizemode="fullscreen"] #browser{
- --uc-sidebar-width: 1px;
- }
- #sidebar-box{
- --uc-autohide-sidebar-delay: 100ms; /* Wait 0.1s before hiding sidebar */
- --uc-autohide-transition-duration: 30ms;
- --uc-autohide-transition-type: linear;
- --browser-area-z-index-sidebar: 3;
- position: relative;
- min-width: var(--uc-sidebar-width) !important;
- width: var(--uc-sidebar-width) !important;
- max-width: var(--uc-sidebar-width) !important;
- z-index: var(--browser-area-z-index-sidebar,3);
- background-color: inherit;
- /* This directionality flipper is played so that sidebar "grows" into the right direction */
- direction: ltr;
- &:is([positionend],[sidebar-positionend]):not(:-moz-locale-dir(rtl)){
- direction: rtl;
- }
- }
- .sidebar-browser-stack{
- background: inherit;
- }
- #main-window[sizemode="fullscreen"] #browser{ --uc-sidebar-width: 1px; }
- #sidebar-splitter{ display: none }
- #sidebar-header{
- overflow: hidden;
- color: var(--chrome-color, inherit) !important;
- padding-inline: 0 !important;
- }
- #sidebar-header::before,
- #sidebar-header::after{
- content: "";
- display: flex;
- padding-left: 8px;
- }
- #sidebar-header,
- #sidebar{
- transition: min-width var(--uc-autohide-transition-duration) var(--uc-autohide-transition-type) var(--uc-autohide-sidebar-delay) !important;
- min-width: var(--uc-sidebar-width) !important;
- will-change: min-width;
- direction: ltr;
- &:-moz-locale-dir(rtl){
- direction: rtl;
- }
- }
- #sidebar-box:hover > #sidebar-header,
- #sidebar-box:hover > #sidebar,
- #sidebar-box:hover > .sidebar-browser-stack > #sidebar{
- min-width: var(--uc-sidebar-hover-width) !important;
- transition-delay: 0ms !important;
- }
- .sidebar-panel{
- background-color: transparent !important;
- color: var(--newtab-text-primary-color) !important;
- }
- .sidebar-panel #search-box{
- -moz-appearance: none !important;
- background-color: rgba(249,249,250,0.1) !important;
- color: inherit !important;
- }
- /* Add sidebar divider and give it background */
- #sidebar,
- #sidebar-header{
- background-color: inherit !important;
- border-inline: 1px solid rgb(80,80,80);
- border-inline-width: 0px 1px;
- }
- #sidebar-box:not([positionend],[sidebar-positionend]) > :-moz-locale-dir(rtl),
- #sidebar-box:is([positionend],[sidebar-positionend]) > *{
- border-inline-width: 1px 0px;
- }
- @media -moz-pref("sidebar.revamp") {
- #sidebar, #sidebar-header{ border-style: none }
- #sidebar-box{ padding: 0 !important; }
- }
- /* Move statuspanel to the other side when sidebar is hovered so it doesn't get covered by sidebar */
- #sidebar-box:not([positionend],[sidebar-positionend]):hover ~ #appcontent #statuspanel{
- inset-inline: auto 0px !important;
- }
- #sidebar-box:not([positionend],[sidebar-positionend]):hover ~ #appcontent #statuspanel-label{
- margin-inline: 0px !important;
- border-left-style: solid !important;
- }
- @media -moz-pref("userchrome.autohide-sidebar.static-layout.enabled"){
- #sidebar-box{
- min-width: var(--uc-sidebar-width) !important;
- contain: size;
- box-shadow: var(--content-area-shadow);
- }
- #sidebar{
- min-width: var(--uc-sidebar-hover-width) !important;
- }
- .sidebar-browser-stack{
- overflow: hidden;
- width: 100%;
- transition: width var(--uc-autohide-transition-duration) var(--uc-autohide-transition-type) var(--uc-autohide-sidebar-delay);
- direction: ltr;
- &:hover{
- transition-delay: 0ms;
- width: var(--uc-sidebar-hover-width);
- }
- &:-moz-locale-dir(rtl){
- transition-property: transform,width !important;
- }
- }
- #sidebar-box[sidebar-positionend]:hover :is(#sidebar-header,#sidebar):-moz-locale-dir(ltr){
- transform: translateX(0);
- transition-delay: 0ms !important;
- }
- #sidebar-box:not([sidebar-positionend]):hover .sidebar-browser-stack:-moz-locale-dir(rtl){
- transform: translateX(calc(-1 * var(--uc-sidebar-hover-width) + var(--uc-sidebar-width)));
- }
- #sidebar-box[sidebar-positionend]:hover > .sidebar-browser-stack:-moz-locale-dir(rtl){
- transform: translateX(calc(var(--uc-sidebar-hover-width) - var(--uc-sidebar-width)));
- transition-delay: 0ms !important;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment