michaelbromley / michaelbromley/angularUtils

optional '...' and last/first page button

Open
#289 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
2k
Forks
842
PR merge metrics
No merged PRs in 30d

Description

I'd like to have the option do disable the first and last page buttons and to then also remove the '...' "pages"

so instead of [<<][<][1][...][4][(5)][6][...][10][>][>>]
I would get [<<][<][2][3][4][(5)][6][7][8][>][>>]

if I had max-size set to 7 (and 5th page selected)

in any case, when having the boundary buttons the [first page][...] .... [...][last page] buttons are unnecessary, the only thing they bring to the table is a display of the max number of pages.

Sure I can rewrite the template to the following to get what I want, but it's not pretty:

```


```

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the pagination template shown in the issue and the code that builds its pages list; compare boundaryLinks, directionLinks, maxSize, and the requested output. Done means optional first and last controls and omission of the ellipsis are supported without a template rewrite, including the max-size 7 example with page 5 selected.

Written by the indexing model from the issue text.

Assessment

Tech stack
angularjs, javascript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.