Skip to content

feat(pagination): add event for firing when amount of pages decreases (now pageChanged event is fired) #2175

@christianlundberg

Description

@christianlundberg

I am using async data and thus I use pageChanged to send a request and get a new page of data. The problem is that when filtering, the amount of pages can obviously decrease and the current page is set to the last page. Now I can understand the logic behind this, but the problem is that it is set to the last page even if the current page is less than the amount of pages. It should only be set to the last page if the current page is actually greater than the amount of pages.

Another thing is that you should be allowed to decide if it should be set to the first or last page. And when automatically setting the current page because the amount of pages changed, the event fired should probably be a different one. I don't like that pageChanged is fired just because the pages shrunk.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions