2
0

🚑 Fix pt-BR i18n loading

This commit is contained in:
Baptiste Arnaud
2023-09-05 18:36:22 +02:00
parent aaa208cef4
commit be0c619316
4 changed files with 13 additions and 13 deletions

View File

@ -22,7 +22,7 @@ const nextConfig = {
],
i18n: {
defaultLocale: 'en',
locales: ['en', 'fr', 'pt', 'pt_BR', 'de'],
locales: ['en', 'fr', 'pt', 'pt-BR', 'de'],
},
experimental: {
outputFileTracingRoot: join(__dirname, '../../'),

View File

@ -19,11 +19,11 @@ import { ChevronDownIcon } from '@/components/icons'
import { MoreInfoTooltip } from '@/components/MoreInfoTooltip'
const localeHumanReadable = {
en: 'English',
fr: 'Français',
de: 'Deutsch',
pt: 'Português',
pt_BR: 'Português (BR)'
en: 'English',
fr: 'Français',
de: 'Deutsch',
pt: 'Português',
'pt-BR': 'Português (BR)',
} as const
export const UserPreferencesForm = () => {

View File

@ -1,6 +1,6 @@
import { createI18n } from 'next-international'
export type I18nFunction = (key: string) => string;
export type I18nFunction = (key: string) => string
export const {
useI18n,
@ -11,9 +11,9 @@ export const {
useChangeLocale,
defineLocale,
} = createI18n({
en: () => import('./en'),
fr: () => import('./fr'),
pt: () => import('./pt'),
pt_BR: () => import('./pt_BR'),
de: () => import('./de'),
en: () => import('./en'),
fr: () => import('./fr'),
pt: () => import('./pt'),
'pt-BR': () => import('./pt-BR'),
de: () => import('./de'),
})