diff --git a/src/public/app/widgets/note_list.js b/src/public/app/widgets/note_list.js index f3ac4b4ba..e61170a33 100644 --- a/src/public/app/widgets/note_list.js +++ b/src/public/app/widgets/note_list.js @@ -67,6 +67,13 @@ export default class NoteListWidget extends TabAwareWidget { await noteListRenderer.renderList(); } + async refresh() { + this.$content.empty(); + this.shownNoteId = null; + + await super.refresh(); + } + /** * We have this event so that we evaluate intersection only after note detail is loaded. * If it's evaluated before note detail then it's clearly intersected (visible) although after note detail load diff --git a/src/public/app/widgets/quick_search.js b/src/public/app/widgets/quick_search.js index 7d018994c..8860c3ba5 100644 --- a/src/public/app/widgets/quick_search.js +++ b/src/public/app/widgets/quick_search.js @@ -58,6 +58,10 @@ export default class QuickSearchWidget extends BasicWidget { this.$dropdownMenu.find('.dropdown-item:first').focus(); }); + utils.bindElShortcut(this.$searchString, 'esc', () => { + this.$dropdownToggle.dropdown('hide'); + }); + return this.$widget; }