From d12c2644e78b22306e7258cce074c6b88117842f Mon Sep 17 00:00:00 2001
From: Luke Pulverenti
diff --git a/dashboard-ui/css/librarybrowser.css b/dashboard-ui/css/librarybrowser.css
index 976d4c43b7..02e843e489 100644
--- a/dashboard-ui/css/librarybrowser.css
+++ b/dashboard-ui/css/librarybrowser.css
@@ -31,7 +31,6 @@
background-size: cover;
}
-
.libraryPage .header {
padding-bottom: 0;
}
@@ -75,6 +74,17 @@
margin-top: 1em;
}
+@media all and (min-width: 900px) {
+
+ .ehsContent {
+ max-width: 880px;
+ }
+
+ .squareEhsContent {
+ max-width: 750px;
+ }
+}
+
@media all and (min-width: 1000px) {
.ehsContent {
diff --git a/dashboard-ui/css/posteritem.css b/dashboard-ui/css/posteritem.css
index a18a9e31f9..010d4a03b2 100644
--- a/dashboard-ui/css/posteritem.css
+++ b/dashboard-ui/css/posteritem.css
@@ -42,9 +42,9 @@
position: relative;
}
- #scenesContent .posterItemImage {
- background-position-y: center;
- }
+#scenesContent .posterItemImage {
+ background-position-y: center;
+}
.posterItem:hover .posterItemImage {
-moz-box-shadow: 0 0 12px 7px #38c;
@@ -126,11 +126,11 @@
}
.squarePosterItem {
- width: 148px;
+ width: 140px;
}
.squarePosterItem .posterItemImage {
- height: 148px;
+ height: 140px;
}
.storeReviewCount {
@@ -343,31 +343,23 @@
}
.miniBackdropPosterItem {
- width: 180px;
+ width: 168px;
}
.miniBackdropPosterItem .posterItemImage {
- height: 101.25px;
+ height: 94.5px;
}
}
@media all and (min-width: 600px) {
- .squarePosterItem {
- width: 170px;
- }
-
- .squarePosterItem .posterItemImage {
- height: 170px;
- }
-
.portraitPosterItem {
- width: 128px;
+ width: 118px;
}
.portraitPosterItem .posterItemImage {
- height: 192px;
+ height: 177px;
}
}
@@ -407,14 +399,6 @@
@media all and (min-width: 750px) {
- .portraitPosterItem {
- width: 118px;
- }
-
- .portraitPosterItem .posterItemImage {
- height: 177px;
- }
-
.bannerPosterItem {
width: 330px;
}
@@ -442,11 +426,11 @@
@media all and (min-width: 1200px) {
.portraitPosterItem {
- width: 144px;
+ width: 122px;
}
.portraitPosterItem .posterItemImage {
- height: 216px;
+ height: 183px;
}
.storeReviewCount {
@@ -468,14 +452,6 @@
width: 19%;
}
- .squarePosterItem {
- width: 167px;
- }
-
- .squarePosterItem .posterItemImage {
- height: 167px;
- }
-
.backdropPosterItem {
width: 298px;
}
diff --git a/dashboard-ui/scripts/channelslatest.js b/dashboard-ui/scripts/channelslatest.js
index ce4818f56d..0effc317f9 100644
--- a/dashboard-ui/scripts/channelslatest.js
+++ b/dashboard-ui/scripts/channelslatest.js
@@ -1,21 +1,47 @@
(function ($, document) {
- function reloadItems(page) {
+ function reloadFromChannels(page, channels) {
- Dashboard.showLoadingMsg();
+ var channelsHtml = channels.map(function (c) {
+
+ return '';
+
+ }).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 options = {
- Limit: 30,
+ Limit: 7,
Fields: "PrimaryImageAspectRatio",
Filters: "IsUnplayed",
- UserId: Dashboard.getCurrentUserId()
+ 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 += '
-
${HeaderLatestChannelItems}
- ' + text + '
';
+ } else {
+ html += '' + text + '
';
+ }
+ }
html += LibraryBrowser.getPosterViewHtml({
items: result.Items,
shape: 'auto',
@@ -25,8 +51,24 @@
lazy: true
});
- $("#items", page).html(html).trigger('create').createPosterItemMenus();
-
+ $('#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();
});
}
diff --git a/dashboard-ui/scripts/dashboardpage.js b/dashboard-ui/scripts/dashboardpage.js
index 5faa2692da..88f8cb7f32 100644
--- a/dashboard-ui/scripts/dashboardpage.js
+++ b/dashboard-ui/scripts/dashboardpage.js
@@ -50,14 +50,15 @@
Dashboard.updateSystemInfo(systemInfo);
- $('#appVersionNumber', page).html('Version ' + systemInfo.Version);
+ $('#appVersionNumber', page).html(Globalize.translate('LabelVersionNumber').replace('{0}', systemInfo.Version));
var port = systemInfo.HttpServerPortNumber;
if (port == systemInfo.WebSocketPortNumber) {
- $('#ports', page).html('Running on port ' + port + '');
+
+ $('#ports', page).html(Globalize.translate('LabelRunningOnPort').replace('{0}', '' + port + ''));
} else {
- $('#ports', page).html('Running on ports ' + port + ' and ' + systemInfo.WebSocketPortNumber + '');
+ $('#ports', page).html(Globalize.translate('LabelRunningOnPorts').replace('{0}', '' + port + '').replace('{1}', '' + systemInfo.WebSocketPortNumber + ''));
}
if (systemInfo.CanSelfRestart) {
@@ -340,13 +341,13 @@
html += '