From 7b8b4efc16648ca9ead2f85e20f88b7dc4df5aad Mon Sep 17 00:00:00 2001 From: Ruud Date: Mon, 13 Jul 2015 20:55:04 +0200 Subject: [PATCH] Charts --- couchpotato/core/media/movie/_base/static/list.js | 6 +- couchpotato/core/media/movie/charts/main.py | 16 ++ .../core/media/movie/charts/static/charts.js | 103 +++-------- .../media/movie/providers/automation/bluray.py | 2 +- .../core/media/movie/suggestion/static/suggest.js | 173 ------------------- .../media/movie/suggestion/static/suggest.scss | 162 ----------------- couchpotato/static/scripts/combined.base.min.js | 2 +- couchpotato/static/scripts/combined.plugins.min.js | 192 +++------------------ couchpotato/static/scripts/page/home.js | 3 +- couchpotato/static/style/combined.min.css | 30 +--- 10 files changed, 71 insertions(+), 618 deletions(-) delete mode 100644 couchpotato/core/media/movie/suggestion/static/suggest.js delete mode 100644 couchpotato/core/media/movie/suggestion/static/suggest.scss diff --git a/couchpotato/core/media/movie/_base/static/list.js b/couchpotato/core/media/movie/_base/static/list.js index 168eea0..68cfba4 100644 --- a/couchpotato/core/media/movie/_base/static/list.js +++ b/couchpotato/core/media/movie/_base/static/list.js @@ -3,6 +3,7 @@ var MovieList = new Class({ Implements: [Events, Options], options: { + api_call: 'media.list', animated_in: false, navigation: true, limit: 50, @@ -52,7 +53,8 @@ var MovieList = new Class({ if(self.options.navigation) self.createNavigation(); - self.getMovies(); + if(self.options.api_call) + self.getMovies(); App.on('movie.added', self.movieAdded.bind(self)); App.on('movie.deleted', self.movieDeleted.bind(self)); @@ -580,7 +582,7 @@ var MovieList = new Class({ } - Api.request(self.options.api_call || 'media.list', { + Api.request(self.options.api_call, { 'data': Object.merge({ 'type': self.options.type || 'movie', 'status': self.options.status, diff --git a/couchpotato/core/media/movie/charts/main.py b/couchpotato/core/media/movie/charts/main.py index 9ab57dd..5aa5679 100644 --- a/couchpotato/core/media/movie/charts/main.py +++ b/couchpotato/core/media/movie/charts/main.py @@ -1,4 +1,5 @@ import time +from couchpotato.core.helpers.variable import getTitle from couchpotato.core.logger import CPLog from couchpotato.api import addApiView @@ -52,6 +53,21 @@ class Charts(Plugin): for chart in charts: chart['hide_wanted'] = self.conf('hide_wanted') chart['hide_library'] = self.conf('hide_library') + + # Create a list the movie/list.js can use + medias = [] + for media in chart.get('list'): + medias.append({ + 'status': 'suggested', + 'title': getTitle(media), + 'type': 'movie', + 'info': media, + 'identifiers': { + 'imdb': media.get('imdb') + } + }) + chart['list'] = medias + self.setCache('charts_cached', charts, timeout = self.update_interval * 3600) except: log.error('Failed refreshing charts') diff --git a/couchpotato/core/media/movie/charts/static/charts.js b/couchpotato/core/media/movie/charts/static/charts.js index 95412ac..1036840 100644 --- a/couchpotato/core/media/movie/charts/static/charts.js +++ b/couchpotato/core/media/movie/charts/static/charts.js @@ -42,12 +42,7 @@ var Charts = new Class({ ) ); - if( Cookie.read('suggestions_charts_menu_selected') === 'charts'){ - self.show(); - } - else - self.el.hide(); - + self.show(); self.fireEvent.delay(0, self, 'created'); }, @@ -73,79 +68,25 @@ var Charts = new Class({ Object.each(json.charts, function(chart){ - var c = new Element('div.chart.tiny_scroll').grab( - new Element('h3').grab( new Element('a', { - 'text': chart.name, - 'href': chart.url - })) - ); - - var it = 1; - - Object.each(chart.list, function(movie){ - - var m = new BlockSearchMovieItem(movie, { - 'onAdded': function(){ - self.afterAdded(m, movie); - } - }); - - var in_database_class = (chart.hide_wanted && movie.in_wanted) ? 'hidden' : (movie.in_wanted ? 'chart_in_wanted' : ((chart.hide_library && movie.in_library) ? 'hidden': (movie.in_library ? 'chart_in_library' : ''))), - in_database_title = movie.in_wanted ? 'Movie in wanted list' : (movie.in_library ? 'Movie in library' : ''); - - m.el.addClass(in_database_class) - .grab( - new Element('div.chart_number', { - 'text': it++, - 'title': in_database_title - }) - ); - - m.data_container.grab( - new Element('div.actions').adopt( - new Element('a.add.icon2', { - 'title': 'Add movie with your default quality', - 'data-add': movie.imdb, - 'events': { - 'click': m.showOptions.bind(m) - } - }), - $(new MA.IMDB(m)), - $(new MA.Trailer(m, { - 'height': 150 - })) - ) - ); - m.data_container.removeEvents('click'); - - var plot = false; - if(m.info.plot && m.info.plot.length > 0) - plot = m.info.plot; - - // Add rating - m.info_container.adopt( - m.rating = m.info.rating && m.info.rating.imdb && m.info.rating.imdb.length == 2 && parseFloat(m.info.rating.imdb[0]) > 0 ? new Element('span.rating', { - 'text': parseFloat(m.info.rating.imdb[0]), - 'title': parseInt(m.info.rating.imdb[1]) + ' votes' - }) : null, - m.genre = m.info.genres && m.info.genres.length > 0 ? new Element('span.genres', { - 'text': m.info.genres.slice(0, 3).join(', ') - }) : null, - m.plot = plot ? new Element('span.plot', { - 'text': plot, - 'events': { - 'click': function(){ - this.toggleClass('full'); - } - } - }) : null - ); - - $(m).inject(c); - + var chart_list = new MovieList({ + 'navigation': false, + 'identifier': chart.name.toLowerCase().replace(/[^a-z0-9]+/g, '_'), + 'title': chart.name, + 'description': 'See source', + 'actions': [MA.Add, MA.SuggestIgnore, MA.SuggestSeen, MA.IMDB, MA.Trailer], + 'load_more': false, + 'view': 'thumb', + 'force_view': true, + 'api_call': null }); - c.inject(self.el); + // Load movies in manually + chart_list.store(chart.list); + chart_list.addMovies(chart.list, chart.list.length); + chart_list.checkIfEmpty(); + chart_list.fireEvent('loaded'); + + $(chart_list).inject(self.el); }); @@ -161,9 +102,11 @@ var Charts = new Class({ self.el.show(); if(!self.shown_once){ - self.api_request = Api.request('charts.view', { - 'onComplete': self.fill.bind(self) - }); + setTimeout(function(){ + self.api_request = Api.request('charts.view', { + 'onComplete': self.fill.bind(self) + }); + }, 100); self.shown_once = true; } diff --git a/couchpotato/core/media/movie/providers/automation/bluray.py b/couchpotato/core/media/movie/providers/automation/bluray.py index 41dfc76..9ae904e 100644 --- a/couchpotato/core/media/movie/providers/automation/bluray.py +++ b/couchpotato/core/media/movie/providers/automation/bluray.py @@ -139,7 +139,7 @@ class Bluray(Automation, RSS): if not movie_list['list']: return - return [ movie_list ] + return [movie_list] config = [{ diff --git a/couchpotato/core/media/movie/suggestion/static/suggest.js b/couchpotato/core/media/movie/suggestion/static/suggest.js deleted file mode 100644 index 083fd3b..0000000 --- a/couchpotato/core/media/movie/suggestion/static/suggest.js +++ /dev/null @@ -1,173 +0,0 @@ -var SuggestList = new Class({ - - Implements: [Options, Events], - - shown_once: false, - - initialize: function(options){ - var self = this; - self.setOptions(options); - - self.create(); - }, - - create: function(){ - var self = this; - - self.el = new Element('div.suggestions', { - 'events': { - 'click:relay(a.delete)': function(e, el){ - (e).stop(); - - $(el).getParent('.media_result').destroy(); - - Api.request('suggestion.ignore', { - 'data': { - 'imdb': el.get('data-ignore') - }, - 'onComplete': self.fill.bind(self) - }); - - }, - 'click:relay(a.eye-open)': function(e, el){ - (e).stop(); - - $(el).getParent('.media_result').destroy(); - - Api.request('suggestion.ignore', { - 'data': { - 'imdb': el.get('data-seen'), - 'mark_seen': 1 - }, - 'onComplete': self.fill.bind(self) - }); - - } - } - }); - - var cookie_menu_select = Cookie.read('suggestions_charts_menu_selected') || 'suggestions'; - if( cookie_menu_select === 'suggestions') - self.show(); - else - self.hide(); - - self.fireEvent.delay(0, self, 'created'); - - }, - - fill: function(json){ - - var self = this; - - if(!json || json.count === 0){ - self.el.hide(); - } - else { - - Object.each(json.suggestions, function(movie){ - - var m = new BlockSearchMovieItem(movie, { - 'onAdded': function(){ - self.afterAdded(m, movie); - } - }); - m.data_container.grab( - new Element('div.actions').adopt( - new Element('a.add.icon2', { - 'title': 'Add movie with your default quality', - 'data-add': movie.imdb, - 'events': { - 'click': m.showOptions.bind(m) - } - }), - $(new MA.IMDB(m)), - $(new MA.Trailer(m, { - 'height': 150 - })), - new Element('a.delete.icon2', { - 'title': 'Don\'t suggest this movie again', - 'data-ignore': movie.imdb - }), - new Element('a.eye-open.icon2', { - 'title': 'Seen it, like it, don\'t add', - 'data-seen': movie.imdb - }) - ) - ); - m.data_container.removeEvents('click'); - - var plot = false; - if(m.info.plot && m.info.plot.length > 0) - plot = m.info.plot; - - // Add rating - m.info_container.adopt( - m.rating = m.info.rating && m.info.rating.imdb && m.info.rating.imdb.length == 2 && parseFloat(m.info.rating.imdb[0]) > 0 ? new Element('span.rating', { - 'text': parseFloat(m.info.rating.imdb[0]), - 'title': parseInt(m.info.rating.imdb[1]) + ' votes' - }) : null, - m.genre = m.info.genres && m.info.genres.length > 0 ? new Element('span.genres', { - 'text': m.info.genres.slice(0, 3).join(', ') - }) : null, - m.plot = plot ? new Element('span.plot', { - 'text': plot, - 'events': { - 'click': function(){ - this.toggleClass('full'); - } - } - }) : null - ); - - $(m).inject(self.el); - - }); - - } - - self.fireEvent('loaded'); - - }, - - afterAdded: function(m, movie){ - var self = this; - - setTimeout(function(){ - $(m).destroy(); - - Api.request('suggestion.ignore', { - 'data': { - 'imdb': movie.imdb, - 'remove_only': true - }, - 'onComplete': self.fill.bind(self) - }); - - }, 3000); - - }, - - show: function(){ - var self = this; - - self.el.show(); - - if(!self.shown_once){ - self.api_request = Api.request('suggestion.view', { - 'onComplete': self.fill.bind(self) - }); - - self.shown_once = true; - } - }, - - hide: function(){ - this.el.hide(); - }, - - toElement: function(){ - return this.el; - } - -}); diff --git a/couchpotato/core/media/movie/suggestion/static/suggest.scss b/couchpotato/core/media/movie/suggestion/static/suggest.scss deleted file mode 100644 index 8e74784..0000000 --- a/couchpotato/core/media/movie/suggestion/static/suggest.scss +++ /dev/null @@ -1,162 +0,0 @@ -.suggestions { - clear: both; - padding-top: 10px; - margin-bottom: 30px; -} - - .suggestions > h2 { - height: 40px; - } - -.suggestions .media_result { - display: inline-block; - width: 33.333%; - height: 150px; -} - - @media all and (max-width: 960px) { - .suggestions .media_result { - width: 50%; - } - } - - @media all and (max-width: 600px) { - .suggestions .media_result { - width: 100%; - } - } - - .suggestions .media_result .data { - left: 100px; - background: #4e5969; - border: none; - } - - .suggestions .media_result .data .info { - top: 10px; - left: 15px; - right: 15px; - bottom: 10px; - overflow: hidden; - } - - .suggestions .media_result .data .info h2 { - white-space: normal; - max-height: 120px; - font-size: 18px; - line-height: 18px; - } - - .suggestions .media_result .data .info .rating, - .suggestions .media_result .data .info .genres, - .suggestions .media_result .data .info .year { - position: static; - display: block; - padding: 0; - opacity: .6; - } - - .suggestions .media_result .data .info .year { - margin: 10px 0 0; - } - - .suggestions .media_result .data .info .rating { - font-size: 20px; - float: right; - margin-top: -20px; - } - .suggestions .media_result .data .info .rating:before { - content: "\e031"; - font-family: 'Elusive-Icons'; - font-size: 14px; - margin: 0 5px 0 0; - vertical-align: bottom; - } - - .suggestions .media_result .data .info .genres { - font-size: 11px; - font-style: italic; - text-align: right; - } - - .suggestions .media_result .data .info .plot { - display: block; - font-size: 11px; - overflow: hidden; - text-align: justify; - height: 100%; - z-index: 2; - top: 64px; - position: absolute; - background: #4e5969; - cursor: pointer; - transition: all .4s ease-in-out; - padding: 0 3px 10px 0; - } - .suggestions .media_result .data:before { - content: ''; - display: block; - height: 10px; - right: 0; - left: 0; - bottom: 10px; - position: absolute; - background: linear-gradient( - 0deg, - rgba(78, 89, 105, 1) 0%, - rgba(78, 89, 105, 0) 100% - ); - z-index: 3; - pointer-events: none; - } - - .suggestions .media_result .data .info .plot.full { - top: 0; - overflow: auto; - } - - .suggestions .media_result .data { - cursor: default; - } - - .suggestions .media_result .options { - left: 100px; - } - .suggestions .media_result .options select[name=title] { width: 100%; } - .suggestions .media_result .options select[name=profile] { width: 100%; } - .suggestions .media_result .options select[name=category] { width: 100%; } - - .suggestions .media_result .button { - position: absolute; - margin: 2px 0 0 0; - right: 15px; - bottom: 15px; - } - - - .suggestions .media_result .thumbnail { - width: 100px; - } - - .suggestions .media_result .actions { - position: absolute; - top: 10px; - right: 10px; - display: none; - width: 140px; - } - .suggestions .media_result:hover .actions { - display: block; - } - .suggestions .media_result:hover h2 .title { - opacity: 0; - } - .suggestions .media_result .data.open .actions { - display: none; - } - - .suggestions .media_result .actions a { - margin-left: 10px; - vertical-align: middle; - } - diff --git a/couchpotato/static/scripts/combined.base.min.js b/couchpotato/static/scripts/combined.base.min.js index 790a6ce..9e84ec4 100644 --- a/couchpotato/static/scripts/combined.base.min.js +++ b/couchpotato/static/scripts/combined.base.min.js @@ -970,7 +970,7 @@ Page.Home = new Class({ return; } self.chain = new Chain(); - self.chain.chain(self.createAvailable.bind(self), self.createSoon.bind(self), self.createSuggestions.bind(self), self.createCharts.bind(self), self.createLate.bind(self)); + self.chain.chain(self.createAvailable.bind(self), self.createSoon.bind(self), self.createSuggestions.bind(self), self.createLate.bind(self)); self.chain.callChain(); }, createAvailable: function() { diff --git a/couchpotato/static/scripts/combined.plugins.min.js b/couchpotato/static/scripts/combined.plugins.min.js index 0f50f63..8946311 100644 --- a/couchpotato/static/scripts/combined.plugins.min.js +++ b/couchpotato/static/scripts/combined.plugins.min.js @@ -423,6 +423,7 @@ var MovieDetails = new Class({ var MovieList = new Class({ Implements: [ Events, Options ], options: { + api_call: "media.list", animated_in: false, navigation: true, limit: 50, @@ -462,7 +463,7 @@ var MovieList = new Class({ }) : null); self.changeView(self.getSavedView() || self.options.view || "thumb"); if (self.options.navigation) self.createNavigation(); - self.getMovies(); + if (self.options.api_call) self.getMovies(); App.on("movie.added", self.movieAdded.bind(self)); App.on("movie.deleted", self.movieDeleted.bind(self)); }, @@ -837,7 +838,7 @@ var MovieList = new Class({ }, 10); self.el.setStyle("min-height", 220); } - Api.request(self.options.api_call || "media.list", { + Api.request(self.options.api_call, { data: Object.merge({ type: self.options.type || "movie", status: self.options.status, @@ -2345,9 +2346,7 @@ var Charts = new Class({ }), self.el_refreshing_text = new Element("span.refreshing", { text: "Refreshing charts..." }))); - if (Cookie.read("suggestions_charts_menu_selected") === "charts") { - self.show(); - } else self.el.hide(); + self.show(); self.fireEvent.delay(0, self, "created"); }, fill: function(json) { @@ -2364,50 +2363,22 @@ var Charts = new Class({ return a.order - b.order; }); Object.each(json.charts, function(chart) { - var c = new Element("div.chart.tiny_scroll").grab(new Element("h3").grab(new Element("a", { - text: chart.name, - href: chart.url - }))); - var it = 1; - Object.each(chart.list, function(movie) { - var m = new BlockSearchMovieItem(movie, { - onAdded: function() { - self.afterAdded(m, movie); - } - }); - var in_database_class = chart.hide_wanted && movie.in_wanted ? "hidden" : movie.in_wanted ? "chart_in_wanted" : chart.hide_library && movie.in_library ? "hidden" : movie.in_library ? "chart_in_library" : "", in_database_title = movie.in_wanted ? "Movie in wanted list" : movie.in_library ? "Movie in library" : ""; - m.el.addClass(in_database_class).grab(new Element("div.chart_number", { - text: it++, - title: in_database_title - })); - m.data_container.grab(new Element("div.actions").adopt(new Element("a.add.icon2", { - title: "Add movie with your default quality", - "data-add": movie.imdb, - events: { - click: m.showOptions.bind(m) - } - }), $(new MA.IMDB(m)), $(new MA.Trailer(m, { - height: 150 - })))); - m.data_container.removeEvents("click"); - var plot = false; - if (m.info.plot && m.info.plot.length > 0) plot = m.info.plot; - m.info_container.adopt(m.rating = m.info.rating && m.info.rating.imdb && m.info.rating.imdb.length == 2 && parseFloat(m.info.rating.imdb[0]) > 0 ? new Element("span.rating", { - text: parseFloat(m.info.rating.imdb[0]), - title: parseInt(m.info.rating.imdb[1]) + " votes" - }) : null, m.genre = m.info.genres && m.info.genres.length > 0 ? new Element("span.genres", { - text: m.info.genres.slice(0, 3).join(", ") - }) : null, m.plot = plot ? new Element("span.plot", { - text: plot, - events: { - click: function() { - this.toggleClass("full"); - } - } - }) : null); - $(m).inject(c); + var chart_list = new MovieList({ + navigation: false, + identifier: chart.name.toLowerCase().replace(/[^a-z0-9]+/g, "_"), + title: chart.name, + description: 'See source', + actions: [ MA.Add, MA.SuggestIgnore, MA.SuggestSeen, MA.IMDB, MA.Trailer ], + load_more: false, + view: "thumb", + force_view: true, + api_call: null }); - c.inject(self.el); + chart_list.store(chart.list); + chart_list.addMovies(chart.list, chart.list.length); + chart_list.checkIfEmpty(); + chart_list.fireEvent("loaded"); + $(chart_list).inject(self.el); }); } self.fireEvent("loaded"); @@ -2416,9 +2387,11 @@ var Charts = new Class({ var self = this; self.el.show(); if (!self.shown_once) { - self.api_request = Api.request("charts.view", { - onComplete: self.fill.bind(self) - }); + setTimeout(function() { + self.api_request = Api.request("charts.view", { + onComplete: self.fill.bind(self) + }); + }, 100); self.shown_once = true; } }, @@ -2476,123 +2449,6 @@ var TraktAutomation = new Class({ new TraktAutomation(); -var SuggestList = new Class({ - Implements: [ Options, Events ], - shown_once: false, - initialize: function(options) { - var self = this; - self.setOptions(options); - self.create(); - }, - create: function() { - var self = this; - self.el = new Element("div.suggestions", { - events: { - "click:relay(a.delete)": function(e, el) { - e.stop(); - $(el).getParent(".media_result").destroy(); - Api.request("suggestion.ignore", { - data: { - imdb: el.get("data-ignore") - }, - onComplete: self.fill.bind(self) - }); - }, - "click:relay(a.eye-open)": function(e, el) { - e.stop(); - $(el).getParent(".media_result").destroy(); - Api.request("suggestion.ignore", { - data: { - imdb: el.get("data-seen"), - mark_seen: 1 - }, - onComplete: self.fill.bind(self) - }); - } - } - }); - var cookie_menu_select = Cookie.read("suggestions_charts_menu_selected") || "suggestions"; - if (cookie_menu_select === "suggestions") self.show(); else self.hide(); - self.fireEvent.delay(0, self, "created"); - }, - fill: function(json) { - var self = this; - if (!json || json.count === 0) { - self.el.hide(); - } else { - Object.each(json.suggestions, function(movie) { - var m = new BlockSearchMovieItem(movie, { - onAdded: function() { - self.afterAdded(m, movie); - } - }); - m.data_container.grab(new Element("div.actions").adopt(new Element("a.add.icon2", { - title: "Add movie with your default quality", - "data-add": movie.imdb, - events: { - click: m.showOptions.bind(m) - } - }), $(new MA.IMDB(m)), $(new MA.Trailer(m, { - height: 150 - })), new Element("a.delete.icon2", { - title: "Don't suggest this movie again", - "data-ignore": movie.imdb - }), new Element("a.eye-open.icon2", { - title: "Seen it, like it, don't add", - "data-seen": movie.imdb - }))); - m.data_container.removeEvents("click"); - var plot = false; - if (m.info.plot && m.info.plot.length > 0) plot = m.info.plot; - m.info_container.adopt(m.rating = m.info.rating && m.info.rating.imdb && m.info.rating.imdb.length == 2 && parseFloat(m.info.rating.imdb[0]) > 0 ? new Element("span.rating", { - text: parseFloat(m.info.rating.imdb[0]), - title: parseInt(m.info.rating.imdb[1]) + " votes" - }) : null, m.genre = m.info.genres && m.info.genres.length > 0 ? new Element("span.genres", { - text: m.info.genres.slice(0, 3).join(", ") - }) : null, m.plot = plot ? new Element("span.plot", { - text: plot, - events: { - click: function() { - this.toggleClass("full"); - } - } - }) : null); - $(m).inject(self.el); - }); - } - self.fireEvent("loaded"); - }, - afterAdded: function(m, movie) { - var self = this; - setTimeout(function() { - $(m).destroy(); - Api.request("suggestion.ignore", { - data: { - imdb: movie.imdb, - remove_only: true - }, - onComplete: self.fill.bind(self) - }); - }, 3e3); - }, - show: function() { - var self = this; - self.el.show(); - if (!self.shown_once) { - self.api_request = Api.request("suggestion.view", { - onComplete: self.fill.bind(self) - }); - self.shown_once = true; - } - }, - hide: function() { - this.el.hide(); - }, - toElement: function() { - return this.el; - } -}); - var NotificationBase = new Class({ Extends: BlockBase, Implements: [ Options, Events ], diff --git a/couchpotato/static/scripts/page/home.js b/couchpotato/static/scripts/page/home.js index 442a691..59bbecf 100644 --- a/couchpotato/static/scripts/page/home.js +++ b/couchpotato/static/scripts/page/home.js @@ -25,7 +25,7 @@ Page.Home = new Class({ self.createAvailable.bind(self), self.createSoon.bind(self), self.createSuggestions.bind(self), - self.createCharts.bind(self), + //self.createCharts.bind(self), self.createLate.bind(self) ); @@ -113,7 +113,6 @@ Page.Home = new Class({ createSuggestions: function(){ var self = this; - // Coming Soon self.suggestions_list = new MovieList({ 'navigation': false, 'identifier': 'suggest', diff --git a/couchpotato/static/style/combined.min.css b/couchpotato/static/style/combined.min.css index c4db6b2..dde5262 100644 --- a/couchpotato/static/style/combined.min.css +++ b/couchpotato/static/style/combined.min.css @@ -291,6 +291,7 @@ @media all and (max-width:600px){.charts .chart{width:100%} } .charts .chart .media_result .data{left:150px;background:#4e5969;border:none} +#category_ordering li:last-child,#profile_ordering li:last-child,.api_docs .api .params tr:last-child td,.api_docs .api .params tr:last-child th{border:0} .charts .chart .media_result .data .info{top:10px;left:15px;right:15px;bottom:10px;overflow:hidden} .charts .chart .media_result .data .info h2{white-space:normal;max-height:120px;font-size:18px;line-height:18px} .charts .chart .media_result .data .info .genres,.charts .chart .media_result .data .info .rating,.charts .chart .media_result .data .info .year{position:static;display:block;padding:0;opacity:.6} @@ -324,35 +325,6 @@ .toggle_menu h2{height:40px} @media all and (max-width:480px){.toggle_menu h2{font-size:16px;text-align:center;height:30px} } -.suggestions{clear:both;padding-top:10px;margin-bottom:30px} -.suggestions>h2{height:40px} -.suggestions .media_result{display:inline-block;width:33.333%;height:150px} -@media all and (max-width:960px){.suggestions .media_result{width:50%} -} -@media all and (max-width:600px){.suggestions .media_result{width:100%} -} -.suggestions .media_result .data{left:100px;background:#4e5969;border:none} -#category_ordering li:last-child,#profile_ordering li:last-child,.api_docs .api .params tr:last-child td,.api_docs .api .params tr:last-child th{border:0} -.suggestions .media_result .data .info{top:10px;left:15px;right:15px;bottom:10px;overflow:hidden} -.suggestions .media_result .data .info h2{white-space:normal;max-height:120px;font-size:18px;line-height:18px} -.suggestions .media_result .data .info .genres,.suggestions .media_result .data .info .rating,.suggestions .media_result .data .info .year{position:static;display:block;padding:0;opacity:.6} -.suggestions .media_result .data .info .year{margin:10px 0 0} -.suggestions .media_result .data .info .rating{font-size:20px;float:right;margin-top:-20px} -.suggestions .media_result .data .info .rating:before{content:"\e031";font-family:Elusive-Icons;font-size:14px;margin:0 5px 0 0;vertical-align:bottom} -.suggestions .media_result .data .info .genres{font-size:11px;font-style:italic;text-align:right} -.suggestions .media_result .data .info .plot{display:block;font-size:11px;overflow:hidden;text-align:justify;height:100%;z-index:2;top:64px;position:absolute;background:#4e5969;cursor:pointer;transition:all .4s ease-in-out;padding:0 3px 10px 0} -.suggestions .media_result .data:before{content:'';display:block;height:10px;right:0;left:0;bottom:10px;position:absolute;background:linear-gradient(0deg,#4e5969 0,rgba(78,89,105,0) 100%);z-index:3;pointer-events:none} -.suggestions .media_result .data .info .plot.full{top:0;overflow:auto} -.suggestions .media_result .data{cursor:default} -.suggestions .media_result .options{left:100px} -.suggestions .media_result .options select[name=category],.suggestions .media_result .options select[name=profile],.suggestions .media_result .options select[name=title]{width:100%} -.suggestions .media_result .button{position:absolute;margin:2px 0 0;right:15px;bottom:15px} -.suggestions .media_result .thumbnail{width:100px} -.suggestions .media_result .actions{position:absolute;top:10px;right:10px;display:none;width:140px} -.suggestions .media_result:hover .actions{display:block} -.suggestions .media_result:hover h2 .title{opacity:0} -.suggestions .media_result .data.open .actions{display:none} -.suggestions .media_result .actions a{margin-left:10px;vertical-align:middle} .add_new_category{padding:20px;display:block;text-align:center;font-size:20px} .category{margin-bottom:20px;position:relative} .category>.delete{position:absolute;padding:16px;right:0;cursor:pointer;opacity:.6;color:#fd5353}