Skip to content

Instantly share code, notes, and snippets.

@mireq

mireq/userChrome.css

Last active May 30, 2020
Embed
What would you like to do?
Compact responsive oneliner for Firefox
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
/* Hide buttons **/
*|*:root:not([customizing]) #nav-bar #nav-bar-customization-target toolbarbutton:not([customizing]) {
margin-left: calc(-2 * var(--toolbarbutton-inner-padding) - 16px - (2 * var(--toolbarbutton-outer-padding))) !important;
opacity: 0 !important;
pointer-events: none !important;
transition: all 100ms var(--animation-easing-function) !important;
}
/* Show on hover or focus */
/*
*|*:root:not([customizing]) :hover > #nav-bar toolbarbutton,
*|*:root:not([customizing]) #navigator-toolbox:focus-within #nav-bar toolbarbutton,
*|*:root:not([customizing]) :hover > #titlebar toolbarbutton {
margin-left: 0 !important;
opacity: 1 !important;
pointer-events: auto !important;
}
*/
/* Don't hide tab buttons */
*|*:root:not([customizing]) :hover > #titlebar #TabsToolbar toolbarbutton {
margin-left: 0px !important;
opacity: 1 !important;
pointer-events: auto !important;
}
/* Disable padding on urlbar */
*|*:root:not([customizing]) #navigator-toolbox #nav-bar #urlbar-container {
margin-inline: 0 !important;
padding-block: 0 !important;
}
/* Hide controls on urlbar focus */
*|*:root:not([customizing]) #navigator-toolbox #nav-bar #nav-bar-customization-target:focus-within ~ toolbarbutton,
*|*:root:not([customizing]) #navigator-toolbox #nav-bar #nav-bar-customization-target:focus-within ~ toolbaritem {
display: none !important;
}
*|*:root:not([customizing]) #navigator-toolbox #nav-bar #urlbar-container:focus-within {
margin-right: -65vw !important;
}
*|*:root:not([customizing]) #navigator-toolbox #nav-bar #urlbar-container:focus-within #page-action-buttons {
display: -moz-box !important;
}
/* Remove styles from urlbar */
*|*:root:not([customizing]) #urlbar.megabar > #urlbar-background {
border-radius: 0 !important;
}
*|*:root:not([customizing]) #urlbar-input-container,
*|*:root:not([customizing]) #urlbar-background {
border: none !important;;
border-radius: 0 !important;
}
*|*:root:not([customizing]) #urlbar {
top: 0 !important;
min-height: var(--tab-min-height) !important;
}
*|*:root:not([customizing]) #urlbar-container {
min-height: var(--tab-min-height) !important;
min-width: 150px !important;
}
*|*:root:not([customizing]) #page-action-buttons {
display: none !important;
}
/* Move tabs 35% to rihgt */
#TabsToolbar {
margin-left: 35vw !important;
}
/* Move navigation 65% to left and negative margin to move to top line */
#nav-bar {
margin-right: 65vw !important;
margin-top: calc(0px - var(--tab-min-height)) !important;
background: transparent !important;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.