Skip to content

Commit

Permalink
Fix behavior when Escape or Enter is pressed; stay in search mode in …
Browse files Browse the repository at this point in the history
…the end.
  • Loading branch information
roncemer committed Oct 2, 2019
1 parent 3cc34e2 commit 4259521
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion dist/vue-bootstrap-ajax-combobox.js
Original file line number Diff line number Diff line change
Expand Up @@ -229,12 +229,18 @@ Vue.component(
this.clearTrigger();
this.doLookupByAltId();
}
this.inSearchMode = true;
}
break;
case 'Escape':
evt.preventDefault();
evt.stopPropagation();
this.enterIdleState();
if (this.inSearchMode) {
this.enterIdleState();
this.inSearchMode = true;
} else {
this.enterIdleState();
}
break;
}
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue-bootstrap-ajax-combobox",
"version": "1.0.10",
"version": "1.0.11",
"description": "AJAX Combobox autocomplete component for Vue.js 2.x and Bootstrap 4.",
"main": "vue-bootstrap-ajax-combobox.js",
"scripts": {
Expand Down

0 comments on commit 4259521

Please sign in to comment.