maxkeppeler / sheets-compose-dialogs

✨ Enhancing Android UIs: A Jetpack Compose Library supporting a wide range of common use-cases with Material Design 3 Dialogs, Popups, and Bottom Sheets. ✨
https://maxkeppeler.github.io/sheets-compose-dialogs/
Apache License 2.0
807 stars 38 forks source link

(DateTime) "getLocalizedPattern" is incorrect for Chinese locale #57

Open zhzhh7378 opened 1 year ago

zhzhh7378 commented 1 year ago

If the “local” is in China, com.maxkeppeler.sheets.date_time.utils.getLocalizedPattern() result is ”pattern=y年M月d日“ then com.maxkeppeler.sheets.date_time.utils.getLocalizedValues() image Unable to obtain correct results

maxkeppeler commented 1 year ago

对不起... I've to use a locale specific approach for splitting. In this case, for Chinese, the pattern doesn't include a delimiter symbol but just characters which are the delimiters. 年 year, 月 month, 日 day, which should be removed and treated just like ":" etc. I will look into this if I have spare time!