diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/assets/javascripts/helpers/google-translate.js | 26 | ||||
-rw-r--r-- | src/assets/javascripts/helpers/medium.js | 26 | ||||
-rw-r--r-- | src/pages/background/background.js | 2 |
3 files changed, 33 insertions, 21 deletions
diff --git a/src/assets/javascripts/helpers/google-translate.js b/src/assets/javascripts/helpers/google-translate.js index 2d3e31a3..04501f9b 100644 --- a/src/assets/javascripts/helpers/google-translate.js +++ b/src/assets/javascripts/helpers/google-translate.js @@ -1,12 +1,26 @@ -const targets = ["translate.google.com", "translate.google.no"]; +const targets = [ + "translate.google.com", + "translate.google.no" +]; -const redirects = ["https://translate.metalune.xyz", "https://simplytranslate.org", -"https://st.alefvanoon.xyz", -"https://translate.josias.dev", -"https://translate.namazso.eu", -"https://translate.riverside.rocks",]; +const redirects = [ + "https://translate.metalune.xyz", + "https://simplytranslate.org", + "https://st.alefvanoon.xyz", + "https://translate.josias.dev", + "https://translate.namazso.eu", + "https://translate.riverside.rocks", + "https://manerakai.asuscomm.com:447", + "https://translate.bus-hit.me" +]; export default { targets, redirects, }; + + + + + + diff --git a/src/assets/javascripts/helpers/medium.js b/src/assets/javascripts/helpers/medium.js index 9f14902c..039e780c 100644 --- a/src/assets/javascripts/helpers/medium.js +++ b/src/assets/javascripts/helpers/medium.js @@ -1,18 +1,16 @@ const targets = [ - "medium.com", - /.*.medium.com/, - /* Other domains of medium blogs, source(s): - * https://findingtom.com/best-medium-blogs-to-follow/#1-forge - * */ - "towardsdatascience.com", - "uxdesign.cc", - "uxplanet.org", - "betterprogramming.pub", - "aninjusticemag.com", - "betterhumans.pub", - "psiloveyou.xyz", - "entrepreneurshandbook.co", - "blog.coinbase.com" + /.*medium.com/, + /.*\.medium.com/, + // Other domains of medium blogs, source(s): https://findingtom.com/best-medium-blogs-to-follow/#1-forge + /towardsdatascience.com/, + /uxdesign.cc/, + /uxplanet.org/, + /betterprogramming.pub/, + /aninjusticemag.com/, + /betterhumans.pub/, + /psiloveyou.xyz/, + /entrepreneurshandbook.co/, + /blog.coinbase.com/ ]; const redirects = [ diff --git a/src/pages/background/background.js b/src/pages/background/background.js index 3f710994..aae71834 100644 --- a/src/pages/background/background.js +++ b/src/pages/background/background.js @@ -652,7 +652,7 @@ browser.webRequest.onBeforeRequest.addListener( redirect = { redirectUrl: redirectReddit(url, initiator, details.type), }; - } else if (mediumDomains.includes(url.host)) { + } else if (mediumDomains.some((rx) => rx.test(url.host))) { redirect = { redirectUrl: redirectMedium(url, initiator), }; |