UNPKG

29.2 kBJavaScriptView Raw
1import * as i2 from '@angular/common';
2import { CommonModule } from '@angular/common';
3import * as i0 from '@angular/core';
4import { Injectable, Optional, SkipSelf, InjectionToken, EventEmitter, Directive, Input, Output, Component, ChangeDetectionStrategy, ViewEncapsulation, Inject, NgModule } from '@angular/core';
5import { Subject } from 'rxjs';
6import * as i3 from '@angular/material/button';
7import { MatButtonModule } from '@angular/material/button';
8import * as i5 from '@angular/material/select';
9import { MatSelectModule } from '@angular/material/select';
10import * as i7 from '@angular/material/tooltip';
11import { MatTooltipModule } from '@angular/material/tooltip';
12import * as i6 from '@angular/material/core';
13import { mixinDisabled, mixinInitialized } from '@angular/material/core';
14import { coerceNumberProperty, coerceBooleanProperty } from '@angular/cdk/coercion';
15import * as i4 from '@angular/material/form-field';
16
17/**
18 * @license
19 * Copyright Google LLC All Rights Reserved.
20 *
21 * Use of this source code is governed by an MIT-style license that can be
22 * found in the LICENSE file at https://angular.io/license
23 */
24/**
25 * To modify the labels and text displayed, create a new instance of MatPaginatorIntl and
26 * include it in a custom provider
27 */
28class MatPaginatorIntl {
29 constructor() {
30 /**
31 * Stream to emit from when labels are changed. Use this to notify components when the labels have
32 * changed after initialization.
33 */
34 this.changes = new Subject();
35 /** A label for the page size selector. */
36 this.itemsPerPageLabel = 'Items per page:';
37 /** A label for the button that increments the current page. */
38 this.nextPageLabel = 'Next page';
39 /** A label for the button that decrements the current page. */
40 this.previousPageLabel = 'Previous page';
41 /** A label for the button that moves to the first page. */
42 this.firstPageLabel = 'First page';
43 /** A label for the button that moves to the last page. */
44 this.lastPageLabel = 'Last page';
45 /** A label for the range of items within the current page and the length of the whole list. */
46 this.getRangeLabel = (page, pageSize, length) => {
47 if (length == 0 || pageSize == 0) {
48 return `0 of ${length}`;
49 }
50 length = Math.max(length, 0);
51 const startIndex = page * pageSize;
52 // If the start index exceeds the list length, do not try and fix the end index to the end.
53 const endIndex = startIndex < length ? Math.min(startIndex + pageSize, length) : startIndex + pageSize;
54 return `${startIndex + 1}${endIndex} of ${length}`;
55 };
56 }
57}
58MatPaginatorIntl.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorIntl, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
59MatPaginatorIntl.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorIntl, providedIn: 'root' });
60i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorIntl, decorators: [{
61 type: Injectable,
62 args: [{ providedIn: 'root' }]
63 }] });
64/** @docs-private */
65function MAT_PAGINATOR_INTL_PROVIDER_FACTORY(parentIntl) {
66 return parentIntl || new MatPaginatorIntl();
67}
68/** @docs-private */
69const MAT_PAGINATOR_INTL_PROVIDER = {
70 // If there is already an MatPaginatorIntl available, use that. Otherwise, provide a new one.
71 provide: MatPaginatorIntl,
72 deps: [[new Optional(), new SkipSelf(), MatPaginatorIntl]],
73 useFactory: MAT_PAGINATOR_INTL_PROVIDER_FACTORY,
74};
75
76/**
77 * @license
78 * Copyright Google LLC All Rights Reserved.
79 *
80 * Use of this source code is governed by an MIT-style license that can be
81 * found in the LICENSE file at https://angular.io/license
82 */
83/** The default page size if there is no page size and there are no provided page size options. */
84const DEFAULT_PAGE_SIZE = 50;
85/**
86 * Change event object that is emitted when the user selects a
87 * different page size or navigates to another page.
88 */
89class PageEvent {
90}
91/** Injection token that can be used to provide the default options for the paginator module. */
92const MAT_PAGINATOR_DEFAULT_OPTIONS = new InjectionToken('MAT_PAGINATOR_DEFAULT_OPTIONS');
93// Boilerplate for applying mixins to _MatPaginatorBase.
94/** @docs-private */
95const _MatPaginatorMixinBase = mixinDisabled(mixinInitialized(class {
96}));
97/**
98 * Base class with all of the `MatPaginator` functionality.
99 * @docs-private
100 */
101class _MatPaginatorBase extends _MatPaginatorMixinBase {
102 /** The zero-based page index of the displayed list of items. Defaulted to 0. */
103 get pageIndex() {
104 return this._pageIndex;
105 }
106 set pageIndex(value) {
107 this._pageIndex = Math.max(coerceNumberProperty(value), 0);
108 this._changeDetectorRef.markForCheck();
109 }
110 /** The length of the total number of items that are being paginated. Defaulted to 0. */
111 get length() {
112 return this._length;
113 }
114 set length(value) {
115 this._length = coerceNumberProperty(value);
116 this._changeDetectorRef.markForCheck();
117 }
118 /** Number of items to display on a page. By default set to 50. */
119 get pageSize() {
120 return this._pageSize;
121 }
122 set pageSize(value) {
123 this._pageSize = Math.max(coerceNumberProperty(value), 0);
124 this._updateDisplayedPageSizeOptions();
125 }
126 /** The set of provided page size options to display to the user. */
127 get pageSizeOptions() {
128 return this._pageSizeOptions;
129 }
130 set pageSizeOptions(value) {
131 this._pageSizeOptions = (value || []).map(p => coerceNumberProperty(p));
132 this._updateDisplayedPageSizeOptions();
133 }
134 /** Whether to hide the page size selection UI from the user. */
135 get hidePageSize() {
136 return this._hidePageSize;
137 }
138 set hidePageSize(value) {
139 this._hidePageSize = coerceBooleanProperty(value);
140 }
141 /** Whether to show the first/last buttons UI to the user. */
142 get showFirstLastButtons() {
143 return this._showFirstLastButtons;
144 }
145 set showFirstLastButtons(value) {
146 this._showFirstLastButtons = coerceBooleanProperty(value);
147 }
148 constructor(_intl, _changeDetectorRef, defaults) {
149 super();
150 this._intl = _intl;
151 this._changeDetectorRef = _changeDetectorRef;
152 this._pageIndex = 0;
153 this._length = 0;
154 this._pageSizeOptions = [];
155 this._hidePageSize = false;
156 this._showFirstLastButtons = false;
157 /** Used to configure the underlying `MatSelect` inside the paginator. */
158 this.selectConfig = {};
159 /** Event emitted when the paginator changes the page size or page index. */
160 this.page = new EventEmitter();
161 this._intlChanges = _intl.changes.subscribe(() => this._changeDetectorRef.markForCheck());
162 if (defaults) {
163 const { pageSize, pageSizeOptions, hidePageSize, showFirstLastButtons } = defaults;
164 if (pageSize != null) {
165 this._pageSize = pageSize;
166 }
167 if (pageSizeOptions != null) {
168 this._pageSizeOptions = pageSizeOptions;
169 }
170 if (hidePageSize != null) {
171 this._hidePageSize = hidePageSize;
172 }
173 if (showFirstLastButtons != null) {
174 this._showFirstLastButtons = showFirstLastButtons;
175 }
176 }
177 }
178 ngOnInit() {
179 this._initialized = true;
180 this._updateDisplayedPageSizeOptions();
181 this._markInitialized();
182 }
183 ngOnDestroy() {
184 this._intlChanges.unsubscribe();
185 }
186 /** Advances to the next page if it exists. */
187 nextPage() {
188 if (!this.hasNextPage()) {
189 return;
190 }
191 const previousPageIndex = this.pageIndex;
192 this.pageIndex = this.pageIndex + 1;
193 this._emitPageEvent(previousPageIndex);
194 }
195 /** Move back to the previous page if it exists. */
196 previousPage() {
197 if (!this.hasPreviousPage()) {
198 return;
199 }
200 const previousPageIndex = this.pageIndex;
201 this.pageIndex = this.pageIndex - 1;
202 this._emitPageEvent(previousPageIndex);
203 }
204 /** Move to the first page if not already there. */
205 firstPage() {
206 // hasPreviousPage being false implies at the start
207 if (!this.hasPreviousPage()) {
208 return;
209 }
210 const previousPageIndex = this.pageIndex;
211 this.pageIndex = 0;
212 this._emitPageEvent(previousPageIndex);
213 }
214 /** Move to the last page if not already there. */
215 lastPage() {
216 // hasNextPage being false implies at the end
217 if (!this.hasNextPage()) {
218 return;
219 }
220 const previousPageIndex = this.pageIndex;
221 this.pageIndex = this.getNumberOfPages() - 1;
222 this._emitPageEvent(previousPageIndex);
223 }
224 /** Whether there is a previous page. */
225 hasPreviousPage() {
226 return this.pageIndex >= 1 && this.pageSize != 0;
227 }
228 /** Whether there is a next page. */
229 hasNextPage() {
230 const maxPageIndex = this.getNumberOfPages() - 1;
231 return this.pageIndex < maxPageIndex && this.pageSize != 0;
232 }
233 /** Calculate the number of pages */
234 getNumberOfPages() {
235 if (!this.pageSize) {
236 return 0;
237 }
238 return Math.ceil(this.length / this.pageSize);
239 }
240 /**
241 * Changes the page size so that the first item displayed on the page will still be
242 * displayed using the new page size.
243 *
244 * For example, if the page size is 10 and on the second page (items indexed 10-19) then
245 * switching so that the page size is 5 will set the third page as the current page so
246 * that the 10th item will still be displayed.
247 */
248 _changePageSize(pageSize) {
249 // Current page needs to be updated to reflect the new page size. Navigate to the page
250 // containing the previous page's first item.
251 const startIndex = this.pageIndex * this.pageSize;
252 const previousPageIndex = this.pageIndex;
253 this.pageIndex = Math.floor(startIndex / pageSize) || 0;
254 this.pageSize = pageSize;
255 this._emitPageEvent(previousPageIndex);
256 }
257 /** Checks whether the buttons for going forwards should be disabled. */
258 _nextButtonsDisabled() {
259 return this.disabled || !this.hasNextPage();
260 }
261 /** Checks whether the buttons for going backwards should be disabled. */
262 _previousButtonsDisabled() {
263 return this.disabled || !this.hasPreviousPage();
264 }
265 /**
266 * Updates the list of page size options to display to the user. Includes making sure that
267 * the page size is an option and that the list is sorted.
268 */
269 _updateDisplayedPageSizeOptions() {
270 if (!this._initialized) {
271 return;
272 }
273 // If no page size is provided, use the first page size option or the default page size.
274 if (!this.pageSize) {
275 this._pageSize =
276 this.pageSizeOptions.length != 0 ? this.pageSizeOptions[0] : DEFAULT_PAGE_SIZE;
277 }
278 this._displayedPageSizeOptions = this.pageSizeOptions.slice();
279 if (this._displayedPageSizeOptions.indexOf(this.pageSize) === -1) {
280 this._displayedPageSizeOptions.push(this.pageSize);
281 }
282 // Sort the numbers using a number-specific sort function.
283 this._displayedPageSizeOptions.sort((a, b) => a - b);
284 this._changeDetectorRef.markForCheck();
285 }
286 /** Emits an event notifying that a change of the paginator's properties has been triggered. */
287 _emitPageEvent(previousPageIndex) {
288 this.page.emit({
289 previousPageIndex,
290 pageIndex: this.pageIndex,
291 pageSize: this.pageSize,
292 length: this.length,
293 });
294 }
295}
296_MatPaginatorBase.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: _MatPaginatorBase, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive });
297_MatPaginatorBase.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.0-rc.0", type: _MatPaginatorBase, inputs: { color: "color", pageIndex: "pageIndex", length: "length", pageSize: "pageSize", pageSizeOptions: "pageSizeOptions", hidePageSize: "hidePageSize", showFirstLastButtons: "showFirstLastButtons", selectConfig: "selectConfig" }, outputs: { page: "page" }, usesInheritance: true, ngImport: i0 });
298i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: _MatPaginatorBase, decorators: [{
299 type: Directive
300 }], ctorParameters: function () { return [{ type: MatPaginatorIntl }, { type: i0.ChangeDetectorRef }, { type: undefined }]; }, propDecorators: { color: [{
301 type: Input
302 }], pageIndex: [{
303 type: Input
304 }], length: [{
305 type: Input
306 }], pageSize: [{
307 type: Input
308 }], pageSizeOptions: [{
309 type: Input
310 }], hidePageSize: [{
311 type: Input
312 }], showFirstLastButtons: [{
313 type: Input
314 }], selectConfig: [{
315 type: Input
316 }], page: [{
317 type: Output
318 }] } });
319let nextUniqueId = 0;
320/**
321 * Component to provide navigation between paged information. Displays the size of the current
322 * page, user-selectable options to change that size, what items are being shown, and
323 * navigational button to go to the previous or next page.
324 */
325class MatPaginator extends _MatPaginatorBase {
326 constructor(intl, changeDetectorRef, defaults) {
327 super(intl, changeDetectorRef, defaults);
328 /** ID for the DOM node containing the paginator's items per page label. */
329 this._pageSizeLabelId = `mat-paginator-page-size-label-${nextUniqueId++}`;
330 this._formFieldAppearance = defaults?.formFieldAppearance || 'outline';
331 }
332}
333MatPaginator.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginator, deps: [{ token: MatPaginatorIntl }, { token: i0.ChangeDetectorRef }, { token: MAT_PAGINATOR_DEFAULT_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Component });
334MatPaginator.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.0-rc.0", type: MatPaginator, selector: "mat-paginator", inputs: { disabled: "disabled" }, host: { attributes: { "role": "group" }, classAttribute: "mat-mdc-paginator" }, exportAs: ["matPaginator"], usesInheritance: true, ngImport: i0, template: "<div class=\"mat-mdc-paginator-outer-container\">\n <div class=\"mat-mdc-paginator-container\">\n <div class=\"mat-mdc-paginator-page-size\" *ngIf=\"!hidePageSize\">\n <div class=\"mat-mdc-paginator-page-size-label\" id=\"{{_pageSizeLabelId}}\">\n {{_intl.itemsPerPageLabel}}\n </div>\n\n <mat-form-field\n *ngIf=\"_displayedPageSizeOptions.length > 1\"\n [appearance]=\"_formFieldAppearance!\"\n [color]=\"color\"\n class=\"mat-mdc-paginator-page-size-select\">\n <mat-select\n [value]=\"pageSize\"\n [disabled]=\"disabled\"\n [aria-labelledby]=\"_pageSizeLabelId\"\n [panelClass]=\"selectConfig.panelClass || ''\"\n [disableOptionCentering]=\"selectConfig.disableOptionCentering\"\n (selectionChange)=\"_changePageSize($event.value)\"\n hideSingleSelectionIndicator>\n <mat-option *ngFor=\"let pageSizeOption of _displayedPageSizeOptions\" [value]=\"pageSizeOption\">\n {{pageSizeOption}}\n </mat-option>\n </mat-select>\n </mat-form-field>\n\n <div\n class=\"mat-mdc-paginator-page-size-value\"\n *ngIf=\"_displayedPageSizeOptions.length <= 1\">{{pageSize}}</div>\n </div>\n\n <div class=\"mat-mdc-paginator-range-actions\">\n <div class=\"mat-mdc-paginator-range-label\" aria-live=\"polite\">\n {{_intl.getRangeLabel(pageIndex, pageSize, length)}}\n </div>\n\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-first\"\n (click)=\"firstPage()\"\n [attr.aria-label]=\"_intl.firstPageLabel\"\n [matTooltip]=\"_intl.firstPageLabel\"\n [matTooltipDisabled]=\"_previousButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_previousButtonsDisabled()\"\n *ngIf=\"showFirstLastButtons\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z\"/>\n </svg>\n </button>\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-previous\"\n (click)=\"previousPage()\"\n [attr.aria-label]=\"_intl.previousPageLabel\"\n [matTooltip]=\"_intl.previousPageLabel\"\n [matTooltipDisabled]=\"_previousButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_previousButtonsDisabled()\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z\"/>\n </svg>\n </button>\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-next\"\n (click)=\"nextPage()\"\n [attr.aria-label]=\"_intl.nextPageLabel\"\n [matTooltip]=\"_intl.nextPageLabel\"\n [matTooltipDisabled]=\"_nextButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_nextButtonsDisabled()\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z\"/>\n </svg>\n </button>\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-last\"\n (click)=\"lastPage()\"\n [attr.aria-label]=\"_intl.lastPageLabel\"\n [matTooltip]=\"_intl.lastPageLabel\"\n [matTooltipDisabled]=\"_nextButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_nextButtonsDisabled()\"\n *ngIf=\"showFirstLastButtons\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z\"/>\n </svg>\n </button>\n </div>\n </div>\n</div>\n", styles: [".mat-mdc-paginator{display:block}.mat-mdc-paginator .mat-mdc-form-field-subscript-wrapper{display:none}.mat-mdc-paginator .mat-mdc-select{line-height:1.5}.mat-mdc-paginator-outer-container{display:flex}.mat-mdc-paginator-container{display:flex;align-items:center;justify-content:flex-end;padding:0 8px;flex-wrap:wrap-reverse;width:100%}.mat-mdc-paginator-page-size{display:flex;align-items:baseline;margin-right:8px}[dir=rtl] .mat-mdc-paginator-page-size{margin-right:0;margin-left:8px}.mat-mdc-paginator-page-size-label{margin:0 4px}.mat-mdc-paginator-page-size-select{margin:0 4px;width:84px}.mat-mdc-paginator-range-label{margin:0 32px 0 24px}.mat-mdc-paginator-range-actions{display:flex;align-items:center}.mat-mdc-paginator-icon{display:inline-block;width:28px}[dir=rtl] .mat-mdc-paginator-icon{transform:rotate(180deg)}.cdk-high-contrast-active .mat-mdc-icon-button[disabled] .mat-mdc-paginator-icon,.cdk-high-contrast-active .mat-mdc-paginator-icon{fill:currentColor;fill:CanvasText}.cdk-high-contrast-active .mat-mdc-paginator-range-actions .mat-mdc-icon-button{outline:solid 1px}"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "component", type: i5.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator"], exportAs: ["matSelect"] }, { kind: "component", type: i6.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "directive", type: i7.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
335i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginator, decorators: [{
336 type: Component,
337 args: [{ selector: 'mat-paginator', exportAs: 'matPaginator', inputs: ['disabled'], host: {
338 'class': 'mat-mdc-paginator',
339 'role': 'group',
340 }, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div class=\"mat-mdc-paginator-outer-container\">\n <div class=\"mat-mdc-paginator-container\">\n <div class=\"mat-mdc-paginator-page-size\" *ngIf=\"!hidePageSize\">\n <div class=\"mat-mdc-paginator-page-size-label\" id=\"{{_pageSizeLabelId}}\">\n {{_intl.itemsPerPageLabel}}\n </div>\n\n <mat-form-field\n *ngIf=\"_displayedPageSizeOptions.length > 1\"\n [appearance]=\"_formFieldAppearance!\"\n [color]=\"color\"\n class=\"mat-mdc-paginator-page-size-select\">\n <mat-select\n [value]=\"pageSize\"\n [disabled]=\"disabled\"\n [aria-labelledby]=\"_pageSizeLabelId\"\n [panelClass]=\"selectConfig.panelClass || ''\"\n [disableOptionCentering]=\"selectConfig.disableOptionCentering\"\n (selectionChange)=\"_changePageSize($event.value)\"\n hideSingleSelectionIndicator>\n <mat-option *ngFor=\"let pageSizeOption of _displayedPageSizeOptions\" [value]=\"pageSizeOption\">\n {{pageSizeOption}}\n </mat-option>\n </mat-select>\n </mat-form-field>\n\n <div\n class=\"mat-mdc-paginator-page-size-value\"\n *ngIf=\"_displayedPageSizeOptions.length <= 1\">{{pageSize}}</div>\n </div>\n\n <div class=\"mat-mdc-paginator-range-actions\">\n <div class=\"mat-mdc-paginator-range-label\" aria-live=\"polite\">\n {{_intl.getRangeLabel(pageIndex, pageSize, length)}}\n </div>\n\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-first\"\n (click)=\"firstPage()\"\n [attr.aria-label]=\"_intl.firstPageLabel\"\n [matTooltip]=\"_intl.firstPageLabel\"\n [matTooltipDisabled]=\"_previousButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_previousButtonsDisabled()\"\n *ngIf=\"showFirstLastButtons\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z\"/>\n </svg>\n </button>\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-previous\"\n (click)=\"previousPage()\"\n [attr.aria-label]=\"_intl.previousPageLabel\"\n [matTooltip]=\"_intl.previousPageLabel\"\n [matTooltipDisabled]=\"_previousButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_previousButtonsDisabled()\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z\"/>\n </svg>\n </button>\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-next\"\n (click)=\"nextPage()\"\n [attr.aria-label]=\"_intl.nextPageLabel\"\n [matTooltip]=\"_intl.nextPageLabel\"\n [matTooltipDisabled]=\"_nextButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_nextButtonsDisabled()\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z\"/>\n </svg>\n </button>\n <button mat-icon-button type=\"button\"\n class=\"mat-mdc-paginator-navigation-last\"\n (click)=\"lastPage()\"\n [attr.aria-label]=\"_intl.lastPageLabel\"\n [matTooltip]=\"_intl.lastPageLabel\"\n [matTooltipDisabled]=\"_nextButtonsDisabled()\"\n [matTooltipPosition]=\"'above'\"\n [disabled]=\"_nextButtonsDisabled()\"\n *ngIf=\"showFirstLastButtons\">\n <svg class=\"mat-mdc-paginator-icon\" viewBox=\"0 0 24 24\" focusable=\"false\">\n <path d=\"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z\"/>\n </svg>\n </button>\n </div>\n </div>\n</div>\n", styles: [".mat-mdc-paginator{display:block}.mat-mdc-paginator .mat-mdc-form-field-subscript-wrapper{display:none}.mat-mdc-paginator .mat-mdc-select{line-height:1.5}.mat-mdc-paginator-outer-container{display:flex}.mat-mdc-paginator-container{display:flex;align-items:center;justify-content:flex-end;padding:0 8px;flex-wrap:wrap-reverse;width:100%}.mat-mdc-paginator-page-size{display:flex;align-items:baseline;margin-right:8px}[dir=rtl] .mat-mdc-paginator-page-size{margin-right:0;margin-left:8px}.mat-mdc-paginator-page-size-label{margin:0 4px}.mat-mdc-paginator-page-size-select{margin:0 4px;width:84px}.mat-mdc-paginator-range-label{margin:0 32px 0 24px}.mat-mdc-paginator-range-actions{display:flex;align-items:center}.mat-mdc-paginator-icon{display:inline-block;width:28px}[dir=rtl] .mat-mdc-paginator-icon{transform:rotate(180deg)}.cdk-high-contrast-active .mat-mdc-icon-button[disabled] .mat-mdc-paginator-icon,.cdk-high-contrast-active .mat-mdc-paginator-icon{fill:currentColor;fill:CanvasText}.cdk-high-contrast-active .mat-mdc-paginator-range-actions .mat-mdc-icon-button{outline:solid 1px}"] }]
341 }], ctorParameters: function () { return [{ type: MatPaginatorIntl }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
342 type: Optional
343 }, {
344 type: Inject,
345 args: [MAT_PAGINATOR_DEFAULT_OPTIONS]
346 }] }]; } });
347
348/**
349 * @license
350 * Copyright Google LLC All Rights Reserved.
351 *
352 * Use of this source code is governed by an MIT-style license that can be
353 * found in the LICENSE file at https://angular.io/license
354 */
355class MatPaginatorModule {
356}
357MatPaginatorModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
358MatPaginatorModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorModule, declarations: [MatPaginator], imports: [CommonModule, MatButtonModule, MatSelectModule, MatTooltipModule], exports: [MatPaginator] });
359MatPaginatorModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorModule, providers: [MAT_PAGINATOR_INTL_PROVIDER], imports: [CommonModule, MatButtonModule, MatSelectModule, MatTooltipModule] });
360i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatPaginatorModule, decorators: [{
361 type: NgModule,
362 args: [{
363 imports: [CommonModule, MatButtonModule, MatSelectModule, MatTooltipModule],
364 exports: [MatPaginator],
365 declarations: [MatPaginator],
366 providers: [MAT_PAGINATOR_INTL_PROVIDER],
367 }]
368 }] });
369
370/**
371 * @license
372 * Copyright Google LLC All Rights Reserved.
373 *
374 * Use of this source code is governed by an MIT-style license that can be
375 * found in the LICENSE file at https://angular.io/license
376 */
377
378/**
379 * @license
380 * Copyright Google LLC All Rights Reserved.
381 *
382 * Use of this source code is governed by an MIT-style license that can be
383 * found in the LICENSE file at https://angular.io/license
384 */
385
386/**
387 * Generated bundle index. Do not edit.
388 */
389
390export { MAT_PAGINATOR_DEFAULT_OPTIONS, MAT_PAGINATOR_INTL_PROVIDER, MAT_PAGINATOR_INTL_PROVIDER_FACTORY, MatPaginator, MatPaginatorIntl, MatPaginatorModule, PageEvent, _MatPaginatorBase };
391//# sourceMappingURL=paginator.mjs.map