Closed
Description
Is your feature request related to a problem? Please describe.
Currently, the igx-paginator
can be used as paginator for the igx-grid
, but this comes with no integration. As a developer, I should be able to put the igx-paginator
inside the igx-grid
, and this should be enough for the paging to work (meaning the paginator and the grid are synced).
All paging properties related properties exposed by the grid should be deprecated, or made private, as they are duplicates of the same paginator properties.
If deprecated or hidden, think of how to resolve the
If any of these properties/inputs/outputs/methods should be used, the developer should use it through the igx-paginator
.
Describe the solution you'd like
<igx-grid #grid1 [data]="data | async">
<igx-paginator #paginator
[totalRecords]="totalCount"
[(page)]="page"
[(perPage)]="perPage"
[selectLabel]="'Records per page:'"
[selectOptions]="selectOptions"
[displayDensity]="grid1.displayDensity"
(pageChange)="paginate($event)"
(perPageChange)="perPageChange($event)">
</igx-paginator>
</igx-grid>
Additional issues
- Verify setting the page to a value different from 0 will work
- Currently, the
IgxGridPagingPipe
usespage
andperPage
grid properties values to slice the data correctly. This should be handled, if these gets deprecatd/hidden. - Any other refactoring needed in the
IgxGridPagingPipe
- for example think of removing the grid.pagingState entirely, as it only seems to serve for getting the totalCountr number, and is used by the state directive. - Expose
paging
event