Hello everyone. I am developing a calendar for users from Ukraine, I need the interface to be in Ukrainian. As I understand it, there is no support for this language, so I created such a js file (I took an example from custom.locale.De.js) and write phrases in Ukrainian directly.
code.PNG (39.87 KiB) Viewed 912 times
But I have a problem with the fact that months and weeks remain the same in English. How can I translate it to Ukrainian?
For dates you should localize DateHelper.locale property. Please check if you did?
Example for Russian language
DateHelper : {
locale : 'ru',
weekStartDay : 1,
// Non-working days which match weekends by default, but can be changed according to schedule needs
nonWorkingDays : {
0 : true,
6 : true
},
// Days considered as weekends by the selected country, but could be working days in the schedule
weekends : {
0 : true,
6 : true
},
unitNames : [
{ single : 'миллисек', plural : 'миллисек', abbrev : 'мс' },
{ single : 'секунда', plural : 'секунд', abbrev : 'с' },
{ single : 'минута', plural : 'минут', abbrev : 'мин' },
{ single : 'час', plural : 'часов', abbrev : 'ч' },
{ single : 'день', plural : 'дней', abbrev : 'д' },
{ single : 'неделя', plural : 'недели', abbrev : 'нед' },
{ single : 'месяц', plural : 'месяцев', abbrev : 'мес' },
{ single : 'квартал', plural : 'кварталов', abbrev : 'квар' },
{ single : 'год', plural : 'лет', abbrev : 'г' },
{ single : 'десятилетие', plural : 'десятилетия', abbrev : 'дес' }
],
// Used to build a RegExp for parsing time units.
// The full names from above are added into the generated Regexp.
// So you may type "2 н" or "2 нед" or "2 неделя" or "2 недели" into a DurationField.
// When generating its display value though, it uses the full localized names above.
unitAbbreviations : [
['мс', 'мил'],
['с', 'сек'],
['м', 'мин'],
['ч'],
['д', 'ден', 'дне'],
['н', 'нед'],
['мес'],
['к', 'квар', 'квр'],
['г'],
['дес']
],
parsers : {
L : 'DD.MM.YYYY',
LT : 'HH:mm'
},
ordinalSuffix : number => `${number}-й`
},