From 30e5ae7121525521a99d52881d51570213eda688 Mon Sep 17 00:00:00 2001 From: frost768 Date: Mon, 29 May 2023 22:10:07 +0300 Subject: [PATCH 1/3] add missing translation keys and polish translation --- src/components/popout/FloatingCard.tsx | 2 +- src/setup/i18n.ts | 4 + src/setup/locales/en/translation.json | 11 +- src/setup/locales/pl/translation.json | 137 ++++++++++++++++++ src/setup/locales/tr/translation.json | 11 +- .../popouts/EpisodeSelectionPopout.tsx | 15 +- 6 files changed, 171 insertions(+), 9 deletions(-) create mode 100644 src/setup/locales/pl/translation.json diff --git a/src/components/popout/FloatingCard.tsx b/src/components/popout/FloatingCard.tsx index b4fd250c..47bfcb59 100644 --- a/src/components/popout/FloatingCard.tsx +++ b/src/components/popout/FloatingCard.tsx @@ -154,7 +154,7 @@ export const FloatingCardView = { className="flex cursor-pointer items-center space-x-2 transition-colors duration-200 hover:text-white" > - Close + {t("videoPlayer.popouts.close")} ); diff --git a/src/setup/i18n.ts b/src/setup/i18n.ts index 6116434a..d3aa261f 100644 --- a/src/setup/i18n.ts +++ b/src/setup/i18n.ts @@ -9,6 +9,7 @@ import en from "./locales/en/translation.json"; import fr from "./locales/fr/translation.json"; import nl from "./locales/nl/translation.json"; import pirate from "./locales/pirate/translation.json"; +import pl from "./locales/pl/translation.json"; import tr from "./locales/tr/translation.json"; import zh from "./locales/zh/translation.json"; @@ -37,6 +38,9 @@ const locales = { pirate: { translation: pirate, }, + pl: { + translation: pl, + }, }; i18n // pass the i18n instance to react-i18next. diff --git a/src/setup/locales/en/translation.json b/src/setup/locales/en/translation.json index d8b81da4..d90b568b 100644 --- a/src/setup/locales/en/translation.json +++ b/src/setup/locales/en/translation.json @@ -71,7 +71,16 @@ "popouts": { "back": "Go back", "sources": "Sources", - "seasons": "Seasons", + "close": "Close", + "seasons": { + "title":"Seasons", + "other": "Other seasons", + "noSeason": "No season" + }, + "episodes": { + "unknown": "Unknown episode", + "noEpisode": "No episode" + }, "captions": "Captions", "playbackSpeed": "Playback speed", "customPlaybackSpeed": "Custom playback speed", diff --git a/src/setup/locales/pl/translation.json b/src/setup/locales/pl/translation.json new file mode 100644 index 00000000..a85d9c70 --- /dev/null +++ b/src/setup/locales/pl/translation.json @@ -0,0 +1,137 @@ +{ + "global": { + "name": "movie-web" + }, + "search": { + "loading_series": "Szukamy twoich ulubionych seriali...", + "loading_movie": "Szukamy twoich ulubionych filmów...", + "loading": "Wczytywanie...", + "allResults": "To wszystko co mamy!", + "noResults": "Nie mogliśmy niczego znaleźć!", + "allFailed": "Nie udało się znaleźć mediów, Spróbuj ponownie!", + "headingTitle": "Wyniki wyszukiwania", + "bookmarks": "Zakładki", + "continueWatching": "Kontynuuj oglądanie", + "title": "Co chciałbyś obejrzeć?", + "placeholder": "Co chciałbyś obejrzeć?" + }, + "media": { + "movie": "Film", + "series": "Serial", + "stopEditing": "Zatrzymaj edycje", + "errors": { + "genericTitle": "Ups, popsuło się!", + "failedMeta": "Nie udało się wczytać metadanych", + "mediaFailed": "Nie udało nam się zarządać mediów, sprawdź połączenie sieciowe i spróbuj ponownie.", + "videoFailed": "Napotkaliśmy błąd podczas odtwarzania rządanego video. Jeśli problem będzie się powtarzać prosimy o zgłoszenie problemu na <0>Serwer Discord lub na <1>GitHub." + } + }, + "seasons": { + "seasonAndEpisode": "S{{season}} E{{episode}}" + }, + "notFound": { + "genericTitle": "Nie znaleziono", + "backArrow": "Wróć na stronę główną", + "media": { + "title": "Nie można znaleźć multimediów", + "description": "Nie mogliśmy znaleźć rządanych multimediów. Albo zostały usunięte, albo grzebałeś przy adresie URL." + }, + "provider": { + "title": "Ten dostawca został wyłączony", + "description": "Mieliśmy problemy z tym dostawcą, albo był zbyt niestabilny, więc musieliśmy go wyłączyć." + }, + "page": { + "title": "Nie można znaleźć tej strony", + "description": "Szukaliśmy wszędzie: w koszu, w szafie a nawet w piwnicy, ale nie byliśmy w stanie znaleźć strony której szukasz." + } + }, + "searchBar": { + "movie": "Filmy", + "series": "Seriale", + "Search": "Szukaj" + }, + "videoPlayer": { + "findingBestVideo": "Szukamy najlepszego video dla ciebie", + "noVideos": "Oj, Nie mogliśmy znaleźć żadnego video", + "loading": "Wczytywanie...", + "backToHome": "Wróć na stronę główną", + "backToHomeShort": "Wróć", + "seasonAndEpisode": "S{{season}} E{{episode}}", + "timeLeft": "Pozostało {{timeLeft}}", + "finishAt": "Zakończ na {{timeFinished, datetime}}", + "buttons": { + "episodes": "Odcinki", + "source": "Źródło", + "captions": "Napisy", + "download": "Pobierz", + "settings": "Ustawienia", + "pictureInPicture": "Obraz w obrazie (PIP)", + "playbackSpeed": "Prędkość odtwarzania" + }, + "popouts": { + "close": "Zamknąć", + "seasons": { + "title":"Sezony", + "other": "Inne sezony", + "noSeason": "Brak sezonu" + }, + "episodes": { + "unknown": "Nieznany odcinki", + "noEpisode": "Brak odcinki" + }, + "back": "Wróć", + "sources": "Źródła", + "captions": "Napisy", + "playbackSpeed": "Prędkość odtwarzania", + "customPlaybackSpeed": "Niestandardowa prędkość odtwarzania", + "captionPreferences": { + "title": "Personalizuj", + "delay": "Opóźnienie", + "fontSize": "Rozmiar", + "opacity": "Przeźroczystość", + "color": "Kolor" + }, + "episode": "E{{index}} - {{title}}", + "noCaptions": "Brak napisów", + "linkedCaptions": "Załączone napisy", + "customCaption": "Napisy niestandardowe", + "uploadCustomCaption": "Załącz", + "noEmbeds": "Nie znaleziono osadzonych mediów dla tego źródła", + + "errors": { + "loadingWentWong": "Coś poszło nie tak {{seasonTitle}}", + "embedsError": "Coś poszło nie tak przy wczytywaniu osadzonych mediów" + }, + "descriptions": { + "sources": "Którego dostawcy chciałbyś używać?", + "embeds": "Wybierz, które video chcesz zobaczyć", + "seasons": "Wybierz, który sezon chcesz obejrzeć", + "episode": "Wybierz odcinek", + "captions": "Zmień język napisów", + "captionPreferences": "Ustaw napisy, tak jak ci to odpowiada", + "playbackSpeed": "Zmień prędkość odtwarzania" + } + }, + "errors": { + "fatalError": "Odtwarzacz napotkał poważny błąd, Prosimy o złoszenie tego na <0>Serwer Discord lub na <1>GitHub." + } + }, + "settings": { + "title": "Ustawienia", + "language": "Język", + "captionLanguage": "Język napisów" + }, + "v3": { + "newSiteTitle": "Nowa wersja została wydana!", + "newDomain": "https://movie-web.app", + "newDomainText": "movie-web przeniesie się wkrótce na nowy adres: <0>https://movie-web.app. Prosimy zaaktualizować swoje zakładki ponieważ <1>stara strona przestanie działać {{date}}.", + "tireless": "Pracowaliśmy niestrudzenie nad tą aktualizacją, Mamy nadzieję że będziecie zadowoleni z tego nad czym pracowaliśmy przez ostatnie parę miesięcy.", + "leaveAnnouncement": "Zabierz mnie tam!" + }, + "casting": { + "casting": "Przesyłanie do urządzenia..." + }, + "errors": { + "offline": "Sprawdź swoje połączenie sieciowe" + } +} diff --git a/src/setup/locales/tr/translation.json b/src/setup/locales/tr/translation.json index 326cc35d..bab6cd1d 100644 --- a/src/setup/locales/tr/translation.json +++ b/src/setup/locales/tr/translation.json @@ -71,7 +71,16 @@ "popouts": { "back": "Geri git", "sources": "Kaynaklar", - "seasons": "Sezonlar", + "close":"Kapat", + "seasons": { + "title":"Sezonlar", + "other": "Diğer sezonlar", + "noSeason": "Sezon yok" + }, + "episodes": { + "unknown": "Bilinmeyen bölüm", + "noEpisode": "Bölüm yok" + }, "captions": "Altyazılar", "playbackSpeed": "Oynatma hızı", "customPlaybackSpeed": "Özel oynatma hızı", diff --git a/src/video/components/popouts/EpisodeSelectionPopout.tsx b/src/video/components/popouts/EpisodeSelectionPopout.tsx index bd152378..c80045bd 100644 --- a/src/video/components/popouts/EpisodeSelectionPopout.tsx +++ b/src/video/components/popouts/EpisodeSelectionPopout.tsx @@ -99,10 +99,10 @@ export function EpisodeSelectionPopout() { <> navigate("/episodes")} - backText={`To ${currentSeasonInfo?.title.toLowerCase()}`} + backText={currentSeasonInfo?.title} /> {currentSeasonInfo @@ -115,12 +115,15 @@ export function EpisodeSelectionPopout() { {season.title} )) - : "No season"} + : t("videoPlayer.popouts.seasons.noSeason")} navigate("/episodes/seasons")} className="flex cursor-pointer items-center space-x-2 transition-colors duration-200 hover:text-white" > - Other seasons + {t("videoPlayer.popouts.seasons.other")} } @@ -181,7 +184,7 @@ export function EpisodeSelectionPopout() { })} )) - : "No episodes"} + : t("videoPlayer.popouts.episodes.noEpisode")} )} From cc4f64032a92f82170de9e687c70e66f1bd17d96 Mon Sep 17 00:00:00 2001 From: Federico Benedetti Date: Sat, 3 Jun 2023 11:55:57 +0200 Subject: [PATCH 2/3] Add Italian language support --- src/setup/i18n.ts | 4 + src/setup/locales/it/translation.json | 128 ++++++++++++++++++++++++++ 2 files changed, 132 insertions(+) create mode 100644 src/setup/locales/it/translation.json diff --git a/src/setup/i18n.ts b/src/setup/i18n.ts index 6116434a..aa69517a 100644 --- a/src/setup/i18n.ts +++ b/src/setup/i18n.ts @@ -11,11 +11,15 @@ import nl from "./locales/nl/translation.json"; import pirate from "./locales/pirate/translation.json"; import tr from "./locales/tr/translation.json"; import zh from "./locales/zh/translation.json"; +import it from "./locales/it/translation.json"; const locales = { en: { translation: en, }, + it: { + translation: it, + }, nl: { translation: nl, }, diff --git a/src/setup/locales/it/translation.json b/src/setup/locales/it/translation.json new file mode 100644 index 00000000..7c28992c --- /dev/null +++ b/src/setup/locales/it/translation.json @@ -0,0 +1,128 @@ +{ + "global": { + "name": "movie-web" + }, + "search": { + "loading_series": "Recupero delle tue serie preferite...", + "loading_movie": "Recupero dei tuoi film preferiti...", + "loading": "Caricamento...", + "allResults": "Ecco tutto ciò che abbiamo!", + "noResults": "Non abbiamo trovato nulla!", + "allFailed": "Impossibile trovare i media, riprova!", + "headingTitle": "Risultati della ricerca", + "bookmarks": "Segnalibri", + "continueWatching": "Continua a guardare", + "title": "Cosa vuoi guardare?", + "placeholder": "Cosa vuoi guardare?" + }, + "media": { + "movie": "Film", + "series": "Serie", + "stopEditing": "Interrompi modifica", + "errors": { + "genericTitle": "Ops, qualcosa si è rotto!", + "failedMeta": "Caricamento dei metadati non riuscito", + "mediaFailed": "Impossibile richiedere il media che hai richiesto, controlla la tua connessione internet e riprova.", + "videoFailed": "Si è verificato un errore durante la riproduzione del video che hai richiesto. Se ciò continua a accadere, segnala il problema sul <0>server Discord o su <1>GitHub." + } + }, + "seasons": { + "seasonAndEpisode": "S{{season}} E{{episode}}" + }, + "notFound": { + "genericTitle": "Non trovato", + "backArrow": "Torna alla home", + "media": { + "title": "Impossibile trovare quel media", + "description": "Non siamo riusciti a trovare il media richiesto. È stato rimosso o hai manomesso l'URL." + }, + "provider": { + "title": "Questo provider è stato disabilitato", + "description": "Abbiamo riscontrato problemi con il provider o era troppo instabile da utilizzare, quindi abbiamo dovuto disabilitarlo." + }, + "page": { + "title": "Impossibile trovare quella pagina", + "description": "Abbiamo cercato ovunque: sotto i bidoni, nell'armadio, dietro il proxy, ma alla fine non siamo riusciti a trovare la pagina che stai cercando." + } + }, + "searchBar": { + "movie": "Film", + "series": "Serie", + "Search": "Cerca" + }, + "videoPlayer": { + "findingBestVideo": "Ricerca del miglior video per te", + "noVideos": "Ops, non è stato possibile trovare alcun video per te", + "loading": "Caricamento...", + "backToHome": "Torna alla home", + "backToHomeShort": "Indietro", + "seasonAndEpisode": "S{{season}} E{{episode}}", + "timeLeft": "{{timeLeft}} rimanente", + "finishAt": "Fine alle {{timeFinished, datetime}}", + "buttons": { + "episodes": "Episodi", + "source": "Fonte", + "captions": "Sottotitoli", + "download": "Download", + "settings": "Impostazioni", + "pictureInPicture": "Picture in Picture", + "playbackSpeed": "Velocità di riproduzione" + }, + "popouts": { + "back": "Torna indietro", + "sources": "Fonti", + "seasons": "Stagioni", + "captions": "Sottotitoli", + "playbackSpeed": "Velocità di riproduzione", + "customPlaybackSpeed": "Velocità di riproduzione personalizzata", + "captionPreferences": { + "title": "Personalizza", + "delay": "Ritardo", + "fontSize": "Dimensione carattere", + "opacity": "Opacità", + "color": "Colore" + }, + "episode": "E{{index}} - {{title}}", + "noCaptions": "Nessun sottotitolo", + "linkedCaptions": "Sottotitoli collegati", + "customCaption": "Sottotitolo personalizzato", + "uploadCustomCaption": "Carica sottotitolo", + "noEmbeds": "Nessun embed è stato trovato per questa fonte", + + "errors": { + "loadingWentWong": "Si è verificato un problema durante il caricamento degli episodi per {{seasonTitle}}", + "embedsError": "Si è verificato un problema durante il caricamento degli embed per questa cosa che ti piace" + }, + "descriptions": { + "sources": "Quale provider desideri utilizzare?", + "embeds": "Scegli quale video visualizzare", + "seasons": "Scegli quale stagione vuoi guardare", + "episode": "Scegli un episodio", + "captions": "Scegli una lingua per i sottotitoli", + "captionPreferences": "Personalizza l'aspetto dei sottotitoli", + "playbackSpeed": "Cambia la velocità di riproduzione" + } + }, + "errors": { + "fatalError": "Il lettore video ha riscontrato un errore fatale, segnalalo sul <0>server Discord o su <1>GitHub." + } + }, + "settings": { + "title": "Impostazioni", + "language": "Lingua", + "captionLanguage": "Lingua dei sottotitoli" + }, + "v3": { + "newSiteTitle": "Nuova versione ora disponibile!", + "newDomain": "https://movie-web.app", + "newDomainText": "movie-web si sposterà presto su un nuovo dominio: <0>https://movie-web.app. Assicurati di aggiornare tutti i tuoi segnalibri poiché <1>il vecchio sito smetterà di funzionare il {{date}}.", + "tireless": "Abbiamo lavorato instancabilmente su questo nuovo aggiornamento, speriamo che ti piaccia quello su cui abbiamo lavorato negli ultimi mesi.", + "leaveAnnouncement": "Portami lì!" + }, + "casting": { + "casting": "Trasmissione su dispositivo in corso..." + }, + "errors": { + "offline": "Controlla la tua connessione internet" + } +} From b7033a31c453f6cfe70117db5042c1a0c645f9a0 Mon Sep 17 00:00:00 2001 From: Federico Benedetti Date: Sat, 3 Jun 2023 12:15:19 +0200 Subject: [PATCH 3/3] Fix locale import position --- src/setup/i18n.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/setup/i18n.ts b/src/setup/i18n.ts index aa69517a..e5f9358f 100644 --- a/src/setup/i18n.ts +++ b/src/setup/i18n.ts @@ -7,11 +7,11 @@ import cs from "./locales/cs/translation.json"; import de from "./locales/de/translation.json"; import en from "./locales/en/translation.json"; import fr from "./locales/fr/translation.json"; +import it from "./locales/it/translation.json"; import nl from "./locales/nl/translation.json"; import pirate from "./locales/pirate/translation.json"; import tr from "./locales/tr/translation.json"; import zh from "./locales/zh/translation.json"; -import it from "./locales/it/translation.json"; const locales = { en: {