From f06105e6889ad3899f83566c8e2f65d3017ef4c0 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sun, 29 Dec 2013 23:35:27 -0500 Subject: [PATCH] restore progress bar on detail page --- dashboard-ui/css/librarybrowser.css | 14 ++++++++++++++ dashboard-ui/scripts/episodes.js | 1 + dashboard-ui/scripts/librarybrowser.js | 21 ++++++++++++++++++--- 3 files changed, 33 insertions(+), 3 deletions(-) diff --git a/dashboard-ui/css/librarybrowser.css b/dashboard-ui/css/librarybrowser.css index a1aa9ac5ee..580f0a7f9c 100644 --- a/dashboard-ui/css/librarybrowser.css +++ b/dashboard-ui/css/librarybrowser.css @@ -551,6 +551,20 @@ a.itemTag:hover { margin-right: 5px; } +.detailImageProgressContainer { + position: absolute; + bottom: 6px; + right: 0; + left: 0; + text-align: center; +} + +.detailImageProgressContainer progress { + width: 100%; + margin: 0 auto; + height: 6px; +} + @media all and (max-width: 550px) { .desktopViewMenuLink { diff --git a/dashboard-ui/scripts/episodes.js b/dashboard-ui/scripts/episodes.js index db669e0733..48802dbf59 100644 --- a/dashboard-ui/scripts/episodes.js +++ b/dashboard-ui/scripts/episodes.js @@ -38,6 +38,7 @@ useAverageAspectRatio: true, shape: "backdrop", showTitle: true, + showProgressBar: true, showParentTitle: true, overlayText: true }); diff --git a/dashboard-ui/scripts/librarybrowser.js b/dashboard-ui/scripts/librarybrowser.js index 602005d4cb..aa68736463 100644 --- a/dashboard-ui/scripts/librarybrowser.js +++ b/dashboard-ui/scripts/librarybrowser.js @@ -946,9 +946,13 @@ if (options.showProgressBar) { - html += "
"; - html += LibraryBrowser.getItemProgressBarHtml(item) || " "; - html += "
"; + var progressHtml = LibraryBrowser.getItemProgressBarHtml(item); + + if (progressHtml || !options.overlayText) { + html += "
"; + html += progressHtml || " "; + html += "
"; + } } if (overlayText) { @@ -1980,6 +1984,7 @@ var linkToGallery = LibraryBrowser.shouldDisplayGallery(item); + html += '
'; if (linkToGallery) { html += ""; } @@ -1990,6 +1995,16 @@ html += ""; } + var progressHtml = LibraryBrowser.getItemProgressBarHtml(item); + + if (progressHtml) { + html += '
'; + html += progressHtml; + html += "
"; + } + + html += "
"; + return html; },