Specify URLs to not affect the @ -moz document in a stylish

With stylish, you can specify domains using @-moz-document url-prefix(http://) , for example.

This applies to all URLs. Is there a way to specify which URLs you don’t want to influence the style? This means that you can have a global stylesheet that will handle everything except the specified URLs, where there is another stylesheet that you want to use.

+4
source share
2 answers

It may seem complicated, but it can be done.
From Stylish: Applying Styles to Certain Sites :

 @-moz-document regexp('(?!http://www\.example\.com).*') { /* CSS rules here.*/ } 

Will be activated for all URLs except those starting with http://www.example.com .

+6
source

my decision

 @-moz-document regexp("^((?!(domain1\.com|domain2\.fr)).)*") { ...YOUR CSS... } 
0
source

Source: https://habr.com/ru/post/1439932/


All Articles