mirror of
https://github.com/discourse/discourse.git
synced 2025-06-02 04:08:41 +08:00
FIX: force date-picker to work with english locale
This commit is contained in:
17
lib/javascripts/moment_locale/he.js
Normal file → Executable file
17
lib/javascripts/moment_locale/he.js
Normal file → Executable file
@ -74,6 +74,23 @@
|
||||
}
|
||||
return number + ' שנים';
|
||||
}
|
||||
},
|
||||
meridiemParse: /אחה"צ|לפנה"צ|אחרי הצהריים|לפני הצהריים|לפנות בוקר|בבוקר|בערב/i,
|
||||
isPM : function (input) {
|
||||
return /^(אחה"צ|אחרי הצהריים|בערב)$/.test(input);
|
||||
},
|
||||
meridiem : function (hour, minute, isLower) {
|
||||
if (hour < 5) {
|
||||
return 'לפנות בוקר';
|
||||
} else if (hour < 10) {
|
||||
return 'בבוקר';
|
||||
} else if (hour < 12) {
|
||||
return isLower ? 'לפנה"צ' : 'לפני הצהריים';
|
||||
} else if (hour < 18) {
|
||||
return isLower ? 'אחה"צ' : 'אחרי הצהריים';
|
||||
} else {
|
||||
return 'בערב';
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user