Isithangami Sabeseki

Custom css

Hello!
I have problems creating my own CSS style. Most of the changes were applied by the browser through userChrome.css and userContent.css, but those elements that use common.css ignore it. What to do in my case?

Hello!
I have problems creating my own CSS style. Most of the changes were applied by the browser through userChrome.css and userContent.css, but those elements that use common.css ignore it. What to do in my case?

Ama-screenshot ananyekiwe

Isisombululo esikhethiwe

Okay, found the other page by pasting

about:preferences#containers

to the address bar and pressing Enter to load it. Similar idea, except this time it's a <window> instead of a <dialog>:

You can see in the Rules panel view that this is about an element in the html namespace, so you will have to use a selector that includes a namespace (*|xxx) to override an existing rule.

The code needs to be in userChrome.css, and probably above the default @namespace line or in a file without a namespace line imported via an @import url(); rule in userChrome.css.

*|input {...}

You can see in the Rules panel view that this is about an element in the html namespace, so you will have to use a selector that includes a namespace (*|xxx) to override an existing rule.
The code needs to be in userChrome.css, and probably above the default @namespace line or in a file without a namespace line imported via an @import url(); rule in userChrome.css.
<pre><nowiki>*|input {...}</nowiki></pre>

What element do you want to change (i.e. override what rule)?
A see this selector active (bold): xul|textbox[focused]
I'm not sure if you will be able to override such an element select.
Did you check this common.css file to see what namespace lines are at the top of the file?
*https://developer.mozilla.org/en/Web/CSS/@namespace

As a proof of concept in a userContent.css file, this works for me. There is a green input on about:config, and a red search box on about:preferences. The reason for using url-prefix is the hashes that are added to the URL when you go to different parts of the page.

As a proof of concept in a userContent.css file, this works for me. There is a green input on about:config, and a red search box on about:preferences. The reason for using url-prefix is the hashes that are added to the URL when you go to different parts of the page.
<pre>input, textarea {
color: white !important;
background-color: green !important;
}
@-moz-document url-prefix("about:preferences") {
input, textarea {
background-color: red !important;
}
}
</pre>
Note: I don't specify any namespace at the top of the file.

Umnikazi wombuzo

jscher2000, I need to change only on the settings page, without touching the sites. This will affect the sites:
input, textarea {

color: white !important;
background-color: green !important;

}
The second part does not work for me without the first, but it affects sites.

'''jscher2000''', I need to change only on the settings page, without touching the sites. This will affect the sites:
input, textarea {
color: white !important;
background-color: green !important;
}
The second part does not work for me without the first, but it affects sites.

Umnikazi wombuzo

Apparently, to explain that you draw other elements that can be drawn without problems, and those that should be painted, colors are ignored or affect the sites, I can not. In any case, thank you for your attention...

Apparently, to explain that you draw other elements that can be drawn without problems, and those that should be painted, colors are ignored or affect the sites, I can not. In any case, thank you for your attention...

What are the complete contents of your userContent.css file so I can test them? To prevent this site from mangling your style rules, please put <pre> before and </pre> after them in your reply. Or you can use a site like Pastebin to share them.

What are the complete contents of your userContent.css file so I can test them? To prevent this site from mangling your style rules, please put &lt;pre> before and &lt;/pre> after them in your reply. Or you can use a site like Pastebin to share them.

Umnikazi wombuzo

I am interested in other elements. This code does not color the necessary ones.
Go to the container menu or network settings. See how much white? THESE ELEMENTS NEED ME! THESE! The last picture was taken with a dark theme to show how many there are.

I am interested in other elements. This code does not color the necessary ones.
Go to the container menu or network settings. See how much white? THESE ELEMENTS NEED ME! THESE! The last picture was taken with a dark theme to show how many there are.

I don't know what that first screenshot is. Is it a drop-down panel or popup window generated by an extension??
In the third screenshot, that connection settings dialog is loaded in a <browser> element, which seems to be like an iframe. So our rule doesn't style that.
When I use [https://developer.mozilla.org/docs/Tools/Page_Inspector Firefox's Page Inspector], I see the top level element in the frame is a <dialog> with id="ConnectionsDialog" so with that in mind, try this:
<pre>dialog#ConnectionsDialog input,
dialog#ConnectionsDialog textarea {
color: white !important;
background-color: red !important;
}
</pre>

Okay, found the other page by pasting
'''about:preferences#containers'''
to the address bar and pressing Enter to load it. Similar idea, except this time it's a <window> instead of a <dialog>:
<pre>window#ContainersDialog input,
window#ContainersDialog textarea {
color: white !important;
background-color: red !important;
}
</pre>