Fixes: 1) Correct line references in locale files for consistency; Extra: Improve formatting and alignment of string segments for clarity and maintainability;
42 lines
914 B
Python
42 lines
914 B
Python
from django.conf import settings
|
|
|
|
|
|
class RootDirectory:
|
|
def __init__(self) -> None:
|
|
self.label = "root"
|
|
self.path = settings.BASE_DIR / "evibes"
|
|
|
|
|
|
# Mapping from Django locale codes to DeepL API codes
|
|
DEEPL_TARGET_LANGUAGES_MAPPING = {
|
|
"ar-ar": "AR",
|
|
"cs-cz": "CS",
|
|
"da-dk": "DA",
|
|
"de-de": "DE",
|
|
"en-gb": "EN-GB",
|
|
"en-us": "EN-US",
|
|
"es-es": "ES",
|
|
"fa-ir": "unsupported",
|
|
"fr-fr": "FR",
|
|
"he-il": "HE",
|
|
"hi-in": "unsupported",
|
|
"hr-hr": "unsupported",
|
|
"id-id": "ID",
|
|
"it-it": "IT",
|
|
"ja-jp": "JA",
|
|
"kk-kz": "unsupported",
|
|
"ko-kr": "KO",
|
|
"nl-nl": "NL",
|
|
"no-no": "NB",
|
|
"pl-pl": "PL",
|
|
"pt-br": "PT-BR",
|
|
"ro-ro": "RO",
|
|
"ru-ru": "RU",
|
|
"sv-se": "SV",
|
|
"th-th": "TH",
|
|
"tr-tr": "TR",
|
|
"vi-vn": "VI",
|
|
"zh-hans": "ZH-HANS",
|
|
}
|
|
|
|
TRANSLATABLE_APPS = ["core", "vibes_auth", "blog", "payments", "root"]
|