From 6f5e4a00588aefdda7a5a1cfe70935870e7e234a Mon Sep 17 00:00:00 2001 From: Bennett Date: Tue, 22 Sep 2020 20:56:48 +0200 Subject: Unpack recipes and update recipes icons (#292) Co-authored-by: Amine Mouafik --- recipes/zalo/LICENSE | 21 +++++++++++ recipes/zalo/README.md | 5 +++ recipes/zalo/icon.png | Bin 0 -> 47801 bytes recipes/zalo/icon.svg | 91 ++++++++++++++++++++++++++++++++++++++++++++++ recipes/zalo/index.js | 3 ++ recipes/zalo/package.json | 18 +++++++++ recipes/zalo/webview.js | 11 ++++++ 7 files changed, 149 insertions(+) create mode 100644 recipes/zalo/LICENSE create mode 100644 recipes/zalo/README.md create mode 100644 recipes/zalo/icon.png create mode 100644 recipes/zalo/icon.svg create mode 100644 recipes/zalo/index.js create mode 100644 recipes/zalo/package.json create mode 100644 recipes/zalo/webview.js (limited to 'recipes/zalo') diff --git a/recipes/zalo/LICENSE b/recipes/zalo/LICENSE new file mode 100644 index 0000000..ef601f9 --- /dev/null +++ b/recipes/zalo/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 Arthur Brugiere + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/recipes/zalo/README.md b/recipes/zalo/README.md new file mode 100644 index 0000000..c53df0a --- /dev/null +++ b/recipes/zalo/README.md @@ -0,0 +1,5 @@ +# Zalo for Ferdi +This is a Ferdi recipe for Zalo + +### How to create your own Ferdi recipes: +* [Read the documentation](https://github.com/getferdi/recipes/blob/master/docs/integration.md) diff --git a/recipes/zalo/icon.png b/recipes/zalo/icon.png new file mode 100644 index 0000000..2bbefab Binary files /dev/null and b/recipes/zalo/icon.png differ diff --git a/recipes/zalo/icon.svg b/recipes/zalo/icon.svg new file mode 100644 index 0000000..ff1ab66 --- /dev/null +++ b/recipes/zalo/icon.svg @@ -0,0 +1,91 @@ + + + + + + + + image/svg+xml + + logo-zalo-vector + + + + + logo-zalo-vector + + + + + + + diff --git a/recipes/zalo/index.js b/recipes/zalo/index.js new file mode 100644 index 0000000..e8243fb --- /dev/null +++ b/recipes/zalo/index.js @@ -0,0 +1,3 @@ +"use strict"; + +module.exports = Franz => Franz; \ No newline at end of file diff --git a/recipes/zalo/package.json b/recipes/zalo/package.json new file mode 100644 index 0000000..183fc20 --- /dev/null +++ b/recipes/zalo/package.json @@ -0,0 +1,18 @@ +{ + "id": "zalo", + "name": "Zalo", + "version": "1.1.1", + "description": "Zalo", + "main": "index.js", + "author": "RoiArthurB ", + "license": "MIT", + "config": { + "serviceURL": "https://chat.zalo.me/", + "hasNotificationSound": true, + "hasDirectMessages": true, + "hasIndirectMessages": false, + "hasTeamID": false, + "hasPredefinedUrl": true, + "hasCustomUrl": false + } +} diff --git a/recipes/zalo/webview.js b/recipes/zalo/webview.js new file mode 100644 index 0000000..0f360c3 --- /dev/null +++ b/recipes/zalo/webview.js @@ -0,0 +1,11 @@ +"use strict"; + +module.exports = Franz => { + const getMessages = function getMessages() { + var unread = 0 + const notificationBadge = document.getElementsByClassName('tab-red-dot').length; + Franz.setBadge(notificationBadge); + }; + + Franz.loop(getMessages); +}; -- cgit v1.2.3-70-g09d2