forked from sombochea/verdaccio-ui
feat: Add french language + minor english language fix (#459)
* feat: Add french language + minor english language fix * Added fr-FR to i18n config + DayJS locale loader Co-authored-by: Liam JACK <1422590-liamjack@users.noreply.gitlab.com>
This commit is contained in:
parent
2a6ad969cc
commit
b17368470d
@ -5,6 +5,7 @@ import translationEN from './translations/en-US.json';
|
|||||||
import translationPT from './translations/pt-BR.json';
|
import translationPT from './translations/pt-BR.json';
|
||||||
import translationES from './translations/es-ES.json';
|
import translationES from './translations/es-ES.json';
|
||||||
import translationDE from './translations/de-DE.json';
|
import translationDE from './translations/de-DE.json';
|
||||||
|
import translationFR from './translations/fr-FR.json';
|
||||||
import translationCN from './translations/zh-CN.json';
|
import translationCN from './translations/zh-CN.json';
|
||||||
|
|
||||||
i18n
|
i18n
|
||||||
@ -16,7 +17,7 @@ i18n
|
|||||||
// in case window.VEDACCIO_LANGUAGE is undefined,it will fall back to 'en-US'
|
// in case window.VEDACCIO_LANGUAGE is undefined,it will fall back to 'en-US'
|
||||||
lng: window?.__VERDACCIO_BASENAME_UI_OPTIONS?.language,
|
lng: window?.__VERDACCIO_BASENAME_UI_OPTIONS?.language,
|
||||||
fallbackLng: 'en-US',
|
fallbackLng: 'en-US',
|
||||||
whitelist: ['en-US', 'pt-BR', 'es-ES', 'de-DE', 'zh-CN'],
|
whitelist: ['en-US', 'pt-BR', 'es-ES', 'de-DE', 'fr-FR', 'zh-CN'],
|
||||||
load: 'currentOnly',
|
load: 'currentOnly',
|
||||||
resources: {
|
resources: {
|
||||||
'en-US': {
|
'en-US': {
|
||||||
@ -31,6 +32,9 @@ i18n
|
|||||||
'de-DE': {
|
'de-DE': {
|
||||||
translation: translationDE,
|
translation: translationDE,
|
||||||
},
|
},
|
||||||
|
'fr-FR': {
|
||||||
|
translation: translationFR,
|
||||||
|
},
|
||||||
'zh-CN': {
|
'zh-CN': {
|
||||||
translation: translationCN,
|
translation: translationCN,
|
||||||
},
|
},
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
},
|
},
|
||||||
"dialog": {
|
"dialog": {
|
||||||
"registry-info": {
|
"registry-info": {
|
||||||
"title": "Register Info"
|
"title": "Registry Info"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"header": {
|
"header": {
|
||||||
@ -132,8 +132,8 @@
|
|||||||
"page-not-found": "404 - Page not found",
|
"page-not-found": "404 - Page not found",
|
||||||
"sorry-we-could-not-find-it": "Sorry, we couldn't find it..."
|
"sorry-we-could-not-find-it": "Sorry, we couldn't find it..."
|
||||||
},
|
},
|
||||||
"app-context-not-correct-used": "The app context was not correct used",
|
"app-context-not-correct-used": "The app context was not used correctly",
|
||||||
"theme-context-not-correct-used": "The theme context was not correct used",
|
"theme-context-not-correct-used": "The theme context was not used correctly",
|
||||||
"package-meta-is-required-at-detail-context": "packageMeta is required at DetailContext"
|
"package-meta-is-required-at-detail-context": "packageMeta is required at DetailContext"
|
||||||
}
|
}
|
||||||
}
|
}
|
139
i18n/translations/fr-FR.json
Normal file
139
i18n/translations/fr-FR.json
Normal file
@ -0,0 +1,139 @@
|
|||||||
|
{
|
||||||
|
"copy-to-clipboard": "Copier dans le presse-papier",
|
||||||
|
"author-anonymous": "Anonyme",
|
||||||
|
"action-bar-action": {
|
||||||
|
"visit-home-page": "Visiter la page d'accueil",
|
||||||
|
"open-an-issue": "Ouvrir un ticket",
|
||||||
|
"download-tarball": "Télécharger l'archive"
|
||||||
|
},
|
||||||
|
"dialog": {
|
||||||
|
"registry-info": {
|
||||||
|
"title": "Informations du Registry"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"header": {
|
||||||
|
"documentation": "Documentation",
|
||||||
|
"registry-info": "Informations du Registry",
|
||||||
|
"greetings": "Bonjour "
|
||||||
|
},
|
||||||
|
"search": {
|
||||||
|
"packages": "Rechercher des paquets"
|
||||||
|
},
|
||||||
|
"auto-complete": {
|
||||||
|
"loading": "En cours de chargement...",
|
||||||
|
"no-results-found": "Aucun resultat trouvé"
|
||||||
|
},
|
||||||
|
"tab": {
|
||||||
|
"uplinks": "Uplinks",
|
||||||
|
"versions": "Versions",
|
||||||
|
"dependencies": "Dépendances",
|
||||||
|
"readme": "Readme"
|
||||||
|
},
|
||||||
|
"uplinks": {
|
||||||
|
"title": "Uplinks",
|
||||||
|
"no-items": "{{name}} n'a pas de uplink."
|
||||||
|
},
|
||||||
|
"versions": {
|
||||||
|
"current-tags": "Tags courants",
|
||||||
|
"version-history": "Historique de version",
|
||||||
|
"not-available": "Non disponible"
|
||||||
|
},
|
||||||
|
"package": {
|
||||||
|
"published-on": "Publié le {{time}} •",
|
||||||
|
"version": "v{{version}}",
|
||||||
|
"visit-home-page": "Visiter la page d'accueil",
|
||||||
|
"homepage": "Page d'accueil",
|
||||||
|
"open-an-issue": "Ouvrir un ticket",
|
||||||
|
"bugs": "Bugs",
|
||||||
|
"download": "Télécharger {{what}}",
|
||||||
|
"the-tar-file": "le fichier tar",
|
||||||
|
"tarball": "Archive"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"has-no-dependencies": "{{package}} n'a aucune dépendance.",
|
||||||
|
"dependency-block": "{{package}}@{{version}}"
|
||||||
|
},
|
||||||
|
"form": {
|
||||||
|
"username": "Nom d'utilisateur",
|
||||||
|
"password": "Mot de passe"
|
||||||
|
},
|
||||||
|
"form-placeholder": {
|
||||||
|
"username": "Votre nom d'utilisateur",
|
||||||
|
"password": "Votre mot de passe"
|
||||||
|
},
|
||||||
|
"form-validation": {
|
||||||
|
"required-field": "Ce champ est obligatoire",
|
||||||
|
"required-min-length": "Ce champ doit faire au moins {{length}} caractères",
|
||||||
|
"unable-to-sign-in": "Connexion impossible",
|
||||||
|
"username-or-password-cant-be-empty": "Le nom d'utilisateur ou mot de passe ne peut pas être vide!"
|
||||||
|
},
|
||||||
|
"help": {
|
||||||
|
"title": "Aucun paquet publié pour l'instant.",
|
||||||
|
"sub-title": "Pour publier votre premier paquet:",
|
||||||
|
"first-step": "1. Se connecter",
|
||||||
|
"first-step-command-line": "npm adduser --registry {{registryUrl}}",
|
||||||
|
"second-step": "2. Publier",
|
||||||
|
"second-step-command-line": "npm publish --registry {{registryUrl}}",
|
||||||
|
"third-step": "3. Recharger cette page."
|
||||||
|
},
|
||||||
|
"sidebar": {
|
||||||
|
"detail": {
|
||||||
|
"latest-version": "Dernière v{{version}}",
|
||||||
|
"version": "v{{version}}"
|
||||||
|
},
|
||||||
|
"installation": {
|
||||||
|
"title": "Installation",
|
||||||
|
"install-using-yarn": "Installer avec yarn",
|
||||||
|
"install-using-yarn-command": "yarn add {{packageName}}",
|
||||||
|
"install-using-npm": "Installer avec npm",
|
||||||
|
"install-using-npm-command": "npm install {{packageName}}",
|
||||||
|
"install-using-pnpm": "Installer avec pnpm",
|
||||||
|
"install-using-pnpm-command": "pnpm install {{packageName}}"
|
||||||
|
},
|
||||||
|
"repository": {
|
||||||
|
"title": "Dépôt"
|
||||||
|
},
|
||||||
|
"author": {
|
||||||
|
"title": "Auteur"
|
||||||
|
},
|
||||||
|
"distribution": {
|
||||||
|
"title": "Dernière distribution",
|
||||||
|
"license": "Licence",
|
||||||
|
"size": "Taille",
|
||||||
|
"file-count": "nombre de fichiers"
|
||||||
|
},
|
||||||
|
"maintainers": {
|
||||||
|
"title": "Mainteneurs"
|
||||||
|
},
|
||||||
|
"contributors": {
|
||||||
|
"title": "Contributeurs"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"npm-version": "Version NPM",
|
||||||
|
"node-js": "NODE JS"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"footer": {
|
||||||
|
"powered-by": "Propulsé par",
|
||||||
|
"made-with-love-on": "Fait avec <0>♥</0> sur"
|
||||||
|
},
|
||||||
|
"button": {
|
||||||
|
"close": "Fermer",
|
||||||
|
"cancel": "Annuler",
|
||||||
|
"login": "Se connecter",
|
||||||
|
"logout": "Se déconnecter",
|
||||||
|
"go-to-the-home-page": "Aller à la page d'accueil",
|
||||||
|
"learn-more": "En savoir plus",
|
||||||
|
"fund-this-package": "<0>Financer</0> ce paquet"
|
||||||
|
},
|
||||||
|
"error": {
|
||||||
|
"unspecific": "Quelque chose a mal tourné.",
|
||||||
|
"404": {
|
||||||
|
"page-not-found": "404 - Page non trouvée",
|
||||||
|
"sorry-we-could-not-find-it": "Desolé, nous n'avons rien retrouvé..."
|
||||||
|
},
|
||||||
|
"app-context-not-correct-used": "Le contexte de l'application n'a pas été utilisé correctement",
|
||||||
|
"theme-context-not-correct-used": "Le contexte du thème n'a pas été utilisé correctement",
|
||||||
|
"package-meta-is-required-at-detail-context": "packageMeta est obligatoire à DetailContext"
|
||||||
|
}
|
||||||
|
}
|
@ -44,6 +44,12 @@ function loadDayJSLocale() {
|
|||||||
dayjs.locale('es');
|
dayjs.locale('es');
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case 'fr-fr':
|
||||||
|
{
|
||||||
|
require('dayjs/locale/fr');
|
||||||
|
dayjs.locale('fr');
|
||||||
|
}
|
||||||
|
break;
|
||||||
case 'zh-cn':
|
case 'zh-cn':
|
||||||
{
|
{
|
||||||
require('dayjs/locale/zh-cn');
|
require('dayjs/locale/zh-cn');
|
||||||
|
Loading…
Reference in New Issue
Block a user