From 59f2d70ae9c25b11d21b0282f41485e0325b93a6 Mon Sep 17 00:00:00 2001 From: Vijay Aravamudhan Date: Sun, 12 Sep 2021 08:54:36 +0530 Subject: New recipe: 'flock' (#688) --- recipes/flock/icon.svg | 1 + recipes/flock/index.js | 1 + recipes/flock/package.json | 11 +++++++++++ recipes/flock/webview.js | 7 +++++++ 4 files changed, 20 insertions(+) create mode 100644 recipes/flock/icon.svg create mode 100644 recipes/flock/index.js create mode 100644 recipes/flock/package.json create mode 100644 recipes/flock/webview.js (limited to 'recipes') diff --git a/recipes/flock/icon.svg b/recipes/flock/icon.svg new file mode 100644 index 0000000..96fbe2e --- /dev/null +++ b/recipes/flock/icon.svg @@ -0,0 +1 @@ +flock diff --git a/recipes/flock/index.js b/recipes/flock/index.js new file mode 100644 index 0000000..23607bd --- /dev/null +++ b/recipes/flock/index.js @@ -0,0 +1 @@ +module.exports = Ferdi => Ferdi; diff --git a/recipes/flock/package.json b/recipes/flock/package.json new file mode 100644 index 0000000..83e5b94 --- /dev/null +++ b/recipes/flock/package.json @@ -0,0 +1,11 @@ +{ + "id": "flock", + "name": "Flock", + "version": "1.0.0", + "license": "MIT", + "repository": "https://github.com/jereddowden/franz-recipe-flock", + "config": { + "serviceURL": "https://web.flock.com", + "hasNotificationSound": true + } +} diff --git a/recipes/flock/webview.js b/recipes/flock/webview.js new file mode 100644 index 0000000..29b52d3 --- /dev/null +++ b/recipes/flock/webview.js @@ -0,0 +1,7 @@ +module.exports = Ferdi => { + const getMessages = () => { + const allMessages = Ferdi.safeParseInt(document.querySelector('.team-counter').textContent); + Ferdi.setBadge(allMessages); + }; + Ferdi.loop(getMessages); +}; -- cgit v1.2.3-54-g00ecf