Add or update translations for the Apache Airflow UI. Guides through setting up locales, scaffolding translation files, translating with locale-specific guidelines, and validating results. Use when working with i18n tasks in airflow-core/src/airflow/ui/public/i18n/locales/.
https://www.apache.org/licenses/LICENSE-2.0 -->
Translation work falls into one of two categories depending on whether the
target locale already exists. Check if a directory for the locale exists under
airflow-core/src/airflow/ui/public/i18n/locales/<locale>/. If it does, skip
ahead to Updating an Existing Translation. If not, start with Adding a Translation below.
When adding a translation, some configuration files need to be updated before translation work can begin.
First, create the locale directory:
mkdir -p airflow-core/src/airflow/ui/public/i18n/locales/<locale>/
Then update the following configuration files, keeping the existing alphabetical ordering in each file:
airflow-core/src/airflow/ui/src/i18n/config.ts: add the locale to the
supportedLanguages array:
{ code: "<locale>", name: "<native name>" },
dev/breeze/src/airflow_breeze/commands/ui_commands.py: add the plural
suffixes for the language to the PLURAL_SUFFIXES dict. Check the i18next
plural rules for the language at https://jsfiddle.net/6bpxsgd4 to determine
which suffixes are needed:
"<locale>": ["<suffixes>"],
.github/boring-cyborg.yml: under labelPRBasedOnFilePath, add: