Skip to content

Commit f77e294

Browse files
committed
Fixed hint for search input
Unbinding arrows shortcuts when closing the popup
1 parent b247c38 commit f77e294

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

front/src/components/Dialogs/SearchDialog.vue

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
v-model="searchText"
99
filled
1010
label="What are you searching for?"
11-
hint="Search for title or description"
11+
hint="Search for title of CTF or task"
1212
autofocus
1313
:loading="loading"
1414
@update:model-value="onSearchChange"
@@ -51,7 +51,7 @@ import { useDialogPluginComponent } from 'quasar';
5151
import ctfnote from 'src/ctfnote';
5252
import { safeSlugify } from 'src/ctfnote/ctfs';
5353
import { Ctf, Task } from 'src/ctfnote/models';
54-
import { defineComponent, onMounted, Ref, ref } from 'vue';
54+
import { defineComponent, onMounted, onUnmounted, Ref, ref } from 'vue';
5555
5656
export default defineComponent({
5757
emits: useDialogPluginComponent.emits,
@@ -73,6 +73,11 @@ export default defineComponent({
7373
const previousShortcut = 'command+p, ctrl+p, up';
7474
const nextShortcut = 'command+n, ctrl+n, down';
7575
76+
onUnmounted(() => {
77+
hotkeys.unbind(previousShortcut);
78+
hotkeys.unbind(nextShortcut);
79+
});
80+
7681
onMounted(() => {
7782
hotkeys.filter = function () {
7883
return true;

0 commit comments

Comments
 (0)