diff options
author | André Oliveira <oliveira.andrerodrigues95@gmail.com> | 2022-07-08 17:32:08 +0100 |
---|---|---|
committer | Vijay Aravamudhan <vraravam@users.noreply.github.com> | 2022-07-08 22:41:25 +0530 |
commit | 6d6ee440ecda3136a69f902adb16569638baa7fc (patch) | |
tree | 091252a99da4814d686ad2b30eb28ad48f3c42a6 /recipes/whatsapp/webview.js | |
parent | New recipe: kiwi IRC (diff) | |
download | ferdium-recipes-6d6ee440ecda3136a69f902adb16569638baa7fc.tar.gz ferdium-recipes-6d6ee440ecda3136a69f902adb16569638baa7fc.tar.zst ferdium-recipes-6d6ee440ecda3136a69f902adb16569638baa7fc.zip |
Fix #90
Diffstat (limited to 'recipes/whatsapp/webview.js')
-rw-r--r-- | recipes/whatsapp/webview.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/recipes/whatsapp/webview.js b/recipes/whatsapp/webview.js index 180be79..77c4ebb 100644 --- a/recipes/whatsapp/webview.js +++ b/recipes/whatsapp/webview.js | |||
@@ -54,6 +54,16 @@ module.exports = Ferdium => { | |||
54 | Ferdium.releaseServiceWorkers(); | 54 | Ferdium.releaseServiceWorkers(); |
55 | }); | 55 | }); |
56 | 56 | ||
57 | Ferdium.handleDarkMode((isEnabled) => { | ||
58 | |||
59 | if (isEnabled) { | ||
60 | document.body.classList.add('dark'); | ||
61 | } else { | ||
62 | document.body.classList.remove('dark'); | ||
63 | } | ||
64 | |||
65 | }); | ||
66 | |||
57 | Ferdium.loop(loopFunc); | 67 | Ferdium.loop(loopFunc); |
58 | 68 | ||
59 | Ferdium.injectCSS(_path.default.join(__dirname, 'service.css')); | 69 | Ferdium.injectCSS(_path.default.join(__dirname, 'service.css')); |