diff --git a/dashboard-ui/components/dockedtabs/dockedtabs.css b/dashboard-ui/components/dockedtabs/dockedtabs.css index 6999a99c1e..97102427f9 100644 --- a/dashboard-ui/components/dockedtabs/dockedtabs.css +++ b/dashboard-ui/components/dockedtabs/dockedtabs.css @@ -6,7 +6,6 @@ .dockedtabs-tab-button { flex-grow: 1; - display: flex !important; align-items: center; justify-content: center; text-transform: none !important; @@ -18,6 +17,14 @@ border-width: 0 !important; } + .dockedtabs-tab-button:not(.hide) { + display: flex !important; + } + +.dockedtabs-tab-button-noflex:not(.hide) { + display: block !important; +} + .dockedtabs-tab-button, .dockedtabs-tab-button-foreground { font-weight: normal !important; } @@ -41,4 +48,4 @@ .dockedtab-midsize { display: none !important; } -} \ No newline at end of file +} diff --git a/dashboard-ui/components/dockedtabs/dockedtabs.js b/dashboard-ui/components/dockedtabs/dockedtabs.js index 995004a8db..16d32beac8 100644 --- a/dashboard-ui/components/dockedtabs/dockedtabs.js +++ b/dashboard-ui/components/dockedtabs/dockedtabs.js @@ -1,4 +1,4 @@ -define(['apphost', 'connectionManager', 'events', 'globalize', 'css!./dockedtabs', 'emby-tabs'], function (appHost, connectionManager, events, globalize) { +define(['apphost', 'connectionManager', 'events', 'globalize', 'browser', 'css!./dockedtabs', 'emby-tabs'], function (appHost, connectionManager, events, globalize, browser) { var currentUser = {}; var currentUserViews = []; @@ -47,7 +47,9 @@ function showMenu(menuItems, button) { - require(['webActionSheet'], function (actionSheet) { + var actionSheetType = browser.safari ? 'actionsheet' : 'webActionSheet'; + + require([actionSheetType], function (actionSheet) { actionSheet.show({ @@ -159,6 +161,20 @@ } } + function addNoFlexClass(buttons) { + + setTimeout(function() { + for (var i = 0, length = buttons.length; i < length; i++) { + + var button = buttons[i]; + + if (button.classList.contains('emby-button-noflex')) { + button.classList.add('dockedtabs-tab-button-noflex'); + } + } + }, 300); + } + function render(options) { var elem = document.createElement('div'); @@ -209,8 +225,11 @@ var buttons = elem.querySelectorAll('.emby-tab-button'); for (var i = 0, length = buttons.length; i < length; i++) { - buttons[i].addEventListener('click', onTabClick); + + var button = buttons[i]; + button.addEventListener('click', onTabClick); } + addNoFlexClass(buttons); options.appFooter.add(elem); diff --git a/dashboard-ui/dashboard/librarydisplay.js b/dashboard-ui/dashboard/librarydisplay.js index 29b2fe1d7c..131d4f7df7 100644 --- a/dashboard-ui/dashboard/librarydisplay.js +++ b/dashboard-ui/dashboard/librarydisplay.js @@ -36,6 +36,7 @@ config.EnableGroupingIntoCollections = form.querySelector('.chkGroupMoviesIntoCollections').checked; config.DisplaySpecialsWithinSeasons = form.querySelector('.chkDisplaySpecialsWithinSeasons').checked; config.DisplayCollectionsView = form.querySelector('.chkDisplayCollectionView').checked; + config.EnableChannelView = !form.querySelector('.chkDisplayChannelsInline').checked; ApiClient.updateServerConfiguration(config).then(Dashboard.processServerConfigurationUpdateResult); }); @@ -50,6 +51,7 @@ view.querySelector('.chkGroupMoviesIntoCollections').checked = config.EnableGroupingIntoCollections; view.querySelector('.chkDisplaySpecialsWithinSeasons').checked = config.DisplaySpecialsWithinSeasons; view.querySelector('.chkDisplayCollectionView').checked = config.DisplayCollectionsView; + view.querySelector('.chkDisplayChannelsInline').checked = !(config.EnableChannelView || false); }); } diff --git a/dashboard-ui/librarydisplay.html b/dashboard-ui/librarydisplay.html index 72676b3e73..23979d5f9d 100644 --- a/dashboard-ui/librarydisplay.html +++ b/dashboard-ui/librarydisplay.html @@ -33,6 +33,14 @@
+ +