File tree Expand file tree Collapse file tree 5 files changed +18
-14
lines changed Expand file tree Collapse file tree 5 files changed +18
-14
lines changed Original file line number Diff line number Diff line change 77 $foreground : map-get ($theme , foreground );
88
99 .mat-paginator ,
10- .mat-paginator-page-length-select .mat-select-trigger {
10+ .mat-paginator-page-size .mat-select-trigger {
1111 color : mat-color ($foreground , secondary-text );
1212 }
1313
3333 }
3434 }
3535
36- .mat-paginator-page-length-select .mat-select-trigger {
36+ .mat-paginator-page-size .mat-select-trigger {
3737 font : {
3838 family : mat-font-family ($config );
3939 size : mat-font-size ($config , caption );
Original file line number Diff line number Diff line change 1- < div class ="mat-paginator-page-length-select ">
2- < div class ="mat-paginator-items-per- page-label ">
1+ < div class ="mat-paginator-page-size ">
2+ < div class ="mat-paginator-page-size -label ">
33 {{_intl.itemsPerPageLabel}}
44 </ div >
55
66 < md-select *ngIf ="_displayedPageSizeOptions.length > 1 "
7+ class ="mat-paginator-page-size-select "
78 [ngModel] ="pageSize "
89 [aria-label] ="_intl.itemsPerPageLabel "
910 (change) ="_changePageSize($event.value) ">
Original file line number Diff line number Diff line change 44
55### Basic use
66Each paginator instance requires:
7- * The current page index
87* The number of items per page
98* The total number of items being paged
109
10+ The current page index defaults to 0, but can be explicitly set via pageIndex.
11+
1112When the user interacts with the paginator, a ` PageEvent ` will be fired that can be used to update
1213any associated data view.
1314
1415### Page size options
1516The paginator displays a dropdown of page sizes for the user to choose from. The options for this
1617dropdown can be set via ` pageSizeOptions `
1718
19+ The current pageSize will always appear in the dropdown, even if it is not included in pageSizeOptions.
20+
1821### Internationalization
1922The labels for the paginator can be customized by providing your own instance of ` MdPaginatorIntl ` .
2023This will allow you to change the following:
Original file line number Diff line number Diff line change @@ -22,17 +22,17 @@ $mat-paginator-button-increment-icon-margin: 16px;
2222 padding : $mat-paginator-padding ;
2323}
2424
25- .mat-paginator-items-per-page-label {
26- margin : $mat-paginator-items-per-page-label-margin ;
27- }
28-
29- .mat-paginator-page-length-select {
25+ .mat-paginator-page-size {
3026 display : flex ;
3127 align-items : center ;
28+ }
3229
33- .mat-select {
34- margin : $mat-paginator-selector-margin ;
35- }
30+ .mat-paginator-page-size-label {
31+ margin : $mat-paginator-items-per-page-label-margin ;
32+ }
33+
34+ .mat-paginator-page-size-select {
35+ margin : $mat-paginator-selector-margin ;
3636
3737 .mat-select-trigger {
3838 min-width : $mat-paginator-selector-trigger-min-width ;
Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ export class MdPaginator implements OnInit {
6363 this . _pageSize = pageSize ;
6464 this . _updateDisplayedPageSizeOptions ( ) ;
6565 }
66- private _pageSize : number ;
66+ private _pageSize : number = 0 ;
6767
6868 /** The set of provided page size options to display to the user. */
6969 @Input ( )
You can’t perform that action at this time.
0 commit comments