From 047e97cb22327076fb10e842d03c680b0e12b487 Mon Sep 17 00:00:00 2001 From: Chris Schneider Date: Fri, 22 Feb 2013 09:08:51 -0600 Subject: [PATCH 1/3] make metro styled tiles look and act the same --- MediaBrowser.WebDashboard/Html/css/site.css | 44 ++++++++++++------- MediaBrowser.WebDashboard/Html/login.html | 2 +- .../Html/scripts/LoginPage.js | 32 +++++++++----- .../Html/scripts/PluginCatalogPage.js | 6 ++- .../Html/scripts/site.js | 27 ++++-------- 5 files changed, 62 insertions(+), 49 deletions(-) diff --git a/MediaBrowser.WebDashboard/Html/css/site.css b/MediaBrowser.WebDashboard/Html/css/site.css index c9b2089c73..2c4971bcc7 100644 --- a/MediaBrowser.WebDashboard/Html/css/site.css +++ b/MediaBrowser.WebDashboard/Html/css/site.css @@ -425,7 +425,6 @@ form, .readOnlyContent { font-size: 15px; padding: 0; position: relative; - padding-bottom: 28px; } .posterViewItem a { @@ -436,7 +435,7 @@ form, .readOnlyContent { .posterViewItem img { max-width: 155px; - max-height: 148px; + max-height: 155px; vertical-align: bottom; } @@ -454,19 +453,25 @@ form, .readOnlyContent { .posterViewItemText { text-overflow: ellipsis; overflow: hidden; - text-wrap: none; white-space: nowrap; margin: 0; - padding: 4px 2px 0; - position: absolute; + padding: 4px 0px 0; bottom: 0; left: 0; right: 0; - height: 24px; background: #181818; text-shadow: none; + max-width: 155px; } + .posterViewItemText div{ + text-overflow: ellipsis; + overflow: hidden; + white-space: nowrap; + margin: 0px 4px; + height: 24px; + } + .posterViewItem:hover, .userItem:hover { -moz-box-shadow: 0 0 20px 3px #2572EB; -webkit-box-shadow: 0 0 20px 3px #2572EB; @@ -477,11 +482,11 @@ form, .readOnlyContent { .posterViewItem { font-size: 16px; - padding-bottom: 29px; } .posterViewItemText { padding-top: 5px; + max-width: 190px; } .posterViewItem img { @@ -496,29 +501,37 @@ form, .readOnlyContent { font-size: 17px; } - .posterViewItem img { - max-width: 280px; - max-height: 250px; - } + .posterViewItem img { + max-width: 280px; + max-height: 280px; + } + + .posterViewItemText { + max-width: 280px; + } } @media all and (min-width: 1920px) { .posterViewItem { font-size: 19px; - padding-bottom: 33px; } - .posterViewItemText { + .posterViewItemText div{ height: 28px; } .posterViewItem img { max-width: 352px; - max-height: 300px; + max-height: 352px; + } + + .posterViewItemText { + max-width: 352px; } } +/*DEPRECATED userItem classes .userItem { display: inline-block; margin: 5px; @@ -620,7 +633,8 @@ form, .readOnlyContent { .userItemHeader { font-size: 40px; } -} +}*/ +/*DEPRECATED userItem classes END /* Startup wizard */ .wizardPage { diff --git a/MediaBrowser.WebDashboard/Html/login.html b/MediaBrowser.WebDashboard/Html/login.html index 4cb73c06ef..36c453d555 100644 --- a/MediaBrowser.WebDashboard/Html/login.html +++ b/MediaBrowser.WebDashboard/Html/login.html @@ -7,7 +7,7 @@
-
+
'; From 58cfcd412672d213af01630cf2894ff78a7bf24c Mon Sep 17 00:00:00 2001 From: Chris Schneider Date: Fri, 22 Feb 2013 09:28:35 -0600 Subject: [PATCH 2/3] added missing type: attr type: attributes were accidentally omitted during the merge --- .../Html/scripts/LoginPage.js | 6 ++++-- .../Html/scripts/site.js | 19 ++++++++++++++++--- 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/MediaBrowser.WebDashboard/Html/scripts/LoginPage.js b/MediaBrowser.WebDashboard/Html/scripts/LoginPage.js index c6d89a4c11..ca4677e04e 100644 --- a/MediaBrowser.WebDashboard/Html/scripts/LoginPage.js +++ b/MediaBrowser.WebDashboard/Html/scripts/LoginPage.js @@ -23,7 +23,8 @@ return ApiClient.getUserImageUrl(user.Id, { width: 240, - tag: user.PrimaryImageTag + tag: user.PrimaryImageTag, + type: "Primary" }); }, @@ -73,7 +74,8 @@ var imgUrl = ApiClient.getUserImageUrl(user.Id, { width: 500, - tag: user.PrimaryImageTag + tag: user.PrimaryImageTag, + type: "Primary" }); html += ''; diff --git a/MediaBrowser.WebDashboard/Html/scripts/site.js b/MediaBrowser.WebDashboard/Html/scripts/site.js index 67f28aeeba..2660697dc2 100644 --- a/MediaBrowser.WebDashboard/Html/scripts/site.js +++ b/MediaBrowser.WebDashboard/Html/scripts/site.js @@ -474,7 +474,8 @@ var Dashboard = { var imageUrl = user.PrimaryImageTag ? ApiClient.getUserImageUrl(user.Id, { height: 400, - tag: user.PrimaryImageTag + tag: user.PrimaryImageTag, + type: "Primary" }) : "css/images/userFlyoutDefault.png"; @@ -566,7 +567,18 @@ var Dashboard = { Dashboard.showLoadingMsg(); - ApiClient.getDirectoryContents(path, { includeDirectories: true }).done(function (folders) { + var promise; + + if (path === "Network") { + promise = ApiClient.getNetworkComputers(); + } + else if (path) { + promise = ApiClient.getDirectoryContents(path, { includeDirectories: true }); + } else { + promise = ApiClient.getDrives(); + } + + promise.done(function (folders) { $('#txtDirectoryPickerPath', page).val(path || ""); @@ -683,7 +695,8 @@ var Dashboard = { var url = ApiClient.getUserImageUrl(user.Id, { width: 225, - tag: user.PrimaryImageTag + tag: user.PrimaryImageTag, + type: "Primary" }); headerHtml += ''; From 5623abb2869d7f3d9c7a06ef39342b4569a3f710 Mon Sep 17 00:00:00 2001 From: Chris Schneider Date: Fri, 22 Feb 2013 09:46:39 -0600 Subject: [PATCH 3/3] removed deprecated code --- MediaBrowser.WebDashboard/Html/css/site.css | 105 -------------------- 1 file changed, 105 deletions(-) diff --git a/MediaBrowser.WebDashboard/Html/css/site.css b/MediaBrowser.WebDashboard/Html/css/site.css index 2c4971bcc7..186266c4dc 100644 --- a/MediaBrowser.WebDashboard/Html/css/site.css +++ b/MediaBrowser.WebDashboard/Html/css/site.css @@ -531,111 +531,6 @@ form, .readOnlyContent { } } -/*DEPRECATED userItem classes -.userItem { - display: inline-block; - margin: 5px; - font-size: 15px; - text-align: left; -} - -.userItemImage { - height: 100px; - width: 100px; - vertical-align: bottom; -} - -.userItemContent { - display: inline-block; - height: 100px; - width: 180px; - float: right; - text-shadow: none; - font-family: 'Segoe UI Light', 'Open Sans', Arial; -} - -.userItemContentInner { - padding: 15px 5px 5px 10px; - color: #fff; -} - -.userItemHeader { - margin: 0 0 10px; - font-size: 16px; - text-overflow: ellipsis; - overflow: hidden; - text-wrap: avoid; - font-family: 'Segoe UI Semilight', 'Open Sans', Arial; -} - -@media all and (min-width: 750px) { - - .userItem { - font-size: 16px; - } - - .userItemContentInner { - padding: 30px 20px 20px; - } - - .userItemImage { - height: 140px; - width: 140px; - } - - .userItemContent { - height: 140px; - width: 210px; - } - - .userItemHeader { - font-size: 26px; - } -} - -@media all and (min-width: 1200px) { - - .userItem { - font-size: 18px; - } - - .userItemImage { - height: 180px; - width: 180px; - } - - .userItemContent { - height: 180px; - width: 270px; - } - - .userItemHeader { - font-size: 32px; - } -} - -@media all and (min-width: 1920px) { - - .userItem { - font-size: 20px; - } - - .userItemImage { - height: 240px; - width: 240px; - } - - .userItemContent { - height: 240px; - width: 360px; - } - - .userItemHeader { - font-size: 40px; - } -}*/ -/*DEPRECATED userItem classes END - /* Startup wizard */ .wizardPage { background: #e2e2e2;