Skip to content
This repository was archived by the owner on May 29, 2019. It is now read-only.

Commit 3b5b3bd

Browse files
committed
chore(pagination): preventDefault on click
- Add `event.preventDefault` call in order to avoid potential router bugs Closes #4096
1 parent 328146d commit 3b5b3bd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/pagination/pagination.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,10 @@ angular.module('ui.bootstrap.pagination', [])
4646
};
4747

4848
$scope.selectPage = function(page, evt) {
49+
if (evt) {
50+
evt.preventDefault();
51+
}
52+
4953
var clickAllowed = !$scope.ngDisabled || !evt;
5054
if (clickAllowed && $scope.page !== page && page > 0 && page <= $scope.totalPages) {
5155
if (evt && evt.target) {

0 commit comments

Comments
 (0)