The idea is that I can include nightmode CSS on Slack during certain times. (And other services too)
I can probably code this myself so this issue is mostly for tracking :)
It will be a great feature!
You are welcome if you can contribute with this task. :wink:
The idea is to add a new option in the configuration window for each service, and the user can enable this feature with predefined CSS files.
Here's a nightmode for Skype.
Hi! quick way to implement this feature...
I added the following JS to the custom code section of the service (and tested it on a few services, with much success)...
function applycss(css){
var head = document.getElementsByTagName('head')[0];
var s = document.createElement('style');
s.setAttribute('type', 'text/css');
s.appendChild(document.createTextNode(css));
head.appendChild(s);
}
//apply via applycss(`YOUR CSS HERE`);
Use the CSS from User Styles. For example, here's a theme for Messenger...
@skmexyz I can't get this to work, do I just paste the entire CSS code between the `` or do I save it as a .css file and put the path to it?
@Silent-Hunter
go to custom code section for the particular service
first add the above function
then on the next line, add the following line (replace YOUR_CSS_HERE with your actual css)
applycss(`YOUR_CSS_HERE`)
Hope that helps!
It did yes thank you!
Skype dark theme broken as of posting date. :/
Can anyone get this snippet working with Slack?
Edit: Nevermind! For those that need things spelled out like I did: //apply via applycss( is a comment and needs to be uncommented first (and "apply via " deleted). It works!
Most helpful comment
Hi! quick way to implement this feature...
I added the following JS to the custom code section of the service (and tested it on a few services, with much success)...
Use the CSS from User Styles. For example, here's a theme for Messenger...