mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
delete section for top plugins by install count
This commit is contained in:
parent
6ffd74b9dd
commit
c1e09008d6
4 changed files with 12 additions and 67 deletions
|
@ -50,10 +50,8 @@
|
|||
<h3 style="margin:0;">${HeaderActiveDevices}</h3>
|
||||
<i class="md-icon"></i>
|
||||
</a>
|
||||
|
||||
<div class="activeDevices itemsContainer vertical-wrap">
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@ -76,7 +74,6 @@
|
|||
</div>
|
||||
|
||||
<div class="dashboardSection serverActivitySection hide activityContainer">
|
||||
|
||||
<a is="emby-linkbutton" href="serveractivity.html?useractivity=false" class="button-flat sectionTitleTextButton">
|
||||
<h3>${Alerts}</h3>
|
||||
<i class="md-icon"></i>
|
||||
|
@ -84,8 +81,12 @@
|
|||
<div class="paperList serverActivityItems" data-activitylimit="4" data-useractivity="false">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="dashboardSection">
|
||||
<a is="emby-linkbutton" href="dashboardgeneral.html" class="button-flat sectionTitleTextButton">
|
||||
<h3>${HeaderPaths}</h3>
|
||||
<i class="md-icon"></i>
|
||||
</a>
|
||||
<div class="paperList">
|
||||
<div class="listItem listItem-border">
|
||||
<div class="listItemBody two-line">
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
<div id="devicesPage" data-role="page" class="page type-interior devicesPage noSecondaryNavPage">
|
||||
|
||||
<div>
|
||||
<div class="content-primary">
|
||||
|
||||
<div class="verticalSection verticalSection">
|
||||
<div class="sectionTitleContainer sectionTitleContainer-cards flex align-items-center">
|
||||
<h2 class="sectionTitle sectionTitle-cards">${TabDevices}</h2>
|
||||
|
@ -11,9 +9,6 @@
|
|||
</div>
|
||||
|
||||
<div is="emby-itemscontainer" class="devicesList vertical-wrap" data-multiselect="false">
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -189,7 +189,7 @@ define(["dom", "layoutManager", "inputManager", "connectionManager", "events", "
|
|||
html += globalize.translate("HeaderAdmin");
|
||||
html += "</h3>";
|
||||
html += '<a is="emby-linkbutton" class="navMenuOption lnkMediaFolder lnkManageServer" data-itemid="dashboard" href="dashboard.html"><i class="md-icon navMenuOptionIcon">dashboard</i><span class="navMenuOptionText">' + globalize.translate("TabDashboard") + "</span></a>";
|
||||
html += '<a is="emby-linkbutton" class="navMenuOption lnkMediaFolder editorViewMenu" data-itemid="editor" href="edititemmetadata.html"><i class="md-icon navMenuOptionIcon">mode_edit</i><span class="navMenuOptionText">' + globalize.translate("MetadataManager") + "</span></a>";
|
||||
html += '<a is="emby-linkbutton" class="navMenuOption lnkMediaFolder editorViewMenu" data-itemid="editor" href="edititemmetadata.html"><i class="md-icon navMenuOptionIcon">mode_edit</i><span class="navMenuOptionText">' + globalize.translate("Metadata") + "</span></a>";
|
||||
html += "</div>";
|
||||
}
|
||||
|
||||
|
|
|
@ -41,82 +41,31 @@ define(["loading", "libraryMenu", "globalize", "cardStyle", "emby-linkbutton", "
|
|||
if (!options.targetSystem || plugin.targetSystem == options.targetSystem) {
|
||||
return "UserInstalled" == plugin.type;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
availablePlugins = allPlugins.sort(function (a__e, b__r) {
|
||||
var aName = a__e.category;
|
||||
var bName = b__r.category;
|
||||
|
||||
if (aName > bName) {
|
||||
availablePlugins = allPlugins.sort(function (a, b) {
|
||||
if (a.category > b.category) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (bName > aName) {
|
||||
} else if (b.category > a.category) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
aName = a__e.name;
|
||||
bName = b__r.name;
|
||||
|
||||
if (aName > bName) {
|
||||
if (a.name > b.name) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (bName > aName) {
|
||||
} else if (b.name > a.name) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
});
|
||||
|
||||
var i__q;
|
||||
var length;
|
||||
var plugin;
|
||||
var currentCategory;
|
||||
var html = "";
|
||||
|
||||
if (!options.categories) {
|
||||
currentCategory = globalize.translate("HeaderTopPlugins");
|
||||
html += '<div class="verticalSection">';
|
||||
html += '<h2 class="sectionTitle sectionTitle-cards">' + currentCategory + "</h2>";
|
||||
var topPlugins = allPlugins.slice(0).sort(function (a__t, b__y) {
|
||||
if (a__t.installs > b__y.installs) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (b__y.installs > a__t.installs) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
var aName = a__t.name;
|
||||
var bName = b__y.name;
|
||||
|
||||
if (aName > bName) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (bName > aName) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
});
|
||||
html += '<div class="itemsContainer vertical-wrap">';
|
||||
var limit = screen.availWidth >= 1920 ? 15 : 12;
|
||||
|
||||
for (i__q = 0, length = Math.min(topPlugins.length, limit); i__q < length; i__q++) {
|
||||
html += getPluginHtml(topPlugins[i__q], options, installedPlugins);
|
||||
}
|
||||
|
||||
html += "</div>";
|
||||
html += "</div>";
|
||||
}
|
||||
|
||||
var hasOpenTag = false;
|
||||
|
||||
for (currentCategory = null, false === options.showCategory && (html += '<div class="itemsContainer vertical-wrap">', hasOpenTag = true), i__q = 0, length = availablePlugins.length; i__q < length; i__q++) {
|
||||
plugin = availablePlugins[i__q];
|
||||
var category = plugin.categoryDisplayName;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue