docs(pagination): update to latest version

Closes #5135
This commit is contained in:
Foxandxss
2015-12-30 15:03:06 +01:00
parent 1f3e55f6fc
commit 2ccaa1977f
+80 -59
View File
@@ -1,74 +1,95 @@
A lightweight pagination directive that is focused on ... providing pagination & will take care of visualising a pagination bar and enable / disable buttons correctly!
### Pagination Settings ###
### uib-pagination settings
Settings can be provided as attributes in the `<uib-pagination>` or globally configured through the `uibPaginationConfig`.
* `boundary-links`
<small class="badge">C</small>
_(Default: `false`)_ -
Whether to display First / Last buttons.
* `ng-change`
:
`ng-change` can be used together with `ng-model` to call a function whenever the page changes.
* `boundary-link-numbers`
<small class="badge">$</small>
<small class="badge">C</small>
_(Default: `false`)_ -
Whether to always display the first and last page numbers. If `max-size` is smaller than the number of pages, then the first and last page numbers are still shown with ellipses in-between as necessary. NOTE: `max-size` refers to the center of the range. This option may add up to 2 more numbers on each side of the displayed range for the end value and what would be an ellipsis but is replaced by a number because it is sequential.
* `ng-model` <i class="glyphicon glyphicon-eye-open"></i>
:
Current page number. First page is 1.
* `direction-links`
<small class="badge">$</small>
<small class="badge">C</small>
_(Default: `true`)_ -
Whether to display Previous / Next buttons.
* `first-text`
<small class="badge">C</small>
_(Default: `First`)_ -
Text for First button.
* `ng-disabled` <i class="glyphicon glyphicon-eye-open"></i>
:
Used to disable the pagination component
* `force-ellipses`
<small class="badge">$</small>
<small class="badge">C</small>
_(Default: `false`)_ -
Also displays ellipses when `rotate` is true and `max-size` is smaller than the number of pages.
* `total-items` <i class="glyphicon glyphicon-eye-open"></i>
:
Total number of items in all pages.
* `items-per-page`
<small class="badge">$</small>
<small class="badge">C</small>
<i class="glyphicon glyphicon-eye-open"></i>
_(Default: `10`)_ -
Maximum number of items per page. A value less than one indicates all items on one page.
* `items-per-page` <i class="glyphicon glyphicon-eye-open"></i>
_(Defaults: 10)_ :
Maximum number of items per page. A value less than one indicates all items on one page.
* `last-text`
<small class="badge">C</small>
_(Default: `Last`)_ -
Text for Last button.
* `max-size`
<small class="badge">$</small>
<i class="glyphicon glyphicon-eye-open"></i>
_(Default: `null`)_ -
Limit number for pagination size.
* `next-text`
<small class="badge">C</small>
_(Default: `Next`)_ -
Text for Next button.
* `max-size` <i class="glyphicon glyphicon-eye-open"></i>
_(Defaults: null)_ :
Limit number for pagination size.
* `ng-change`
<small class="badge">$</small> -
This can be used to call a function whenever the page changes.
* `ng-disabled`
<small class="badge">$</small>
<i class="glyphicon glyphicon-eye-open"></i>
_(Default: `false`)_ -
Used to disable the pagination component.
* `num-pages` <small class="badge">readonly</small>
_(Defaults: angular.noop)_ :
An optional expression assigned the total number of pages to display.
* `ng-model`
<small class="badge">$</small>
<i class="glyphicon glyphicon-eye-open"></i> -
Current page number. First page is 1.
* `rotate`
_(Defaults: true)_ :
Whether to keep current page in the middle of the visible ones.
* `force-ellipses`
_(Defaults: false)_ :
Also displays ellipses when `rotate` is true and `max-size` is smaller than the number of pages.
* `num-pages`
<small class="badge">$</small>
<small class="badge">readonly</small>
_(Default: `angular.noop`)_ -
An optional expression assigned the total number of pages to display.
* `direction-links`
_(Default: true)_ :
Whether to display Previous / Next buttons.
* `previous-text`
<small class="badge">C</small>
_(Default: `Previous`)_ -
Text for Previous button.
* `previous-text`
_(Default: 'Previous')_ :
Text for Previous button.
* `rotate`
<small class="badge">$</small>
<small class="badge">C</small>
_(Default: `true`)_ -
Whether to keep current page in the middle of the visible ones.
* `next-text`
_(Default: 'Next')_ :
Text for Next button.
* `boundary-links`
_(Default: false)_ :
Whether to display First / Last buttons.
* `first-text`
_(Default: 'First')_ :
Text for First button.
* `last-text`
_(Default: 'Last')_ :
Text for Last button.
* `boundary-link-numbers`
_(Default: false)_ :
Whether to always display the first and last page numbers. If `max-size` is smaller than the number of pages, then the first and last page numbers are still shown with ellipses in-between as necessary. NOTE: `max-size` refers to the center of the range. This option may add up to 2 more numbers on each side of the displayed range for the end value and what would be an ellipsis but is replaced by a number because it is sequential.
* `template-url`
_(Default: 'uib/template/pagination/pagination.html')_ :
* `template-url`
_(Default: `uib/template/pagination/pagination.html`)_ -
Override the template for the component with a custom provided template
* `total-items`
<small class="badge">$</small>
<i class="glyphicon glyphicon-eye-open"></i> -
Total number of items in all pages.