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

fix(pagination): paging buttons stay focused when page is changed #3486 #3488

Closed
wants to merge 3 commits into from
Closed

fix(pagination): paging buttons stay focused when page is changed #3486 #3488

wants to merge 3 commits into from

Conversation

benthepoet
Copy link
Contributor

This fixes #3486. Just needed to pass in the $event to blur the page button after it has been clicked. Page numbers were sticking upon selection because "track by $index" with ngRepeat keeps the DOM from destroying and recreating elements most of the time. Direction links were also affected along with pager template as well.

…t doesn't stay focused after the page changes.
@karianna
Copy link
Contributor

karianna commented Apr 4, 2015

Hi @benthepoet, could you add some tests for this?

-tested page link
-tested direction links
-tested boundary links
-tested page link when max-size is set
if ( $scope.page !== page && page > 0 && page <= $scope.totalPages) {
if (evt && evt.target) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this ever be called without an event object?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wesleycho
Copy link
Contributor

Thanks for this work - this will make it in the next release.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pagination focusing on page that hasn't been clicked
3 participants