aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/riseup
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/riseup')
-rw-r--r--recipes/riseup/package.json2
-rw-r--r--recipes/riseup/webview.js10
2 files changed, 10 insertions, 2 deletions
diff --git a/recipes/riseup/package.json b/recipes/riseup/package.json
index f6ea15b..7dc626e 100644
--- a/recipes/riseup/package.json
+++ b/recipes/riseup/package.json
@@ -1,7 +1,7 @@
1{ 1{
2 "id": "riseup", 2 "id": "riseup",
3 "name": "Riseup.net", 3 "name": "Riseup.net",
4 "version": "1.2.0", 4 "version": "1.3.0",
5 "license": "MIT", 5 "license": "MIT",
6 "config": { 6 "config": {
7 "serviceURL": "https://mail.riseup.net" 7 "serviceURL": "https://mail.riseup.net"
diff --git a/recipes/riseup/webview.js b/recipes/riseup/webview.js
index 6f63103..bbf0db6 100644
--- a/recipes/riseup/webview.js
+++ b/recipes/riseup/webview.js
@@ -1,12 +1,20 @@
1function _interopRequireDefault(obj) {
2 return obj && obj.__esModule ? obj : { default: obj };
3}
4
5const _path = _interopRequireDefault(require('path'));
6
1module.exports = Ferdium => { 7module.exports = Ferdium => {
2 const getMessages = () => { 8 const getMessages = () => {
3 let unread = 0; 9 let unread = 0;
4 const notificationBadge = document.querySelectorAll('.unreadcount')[0]; 10 const notificationBadge = document.querySelectorAll('.unreadcount')[0];
5 if (notificationBadge != undefined) { 11 if (notificationBadge !== undefined) {
6 unread = Ferdium.safeParseInt(notificationBadge.textContent); 12 unread = Ferdium.safeParseInt(notificationBadge.textContent);
7 } 13 }
8 Ferdium.setBadge(unread); 14 Ferdium.setBadge(unread);
9 }; 15 };
10 16
11 Ferdium.loop(getMessages); 17 Ferdium.loop(getMessages);
18
19 Ferdium.injectCSS(_path.default.join(__dirname, 'service.css'));
12}; 20};