1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

update lists

This commit is contained in:
Luke Pulverenti 2016-10-03 02:28:45 -04:00
parent 6f73ce4cc3
commit c2290dd41d
33 changed files with 540 additions and 627 deletions

View file

@ -131,8 +131,8 @@
var currentLocale = getCurrentLocale();
return currentLocale && toLocaleTimeStringSupportsLocales ?
date.toLocaleTimeString(currentLocale, options || {}) :
date.toLocaleTimeString();
date.toLocaleTimeString(currentLocale, options || {}).toLowerCase() :
date.toLocaleTimeString().toLowerCase();
}
function getDisplayTime(date) {
@ -147,38 +147,12 @@
}
}
var time = toLocaleTimeString(date);
return toLocaleTimeString(date, {
var timeLower = time.toLowerCase();
hour: 'numeric',
minute: '2-digit'
if (timeLower.indexOf('am') != -1 || timeLower.indexOf('pm') != -1) {
time = timeLower;
var hour = date.getHours() % 12;
var suffix = date.getHours() > 11 ? 'pm' : 'am';
if (!hour) {
hour = 12;
}
var minutes = date.getMinutes();
if (minutes < 10) {
minutes = '0' + minutes;
}
minutes = ':' + minutes;
time = hour + minutes + suffix;
} else {
var timeParts = time.split(':');
// Trim off seconds
if (timeParts.length > 2) {
timeParts.length -= 1;
time = timeParts.join(':');
}
}
return time;
});
}
function isRelativeDay(date, offsetInDays) {