From 3e4e725347b4a77fd284cea97ca2827a9770ff35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Jaenisch?= Date: Fri, 14 Jun 2024 18:04:16 +0200 Subject: [PATCH] feat: add bg and pl to language switcher MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This should help translators see their efforts come to fruition. Signed-off-by: André Jaenisch --- src/lib/i18n/index.ts | 4 +- src/lib/i18n/locales/bg.json | 228 +++++++++++++++++------------------ src/lib/i18n/locales/de.json | 228 +++++++++++++++++------------------ src/lib/i18n/locales/en.json | 228 +++++++++++++++++------------------ src/lib/i18n/locales/pl.json | 228 +++++++++++++++++------------------ 5 files changed, 459 insertions(+), 457 deletions(-) diff --git a/src/lib/i18n/index.ts b/src/lib/i18n/index.ts index 7c23e43..c8ff727 100644 --- a/src/lib/i18n/index.ts +++ b/src/lib/i18n/index.ts @@ -15,16 +15,18 @@ import { init, register } from 'svelte-i18n'; const defaultLocale = 'en'; +register('bg', () => import('./locales/bg.json')); register('de', () => import('./locales/de.json')); register('en', () => import('./locales/en.json')); register('he', () => import('./locales/he.json')); +register('pl', () => import('./locales/pl.json')); init({ fallbackLocale: defaultLocale, initialLocale: browser ? window.navigator.language : defaultLocale }); -export function mapLocaleToDir(locale: 'de' | 'en' | 'he'): 'ltr' | 'rtl' { +export function mapLocaleToDir(locale: 'bg' | 'de' | 'en' | 'he' | 'pl'): 'ltr' | 'rtl' { if (['he'].includes(locale)) { return 'rtl'; } diff --git a/src/lib/i18n/locales/bg.json b/src/lib/i18n/locales/bg.json index d118049..b17569b 100644 --- a/src/lib/i18n/locales/bg.json +++ b/src/lib/i18n/locales/bg.json @@ -1,116 +1,116 @@ { - "page": { - "import_project": { - "form": { - "avatar": "Аватар", - "components": "Компоненти", - "fields": { - "avatar": { - "label": "" - }, - "description": { - "label": "", - "placeholder": "" - }, - "issues": { - "label": "" - }, - "name": { - "error": "", - "label": "", - "placeholder": "" - }, - "pr": { - "label": "" - }, - "repository": { - "hint": "", - "label": "", - "placeholder": "" - } - }, - "submit": "" - }, - "heading": "", - "intro": "" - }, - "login": { - "form": { - "fields": { - "account": { - "label": "" - }, - "passphrase": { - "label": "", - "placeholder": "" - }, - "server": { - "label": "" - } - }, - "reset": "", - "submit": "Подаване", - "validation": { - "incorrect": "", - "missing": "" - } - }, - "heading": "", - "intro": "" - }, - "profile": { - "activities": { - "block_or_report": "", - "like": "" - }, - "heading": "", - "history": { - "activities": { - "setup": { - "description": "", - "summary": "" - } - }, - "heading": "" - }, - "projects": { - "add_or_import": "", - "empty": "", - "heading": "" - } - }, - "projects": { - "file_table": { - "updated": "" - }, - "form": { - "fields": { - "more_filters": { - "submit": "" - }, - "projects": { - "submit": "" - }, - "search": { - "placeholder": "", - "submit": "" - }, - "starred": { - "submit": "" - } - } - }, - "nav": { - "next": "", - "previous": "" - }, - "table": { - "heading": { - "last_updated": "", - "name": "" - } - } - }, - "welcome": "" - } + "page": { + "import_project": { + "form": { + "avatar": "Аватар", + "components": "Компоненти", + "fields": { + "avatar": { + "label": "" + }, + "description": { + "label": "", + "placeholder": "" + }, + "issues": { + "label": "" + }, + "name": { + "error": "", + "label": "", + "placeholder": "" + }, + "pr": { + "label": "" + }, + "repository": { + "hint": "", + "label": "", + "placeholder": "" + } + }, + "submit": "" + }, + "heading": "", + "intro": "" + }, + "login": { + "form": { + "fields": { + "account": { + "label": "" + }, + "passphrase": { + "label": "", + "placeholder": "" + }, + "server": { + "label": "" + } + }, + "reset": "", + "submit": "Подаване", + "validation": { + "incorrect": "", + "missing": "" + } + }, + "heading": "", + "intro": "" + }, + "profile": { + "activities": { + "block_or_report": "", + "like": "" + }, + "heading": "", + "history": { + "activities": { + "setup": { + "description": "", + "summary": "" + } + }, + "heading": "" + }, + "projects": { + "add_or_import": "", + "empty": "", + "heading": "" + } + }, + "projects": { + "file_table": { + "updated": "" + }, + "form": { + "fields": { + "more_filters": { + "submit": "" + }, + "projects": { + "submit": "" + }, + "search": { + "placeholder": "", + "submit": "" + }, + "starred": { + "submit": "" + } + } + }, + "nav": { + "next": "", + "previous": "" + }, + "table": { + "heading": { + "last_updated": "", + "name": "" + } + } + }, + "welcome": "" + } } diff --git a/src/lib/i18n/locales/de.json b/src/lib/i18n/locales/de.json index 17aed3a..1663a91 100644 --- a/src/lib/i18n/locales/de.json +++ b/src/lib/i18n/locales/de.json @@ -1,116 +1,116 @@ { - "page": { - "import_project": { - "form": { - "avatar": "Avatar", - "components": "Komponenten", - "fields": { - "avatar": { - "label": "Bild hochladen" - }, - "description": { - "label": "Beschreibung", - "placeholder": "Beschreibe das Projekt in unter 100 Zeichen..." - }, - "issues": { - "label": "Issues" - }, - "name": { - "error": "Dieses Feld ist erforderlich", - "label": "Name", - "placeholder": "Name des Projekts..." - }, - "pr": { - "label": "Pullrequest" - }, - "repository": { - "hint": "optional: von Git-Repository importieren", - "label": "Repository", - "placeholder": "URL des Git-Repositorys" - } - }, - "submit": "Projekt erstellen" - }, - "heading": "Projekt erstellen", - "intro": "Neues F2-Projekt zu Anvil hinzufügen." - }, - "login": { - "form": { - "fields": { - "account": { - "label": "Accountname" - }, - "passphrase": { - "label": "Passwort", - "placeholder": "Passwort" - }, - "server": { - "label": "F2-Server" - } - }, - "reset": "Passwort zurücksetzen", - "submit": "Einloggen", - "validation": { - "incorrect": "Accountname oder Kennwort sind falsch.", - "missing": "Das Account-Feld ist verbindlich." - } - }, - "heading": "Einloggen", - "intro": "Die Einwahldaten ausfüllen um Anvil mit deinem F2-Account zu benutzen." - }, - "profile": { - "activities": { - "block_or_report": "{blockElementOpen}blockieren{blockElementClose} oder {reportElementOpen}melden{reportElementClose}", - "like": "Gefällt mir" - }, - "heading": "Profil für", - "history": { - "activities": { - "setup": { - "description": "Das F2-Konto @{username}@{instance} wurde erfolgreich innerhalb von {created_with} erstellt", - "summary": "Kontoeinstellungen" - } - }, - "heading": "Aktivitäten" - }, - "projects": { - "add_or_import": "{addElementOpen}Ein Projekt hinzufügen{addElementClose} oder {importElementOpen}Ein Projekt importieren{importElementClose}.", - "empty": "Bisher keine Projekte hinzugefügt.", - "heading": "Projekte" - } - }, - "projects": { - "file_table": { - "updated": "Aktualisiert: {relativeTime}" - }, - "form": { - "fields": { - "more_filters": { - "submit": "Weitere Filter" - }, - "projects": { - "submit": "Meine Projekte" - }, - "search": { - "placeholder": "Suchen oder filtern", - "submit": "Absenden" - }, - "starred": { - "submit": "Favorisiert" - } - } - }, - "nav": { - "next": "Weiter", - "previous": "Zurück" - }, - "table": { - "heading": { - "last_updated": "Letzte Aktualisierung", - "name": "Name" - } - } - }, - "welcome": "Willkommen bei Anvil!" - } + "page": { + "import_project": { + "form": { + "avatar": "Avatar", + "components": "Komponenten", + "fields": { + "avatar": { + "label": "Bild hochladen" + }, + "description": { + "label": "Beschreibung", + "placeholder": "Beschreibe das Projekt in unter 100 Zeichen..." + }, + "issues": { + "label": "Issues" + }, + "name": { + "error": "Dieses Feld ist erforderlich", + "label": "Name", + "placeholder": "Name des Projekts..." + }, + "pr": { + "label": "Pullrequest" + }, + "repository": { + "hint": "optional: von Git-Repository importieren", + "label": "Repository", + "placeholder": "URL des Git-Repositorys" + } + }, + "submit": "Projekt erstellen" + }, + "heading": "Projekt erstellen", + "intro": "Neues F2-Projekt zu Anvil hinzufügen." + }, + "login": { + "form": { + "fields": { + "account": { + "label": "Accountname" + }, + "passphrase": { + "label": "Passwort", + "placeholder": "Passwort" + }, + "server": { + "label": "F2-Server" + } + }, + "reset": "Passwort zurücksetzen", + "submit": "Einloggen", + "validation": { + "incorrect": "Accountname oder Kennwort sind falsch.", + "missing": "Das Account-Feld ist verbindlich." + } + }, + "heading": "Einloggen", + "intro": "Die Einwahldaten ausfüllen um Anvil mit deinem F2-Account zu benutzen." + }, + "profile": { + "activities": { + "block_or_report": "{blockElementOpen}blockieren{blockElementClose} oder {reportElementOpen}melden{reportElementClose}", + "like": "Gefällt mir" + }, + "heading": "Profil für", + "history": { + "activities": { + "setup": { + "description": "Das F2-Konto @{username}@{instance} wurde erfolgreich innerhalb von {created_with} erstellt", + "summary": "Kontoeinstellungen" + } + }, + "heading": "Aktivitäten" + }, + "projects": { + "add_or_import": "{addElementOpen}Ein Projekt hinzufügen{addElementClose} oder {importElementOpen}Ein Projekt importieren{importElementClose}.", + "empty": "Bisher keine Projekte hinzugefügt.", + "heading": "Projekte" + } + }, + "projects": { + "file_table": { + "updated": "Aktualisiert: {relativeTime}" + }, + "form": { + "fields": { + "more_filters": { + "submit": "Weitere Filter" + }, + "projects": { + "submit": "Meine Projekte" + }, + "search": { + "placeholder": "Suchen oder filtern", + "submit": "Absenden" + }, + "starred": { + "submit": "Favorisiert" + } + } + }, + "nav": { + "next": "Weiter", + "previous": "Zurück" + }, + "table": { + "heading": { + "last_updated": "Letzte Aktualisierung", + "name": "Name" + } + } + }, + "welcome": "Willkommen bei Anvil!" + } } diff --git a/src/lib/i18n/locales/en.json b/src/lib/i18n/locales/en.json index 253647a..63b30f8 100644 --- a/src/lib/i18n/locales/en.json +++ b/src/lib/i18n/locales/en.json @@ -1,116 +1,116 @@ { - "page": { - "import_project": { - "form": { - "avatar": "Avatar", - "components": "Components", - "fields": { - "avatar": { - "label": "Upload image" - }, - "description": { - "label": "Description", - "placeholder": "Describe the project in less than 100 characters…" - }, - "issues": { - "label": "Issues" - }, - "name": { - "error": "This field is required", - "label": "Name", - "placeholder": "Name of the project…" - }, - "pr": { - "label": "Pull Requests" - }, - "repository": { - "hint": "optional: import from git repo", - "label": "Repository", - "placeholder": "url of git repository…" - } - }, - "submit": "Create project" - }, - "heading": "Create project", - "intro": "Add a new F2 project to Anvil." - }, - "login": { - "form": { - "fields": { - "account": { - "label": "Account name" - }, - "passphrase": { - "label": "Passphrase", - "placeholder": "password" - }, - "server": { - "label": "F2 server" - } - }, - "reset": "Reset passphrase", - "submit": "Log in", - "validation": { - "incorrect": "Account or password wrong.", - "missing": "The account field is required." - } - }, - "heading": "Log in", - "intro": "To use Anvil with your F2 account, fill in your credentials." - }, - "profile": { - "activities": { - "block_or_report": "{blockElementOpen}block{blockElementClose} or {reportElementOpen}report{reportElementClose}", - "like": "Like" - }, - "heading": "Profile for", - "history": { - "activities": { - "setup": { - "description": "The F2 account @{username}@{instance} was successfully set up within {created_with}", - "summary": "account set up" - } - }, - "heading": "Activities" - }, - "projects": { - "add_or_import": "{addElementOpen}Add a project{addElementClose} or {importElementOpen}import a project{importElementClose}.", - "empty": "No projects added yet.", - "heading": "Projects" - } - }, - "projects": { - "file_table": { - "updated": "Updated {relativeTime}" - }, - "form": { - "fields": { - "more_filters": { - "submit": "More Filters" - }, - "projects": { - "submit": "My projects" - }, - "search": { - "placeholder": "Search or filter", - "submit": "Submit" - }, - "starred": { - "submit": "Starred" - } - } - }, - "nav": { - "next": "Next", - "previous": "Previous" - }, - "table": { - "heading": { - "last_updated": "Last updated", - "name": "Name" - } - } - }, - "welcome": "Welcome to Anvil!" - } + "page": { + "import_project": { + "form": { + "avatar": "Avatar", + "components": "Components", + "fields": { + "avatar": { + "label": "Upload image" + }, + "description": { + "label": "Description", + "placeholder": "Describe the project in less than 100 characters…" + }, + "issues": { + "label": "Issues" + }, + "name": { + "error": "This field is required", + "label": "Name", + "placeholder": "Name of the project…" + }, + "pr": { + "label": "Pull Requests" + }, + "repository": { + "hint": "optional: import from git repo", + "label": "Repository", + "placeholder": "url of git repository…" + } + }, + "submit": "Create project" + }, + "heading": "Create project", + "intro": "Add a new F2 project to Anvil." + }, + "login": { + "form": { + "fields": { + "account": { + "label": "Account name" + }, + "passphrase": { + "label": "Passphrase", + "placeholder": "password" + }, + "server": { + "label": "F2 server" + } + }, + "reset": "Reset passphrase", + "submit": "Log in", + "validation": { + "incorrect": "Account or password wrong.", + "missing": "The account field is required." + } + }, + "heading": "Log in", + "intro": "To use Anvil with your F2 account, fill in your credentials." + }, + "profile": { + "activities": { + "block_or_report": "{blockElementOpen}block{blockElementClose} or {reportElementOpen}report{reportElementClose}", + "like": "Like" + }, + "heading": "Profile for", + "history": { + "activities": { + "setup": { + "description": "The F2 account @{username}@{instance} was successfully set up within {created_with}", + "summary": "account set up" + } + }, + "heading": "Activities" + }, + "projects": { + "add_or_import": "{addElementOpen}Add a project{addElementClose} or {importElementOpen}import a project{importElementClose}.", + "empty": "No projects added yet.", + "heading": "Projects" + } + }, + "projects": { + "file_table": { + "updated": "Updated {relativeTime}" + }, + "form": { + "fields": { + "more_filters": { + "submit": "More Filters" + }, + "projects": { + "submit": "My projects" + }, + "search": { + "placeholder": "Search or filter", + "submit": "Submit" + }, + "starred": { + "submit": "Starred" + } + } + }, + "nav": { + "next": "Next", + "previous": "Previous" + }, + "table": { + "heading": { + "last_updated": "Last updated", + "name": "Name" + } + } + }, + "welcome": "Welcome to Anvil!" + } } diff --git a/src/lib/i18n/locales/pl.json b/src/lib/i18n/locales/pl.json index 21a5033..c2c76d4 100644 --- a/src/lib/i18n/locales/pl.json +++ b/src/lib/i18n/locales/pl.json @@ -1,116 +1,116 @@ { - "page": { - "import_project": { - "form": { - "avatar": "Awatar", - "components": "Komponenty", - "fields": { - "avatar": { - "label": "Prześlij obraz" - }, - "description": { - "label": "Opis", - "placeholder": "Opisz projekt w mniej niż 100 znaków…" - }, - "issues": { - "label": "Zgłoszenia" - }, - "name": { - "error": "To pole jest wymagane", - "label": "Nazwa", - "placeholder": "Nazwa projektu…" - }, - "pr": { - "label": "" - }, - "repository": { - "hint": "opcjonalnie: zaimportuj repozytorium git", - "label": "Repozytorium", - "placeholder": "Adres URL repozytorium git…" - } - }, - "submit": "Stwórz projekt" - }, - "heading": "Stwórz projekt", - "intro": "Dodaj nowy projekt F2 do Anvil." - }, - "login": { - "form": { - "fields": { - "account": { - "label": "Nazwa konta" - }, - "passphrase": { - "label": "Fraza dostępu", - "placeholder": "Hasło" - }, - "server": { - "label": "Serwer F2" - } - }, - "reset": "Zresetuj frazę dostępu", - "submit": "Zaloguj się", - "validation": { - "incorrect": "Nazwa konta lub hasło jest niepoprawne.", - "missing": "Pole nazwy konta jest wymagane." - } - }, - "heading": "Logowanie", - "intro": "" - }, - "profile": { - "activities": { - "block_or_report": "{blockElementOpen}zablokuj{blockElementClose} lub {reportElementOpen}zgłoś{reportElementClose}", - "like": "Polub" - }, - "heading": "Profil dla", - "history": { - "activities": { - "setup": { - "description": "Konto F2 @{username}@{instance} zostało poprawnie ustawione z {created_with}", - "summary": "" - } - }, - "heading": "Aktywność" - }, - "projects": { - "add_or_import": "{addElementOpen}Dodaj{addElementClose} lub {importElementOpen}zaimportuj projekt{importElementClose}.", - "empty": "Nie dodano jeszcze żadnego projektu.", - "heading": "Projekty" - } - }, - "projects": { - "file_table": { - "updated": "Zaktualizowano {relativeTime}" - }, - "form": { - "fields": { - "more_filters": { - "submit": "Więcej filtrów" - }, - "projects": { - "submit": "Moje projekty" - }, - "search": { - "placeholder": "Wyszukaj lub filtruj", - "submit": "Prześlij" - }, - "starred": { - "submit": "Dodano do ulubionych" - } - } - }, - "nav": { - "next": "Dalej", - "previous": "Wstecz" - }, - "table": { - "heading": { - "last_updated": "Ostatnio zaktualizowano", - "name": "Nazwa" - } - } - }, - "welcome": "Witamy w Anvil!" - } + "page": { + "import_project": { + "form": { + "avatar": "Awatar", + "components": "Komponenty", + "fields": { + "avatar": { + "label": "Prześlij obraz" + }, + "description": { + "label": "Opis", + "placeholder": "Opisz projekt w mniej niż 100 znaków…" + }, + "issues": { + "label": "Zgłoszenia" + }, + "name": { + "error": "To pole jest wymagane", + "label": "Nazwa", + "placeholder": "Nazwa projektu…" + }, + "pr": { + "label": "" + }, + "repository": { + "hint": "opcjonalnie: zaimportuj repozytorium git", + "label": "Repozytorium", + "placeholder": "Adres URL repozytorium git…" + } + }, + "submit": "Stwórz projekt" + }, + "heading": "Stwórz projekt", + "intro": "Dodaj nowy projekt F2 do Anvil." + }, + "login": { + "form": { + "fields": { + "account": { + "label": "Nazwa konta" + }, + "passphrase": { + "label": "Fraza dostępu", + "placeholder": "Hasło" + }, + "server": { + "label": "Serwer F2" + } + }, + "reset": "Zresetuj frazę dostępu", + "submit": "Zaloguj się", + "validation": { + "incorrect": "Nazwa konta lub hasło jest niepoprawne.", + "missing": "Pole nazwy konta jest wymagane." + } + }, + "heading": "Logowanie", + "intro": "" + }, + "profile": { + "activities": { + "block_or_report": "{blockElementOpen}zablokuj{blockElementClose} lub {reportElementOpen}zgłoś{reportElementClose}", + "like": "Polub" + }, + "heading": "Profil dla", + "history": { + "activities": { + "setup": { + "description": "Konto F2 @{username}@{instance} zostało poprawnie ustawione z {created_with}", + "summary": "" + } + }, + "heading": "Aktywność" + }, + "projects": { + "add_or_import": "{addElementOpen}Dodaj{addElementClose} lub {importElementOpen}zaimportuj projekt{importElementClose}.", + "empty": "Nie dodano jeszcze żadnego projektu.", + "heading": "Projekty" + } + }, + "projects": { + "file_table": { + "updated": "Zaktualizowano {relativeTime}" + }, + "form": { + "fields": { + "more_filters": { + "submit": "Więcej filtrów" + }, + "projects": { + "submit": "Moje projekty" + }, + "search": { + "placeholder": "Wyszukaj lub filtruj", + "submit": "Prześlij" + }, + "starred": { + "submit": "Dodano do ulubionych" + } + } + }, + "nav": { + "next": "Dalej", + "previous": "Wstecz" + }, + "table": { + "heading": { + "last_updated": "Ostatnio zaktualizowano", + "name": "Nazwa" + } + } + }, + "welcome": "Witamy w Anvil!" + } }