1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

update tabs

This commit is contained in:
Luke Pulverenti 2016-07-05 14:11:34 -04:00
parent bea9f41675
commit 6d7465f64d
5 changed files with 68 additions and 121 deletions

View file

@ -40,7 +40,7 @@
html += '</div>';
html += '</div>';
html += '<div class="viewMenuBarTabs hiddenScrollX">';
html += '<div class="viewMenuBarTabs">';
html += '</div>';
var viewMenuBar = document.createElement('div');
@ -710,22 +710,29 @@
if (LibraryMenu.tabType != type) {
require(['paper-tabs'], function () {
var index = 0;
var noInk = browserInfo.animate ? '' : ' noink';
viewMenuBarTabs.innerHTML = '<div class="libraryViewNav hiddenScrollX">' + builder().map(function (t) {
viewMenuBarTabs.innerHTML = '<paper-tabs selected="' + selectedIndex + '" hidescrollbuttons ' + noInk + '>' + builder().map(function (t) {
var tabClass = selectedIndex == index ? 'pageTabButton is-active' : 'pageTabButton';
return '<paper-tab link><a class="clearLink paperTabLink" href="' + t.href + '"><div>' + t.name + '</div></a></paper-tab>';
var tabHtml = '<a class="' + tabClass + '" href="' + t.href + '" data-index="' + index + '">' + t.name + '<div class="pageTabButtonSelectionBar"></div></a>';
index++;
return tabHtml;
}).join('') + '</paper-tabs>';
document.body.classList.add('withTallToolbar');
LibraryMenu.tabType = type;
});
}).join('') + '</div>';
document.body.classList.add('withTallToolbar');
LibraryMenu.tabType = type;
return;
}
viewMenuBarTabs.querySelector('paper-tabs').selected = selectedIndex;
var activeTab = viewMenuBarTabs.querySelector('.is-active');
var newTab = viewMenuBarTabs.querySelector('.pageTabButton[data-index="' + selectedIndex + '"]');
newTab.classList.add('is-active');
if (newTab != activeTab && activeTab) {
activeTab.classList.remove('is-active');
}
LibraryMenu.tabType = type;
},

View file

@ -1922,7 +1922,6 @@ var AppInfo = {};
define("jqmpanel", ['jqmbase', "thirdparty/jquerymobile-1.4.5/jqm.panel", 'css!thirdparty/jquerymobile-1.4.5/jqm.panel.css']);
define("iron-icon-set", ["html!" + bowerPath + "/iron-icon/iron-icon.html", "html!" + bowerPath + "/iron-iconset-svg/iron-iconset-svg.html"]);
define("slideshow", [embyWebComponentsBowerPath + "/slideshow/slideshow"], returnFirstDependency);
define('fetch', [bowerPath + '/fetch/fetch']);
@ -2595,7 +2594,7 @@ var AppInfo = {};
defineRoute({
path: '/librarysettings.html',
dependencies: ['emby-collapsible', 'paper-input', 'paper-checkbox', 'emby-button'],
dependencies: ['emby-collapsible', 'paper-input', 'paper-checkbox', 'emby-button', 'jqmlistview'],
autoFocus: false,
roles: 'admin',
controller: 'scripts/librarysettings'