@progress/kendo-angular-pager 4.0.6 → 4.1.0-dev.202211230837
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/kendo-angular-pager.umd.js +1 -1
- package/esm2015/main.js +1 -0
- package/esm2015/package-metadata.js +1 -1
- package/esm2015/pager/focusable.directive.js +51 -0
- package/esm2015/pager/localization/custom-messages.component.js +3 -3
- package/esm2015/pager/localization/localized-messages.directive.js +3 -3
- package/esm2015/pager/localization/messages.js +5 -3
- package/esm2015/pager/navigation.service.js +37 -0
- package/esm2015/pager/pager-element.component.js +3 -3
- package/esm2015/pager/pager-info.component.js +3 -3
- package/esm2015/pager/pager-input.component.js +15 -9
- package/esm2015/pager/pager-next-buttons.component.js +9 -8
- package/esm2015/pager/pager-numeric-buttons.component.js +20 -13
- package/esm2015/pager/pager-page-sizes.component.js +7 -6
- package/esm2015/pager/pager-prev-buttons.component.js +9 -8
- package/esm2015/pager/pager-template.directive.js +3 -3
- package/esm2015/pager/pager.component.js +138 -20
- package/esm2015/pager/pager.module.js +11 -7
- package/esm2015/util.js +26 -0
- package/fesm2015/kendo-angular-pager.js +320 -87
- package/main.d.ts +1 -0
- package/package.json +1 -1
- package/pager/focusable.directive.d.ts +23 -0
- package/pager/localization/messages.d.ts +5 -1
- package/pager/navigation.service.d.ts +15 -0
- package/pager/pager-input.component.d.ts +4 -2
- package/pager/pager.component.d.ts +27 -3
- package/pager/pager.module.d.ts +6 -5
- package/util.d.ts +8 -0
package/main.d.ts
CHANGED
|
@@ -15,5 +15,6 @@ export { PagerNumericButtonsComponent } from './pager/pager-numeric-buttons.comp
|
|
|
15
15
|
export { PagerNextButtonsComponent } from './pager/pager-next-buttons.component';
|
|
16
16
|
export { PagerInputComponent } from './pager/pager-input.component';
|
|
17
17
|
export { PagerInfoComponent } from './pager/pager-info.component';
|
|
18
|
+
export { PagerFocusableDirective } from './pager/focusable.directive';
|
|
18
19
|
export { PagerComponent } from './pager/pager.component';
|
|
19
20
|
export { PagerModule } from './pager/pager.module';
|
package/package.json
CHANGED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { ElementRef, OnDestroy, OnInit, Renderer2 } from '@angular/core';
|
|
6
|
+
import { PagerNavigationService } from './navigation.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
/**
|
|
9
|
+
* Place the directive on custom focusable elements in the [`kendoDataPagerTemplate`]({% slug api_pager_pagertemplatedirective %}) to include them in the built-in Pager keyboard navigation.
|
|
10
|
+
*/
|
|
11
|
+
export declare class PagerFocusableDirective implements OnInit, OnDestroy {
|
|
12
|
+
private navigationService;
|
|
13
|
+
private element;
|
|
14
|
+
private renderer;
|
|
15
|
+
private subscriptions;
|
|
16
|
+
constructor(navigationService: PagerNavigationService, element: ElementRef, renderer: Renderer2);
|
|
17
|
+
ngOnInit(): void;
|
|
18
|
+
ngOnDestroy(): void;
|
|
19
|
+
private get nativeElement();
|
|
20
|
+
private innerNavigationChange;
|
|
21
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PagerFocusableDirective, never>;
|
|
22
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<PagerFocusableDirective, "[kendoPagerFocusable]", ["kendoPagerFocusable"], {}, {}, never>;
|
|
23
|
+
}
|
|
@@ -48,6 +48,10 @@ export declare class Messages extends ComponentMessages {
|
|
|
48
48
|
* The text of the title and aria-label attributes applied to the page chooser.
|
|
49
49
|
*/
|
|
50
50
|
selectPage: string;
|
|
51
|
+
/**
|
|
52
|
+
* The text of the aria-label attribute applied to the input element for entering the page number."
|
|
53
|
+
*/
|
|
54
|
+
inputLabel: string;
|
|
51
55
|
static ɵfac: i0.ɵɵFactoryDeclaration<Messages, never>;
|
|
52
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<Messages, "kendoPagerMessages", never, { "firstPage": "firstPage"; "lastPage": "lastPage"; "previousPage": "previousPage"; "nextPage": "nextPage"; "page": "page"; "pageNumberInputTitle": "pageNumberInputTitle"; "itemsPerPage": "itemsPerPage"; "of": "of"; "items": "items"; "selectPage": "selectPage"; }, {}, never>;
|
|
56
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<Messages, "kendoPagerMessages", never, { "firstPage": "firstPage"; "lastPage": "lastPage"; "previousPage": "previousPage"; "nextPage": "nextPage"; "page": "page"; "pageNumberInputTitle": "pageNumberInputTitle"; "itemsPerPage": "itemsPerPage"; "of": "of"; "items": "items"; "selectPage": "selectPage"; "inputLabel": "inputLabel"; }, {}, never>;
|
|
53
57
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Subject } from "rxjs";
|
|
6
|
+
/**
|
|
7
|
+
* @hidden
|
|
8
|
+
*/
|
|
9
|
+
export declare class PagerNavigationService {
|
|
10
|
+
isNavigable: boolean;
|
|
11
|
+
innerNavigationChange: Subject<boolean>;
|
|
12
|
+
toggleInnerNavigation(value: boolean): void;
|
|
13
|
+
keepFocusWithinComponent(wrapper: HTMLElement, target: HTMLElement, event: KeyboardEvent): void;
|
|
14
|
+
getFirstAndLastFocusable(wrapper: HTMLElement): Array<HTMLElement>;
|
|
15
|
+
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { NumericTextBoxComponent } from '@progress/kendo-angular-inputs';
|
|
6
|
-
import { ChangeDetectorRef, NgZone } from '@angular/core';
|
|
6
|
+
import { ChangeDetectorRef, NgZone, Renderer2 } from '@angular/core';
|
|
7
7
|
import { PagerElementComponent } from './pager-element.component';
|
|
8
8
|
import { LocalizationService } from "@progress/kendo-angular-l10n";
|
|
9
9
|
import { PagerContextService, PagerContextChanges } from "./pager-context.service";
|
|
@@ -14,8 +14,9 @@ import * as i0 from "@angular/core";
|
|
|
14
14
|
export declare class PagerInputComponent extends PagerElementComponent {
|
|
15
15
|
protected pagerContext: PagerContextService;
|
|
16
16
|
private zone;
|
|
17
|
+
private renderer;
|
|
17
18
|
numericInput: NumericTextBoxComponent;
|
|
18
|
-
constructor(localization: LocalizationService, pagerContext: PagerContextService, zone: NgZone, cd: ChangeDetectorRef);
|
|
19
|
+
constructor(localization: LocalizationService, pagerContext: PagerContextService, zone: NgZone, cd: ChangeDetectorRef, renderer: Renderer2);
|
|
19
20
|
/**
|
|
20
21
|
* @hidden
|
|
21
22
|
*
|
|
@@ -40,6 +41,7 @@ export declare class PagerInputComponent extends PagerElementComponent {
|
|
|
40
41
|
* @hidden
|
|
41
42
|
*/
|
|
42
43
|
get hasPages(): boolean;
|
|
44
|
+
ngAfterViewInit(): void;
|
|
43
45
|
protected onChanges({ total, skip, pageSize }: PagerContextChanges): void;
|
|
44
46
|
static ɵfac: i0.ɵɵFactoryDeclaration<PagerInputComponent, never>;
|
|
45
47
|
static ɵcmp: i0.ɵɵComponentDeclaration<PagerInputComponent, "kendo-datapager-input", never, {}, {}, never, never>;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { EventEmitter, OnChanges, SimpleChanges, OnInit, OnDestroy, ElementRef } from '@angular/core';
|
|
5
|
+
import { EventEmitter, OnChanges, SimpleChanges, OnInit, OnDestroy, ElementRef, Renderer2, NgZone } from '@angular/core';
|
|
6
6
|
import { PageChangeEvent } from './change-event-args.interface';
|
|
7
7
|
import { PagerTemplateDirective } from "./pager-template.directive";
|
|
8
8
|
import { ResizeSensorComponent } from "@progress/kendo-angular-common";
|
|
@@ -11,11 +11,15 @@ import { PageSizeChangeEvent } from './pagesizechange-event';
|
|
|
11
11
|
import { PageSizeItem } from './pagesize-item.interface';
|
|
12
12
|
import { PagerType } from './common/pager-type';
|
|
13
13
|
import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
14
|
+
import { PagerNavigationService } from './navigation.service';
|
|
14
15
|
import * as i0 from "@angular/core";
|
|
15
16
|
export declare class PagerComponent implements OnChanges, OnInit, OnDestroy {
|
|
16
17
|
private pagerContext;
|
|
17
18
|
private element;
|
|
18
19
|
private localization;
|
|
20
|
+
private renderer;
|
|
21
|
+
private ngZone;
|
|
22
|
+
private navigationService;
|
|
19
23
|
resizeSensor: ResizeSensorComponent;
|
|
20
24
|
template: PagerTemplateDirective;
|
|
21
25
|
/**
|
|
@@ -53,6 +57,13 @@ export declare class PagerComponent implements OnChanges, OnInit, OnDestroy {
|
|
|
53
57
|
* Toggles the **Previous** and **Next** buttons.
|
|
54
58
|
*/
|
|
55
59
|
previousNext: boolean;
|
|
60
|
+
/**
|
|
61
|
+
* If set to `true`, the user can use dedicated shortcuts to interact with the Pager ([see example]({% slug keyboard_navigation_pager %})).
|
|
62
|
+
* By default, navigation is disabled and the Pager content is accessible in the normal tab sequence.
|
|
63
|
+
* @default false
|
|
64
|
+
*/
|
|
65
|
+
set navigable(value: boolean);
|
|
66
|
+
get navigable(): boolean;
|
|
56
67
|
/**
|
|
57
68
|
* Fires when the current page of the Pager is changed ([see example]({% slug overview_pager %}#toc-basic-usage)).
|
|
58
69
|
* You have to handle the event yourself and page the data.
|
|
@@ -66,7 +77,14 @@ export declare class PagerComponent implements OnChanges, OnInit, OnDestroy {
|
|
|
66
77
|
pageSizeChange: EventEmitter<PageSizeChangeEvent>;
|
|
67
78
|
pagerClass: boolean;
|
|
68
79
|
widgetRole: string;
|
|
80
|
+
roleDescription: string;
|
|
81
|
+
keyShortcuts: string;
|
|
82
|
+
hostTabindex: string;
|
|
69
83
|
get dir(): string;
|
|
84
|
+
/**
|
|
85
|
+
* @hidden
|
|
86
|
+
*/
|
|
87
|
+
focusHandler(ev: any): void;
|
|
70
88
|
get totalPages(): number;
|
|
71
89
|
get currentPage(): number;
|
|
72
90
|
get pageSizeValues(): boolean | Array<number | PageSizeItem>;
|
|
@@ -75,7 +93,9 @@ export declare class PagerComponent implements OnChanges, OnInit, OnDestroy {
|
|
|
75
93
|
private _templateContext;
|
|
76
94
|
private _pageSizeValues;
|
|
77
95
|
private direction;
|
|
78
|
-
|
|
96
|
+
private isInnerNavigationEnabled;
|
|
97
|
+
private _navigable;
|
|
98
|
+
constructor(pagerContext: PagerContextService, element: ElementRef, localization: LocalizationService, renderer: Renderer2, ngZone: NgZone, navigationService: PagerNavigationService);
|
|
79
99
|
ngOnInit(): void;
|
|
80
100
|
ngAfterViewInit(): void;
|
|
81
101
|
ngOnChanges(changes: SimpleChanges): void;
|
|
@@ -93,6 +113,10 @@ export declare class PagerComponent implements OnChanges, OnInit, OnDestroy {
|
|
|
93
113
|
*/
|
|
94
114
|
onPageSizeChange(event: PageSizeChangeEvent): void;
|
|
95
115
|
private resizeHandler;
|
|
116
|
+
private textFor;
|
|
117
|
+
private get ariaLabel();
|
|
118
|
+
private keyDownHandler;
|
|
119
|
+
private innerNavigationChange;
|
|
96
120
|
static ɵfac: i0.ɵɵFactoryDeclaration<PagerComponent, never>;
|
|
97
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<PagerComponent, "kendo-datapager", ["kendoDataPager"], { "total": "total"; "skip": "skip"; "pageSize": "pageSize"; "buttonCount": "buttonCount"; "info": "info"; "type": "type"; "pageSizeValues": "pageSizeValues"; "previousNext": "previousNext"; }, { "pageChange": "pageChange"; "pageSizeChange": "pageSizeChange"; }, ["template"], never>;
|
|
121
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PagerComponent, "kendo-datapager", ["kendoDataPager"], { "total": "total"; "skip": "skip"; "pageSize": "pageSize"; "buttonCount": "buttonCount"; "info": "info"; "type": "type"; "pageSizeValues": "pageSizeValues"; "previousNext": "previousNext"; "navigable": "navigable"; }, { "pageChange": "pageChange"; "pageSizeChange": "pageSizeChange"; }, ["template"], never>;
|
|
98
122
|
}
|
package/pager/pager.module.d.ts
CHANGED
|
@@ -13,16 +13,17 @@ import * as i7 from "./pager-page-sizes.component";
|
|
|
13
13
|
import * as i8 from "./pager-template.directive";
|
|
14
14
|
import * as i9 from "./localization/localized-messages.directive";
|
|
15
15
|
import * as i10 from "./localization/custom-messages.component";
|
|
16
|
-
import * as i11 from "
|
|
17
|
-
import * as i12 from "@
|
|
18
|
-
import * as i13 from "@progress/kendo-angular-
|
|
19
|
-
import * as i14 from "@progress/kendo-angular-
|
|
16
|
+
import * as i11 from "./focusable.directive";
|
|
17
|
+
import * as i12 from "@angular/common";
|
|
18
|
+
import * as i13 from "@progress/kendo-angular-inputs";
|
|
19
|
+
import * as i14 from "@progress/kendo-angular-dropdowns";
|
|
20
|
+
import * as i15 from "@progress/kendo-angular-common";
|
|
20
21
|
/**
|
|
21
22
|
* @hidden
|
|
22
23
|
*/
|
|
23
24
|
export declare class PagerModule {
|
|
24
25
|
static exports(): any[];
|
|
25
26
|
static ɵfac: i0.ɵɵFactoryDeclaration<PagerModule, never>;
|
|
26
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<PagerModule, [typeof i1.PagerComponent, typeof i2.PagerPrevButtonsComponent, typeof i3.PagerNextButtonsComponent, typeof i4.PagerNumericButtonsComponent, typeof i5.PagerInputComponent, typeof i6.PagerInfoComponent, typeof i7.PagerPageSizesComponent, typeof i8.PagerTemplateDirective, typeof i9.LocalizedMessagesDirective, typeof i10.CustomMessagesComponent], [typeof
|
|
27
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<PagerModule, [typeof i1.PagerComponent, typeof i2.PagerPrevButtonsComponent, typeof i3.PagerNextButtonsComponent, typeof i4.PagerNumericButtonsComponent, typeof i5.PagerInputComponent, typeof i6.PagerInfoComponent, typeof i7.PagerPageSizesComponent, typeof i8.PagerTemplateDirective, typeof i9.LocalizedMessagesDirective, typeof i10.CustomMessagesComponent, typeof i11.PagerFocusableDirective], [typeof i12.CommonModule, typeof i13.NumericTextBoxModule, typeof i14.DropDownListModule, typeof i15.EventsModule, typeof i15.ResizeSensorModule], [typeof i1.PagerComponent, typeof i2.PagerPrevButtonsComponent, typeof i3.PagerNextButtonsComponent, typeof i4.PagerNumericButtonsComponent, typeof i5.PagerInputComponent, typeof i6.PagerInfoComponent, typeof i7.PagerPageSizesComponent, typeof i8.PagerTemplateDirective, typeof i9.LocalizedMessagesDirective, typeof i10.CustomMessagesComponent, typeof i11.PagerFocusableDirective]>;
|
|
27
28
|
static ɵinj: i0.ɵɵInjectorDeclaration<PagerModule>;
|
|
28
29
|
}
|
package/util.d.ts
CHANGED