From 7eef3fa3a9756db8455b6a4c782d4ff5bed00307 Mon Sep 17 00:00:00 2001 From: Natanael Rodriguez Ramos Date: Tue, 23 Apr 2024 13:30:22 +0100 Subject: [PATCH 1/3] fix: Add scroll reset on payment select --- .../ivpn-v3/assets/js/components/SelectPaymentMethod.vue | 8 ++++++++ src/themes/ivpn-v3/assets/js/views/Account/AddFunds.vue | 9 +++++++-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/themes/ivpn-v3/assets/js/components/SelectPaymentMethod.vue b/src/themes/ivpn-v3/assets/js/components/SelectPaymentMethod.vue index f7d99d1cc..c980e40cf 100644 --- a/src/themes/ivpn-v3/assets/js/components/SelectPaymentMethod.vue +++ b/src/themes/ivpn-v3/assets/js/components/SelectPaymentMethod.vue @@ -23,6 +23,7 @@ tag="button" class="btn btn-solid pay-button" :to="{ name: 'add-funds-cc', params: { price: price.id } }" + @click.native="scrollToTop" >
Credit Card @@ -31,6 +32,7 @@ tag="button" class="btn btn-solid pay-button" :to="{ name: 'add-funds-paypal', params: { price: price.id } }" + @click.native="scrollToTop" >
PayPal @@ -39,6 +41,7 @@ tag="button" class="btn btn-solid pay-button" :to="{ name: 'add-funds-bitcoin', params: { price: price.id } }" + @click.native="scrollToTop" >
Bitcoin @@ -47,6 +50,7 @@ tag="button" class="btn btn-solid pay-button" :to="{ name: 'add-funds-monero', params: { price: price.id } }" + @click.native="scrollToTop" >
Monero @@ -55,6 +59,7 @@ tag="button" class="btn btn-solid pay-button" :to="{ name: 'add-funds-cash', params: { price: price.id } }" + @click.native="scrollToTop" >
Cash @@ -113,6 +118,9 @@ export default { toggleMoreOptions() { this.more = !this.more; }, + scrollToTop() { + window.scrollTo(0,0); + }, }, }; diff --git a/src/themes/ivpn-v3/assets/js/views/Account/AddFunds.vue b/src/themes/ivpn-v3/assets/js/views/Account/AddFunds.vue index 523e4b4f3..13f938935 100644 --- a/src/themes/ivpn-v3/assets/js/views/Account/AddFunds.vue +++ b/src/themes/ivpn-v3/assets/js/views/Account/AddFunds.vue @@ -1,10 +1,10 @@