Skip to content
This repository has been archived by the owner on Dec 2, 2022. It is now read-only.

Commit

Permalink
Fix: #777 - Re: Scroll in the drop down menus #773 - Custom menu sub-…
Browse files Browse the repository at this point in the history
…menus no longer accessible.
  • Loading branch information
gjb2048 committed Oct 16, 2016
1 parent 016ca09 commit baa9b07
Show file tree
Hide file tree
Showing 11 changed files with 41 additions and 19 deletions.
1 change: 1 addition & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
New in 3.0.1.12
===============
- FIX: Issue #777: Re: Scroll in the drop down menus #773 - Custom menu sub-menus no longer accessible.
- FIX: Tidy up Bootstrap override LESS.

New in 3.0.1.11
Expand Down
12 changes: 9 additions & 3 deletions classes/output/core_renderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -502,13 +502,19 @@ protected function render_custom_menu_item(custom_menu_item $menunode, $level =
$content .= $this->getfontawesomemarkup('caret-right');
}
$content .= '</a>';
$content .= '<div class="dropdown-menu">';
$content .= '<ul>';
if ($level == 1) {
$content .= '<div class="dropdown-menu">';
$content .= '<ul>';
} else {
$content .= '<ul class="dropdown-menu">';
}
foreach ($menunode->get_children() as $menunode) {
$content .= $this->render_custom_menu_item($menunode, 0);
}
$content .= '</ul>';
$content .= '</div>';
if ($level == 1) {
$content .= '</div>';
}
} else {
// Also, if the node's text matches '####', add a class so we can treat it as a divider.
$content = '';
Expand Down
12 changes: 8 additions & 4 deletions less/essential-alternative.less
Original file line number Diff line number Diff line change
Expand Up @@ -299,8 +299,10 @@
.dropdown-toggle:after {
border-left-color: inherit;
}
&:focus, &:hover .dropdown-toggle:after {
border-left-color: ~"[[setting:alternativethemenavcolor@{index}]]";
&:focus, &:hover {
.dropdown-toggle:after {
border-left-color: ~"[[setting:alternativethemenavcolor@{index}]]";
}
}
}
}
Expand Down Expand Up @@ -1127,8 +1129,10 @@
border-left-color: transparent;
border-top-color: ~"[[setting:alternativethemeiconcolor@{index}]]";
}
&:hover .dropdown-toggle:after {
border-top-color: ~"[[setting:alternativethemenavcolor@{index}]]";
&:focus, &:hover {
.dropdown-toggle:after {
border-top-color: ~"[[setting:alternativethemenavcolor@{index}]]";
}
}
}
.dropdown-submenu, .dropdown-submenu:hover {
Expand Down
6 changes: 5 additions & 1 deletion less/essential/navigation.less
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ div.dropdown-menu > ul {
li a {
display: block;
}
#custom_menu & {
max-height: none;
overflow-y: visible;
}
}

.navbar {
Expand Down Expand Up @@ -119,7 +123,7 @@ div.dropdown-menu > ul {
}
}

.dropdown-menu {
.dropdown > .dropdown-menu {
margin: 0;
}

Expand Down
12 changes: 8 additions & 4 deletions less/essential/settings/navigation.less
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,10 @@
.dropdown-toggle:after {
border-left-color: inherit;
}
&:hover .dropdown-toggle:after {
border-left-color: ~"[[setting:themenavcolor]]";
&:focus, &:hover {
.dropdown-toggle:after {
border-left-color: ~"[[setting:themenavcolor]]";
}
}
}
}
Expand Down Expand Up @@ -162,8 +164,10 @@
border-left-color: transparent;
border-top-color: ~"[[setting:themeiconcolor]]";
}
&:hover .dropdown-toggle:after {
border-top-color: ~"[[setting:themenavcolor]]";
&:focus, &:hover {
.dropdown-toggle:after {
border-top-color: ~"[[setting:themenavcolor]]";
}
}
}
.dropdown-submenu, .dropdown-submenu:hover {
Expand Down
2 changes: 1 addition & 1 deletion style/essential-alternative.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion style/essential-rtl.css

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions style/essential-rtl_ie9.css

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions style/essential-settings.css
Original file line number Diff line number Diff line change
Expand Up @@ -903,6 +903,7 @@ button.website:focus {
.navbar .navbar-inner .nav .dropdown-menu .dropdown-submenu .dropdown-toggle:after {
border-left-color: inherit;
}
.navbar .navbar-inner .nav .dropdown-menu .dropdown-submenu:focus .dropdown-toggle:after,
.navbar .navbar-inner .nav .dropdown-menu .dropdown-submenu:hover .dropdown-toggle:after {
border-left-color: [[setting:themenavcolor]];
}
Expand Down Expand Up @@ -980,6 +981,8 @@ button.website:focus {
border-left-color: transparent;
border-top-color: [[setting:themeiconcolor]];
}
.navbar .nav-collapse.in .nav .dropdown-submenu:focus .dropdown-toggle:after,
.navbar .nav-collapse.in .nav .dropdown-menu .dropdown-submenu:focus .dropdown-toggle:after,
.navbar .nav-collapse.in .nav .dropdown-submenu:hover .dropdown-toggle:after,
.navbar .nav-collapse.in .nav .dropdown-menu .dropdown-submenu:hover .dropdown-toggle:after {
border-top-color: [[setting:themenavcolor]];
Expand Down
2 changes: 1 addition & 1 deletion style/essential.css

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions style/essential_ie9.css

Large diffs are not rendered by default.

0 comments on commit baa9b07

Please sign in to comment.