diff options
Diffstat (limited to 'recipes/facebook/webview.js')
-rwxr-xr-x | recipes/facebook/webview.js | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/recipes/facebook/webview.js b/recipes/facebook/webview.js index 1ff8558..f3ba1b6 100755 --- a/recipes/facebook/webview.js +++ b/recipes/facebook/webview.js | |||
@@ -1,8 +1,16 @@ | |||
1 | function _interopRequireDefault(obj) { | ||
2 | return obj && obj.__esModule ? obj : { default: obj }; | ||
3 | } | ||
4 | |||
5 | const _path = _interopRequireDefault(require('path')); | ||
6 | |||
1 | module.exports = Ferdium => { | 7 | module.exports = Ferdium => { |
2 | const getNotifications = function getNotifications() { | 8 | const getNotifications = function getNotifications() { |
3 | let count = 0; | 9 | let count = 0; |
4 | 10 | ||
5 | const queryList = document.querySelectorAll('.bp9cbjyn.bwm1u5wc.pq6dq46d.datstx6m.taijpn5t.jb3vyjys.jxrgncrl.qt6c0cv9.qnrpqo6b.k4urcfbm'); | 11 | const queryList = document.querySelectorAll( |
12 | '.bp9cbjyn.bwm1u5wc.pq6dq46d.datstx6m.taijpn5t.jb3vyjys.jxrgncrl.qt6c0cv9.qnrpqo6b.k4urcfbm', | ||
13 | ); | ||
6 | for (const element of queryList) { | 14 | for (const element of queryList) { |
7 | count += Ferdium.safeParseInt(element.textContent); | 15 | count += Ferdium.safeParseInt(element.textContent); |
8 | } | 16 | } |
@@ -29,4 +37,6 @@ module.exports = Ferdium => { | |||
29 | }; | 37 | }; |
30 | 38 | ||
31 | Ferdium.loop(loopFunc); | 39 | Ferdium.loop(loopFunc); |
40 | |||
41 | Ferdium.injectCSS(_path.default.join(__dirname, 'service.css')); | ||
32 | }; | 42 | }; |