michaelbromley / michaelbromley/angularUtils
dirPagination: Wrong behaviour in showing List Numbers
- Dominant language
- JavaScript
- Stars
- 2k
- Forks
- 842
- PR merge metrics
- No merged PRs in 30d
Description
**Description of issue**:
At the moment I have a Table which goes about 6 Pages. I set max size="5" so It shows me A1|2|3|..|6.
If I click on Page 3 the output is 1|2|A3|...|6
_A stands for Active Selected Page
*_Steps to reproduce**:
**Expected result**:
It shall show ..|2|A3|4|..|6 . So one Page before and after 3 -> 2+4
**Actual result**:
On my Page it shows <<| <|1| 2| A3| ..|6|>|>> .
This is Disturbing because if I selected Page3 the |..| are Disbale and I can only change to Page 4 by clicking on |>|
The same goes for the other Site aroun with 4
<<| <| ..|A4|56|>|>>
**Demo**: (for dirPagination, fork and modify this Plunk: http://plnkr.co/edit/b37IdFFJUokaeSummETX?p=preview)
Any relevant code:
```
Version 0.11.1
```
Its a Simple Pagination without any controller functions for setPages or so.
After Cheking the Example and a bit thinking. Could it be that this is more "Function and not a Bug" ?
Default setting is to show the 2before and 2next so by 6 Pages this is normal behaviour?`
Is there a Possibility to change that because with less pages this is annoying?
To change to show one before/next?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the dir-pagination-controls usage shown in the issue and reproduce the behavior in the linked Plunk demo using version 0.11.1 and max-size="5". Trace how the control calculates visible page numbers and verify the result against the expected output for pages 3 and 4; done means the pagination shows the requested neighboring pages or clearly documents the intended configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angularjs
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100