Parcourir la source

Add donation links to Firefox extensions

Added donation links to Firefox extensions
sy-b il y a 3 ans
Parent
commit
aee36b0ff6
2 fichiers modifiés avec 18 ajouts et 1 suppressions
  1. 6 0
      Extensions/firefox/popup.html
  2. 12 1
      Extensions/firefox/popup.js

+ 6 - 0
Extensions/firefox/popup.html

@@ -20,6 +20,12 @@
       <button id="link_github">GitHub</button>
       <button id="link_discord">Discord</button>
 
+      <br><br>
+      <p>Donate</p>
+      <button id="link_patreon">Patreon</button>
+      <button id="link_yoomoney">Yoomoney</button>
+      <br>
+
       <br>
 <!--      <button id="advancedToggle">Show Settings</button>-->
       <br>

+ 12 - 1
Extensions/firefox/popup.js

@@ -7,7 +7,9 @@ const config = {
   links: {
     website: 'https://returnyoutubedislike.com',
     github: 'https://github.com/Anarios/return-youtube-dislike',
-    discord: 'https://discord.gg/mYnESY4Md5'
+    discord: 'https://discord.gg/mYnESY4Md5',
+    patreon: 'https://www.patreon.com/returnyoutubedislike',
+    yoomoney: 'https://returnyoutubedislike.com/pay/yoomoney'
   },
 };
 
@@ -24,6 +26,15 @@ document.getElementById('link_discord').addEventListener('click', () => {
   chrome.tabs.create({url: config.links.discord});
 });
 
+document.getElementById('link_patreon').addEventListener('click', () => {
+  chrome.tabs.create({url: config.links.patreon});
+});
+
+document.getElementById('link_yoomoney').addEventListener('click', () => {
+  chrome.tabs.create({url: config.links.yoomoney});
+});
+
+
 /*   Advanced Toggle   */
 const advancedToggle = document.getElementById('advancedToggle');
 advancedToggle.addEventListener('click', () => {