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/googledrive/README.md | 16 ++++ recipes/googledrive/icon.png | Bin 0 -> 50522 bytes recipes/googledrive/icon.svg | 193 +++++++++++++++++++++++++++++++++++++++ recipes/googledrive/index.js | 18 ++++ recipes/googledrive/package.json | 25 +++++ recipes/googledrive/service.css | 5 + recipes/googledrive/webview.js | 16 ++++ 7 files changed, 273 insertions(+) create mode 100644 recipes/googledrive/README.md create mode 100644 recipes/googledrive/icon.png create mode 100644 recipes/googledrive/icon.svg create mode 100644 recipes/googledrive/index.js create mode 100644 recipes/googledrive/package.json create mode 100644 recipes/googledrive/service.css create mode 100644 recipes/googledrive/webview.js (limited to 'recipes/googledrive') diff --git a/recipes/googledrive/README.md b/recipes/googledrive/README.md new file mode 100644 index 0000000..2304ba2 --- /dev/null +++ b/recipes/googledrive/README.md @@ -0,0 +1,16 @@ +# Google Drive for Franz + +Google Drive Recipe for [Franz](http://meetfranz.com), fixed for files not being displayed. + +### Installation + +1. Download/clone this repo to your computer + +2. Copy the recipe folder to the following location (you may need to create the `dev` folder): +* Mac: `~/Library/Application Support/Franz/recipes/dev/` +* Windows: `%appdata%/Franz/recipes/dev/` +* Linux: `~/.config/Franz/recipes/dev` + +3. Relaod Franz + +4. Navigate to "Add Service -> Development" section in Franz. \ No newline at end of file diff --git a/recipes/googledrive/icon.png b/recipes/googledrive/icon.png new file mode 100644 index 0000000..b56e0b2 Binary files /dev/null and b/recipes/googledrive/icon.png differ diff --git a/recipes/googledrive/icon.svg b/recipes/googledrive/icon.svg new file mode 100644 index 0000000..a18f9cf --- /dev/null +++ b/recipes/googledrive/icon.svg @@ -0,0 +1,193 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/recipes/googledrive/index.js b/recipes/googledrive/index.js new file mode 100644 index 0000000..aacc1ac --- /dev/null +++ b/recipes/googledrive/index.js @@ -0,0 +1,18 @@ +var os = require('os') + +module.exports = Franz => + class googledrive extends Franz { + modifyRequestHeaders() { + return [ + { + headers: { + 'user-agent': window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+ \([^)]+\)/g, '').trim(), + 'origin': 'https://drive.google.com' + }, + requestFilters: { + urls: ['*://*/*'], + }, + }, + ]; + } + }; diff --git a/recipes/googledrive/package.json b/recipes/googledrive/package.json new file mode 100644 index 0000000..755dcff --- /dev/null +++ b/recipes/googledrive/package.json @@ -0,0 +1,25 @@ +{ + "id": "googledrive", + "name": "Google Drive", + "version": "1.0.5", + "description": "Google Drive", + "main": "index.js", + "author": "Djonathan Goulart", + "repository": "https://github.com/BrianGilbert/franz-recipe-tawk", + "license": "MIT", + "config": { + "serviceURL": "https://drive.google.com/", + "serviceName": "Google Drive", + "message": "", + "popup": [], + "hasNotificationSound": false, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/recipes/googledrive/service.css b/recipes/googledrive/service.css new file mode 100644 index 0000000..b453fd4 --- /dev/null +++ b/recipes/googledrive/service.css @@ -0,0 +1,5 @@ +.app-wrapper-web .app { + width: 100% !important; + height: 100% !important; + top: 0 !important; +} diff --git a/recipes/googledrive/webview.js b/recipes/googledrive/webview.js new file mode 100644 index 0000000..64a0219 --- /dev/null +++ b/recipes/googledrive/webview.js @@ -0,0 +1,16 @@ +module.exports = (Franz, options) => { + window.chrome = { + runtime: { + connect: () => { + return { + onMessage: { + addListener: () => {console.warn('chrome.runtime is not implemented')}, + removeListener: () => {console.warn('chrome.runtime is not implemented')}, + }, + postMessage: () => {console.warn('chrome.runtime is not implemented')}, + disconnect: () => {console.warn('chrome.runtime is not implemented')}, + } + } + } + } +} \ No newline at end of file -- cgit v1.2.3-70-g09d2