Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Page numbers don't scroll past first 10 in some conditions #518

Open
jontsnz opened this issue Dec 13, 2016 · 0 comments
Open

Page numbers don't scroll past first 10 in some conditions #518

jontsnz opened this issue Dec 13, 2016 · 0 comments

Comments

@jontsnz
Copy link

jontsnz commented Dec 13, 2016

The dropdown containing the page numbers usually fetches another 10 entries once you scroll down to the last item in the dropdown. Under Chrome 55.0.2883.75 (64-bit) on the external screen of a Macbook Pro Retina it does not fetch the next 10 when you scroll to the 10th item. However, if you click ">" from the 10th to go to the 11th, then it will fetch the next 10, and continues to fetch 10 from that point onwards.

md-datatable page numbers

Debugging reveals that the content.prop('scrollTop') is returning a decimal rather than an integer. This appears to be caused by a recent change to Chrome to support hi-res devices.

The solution is to round the property when fetching it: Math.round(content.prop('scrollTop'))

jontsnz added a commit to jontsnz/md-data-table that referenced this issue Dec 13, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant