From 88dbfcf03e4231ebc65c818ef368fd56eb704bfc Mon Sep 17 00:00:00 2001 From: Nym Date: Tue, 14 Mar 2017 11:00:16 -0400 Subject: [PATCH] Update dirPagination.js Scroll to top of view when pagination button clicked to update content in view (inside scope.setCurrent) --- src/directives/pagination/dirPagination.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/directives/pagination/dirPagination.js b/src/directives/pagination/dirPagination.js index a1a7265..15637e0 100644 --- a/src/directives/pagination/dirPagination.js +++ b/src/directives/pagination/dirPagination.js @@ -330,6 +330,8 @@ if (paginationService.isRegistered(paginationId) && isValidPageNumber(num)) { num = parseInt(num, 10); paginationService.setCurrentPage(paginationId, num); + // scroll to top of view after clicking pagination button to load new content into view + window.scrollTo(0,0); } };