FIX: Close navigation dropdown when item selected (#12155)

This `if` statement was backwards, such that it was a no-op. This hasn't
caused a problem because clicking an item triggers a page load, which
destroys and recreates the component.

However, we are soon planning to remove the intermediate loading screen,
which means the component will not be removed/recreated.

https://meta.discourse.org/t/177939/202
This commit is contained in:
David Taylor 2021-02-22 10:41:09 +00:00 committed by GitHub
parent 04c75d417b
commit 863c7919d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -52,7 +52,7 @@ export default Component.extend(FilterModeMixin, {
},
ensureDropClosed() {
if (!this.expanded) {
if (this.expanded) {
this.set("expanded", false);
}
$(window).off("click.navigation-bar");