waseefakhtar / dose-android

💊⏰ Dose is a medication reminder app for Android, built entirely using Kotlin and Jetpack Compose with MVVM + Clean Architecture
https://play.google.com/store/apps/details?id=com.waseefakhtar.doseapp
MIT License
509 stars 80 forks source link

Extract Daily, Weekly, and Monthly enum values to strings.xml #136

Open yamin8000 opened 8 months ago

yamin8000 commented 8 months ago

https://github.com/waseefakhtar/dose-android/blob/10b015513497b069fdaf965cbb8d250e90d0c54d/app/src/main/java/com/waseefakhtar/doseapp/feature/addmedication/AddMedicationRoute.kt#L288

https://github.com/waseefakhtar/dose-android/blob/10b015513497b069fdaf965cbb8d250e90d0c54d/app/src/main/java/com/waseefakhtar/doseapp/feature/addmedication/AddMedicationRoute.kt#L268

Also for the Recurrence Dropdown, you're using its enum name instead of providing a translated text.
I fixed this problem in one of my apps by introducing an integer variable inside the enum which refers to the resource id of the string equal to the current enum value.

waseefakhtar commented 8 months ago

Thanks for reporting this! Definitely something we should fix.

waseefakhtar commented 8 months ago

All the hardcoded strings are now extracted in #126 except for the Recurrence dropdown so we can rename this to be clear.