UX: Disable automatic update of search results on blur/change #1995

As discussed/requested in the issue comments.
This commit is contained in:
Michael Mayer 2022-03-25 08:44:00 +01:00
parent 00ab2c662b
commit 80df455e25
7 changed files with 7 additions and 20 deletions

View File

@ -1,7 +1,7 @@
<template>
<v-form ref="form" lazy-validation
dense autocomplete="off" class="p-photo-toolbar p-album-toolbar" accept-charset="UTF-8"
@submit.prevent="filterChange">
@submit.prevent="updateQuery">
<v-toolbar flat :dense="$vuetify.breakpoint.smAndDown" class="page-toolbar" color="secondary">
<v-toolbar-title :title="album.Title">
{{ album.Title }}
@ -150,7 +150,7 @@ export default {
}
},
dropdownChange() {
this.filterChange();
this.updateQuery();
if (window.innerWidth < 600) {
this.searchExpanded = false;
@ -163,10 +163,9 @@ export default {
},
setView(name) {
this.settings.view = name;
this.filterChange();
this.updateQuery();
},
clearQuery() {
this.filter.q = '';
updateQuery() {
this.filterChange();
},
download() {

View File

@ -13,8 +13,6 @@
prepend-inner-icon="search"
color="secondary-dark"
@input="onChangeQuery"
@change="updateQuery"
@blur="updateQuery"
@keyup.enter.native="updateQuery"
@click:clear="clearQuery"
></v-text-field>
@ -231,7 +229,7 @@ export default {
return this.all.years.concat(options.IndexedYears());
},
dropdownChange() {
this.filterChange();
this.updateQuery();
if (window.innerWidth < 600) {
this.searchExpanded = false;
@ -239,7 +237,7 @@ export default {
},
setView(name) {
this.settings.view = name;
this.filterChange();
this.updateQuery();
},
onChangeQuery(val) {
this.q = String(val);

View File

@ -15,8 +15,6 @@
prepend-inner-icon="search"
color="secondary-dark"
@input="onChangeQuery"
@change="updateQuery"
@blur="updateQuery"
@keyup.enter.native="updateQuery"
@click:clear="clearQuery"
></v-text-field>

View File

@ -15,8 +15,6 @@
autocapitalize="none"
color="secondary-dark"
@input="onChangeQuery"
@change="updateQuery"
@blur="updateQuery"
@keyup.enter.native="updateQuery"
@click:clear="clearQuery"
></v-text-field>

View File

@ -12,8 +12,6 @@
prepend-inner-icon="search"
color="secondary-dark"
@input="onChangeQuery"
@change="updateQuery"
@blur="updateQuery"
@keyup.enter.native="updateQuery"
@click:clear="clearQuery"
></v-text-field>

View File

@ -15,8 +15,6 @@
autocapitalize="none"
color="secondary-dark"
@input="onChangeQuery"
@change="updateQuery"
@blur="updateQuery"
@keyup.enter.native="updateQuery"
@click:clear="clearQuery"
></v-text-field>

View File

@ -5,7 +5,7 @@
<div class="maplibregl-ctrl maplibregl-ctrl-group">
<v-text-field v-model.lazy.trim="filter.q"
solo hide-details clearable flat single-line validate-on-blur
class="pa-0 ma-0 input-search"
class="input-search pa-0 ma-0"
:label="$gettext('Search')"
prepend-inner-icon="search"
browser-autocomplete="off"
@ -13,8 +13,6 @@
autocapitalize="none"
color="secondary-dark"
@click:clear="clearQuery"
@blur="formChange"
@change="formChange"
@keyup.enter.native="formChange"
></v-text-field>
</div>