From 41a4dbc484b6d4c6fe09b2bce7a3364032a01650 Mon Sep 17 00:00:00 2001 From: Sunny Singh Date: Wed, 3 Feb 2021 02:17:03 +0530 Subject: Added recipe for productivity app Clockify (#431) --- clockify/README.md | 5 +++++ clockify/icon.svg | 20 ++++++++++++++++++++ clockify/index.js | 3 +++ clockify/package.json | 23 +++++++++++++++++++++++ clockify/service.css | 3 +++ clockify/webview.js | 11 +++++++++++ 6 files changed, 65 insertions(+) create mode 100644 clockify/README.md create mode 100644 clockify/icon.svg create mode 100644 clockify/index.js create mode 100644 clockify/package.json create mode 100644 clockify/service.css create mode 100644 clockify/webview.js diff --git a/clockify/README.md b/clockify/README.md new file mode 100644 index 0000000..a3b4401 --- /dev/null +++ b/clockify/README.md @@ -0,0 +1,5 @@ +# Clockify for Franz +This is the official Franz recipe for [Clockify](https://clockify.me/), the forever free time tracking application. + +### How to create your own Franz recipes: +* [Read the documentation](https://github.com/meetfranz/plugins) diff --git a/clockify/icon.svg b/clockify/icon.svg new file mode 100644 index 0000000..f2fa1d0 --- /dev/null +++ b/clockify/icon.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/clockify/index.js b/clockify/index.js new file mode 100644 index 0000000..e8243fb --- /dev/null +++ b/clockify/index.js @@ -0,0 +1,3 @@ +"use strict"; + +module.exports = Franz => Franz; \ No newline at end of file diff --git a/clockify/package.json b/clockify/package.json new file mode 100644 index 0000000..f7b794a --- /dev/null +++ b/clockify/package.json @@ -0,0 +1,23 @@ +{ + "id": "clockify", + "name": "Clockify", + "version": "1.0.0", + "description": "Clockify", + "main": "index.js", + "author": "Sunny Singh ", + "license": "MIT", + "config": { + "serviceURL": "https://clockify.me/tracker", + "message": "", + "popup": [], + "hasNotificationSound": true, + "hasDirectMessages": true, + "hasIndirectMessages": false, + "hasTeamID": false, + "hasPredefinedUrl": true, + "hasCustomUrl": false, + "webviewOptions": { + "disablewebsecurity": "" + } + } +} diff --git a/clockify/service.css b/clockify/service.css new file mode 100644 index 0000000..a16a615 --- /dev/null +++ b/clockify/service.css @@ -0,0 +1,3 @@ +.notice { + display: none; +} diff --git a/clockify/webview.js b/clockify/webview.js new file mode 100644 index 0000000..5aab471 --- /dev/null +++ b/clockify/webview.js @@ -0,0 +1,11 @@ +"use strict"; + +module.exports = Franz => { + const getMessages = function getMessages() { + const notifications = document.querySelectorAll('.notification--number'); + + Franz.setBadge(0, notifications.length >= 1 ? 1 : 0); + }; + + Franz.loop(getMessages); +}; \ No newline at end of file -- cgit v1.2.3-54-g00ecf