Skip to content

Instantly share code, notes, and snippets.

@ivan
Created July 31, 2024 06:37
Show Gist options
  • Save ivan/51367e57cfeeea446adef5b7f5874aa9 to your computer and use it in GitHub Desktop.
Save ivan/51367e57cfeeea446adef5b7f5874aa9 to your computer and use it in GitHub Desktop.
userContent.css and userChrome.css for Firefox / Floorp
/*************************************************************************************************************************************************************************************************************************************************************
"userChrome.css" is a custom CSS file that can be used to specify CSS style rules for Floorp's interface (NOT internal site) using "chrome" privileges.
For instance, if you want to hide the tab bar, you can use the following CSS rule:
**************************************
#TabsToolbar { *
display: none !important; *
} *
**************************************
NOTE: You can use the userChrome.css file without change preferences (about:config)
Quote: https://userChrome.org | https://github.com/topics/userchrome
************************************************************************************************************************************************************************************************************************************************************/
@charset "UTF-8";
@-moz-document url(chrome://browser/content/browser.xhtml) {
/**
* Hide the sidebar when fullscreen
* https://github.com/piroor/treestyletab/issues/1548#issuecomment-345411610
*/
#main-window[inFullscreen] #sidebar-box,
#main-window[inFullscreen] #sidebar-splitter {
display: none !important;
width: 0px !important;
}
}
/*************************************************************************************************************************************************************************************************************************************************************
"userContent.css" is a custom CSS file that can be used to specify CSS style rules for Floorp's internal site using "chrome" privileges.
For instance, if you want to apply CSS at "about:newtab" and "about:home", you can use the following CSS rule:
***********************************************************************
@-moz-document url-prefix("about:newtab"), url-prefix("about:home") { *
*
* Write your css * *
*
} *
***********************************************************************
NOTE: You can use the userContent.css file without change preferences (about:config)
************************************************************************************************************************************************************************************************************************************************************/
@charset "UTF-8";
@namespace url(http://www.w3.org/1999/xhtml);
@-moz-document regexp("chrome://browser/content/devtools/**/.*"){
.devtools-monospace {
/* In the devtools, use the default monospace font we configured, not Consolas */
font-family: monospace !important;
font-size: 9pt !important;
}
:root {
/* Make things slightly larger than the default 11px */
--theme-body-font-size: 9pt !important;
--theme-code-font-size: 9pt !important;
}
:root[platform="win"] {
/* In the Console tab, use the default monospace font we configured, not Consolas */
--monospace-font-family: monospace !important;
}
}
/* Use one monospace font */
@font-face { src: local("PragmataPro Mono"); font-family: "Consolas"; }
@font-face { src: local("PragmataPro Mono"); font-family: "Courier"; }
@font-face { src: local("PragmataPro Mono"); font-family: "Courier New"; }
@font-face { src: local("PragmataPro Mono"); font-family: "Segoe UI Mono"; }
@font-face { src: local("PragmataPro Mono"); font-family: "Cascadia Mono"; }
@font-face { src: local("PragmataPro Mono"); font-family: "Lucida Sans Typewriter"; }
/* Use one sans-serif font */
@font-face { src: local("Inter Display"); font-family: "system-ui"; }
@font-face { src: local("Inter Display"); font-family: "-apple-system"; }
@font-face { src: local("Inter Display"); font-family: "BlinkMacSystemFont"; }
@font-face { src: local("Inter Display"); font-family: "Arial"; }
@font-face { src: local("Inter Display"); font-family: "Helvetica"; }
@font-face { src: local("Inter Display"); font-family: "Segoe UI"; }
@font-face { src: local("Inter Display"); font-family: "Segoe UI Adjusted"; }
@font-face { src: local("Inter Display"); font-family: "Verdana"; }
@font-face { src: local("Inter Display"); font-family: "Tahoma"; }
@font-face { src: local("Inter Display"); font-family: "Trebuchet MS"; }
@font-face { src: local("Inter Display"); font-family: "Lucida Sans"; }
@font-face { src: local("Inter Display"); font-family: "Calibri"; }
@font-face { src: local("Inter Display"); font-family: "Gill Sans"; }
@font-face { src: local("Inter Display"); font-family: "Gill Sans MT"; }
@font-face { src: local("Inter Display"); font-family: "Inter"; }
/* Replace serif with our one sans-serif font (serif on screens reads worse) */
@font-face { src: local("Inter Display"); font-family: "Georgia"; }
@font-face { src: local("Inter Display"); font-family: "Times"; }
@font-face { src: local("Inter Display"); font-family: "Times New Roman"; }
@font-face { src: local("Inter Display"); font-family: "Palatino Linotype"; }
@font-face { src: local("Inter Display"); font-family: "Garamond"; }
@font-face { src: local("Inter Display"); font-family: "Bookman"; }
@font-face { src: local("Inter Display"); font-family: "PT Serif"; }
@font-face { src: local("Inter Display"); font-family: "Book Antiqua"; }
@font-face { src: local("Inter Display"); font-family: "Cambria"; }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment