25
Dacexi
7y

I finaly managed to make a dark mode on slack desktop app! Still has some bugs (like scrollbar being white) but works well enough for me. If anyone is interested tell me in the comments 🙂

How i did it (Linux paths but should be the same process for Windows):

You can execute scripts in /usr/lib/slack/resources/app.asar.unpacked/src/static/index.js

Using that i figgured out that slack desktop is basically an actual webview to their website and some os hooks.

To edit the contents of the webview you can call `document.getElementsByClassName('WebViewContext')[0].executeJavaScript("alert(1)")`

Then i just simply packaged up some custom css to be loaded with JS.

Quite simple actually.

Using this method you can create all kinds of plugins for slack, so go wild!

Comments
  • 2
    @nik123 i have no idea how to do gtk or qt. Slack is electron which is css, js and html.

    You need to replace the contents of /usr/lib/slack/resources/app.asar.unpacked/src/static/index.js with my script: https://pastebin.com/BKNsSSt4 (MAKE SURE YOU BACK UP THE FILE IN CASE YOU WANT TO GO BACK)
  • 2
    @nik123 Also, my recommended sidebar theme: #2a2a30,#49494f,#2D9EE0,#FFFFFF,#49494F,#c8cccf,#68d65e,#DC5960

    Most should work but this fits in the best.
  • 2
    Favorited fit when I download slack eventually
Add Comment