slang-i18n / slang

Type-safe i18n for Dart and Flutter
https://pub.dev/packages/slang
MIT License
419 stars 36 forks source link

Incorrect apply command behaviour #224

Closed ChaserVasya closed 2 weeks ago

ChaserVasya commented 2 weeks ago

Describe the bug apply command has incorrect behaviour. To Reproduce add new translation to base locale file

enum DateRange {
  day,
  week,
  month,
}
  "dateRange(context=DateRange, param=type)" : {
    "day": "День",
    "week": "Неделя",
    "month": "Месяц"
  },

dart run slang analyze Fill other translations from _missing_translations.json dart run slang apply

output:

  "dateRange(context=DateRange, param=type)": {
    "day": "Day",
    "week": "Week",
    "month": "Month"
  },
  "dateRange": {
    "day": "Day",
    "week": "Week",
    "month": "Month"
  }

Expected behavior output:

  "dateRange(context=DateRange, param=type)": {
    "day": "Day",
    "week": "Week",
    "month": "Month"
  },
Tienisto commented 2 weeks ago

Do you use the latest version?

ChaserVasya commented 2 weeks ago

@Tienisto 3.29.0

Tienisto commented 2 weeks ago

This should be already fixed in 3.30.1