@progress/kendo-angular-scheduler 4.3.1-dev.202208110754 → 4.3.1
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-scheduler.umd.js +1 -1
- package/esm2015/navigation/focus.service.js +2 -1
- package/esm2015/package-metadata.js +1 -1
- package/esm2015/toolbar/navigation.component.js +43 -19
- package/esm2015/views/common/view-footer.component.js +12 -8
- package/esm2015/views/month/month-view-item.component.js +3 -0
- package/esm2015/views/view-items/base-view-item.js +1 -3
- package/fesm2015/kendo-angular-scheduler.js +65 -37
- package/package.json +1 -1
- package/toolbar/navigation.component.d.ts +19 -1
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { Injectable, Optional, EventEmitter } from '@angular/core';
|
|
6
|
-
import { Subscription
|
|
6
|
+
import { Subscription } from 'rxjs';
|
|
7
|
+
import { take } from 'rxjs/operators';
|
|
7
8
|
import * as i0 from "@angular/core";
|
|
8
9
|
import * as i1 from "../views/common/dom-events.service";
|
|
9
10
|
/**
|
|
@@ -9,7 +9,7 @@ export const packageMetadata = {
|
|
|
9
9
|
name: '@progress/kendo-angular-scheduler',
|
|
10
10
|
productName: 'Kendo UI for Angular',
|
|
11
11
|
productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
|
|
12
|
-
publishDate:
|
|
12
|
+
publishDate: 1662549700,
|
|
13
13
|
version: '',
|
|
14
14
|
licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
|
|
15
15
|
};
|
|
@@ -8,9 +8,10 @@ import * as i0 from "@angular/core";
|
|
|
8
8
|
import * as i1 from "@progress/kendo-angular-popup";
|
|
9
9
|
import * as i2 from "./toolbar.service";
|
|
10
10
|
import * as i3 from "@progress/kendo-angular-l10n";
|
|
11
|
-
import * as i4 from "
|
|
12
|
-
import * as i5 from "@progress/kendo-angular-
|
|
13
|
-
import * as i6 from "@angular
|
|
11
|
+
import * as i4 from "../views/view-context.service";
|
|
12
|
+
import * as i5 from "@progress/kendo-angular-dateinputs";
|
|
13
|
+
import * as i6 from "@progress/kendo-angular-buttons";
|
|
14
|
+
import * as i7 from "@angular/common";
|
|
14
15
|
/**
|
|
15
16
|
* A toolbar component which contains the controls for date navigation
|
|
16
17
|
* ([see example]({% slug toolbar_scheduler %}#toc-including-the-built-in-components)).
|
|
@@ -28,10 +29,12 @@ import * as i6 from "@angular/common";
|
|
|
28
29
|
* {% endmeta %}
|
|
29
30
|
*/
|
|
30
31
|
export class ToolbarNavigationComponent {
|
|
31
|
-
constructor(popupService, toolbarService, localization, cd) {
|
|
32
|
+
constructor(popupService, toolbarService, localization, cd, viewContext) {
|
|
32
33
|
this.popupService = popupService;
|
|
33
34
|
this.toolbarService = toolbarService;
|
|
34
35
|
this.localization = localization;
|
|
36
|
+
this.cd = cd;
|
|
37
|
+
this.viewContext = viewContext;
|
|
35
38
|
/**
|
|
36
39
|
* @hidden
|
|
37
40
|
* TODO: Drop in next MAJOR version
|
|
@@ -47,6 +50,10 @@ export class ToolbarNavigationComponent {
|
|
|
47
50
|
* TODO: Drop in next MAJOR version
|
|
48
51
|
*/
|
|
49
52
|
this.inlineGapStyle = 'inherit';
|
|
53
|
+
/**
|
|
54
|
+
* @hidden
|
|
55
|
+
*/
|
|
56
|
+
this.dateRangeText = { short: '', long: '', current: '' };
|
|
50
57
|
this.subs = this.localization.changes.subscribe(() => {
|
|
51
58
|
cd.markForCheck();
|
|
52
59
|
});
|
|
@@ -92,6 +99,16 @@ export class ToolbarNavigationComponent {
|
|
|
92
99
|
onBlur() {
|
|
93
100
|
this.closePopup();
|
|
94
101
|
}
|
|
102
|
+
ngOnInit() {
|
|
103
|
+
this.subs.add(this.ctx.dateRange.subscribe(res => {
|
|
104
|
+
this.dateRangeText.short = res === null || res === void 0 ? void 0 : res.shortText;
|
|
105
|
+
this.dateRangeText.long = res === null || res === void 0 ? void 0 : res.text;
|
|
106
|
+
this.setDateRangeText();
|
|
107
|
+
}));
|
|
108
|
+
this.subs.add(this.viewContext.resize.subscribe(() => {
|
|
109
|
+
this.setDateRangeText();
|
|
110
|
+
}));
|
|
111
|
+
}
|
|
95
112
|
ngOnDestroy() {
|
|
96
113
|
this.subs.unsubscribe();
|
|
97
114
|
this.closePopup();
|
|
@@ -158,8 +175,13 @@ export class ToolbarNavigationComponent {
|
|
|
158
175
|
this.popupRef = null;
|
|
159
176
|
}
|
|
160
177
|
}
|
|
178
|
+
setDateRangeText() {
|
|
179
|
+
const isDesktop = window.matchMedia('(min-width: 1024px)').matches;
|
|
180
|
+
this.dateRangeText.current = isDesktop ? this.dateRangeText.long : this.dateRangeText.short;
|
|
181
|
+
this.cd.detectChanges();
|
|
182
|
+
}
|
|
161
183
|
}
|
|
162
|
-
ToolbarNavigationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ToolbarNavigationComponent, deps: [{ token: i1.PopupService }, { token: i2.ToolbarService }, { token: i3.LocalizationService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
184
|
+
ToolbarNavigationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ToolbarNavigationComponent, deps: [{ token: i1.PopupService }, { token: i2.ToolbarService }, { token: i3.LocalizationService }, { token: i0.ChangeDetectorRef }, { token: i4.ViewContextService }], target: i0.ɵɵFactoryTarget.Component });
|
|
163
185
|
ToolbarNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ToolbarNavigationComponent, selector: "[kendoSchedulerToolbarNavigation]", inputs: { min: "min", max: "max" }, host: { properties: { "style.display": "this.inlineDisplayStyle", "style.flex-flow": "this.inlineFlexFlowStyle", "style.gap": "this.inlineGapStyle" } }, providers: [
|
|
164
186
|
PopupService
|
|
165
187
|
], viewQueries: [{ propertyName: "calendar", first: true, predicate: ["calendar"], descendants: true }], ngImport: i0, template: `
|
|
@@ -190,18 +212,19 @@ ToolbarNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0
|
|
|
190
212
|
</button>
|
|
191
213
|
</span>
|
|
192
214
|
|
|
193
|
-
<
|
|
215
|
+
<button
|
|
216
|
+
#anchor
|
|
217
|
+
kendoButton
|
|
218
|
+
icon="calendar"
|
|
219
|
+
fillMode="flat"
|
|
194
220
|
(click)="toggleSelectedDate({ nativeElement: anchor }, template)"
|
|
195
221
|
role="button"
|
|
196
|
-
href="#"
|
|
197
222
|
class="k-nav-current"
|
|
198
223
|
tabindex="-1"
|
|
199
224
|
[attr.aria-live]="'polite'"
|
|
200
225
|
>
|
|
201
|
-
<span
|
|
202
|
-
|
|
203
|
-
<span class="k-lg-date-format">{{ (ctx.dateRange | async)?.text }}</span>
|
|
204
|
-
</a>
|
|
226
|
+
<span>{{ dateRangeText?.current }}</span>
|
|
227
|
+
</button>
|
|
205
228
|
|
|
206
229
|
<ng-template #template>
|
|
207
230
|
<kendo-calendar #calendar (blur)="onBlur()" (valueChange)="selectDate($event)" [value]="ctx.selectedDate | async" [min]="min" [max]="max">
|
|
@@ -209,7 +232,7 @@ ToolbarNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0
|
|
|
209
232
|
</kendo-calendar-messages>
|
|
210
233
|
</kendo-calendar>
|
|
211
234
|
</ng-template>
|
|
212
|
-
`, isInline: true, components: [{ type:
|
|
235
|
+
`, isInline: true, components: [{ type: i5.CalendarComponent, selector: "kendo-calendar", inputs: ["id", "focusedDate", "min", "max", "rangeValidation", "selection", "value", "disabled", "tabindex", "tabIndex", "disabledDates", "navigation", "activeView", "bottomView", "topView", "type", "animateNavigation", "weekNumber", "cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "headerTitleTemplate", "navigationItemTemplate"], outputs: ["activeViewChange", "navigate", "activeViewDateChange", "valueChange"], exportAs: ["kendo-calendar"] }, { type: i5.CalendarCustomMessagesComponent, selector: "kendo-calendar-messages" }], directives: [{ type: i6.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], pipes: { "async": i7.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
213
236
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ToolbarNavigationComponent, decorators: [{
|
|
214
237
|
type: Component,
|
|
215
238
|
args: [{
|
|
@@ -247,18 +270,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
247
270
|
</button>
|
|
248
271
|
</span>
|
|
249
272
|
|
|
250
|
-
<
|
|
273
|
+
<button
|
|
274
|
+
#anchor
|
|
275
|
+
kendoButton
|
|
276
|
+
icon="calendar"
|
|
277
|
+
fillMode="flat"
|
|
251
278
|
(click)="toggleSelectedDate({ nativeElement: anchor }, template)"
|
|
252
279
|
role="button"
|
|
253
|
-
href="#"
|
|
254
280
|
class="k-nav-current"
|
|
255
281
|
tabindex="-1"
|
|
256
282
|
[attr.aria-live]="'polite'"
|
|
257
283
|
>
|
|
258
|
-
<span
|
|
259
|
-
|
|
260
|
-
<span class="k-lg-date-format">{{ (ctx.dateRange | async)?.text }}</span>
|
|
261
|
-
</a>
|
|
284
|
+
<span>{{ dateRangeText?.current }}</span>
|
|
285
|
+
</button>
|
|
262
286
|
|
|
263
287
|
<ng-template #template>
|
|
264
288
|
<kendo-calendar #calendar (blur)="onBlur()" (valueChange)="selectDate($event)" [value]="ctx.selectedDate | async" [min]="min" [max]="max">
|
|
@@ -268,7 +292,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
268
292
|
</ng-template>
|
|
269
293
|
`
|
|
270
294
|
}]
|
|
271
|
-
}], ctorParameters: function () { return [{ type: i1.PopupService }, { type: i2.ToolbarService }, { type: i3.LocalizationService }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { calendar: [{
|
|
295
|
+
}], ctorParameters: function () { return [{ type: i1.PopupService }, { type: i2.ToolbarService }, { type: i3.LocalizationService }, { type: i0.ChangeDetectorRef }, { type: i4.ViewContextService }]; }, propDecorators: { calendar: [{
|
|
272
296
|
type: ViewChild,
|
|
273
297
|
args: ['calendar', { static: false }]
|
|
274
298
|
}], inlineDisplayStyle: [{
|
|
@@ -26,10 +26,12 @@ export class ViewFooterComponent {
|
|
|
26
26
|
}
|
|
27
27
|
ViewFooterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ViewFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
28
28
|
ViewFooterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ViewFooterComponent, selector: "[viewFooter]", inputs: { items: "items" }, outputs: { itemClick: "itemClick" }, host: { properties: { "class.k-scheduler-footer": "this.hostClasses", "class.k-toolbar": "this.hostClasses", "style.justify-content": "this.inlineJustifyContentStyle" } }, ngImport: i0, template: `
|
|
29
|
-
<
|
|
30
|
-
<
|
|
31
|
-
|
|
32
|
-
|
|
29
|
+
<span class="k-scheduler-navigation">
|
|
30
|
+
<button type="button" kendoButton *ngFor="let item of items" [ngClass]="item.cssClass" (click)="onItemClick($event, item)">
|
|
31
|
+
<span class="k-button-icon k-icon" [ngClass]="item.iconClass"></span>
|
|
32
|
+
<span class="k-button-text">{{ item.text }}</span>
|
|
33
|
+
</button>
|
|
34
|
+
</span>
|
|
33
35
|
`, isInline: true, directives: [{ type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
34
36
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ViewFooterComponent, decorators: [{
|
|
35
37
|
type: Component,
|
|
@@ -37,10 +39,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
37
39
|
// eslint-disable-next-line @angular-eslint/component-selector
|
|
38
40
|
selector: '[viewFooter]',
|
|
39
41
|
template: `
|
|
40
|
-
<
|
|
41
|
-
<
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
<span class="k-scheduler-navigation">
|
|
43
|
+
<button type="button" kendoButton *ngFor="let item of items" [ngClass]="item.cssClass" (click)="onItemClick($event, item)">
|
|
44
|
+
<span class="k-button-icon k-icon" [ngClass]="item.iconClass"></span>
|
|
45
|
+
<span class="k-button-text">{{ item.text }}</span>
|
|
46
|
+
</button>
|
|
47
|
+
</span>
|
|
44
48
|
`
|
|
45
49
|
}]
|
|
46
50
|
}], propDecorators: { hostClasses: [{
|
|
@@ -78,8 +78,7 @@ export class BaseViewItem {
|
|
|
78
78
|
right: this.localization.rtl ? `${rect.left}px` : '',
|
|
79
79
|
top: `${rect.top}px`,
|
|
80
80
|
width: `${rect.width}px`,
|
|
81
|
-
height: `${rect.height}px
|
|
82
|
-
display: 'block'
|
|
81
|
+
height: `${rect.height}px`
|
|
83
82
|
});
|
|
84
83
|
}
|
|
85
84
|
}
|
|
@@ -90,7 +89,6 @@ export class BaseViewItem {
|
|
|
90
89
|
this.subs.add(this.slotService.slotsChange.subscribe(() => {
|
|
91
90
|
this.rect = null;
|
|
92
91
|
this.setStyles({
|
|
93
|
-
display: 'none',
|
|
94
92
|
width: 0,
|
|
95
93
|
left: 0
|
|
96
94
|
});
|
|
@@ -10,10 +10,10 @@ import * as i12$1 from '@progress/kendo-angular-common';
|
|
|
10
10
|
import { hasObservers, isDocumentAvailable, isChanged, Keys, anyChanged, ResizeSensorComponent, EventsModule, guid, ResizeSensorModule } from '@progress/kendo-angular-common';
|
|
11
11
|
import { isEqualDate, timezoneNames, ZonedDate, toLocalDate, getDate, Day, MS_PER_DAY, addDays, firstDayOfMonth, addMonths, firstDayInWeek } from '@progress/kendo-date-math';
|
|
12
12
|
import { validatePackage } from '@progress/kendo-licensing';
|
|
13
|
-
import * as
|
|
13
|
+
import * as i5 from '@progress/kendo-angular-dateinputs';
|
|
14
14
|
import { PreventableEvent as PreventableEvent$1, CalendarModule, DateInputsModule } from '@progress/kendo-angular-dateinputs';
|
|
15
|
-
import { Subject, BehaviorSubject, fromEvent, Subscription,
|
|
16
|
-
import { auditTime, buffer, filter, map, debounceTime, take
|
|
15
|
+
import { Subject, BehaviorSubject, fromEvent, Subscription, combineLatest, merge } from 'rxjs';
|
|
16
|
+
import { auditTime, buffer, filter, map, debounceTime, take, switchMap, tap, distinctUntilChanged } from 'rxjs/operators';
|
|
17
17
|
import * as i11$1 from '@angular/forms';
|
|
18
18
|
import { NG_VALUE_ACCESSOR, FormControl, FormGroup, ReactiveFormsModule } from '@angular/forms';
|
|
19
19
|
import * as i1 from '@progress/kendo-angular-dialog';
|
|
@@ -43,7 +43,7 @@ const packageMetadata = {
|
|
|
43
43
|
name: '@progress/kendo-angular-scheduler',
|
|
44
44
|
productName: 'Kendo UI for Angular',
|
|
45
45
|
productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
|
|
46
|
-
publishDate:
|
|
46
|
+
publishDate: 1662549700,
|
|
47
47
|
version: '',
|
|
48
48
|
licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
|
|
49
49
|
};
|
|
@@ -1618,7 +1618,7 @@ class DialogsService {
|
|
|
1618
1618
|
this.focusService.focus();
|
|
1619
1619
|
return false;
|
|
1620
1620
|
}
|
|
1621
|
-
this.viewState.layoutEnd.pipe(take
|
|
1621
|
+
this.viewState.layoutEnd.pipe(take(1)).subscribe(() => this.focusService.focus());
|
|
1622
1622
|
const res = result;
|
|
1623
1623
|
return res.value;
|
|
1624
1624
|
}));
|
|
@@ -2305,10 +2305,12 @@ const alwaysFalse = () => false;
|
|
|
2305
2305
|
* {% endmeta %}
|
|
2306
2306
|
*/
|
|
2307
2307
|
class ToolbarNavigationComponent {
|
|
2308
|
-
constructor(popupService, toolbarService, localization, cd) {
|
|
2308
|
+
constructor(popupService, toolbarService, localization, cd, viewContext) {
|
|
2309
2309
|
this.popupService = popupService;
|
|
2310
2310
|
this.toolbarService = toolbarService;
|
|
2311
2311
|
this.localization = localization;
|
|
2312
|
+
this.cd = cd;
|
|
2313
|
+
this.viewContext = viewContext;
|
|
2312
2314
|
/**
|
|
2313
2315
|
* @hidden
|
|
2314
2316
|
* TODO: Drop in next MAJOR version
|
|
@@ -2324,6 +2326,10 @@ class ToolbarNavigationComponent {
|
|
|
2324
2326
|
* TODO: Drop in next MAJOR version
|
|
2325
2327
|
*/
|
|
2326
2328
|
this.inlineGapStyle = 'inherit';
|
|
2329
|
+
/**
|
|
2330
|
+
* @hidden
|
|
2331
|
+
*/
|
|
2332
|
+
this.dateRangeText = { short: '', long: '', current: '' };
|
|
2327
2333
|
this.subs = this.localization.changes.subscribe(() => {
|
|
2328
2334
|
cd.markForCheck();
|
|
2329
2335
|
});
|
|
@@ -2369,6 +2375,16 @@ class ToolbarNavigationComponent {
|
|
|
2369
2375
|
onBlur() {
|
|
2370
2376
|
this.closePopup();
|
|
2371
2377
|
}
|
|
2378
|
+
ngOnInit() {
|
|
2379
|
+
this.subs.add(this.ctx.dateRange.subscribe(res => {
|
|
2380
|
+
this.dateRangeText.short = res === null || res === void 0 ? void 0 : res.shortText;
|
|
2381
|
+
this.dateRangeText.long = res === null || res === void 0 ? void 0 : res.text;
|
|
2382
|
+
this.setDateRangeText();
|
|
2383
|
+
}));
|
|
2384
|
+
this.subs.add(this.viewContext.resize.subscribe(() => {
|
|
2385
|
+
this.setDateRangeText();
|
|
2386
|
+
}));
|
|
2387
|
+
}
|
|
2372
2388
|
ngOnDestroy() {
|
|
2373
2389
|
this.subs.unsubscribe();
|
|
2374
2390
|
this.closePopup();
|
|
@@ -2435,8 +2451,13 @@ class ToolbarNavigationComponent {
|
|
|
2435
2451
|
this.popupRef = null;
|
|
2436
2452
|
}
|
|
2437
2453
|
}
|
|
2454
|
+
setDateRangeText() {
|
|
2455
|
+
const isDesktop = window.matchMedia('(min-width: 1024px)').matches;
|
|
2456
|
+
this.dateRangeText.current = isDesktop ? this.dateRangeText.long : this.dateRangeText.short;
|
|
2457
|
+
this.cd.detectChanges();
|
|
2458
|
+
}
|
|
2438
2459
|
}
|
|
2439
|
-
ToolbarNavigationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ToolbarNavigationComponent, deps: [{ token: i1$1.PopupService }, { token: ToolbarService }, { token: i2.LocalizationService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
2460
|
+
ToolbarNavigationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ToolbarNavigationComponent, deps: [{ token: i1$1.PopupService }, { token: ToolbarService }, { token: i2.LocalizationService }, { token: i0.ChangeDetectorRef }, { token: ViewContextService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2440
2461
|
ToolbarNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ToolbarNavigationComponent, selector: "[kendoSchedulerToolbarNavigation]", inputs: { min: "min", max: "max" }, host: { properties: { "style.display": "this.inlineDisplayStyle", "style.flex-flow": "this.inlineFlexFlowStyle", "style.gap": "this.inlineGapStyle" } }, providers: [
|
|
2441
2462
|
PopupService
|
|
2442
2463
|
], viewQueries: [{ propertyName: "calendar", first: true, predicate: ["calendar"], descendants: true }], ngImport: i0, template: `
|
|
@@ -2467,18 +2488,19 @@ ToolbarNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0
|
|
|
2467
2488
|
</button>
|
|
2468
2489
|
</span>
|
|
2469
2490
|
|
|
2470
|
-
<
|
|
2491
|
+
<button
|
|
2492
|
+
#anchor
|
|
2493
|
+
kendoButton
|
|
2494
|
+
icon="calendar"
|
|
2495
|
+
fillMode="flat"
|
|
2471
2496
|
(click)="toggleSelectedDate({ nativeElement: anchor }, template)"
|
|
2472
2497
|
role="button"
|
|
2473
|
-
href="#"
|
|
2474
2498
|
class="k-nav-current"
|
|
2475
2499
|
tabindex="-1"
|
|
2476
2500
|
[attr.aria-live]="'polite'"
|
|
2477
2501
|
>
|
|
2478
|
-
<span
|
|
2479
|
-
|
|
2480
|
-
<span class="k-lg-date-format">{{ (ctx.dateRange | async)?.text }}</span>
|
|
2481
|
-
</a>
|
|
2502
|
+
<span>{{ dateRangeText?.current }}</span>
|
|
2503
|
+
</button>
|
|
2482
2504
|
|
|
2483
2505
|
<ng-template #template>
|
|
2484
2506
|
<kendo-calendar #calendar (blur)="onBlur()" (valueChange)="selectDate($event)" [value]="ctx.selectedDate | async" [min]="min" [max]="max">
|
|
@@ -2486,7 +2508,7 @@ ToolbarNavigationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0
|
|
|
2486
2508
|
</kendo-calendar-messages>
|
|
2487
2509
|
</kendo-calendar>
|
|
2488
2510
|
</ng-template>
|
|
2489
|
-
`, isInline: true, components: [{ type:
|
|
2511
|
+
`, isInline: true, components: [{ type: i5.CalendarComponent, selector: "kendo-calendar", inputs: ["id", "focusedDate", "min", "max", "rangeValidation", "selection", "value", "disabled", "tabindex", "tabIndex", "disabledDates", "navigation", "activeView", "bottomView", "topView", "type", "animateNavigation", "weekNumber", "cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "headerTitleTemplate", "navigationItemTemplate"], outputs: ["activeViewChange", "navigate", "activeViewDateChange", "valueChange"], exportAs: ["kendo-calendar"] }, { type: i5.CalendarCustomMessagesComponent, selector: "kendo-calendar-messages" }], directives: [{ type: i3.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], pipes: { "async": i11.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2490
2512
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ToolbarNavigationComponent, decorators: [{
|
|
2491
2513
|
type: Component,
|
|
2492
2514
|
args: [{
|
|
@@ -2524,18 +2546,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
2524
2546
|
</button>
|
|
2525
2547
|
</span>
|
|
2526
2548
|
|
|
2527
|
-
<
|
|
2549
|
+
<button
|
|
2550
|
+
#anchor
|
|
2551
|
+
kendoButton
|
|
2552
|
+
icon="calendar"
|
|
2553
|
+
fillMode="flat"
|
|
2528
2554
|
(click)="toggleSelectedDate({ nativeElement: anchor }, template)"
|
|
2529
2555
|
role="button"
|
|
2530
|
-
href="#"
|
|
2531
2556
|
class="k-nav-current"
|
|
2532
2557
|
tabindex="-1"
|
|
2533
2558
|
[attr.aria-live]="'polite'"
|
|
2534
2559
|
>
|
|
2535
|
-
<span
|
|
2536
|
-
|
|
2537
|
-
<span class="k-lg-date-format">{{ (ctx.dateRange | async)?.text }}</span>
|
|
2538
|
-
</a>
|
|
2560
|
+
<span>{{ dateRangeText?.current }}</span>
|
|
2561
|
+
</button>
|
|
2539
2562
|
|
|
2540
2563
|
<ng-template #template>
|
|
2541
2564
|
<kendo-calendar #calendar (blur)="onBlur()" (valueChange)="selectDate($event)" [value]="ctx.selectedDate | async" [min]="min" [max]="max">
|
|
@@ -2545,7 +2568,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
2545
2568
|
</ng-template>
|
|
2546
2569
|
`
|
|
2547
2570
|
}]
|
|
2548
|
-
}], ctorParameters: function () { return [{ type: i1$1.PopupService }, { type: ToolbarService }, { type: i2.LocalizationService }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { calendar: [{
|
|
2571
|
+
}], ctorParameters: function () { return [{ type: i1$1.PopupService }, { type: ToolbarService }, { type: i2.LocalizationService }, { type: i0.ChangeDetectorRef }, { type: ViewContextService }]; }, propDecorators: { calendar: [{
|
|
2549
2572
|
type: ViewChild,
|
|
2550
2573
|
args: ['calendar', { static: false }]
|
|
2551
2574
|
}], inlineDisplayStyle: [{
|
|
@@ -3079,7 +3102,7 @@ SchedulerDateTimePickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion:
|
|
|
3079
3102
|
[(value)]='date'
|
|
3080
3103
|
(valueChange)='onValueChange($event)'
|
|
3081
3104
|
></kendo-timepicker>
|
|
3082
|
-
`, isInline: true, styles: ["\n kendo-datepicker,\n kendo-timepicker {\n width: 170px;\n }\n "], components: [{ type:
|
|
3105
|
+
`, isInline: true, styles: ["\n kendo-datepicker,\n kendo-timepicker {\n width: 170px;\n }\n "], components: [{ type: i5.DatePickerComponent, selector: "kendo-datepicker", inputs: ["cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "headerTitleTemplate", "navigationItemTemplate", "focusableId", "activeView", "bottomView", "topView", "calendarType", "animateCalendarNavigation", "disabled", "readonly", "readOnlyInput", "popupSettings", "navigation", "min", "max", "incompleteDateValidation", "focusedDate", "value", "format", "twoDigitYearMax", "formatPlaceholder", "placeholder", "tabindex", "tabIndex", "disabledDates", "title", "rangeValidation", "disabledDatesValidation", "weekNumber", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur", "open", "close"], exportAs: ["kendo-datepicker"] }, { type: i5.TimePickerComponent, selector: "kendo-timepicker", inputs: ["focusableId", "disabled", "readonly", "readOnlyInput", "format", "formatPlaceholder", "placeholder", "min", "max", "incompleteDateValidation", "cancelButton", "nowButton", "steps", "popupSettings", "tabindex", "tabIndex", "title", "rangeValidation", "value", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur", "open", "close"], exportAs: ["kendo-timepicker"] }], directives: [{ type: i11.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
3083
3106
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SchedulerDateTimePickerComponent, decorators: [{
|
|
3084
3107
|
type: Component,
|
|
3085
3108
|
args: [{
|
|
@@ -4513,7 +4536,7 @@ RecurrenceEndRuleEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion:
|
|
|
4513
4536
|
</li>
|
|
4514
4537
|
</ul>
|
|
4515
4538
|
</div>
|
|
4516
|
-
`, isInline: true, components: [{ type: i12.NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur"], exportAs: ["kendoNumericTextBox"] }, { type:
|
|
4539
|
+
`, isInline: true, components: [{ type: i12.NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur"], exportAs: ["kendoNumericTextBox"] }, { type: i5.DatePickerComponent, selector: "kendo-datepicker", inputs: ["cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "headerTitleTemplate", "navigationItemTemplate", "focusableId", "activeView", "bottomView", "topView", "calendarType", "animateCalendarNavigation", "disabled", "readonly", "readOnlyInput", "popupSettings", "navigation", "min", "max", "incompleteDateValidation", "focusedDate", "value", "format", "twoDigitYearMax", "formatPlaceholder", "placeholder", "tabindex", "tabIndex", "disabledDates", "title", "rangeValidation", "disabledDatesValidation", "weekNumber", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur", "open", "close"], exportAs: ["kendo-datepicker"] }], directives: [{ type: EndRuleRadioButtonDirective, selector: "[kendoRecurrenceEndRuleRadioButton]", inputs: ["kendoRecurrenceEndRuleRadioButton"] }] });
|
|
4517
4540
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: RecurrenceEndRuleEditorComponent, decorators: [{
|
|
4518
4541
|
type: Component,
|
|
4519
4542
|
args: [{
|
|
@@ -8301,7 +8324,7 @@ class AgendaViewInternalComponent {
|
|
|
8301
8324
|
this.tasks.next(tasks);
|
|
8302
8325
|
}));
|
|
8303
8326
|
this.subs.add(this.viewContext.optionsChange.subscribe(this.optionsChange.bind(this)));
|
|
8304
|
-
const onStable = () => this.zone.onStable.pipe(take
|
|
8327
|
+
const onStable = () => this.zone.onStable.pipe(take(1));
|
|
8305
8328
|
this.subs.add(combineLatest(this.tasks, this.localization.changes).pipe(switchMap(onStable))
|
|
8306
8329
|
.subscribe(this.updateContentHeight));
|
|
8307
8330
|
this.subs.add(this.pdfService.createElement.subscribe(this.createPDFElement.bind(this)));
|
|
@@ -8909,8 +8932,7 @@ class BaseViewItem {
|
|
|
8909
8932
|
right: this.localization.rtl ? `${rect.left}px` : '',
|
|
8910
8933
|
top: `${rect.top}px`,
|
|
8911
8934
|
width: `${rect.width}px`,
|
|
8912
|
-
height: `${rect.height}px
|
|
8913
|
-
display: 'block'
|
|
8935
|
+
height: `${rect.height}px`
|
|
8914
8936
|
});
|
|
8915
8937
|
}
|
|
8916
8938
|
}
|
|
@@ -8921,7 +8943,6 @@ class BaseViewItem {
|
|
|
8921
8943
|
this.subs.add(this.slotService.slotsChange.subscribe(() => {
|
|
8922
8944
|
this.rect = null;
|
|
8923
8945
|
this.setStyles({
|
|
8924
|
-
display: 'none',
|
|
8925
8946
|
width: 0,
|
|
8926
8947
|
left: 0
|
|
8927
8948
|
});
|
|
@@ -9331,6 +9352,9 @@ class MonthViewItemComponent extends BaseViewItem {
|
|
|
9331
9352
|
this.toggle(false);
|
|
9332
9353
|
return;
|
|
9333
9354
|
}
|
|
9355
|
+
else {
|
|
9356
|
+
this.toggle(true);
|
|
9357
|
+
}
|
|
9334
9358
|
super.reflow();
|
|
9335
9359
|
}
|
|
9336
9360
|
}
|
|
@@ -9666,7 +9690,7 @@ class BaseView {
|
|
|
9666
9690
|
}
|
|
9667
9691
|
}
|
|
9668
9692
|
onStable() {
|
|
9669
|
-
return this.zone.onStable.asObservable().pipe(take
|
|
9693
|
+
return this.zone.onStable.asObservable().pipe(take(1));
|
|
9670
9694
|
}
|
|
9671
9695
|
updateView() {
|
|
9672
9696
|
this.slotService.invalidate();
|
|
@@ -11346,10 +11370,12 @@ class ViewFooterComponent {
|
|
|
11346
11370
|
}
|
|
11347
11371
|
ViewFooterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ViewFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
11348
11372
|
ViewFooterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ViewFooterComponent, selector: "[viewFooter]", inputs: { items: "items" }, outputs: { itemClick: "itemClick" }, host: { properties: { "class.k-scheduler-footer": "this.hostClasses", "class.k-toolbar": "this.hostClasses", "style.justify-content": "this.inlineJustifyContentStyle" } }, ngImport: i0, template: `
|
|
11349
|
-
<
|
|
11350
|
-
<
|
|
11351
|
-
|
|
11352
|
-
|
|
11373
|
+
<span class="k-scheduler-navigation">
|
|
11374
|
+
<button type="button" kendoButton *ngFor="let item of items" [ngClass]="item.cssClass" (click)="onItemClick($event, item)">
|
|
11375
|
+
<span class="k-button-icon k-icon" [ngClass]="item.iconClass"></span>
|
|
11376
|
+
<span class="k-button-text">{{ item.text }}</span>
|
|
11377
|
+
</button>
|
|
11378
|
+
</span>
|
|
11353
11379
|
`, isInline: true, directives: [{ type: i11.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { type: i11.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
11354
11380
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ViewFooterComponent, decorators: [{
|
|
11355
11381
|
type: Component,
|
|
@@ -11357,10 +11383,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
11357
11383
|
// eslint-disable-next-line @angular-eslint/component-selector
|
|
11358
11384
|
selector: '[viewFooter]',
|
|
11359
11385
|
template: `
|
|
11360
|
-
<
|
|
11361
|
-
<
|
|
11362
|
-
|
|
11363
|
-
|
|
11386
|
+
<span class="k-scheduler-navigation">
|
|
11387
|
+
<button type="button" kendoButton *ngFor="let item of items" [ngClass]="item.cssClass" (click)="onItemClick($event, item)">
|
|
11388
|
+
<span class="k-button-icon k-icon" [ngClass]="item.iconClass"></span>
|
|
11389
|
+
<span class="k-button-text">{{ item.text }}</span>
|
|
11390
|
+
</button>
|
|
11391
|
+
</span>
|
|
11364
11392
|
`
|
|
11365
11393
|
}]
|
|
11366
11394
|
}], propDecorators: { hostClasses: [{
|
|
@@ -15892,7 +15920,7 @@ class ShortcutsDirective {
|
|
|
15892
15920
|
}
|
|
15893
15921
|
}
|
|
15894
15922
|
focusWait() {
|
|
15895
|
-
this.viewState.layoutEnd.pipe(take
|
|
15923
|
+
this.viewState.layoutEnd.pipe(take(1)).subscribe(() => this.focusService.focus());
|
|
15896
15924
|
}
|
|
15897
15925
|
}
|
|
15898
15926
|
ShortcutsDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ShortcutsDirective, deps: [{ token: SchedulerComponent }, { token: DomEventsService }, { token: FocusService }, { token: i0.NgZone }, { token: i0.ChangeDetectorRef }, { token: ViewStateService }, { token: DialogsService }], target: i0.ɵɵFactoryTarget.Directive });
|
package/package.json
CHANGED
|
@@ -8,7 +8,16 @@ import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
|
8
8
|
import { ToolbarService } from './toolbar.service';
|
|
9
9
|
import { ToolbarContext } from './toolbar-context';
|
|
10
10
|
import { CalendarComponent } from '@progress/kendo-angular-dateinputs';
|
|
11
|
+
import { ViewContextService } from '../views/view-context.service';
|
|
11
12
|
import * as i0 from "@angular/core";
|
|
13
|
+
/**
|
|
14
|
+
* @hidden
|
|
15
|
+
*/
|
|
16
|
+
interface DateRangeText {
|
|
17
|
+
short: string;
|
|
18
|
+
long: string;
|
|
19
|
+
current: string;
|
|
20
|
+
}
|
|
12
21
|
/**
|
|
13
22
|
* A toolbar component which contains the controls for date navigation
|
|
14
23
|
* ([see example]({% slug toolbar_scheduler %}#toc-including-the-built-in-components)).
|
|
@@ -29,6 +38,8 @@ export declare class ToolbarNavigationComponent implements OnDestroy {
|
|
|
29
38
|
private popupService;
|
|
30
39
|
private toolbarService;
|
|
31
40
|
private localization;
|
|
41
|
+
private cd;
|
|
42
|
+
private viewContext;
|
|
32
43
|
set calendar(calendar: CalendarComponent);
|
|
33
44
|
/**
|
|
34
45
|
* @hidden
|
|
@@ -73,13 +84,18 @@ export declare class ToolbarNavigationComponent implements OnDestroy {
|
|
|
73
84
|
* @hidden
|
|
74
85
|
*/
|
|
75
86
|
get ctx(): ToolbarContext;
|
|
87
|
+
/**
|
|
88
|
+
* @hidden
|
|
89
|
+
*/
|
|
90
|
+
dateRangeText: DateRangeText;
|
|
76
91
|
private popupRef;
|
|
77
92
|
private subs;
|
|
78
|
-
constructor(popupService: PopupService, toolbarService: ToolbarService, localization: LocalizationService, cd: ChangeDetectorRef);
|
|
93
|
+
constructor(popupService: PopupService, toolbarService: ToolbarService, localization: LocalizationService, cd: ChangeDetectorRef, viewContext: ViewContextService);
|
|
79
94
|
/**
|
|
80
95
|
* @hidden
|
|
81
96
|
*/
|
|
82
97
|
onBlur(): void;
|
|
98
|
+
ngOnInit(): void;
|
|
83
99
|
ngOnDestroy(): void;
|
|
84
100
|
/**
|
|
85
101
|
* @hidden
|
|
@@ -102,6 +118,8 @@ export declare class ToolbarNavigationComponent implements OnDestroy {
|
|
|
102
118
|
*/
|
|
103
119
|
todayClick(): boolean;
|
|
104
120
|
protected closePopup(): void;
|
|
121
|
+
private setDateRangeText;
|
|
105
122
|
static ɵfac: i0.ɵɵFactoryDeclaration<ToolbarNavigationComponent, never>;
|
|
106
123
|
static ɵcmp: i0.ɵɵComponentDeclaration<ToolbarNavigationComponent, "[kendoSchedulerToolbarNavigation]", never, { "min": "min"; "max": "max"; }, {}, never, never>;
|
|
107
124
|
}
|
|
125
|
+
export {};
|