aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/simplenote
diff options
context:
space:
mode:
authorLibravatar Markus Hatvan <markus_hatvan@aon.at>2021-10-05 17:04:09 +0200
committerLibravatar GitHub <noreply@github.com>2021-10-05 17:04:09 +0200
commitd3841b766f9d37d557646003899f67525c5f755f (patch)
tree1bcab990c94f2b05678b7a83ffebe08298500f0b /recipes/simplenote
parentchore: repo maintenance (#732) (diff)
downloadferdium-recipes-d3841b766f9d37d557646003899f67525c5f755f.tar.gz
ferdium-recipes-d3841b766f9d37d557646003899f67525c5f755f.tar.zst
ferdium-recipes-d3841b766f9d37d557646003899f67525c5f755f.zip
chore: add eslint-plugin-unicorn (#733)
Diffstat (limited to 'recipes/simplenote')
-rw-r--r--recipes/simplenote/index.js3
-rw-r--r--recipes/simplenote/webview.js10
2 files changed, 8 insertions, 5 deletions
diff --git a/recipes/simplenote/index.js b/recipes/simplenote/index.js
index 18db071..15ecf81 100644
--- a/recipes/simplenote/index.js
+++ b/recipes/simplenote/index.js
@@ -1,2 +1 @@
1module.exports = Ferdi => class simplenote extends Ferdi { module.exports = Ferdi => class simplenote extends Ferdi {};
2};
diff --git a/recipes/simplenote/webview.js b/recipes/simplenote/webview.js
index 8d1afc8..ae392f5 100644
--- a/recipes/simplenote/webview.js
+++ b/recipes/simplenote/webview.js
@@ -3,11 +3,15 @@ module.exports = Ferdi => {
3 let count = 0; 3 let count = 0;
4 4
5 if (window.location.pathname.includes('messaging')) { 5 if (window.location.pathname.includes('messaging')) {
6 count = document.querySelectorAll('.msg-conversation-card__unread-count').length; 6 count = document.querySelectorAll(
7 '.msg-conversation-card__unread-count',
8 ).length;
7 } else { 9 } else {
8 const element = document.querySelector('.nav-item--messaging .nav-item__badge-count'); 10 const element = document.querySelector(
11 '.nav-item--messaging .nav-item__badge-count',
12 );
9 if (element) { 13 if (element) {
10 count = Ferdi.safeParseInt(element.innerHTML); 14 count = Ferdi.safeParseInt(element.textContent);
11 } 15 }
12 } 16 }
13 17