Scroll to top with page navigation
Torey Heinz
committed Jul 12, 2025
commit cde3f300d424908ffd9863e906aecaa3346525dc
Showing 1
changed file with
2 additions
and 0 deletions
src/views/Assessment.vue
+2
-0
| @@ | @@ -173,12 +173,14 @@ const getQuestionNumber = (index) => { |
| const previousPage = () => { | |
| if (currentPage.value > 0) { | |
| currentPage.value-- | |
| + | window.scrollTo({ top: 0, behavior: 'smooth' }) |
| } | |
| } | |
| const nextPage = () => { | |
| if (!isLastPage.value) { | |
| currentPage.value++ | |
| + | window.scrollTo({ top: 0, behavior: 'smooth' }) |
| } | |
| } | |