aboutsummaryrefslogtreecommitdiffstats
path: root/recipes
diff options
context:
space:
mode:
authorLibravatar André Oliveira <oliveira.andrerodrigues95@gmail.com>2023-01-13 17:36:14 +0000
committerLibravatar Vijay Aravamudhan <vraravam@users.noreply.github.com>2023-01-14 04:42:25 +0530
commit00c0a3f79a9a8fd5bd2025c922557e48a7a4b401 (patch)
tree7a810b558d17f4ac05a5c7e23012180a83a3ded4 /recipes
parentFix: Infomaniak unread messages badge to exclude spam emails (#273) (diff)
downloadferdium-recipes-00c0a3f79a9a8fd5bd2025c922557e48a7a4b401.tar.gz
ferdium-recipes-00c0a3f79a9a8fd5bd2025c922557e48a7a4b401.tar.zst
ferdium-recipes-00c0a3f79a9a8fd5bd2025c922557e48a7a4b401.zip
feat: add ChatGPT recipe
Diffstat (limited to 'recipes')
-rw-r--r--recipes/chatgpt/icon.svg48
-rw-r--r--recipes/chatgpt/index.js18
-rw-r--r--recipes/chatgpt/package.json9
-rw-r--r--recipes/chatgpt/webview.js1
4 files changed, 76 insertions, 0 deletions
diff --git a/recipes/chatgpt/icon.svg b/recipes/chatgpt/icon.svg
new file mode 100644
index 0000000..116e5d5
--- /dev/null
+++ b/recipes/chatgpt/icon.svg
@@ -0,0 +1,48 @@
1<?xml version="1.0" encoding="utf-8"?>
2<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
3 viewBox="0 0 225.9 225.9" style="enable-background:new 0 0 225.9 225.9;" xml:space="preserve">
4<style type="text/css">
5 .st0{fill:#74A89B;}
6 .st1{fill:#FFFFFF;}
7</style>
8<path class="st0" d="M0,59.24v104.2c0,4.38,0.42,8.77,1.41,13.04c4.76,20.52,15.95,35.21,33.83,43.87c7.86,3.8,16.56,5.55,25.3,5.55
9 l165.37,0l0-166.72c0-20.05-9.7-39.2-26.62-49.96c-0.34-0.21-0.67-0.42-1.01-0.63C188.95,2.87,178.16,0,167.23,0H59.44
10 C48.53,0,37.7,2.75,28.47,8.57C20.7,13.48,13.68,19.9,8.07,29.14C2.58,38.17,0,48.67,0,59.24z"/>
11<g>
12 <path class="st1" d="M120.6,197.4c-8.82-0.08-17.76-3.13-25.53-9.4c-1.61-1.3-3.04-2.82-4.53-4.26c-0.31-0.3-0.54-0.47-1.05-0.37
13 c-12.68,2.32-24.26-0.29-34.46-8.17c-8.12-6.27-13.25-14.58-15.53-24.6c-1.65-7.25-1.26-14.44,0.93-21.53
14 c0.18-0.58,0.09-0.95-0.3-1.39c-5.27-6.07-8.61-13.09-9.89-21.02c-1.62-10.03,0.13-19.49,5.22-28.28
15 c5.63-9.71,13.85-16.22,24.6-19.49c0.9-0.27,1.8-0.55,2.72-0.7c0.59-0.1,0.81-0.38,1-0.91c4.01-11.21,11.33-19.5,22.07-24.66
16 c7.57-3.63,15.59-4.82,23.91-3.72c10.11,1.33,18.63,5.8,25.58,13.26c0.32,0.35,0.58,0.5,1.12,0.4c12.65-2.3,24.2,0.29,34.38,8.15
17 c8.41,6.5,13.62,15.12,15.75,25.56c1.42,6.97,0.97,13.85-1.13,20.63c-0.17,0.54-0.09,0.9,0.28,1.32c5.05,5.8,8.29,12.49,9.74,20.03
18 c0.89,4.66,0.98,9.34,0.29,14.04c-1.19,8.05-4.41,15.18-9.61,21.41c-6.11,7.32-13.88,11.95-23.16,14.08
19 c-0.48,0.11-0.69,0.32-0.84,0.75c-4.21,11.86-12.06,20.38-23.57,25.45C133.24,196.33,127.59,197.41,120.6,197.4z M124.31,46.89
20 c-0.35-0.29-0.6-0.51-0.86-0.71c-8.11-6.06-17.13-7.98-26.96-5.66c-13.89,3.27-23.98,16.14-23.99,30.39
21 c-0.01,12.91,0,25.82-0.02,38.72c0,0.74,0.19,1.2,0.87,1.59c3.97,2.25,7.9,4.55,11.85,6.83c0.54,0.31,1.08,0.6,1.76,0.98
22 c0-0.51,0-0.86,0-1.21c0-15.29,0.01-30.58-0.01-45.87c0-2.32,0.95-4.04,2.95-5.19c7.08-4.09,14.17-8.18,21.25-12.27
23 C115.52,51.97,119.87,49.46,124.31,46.89z M138.94,106.88c0,0.56,0,0.91,0,1.27c0,15.26-0.01,30.52,0.01,45.78
24 c0,2.31-0.91,4.05-2.91,5.21c-8.49,4.91-16.99,9.81-25.48,14.71c-2.96,1.71-5.92,3.42-8.95,5.17c0.28,0.24,0.5,0.45,0.74,0.63
25 c8.35,6.27,17.63,8.2,27.73,5.56c13.53-3.54,23.24-16.03,23.32-29.91c0.07-13.07,0.01-26.15,0.03-39.22c0-0.63-0.19-0.99-0.75-1.31
26 c-2.93-1.66-5.84-3.37-8.76-5.05C142.31,108.81,140.71,107.89,138.94,106.88z M50.07,136.17c-0.58,3.19-0.63,6.26-0.22,9.31
27 c0.92,6.83,3.64,12.86,8.47,17.79c7.76,7.91,17.2,11.03,28.17,9.41c4.32-0.64,8.22-2.4,11.98-4.59
28 c10.62-6.19,21.28-12.31,31.94-18.44c0.6-0.34,0.85-0.72,0.84-1.43c-0.03-4.93-0.02-9.86-0.02-14.79c0-0.27,0-0.53,0-0.92
29 c-0.33,0.16-0.54,0.26-0.75,0.38c-7.49,4.32-14.98,8.65-22.47,12.97c-5.81,3.36-11.64,6.7-17.44,10.08
30 c-2.08,1.21-4.11,1.28-6.19,0.05c-2.07-1.22-4.16-2.41-6.24-3.61c-7.68-4.44-15.36-8.87-23.04-13.31
31 C53.47,138.11,51.82,137.17,50.07,136.17z M94.68,93.47c0.79-0.45,1.43-0.81,2.06-1.18c7.61-4.4,15.21-8.79,22.82-13.19
32 c5.31-3.07,10.63-6.13,15.94-9.2c2-1.15,3.97-1.16,5.97,0.01c2.07,1.22,4.16,2.41,6.24,3.61c7.7,4.45,15.41,8.9,23.11,13.35
33 c1.64,0.95,3.29,1.89,4.95,2.84c0.07-0.15,0.12-0.21,0.14-0.29c0.64-3.98,0.52-7.94-0.35-11.87c-2.9-13.15-13.99-23.12-27.41-24.58
34 c-7.08-0.77-13.67,0.75-19.81,4.32c-6.83,3.97-13.68,7.92-20.52,11.88c-4.16,2.41-8.33,4.8-12.48,7.23
35 c-0.3,0.18-0.65,0.6-0.65,0.91C94.67,82.64,94.68,87.96,94.68,93.47z M61.43,70.09c-0.47,0.18-0.83,0.3-1.18,0.45
36 c-12.88,5.29-21.35,19.03-19.11,33.74c1.46,9.62,6.24,17.26,14.58,22.27c11.36,6.84,22.93,13.33,34.4,19.98
37 c0.46,0.27,0.84,0.25,1.3-0.02c4.39-2.56,8.8-5.09,13.2-7.64c0.17-0.1,0.33-0.23,0.53-0.39c-5.91-3.42-11.75-6.8-17.58-10.17
38 c-7.7-4.45-15.4-8.91-23.11-13.34c-2.08-1.19-3.03-2.95-3.02-5.32c0.01-12.82,0-25.64,0-38.46C61.43,70.87,61.43,70.54,61.43,70.09
39 z M164.48,155.83c0.3-0.11,0.51-0.18,0.71-0.26c13.63-5.36,22.14-19.75,19.45-34.82c-1.61-9.03-6.29-16.15-14.01-21.14
40 c-3.48-2.25-7.14-4.2-10.73-6.27c-8.03-4.65-16.07-9.29-24.1-13.95c-0.46-0.26-0.83-0.26-1.3,0.01c-4.39,2.56-8.8,5.09-13.2,7.64
41 c-0.18,0.1-0.33,0.24-0.55,0.39c4.86,2.81,9.64,5.58,14.42,8.34c8.78,5.07,17.56,10.15,26.34,15.21c2.01,1.16,2.96,2.89,2.95,5.19
42 c0,12.9,0,25.81,0,38.71C164.48,155.16,164.48,155.44,164.48,155.83z M131.24,112.98c0-3.27-0.02-6.54,0.02-9.8
43 c0.01-0.58-0.19-0.88-0.67-1.16c-5.7-3.27-11.4-6.56-17.09-9.86c-0.37-0.21-0.62-0.26-1.03-0.02c-5.71,3.32-11.43,6.62-17.16,9.9
44 c-0.46,0.26-0.64,0.55-0.64,1.09c0.02,6.54,0.02,13.07,0,19.61c0,0.58,0.19,0.88,0.67,1.16c5.7,3.27,11.4,6.56,17.09,9.86
45 c0.37,0.21,0.62,0.26,1.03,0.02c5.71-3.32,11.43-6.62,17.16-9.9c0.46-0.26,0.64-0.55,0.64-1.09
46 C131.22,119.52,131.24,116.25,131.24,112.98z"/>
47</g>
48</svg>
diff --git a/recipes/chatgpt/index.js b/recipes/chatgpt/index.js
new file mode 100644
index 0000000..80eaf51
--- /dev/null
+++ b/recipes/chatgpt/index.js
@@ -0,0 +1,18 @@
1module.exports = (Ferdium) => class Messenger extends Ferdium {
2 overrideUserAgent() {
3 return window.navigator.userAgent.replace(/(Ferdium|Electron)\/\S+ \([^)]+\)/g, '').trim();
4 }
5
6 modifyRequestHeaders() {
7 return [
8 {
9 headers: {
10 'user-agent': window.navigator.userAgent.replace(/(Ferdium|Electron)\/\S+ \([^)]+\)/g, '').trim(),
11 },
12 requestFilters: {
13 urls: ['*://*/*'],
14 },
15 },
16 ];
17 }
18};
diff --git a/recipes/chatgpt/package.json b/recipes/chatgpt/package.json
new file mode 100644
index 0000000..aeed764
--- /dev/null
+++ b/recipes/chatgpt/package.json
@@ -0,0 +1,9 @@
1{
2 "id": "chatgpt",
3 "name": "ChatGPT",
4 "version": "1.0.0",
5 "license": "MIT",
6 "config": {
7 "serviceURL": "https://chat.openai.com/chat"
8 }
9}
diff --git a/recipes/chatgpt/webview.js b/recipes/chatgpt/webview.js
new file mode 100644
index 0000000..dd41f72
--- /dev/null
+++ b/recipes/chatgpt/webview.js
@@ -0,0 +1 @@
module.exports = Ferdium => Ferdium;