aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/lark
diff options
context:
space:
mode:
authorLibravatar Shao Yang Hong <hongsy2006@gmail.com>2020-10-07 22:24:06 +0800
committerLibravatar GitHub <noreply@github.com>2020-10-07 15:24:06 +0100
commit12f4f7ab7487b30c31f43dbc3009fb5b8769efdc (patch)
treec44786c7a3b7699f1f8051db08e8651ea9a1b0eb /recipes/lark
parentAdd recipe for Simplenote (#317) (diff)
downloadferdium-recipes-12f4f7ab7487b30c31f43dbc3009fb5b8769efdc.tar.gz
ferdium-recipes-12f4f7ab7487b30c31f43dbc3009fb5b8769efdc.tar.zst
ferdium-recipes-12f4f7ab7487b30c31f43dbc3009fb5b8769efdc.zip
Add recipe for Lark (#315)
Diffstat (limited to 'recipes/lark')
-rw-r--r--recipes/lark/README.md5
-rw-r--r--recipes/lark/darkmode.css0
-rw-r--r--recipes/lark/icon.pngbin0 -> 173486 bytes
-rw-r--r--recipes/lark/icon.svg1
-rw-r--r--recipes/lark/index.js1
-rw-r--r--recipes/lark/package.json15
-rw-r--r--recipes/lark/service.css7
-rw-r--r--recipes/lark/webview.js18
8 files changed, 47 insertions, 0 deletions
diff --git a/recipes/lark/README.md b/recipes/lark/README.md
new file mode 100644
index 0000000..9618a9e
--- /dev/null
+++ b/recipes/lark/README.md
@@ -0,0 +1,5 @@
1# Lark for Franz
2A Franz recipe for Lark
3
4### How to create your own Franz recipes:
5* [Read the documentation](https://github.com/meetfranz/plugins)
diff --git a/recipes/lark/darkmode.css b/recipes/lark/darkmode.css
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/recipes/lark/darkmode.css
diff --git a/recipes/lark/icon.png b/recipes/lark/icon.png
new file mode 100644
index 0000000..7a81805
--- /dev/null
+++ b/recipes/lark/icon.png
Binary files differ
diff --git a/recipes/lark/icon.svg b/recipes/lark/icon.svg
new file mode 100644
index 0000000..9f7ce09
--- /dev/null
+++ b/recipes/lark/icon.svg
@@ -0,0 +1 @@
<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 1024 1024"><defs><style>.cls-1,.cls-2{fill:none;}.cls-2{opacity:0;}.cls-3{clip-path:url(#clip-path);}.cls-4{fill:#38f;}.cls-5{fill:#005de0;}.cls-6{clip-path:url(#clip-path-2);}.cls-7{fill:#46ebd5;}.cls-8{fill:#00d0b6;}</style><clipPath id="clip-path"><path class="cls-1" d="M816.92,219.71,663.13,385.92a5.73,5.73,0,0,0-1.4,5A34.52,34.52,0,0,1,603,421.85L468.81,556.06A20,20,0,0,0,463,571.71l13.22,176.68L619.85,892a12,12,0,0,0,20-5.15L831,227.49C833.25,219.13,822.8,213.36,816.92,219.71Z"/></clipPath><clipPath id="clip-path-2"><path class="cls-1" d="M805.16,208,639,361.73a5.72,5.72,0,0,1-5,1.41A34.52,34.52,0,0,0,603,421.85L468.81,556.06a20,20,0,0,1-15.65,5.81L276.47,548.65,132.85,405A12,12,0,0,1,138,385L797.38,193.86C805.74,191.62,811.51,202.07,805.16,208Z"/></clipPath></defs><title>larklogo</title><rect class="cls-2" x="-0.18" y="0.48" width="1024" height="1024"/><g class="cls-3"><path class="cls-4" d="M841.84,190.26,663.36,383.15a5.69,5.69,0,0,0-1.43,5,34.9,34.9,0,0,1-59.34,31.3L460.36,561.7l14.05,187.87L634.14,909.29Z"/><path class="cls-5" d="M839.69,195.1,663.13,385.92a5.71,5.71,0,0,0-1.4,5A34.52,34.52,0,0,1,603,421.85L463.23,561.64a2.81,2.81,0,0,0-.82,2.19l13.81,184.56,356-537.11Z"/></g><g class="cls-6"><path class="cls-7" d="M834.61,183,641.72,361.51a5.73,5.73,0,0,1-5,1.43,34.9,34.9,0,0,0-31.31,59.34L463.16,564.51,275.3,550.45,115.58,390.73Z"/><path class="cls-8" d="M829.76,185.18,639,361.73a5.73,5.73,0,0,1-5,1.41A34.52,34.52,0,0,0,603,421.85L463.23,561.64a2.77,2.77,0,0,1-2.2.81L276.48,548.64l537.11-356Z"/></g></svg> \ No newline at end of file
diff --git a/recipes/lark/index.js b/recipes/lark/index.js
new file mode 100644
index 0000000..258da41
--- /dev/null
+++ b/recipes/lark/index.js
@@ -0,0 +1 @@
module.exports = Franz => Franz;
diff --git a/recipes/lark/package.json b/recipes/lark/package.json
new file mode 100644
index 0000000..35c3203
--- /dev/null
+++ b/recipes/lark/package.json
@@ -0,0 +1,15 @@
1{
2 "id": "lark",
3 "name": "Lark",
4 "version": "0.0.1",
5 "description": "Lark",
6 "main": "index.js",
7 "author": "hongsy <hongsy2006@gmail.com>",
8 "license": "MIT",
9 "config": {
10 "serviceURL": "https://{teamId}.larksuite.com/messenger/",
11 "hasTeamId": true,
12 "urlInputSuffix": ".larksuite.com",
13 "hasNotificationSound": true
14 }
15}
diff --git a/recipes/lark/service.css b/recipes/lark/service.css
new file mode 100644
index 0000000..eb94cde
--- /dev/null
+++ b/recipes/lark/service.css
@@ -0,0 +1,7 @@
1.lark-chat-left {
2 background: white;
3}
4
5.left.electron-draggable {
6 background: white;
7} \ No newline at end of file
diff --git a/recipes/lark/webview.js b/recipes/lark/webview.js
new file mode 100644
index 0000000..a3b052d
--- /dev/null
+++ b/recipes/lark/webview.js
@@ -0,0 +1,18 @@
1const path = require('path');
2
3
4module.exports = (Franz) => {
5 const getMessages = function getMessages() {
6
7 const ele = document.querySelectorAll('.larkc-badge-count.navbarMenu-badge');
8 if (!ele.length) {
9 Franz.setBadge(0);
10 return;
11 }
12 const messages = parseInt(ele[0].innerHTML, 10);
13 Franz.setBadge(messages);
14 };
15
16 Franz.injectCSS(path.join(__dirname, 'service.css'));
17 Franz.loop(getMessages);
18};