Client - init Italian (it) translation files

This commit is contained in:
Sam 2022-12-11 09:50:33 +01:00
parent ad32f3b33d
commit bd8df6af3d
19 changed files with 65 additions and 1 deletions

View File

@ -18,6 +18,7 @@
"@zxcvbn-ts/language-de": "^2.1.0",
"@zxcvbn-ts/language-en": "^2.1.0",
"@zxcvbn-ts/language-fr": "^2.2.0",
"@zxcvbn-ts/language-it": "^2.1.0",
"axios": "^1.2.0",
"chart.js": "^4.0.1",
"chartjs-plugin-datalabels": "^2.1.0",

View File

@ -6,7 +6,7 @@ import { createI18n, LocaleMessages, VueMessageType } from 'vue-i18n'
* The loaded `JSON` locale messages is pre-compiled by `@intlify/vue-i18n-loader`, which is integrated into `vue-cli-plugin-i18n`.
* See: https://github.com/intlify/vue-i18n-loader#rocket-i18n-resource-pre-compilation
*/
const disabledLanguages = ['nb'] // to update after translations release
const disabledLanguages = ['it', 'nb'] // to update after translations release
function loadLocaleMessages(): Record<string, LocaleMessages<VueMessageType>> {
const locales = require.context('./locales', true, /[A-Za-z0-9-_,\s]+\.ts$/i)

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,27 @@
import AboutTranslations from './about.json'
import AdministrationTranslations from './administration.json'
import ApiTranslations from './api.json'
import ButtonsTranslations from './buttons.json'
import CommonTranslations from './common.json'
import DashboardTranslations from './dashboard.json'
import ErrorTranslations from './error.json'
import OAuth2Translations from './oauth2.json'
import SportsTranslations from './sports.json'
import StatisticsTranslations from './statistics.json'
import UserTranslations from './user.json'
import WorkoutsTranslations from './workouts.json'
export default {
about: AboutTranslations,
admin: AdministrationTranslations,
api: ApiTranslations,
buttons: ButtonsTranslations,
common: CommonTranslations,
dashboard: DashboardTranslations,
error: ErrorTranslations,
oauth2: OAuth2Translations,
sports: SportsTranslations,
statistics: StatisticsTranslations,
user: UserTranslations,
workouts: WorkoutsTranslations,
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -0,0 +1,2 @@
{
}

View File

@ -97,6 +97,7 @@ const dateStringFormats: Record<string, string> = {
de: 'do MMM yyyy',
en: 'MMM. do, yyyy',
fr: 'd MMM yyyy',
// it: 'd MMM yyyy',
// nb: 'do MMM yyyy',
nl: 'd MMM yyyy',
}

View File

@ -8,6 +8,7 @@ export const localeFromLanguage: Record<string, Locale> = {
de: de,
en: enUS,
fr: fr,
// it: it,
// nb: nb, // disabled for now
nl: nl,
}
@ -16,6 +17,7 @@ export const languageLabels: Record<string, string> = {
de: 'Deutsch',
en: 'English',
fr: 'Français',
// it: 'Italiano',
// nb: 'Norsk bokmål', // disabled for now
nl: 'Nederlands',
}

View File

@ -13,10 +13,14 @@ export const setZxcvbnOptions = async (language: string) => {
const zxcvbnDePackage = await import(
/* webpackChunkName: "password" */ '@zxcvbn-ts/language-de'
)
const zxcvbnItPackage = await import(
/* webpackChunkName: "password" */ '@zxcvbn-ts/language-it'
)
const zxcvbnLangPackages: Record<string, typeof zxcvbnEnPackage> = {
de: zxcvbnDePackage,
en: zxcvbnEnPackage,
fr: zxcvbnFrPackage,
it: zxcvbnItPackage,
// no package available for norwegian bokmal, fallback on english
nb: zxcvbnEnPackage,
// no package available for dutch (Nederlands), fallback on english

View File

@ -2160,6 +2160,11 @@
resolved "https://registry.yarnpkg.com/@zxcvbn-ts/language-fr/-/language-fr-2.2.0.tgz#0b7dd93ebba0044fbe733836bc7091b76d42afe1"
integrity sha512-KK+vIXm17mZyo7jLmV4T0fT6hh5NOBABdmkCBVpLyXq+rlZpdaz6HgoYLjqq2JbEU3KSZ+gv6qW+2N4dMk3Tlw==
"@zxcvbn-ts/language-it@^2.1.0":
version "2.1.0"
resolved "https://registry.yarnpkg.com/@zxcvbn-ts/language-it/-/language-it-2.1.0.tgz#43dc6909eeaf64ec81a3efbfc761ae2b9253706b"
integrity sha512-ABYJp2HobzQ9B2PAbvNcEY7P7tFpa2TjFpINjkNdm/+zp+wSS5jrRP+siRH9dkXBI79jtwdliQ6uCdP9s4Sm8w==
abab@^2.0.5, abab@^2.0.6:
version "2.0.6"
resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291"