Skip to content

Commit

Permalink
hide menu on mobile device
Browse files Browse the repository at this point in the history
  • Loading branch information
hackmod committed Apr 30, 2018
1 parent d987afa commit f5f96e5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions www/app/routes/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,10 @@ export default Ember.Route.extend({
}

return true;
},

toggleMenu: function() {
Ember.$('.navbar-collapse.in').attr("aria-expanded", false).removeClass("in");
}
},

Expand Down
2 changes: 1 addition & 1 deletion www/app/templates/application.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<a class="navbar-brand"><span class="logo-1">{{config.PoolName}}</span> <span class="logo-2">Pool</span></a>
</div>
<div class="collapse navbar-collapse">
<ul class="nav navbar-nav">
<ul class="nav navbar-nav" {{action 'toggleMenu'}}>
{{#active-li currentWhen='index'}}
{{#link-to 'index'}}
<i class="fa fa-home"></i> {{t 'menu.home'}}
Expand Down

1 comment on commit f5f96e5

@mo9a7i
Copy link

@mo9a7i mo9a7i commented on f5f96e5 Jun 22, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what behavior does this fix?

Please sign in to comment.