Custom paging issue

Certified Senior Developer

I have use case in which we show custom pagination  issue is their we have used custom pagination and dropdown on 10,20,50,100

when  I am moving my pagination to last page and with 10 have drop down value it is working fine giving exact deifference that I have between my data in pagination but when I am increasing drop down value to 100

but getting issue their startindex in not moving back.  Like my total data count is 32 

3001-3032 of 3032 is my desired outcome I want like my start index should move back with my dropdown. Can you suggest solution anyone

STEP 1:-

STEP 2 where issue is

  Discussion posts and replies are publicly visible