Open RodrigoPauletti opened 5 years ago
@yggg It works! Thanks, bro.
Hi It still doesn't work properly unfortunately. The are 2 problems: 1) if you check formControl errors, there's invalid date if format is little bit different from english for example: czech date format (cs-CZ) is 'D. M. YYYY' if you choose 28.3.2019 from picker correct string is inserted into input. But there will be validation error on formControl.
2) if you change date directly in the input, locale format isn't used ex: 28.3.2019 -> 29.3.2019
tryit: https://stackblitz.com/edit/localeid-datepicker-localization-2
Hi @p-spacek! Thanks for the example, I can see the issue. As a workaround until the fix, you can use date-fns or moment service, then everything should work. See Formatting Issue in the docs for guidance on how to install and use different date services.
Hi @yggg , i'm afraid that this doesn't help. Behave is the same. I'm not able to show it on stackblitz - I have some problems add nebular/date-fns :-/ https://stackblitz.com/edit/localeid-datepicker-localization-2-w6uat3, but in my enviroment it doesn't work.
Hi It still doesn't work properly unfortunately. The are 2 problems:
- if you check formControl errors, there's invalid date if format is little bit different from english for example: czech date format (cs-CZ) is 'D. M. YYYY' if you choose 28.3.2019 from picker correct string is inserted into input. But there will be validation error on formControl.
- if you change date directly in the input, locale format isn't used ex: 28.3.2019 -> 29.3.2019
tryit: https://stackblitz.com/edit/localeid-datepicker-localization-2
same issue here formControl validation error when language is zh-cn
Hi, I use format yyyy-MM-dd, and the range-picker will not change after input value changed.
It seems NbRangeAdapterService
use '-' to split range start / end.
parse(range: string, format): NbCalendarRange<D> {
const [start, end] = range.split('-').map(subDate => subDate.trim());
I think it should be use range.split(' - ')
instead of range.split('-')
I have changed language succesfully, but the calendar still shows "today". How can i fix or change it ? I have opted to hide it with property showHeader=false, but i still wish to know how to change it.
@yggg I have any problem with you example in my proyect. If i change the language for es, in your example is success but in my project i can´t pick janurary,april,august and december days. The input is empty, what happend? IMPORTANT the problem is caused for nb-rangepicker, however with datepicker is success
further question, what if i want to implement a translation service to allow two languages in my app? could there be the possibility to change calendar language when a LangChangeEvent occurs???
any updates here I want to add another language.
Issue type
I'm submitting a ...
Issue description
Current behavior:
Expected behavior:
Other information:
npm, node, OS, Browser
Angular, Nebular