mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-20 22:42:53 -05:00
parent
a0015d65a7
commit
49eea7f6e2
1 changed files with 2 additions and 2 deletions
|
@ -8,14 +8,14 @@ var ApplicationView = Ember.View.extend({
|
|||
setupGlobalMobileNav: function () {
|
||||
// #### Navigating within the sidebar closes it.
|
||||
var self = this;
|
||||
$('body').on('click', '.js-nav-item', function () {
|
||||
$('body').on('click tap', '.js-nav-item', function () {
|
||||
if (mobileQuery.matches) {
|
||||
self.set('controller.showGlobalMobileNav', false);
|
||||
}
|
||||
});
|
||||
|
||||
// #### Close the nav if mobile and clicking outside of the nav or not the burger toggle
|
||||
$('.js-nav-cover').on('click', function () {
|
||||
$('.js-nav-cover').on('click tap', function () {
|
||||
var isOpen = self.get('controller.showGlobalMobileNav');
|
||||
if (isOpen) {
|
||||
self.set('controller.showGlobalMobileNav', false);
|
||||
|
|
Loading…
Add table
Reference in a new issue