diff --git a/assets/release_notes.md b/assets/release_notes.md index ddf90a1c..300f7a26 100644 --- a/assets/release_notes.md +++ b/assets/release_notes.md @@ -3,6 +3,7 @@ - Enable label printing for stock locations - Enable label printing for parts +- Updated translation support ### 0.12.5 - July 2023 --- diff --git a/ios/Runner/Info.plist b/ios/Runner/Info.plist index d2611ef0..5cd05c63 100644 --- a/ios/Runner/Info.plist +++ b/ios/Runner/Info.plist @@ -34,11 +34,13 @@ pt-BR pt-PT ru-RU + sl_SI sv-SE th-TH tr-TR vi-VN zh-CN + zh-TW CFBundleName InvenTree diff --git a/lib/l10n/collect_translations.py b/lib/l10n/collect_translations.py index 4f0182a0..03148a69 100644 --- a/lib/l10n/collect_translations.py +++ b/lib/l10n/collect_translations.py @@ -91,12 +91,16 @@ def generate_locale_list(locales): with open("supported_locales.dart", "w") as output: output.write("// This file is auto-generated by the 'collect_translations.py' script - do not edit it directly!\n\n") - output.write('import "package:flutter/material.dart";\n\n') + output.write("const List supported_locales = [\n") - output.write("const List supported_locales = [\n"); + locales = sorted(locales) for locale in locales: + + if locale.startswith('.'): + continue + splt = locale.split("_") if len(splt) == 2: