mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-09 15:35:47 +01:00
added link to 'install plugins' page in acp installed plugins menu dropdown
also fixed annoying white background when a menu item other than the one active is focused upon
This commit is contained in:
@@ -105,6 +105,7 @@
|
|||||||
|
|
||||||
.nav-list {
|
.nav-list {
|
||||||
background: #232323;
|
background: #232323;
|
||||||
|
|
||||||
li {
|
li {
|
||||||
i {
|
i {
|
||||||
margin-right: 6px;
|
margin-right: 6px;
|
||||||
@@ -134,6 +135,10 @@
|
|||||||
padding-left: 11px;
|
padding-left: 11px;
|
||||||
outline: 0;
|
outline: 0;
|
||||||
|
|
||||||
|
&:focus {
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
span {
|
span {
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
margin-right: -8px;
|
margin-right: -8px;
|
||||||
|
|||||||
@@ -117,16 +117,21 @@
|
|||||||
function selectMenuItem(url) {
|
function selectMenuItem(url) {
|
||||||
url = url.replace(/\/\d+$/, '');
|
url = url.replace(/\/\d+$/, '');
|
||||||
|
|
||||||
|
// If index is requested, load the dashboard
|
||||||
|
if (url === 'admin') {
|
||||||
|
url = 'admin/general/dashboard';
|
||||||
|
}
|
||||||
|
|
||||||
$('#main-menu .nav-list > li').removeClass('active').each(function() {
|
$('#main-menu .nav-list > li').removeClass('active').each(function() {
|
||||||
var menu = $(this),
|
var menu = $(this),
|
||||||
category = menu.parents('.sidebar-nav'),
|
category = menu.parents('.sidebar-nav'),
|
||||||
href = menu.children('a').attr('href');
|
href = menu.children('a').attr('href'),
|
||||||
|
isLink = menu.attr('data-link') === '1';
|
||||||
|
|
||||||
if (href && href.slice(1).indexOf(url) !== -1) {
|
if (!isLink && href && href.slice(1) === url) {
|
||||||
category.addClass('open');
|
category.addClass('open');
|
||||||
menu.addClass('active');
|
menu.addClass('active');
|
||||||
modifyBreadcrumb(category.find('.nav-header').text(), menu.text());
|
modifyBreadcrumb(category.find('.nav-header').text(), menu.text());
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -82,6 +82,9 @@
|
|||||||
<a href="{relative_path}/admin{plugins.route}">{plugins.name}</a>
|
<a href="{relative_path}/admin{plugins.route}">{plugins.name}</a>
|
||||||
</li>
|
</li>
|
||||||
<!-- END plugins -->
|
<!-- END plugins -->
|
||||||
|
<li data-link="1">
|
||||||
|
<a href="{relative_path}/admin/extend/plugins"><i class="fa fa-plus"></i> Install Plugins</a>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<!-- ENDIF plugins.length -->
|
<!-- ENDIF plugins.length -->
|
||||||
|
|||||||
Reference in New Issue
Block a user