Skip to content

Commit

Permalink
[reposense#1810] Fix filter glob user input (reposense#1827)
Browse files Browse the repository at this point in the history
The input glob previously does not allow user input. Once clicked, the
report will refresh and does not allow user to type in anything in the
input box.

Let's remove v-on:focus to stop listening for focus event and stop
triggering indicateSearchBar(), which causes an update to
selectedFileTypes when the user clicks on the input box, resulting in
the report refreshing.

Let's also update input#search to also trigger indicateSearchBar() on
change event. input#search should have the same behaviour when the user
presses the Enter key as when user clicks button#submit-button.
  • Loading branch information
Punpun1643 authored Aug 31, 2022
1 parent 50751e8 commit 026195f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions frontend/src/views/v-authorship.vue
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,15 @@
type="radio",
value="search",
v-model="filterType",
v-on:change="indicateSearchBar(); updateSearchBarValue();"
v-on:change="indicateSearchBar"
)
.mui-form--inline
input#search(
type="search",
placeholder="Filter by glob",
ref="searchBar",
v-bind:value="searchBarValue",
v-on:focus="indicateSearchBar",
v-on:keyup.enter="updateSearchBarValue"
v-on:keyup.enter="indicateSearchBar(); updateSearchBarValue();"
)
button#submit-button(
type="button",
Expand Down

0 comments on commit 026195f

Please sign in to comment.