Is there a way to do this with user CSS on Firefox?

The content has to have full opacity. So setting opacity through the compositor or the opacity CSS property does not count.

Setting a background-color with some alpha on userContent.css technically works but because the browser itself is fully opaque, doesn’t show the background. Trying to set background-related properties on #browser on userChrome.css doesn’t have an effect. If I can make only the background of #browser transparent, this’ll work. But I don’t know if that’s possible.

edit: it is possible, with lots of caveats. Site-specific fixes will be required, popups are hard to read. If you have dark wallpapers enable dark reader to make site content readable on a dark background.

1- set browser.tabs.allow_transparent_browser to true

2- in userChrome.css add #main-window, #tabbrowser-tabpanels{ background: transparent !important; }

3- userContent.css:

*{
  background-color: transparent !important;
}
/* if you don't want full transparency */
html:root{
  background-color: #00000080 !important;
}
  • Max-P@lemmy.max-p.me
    link
    fedilink
    arrow-up
    1
    ·
    6 days ago

    You might be able to convince Firefox to be transparent with a GTK theme as Firefox uses GTK under the hood for the window. If you’re lucky it won’t bother clearing it with black just in case and it’ll actually be transparent.

    The shader option is pretty neat and easy though.

    • Quail4789@lemmy.mlOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      6 days ago

      Please see my response to the other comment. I could use the help if you know about shaders.