aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--README.md6
-rw-r--r--package.json2
-rwxr-xr-x[-rw-r--r--]script.sh0
-rw-r--r--src/_locales/en/messages.json3
-rw-r--r--src/assets/javascripts/translate/translate.js44
-rw-r--r--src/instances/blacklist.json8
-rw-r--r--src/instances/data.json64
-rw-r--r--src/instances/get_instances.py16
-rw-r--r--src/pages/options/index.html44
-rw-r--r--src/pages/options/widgets/translate.js32
-rw-r--r--src/pages/options/widgets/translate.pug9
11 files changed, 185 insertions, 43 deletions
diff --git a/README.md b/README.md
index 26ed7f01..2c80a614 100644
--- a/README.md
+++ b/README.md
@@ -66,6 +66,12 @@ npm update
npm install
```
+If you are modifying any files ending with .pug, the pug cli needs to be installed with the following command (with root privileges):
+```
+npm install -g pug-cli
+```
+and then run `./script.sh` to generate pages in the background.
+
### Build
```
npm run build
diff --git a/package.json b/package.json
index 004b0fb9..2f8f9abf 100644
--- a/package.json
+++ b/package.json
@@ -26,4 +26,4 @@
"dependencies": {
"buffer": "^6.0.3"
}
-} \ No newline at end of file
+}
diff --git a/script.sh b/script.sh
index 00914fd1..00914fd1 100644..100755
--- a/script.sh
+++ b/script.sh
diff --git a/src/_locales/en/messages.json b/src/_locales/en/messages.json
index 33b589bd..d3b7a355 100644
--- a/src/_locales/en/messages.json
+++ b/src/_locales/en/messages.json
@@ -209,6 +209,9 @@
"i2p": {
"message": "I2P"
},
+ "loki": {
+ "message": "Lokinet"
+ },
"testInstancesLatency": {
"message": "Test Instances Latency"
}
diff --git a/src/assets/javascripts/translate/translate.js b/src/assets/javascripts/translate/translate.js
index 62cd8334..bbf08d52 100644
--- a/src/assets/javascripts/translate/translate.js
+++ b/src/assets/javascripts/translate/translate.js
@@ -9,7 +9,9 @@ const targets = [
let redirects = {
"simplyTranslate": {
"normal": [],
- "tor": []
+ "tor": [],
+ "i2p": [],
+ "loki": []
},
"lingva": {
"normal": [],
@@ -26,6 +28,10 @@ let
simplyTranslateNormalCustomRedirects,
simplyTranslateTorRedirectsChecks,
simplyTranslateTorCustomRedirects,
+ simplyTranslateI2PRedirectsChecks,
+ simplyTranslateI2PCustomRedirects,
+ simplyTranslateLokiRedirectsChecks,
+ simplyTranslateLokiCustomReidrects,
lingvaNormalRedirectsChecks,
lingvaNormalCustomRedirects,
lingvaTorRedirectsChecks,
@@ -44,6 +50,10 @@ function init() {
"simplyTranslateNormalCustomRedirects",
"simplyTranslateTorRedirectsChecks",
"simplyTranslateTorCustomRedirects",
+ "simplyTranslateI2PRedirectsChecks",
+ "simplyTranslateI2PCustomRedirects",
+ "simplyTranslateLokiRedirectsChecks",
+ "simplyTranslateLokiCustomReidrects",
"lingvaNormalRedirectsChecks",
"lingvaNormalCustomRedirects",
@@ -59,6 +69,10 @@ function init() {
simplyTranslateNormalCustomRedirects = r.simplyTranslateNormalCustomRedirects;
simplyTranslateTorRedirectsChecks = r.simplyTranslateTorRedirectsChecks;
simplyTranslateTorCustomRedirects = r.simplyTranslateTorCustomRedirects;
+ simplyTranslateI2PRedirectsChecks = r.simplyTranslateI2PRedirectsChecks;
+ simplyTranslateI2PCustomRedirects = r.simplyTranslateI2PCustomRedirects;
+ simplyTranslateLokiRedirectsChecks = r.simplyTranslateLokiRedirectsChecks;
+ simplyTranslateLokiCustomReidrects = r.simplyTranslateLokiCustomReidrects;
lingvaNormalRedirectsChecks = r.lingvaNormalRedirectsChecks;
lingvaNormalCustomRedirects = r.lingvaNormalCustomRedirects;
lingvaTorRedirectsChecks = r.lingvaTorRedirectsChecks;
@@ -84,6 +98,8 @@ function setRedirects(val) {
translateRedirects: redirects,
simplyTranslateNormalRedirectsChecks: redirects.simplyTranslate.normal,
simplyTranslateTorRedirectsChecks: redirects.simplyTranslate.tor,
+ simplyTranslateI2PRedirectsChecks: redirects.simplyTranslate.i2p,
+ simplyTranslateLokiRedirectsChecks: redirects.simplyTranslate.loki,
lingvaNormalRedirectsChecks,
lingvaTorRedirectsChecks: redirects.lingva.tor,
})
@@ -148,11 +164,17 @@ function copyPasteSimplyTranslateCookies(test, from) {
...simplyTranslateNormalCustomRedirects,
...simplyTranslateTorRedirectsChecks,
...simplyTranslateTorCustomRedirects,
+ ...simplyTranslateI2PRedirectsChecks,
+ ...simplyTranslateI2PCustomRedirects,
+ ...simplyTranslateLokiRedirectsChecks,
+ ...simplyTranslateLokiCustomReidrects,
].includes(protocolHost)) { resolve(); return; }
if (!test) {
let checkedInstances;
if (translateProtocol == 'normal') checkedInstances = [...simplyTranslateNormalRedirectsChecks, ...simplyTranslateNormalCustomRedirects]
else if (translateProtocol == 'tor') checkedInstances = [...simplyTranslateTorRedirectsChecks, ...simplyTranslateTorCustomRedirects]
+ else if (translateProtocol == 'i2p') checkedInstances = [...simplyTranslateI2PRedirectsChecks, ...simplyTranslateI2PCustomRedirects]
+ else if (translateProtocol == 'loki') checkedInstances = [...simplyTranslateLokiRedirectsChecks, ...simplyTranslateLokiCustomReidrects]
await utils.copyCookie('simplyTranslate', from, checkedInstances, 'from_lang');
await utils.copyCookie('simplyTranslate', from, checkedInstances, 'to_lang');
await utils.copyCookie('simplyTranslate', from, checkedInstances, 'tts_enabled');
@@ -170,6 +192,8 @@ function pasteSimplyTranslateCookies() {
let checkedInstances;
if (translateProtocol == 'normal') checkedInstances = [...simplyTranslateNormalRedirectsChecks, ...simplyTranslateNormalCustomRedirects]
else if (translateProtocol == 'tor') checkedInstances = [...simplyTranslateTorRedirectsChecks, ...simplyTranslateTorCustomRedirects]
+ else if (translateProtocol == 'i2p') checkedInstances = [...simplyTranslateI2PRedirectsChecks, ...simplyTranslateI2PCustomRedirects]
+ else if (translateProtocol == 'loki') checkedInstances = [...simplyTranslateLokiRedirectsChecks, ...simplyTranslateLokiCustomReidrects]
utils.getCookiesFromStorage('simplyTranslate', checkedInstances, 'from_lang');
utils.getCookiesFromStorage('simplyTranslate', checkedInstances, 'to_lang');
utils.getCookiesFromStorage('simplyTranslate', checkedInstances, 'tts_enabled');
@@ -187,6 +211,8 @@ function redirect(url, disableOverride) {
let instancesList;
if (translateProtocol == 'normal') instancesList = [...simplyTranslateNormalRedirectsChecks, ...simplyTranslateNormalCustomRedirects];
if (translateProtocol == 'tor') instancesList = [...simplyTranslateTorRedirectsChecks, ...simplyTranslateTorCustomRedirects];
+ if (translateProtocol == 'i2p') instancesList = [...simplyTranslateI2PRedirectsChecks, ...simplyTranslateI2PCustomRedirects];
+ if (translateProtocol == 'loki') instancesList = [...simplyTranslateLokiRedirectsChecks, ...simplyTranslateLokiCustomReidrects];
if (instancesList.length === 0) return;
const randomInstance = utils.getRandomInstance(instancesList)
@@ -221,9 +247,13 @@ function switchInstance(url, disableOverride) {
if (![
...translateRedirects.simplyTranslate.normal,
...translateRedirects.simplyTranslate.tor,
+ ...translateRedirects.simplyTranslate.i2p,
+ ...translateRedirects.simplyTranslate.loki,
...simplyTranslateNormalCustomRedirects,
...simplyTranslateTorCustomRedirects,
+ ...simplyTranslateI2PCustomRedirects,
+ ...simplyTranslateLokiCustomReidrects,
...translateRedirects.lingva.normal,
...translateRedirects.lingva.tor,
@@ -241,6 +271,14 @@ function switchInstance(url, disableOverride) {
if (translateFrontend == 'simplyTranslate') instancesList = [...simplyTranslateTorRedirectsChecks, ...simplyTranslateTorCustomRedirects];
else if (translateFrontend == 'lingva') instancesList = [...lingvaTorRedirectsChecks, ...lingvaTorCustomRedirects];
}
+ else if (translateProtocol == 'i2p') {
+ if (translateFrontend == 'simplyTranslate') instancesList = [...simplyTranslateI2PRedirectsChecks, ...simplyTranslateI2PCustomRedirects];
+ //else if (translateFrontend == 'lingva') instancesList = [...lingvaI2PRedirectsChecks, ...lingvaI2PCustomRedirects];
+ }
+ else if (translateProtocol == 'loki') {
+ if (translateFrontend == 'simplyTranslate') instancesList = [...simplyTranslateLokiRedirectsChecks, ...simplyTranslateLokiCustomReidrects];
+ //else if (translateFrontend == 'lingva') instancesList = [...lingvaLokiRedirectsChecks, ...lingvaLokiCustomRedirects];
+ }
const i = instancesList.indexOf(protocolHost);
if (i > -1) instancesList.splice(i, 1);
@@ -274,6 +312,10 @@ function initDefaults() {
simplyTranslateNormalCustomRedirects: [],
simplyTranslateTorRedirectsChecks: [...redirects.simplyTranslate.tor],
simplyTranslateTorCustomRedirects: [],
+ simplyTranslateI2PRedirectsChecks: [...redirects.simplyTranslate.i2p],
+ simplyTranslateI2PCustomRedirects: [],
+ simplyTranslateLokiRedirectsChecks: [...redirects.simplyTranslate.loki],
+ simplyTranslateLokiCustomReidrects: [],
lingvaNormalRedirectsChecks: lingvaNormalRedirectsChecks,
lingvaNormalCustomRedirects: [],
diff --git a/src/instances/blacklist.json b/src/instances/blacklist.json
index 318226f5..025f5935 100644
--- a/src/instances/blacklist.json
+++ b/src/instances/blacklist.json
@@ -16,6 +16,8 @@
"https://nitter.winscloud.net",
"https://twtr.bch.bar",
"https://twitter.dr460nf1r3.org",
+ "https://nitter.wef.lol",
+ "https://nitter.catalyst.sx",
"https://bib.actionsack.com",
"https://libreddit.domain.glass",
"https://r.nf",
@@ -35,16 +37,20 @@
"https://teddit.httpjames.space",
"https://teddit.encrypted-data.xyz",
"https://wiki.604kph.xyz",
+ "https://wikiless.lunar.icu",
+ "https://lingva.lunar.icu",
"https://searx.josie.lol",
"https://searx.org",
"https://searx.run",
+ "https://searx.albony.xyz",
"https://searx.kujonello.cf",
"https://search.albony.xyz",
"https://search.garudalinux.org",
"https://search.dr460nf1r3.org",
+ "https://search.wef.lol",
"https://i.actionsack.com"
],
"authenticate": [
"https://nitter.nixnet.services"
]
-} \ No newline at end of file
+}
diff --git a/src/instances/data.json b/src/instances/data.json
index 113b6b7d..1c942300 100644
--- a/src/instances/data.json
+++ b/src/instances/data.json
@@ -14,8 +14,8 @@
"https://invidious.sethforprivacy.com",
"https://inv.bp.projectsegfau.lt",
"https://invidious.projectsegfau.lt",
- "https://invidious.nerdvpn.de",
"https://inv.vern.cc",
+ "https://invidious.nerdvpn.de",
"https://invidious.slipfox.xyz",
"https://youtube.076.ne.jp",
"https://invidious.esmailelbob.xyz",
@@ -26,7 +26,6 @@
"http://c7hqkpkpemu6e7emz5b4vyz7idjgdvgaaa3dyimmeojqbgpea3xqjoid.onion",
"http://w6ijuptxiku4xpnnaetxvnkc5vqcdu7mgns2u77qefoixi63vbvnpnqd.onion",
"http://kbjggqkzv65ivcqj6bumvp337z6264huv5kpkwuv6gu5yjiskvan7fad.onion",
- "http://grwp24hodrefzvjjuccrkw3mjq4tzhaaq32amf33dzpmuxe7ilepcmad.onion",
"http://osbivz6guyeahrwp2lnwyjk2xos342h4ocsxyqrlaopqjuhwn2djiiyd.onion",
"http://u2cvlit75owumwpy4dj2hsmvkq7nvrclkpht7xgyye2pyoxhpmclkrad.onion",
"http://euxxcnhsynwmfidvhjf6uzptsmh4dipkmgdmcmxxuo7tunp3ad2jrwyd.onion/",
@@ -141,7 +140,10 @@
"https://nitter.priv.pw",
"https://t.com.sb",
"https://nt.vern.cc",
- "https://nitter.wef.lol"
+ "https://nitter.wef.lol",
+ "https://nitter.tokhmi.xyz",
+ "https://nitter.catalyst.sx",
+ "https://unofficialbird.com"
],
"tor": [
"http://3nzoldnxplag42gqjs23xvghtzf6t6yzssrtytnntc6ppc7xxuoneoad.onion",
@@ -304,7 +306,6 @@
"wikiless": {
"normal": [
"https://wikiless.org",
- "https://wikiless.alefvanoon.xyz",
"https://wikiless.sethforprivacy.com",
"https://wiki.604kph.xyz",
"https://wikiless.lunar.icu",
@@ -342,7 +343,8 @@
"https://quora.vern.cc",
"https://quetre.pussthecat.org",
"https://wuetre.herokuapp.com",
- "https://quetreus.herokuapp.com"
+ "https://quetreus.herokuapp.com",
+ "https://quetre.tokhmi.xyz"
],
"tor": []
},
@@ -350,7 +352,8 @@
"normal": [
"https://libremdb.herokuapp.com",
"https://libremdb.pussthecat.org",
- "https://libremdbeu.herokuapp.com"
+ "https://libremdbeu.herokuapp.com",
+ "https://lmdb.tokhmi.xyz"
],
"tor": []
},
@@ -377,6 +380,12 @@
"http://fyng2tsmzmvxmojzbbwmfnsn2lrcyftf4cw6rk5j2v2huliazud3fjid.onion",
"http://xxtbwyb5z5bdvy2f6l2yquu5qilgkjeewno4qfknvb3lkg3nmoklitid.onion",
"http://translate.prnoid54e44a4bduq5due64jkk7wcnkxcp5kv3juncm7veptjcqudgyd.onion"
+ ],
+ "i2p": [
+ "http://kmnkkp4v4ublygtnyq46oacy3qw75nrxxniriuaersumw7bfsm2a.b32.i2p"
+ ],
+ "loki": [
+ "http://translate.priv.loki"
]
},
"lingva": {
@@ -393,11 +402,13 @@
"searx": {
"tor": [
"http://3afisqjw2rxm6z7mmstyt5rx75qfqrgxnkzftknbp2vhipr2nrmrjdyd.onion",
+ "http://w5rl6wsd7mzj4bdkbuqvzidet5osdsm5jhg2f7nvfidakfq5exda5wid.onion",
"http://yra4tke2pwcnatxjkufpw6kvebu3h3ti2jca2lcdpgx3mpwol326lzid.onion",
"http://z5vawdol25vrmorm4yydmohsd4u6rdoj2sylvoi3e3nqvxkvpqul7bqd.onion",
"http://zbuc3bbzbfdqqo2x46repx2ddajbha6fpsjeeptjhhhhzji3zopxdqyd.onion",
"http://f4qfqajszpx5b7itzxt6mb7kj4ktpgbdq7lq6xaiqyqx6a7de3epptad.onion",
- "http://rq2w52kyrif3xpfihkgjnhqm3a5aqhoikpv72z3drpjglfzc2wr5z4yd.onion"
+ "http://rq2w52kyrif3xpfihkgjnhqm3a5aqhoikpv72z3drpjglfzc2wr5z4yd.onion",
+ "http://searx.bsbvtqi5oq2cqzn32zt4cr2f2z2rwots3dq7gmdcnlyqoxko2wx6reqd.onion"
],
"i2p": [
"http://ransack.i2p",
@@ -408,7 +419,6 @@
"https://dynabyte.ca",
"https://jsearch.pw",
"https://nibblehole.com",
- "https://procurx.pt",
"https://search.ethibox.fr",
"https://search.jpope.org",
"https://search.snopyta.org",
@@ -427,16 +437,17 @@
"https://searx.nixnet.services",
"https://searx.openhoofd.nl",
"https://searx.org",
+ "https://searx.ppeb.me",
"https://searx.pwoss.org",
"https://searx.rasp.fr",
"https://searx.ru",
"https://searx.run",
"https://searx.semipvt.com",
- "https://searx.sethforprivacy.com",
"https://searx.sp-codes.de",
"https://searx.stuehieyr.com",
"https://searx.tuxcloud.net",
"https://searx.tyil.nl",
+ "https://searx.vanwa.tech",
"https://searx.webheberg.info",
"https://searx.xyz",
"https://searx.zapashcanon.fr",
@@ -452,7 +463,6 @@
},
"searxng": {
"tor": [
- "http://w5rl6wsd7mzj4bdkbuqvzidet5osdsm5jhg2f7nvfidakfq5exda5wid.onion",
"http://4n53nafyi77iplnbrpmxnp3x4exbswwxigujaxy3b37fvr7bvlopxeyd.onion",
"http://search3q76rqpektbrchlf2rjq4fnbxzeov6rljdywg3nwbunpgd7bid.onion",
"http://searchoorwalty5a2ailrboa2asqyts2u7bdoqwnjefpgjobpvtzn4qd.onion",
@@ -477,8 +487,8 @@
"https://search.ashs.club",
"https://search.bingowaves.xyz",
"https://search.bus-hit.me",
- "https://search.chemicals-in-the-water.eu",
"https://search.disroot.org",
+ "https://search.kiwitalk.de",
"https://search.mdosch.de",
"https://search.neet.works",
"https://search.ononoki.org",
@@ -489,12 +499,14 @@
"https://search.unlocked.link",
"https://search.vojkovic.xyz",
"https://search.zzls.xyz",
+ "https://searx.albony.xyz",
"https://searx.be",
"https://searx.becomesovran.com",
"https://searx.chocoflan.net",
"https://searx.ebnar.xyz",
"https://searx.ericaftereric.top",
"https://searx.esmailelbob.xyz",
+ "https://searx.fi",
"https://searx.fmac.xyz",
"https://searx.gnous.eu",
"https://searx.kujonello.cf",
@@ -505,6 +517,7 @@
"https://searx.orion-hub.fr",
"https://searx.priv.pw",
"https://searx.prvcy.eu",
+ "https://searx.sethforprivacy.com",
"https://searx.sev.monster",
"https://searx.slipfox.xyz/searx",
"http://fub6vgedgeadlu3ctskrpkcqjruh76tckwtj5swfhyblgml2tzgzckqd.onion/searx",
@@ -536,7 +549,8 @@
"https://whoogle.dcs0.hu",
"https://whoogle.esmailelbob.xyz",
"https://whoogle.lunar.icu",
- "https://whoogle.privacydev.net"
+ "https://whoogle.privacydev.net",
+ "https://search.wef.lol"
],
"tor": [],
"i2p": []
@@ -562,14 +576,12 @@
"peertube": [
"https://video.slipfox.xyz",
"https://pt.vern.cc",
- "https://periscope.numenaute.org",
"https://3.600900.su",
"https://vnop.org",
"https://videos.cassidypunchmachine.com",
"https://video.mullet.social",
"https://tv1.gomntu.space",
"https://dalek.zone",
- "https://syop.xyz",
"https://seka.pona.la",
"https://syop.tv",
"https://watch.thelema.social",
@@ -584,7 +596,6 @@
"https://vid.mkp.ca",
"https://jupiter.tube",
"https://tuvideo.encanarias.info",
- "https://peertube.louis.software",
"https://videos.squat.net",
"https://peertube.chaunchy.com",
"https://tube.vrpnet.org",
@@ -597,16 +608,13 @@
"https://video.olos311.org",
"https://peertube.atilla.org",
"https://video.lapineige.fr",
- "https://videos.scanlines.xyz",
"https://zapping.no-ip.info",
"https://tube.azkware.net",
"https://video.lunasqu.ee",
- "https://bundang.tube.jeena.net",
"https://v.mkp.ca",
"https://peertube.eus",
"https://infothema.net",
"https://tube.nilsu.org",
- "https://peertube.nrsk.no",
"https://podlibre.video",
"https://videos.tankernn.eu",
"https://watch.autonomous-zone.earth",
@@ -630,8 +638,10 @@
"https://tube.nestor.coop",
"https://live.oldskool.fi",
"https://dytube.com",
+ "https://video.toby3d.me",
"https://tube.thierrytalbert.fr",
"https://peertube.informaction.info",
+ "https://peertube.thele.me",
"https://tube.ac-amiens.fr",
"https://tube.alado.space",
"https://tube.network.europa.eu",
@@ -685,7 +695,6 @@
"https://tube.pawelko.net",
"https://video.livecchi.cloud",
"https://anarchy.video",
- "https://movies.toine.be",
"https://peertube.gsugambit.com",
"https://media.zat.im",
"https://videos.sadx.moe",
@@ -714,7 +723,6 @@
"https://vid.twhtv.club",
"https://video.retroedge.tech",
"https://truvitv.com",
- "https://tube.itsg.host",
"https://pt.ilyamikcoder.com",
"https://peertube.sensin.eu",
"https://watch.riverside.rocks",
@@ -724,7 +732,6 @@
"https://video.asgardius.company",
"https://video.publicspaces.net",
"https://video.eientei.org",
- "https://vhs.2xx04.xyz",
"https://tv.suwerenni.org",
"https://tube.revertron.com",
"https://tube.erzbistum-hamburg.de",
@@ -755,7 +762,6 @@
"https://video.greenmycity.eu",
"https://peertubemirror.satoshishop.de",
"https://przej.me",
- "https://tube.motuhake.xyz",
"https://pt.mezzo.moe",
"https://tube.dsocialize.net",
"https://video.pourpenser.pro",
@@ -853,6 +859,7 @@
"https://tube.1o1.io",
"https://peertube.aventer.biz",
"https://videos.rights.ninja",
+ "https://pertur.be",
"https://tube.pilgerweg-21.de",
"https://freediverse.com",
"https://pocketnetpeertube2.nohost.me",
@@ -891,7 +898,6 @@
"https://live.solari.com",
"https://live.codinglab.ch",
"https://dud-video.inf.tu-dresden.de",
- "https://peertube.negativezero.link",
"https://media-test.interior.edu.uy",
"https://media.interior.edu.uy",
"https://bitcast.online",
@@ -904,7 +910,6 @@
"https://tube.cnr.it",
"https://peertube.dtmf.ca",
"https://tube.ponsonaille.fr",
- "https://peertube.ares.bioxis-server.fr",
"https://tube.int5.net",
"https://peertube.jackbot.fr",
"https://stream.nuemedia.se",
@@ -1027,7 +1032,6 @@
"https://peertube.scyldings.com",
"https://gade.o-k-i.net",
"https://peertube.mobilsicher.de",
- "https://tube.emy.plus",
"https://video.jigmedatse.com",
"https://video.amiga-ng.org",
"https://peertube.espace.si",
@@ -1077,7 +1081,6 @@
"https://auf1.eu",
"https://tube.toontoet.nl",
"https://video.gyt.is",
- "https://peertube.0x5e.eu",
"https://peertube.jensdiemer.de",
"https://tube.futuretic.fr",
"https://libra.syntazia.org",
@@ -1166,8 +1169,6 @@
"https://video.triplea.fr",
"https://video.catgirl.biz",
"https://vulgarisation-informatique.fr",
- "https://videos.thisishowidontdisappear.com",
- "https://video.islameye.com",
"https://tube.kotur.org",
"https://peertube.euskarabildua.eus",
"https://video.veloma.org",
@@ -1199,7 +1200,6 @@
"https://tube.grap.coop",
"https://webtv.vandoeuvre.net",
"https://peertube.european-pirates.eu",
- "https://video.potate.space",
"https://video.fhtagn.org",
"https://kirche.peertube-host.de",
"https://v.lor.sh",
@@ -1276,8 +1276,6 @@
"https://videos.weblib.re",
"https://tube.oisux.org",
"https://peertube.louisematic.site",
- "https://tv2.cocu.cc",
- "https://tv1.cocu.cc",
"https://clap.nerv-project.eu",
"https://tube.lacaveatonton.ovh",
"https://peertube.tspu.edu.ru",
@@ -1422,7 +1420,6 @@
"https://vid.garwood.io",
"https://kolektiva.media",
"https://peertube.ichigo.everydayimshuflin.com",
- "https://petitlutinartube.fr",
"https://video.lundi.am",
"https://tube.florimond.eu",
"https://peertube.taxinachtegel.de",
@@ -1542,7 +1539,6 @@
"https://diode.zone",
"https://peertube.nomagic.uk",
"https://video.rastapuls.com",
- "https://video.mantlepro.com",
"https://peertube.musicstudio.pro",
"https://peertube.we-keys.fr",
"https://artitube.artifaille.fr",
@@ -1582,4 +1578,4 @@
"https://peertube2.cpy.re",
"https://peertube.cpy.re"
]
-} \ No newline at end of file
+}
diff --git a/src/instances/get_instances.py b/src/instances/get_instances.py
index 7c270843..098bc38b 100644
--- a/src/instances/get_instances.py
+++ b/src/instances/get_instances.py
@@ -279,6 +279,7 @@ def libremdb():
_list['tor'].append(item)
else:
_list['normal'].append(item)
+
mightyList['libremdb'] = _list
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Libremdb')
@@ -295,6 +296,16 @@ def simplytranslate():
for item in r.text.strip().split('\n'):
simplyTranslateList['tor'].append('http://' + item)
+ r = requests.get('https://simple-web.org/instances/simplytranslate_i2p')
+ simplyTranslateList['i2p'] = []
+ for item in r.text.strip().split('\n'):
+ simplyTranslateList['i2p'].append('http://' + item)
+
+ r = requests.get('https://simple-web.org/instances/simplytranslate_loki')
+ simplyTranslateList['loki'] = []
+ for item in r.text.strip().split('\n'):
+ simplyTranslateList['loki'].append('http://' + item)
+
mightyList['simplyTranslate'] = simplyTranslateList
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'SimplyTranslate')
@@ -308,6 +319,7 @@ def linvgatranslate():
lingvaList['tor'] = []
for item in rJson:
lingvaList['normal'].append(item)
+
mightyList['lingva'] = lingvaList
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'LinvgaTranslate')
@@ -432,9 +444,9 @@ for k1, v1 in mightyList.items():
mightyList[k1][k2].remove(instance)
print("removed " + instance)
else:
- if not instance.endswith('.onion') and not instance.endswith('.i2p') and is_cloudflare(instance):
+ if not instance.endswith('.onion') and not instance.endswith('.i2p') and not instance.endswith('.loki') and is_cloudflare(instance):
cloudflare.append(instance)
- if not instance.endswith('.onion') and not instance.endswith('.i2p') and is_authenticate(instance):
+ if not instance.endswith('.onion') and not instance.endswith('.i2p') and not instance.endswith('.loki') and is_authenticate(instance):
authenticate.append(instance)
peertube()
diff --git a/src/pages/options/index.html b/src/pages/options/index.html
index 6d97cfac..241a20e7 100644
--- a/src/pages/options/index.html
+++ b/src/pages/options/index.html
@@ -1765,6 +1765,8 @@
<select id="translate-protocol">
<option value="normal" data-localise="__MSG_normal__">Normal</option>
<option value="tor" data-localise="__MSG_tor__">Tor</option>
+ <option value="i2p" data-localise="__MSG_i2p__">I2P</option>
+ <option value="loki" data-localise="__MSG_loki__">Lokinet</option>
</select>
</div>
<hr>
@@ -1820,6 +1822,48 @@
</form>
<div class="checklist custom-checklist"></div>
</div>
+ <div class="i2p">
+ <div class="some-block option-block">
+ <h4 data-localise="__MSG_defaultInstances__">Default Instances</h4>
+ </div>
+ <div class="checklist"></div>
+ <hr>
+ <div class="some-block option-block">
+ <h4 data-localise="__MSG_customInstances__">Custom Instances</h4>
+ </div>
+ <form class="custom-instance-form">
+ <div class="some-block option-block">
+ <input class="custom-instance" placeholder="http://simplytranslate.i2p" type="url">
+ <button class="add add-instance" type="submit">
+ <svg xmlns="https://www.w3.org/2000/svg" height="20px" viewBox="0 0 24 24" width="20px" fill="currentColor">
+ <path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"></path>
+ </svg>
+ </button>
+ </div>
+ </form>
+ <div class="checklist custom-checklist"></div>
+ </div>
+ <div class="loki">
+ <div class="some-block option-block">
+ <h4 data-localise="__MSG_defaultInstances__">Default Instances</h4>
+ </div>
+ <div class="checklist"></div>
+ <hr>
+ <div class="some-block option-block">
+ <h4 data-localise="__MSG_customInstances__">Custom Instances</h4>
+ </div>
+ <form class="custom-instance-form">
+ <div class="some-block option-block">
+ <input class="custom-instance" placeholder="http://simplytranslate.loki" type="url">
+ <button class="add add-instance" type="submit">
+ <svg xmlns="https://www.w3.org/2000/svg" height="20px" viewBox="0 0 24 24" width="20px" fill="currentColor">
+ <path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"></path>
+ </svg>
+ </button>
+ </div>
+ </form>
+ <div class="checklist custom-checklist"></div>
+ </div>
</div>
<div id="lingva">
<div class="normal">
diff --git a/src/pages/options/widgets/translate.js b/src/pages/options/widgets/translate.js
index 3e1f53eb..04869b63 100644
--- a/src/pages/options/widgets/translate.js
+++ b/src/pages/options/widgets/translate.js
@@ -22,6 +22,8 @@ function changeFrontendsSettings() {
function changeProtocolSettings() {
const normalSimplyTranslateDiv = document.getElementById("simplyTranslate").getElementsByClassName("normal")[0];
const torSimplyTranslateDiv = document.getElementById("simplyTranslate").getElementsByClassName("tor")[0];
+ const i2pSimplyTranslateDiv = document.getElementById("simplyTranslate").getElementsByClassName("i2p")[0];
+ const lokiSimplyTranslateDiv = document.getElementById("simplyTranslate").getElementsByClassName("loki")[0];
const normalLingvaDiv = document.getElementById("lingva").getElementsByClassName("normal")[0];
const torLingvaDiv = document.getElementById("lingva").getElementsByClassName("tor")[0];
@@ -29,14 +31,34 @@ function changeProtocolSettings() {
if (protocol.value == 'normal') {
normalSimplyTranslateDiv.style.display = 'block';
normalLingvaDiv.style.display = 'block';
- torLingvaDiv.style.display = 'none';
torSimplyTranslateDiv.style.display = 'none';
+ torLingvaDiv.style.display = 'none';
+ i2pSimplyTranslateDiv.style.display = 'none';
+ lokiSimplyTranslateDiv.style.display = 'none';
}
else if (protocol.value == 'tor') {
normalSimplyTranslateDiv.style.display = 'none';
normalLingvaDiv.style.display = 'none';
- torLingvaDiv.style.display = 'block';
torSimplyTranslateDiv.style.display = 'block';
+ torLingvaDiv.style.display = 'block';
+ i2pSimplyTranslateDiv.style.display = 'none';
+ lokiSimplyTranslateDiv.style.display = 'none';
+ }
+ else if (protocol.value == 'i2p') {
+ normalSimplyTranslateDiv.style.display = 'none';
+ normalLingvaDiv.style.display = 'none';
+ torSimplyTranslateDiv.style.display = 'none';
+ torLingvaDiv.style.display = 'none';
+ i2pSimplyTranslateDiv.style.display = 'block';
+ lokiSimplyTranslateDiv.style.display = 'none';
+ }
+ else if (protocol.value == 'loki') {
+ normalSimplyTranslateDiv.style.display = 'none';
+ normalLingvaDiv.style.display = 'none';
+ torSimplyTranslateDiv.style.display = 'none';
+ torLingvaDiv.style.display = 'none';
+ i2pSimplyTranslateDiv.style.display = 'none';
+ lokiSimplyTranslateDiv.style.display = 'block';
}
}
@@ -66,10 +88,12 @@ translate.addEventListener("change", () => {
})
-utils.processDefaultCustomInstances('translate', 'simplyTranslate', 'normal', document)
+utils.processDefaultCustomInstances('translate', 'simplyTranslate', 'normal', document);
utils.processDefaultCustomInstances('translate', 'simplyTranslate', 'tor', document);
+utils.processDefaultCustomInstances('translate', 'simplyTranslate', 'i2p', document);
+utils.processDefaultCustomInstances('translate', 'simplyTranslate', 'loki', document);
utils.processDefaultCustomInstances('translate', 'lingva', 'normal', document);
utils.processDefaultCustomInstances('translate', 'lingva', 'tor', document);
utils.latency('translate', 'simplyTranslate', document, location, true)
-utils.latency('translate', 'lingva', document, location, true) \ No newline at end of file
+utils.latency('translate', 'lingva', document, location, true)
diff --git a/src/pages/options/widgets/translate.pug b/src/pages/options/widgets/translate.pug
index 6fc9b38c..c29d75e1 100644
--- a/src/pages/options/widgets/translate.pug
+++ b/src/pages/options/widgets/translate.pug
@@ -17,6 +17,8 @@ section#translate_page.option-block
select#translate-protocol
option(value="normal" data-localise="__MSG_normal__") Normal
option(value="tor" data-localise="__MSG_tor__") Tor
+ option(value="i2p" data-localise="__MSG_i2p__") I2P
+ option(value="loki" data-localise="__MSG_loki__") Lokinet
hr
#simplyTranslate
@@ -28,6 +30,13 @@ section#translate_page.option-block
.tor
include ../../widgets/instances.pug
+instances('http://hxecvvetgrznmprg.onion')
+ .i2p
+ include ../../widgets/instances.pug
+ +instances('http://simplytranslate.i2p')
+ .loki
+ include ../../widgets/instances.pug
+ +instances('http://simplytranslate.loki')
+
#lingva
.normal
include ../../widgets/instances.pug