@@ -156,7 +156,7 @@ import { IgxGridHeaderRowComponent } from './headers/grid-header-row.component';
156
156
import { IgxGridGroupByAreaComponent } from './grouping/grid-group-by-area.component' ;
157
157
158
158
let FAKE_ROW_ID = - 1 ;
159
-
159
+ const DEFAULT_ITEMS_PER_PAGE = 15 ;
160
160
const MINIMUM_COLUMN_WIDTH = 136 ;
161
161
const FILTER_ROW_HEIGHT = 50 ;
162
162
// By default row editing overlay outlet is inside grid body so that overlay is hidden below grid header when scrolling.
@@ -1477,7 +1477,7 @@ export abstract class IgxGridBaseDirective extends DisplayDensityBase implements
1477
1477
@DeprecateProperty ( '`perPage` is deprecated. Use `perPage` property from `paginator` component instead.' )
1478
1478
@Input ( )
1479
1479
public get perPage ( ) : number {
1480
- return this . paginator ?. perPage || 15 ;
1480
+ return this . paginator ?. perPage || DEFAULT_ITEMS_PER_PAGE ;
1481
1481
}
1482
1482
1483
1483
public set perPage ( val : number ) {
@@ -2739,7 +2739,7 @@ export abstract class IgxGridBaseDirective extends DisplayDensityBase implements
2739
2739
/**
2740
2740
* @hidden
2741
2741
*/
2742
- protected _perPage = 15 ;
2742
+ protected _perPage = DEFAULT_ITEMS_PER_PAGE ;
2743
2743
/**
2744
2744
* @hidden
2745
2745
*/
@@ -3627,7 +3627,7 @@ export abstract class IgxGridBaseDirective extends DisplayDensityBase implements
3627
3627
// Keep the stream open for future subscribers
3628
3628
this . rendered$ . pipe ( takeUntil ( this . destroy$ ) ) . subscribe ( ( ) => {
3629
3629
if ( this . paginator ) {
3630
- this . paginator . perPage = this . _perPage !== 15 ? this . _perPage : this . paginator . perPage ;
3630
+ this . paginator . perPage = this . _perPage !== DEFAULT_ITEMS_PER_PAGE ? this . _perPage : this . paginator . perPage ;
3631
3631
this . paginator . totalRecords = this . totalRecords ;
3632
3632
this . paginator . overlaySettings = { outlet : this . outlet } ;
3633
3633
}
0 commit comments