update translations
|
@ -1,12 +1,10 @@
|
|||
.btnCastImage {
|
||||
background-color: transparent;
|
||||
background-size: contain;
|
||||
background-size: 100%;
|
||||
background-repeat: no-repeat;
|
||||
background-position: center center;
|
||||
width: 28px;
|
||||
width: 23px;
|
||||
height: 100%;
|
||||
position: relative;
|
||||
top: 2px;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
|
@ -39,3 +37,10 @@
|
|||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@media all and (max-width: 400px) {
|
||||
.btnCastImage {
|
||||
width: 28px;
|
||||
}
|
||||
}
|
||||
|
|
Before Width: | Height: | Size: 1 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.7 KiB |
|
@ -12,10 +12,6 @@
|
|||
margin-left: .5em;
|
||||
}
|
||||
|
||||
.page[data-theme=b] {
|
||||
background-color: #202020;
|
||||
}
|
||||
|
||||
.backdropPage {
|
||||
background-color: rgba(15, 15,15, .92)!important;
|
||||
}
|
||||
|
@ -49,6 +45,7 @@
|
|||
margin-bottom: 0;
|
||||
padding-left: 4px;
|
||||
}
|
||||
|
||||
.firstListHeader {
|
||||
margin-top: .25em;
|
||||
}
|
||||
|
@ -74,6 +71,17 @@
|
|||
margin-top: 1em;
|
||||
}
|
||||
|
||||
.sectionHeaderButton {
|
||||
vertical-align: middle;
|
||||
margin: 0 0 0 1.5em;
|
||||
position: relative;
|
||||
top: 8px;
|
||||
}
|
||||
|
||||
.firstListHeader + .sectionHeaderButton {
|
||||
top: 3px;
|
||||
}
|
||||
|
||||
@media all and (min-width: 900px) {
|
||||
|
||||
.ehsContent {
|
||||
|
|
|
@ -12,11 +12,11 @@
|
|||
margin: .5em 0;
|
||||
}
|
||||
|
||||
.viewMenuBar, .headerButton {
|
||||
.viewMenuBar, .barsMenuButton, .libraryMenuButtonText, .btnCast {
|
||||
height: 50px;
|
||||
}
|
||||
|
||||
.headerButton {
|
||||
.barsMenuButton, .libraryMenuButtonText, .btnCast {
|
||||
line-height: 50px;
|
||||
}
|
||||
|
||||
|
@ -35,12 +35,12 @@
|
|||
}
|
||||
|
||||
.headerButton img {
|
||||
height: 18px;
|
||||
height: 19px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.headerSearchButton img {
|
||||
height: 16px;
|
||||
height: 18px;
|
||||
}
|
||||
|
||||
.headerButtonLeft {
|
||||
|
@ -54,8 +54,8 @@
|
|||
|
||||
.headerButtonRight {
|
||||
border-width: 0 !important;
|
||||
float: left;
|
||||
padding: 0 15px;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.headerButtonRight:first-child {
|
||||
|
@ -106,8 +106,8 @@
|
|||
left: 0;
|
||||
z-index: 1000;
|
||||
top: 0;
|
||||
background: #000;
|
||||
border-bottom: 1px solid #101010;
|
||||
background-image: linear-gradient(#262626,#111);
|
||||
border-bottom: 1px solid #111;
|
||||
border-top: 0;
|
||||
border-left: 0;
|
||||
border-right: 0;
|
||||
|
@ -116,23 +116,13 @@
|
|||
.libraryViewNav {
|
||||
height: 48px;
|
||||
overflow: hidden;
|
||||
border-bottom: 1px solid #222;
|
||||
position: fixed;
|
||||
right: 0;
|
||||
left: 0;
|
||||
top: 51px;
|
||||
z-index: 1000;
|
||||
background-color: #161616;
|
||||
}
|
||||
|
||||
@media all and (max-width: 460px) {
|
||||
.headerButtonLeft img {
|
||||
height: 15px;
|
||||
}
|
||||
|
||||
.btnCastImage {
|
||||
width: 26px !important;
|
||||
}
|
||||
background-image: linear-gradient(#1a1a1a,#1a1a1a);
|
||||
border-bottom: 1px solid #111;
|
||||
}
|
||||
|
||||
.viewMenuLink {
|
||||
|
|
|
@ -8,23 +8,22 @@
|
|||
-moz-border-radius: 2px;
|
||||
-webkit-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
padding: 0 12px;
|
||||
line-height: 22px;
|
||||
margin-top: 15px;
|
||||
padding: 6px 12px;
|
||||
text-align: center;
|
||||
text-decoration: none !important;
|
||||
-moz-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
background-color: #353535;
|
||||
background-image: -webkit-gradient(linear,left top,left bottom,from(#353535),to(#313131));
|
||||
background-image: -webkit-linear-gradient(top,#353535,#313131);
|
||||
background-image: -moz-linear-gradient(top,#353535,#313131);
|
||||
background-image: -ms-linear-gradient(top,#353535,#313131);
|
||||
background-image: -o-linear-gradient(top,#353535,#313131);
|
||||
background-image: linear-gradient(top,#353535,#313131);
|
||||
border: 1px solid #444;
|
||||
background-color: #444;
|
||||
background-image: -webkit-gradient(linear,left top,left bottom,from(#444),to(#313131));
|
||||
background-image: -webkit-linear-gradient(top,#444,#313131);
|
||||
background-image: -moz-linear-gradient(top,#444,#313131);
|
||||
background-image: -ms-linear-gradient(top,#444,#313131);
|
||||
background-image: -o-linear-gradient(top,#444,#313131);
|
||||
background-image: linear-gradient(top,#444,#313131);
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
font-family: "Open Sans";
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.levelNormal {
|
||||
|
|
|
@ -274,7 +274,7 @@ h1 .imageLink {
|
|||
|
||||
.content-secondary {
|
||||
z-index: 1000;
|
||||
background: #e6e6e6;
|
||||
background: #333;
|
||||
border: 0;
|
||||
border-right: 1px solid #ddd;
|
||||
display: none;
|
||||
|
@ -297,7 +297,7 @@ h1 .imageLink {
|
|||
display: block;
|
||||
padding: .6em 20px .6em 20px;
|
||||
text-decoration: none;
|
||||
color: #000!important;
|
||||
color: #eee!important;
|
||||
text-shadow: none!important;
|
||||
font-weight: 400!important;
|
||||
font-size: 14px;
|
||||
|
@ -311,12 +311,12 @@ h1 .imageLink {
|
|||
.sidebarLinks a.selectedSidebarLink {
|
||||
background: #38c!important;
|
||||
color: #fff!important;
|
||||
margin-right: -1px;
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
.sidebarDivider {
|
||||
height: 1px;
|
||||
background: #d8d8d8;
|
||||
background: #444;
|
||||
margin: .25em 0;
|
||||
}
|
||||
|
||||
|
@ -1073,4 +1073,4 @@ progress {
|
|||
width: 250px;
|
||||
height: 140.625px;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
<div class="libraryViewNav scopedLibraryViewNav">
|
||||
<a href="index.html">${TabHome}</a>
|
||||
<a href="homelatest.html">${TabLatest}</a>
|
||||
<a href="tvrecommended.html">${TabNextUp}</a>
|
||||
<a href="favorites.html" class="ui-btn-active">${TabFavorites}</a>
|
||||
<a href="tvupcoming.html">${TabUpcoming}</a>
|
||||
|
|
29
dashboard-ui/homelatest.html
Normal file
|
@ -0,0 +1,29 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>${TitleMediaBrowser}</title>
|
||||
</head>
|
||||
<body>
|
||||
<div id="homeLatestPage" data-role="page" class="page type-home libraryPage allLibraryPage backdropPage" data-theme="b" data-backdroptype="movie,series,game,book">
|
||||
|
||||
<div class="libraryViewNav scopedLibraryViewNav">
|
||||
<a href="index.html">${TabHome}</a>
|
||||
<a href="#" class="ui-btn-active">${TabLatest}</a>
|
||||
<a href="tvrecommended.html">${TabNextUp}</a>
|
||||
<a href="favorites.html">${TabFavorites}</a>
|
||||
<a href="tvupcoming.html">${TabUpcoming}</a>
|
||||
</div>
|
||||
|
||||
<div data-role="content">
|
||||
|
||||
<table class="ehsContent homeEhsContent">
|
||||
<tr>
|
||||
<td>
|
||||
<div class="sections"></div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
<div class="libraryViewNav scopedLibraryViewNav">
|
||||
<a href="#" class="ui-btn-active">${TabHome}</a>
|
||||
<a href="homelatest.html">${TabLatest}</a>
|
||||
<a href="tvrecommended.html">${TabNextUp}</a>
|
||||
<a href="favorites.html">${TabFavorites}</a>
|
||||
<a href="tvupcoming.html">${TabUpcoming}</a>
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
<div class="itemTabs homeTabs" style="display: none;">
|
||||
<div class="libraryViewNav scopedLibraryViewNav">
|
||||
<a href="index.html" class="lnkHomeHome">${TabHome}</a>
|
||||
<a href="homelatest.html">${TabLatest}</a>
|
||||
<a href="tvrecommended.html" class="lnkHomeNextUp">${TabNextUp}</a>
|
||||
<a href="favorites.html" class="lnkHomeFavorites">${TabFavorites}</a>
|
||||
<a href="tvupcoming.html" class="lnkHomeUpcoming">${TabUpcoming}</a>
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<form class="displayPreferencesForm" style="margin: 0 auto;">
|
||||
|
||||
<div class="detailSectionHeader" style="margin: 0 .5em;">
|
||||
${HeaderLibraryViews}
|
||||
${HeaderMyViews}
|
||||
</div>
|
||||
<div style="margin: 0 1em;">
|
||||
<p>${LabelSelectFolderGroups}</p>
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
<option value="">${OptionAuto}</option>
|
||||
<option value="latestmedia">${OptionLatestMedia}</option>
|
||||
<option value="latestchannelmedia">${OptionLatestChannelMedia}</option>
|
||||
<option value="latesttvrecordings">${OptionLatestTvRecordings}</option>
|
||||
<option value="librarytiles">${OptionMyLibrary}</option>
|
||||
<option value="smalllibrarytiles">${OptionMyLibrarySmall}</option>
|
||||
<option value="folders">${OptionLibraryFolders}</option>
|
||||
|
@ -40,6 +41,7 @@
|
|||
<option value="">${OptionAuto}</option>
|
||||
<option value="latestmedia">${OptionLatestMedia}</option>
|
||||
<option value="latestchannelmedia">${OptionLatestChannelMedia}</option>
|
||||
<option value="latesttvrecordings">${OptionLatestTvRecordings}</option>
|
||||
<option value="librarytiles">${OptionMyLibrary}</option>
|
||||
<option value="smalllibrarytiles">${OptionMyLibrarySmall}</option>
|
||||
<option value="folders">${OptionLibraryFolders}</option>
|
||||
|
@ -53,6 +55,7 @@
|
|||
<option value="">${OptionAuto}</option>
|
||||
<option value="latestmedia">${OptionLatestMedia}</option>
|
||||
<option value="latestchannelmedia">${OptionLatestChannelMedia}</option>
|
||||
<option value="latesttvrecordings">${OptionLatestTvRecordings}</option>
|
||||
<option value="librarytiles">${OptionMyLibrary}</option>
|
||||
<option value="smalllibrarytiles">${OptionMyLibrarySmall}</option>
|
||||
<option value="folders">${OptionLibraryFolders}</option>
|
||||
|
@ -66,6 +69,7 @@
|
|||
<option value="">${OptionAuto}</option>
|
||||
<option value="latestmedia">${OptionLatestMedia}</option>
|
||||
<option value="latestchannelmedia">${OptionLatestChannelMedia}</option>
|
||||
<option value="latesttvrecordings">${OptionLatestTvRecordings}</option>
|
||||
<option value="librarytiles">${OptionMyLibrary}</option>
|
||||
<option value="smalllibrarytiles">${OptionMyLibrarySmall}</option>
|
||||
<option value="folders">${OptionLibraryFolders}</option>
|
||||
|
|
|
@ -1,79 +1,8 @@
|
|||
(function ($, document) {
|
||||
|
||||
function reloadFromChannels(page, channels) {
|
||||
|
||||
var channelsHtml = channels.map(function (c) {
|
||||
|
||||
return '<div id="channel' + c.Id + '"></div>';
|
||||
|
||||
}).join('');
|
||||
|
||||
$('.items', page).html(channelsHtml);
|
||||
|
||||
for (var i = 0, length = channels.length; i < length; i++) {
|
||||
|
||||
var channel = channels[i];
|
||||
|
||||
reloadFromChannel(page, channel, i);
|
||||
}
|
||||
}
|
||||
|
||||
function reloadFromChannel(page, channel, index) {
|
||||
|
||||
var screenWidth = $(window).width();
|
||||
|
||||
var options = {
|
||||
|
||||
Limit: screenWidth >= 1920 ? 10 : (screenWidth >= 1440 ? 8 : (screenWidth >= 800 ? 6 : 6)),
|
||||
Fields: "PrimaryImageAspectRatio",
|
||||
Filters: "IsUnplayed",
|
||||
UserId: Dashboard.getCurrentUserId(),
|
||||
ChannelIds: channel.Id
|
||||
};
|
||||
|
||||
$.getJSON(ApiClient.getUrl("Channels/Items/Latest", options)).done(function (result) {
|
||||
|
||||
var html = '';
|
||||
|
||||
if (result.Items.length) {
|
||||
|
||||
var text = Globalize.translate('HeaderLatestFromChannel').replace('{0}', channel.Name);
|
||||
if (index) {
|
||||
html += '<h1 class="listHeader">' + text + '</h1>';
|
||||
} else {
|
||||
html += '<h1 class="listHeader firstListHeader">' + text + '</h1>';
|
||||
}
|
||||
}
|
||||
html += LibraryBrowser.getPosterViewHtml({
|
||||
items: result.Items,
|
||||
shape: 'auto',
|
||||
defaultShape: 'square',
|
||||
showTitle: true,
|
||||
centerText: true,
|
||||
context: 'channels',
|
||||
lazy: true
|
||||
});
|
||||
|
||||
$('#channel' + channel.Id + '', page).html(html).trigger('create').createPosterItemMenus();
|
||||
});
|
||||
}
|
||||
|
||||
function reloadItems(page) {
|
||||
|
||||
Dashboard.showLoadingMsg();
|
||||
|
||||
var options = {
|
||||
|
||||
UserId: Dashboard.getCurrentUserId(),
|
||||
SupportsLatestItems: true
|
||||
};
|
||||
|
||||
$.getJSON(ApiClient.getUrl("Channels", options)).done(function (result) {
|
||||
|
||||
reloadFromChannels(page, result.Items);
|
||||
|
||||
Dashboard.hideLoadingMsg();
|
||||
});
|
||||
Sections.loadLatestChannelItems($(".items", page), Dashboard.getCurrentUserId());
|
||||
}
|
||||
|
||||
$(document).on('pagebeforeshow', "#channelsLatestPage", function () {
|
||||
|
|
|
@ -13,6 +13,16 @@
|
|||
return true;
|
||||
}
|
||||
|
||||
function htmlEncode(value) {
|
||||
//create a in-memory div, set it's inner text(which jQuery automatically encodes)
|
||||
//then grab the encoded contents back out. The div never exists on the page.
|
||||
return $('<div/>').text(value).html();
|
||||
}
|
||||
|
||||
function htmlDecode(value) {
|
||||
return $('<div/>').html(value).text();
|
||||
}
|
||||
|
||||
// Array Remove - By John Resig (MIT Licensed)
|
||||
Array.prototype.remove = function (from, to) {
|
||||
var rest = this.slice((to || from) + 1 || this.length);
|
||||
|
|
35
dashboard-ui/scripts/homelatest.js
Normal file
|
@ -0,0 +1,35 @@
|
|||
(function ($, document, apiClient) {
|
||||
|
||||
function loadSections(page, userId) {
|
||||
|
||||
var i, length;
|
||||
var sectionCount = 3;
|
||||
|
||||
var elem = $('.sections', page);
|
||||
|
||||
if (!elem.html().length) {
|
||||
var html = '';
|
||||
for (i = 0, length = sectionCount; i < length; i++) {
|
||||
|
||||
html += '<div class="homePageSection section' + i + '"></div>';
|
||||
}
|
||||
|
||||
elem.html(html);
|
||||
}
|
||||
|
||||
Sections.loadRecentlyAdded($('.section0', page), userId);
|
||||
Sections.loadLatestLiveTvRecordings($(".section1", page), userId);
|
||||
Sections.loadLatestChannelItems($(".section2", page), userId);
|
||||
}
|
||||
|
||||
$(document).on('pagebeforeshow', "#homeLatestPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
var userId = Dashboard.getCurrentUserId();
|
||||
|
||||
loadSections(page, userId);
|
||||
|
||||
});
|
||||
|
||||
})(jQuery, document, ApiClient);
|
|
@ -14,24 +14,6 @@
|
|||
return deferred.promise();
|
||||
}
|
||||
|
||||
function getDefaultSection(index) {
|
||||
|
||||
switch (index) {
|
||||
|
||||
case 0:
|
||||
return 'smalllibrarytiles';
|
||||
case 1:
|
||||
return 'resume';
|
||||
case 2:
|
||||
return 'latestmedia';
|
||||
case 3:
|
||||
return '';
|
||||
default:
|
||||
return '';
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function loadRecentlyAdded(elem, userId) {
|
||||
|
||||
var screenWidth = $(window).width();
|
||||
|
@ -40,7 +22,7 @@
|
|||
|
||||
SortBy: "DateCreated",
|
||||
SortOrder: "Descending",
|
||||
Limit: screenWidth >= 2400 ? 30 : (screenWidth >= 1920 ? 20 : (screenWidth >= 1440 ? 10 : (screenWidth >= 800 ? 9 : 8))),
|
||||
Limit: screenWidth >= 2400 ? 30 : (screenWidth >= 1920 ? 15 : (screenWidth >= 1440 ? 10 : (screenWidth >= 800 ? 9 : 8))),
|
||||
Recursive: true,
|
||||
Fields: "PrimaryImageAspectRatio",
|
||||
Filters: "IsUnplayed,IsNotFolder",
|
||||
|
@ -115,9 +97,12 @@
|
|||
|
||||
if (items.length) {
|
||||
|
||||
var cssClass = index ? 'listHeader' : 'listHeader firstListHeader';
|
||||
var cssClass = index !== 0 ? 'listHeader' : 'listHeader firstListHeader';
|
||||
|
||||
html += '<h1 class="' + cssClass + '">' + Globalize.translate('HeaderMyLibrary') + '</h1>';
|
||||
html += '<div>';
|
||||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="' + cssClass + '">' + Globalize.translate('HeaderMyViews') + '</h1>';
|
||||
html += '<a href="mypreferencesdisplay.html" data-role="button" data-icon="edit" data-mini="true" data-inline="true" data-iconpos="notext" class="sectionHeaderButton">d</a>';
|
||||
html += '</div>';
|
||||
|
||||
html += '<div>';
|
||||
html += LibraryBrowser.getPosterViewHtml({
|
||||
|
@ -214,6 +199,158 @@
|
|||
});
|
||||
}
|
||||
|
||||
function handleLibraryLinkNavigations(elem) {
|
||||
|
||||
$('a.posterItem', elem).on('click', function () {
|
||||
|
||||
var text = $('.posterItemText', this).html();
|
||||
|
||||
LibraryMenu.setText(text);
|
||||
});
|
||||
}
|
||||
|
||||
function loadLatestChannelItems(elem, userId, options) {
|
||||
|
||||
options = $.extend(options || {}, {
|
||||
|
||||
UserId: userId,
|
||||
SupportsLatestItems: true
|
||||
});
|
||||
|
||||
$.getJSON(ApiClient.getUrl("Channels", options)).done(function (result) {
|
||||
|
||||
var channels = result.Items;
|
||||
|
||||
var channelsHtml = channels.map(function (c) {
|
||||
|
||||
return '<div id="channel' + c.Id + '"></div>';
|
||||
|
||||
}).join('');
|
||||
|
||||
$(elem).html(channelsHtml);
|
||||
|
||||
for (var i = 0, length = channels.length; i < length; i++) {
|
||||
|
||||
var channel = channels[i];
|
||||
|
||||
loadLatestChannelItemsFromChannel(elem, channel, i);
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
function loadLatestChannelItemsFromChannel(page, channel, index) {
|
||||
|
||||
var screenWidth = $(window).width();
|
||||
|
||||
var options = {
|
||||
|
||||
Limit: screenWidth >= 1920 ? 9 : (screenWidth >= 1440 ? 8 : (screenWidth >= 800 ? 6 : 6)),
|
||||
Fields: "PrimaryImageAspectRatio",
|
||||
Filters: "IsUnplayed",
|
||||
UserId: Dashboard.getCurrentUserId(),
|
||||
ChannelIds: channel.Id
|
||||
};
|
||||
|
||||
$.getJSON(ApiClient.getUrl("Channels/Items/Latest", options)).done(function (result) {
|
||||
|
||||
var html = '';
|
||||
|
||||
if (result.Items.length) {
|
||||
|
||||
var cssClass = index !== 0 ? 'listHeader' : 'listHeader firstListHeader';
|
||||
|
||||
html += '<div>';
|
||||
var text = Globalize.translate('HeaderLatestFromChannel').replace('{0}', channel.Name);
|
||||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="' + cssClass + '">' + text + '</h1>';
|
||||
html += '<a href="channelitems.html?context=channels&id=' + channel.Id + '" data-role="button" data-icon="arrow-r" data-mini="true" data-inline="true" data-iconpos="notext" class="sectionHeaderButton">d</a>';
|
||||
html += '</div>';
|
||||
}
|
||||
html += LibraryBrowser.getPosterViewHtml({
|
||||
items: result.Items,
|
||||
shape: 'auto',
|
||||
defaultShape: 'square',
|
||||
showTitle: true,
|
||||
centerText: true,
|
||||
context: 'channels',
|
||||
lazy: true
|
||||
});
|
||||
|
||||
$('#channel' + channel.Id + '', page).html(html).trigger('create').createPosterItemMenus();
|
||||
});
|
||||
}
|
||||
|
||||
function loadLatestLiveTvRecordings(elem, userId, index) {
|
||||
|
||||
ApiClient.getLiveTvRecordings({
|
||||
|
||||
userId: userId,
|
||||
limit: 9,
|
||||
IsInProgress: false
|
||||
|
||||
}).done(function (result) {
|
||||
|
||||
var html = '';
|
||||
|
||||
if (result.Items.length) {
|
||||
|
||||
var cssClass = index !== 0 ? 'listHeader' : 'listHeader firstListHeader';
|
||||
|
||||
html += '<div>';
|
||||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="' + cssClass + '">' + Globalize.translate('HeaderLatestTvRecordings') + '</h1>';
|
||||
html += '<a href="livetvrecordings.html?context=livetv" data-role="button" data-icon="arrow-r" data-mini="true" data-inline="true" data-iconpos="notext" class="sectionHeaderButton">d</a>';
|
||||
html += '</div>';
|
||||
}
|
||||
|
||||
var screenWidth = $(window).width();
|
||||
|
||||
html += LibraryBrowser.getPosterViewHtml({
|
||||
items: result.Items,
|
||||
shape: "auto",
|
||||
showTitle: true,
|
||||
showParentTitle: true,
|
||||
overlayText: screenWidth >= 600,
|
||||
coverImage: true,
|
||||
lazy: true
|
||||
});
|
||||
|
||||
elem.html(html).trigger('create').createPosterItemMenus();
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
window.Sections = {
|
||||
loadRecentlyAdded: loadRecentlyAdded,
|
||||
loadLatestChannelMedia: loadLatestChannelMedia,
|
||||
loadLibraryTiles: loadLibraryTiles,
|
||||
loadLibraryFolders: loadLibraryFolders,
|
||||
loadResume: loadResume,
|
||||
loadLatestChannelItems: loadLatestChannelItems,
|
||||
loadLatestLiveTvRecordings: loadLatestLiveTvRecordings
|
||||
};
|
||||
|
||||
})(jQuery, document, ApiClient);
|
||||
|
||||
(function ($, document, apiClient) {
|
||||
|
||||
function getDefaultSection(index) {
|
||||
|
||||
switch (index) {
|
||||
|
||||
case 0:
|
||||
return 'smalllibrarytiles';
|
||||
case 1:
|
||||
return 'resume';
|
||||
case 2:
|
||||
return '';
|
||||
case 3:
|
||||
return '';
|
||||
default:
|
||||
return '';
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function loadSection(page, userId, displayPreferences, index) {
|
||||
|
||||
var section = displayPreferences.CustomPrefs['home' + index] || getDefaultSection(index);
|
||||
|
@ -221,23 +358,27 @@
|
|||
var elem = $('.section' + index, page);
|
||||
|
||||
if (section == 'latestmedia') {
|
||||
loadRecentlyAdded(elem, userId);
|
||||
Sections.loadRecentlyAdded(elem, userId);
|
||||
}
|
||||
else if (section == 'librarytiles') {
|
||||
loadLibraryTiles(elem, userId, 'backdrop', index);
|
||||
Sections.loadLibraryTiles(elem, userId, 'backdrop', index);
|
||||
}
|
||||
else if (section == 'smalllibrarytiles' || section == 'librarybuttons') {
|
||||
loadLibraryTiles(elem, userId, 'miniBackdrop', index);
|
||||
Sections.loadLibraryTiles(elem, userId, 'smallBackdrop', index);
|
||||
}
|
||||
else if (section == 'resume') {
|
||||
loadResume(elem, userId);
|
||||
Sections.loadResume(elem, userId);
|
||||
}
|
||||
|
||||
else if (section == 'latesttvrecordings') {
|
||||
Sections.loadLatestLiveTvRecordings(elem, userId);
|
||||
}
|
||||
|
||||
else if (section == 'folders') {
|
||||
loadLibraryFolders(elem, userId, 'backdrop', index);
|
||||
Sections.loadLibraryFolders(elem, userId, 'smallBackdrop', index);
|
||||
|
||||
} else if (section == 'latestchannelmedia') {
|
||||
loadLatestChannelMedia(elem, userId);
|
||||
Sections.loadLatestChannelMedia(elem, userId);
|
||||
|
||||
} else {
|
||||
|
||||
|
@ -268,16 +409,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
function handleLibraryLinkNavigations(elem) {
|
||||
|
||||
$('a', elem).on('click', function () {
|
||||
|
||||
var text = $('.posterItemText', this).html();
|
||||
|
||||
LibraryMenu.setText(text);
|
||||
});
|
||||
}
|
||||
|
||||
var homePageDismissValue = '2';
|
||||
|
||||
function dismissWelcome(page, userId) {
|
||||
|
|
|
@ -377,11 +377,11 @@
|
|||
return 'movieslatest.html?topParentId=' + item.Id;
|
||||
}
|
||||
|
||||
if (item.CollectionType == 'boxsets' || item.Type == 'ManualCollectionsFolder') {
|
||||
if (item.CollectionType == 'boxsets') {
|
||||
return 'collections.html?topParentId=' + item.Id;
|
||||
}
|
||||
|
||||
if (item.CollectionType == 'trailers' || item.Type == 'TrailerCollectionFolder') {
|
||||
if (item.CollectionType == 'trailers') {
|
||||
return 'movietrailers.html?topParentId=' + item.Id;
|
||||
}
|
||||
|
||||
|
@ -807,7 +807,7 @@
|
|||
|
||||
if (!imgUrl && !options.showTitle) {
|
||||
html += "<div class='posterItemDefaultText'>";
|
||||
html += name;
|
||||
html += htmlEncode(name);
|
||||
html += "</div>";
|
||||
}
|
||||
|
||||
|
@ -828,7 +828,7 @@
|
|||
|
||||
if (options.showTitle || forceName) {
|
||||
|
||||
lines.push(name);
|
||||
lines.push(htmlEncode(name));
|
||||
}
|
||||
|
||||
if (options.showItemCounts) {
|
||||
|
|
|
@ -34,15 +34,16 @@
|
|||
|
||||
html += '<div class="posterItemOverlayInner">';
|
||||
|
||||
var isSmallItem = $(posterItem).hasClass('smallBackdropPosterItem');
|
||||
var isSmallItem = $(posterItem).hasClass('smallBackdropPosterItem') || $(posterItem).hasClass('miniBackdropPosterItem');
|
||||
var isMiniItem = $(posterItem).hasClass('miniBackdropPosterItem');
|
||||
var isPortrait = $(posterItem).hasClass('portraitPosterItem');
|
||||
var isSquare = $(posterItem).hasClass('squarePosterItem');
|
||||
|
||||
var parentName = isSmallItem || isPortrait ? null : item.SeriesName;
|
||||
var parentName = isSmallItem || isMiniItem || isPortrait ? null : item.SeriesName;
|
||||
var name = LibraryBrowser.getPosterViewDisplayName(item, true);
|
||||
|
||||
html += '<div style="font-weight:bold;margin-bottom:1em;">';
|
||||
var logoHeight = isSmallItem ? 20 : 26;
|
||||
var logoHeight = isSmallItem || isMiniItem ? 20 : 26;
|
||||
var maxLogoWidth = isPortrait ? 100 : 200;
|
||||
var imgUrl;
|
||||
|
||||
|
@ -76,27 +77,29 @@
|
|||
html += '<p>';
|
||||
html += name;
|
||||
html += '</p>';
|
||||
} else if (!isSmallItem) {
|
||||
} else if (!isSmallItem && !isMiniItem) {
|
||||
html += '<p class="itemMiscInfo" style="white-space:nowrap;">';
|
||||
html += LibraryBrowser.getMiscInfoHtml(item);
|
||||
html += '</p>';
|
||||
}
|
||||
|
||||
html += '<div style="margin:1.25em 0;">';
|
||||
html += '<span class="itemCommunityRating">';
|
||||
html += LibraryBrowser.getRatingHtml(item, false);
|
||||
html += '</span>';
|
||||
if (!isMiniItem) {
|
||||
html += '<div style="margin:1.25em 0;">';
|
||||
html += '<span class="itemCommunityRating">';
|
||||
html += LibraryBrowser.getRatingHtml(item, false);
|
||||
html += '</span>';
|
||||
|
||||
if (isPortrait) {
|
||||
html += '<span class="userDataIcons" style="display:block;margin:1.25em 0;">';
|
||||
html += LibraryBrowser.getUserDataIconsHtml(item);
|
||||
html += '</span>';
|
||||
} else {
|
||||
html += '<span class="userDataIcons">';
|
||||
html += LibraryBrowser.getUserDataIconsHtml(item);
|
||||
html += '</span>';
|
||||
if (isPortrait) {
|
||||
html += '<span class="userDataIcons" style="display:block;margin:1.25em 0;">';
|
||||
html += LibraryBrowser.getUserDataIconsHtml(item);
|
||||
html += '</span>';
|
||||
} else {
|
||||
html += '<span class="userDataIcons">';
|
||||
html += LibraryBrowser.getUserDataIconsHtml(item);
|
||||
html += '</span>';
|
||||
}
|
||||
html += '</div>';
|
||||
}
|
||||
html += '</div>';
|
||||
|
||||
html += '<div>';
|
||||
|
||||
|
@ -179,9 +182,7 @@
|
|||
|
||||
}
|
||||
|
||||
$.fn.createPosterItemMenus = function (options) {
|
||||
|
||||
options = options || {};
|
||||
$.fn.createPosterItemMenus = function () {
|
||||
|
||||
var preventHover = false;
|
||||
|
||||
|
@ -243,7 +244,7 @@
|
|||
preventHover = true;
|
||||
}
|
||||
|
||||
var elems = '.backdropPosterItem,.smallBackdropPosterItem,.portraitPosterItem,.squarePosterItem';
|
||||
var elems = '.backdropPosterItem,.smallBackdropPosterItem,.portraitPosterItem,.squarePosterItem,.miniBackdropPosterItem';
|
||||
|
||||
return this.off('.posterItemHoverMenu')
|
||||
.on('mouseenter.posterItemHoverMenu', elems, onHoverIn)
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
|
||||
html += '<a class="headerButton headerButtonRight headerUserButton" href="#" onclick="Dashboard.showUserFlyout(this);">';
|
||||
|
||||
var userButtonHeight = 22;
|
||||
var userButtonHeight = 21;
|
||||
if (user.PrimaryImageTag) {
|
||||
|
||||
var url = ApiClient.getUserImageUrl(user.Id, {
|
||||
|
|
|
@ -209,7 +209,7 @@
|
|||
|
||||
$(document).on('headercreated', function (e) {
|
||||
|
||||
$('<a class="headerButton headerButtonRight btnNotifications" href="#" title="Notifications"><div class="btnNotificationsInner">0</div></a>').insertBefore($('.headerUserButton')).on('click', Notifications.showNotificationsFlyout);
|
||||
$('<a class="headerButton headerButtonRight btnNotifications" href="#" title="Notifications"><div class="btnNotificationsInner">0</div></a>').insertAfter($('.headerUserButton')).on('click', Notifications.showNotificationsFlyout);
|
||||
|
||||
Notifications.updateNotificationCount();
|
||||
});
|
||||
|
|
|
@ -231,7 +231,7 @@ var Dashboard = {
|
|||
var html = '<span style="margin-right: 1em;">Please restart to finish updating.</span>';
|
||||
|
||||
if (systemInfo.CanSelfRestart) {
|
||||
html += '<button type="button" data-icon="refresh" onclick="$(this).buttonEnabled(false);Dashboard.restartServer();" data-theme="b" data-inline="true" data-mini="true">Restart Server</button>';
|
||||
html += '<button type="button" data-icon="refresh" onclick="$(this).buttonEnabled(false);Dashboard.restartServer();" data-theme="b" data-inline="true" data-mini="true">Restart</button>';
|
||||
}
|
||||
|
||||
Dashboard.showFooterNotification({ id: "serverRestartWarning", html: html, forceShow: true, allowHide: false });
|
||||
|
|
|
@ -104,8 +104,10 @@
|
|||
|
||||
if (result.Items.length) {
|
||||
$('#resumableSection', page).show();
|
||||
$('.nextUpHeader', page).removeClass('firstListHeader');
|
||||
} else {
|
||||
$('#resumableSection', page).hide();
|
||||
$('.nextUpHeader', page).addClass('firstListHeader');
|
||||
}
|
||||
|
||||
$('#resumableItems', page).html(LibraryBrowser.getPosterViewHtml({
|
||||
|
|
|
@ -2625,7 +2625,7 @@ MediaBrowser.ApiClient = function ($, navigator, JSON, WebSocket, setTimeout, wi
|
|||
options = options || {};
|
||||
options.userId = userId;
|
||||
|
||||
var url = self.getUrl("AlbumArtists", options);
|
||||
var url = self.getUrl("Artists/AlbumArtists", options);
|
||||
|
||||
return self.ajax({
|
||||
type: "GET",
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
<div class="libraryViewNav globalNav" style="display: none;">
|
||||
<a href="index.html">${TabHome}</a>
|
||||
<a href="homelatest.html">${TabLatest}</a>
|
||||
<a href="#" class="ui-btn-active">${TabNextUp}</a>
|
||||
<a href="favorites.html">${TabFavorites}</a>
|
||||
<a href="tvupcoming.html">${TabUpcoming}</a>
|
||||
|
@ -35,7 +36,7 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<h1 class="listHeader">${HeaderNextUp}</h1>
|
||||
<h1 class="listHeader nextUpHeader">${HeaderNextUp}</h1>
|
||||
</div>
|
||||
|
||||
<div id="nextUpItems">
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
<div id="tvUpcomingPage" data-role="page" class="page libraryPage backdropPage" data-backdroptype="series" data-theme="b">
|
||||
<div class="libraryViewNav scopedLibraryViewNav">
|
||||
<a href="index.html">${TabHome}</a>
|
||||
<a href="homelatest.html">${TabLatest}</a>
|
||||
<a href="tvrecommended.html">${TabNextUp}</a>
|
||||
<a href="favorites.html">${TabFavorites}</a>
|
||||
<a href="#" class="ui-btn-active">${TabUpcoming}</a>
|
||||
|
|