diff options
author | 2021-08-27 18:13:24 +0530 | |
---|---|---|
committer | 2021-08-27 18:13:24 +0530 | |
commit | 155c4b832281348c16be1f4ef667e6e23dbf1bd8 (patch) | |
tree | d144e2de2e6c7fb2e334246e8a4aecdbeb08ef8d /recipes/googlemeet/webview.js | |
parent | docs: fixed template file for creating recipe. (diff) | |
download | ferdium-recipes-155c4b832281348c16be1f4ef667e6e23dbf1bd8.tar.gz ferdium-recipes-155c4b832281348c16be1f4ef667e6e23dbf1bd8.tar.zst ferdium-recipes-155c4b832281348c16be1f4ef667e6e23dbf1bd8.zip |
chore: normalized all recipes to ensure compatibility with es6 (#639)
- Removed some calls to set badge with '0' all the time.
- Removed all 'sourceMaps' since they are all outdated atm.
Diffstat (limited to 'recipes/googlemeet/webview.js')
-rw-r--r-- | recipes/googlemeet/webview.js | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/recipes/googlemeet/webview.js b/recipes/googlemeet/webview.js index eb6f7f3..3a20b0c 100644 --- a/recipes/googlemeet/webview.js +++ b/recipes/googlemeet/webview.js | |||
@@ -1,13 +1,11 @@ | |||
1 | const { | 1 | const _path = _interopRequireDefault(require('path')); |
2 | remote, | ||
3 | } = require('electron'); | ||
4 | 2 | ||
5 | const path = require('path'); | 3 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } |
4 | |||
5 | const { remote } = require('electron'); | ||
6 | 6 | ||
7 | const webContents = remote.getCurrentWebContents(); | 7 | const webContents = remote.getCurrentWebContents(); |
8 | const { | 8 | const { session } = webContents; |
9 | session, | ||
10 | } = webContents; | ||
11 | 9 | ||
12 | window.onload = () => { | 10 | window.onload = () => { |
13 | const title = document.querySelector('.window-title').innerHTML; | 11 | const title = document.querySelector('.window-title').innerHTML; |
@@ -17,7 +15,7 @@ window.onload = () => { | |||
17 | } | 15 | } |
18 | }; | 16 | }; |
19 | 17 | ||
20 | module.exports = Franz => { | 18 | module.exports = Ferdi => { |
21 | session.flushStorageData(); | 19 | session.flushStorageData(); |
22 | session.clearStorageData({ | 20 | session.clearStorageData({ |
23 | storages: ['serviceworkers'], | 21 | storages: ['serviceworkers'], |
@@ -33,9 +31,10 @@ module.exports = Franz => { | |||
33 | } | 31 | } |
34 | } | 32 | } |
35 | 33 | ||
36 | Franz.setBadge(count); | 34 | Ferdi.setBadge(count); |
37 | }; | 35 | }; |
38 | 36 | ||
39 | Franz.injectCSS(path.join(__dirname, 'service.css')); | 37 | Ferdi.loop(getMessages); |
40 | Franz.loop(getMessages); | 38 | |
39 | Ferdi.injectCSS(_path.default.join(__dirname, 'service.css')); | ||
41 | }; | 40 | }; |