this post was submitted on 28 May 2024
7 points (100.0% liked)

Firefox Customs

3 readers
9 users here now

Chat with us!

Post your unsupported Firefox customizations here!

From the makers of r/FirefoxCSS

Links

Related

Rules

  1. Posts must have flair!
  2. Posts cannot be memes/shitposts. They should be about Firefox customization with CSS.
  3. Please be civil. Bear in mind that many users come here for help and would be turned off by insults and rudeness.
  4. When posting large amount of code use a service dedicated to hosting text snippets, such as pastebin, hastebin, github gist or equivalent. Relatively short snippets can be wrapped in code-block for inline viewing.
  5. Do NOT use url-shorteners or link to compressed downloads (such as zip or rar) when sharing code.

founded 1 year ago
MODERATORS
 

hi, I'm asking for help to solve this inconvenient when I try to replace the default wallpapers in newtab page.
Fist of all I'm using the developer Firefox version that use beta version to do this.

I have activated this preference in about:config page:

browser.newtabpage.activity-stream.newtabWallpapers.enabled to true

after that I replaced the wallpapers thumbnails successfully with the next code:

/* Miniaturas de wallpapers */

/* Dark */

.wallpaper-input.dark-landscape { background-image: url("../newtab/wallpaper-dark.png") !important; }

.wallpaper-input.dark-panda { background-image: url("../newtab/wallpaper-dark2.png") !important; }

.wallpaper-input.dark-color { background-image: url("../newtab/wallpaper-dark3.png") !important; }

.wallpaper-input.dark-sky { background-image: url("../newtab/wallpaper-dark4.png") !important; }

.wallpaper-input.dark-mountain { background-image: url("../newtab/wallpaper-dark5.png") !important; }

.wallpaper-input.dark-beach { background-image: url("../newtab/wallpaper-dark6.png") !important; }

but when I try to replace the wallpaper for the first image in newtab page it don't work with the path I used to use, for example this code:

body:has(#dark-landscape[aria-checked="true"]){
--newtab-wallpaper-dark: url("../newtab/wallpaper-dark.png") !important;
    }

and only works when I use a url for the new image like this:

body:has(#dark-landscape[aria-checked="true"]){
--newtab-wallpaper-dark: url(https://i.imgur.com/It1Ugaa.png) !important;
}

so I wonder if is my mistake or is a Firefox bug, or maybe there is a trick to solve it? cause I would like to use local images and not urls.

you are viewing a single comment's thread
view the rest of the comments
[โ€“] Godie@lemmy.world 1 points 5 months ago

ooh, thanks for the explanation, I'm sure I understand better how this works. ๐Ÿ’™