From 53a24345a423142da6b70fcf0bc3cbe2bb1638d6 Mon Sep 17 00:00:00 2001 From: Sarah Dayan <5370675+sarahdayan@users.noreply.github.com> Date: Fri, 8 Sep 2023 10:59:46 +0200 Subject: [PATCH] fix(vue-instantsearch): prevent click on navigation items when pressing modifiers (#5837) --- .../vue-instantsearch/src/components/Pagination.vue | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/vue-instantsearch/src/components/Pagination.vue b/packages/vue-instantsearch/src/components/Pagination.vue index 6edd32a035..a1982e4cb8 100644 --- a/packages/vue-instantsearch/src/components/Pagination.vue +++ b/packages/vue-instantsearch/src/components/Pagination.vue @@ -30,7 +30,7 @@ :class="suit('link')" aria-label="First" :href="state.createURL(0)" - @click.prevent="refine(0)" + @click.exact.left.prevent="refine(0)" >‹‹ @@ -58,7 +58,7 @@ :class="suit('link')" aria-label="Previous" :href="state.createURL(state.currentRefinement - 1)" - @click.prevent="refine(state.currentRefinement - 1)" + @click.exact.left.prevent="refine(state.currentRefinement - 1)" >‹ @@ -89,7 +89,7 @@ :class="suit('link')" :href="state.createURL(page)" :aria-label="`Page ${page + 1}`" - @click.prevent="refine(page)" + @click.exact.left.prevent="refine(page)" >{{ page + 1 }} @@ -114,7 +114,7 @@ :class="suit('link')" aria-label="Next" :href="state.createURL(state.currentRefinement + 1)" - @click.prevent="refine(state.currentRefinement + 1)" + @click.exact.left.prevent="refine(state.currentRefinement + 1)" >› @@ -142,7 +142,7 @@ :class="suit('link')" aria-label="Last" :href="state.createURL(state.nbPages - 1)" - @click.prevent="refine(state.nbPages - 1)" + @click.exact.left.prevent="refine(state.nbPages - 1)" >››