diff options
Diffstat (limited to 'recipes/instagram-direct-messages/webview.js')
-rw-r--r-- | recipes/instagram-direct-messages/webview.js | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/recipes/instagram-direct-messages/webview.js b/recipes/instagram-direct-messages/webview.js index a59013a..01187b8 100644 --- a/recipes/instagram-direct-messages/webview.js +++ b/recipes/instagram-direct-messages/webview.js | |||
@@ -1,21 +1,21 @@ | |||
1 | "use strict"; | ||
2 | |||
3 | const _path = _interopRequireDefault(require('path')); | ||
4 | |||
5 | function _interopRequireDefault(obj) { | 1 | function _interopRequireDefault(obj) { |
6 | return obj && obj.__esModule ? obj : { default: obj }; | 2 | return obj && obj.__esModule ? obj : { default: obj }; |
7 | } | 3 | } |
8 | 4 | ||
5 | const _path = _interopRequireDefault(require('path')); | ||
6 | |||
9 | setInterval(() => { | 7 | setInterval(() => { |
10 | document.querySelector("._lz6s.Hz2lF").style.display = "none"; | 8 | document.querySelector('._lz6s.Hz2lF').style.display = 'none'; |
11 | document.querySelector(".t30g8.L1C6I").style.paddingTop = 0; | 9 | document.querySelector('.t30g8.L1C6I').style.paddingTop = 0; |
12 | document.querySelector(".i0EQd").style.maxWidth = 'unset !important'; | 10 | document.querySelector('.i0EQd').style.maxWidth = 'unset !important'; |
13 | }, 3000); | 11 | }, 3000); |
14 | 12 | ||
15 | module.exports = (Ferdium) => { | 13 | module.exports = Ferdium => { |
16 | const getMessages = () => { | 14 | const getMessages = () => { |
17 | const element = document.querySelector('a[href^="/direct/inbox"]'); | 15 | const element = document.querySelector('a[href^="/direct/inbox"]'); |
18 | Ferdium.setBadge(element.textContent ? Ferdium.safeParseInt(element.textContent) : 0); | 16 | Ferdium.setBadge( |
17 | element.textContent ? Ferdium.safeParseInt(element.textContent) : 0, | ||
18 | ); | ||
19 | }; | 19 | }; |
20 | 20 | ||
21 | Ferdium.loop(getMessages); | 21 | Ferdium.loop(getMessages); |