mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Add Latvian language support (#6749)
* Add Latvian language support * Add empty frontend translation * Add messages.d.ts
This commit is contained in:
parent
7811ba5578
commit
6a7ea919e1
@ -2,12 +2,14 @@
|
||||
|
||||
If a new language translation is supported, it must be added here
|
||||
After adding a new language, run the following command:
|
||||
|
||||
python manage.py makemessages -l <language_code> -e html,js,py --no-wrap
|
||||
where <language_code> is the code for the new language
|
||||
- where <language_code> is the code for the new language
|
||||
|
||||
Additionally, update the following files with the new locale code:
|
||||
|
||||
- /src/frontend/.linguirc file
|
||||
- /src/frontend/src/context/LanguageContext.tsx
|
||||
- /src/frontend/src/contexts/LanguageContext.tsx
|
||||
"""
|
||||
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
@ -30,6 +32,7 @@ LOCALES = [
|
||||
('it', _('Italian')),
|
||||
('ja', _('Japanese')),
|
||||
('ko', _('Korean')),
|
||||
('lv', _('Latvian')),
|
||||
('nl', _('Dutch')),
|
||||
('no', _('Norwegian')),
|
||||
('pl', _('Polish')),
|
||||
|
14163
InvenTree/locale/lv/LC_MESSAGES/django.po
Normal file
14163
InvenTree/locale/lv/LC_MESSAGES/django.po
Normal file
File diff suppressed because it is too large
Load Diff
@ -17,6 +17,7 @@
|
||||
"it",
|
||||
"ja",
|
||||
"ko",
|
||||
"lv",
|
||||
"nl",
|
||||
"no",
|
||||
"pl",
|
||||
|
@ -34,6 +34,7 @@ export const getSupportedLanguages = (): Record<string, string> => {
|
||||
it: t`Italian`,
|
||||
ja: t`Japanese`,
|
||||
ko: t`Korean`,
|
||||
lv: t`Latvian`,
|
||||
nl: t`Dutch`,
|
||||
no: t`Norwegian`,
|
||||
pl: t`Polish`,
|
||||
|
4
src/frontend/src/locales/lv/messages.d.ts
vendored
Normal file
4
src/frontend/src/locales/lv/messages.d.ts
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
import { Messages } from '@lingui/core';
|
||||
declare const messages: Messages;
|
||||
export { messages };
|
||||
|
4964
src/frontend/src/locales/lv/messages.po
Normal file
4964
src/frontend/src/locales/lv/messages.po
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user