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

update translations

This commit is contained in:
Luke Pulverenti 2015-05-08 15:10:53 -04:00
parent 59ba9520de
commit fc9519999d
6 changed files with 393 additions and 357 deletions

View file

@ -246,6 +246,21 @@
background-position: center center; background-position: center center;
} }
.iconCardImage {
text-align: center;
position: relative;
}
.cardImage .fa {
color: rgb(255, 255, 255);
position: absolute;
left: 0;
right: 0;
font-size: 50px;
margin: auto;
top: 25%;
}
.bannerCard { .bannerCard {
width: 100%; width: 100%;
} }

View file

@ -1116,54 +1116,52 @@
squareSize = posterInfo.smallSquareSize; squareSize = posterInfo.smallSquareSize;
} }
var dateText;
for (var i = 0, length = items.length; i < length; i++) { for (var i = 0, length = items.length; i < length; i++) {
var item = items[i]; var item = items[i];
dateText = null;
primaryImageAspectRatio = LibraryBrowser.getAveragePrimaryImageAspectRatio([item]); primaryImageAspectRatio = LibraryBrowser.getAveragePrimaryImageAspectRatio([item]);
if (options.showPremiereDateIndex) { if (options.showPremiereDateIndex) {
var futureDateText;
if (item.PremiereDate) { if (item.PremiereDate) {
try { try {
futureDateText = LibraryBrowser.getFutureDateText(parseISO8601Date(item.PremiereDate, { toLocal: true }), true); dateText = LibraryBrowser.getFutureDateText(parseISO8601Date(item.PremiereDate, { toLocal: true }), true);
} catch (err) { } catch (err) {
} }
} }
var val = futureDateText || Globalize.translate('HeaderUnknownDate'); var newIndexValue = dateText || Globalize.translate('HeaderUnknownDate');
if (val != currentIndexValue) { if (newIndexValue != currentIndexValue) {
html += '<h2 class="timelineHeader detailSectionHeader" style="text-align:center;">' + val + '</h2>'; html += '<h2 class="timelineHeader detailSectionHeader" style="text-align:center;">' + newIndexValue + '</h2>';
currentIndexValue = val; currentIndexValue = newIndexValue;
} }
} }
else if (options.showStartDateIndex) { else if (options.showStartDateIndex) {
var futureDateText;
if (item.StartDate) { if (item.StartDate) {
try { try {
futureDateText = LibraryBrowser.getFutureDateText(parseISO8601Date(item.StartDate, { toLocal: true }), true); dateText = LibraryBrowser.getFutureDateText(parseISO8601Date(item.StartDate, { toLocal: true }), true);
} catch (err) { } catch (err) {
} }
} }
var val = futureDateText || Globalize.translate('HeaderUnknownDate'); var newIndexValue = dateText || Globalize.translate('HeaderUnknownDate');
if (val != currentIndexValue) { if (newIndexValue != currentIndexValue) {
html += '<h2 class="timelineHeader detailSectionHeader" style="text-align:center;">' + val + '</h2>'; html += '<h2 class="timelineHeader detailSectionHeader" style="text-align:center;">' + newIndexValue + '</h2>';
currentIndexValue = val; currentIndexValue = newIndexValue;
} }
} else if (options.timeline) { } else if (options.timeline) {
var year = item.ProductionYear || Globalize.translate('HeaderUnknownYear'); var year = item.ProductionYear || Globalize.translate('HeaderUnknownYear');
@ -1175,7 +1173,17 @@
} }
} }
html += LibraryBrowser.getPosterViewItemHtml(item, i, options, primaryImageAspectRatio, thumbWidth, posterWidth, squareSize, bannerWidth);
}
return html;
},
getPosterViewItemHtml: function (item, index, options, primaryImageAspectRatio, thumbWidth, posterWidth, squareSize, bannerWidth) {
var html = '';
var imgUrl = null; var imgUrl = null;
var icon;
var background = null; var background = null;
var width = null; var width = null;
var height = null; var height = null;
@ -1346,32 +1354,32 @@
} else if (item.MediaType == "Audio" || item.Type == "MusicAlbum" || item.Type == "MusicArtist") { } else if (item.MediaType == "Audio" || item.Type == "MusicAlbum" || item.Type == "MusicArtist") {
if (item.Name && options.showTitle) { if (item.Name && options.showTitle) {
imgUrl = 'css/images/items/list/audio.png'; icon = 'fa-music';
} }
background = defaultBackground; background = defaultBackground;
} else if (item.Type == "Recording" || item.Type == "Program" || item.Type == "TvChannel") { } else if (item.Type == "Recording" || item.Type == "Program" || item.Type == "TvChannel") {
if (item.Name && options.showTitle) { if (item.Name && options.showTitle) {
imgUrl = 'css/images/items/list/collection.png'; icon = 'fa-folder-open';
} }
background = defaultBackground; background = defaultBackground;
} else if (item.MediaType == "Video" || item.Type == "Season" || item.Type == "Series") { } else if (item.MediaType == "Video" || item.Type == "Season" || item.Type == "Series") {
if (item.Name && options.showTitle) { if (item.Name && options.showTitle) {
imgUrl = 'css/images/items/list/video.png'; icon = 'fa-video-camera';
} }
background = defaultBackground; background = defaultBackground;
} else if (item.Type == "Person") { } else if (item.Type == "Person") {
if (item.Name && options.showTitle) { if (item.Name && options.showTitle) {
imgUrl = 'css/images/items/list/person.png'; icon = 'fa-user';
} }
background = defaultBackground; background = defaultBackground;
} else { } else {
if (item.Name && options.showTitle) { if (item.Name && options.showTitle) {
imgUrl = 'css/images/items/list/collection.png'; icon = 'fa-folder-open';
} }
background = defaultBackground; background = defaultBackground;
} }
@ -1400,7 +1408,7 @@
cssClass += ' bottomPaddedCard'; cssClass += ' bottomPaddedCard';
} }
var dataAttributes = LibraryBrowser.getItemDataAttributes(item, options, i); var dataAttributes = LibraryBrowser.getItemDataAttributes(item, options, index);
var defaultAction = options.defaultAction; var defaultAction = options.defaultAction;
if (defaultAction == 'play' || defaultAction == 'playallfromhere') { if (defaultAction == 'play' || defaultAction == 'playallfromhere') {
@ -1424,6 +1432,10 @@
} }
var imageCssClass = 'cardImage'; var imageCssClass = 'cardImage';
if (icon) {
imageCssClass += " iconCardImage";
}
if (options.coverImage) { if (options.coverImage) {
imageCssClass += " coveredCardImage"; imageCssClass += " coveredCardImage";
} }
@ -1455,7 +1467,11 @@
} }
html += '<a class="' + anchorCssClass + '" href="' + href + '"' + defaultActionAttribute + '>'; html += '<a class="' + anchorCssClass + '" href="' + href + '"' + defaultActionAttribute + '>';
html += '<div class="' + imageCssClass + '" style="' + style + '"' + dataSrc + '></div>'; html += '<div class="' + imageCssClass + '" style="' + style + '"' + dataSrc + '>';
if (icon) {
html += '<i class="fa ' + icon + '"></i>';
}
html += '</div>';
html += '<div class="cardOverlayTarget"></div>'; html += '<div class="cardOverlayTarget"></div>';
@ -1511,8 +1527,6 @@
// card // card
html += "</div>"; html += "</div>";
}
return html; return html;
}, },

View file

@ -317,9 +317,11 @@
html += Globalize.translate('ButtonHome'); html += Globalize.translate('ButtonHome');
html += '</a>'; html += '</a>';
}
html += '<a class="sidebarLink lnkMediaFolder" data-itemid="dashboard" data-rel="none" href="nowplaying.html"><span class="fa fa-tablet sidebarLinkIcon"></span>' + Globalize.translate('ButtonRemote') + '</a>';
html += '<div class="libraryMenuDivider"></div>'; html += '<div class="libraryMenuDivider"></div>';
}
html += getViewsHtml(); html += getViewsHtml();
html += '</div>'; html += '</div>';

View file

@ -13,7 +13,9 @@
currentHtml += '<label for="' + id + '">' + i.Name + '</label>'; currentHtml += '<label for="' + id + '">' + i.Name + '</label>';
var isChecked = user.Configuration.ExcludeFoldersFromGrouping.indexOf(i.Id) == -1; var isChecked = (user.Configuration.ExcludeFoldersFromGrouping != null && user.Configuration.ExcludeFoldersFromGrouping.indexOf(i.Id) == -1) ||
user.Configuration.GroupedFolders.indexOf(i.Id) != -1;
var checkedHtml = isChecked ? ' checked="checked"' : ''; var checkedHtml = isChecked ? ' checked="checked"' : '';
currentHtml += '<input class="chkGroupFolder" data-folderid="' + i.Id + '" type="checkbox" id="' + id + '"' + checkedHtml + ' />'; currentHtml += '<input class="chkGroupFolder" data-folderid="' + i.Id + '" type="checkbox" id="' + id + '"' + checkedHtml + ' />';
@ -209,7 +211,9 @@
return i.getAttribute('data-folderid'); return i.getAttribute('data-folderid');
}); });
user.Configuration.ExcludeFoldersFromGrouping = $(".chkGroupFolder:not(:checked)", page).get().map(function (i) { user.Configuration.ExcludeFoldersFromGrouping = null;
user.Configuration.GroupedFolders = $(".chkGroupFolder:checked", page).get().map(function (i) {
return i.getAttribute('data-folderid'); return i.getAttribute('data-folderid');
}); });

View file

@ -615,12 +615,14 @@
function showIntro() { function showIntro() {
if (store.getItem('remotecontrolswipedown') != '1') { var expected = '2';
if (store.getItem('remotecontrolswipedown') != expected) {
Dashboard.alert({ Dashboard.alert({
message: Globalize.translate('MessageSwipeDownOnRemoteControl'), message: Globalize.translate('MessageSwipeDownOnRemoteControl'),
title: Globalize.translate('HeaderAlert') title: Globalize.translate('HeaderAlert')
}); });
store.setItem('remotecontrolswipedown', '1'); store.setItem('remotecontrolswipedown', expected);
} }
} }

View file

@ -1489,7 +1489,6 @@ var AppInfo = {};
if (isCordova) { if (isCordova) {
AppInfo.enableBottomTabs = true; AppInfo.enableBottomTabs = true;
AppInfo.resetOnLibraryChange = true;
} }
} }
else { else {
@ -1499,7 +1498,7 @@ var AppInfo = {};
} }
} }
if (!AppInfo.hasLowImageBandwidth) { if (!AppInfo.hasLowImageBandwidth || !isCordova) {
AppInfo.enableLatestChannelItems = true; AppInfo.enableLatestChannelItems = true;
AppInfo.enableStudioTabs = true; AppInfo.enableStudioTabs = true;
AppInfo.enablePeopleTabs = true; AppInfo.enablePeopleTabs = true;