Skip to content

Commit 30641dc

Browse files
authored
fix(ui): Prevent zoom when double-tapping price-based charging buttons in Koala theme (#3046)
Users will often quickly press the buttons to increase/decrease the price-based charging amount multiple times. On touch-based devices, this will zoom in on the button, which is very annoying. By setting `touch-action: manipulation` on the relevant buttons, this is prevented.
1 parent ab87e6d commit 30641dc

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

packages/modules/web_themes/koala/source/src/components/ChargePointEcoSettings.vue

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676
<div class="col-auto">
7777
<q-btn
7878
v-if="maxPrice.value"
79-
class="col-auto q-mr-xs"
79+
class="col-auto q-mr-xs disable-zoom"
8080
label="-1,00"
8181
color="grey"
8282
size="sm"
@@ -85,7 +85,7 @@
8585
/>
8686
<q-btn
8787
v-if="maxPrice.value"
88-
class="col-auto q-mr-xs"
88+
class="col-auto q-mr-xs disable-zoom"
8989
label="-0,10"
9090
color="grey"
9191
size="sm"
@@ -94,7 +94,7 @@
9494
/>
9595
<q-btn
9696
v-if="maxPrice.value"
97-
class="col-auto"
97+
class="col-auto disable-zoom"
9898
label="-0,01"
9999
color="grey"
100100
size="sm"
@@ -113,7 +113,7 @@
113113
<div class="col-auto">
114114
<q-btn
115115
v-if="maxPrice.value"
116-
class="col-auto q-mr-xs"
116+
class="col-auto q-mr-xs disable-zoom"
117117
label="+0,01"
118118
color="grey"
119119
size="sm"
@@ -122,7 +122,7 @@
122122
/>
123123
<q-btn
124124
v-if="maxPrice.value"
125-
class="col-auto q-mr-xs"
125+
class="col-auto q-mr-xs disable-zoom"
126126
label="+0,10"
127127
color="grey"
128128
size="sm"
@@ -131,7 +131,7 @@
131131
/>
132132
<q-btn
133133
v-if="maxPrice.value"
134-
class="col-auto"
134+
class="col-auto disable-zoom"
135135
label="+1,00"
136136
color="grey"
137137
size="sm"
@@ -217,3 +217,9 @@ const maxPrice = computed(() =>
217217
mqttStore.chargePointConnectedVehicleEcoChargeMaxPrice(props.chargePointId),
218218
);
219219
</script>
220+
221+
<style scoped>
222+
.disable-zoom {
223+
touch-action: manipulation;
224+
}
225+
</style>

0 commit comments

Comments
 (0)