diff options
Diffstat (limited to 'recipes/weekplan/webview.js')
-rw-r--r-- | recipes/weekplan/webview.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/recipes/weekplan/webview.js b/recipes/weekplan/webview.js new file mode 100644 index 0000000..5a8a8fb --- /dev/null +++ b/recipes/weekplan/webview.js | |||
@@ -0,0 +1,10 @@ | |||
1 | module.exports = Ferdi => { | ||
2 | getMessages = () => { | ||
3 | const events = document.querySelectorAll(".today")[0].getElementsByClassName('list')[0].getElementsByClassName('task-list')[0].getElementsByClassName('event-section')[0].getElementsByClassName('droppable')[0].children[0].childElementCount | ||
4 | const tasks = document.querySelectorAll(".today")[0].getElementsByClassName('list')[0].getElementsByClassName('task-list')[0].getElementsByClassName('task-section')[0].getElementsByClassName('droppable')[0].children[0].childElementCount | ||
5 | |||
6 | Ferdi.setBadge(events + tasks); | ||
7 | }; | ||
8 | |||
9 | Ferdi.loop(getMessages); | ||
10 | } | ||