@progress/kendo-angular-scheduler 21.4.1-develop.1 → 22.0.0-develop.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/editing/recurrence/localization/messages.d.ts +1 -1
- package/editing/resource-editor-base.d.ts +1 -1
- package/editing-directives/editing-directive-base.d.ts +1 -1
- package/fesm2022/progress-kendo-angular-scheduler.mjs +313 -313
- package/localization/messages.d.ts +1 -1
- package/package.json +20 -28
- package/schematics/ngAdd/index.js +3 -3
- package/views/common/base-view.d.ts +1 -1
- package/views/common/configuration-view-base.d.ts +1 -1
- package/views/day-time/day-time-view-base.d.ts +1 -1
- package/views/day-time/day-time-view.component.d.ts +1 -1
- package/views/multi-day/multi-day-view-base.d.ts +1 -1
- package/views/timeline/timeline-base.d.ts +1 -1
- package/views/view-items/base-slot.directive.d.ts +1 -1
- package/views/view-items/base-view-item.d.ts +1 -1
- package/esm2022/common/constants.mjs +0 -8
- package/esm2022/common/default-model-fields.mjs +0 -20
- package/esm2022/common/dom-queries.mjs +0 -107
- package/esm2022/common/modifiers.mjs +0 -31
- package/esm2022/common/util.mjs +0 -227
- package/esm2022/data-binding.directive.mjs +0 -162
- package/esm2022/directives.mjs +0 -136
- package/esm2022/editing/date-time-picker.component.mjs +0 -190
- package/esm2022/editing/dialogs.service.mjs +0 -96
- package/esm2022/editing/edit-dialog-template.directive.mjs +0 -53
- package/esm2022/editing/edit-dialog.component.mjs +0 -679
- package/esm2022/editing/edit.service.mjs +0 -107
- package/esm2022/editing/local-data-changes.service.mjs +0 -18
- package/esm2022/editing/recurrence/end-rule-radio-button.directive.mjs +0 -77
- package/esm2022/editing/recurrence/localization/custom-messages.component.mjs +0 -44
- package/esm2022/editing/recurrence/localization/localized-messages.directive.mjs +0 -39
- package/esm2022/editing/recurrence/localization/messages.mjs +0 -239
- package/esm2022/editing/recurrence/localization/recurrence-localization.service.mjs +0 -47
- package/esm2022/editing/recurrence/recurrence-editor.component.mjs +0 -497
- package/esm2022/editing/recurrence/recurrence-end-rule-editor.component.mjs +0 -334
- package/esm2022/editing/recurrence/recurrence-frequency-editor.component.mjs +0 -105
- package/esm2022/editing/recurrence/recurrence-interval-editor.component.mjs +0 -169
- package/esm2022/editing/recurrence/recurrence-monthly-yearly-editor.component.mjs +0 -468
- package/esm2022/editing/recurrence/recurrence-weekday-rule-editor.component.mjs +0 -138
- package/esm2022/editing/recurrence/recurrence.service.mjs +0 -254
- package/esm2022/editing/recurrence/repeat-on-radio-button.directive.mjs +0 -81
- package/esm2022/editing/resource-editor-base.mjs +0 -59
- package/esm2022/editing/resource-multiple-editor.component.mjs +0 -101
- package/esm2022/editing/resource-single-editor.component.mjs +0 -82
- package/esm2022/editing/timezone-editor.component.mjs +0 -193
- package/esm2022/editing-directives/base-edit.service.mjs +0 -320
- package/esm2022/editing-directives/edit-service.interface.mjs +0 -5
- package/esm2022/editing-directives/editing-directive-base.mjs +0 -242
- package/esm2022/editing-directives/local-edit.service.mjs +0 -122
- package/esm2022/editing-directives/reactive-editing.directive.mjs +0 -132
- package/esm2022/editing-directives/utils.mjs +0 -107
- package/esm2022/events/add-event.mjs +0 -26
- package/esm2022/events/cancel-event.mjs +0 -14
- package/esm2022/events/create-event.mjs +0 -40
- package/esm2022/events/date-change-event.mjs +0 -29
- package/esm2022/events/drag-end-event.mjs +0 -46
- package/esm2022/events/drag-event.mjs +0 -54
- package/esm2022/events/drag-start-event.mjs +0 -30
- package/esm2022/events/edit-event-base.mjs +0 -32
- package/esm2022/events/edit-event.mjs +0 -30
- package/esm2022/events/event-click-event.mjs +0 -32
- package/esm2022/events/event-keydown-event.mjs +0 -28
- package/esm2022/events/more-events-click.mjs +0 -24
- package/esm2022/events/navigate-event.mjs +0 -26
- package/esm2022/events/preventable-event.mjs +0 -28
- package/esm2022/events/remove-event.mjs +0 -30
- package/esm2022/events/resize-end-event.mjs +0 -38
- package/esm2022/events/resize-event.mjs +0 -46
- package/esm2022/events/resize-start-event.mjs +0 -30
- package/esm2022/events/save-event.mjs +0 -18
- package/esm2022/events/slot-click-event.mjs +0 -44
- package/esm2022/events/slot-drag-end-event.mjs +0 -10
- package/esm2022/events/slot-drag-event.mjs +0 -40
- package/esm2022/events/slot-drag-start-event.mjs +0 -44
- package/esm2022/events/view-event-map.mjs +0 -35
- package/esm2022/events.mjs +0 -27
- package/esm2022/index.mjs +0 -83
- package/esm2022/loading.component.mjs +0 -52
- package/esm2022/localization/custom-messages.component.mjs +0 -56
- package/esm2022/localization/localized-messages.directive.mjs +0 -39
- package/esm2022/localization/messages.mjs +0 -614
- package/esm2022/localization/scheduler-localization.service.mjs +0 -31
- package/esm2022/navigation/focus-position.interface.mjs +0 -5
- package/esm2022/navigation/focus.service.mjs +0 -202
- package/esm2022/navigation/focusable-element.interface.mjs +0 -5
- package/esm2022/navigation/focusable.directive.mjs +0 -98
- package/esm2022/navigation/shortcuts.directive.mjs +0 -239
- package/esm2022/navigation.mjs +0 -6
- package/esm2022/package-metadata.mjs +0 -16
- package/esm2022/pdf/pdf-command.directive.mjs +0 -96
- package/esm2022/pdf/pdf-export-event.mjs +0 -10
- package/esm2022/pdf/pdf.component.mjs +0 -241
- package/esm2022/pdf/pdf.module.mjs +0 -42
- package/esm2022/pdf/pdf.service.mjs +0 -36
- package/esm2022/progress-kendo-angular-scheduler.mjs +0 -8
- package/esm2022/scheduler.component.mjs +0 -1981
- package/esm2022/scheduler.module.mjs +0 -138
- package/esm2022/toolbar/navigation.component.mjs +0 -391
- package/esm2022/toolbar/toolbar-context.mjs +0 -5
- package/esm2022/toolbar/toolbar-template.directive.mjs +0 -50
- package/esm2022/toolbar/toolbar.component.mjs +0 -168
- package/esm2022/toolbar/toolbar.service.mjs +0 -46
- package/esm2022/toolbar/view-selector.component.mjs +0 -181
- package/esm2022/types/actions.mjs +0 -5
- package/esm2022/types/create-form-group-args.interface.mjs +0 -5
- package/esm2022/types/crud-operation.enum.mjs +0 -18
- package/esm2022/types/current-time-settings.interface.mjs +0 -5
- package/esm2022/types/date-range.interface.mjs +0 -5
- package/esm2022/types/datepicker-options.interface.mjs +0 -5
- package/esm2022/types/edit-event-args.interface.mjs +0 -5
- package/esm2022/types/edit-mode.enum.mjs +0 -23
- package/esm2022/types/editable-settings.interface.mjs +0 -5
- package/esm2022/types/event-style-args.interface.mjs +0 -5
- package/esm2022/types/focusable-container.mjs +0 -5
- package/esm2022/types/group.interface.mjs +0 -5
- package/esm2022/types/numeric-options.interface.mjs +0 -5
- package/esm2022/types/ongoing-events-settings.interface.mjs +0 -5
- package/esm2022/types/resource.interface.mjs +0 -5
- package/esm2022/types/scheduler-event.mjs +0 -5
- package/esm2022/types/scheduler-model-fields.interface.mjs +0 -5
- package/esm2022/types/scheduler-slot.interface.mjs +0 -5
- package/esm2022/types/scheduler-view.mjs +0 -9
- package/esm2022/types/slot-class-args.interface.mjs +0 -5
- package/esm2022/types/slot-selection.mjs +0 -35
- package/esm2022/types/view-item.interface.mjs +0 -5
- package/esm2022/types.mjs +0 -12
- package/esm2022/views/agenda/agenda-header-item.component.mjs +0 -85
- package/esm2022/views/agenda/agenda-header.component.mjs +0 -75
- package/esm2022/views/agenda/agenda-task-item.component.mjs +0 -137
- package/esm2022/views/agenda/agenda-view-internal.component.mjs +0 -424
- package/esm2022/views/agenda/agenda-view-list.component.mjs +0 -256
- package/esm2022/views/agenda/agenda-view.component.mjs +0 -130
- package/esm2022/views/agenda/tasks.collection.mjs +0 -96
- package/esm2022/views/agenda/utils.mjs +0 -176
- package/esm2022/views/common/base-view.mjs +0 -1099
- package/esm2022/views/common/configuration-view-base.mjs +0 -164
- package/esm2022/views/common/dom-events.service.mjs +0 -22
- package/esm2022/views/common/hint-container.component.mjs +0 -41
- package/esm2022/views/common/repeat.pipe.mjs +0 -36
- package/esm2022/views/common/resize-hint.component.mjs +0 -97
- package/esm2022/views/common/resource-iterator.pipe.mjs +0 -49
- package/esm2022/views/common/scheduler-task.mjs +0 -5
- package/esm2022/views/common/slot-selectable.directive.mjs +0 -137
- package/esm2022/views/common/view-footer.component.mjs +0 -103
- package/esm2022/views/common/work-hours-footer.directive.mjs +0 -45
- package/esm2022/views/constants.mjs +0 -31
- package/esm2022/views/day-time/day-time-slot.service.mjs +0 -633
- package/esm2022/views/day-time/day-time-view-base.mjs +0 -244
- package/esm2022/views/day-time/day-time-view-item.component.mjs +0 -216
- package/esm2022/views/day-time/day-time-view.component.mjs +0 -437
- package/esm2022/views/day-time/event-slot.directive.mjs +0 -138
- package/esm2022/views/day-time/utils.mjs +0 -32
- package/esm2022/views/month/month-slot.component.mjs +0 -166
- package/esm2022/views/month/month-slot.service.mjs +0 -404
- package/esm2022/views/month/month-view-item.component.mjs +0 -161
- package/esm2022/views/month/month-view-renderer.component.mjs +0 -683
- package/esm2022/views/month/month-view.component.mjs +0 -203
- package/esm2022/views/month/multi-week-view.component.mjs +0 -202
- package/esm2022/views/month/utils.mjs +0 -107
- package/esm2022/views/multi-day/day-view.component.mjs +0 -186
- package/esm2022/views/multi-day/multi-day-view-base.mjs +0 -55
- package/esm2022/views/multi-day/multi-day-view-renderer.component.mjs +0 -1002
- package/esm2022/views/multi-day/multi-day-view.component.mjs +0 -197
- package/esm2022/views/multi-day/utils.mjs +0 -63
- package/esm2022/views/multi-day/week-view.component.mjs +0 -189
- package/esm2022/views/multi-day/work-week-view.component.mjs +0 -172
- package/esm2022/views/scheduler-view.directive.mjs +0 -65
- package/esm2022/views/templates/agenda-date-template.directive.mjs +0 -41
- package/esm2022/views/templates/agenda-time-template.directive.mjs +0 -46
- package/esm2022/views/templates/all-day-event-template.directive.mjs +0 -42
- package/esm2022/views/templates/all-day-slot-template.directive.mjs +0 -42
- package/esm2022/views/templates/date-header-template.directive.mjs +0 -42
- package/esm2022/views/templates/event-template.directive.mjs +0 -42
- package/esm2022/views/templates/group-header-template.directive.mjs +0 -42
- package/esm2022/views/templates/major-time-header-template.directive.mjs +0 -41
- package/esm2022/views/templates/minor-time-header-template.directive.mjs +0 -41
- package/esm2022/views/templates/month-day-slot-template.directive.mjs +0 -42
- package/esm2022/views/templates/multi-week-day-slot-template.directive.mjs +0 -42
- package/esm2022/views/templates/time-slot-template.directive.mjs +0 -43
- package/esm2022/views/templates.mjs +0 -16
- package/esm2022/views/timeline/timeline-base.mjs +0 -39
- package/esm2022/views/timeline/timeline-month-view.component.mjs +0 -211
- package/esm2022/views/timeline/timeline-multi-day-view.component.mjs +0 -649
- package/esm2022/views/timeline/timeline-view.component.mjs +0 -189
- package/esm2022/views/timeline/timeline-week-view.component.mjs +0 -181
- package/esm2022/views/timeline/utils.mjs +0 -60
- package/esm2022/views/utils.mjs +0 -373
- package/esm2022/views/view-context.service.mjs +0 -111
- package/esm2022/views/view-items/base-slot.directive.mjs +0 -104
- package/esm2022/views/view-items/base-slot.service.mjs +0 -82
- package/esm2022/views/view-items/base-view-item.mjs +0 -194
- package/esm2022/views/view-items/item-map.mjs +0 -38
- package/esm2022/views/view-items/types.mjs +0 -5
- package/esm2022/views/view-state.service.mjs +0 -144
- package/esm2022/views/year/utils.mjs +0 -60
- package/esm2022/views/year/year-view-internal.component.mjs +0 -471
- package/esm2022/views/year/year-view.component.mjs +0 -136
|
@@ -1,424 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Component, Input, ViewChild, ElementRef, NgZone, Renderer2, TemplateRef } from '@angular/core';
|
|
6
|
-
import { anyChanged } from '@progress/kendo-angular-common';
|
|
7
|
-
import { IntlService } from '@progress/kendo-angular-intl';
|
|
8
|
-
import { addDays, getDate } from '@progress/kendo-date-math';
|
|
9
|
-
import { Subscription, BehaviorSubject, combineLatest, fromEvent, merge } from 'rxjs';
|
|
10
|
-
import { switchMap, take, map } from 'rxjs/operators';
|
|
11
|
-
import { ViewContextService } from '../view-context.service';
|
|
12
|
-
import { ViewStateService } from '../view-state.service';
|
|
13
|
-
import { hasScrollbar, closestInScope, hasClasses } from '../../common/dom-queries';
|
|
14
|
-
import { createResourceGroups, groupEvents } from './utils';
|
|
15
|
-
import { ignoreContentChild, elementOffset } from '../utils';
|
|
16
|
-
import { PDFService } from '../../pdf/pdf.service';
|
|
17
|
-
import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
18
|
-
import { AsyncPipe } from '@angular/common';
|
|
19
|
-
import { AgendaListComponent } from './agenda-view-list.component';
|
|
20
|
-
import { AgendaHeaderComponent } from './agenda-header.component';
|
|
21
|
-
import * as i0 from "@angular/core";
|
|
22
|
-
import * as i1 from "../view-context.service";
|
|
23
|
-
import * as i2 from "../view-state.service";
|
|
24
|
-
import * as i3 from "@progress/kendo-angular-intl";
|
|
25
|
-
import * as i4 from "../../pdf/pdf.service";
|
|
26
|
-
import * as i5 from "@progress/kendo-angular-l10n";
|
|
27
|
-
/**
|
|
28
|
-
* @hidden
|
|
29
|
-
*/
|
|
30
|
-
export class AgendaViewInternalComponent {
|
|
31
|
-
viewContext;
|
|
32
|
-
viewState;
|
|
33
|
-
intl;
|
|
34
|
-
renderer;
|
|
35
|
-
element;
|
|
36
|
-
zone;
|
|
37
|
-
pdfService;
|
|
38
|
-
localization;
|
|
39
|
-
selectedDate;
|
|
40
|
-
hiddenDays;
|
|
41
|
-
eventTemplate;
|
|
42
|
-
slotClass;
|
|
43
|
-
eventClass;
|
|
44
|
-
eventStyles;
|
|
45
|
-
agendaTimeTemplate;
|
|
46
|
-
agendaDateTemplate;
|
|
47
|
-
selectedDateFormat;
|
|
48
|
-
selectedShortDateFormat;
|
|
49
|
-
numberOfDays;
|
|
50
|
-
headerWrap;
|
|
51
|
-
content;
|
|
52
|
-
tasks = new BehaviorSubject(null);
|
|
53
|
-
groupedResources = [];
|
|
54
|
-
editable;
|
|
55
|
-
get eventTemplateRef() {
|
|
56
|
-
return this.eventTemplate || (this.schedulerEventTemplate || {}).templateRef;
|
|
57
|
-
}
|
|
58
|
-
get agendaTimeTemplateRef() {
|
|
59
|
-
return this.agendaTimeTemplate || (this.schedulerAgendaTimeTemplate || {}).templateRef;
|
|
60
|
-
}
|
|
61
|
-
get agendaDateTemplateRef() {
|
|
62
|
-
return this.agendaDateTemplate || (this.schedulerAgendaDateTemplate || {}).templateRef;
|
|
63
|
-
}
|
|
64
|
-
schedulerEventTemplate;
|
|
65
|
-
schedulerAgendaTimeTemplate;
|
|
66
|
-
schedulerAgendaDateTemplate;
|
|
67
|
-
group;
|
|
68
|
-
resources;
|
|
69
|
-
spans = [];
|
|
70
|
-
items;
|
|
71
|
-
range;
|
|
72
|
-
groups;
|
|
73
|
-
min;
|
|
74
|
-
max;
|
|
75
|
-
subs = new Subscription();
|
|
76
|
-
constructor(viewContext, viewState, intl, renderer, element, zone, pdfService, localization) {
|
|
77
|
-
this.viewContext = viewContext;
|
|
78
|
-
this.viewState = viewState;
|
|
79
|
-
this.intl = intl;
|
|
80
|
-
this.renderer = renderer;
|
|
81
|
-
this.element = element;
|
|
82
|
-
this.zone = zone;
|
|
83
|
-
this.pdfService = pdfService;
|
|
84
|
-
this.localization = localization;
|
|
85
|
-
}
|
|
86
|
-
ngOnInit() {
|
|
87
|
-
this.updateContentHeight = this.updateContentHeight.bind(this);
|
|
88
|
-
this.subs.add(this.viewContext.selectedDate.subscribe(this.onSelectDate.bind(this)));
|
|
89
|
-
this.subs.add(this.viewContext.action.subscribe(this.onAction.bind(this)));
|
|
90
|
-
this.subs.add(this.viewContext.execute.subscribe(this.execute.bind(this)));
|
|
91
|
-
this.subs.add(this.viewContext.resize.subscribe(this.updateContentHeight));
|
|
92
|
-
this.subs.add(combineLatest([
|
|
93
|
-
this.viewContext.items,
|
|
94
|
-
this.viewState.dateRange
|
|
95
|
-
]).pipe(map(([items, dateRange]) => {
|
|
96
|
-
this.items = items;
|
|
97
|
-
this.range = dateRange;
|
|
98
|
-
return this.createEventGroups();
|
|
99
|
-
}))
|
|
100
|
-
.subscribe((tasks) => {
|
|
101
|
-
this.tasks.next(tasks);
|
|
102
|
-
}));
|
|
103
|
-
this.subs.add(this.viewContext.optionsChange.subscribe(this.optionsChange.bind(this)));
|
|
104
|
-
const onStable = () => this.zone.onStable.pipe(take(1));
|
|
105
|
-
this.subs.add(combineLatest(this.tasks, this.localization.changes).pipe(switchMap(onStable))
|
|
106
|
-
.subscribe(this.updateContentHeight));
|
|
107
|
-
this.subs.add(this.pdfService.createElement.subscribe(this.createPDFElement.bind(this)));
|
|
108
|
-
}
|
|
109
|
-
ngOnChanges(changes) {
|
|
110
|
-
if (anyChanged(['selectedDateFormat', 'selectedShortDateFormat', 'numberOfDays', 'hiddenDays'], changes)) {
|
|
111
|
-
this.viewState.notifyDateRange(this.dateRange(this.selectedDate));
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
ngAfterViewInit() {
|
|
115
|
-
if (!this.element) {
|
|
116
|
-
return;
|
|
117
|
-
}
|
|
118
|
-
const contentElement = this.content.nativeElement;
|
|
119
|
-
this.zone.runOutsideAngular(() => {
|
|
120
|
-
this.subs.add(merge(fromEvent(contentElement, 'click'), fromEvent(contentElement, 'contextmenu'), fromEvent(contentElement, 'dblclick'))
|
|
121
|
-
.subscribe(e => this.onClick(e)));
|
|
122
|
-
this.subs.add(fromEvent(contentElement, 'keydown')
|
|
123
|
-
.subscribe(e => this.onKeydown(e)));
|
|
124
|
-
});
|
|
125
|
-
}
|
|
126
|
-
onClick(e) {
|
|
127
|
-
const targetTask = this.targetTask(e.target);
|
|
128
|
-
if (targetTask) {
|
|
129
|
-
const { task, eventTarget } = targetTask;
|
|
130
|
-
const eventType = e.type;
|
|
131
|
-
const isSingle = eventType === 'click';
|
|
132
|
-
const isDouble = eventType === 'dblclick';
|
|
133
|
-
if (isSingle && closestInScope(e.target, node => hasClasses(node, 'k-event-delete'), eventTarget)) {
|
|
134
|
-
this.viewState.emitEvent('remove', { event: task.event, dataItem: task.event.dataItem });
|
|
135
|
-
}
|
|
136
|
-
else {
|
|
137
|
-
const name = isDouble ? 'eventDblClick' : 'eventClick';
|
|
138
|
-
this.viewState.emitEvent(name, { type: eventType, event: task.event, originalEvent: e });
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
onKeydown(e) {
|
|
143
|
-
const targetTask = this.targetTask(e.target);
|
|
144
|
-
if (targetTask) {
|
|
145
|
-
const task = targetTask.task;
|
|
146
|
-
this.viewState.emitEvent('eventKeydown', { event: task.event, dataItem: task.event.dataItem, originalEvent: e });
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
targetTask(target) {
|
|
150
|
-
const eventTarget = closestInScope(target, node => node.hasAttribute('data-task-index'), this.element.nativeElement);
|
|
151
|
-
if (eventTarget) {
|
|
152
|
-
return {
|
|
153
|
-
eventTarget,
|
|
154
|
-
task: this.elementTask(eventTarget)
|
|
155
|
-
};
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
updateContentHeight() {
|
|
159
|
-
const element = this.element.nativeElement;
|
|
160
|
-
const parent = element.parentNode;
|
|
161
|
-
const content = this.content.nativeElement;
|
|
162
|
-
this.renderer.setStyle(content, 'height', '');
|
|
163
|
-
let height = parent.clientHeight;
|
|
164
|
-
for (let idx = 0; idx < parent.children.length; idx++) {
|
|
165
|
-
const child = parent.children[idx];
|
|
166
|
-
if (child !== element && !ignoreContentChild(child)) {
|
|
167
|
-
height -= child.offsetHeight;
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
const headerElement = this.headerWrap.nativeElement;
|
|
171
|
-
height -= this.headerWrap ? headerElement.offsetHeight : 0;
|
|
172
|
-
this.renderer.setStyle(content, 'height', `${height}px`);
|
|
173
|
-
const rtl = this.localization.rtl;
|
|
174
|
-
// Need to explicitly set 'padding-inline-xxx' to 0px when the Scheduler has no height set
|
|
175
|
-
if (!hasScrollbar(content, 'vertical')) {
|
|
176
|
-
this.renderer.setStyle(headerElement, !rtl ? 'padding-inline-end' : 'padding-inline-start', '0px');
|
|
177
|
-
}
|
|
178
|
-
this.renderer.removeStyle(headerElement, rtl ? 'padding-inline-end' : 'padding-inline-start');
|
|
179
|
-
this.viewState.notifyLayoutEnd();
|
|
180
|
-
}
|
|
181
|
-
ngOnDestroy() {
|
|
182
|
-
this.subs.unsubscribe();
|
|
183
|
-
}
|
|
184
|
-
optionsChange(changes) {
|
|
185
|
-
this.group = changes.group;
|
|
186
|
-
this.resources = changes.resources;
|
|
187
|
-
this.groupResources();
|
|
188
|
-
this.min = changes.min;
|
|
189
|
-
this.max = changes.max;
|
|
190
|
-
this.editable = changes.editable;
|
|
191
|
-
if (this.items && this.items.length) {
|
|
192
|
-
this.tasks.next(this.createEventGroups());
|
|
193
|
-
}
|
|
194
|
-
this.schedulerEventTemplate = changes.eventTemplate;
|
|
195
|
-
this.schedulerAgendaTimeTemplate = changes.agendaTimeTemplate;
|
|
196
|
-
this.schedulerAgendaDateTemplate = changes.agendaDateTemplate;
|
|
197
|
-
}
|
|
198
|
-
onSelectDate(date) {
|
|
199
|
-
this.selectedDate = date;
|
|
200
|
-
this.viewState.notifyDateRange(this.dateRange());
|
|
201
|
-
}
|
|
202
|
-
onAction(e) {
|
|
203
|
-
const now = getDate(this.selectedDate);
|
|
204
|
-
if (e.type === 'next') {
|
|
205
|
-
const next = getDate(addDays(now, this.numberOfDays));
|
|
206
|
-
if (this.isInRange(next)) {
|
|
207
|
-
this.viewState.notifyNextDate(next);
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
if (e.type === 'prev') {
|
|
211
|
-
const next = getDate(addDays(now, -this.numberOfDays));
|
|
212
|
-
if (this.isInRange(next)) {
|
|
213
|
-
this.viewState.notifyNextDate(next);
|
|
214
|
-
}
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
createEventGroups() {
|
|
218
|
-
const resourceGroups = this.groupedResources.length ? createResourceGroups(this.groupedResources) : null;
|
|
219
|
-
const eventGroups = this.groups = groupEvents(this.items, {
|
|
220
|
-
taskResources: this.taskResources,
|
|
221
|
-
resourceGroups,
|
|
222
|
-
allResources: this.resources,
|
|
223
|
-
spans: this.spans,
|
|
224
|
-
dateRange: this.range,
|
|
225
|
-
hiddenDays: this.hiddenDays
|
|
226
|
-
});
|
|
227
|
-
return eventGroups;
|
|
228
|
-
}
|
|
229
|
-
dateRange(date = this.selectedDate) {
|
|
230
|
-
const start = getDate(date);
|
|
231
|
-
const end = getDate(addDays(start, this.numberOfDays));
|
|
232
|
-
const rangeEnd = getDate(addDays(start, this.numberOfDays - 1));
|
|
233
|
-
const text = this.intl.format(this.selectedDateFormat, start, rangeEnd);
|
|
234
|
-
const shortText = this.intl.format(this.selectedShortDateFormat, start, rangeEnd);
|
|
235
|
-
return { start, end, text, shortText };
|
|
236
|
-
}
|
|
237
|
-
groupResources() {
|
|
238
|
-
const resources = this.resources || [];
|
|
239
|
-
const group = this.group || {};
|
|
240
|
-
const grouped = group.resources;
|
|
241
|
-
const groupedResources = this.groupedResources = [];
|
|
242
|
-
if (grouped && grouped.length) {
|
|
243
|
-
for (let groupIdx = 0; groupIdx < grouped.length; groupIdx++) {
|
|
244
|
-
const name = grouped[groupIdx];
|
|
245
|
-
const resource = resources.find(item => item.name === name);
|
|
246
|
-
if (resource) {
|
|
247
|
-
groupedResources.push(resource);
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
}
|
|
251
|
-
this.spans = this.resourceSpans();
|
|
252
|
-
}
|
|
253
|
-
resourceSpans() {
|
|
254
|
-
const spans = [1];
|
|
255
|
-
const resources = this.groupedResources;
|
|
256
|
-
let span = 1;
|
|
257
|
-
for (let idx = resources.length - 1; idx > 0; idx--) {
|
|
258
|
-
span *= ((resources[idx].data || []).length || 1);
|
|
259
|
-
spans.unshift(span);
|
|
260
|
-
}
|
|
261
|
-
return spans;
|
|
262
|
-
}
|
|
263
|
-
get taskResources() {
|
|
264
|
-
if (this.groupedResources.length) {
|
|
265
|
-
return this.groupedResources;
|
|
266
|
-
}
|
|
267
|
-
else if (this.resources && this.resources.length) {
|
|
268
|
-
return [this.resources[0]];
|
|
269
|
-
}
|
|
270
|
-
else {
|
|
271
|
-
return [{}];
|
|
272
|
-
}
|
|
273
|
-
}
|
|
274
|
-
isInRange(date) {
|
|
275
|
-
const dateRange = this.dateRange(date);
|
|
276
|
-
return (!this.min || this.min < dateRange.end) && (!this.max || dateRange.start <= this.max);
|
|
277
|
-
}
|
|
278
|
-
createPDFElement() {
|
|
279
|
-
const element = this.element.nativeElement.cloneNode(true);
|
|
280
|
-
element.style.width = `${this.element.nativeElement.offsetWidth}px`;
|
|
281
|
-
element.querySelector('.k-scheduler-content').style.height = 'auto';
|
|
282
|
-
const header = element.querySelector('.k-scheduler-header');
|
|
283
|
-
header.style.paddingRight = 0;
|
|
284
|
-
header.style.paddingLeft = 0;
|
|
285
|
-
this.pdfService.elementReady.emit({
|
|
286
|
-
element: element
|
|
287
|
-
});
|
|
288
|
-
}
|
|
289
|
-
elementTask(element) {
|
|
290
|
-
const index = parseInt(element.getAttribute('data-task-index'), 10);
|
|
291
|
-
const groupIndex = parseInt(element.getAttribute('data-group-index'), 10);
|
|
292
|
-
const group = this.groups[groupIndex];
|
|
293
|
-
const task = group.tasks.itemAt(index);
|
|
294
|
-
return task;
|
|
295
|
-
}
|
|
296
|
-
execute(e) {
|
|
297
|
-
if (e.name === 'slotByPosition') {
|
|
298
|
-
const slot = this.slotByPosition(e.args);
|
|
299
|
-
e.result(slot);
|
|
300
|
-
}
|
|
301
|
-
else if (e.name === 'eventFromElement') {
|
|
302
|
-
const task = this.elementTask(e.args.element);
|
|
303
|
-
if (task) {
|
|
304
|
-
e.result(task.event);
|
|
305
|
-
}
|
|
306
|
-
}
|
|
307
|
-
}
|
|
308
|
-
slotByPosition({ x, y }) {
|
|
309
|
-
const contentTable = this.content.nativeElement.querySelector('table');
|
|
310
|
-
const offset = elementOffset(contentTable);
|
|
311
|
-
if (offset.top <= y && y <= offset.top + offset.height) {
|
|
312
|
-
const contentRows = contentTable.rows;
|
|
313
|
-
if (!contentRows.length) {
|
|
314
|
-
return;
|
|
315
|
-
}
|
|
316
|
-
const taskOffset = elementOffset(contentRows[0].cells[contentRows[0].cells.length - 1]);
|
|
317
|
-
if (taskOffset.left <= x && x <= taskOffset.left + taskOffset.width) {
|
|
318
|
-
for (let idx = 0; idx < contentRows.length; idx++) {
|
|
319
|
-
const row = contentRows[idx];
|
|
320
|
-
const rowOffset = elementOffset(row);
|
|
321
|
-
if (rowOffset.top <= y && y <= rowOffset.top + rowOffset.height) {
|
|
322
|
-
const element = row.querySelector('[data-task-index]');
|
|
323
|
-
const task = this.elementTask(element);
|
|
324
|
-
const event = task.event;
|
|
325
|
-
return {
|
|
326
|
-
element: new ElementRef(element),
|
|
327
|
-
start: event.start,
|
|
328
|
-
end: event.end,
|
|
329
|
-
event: event,
|
|
330
|
-
resources: task.resources,
|
|
331
|
-
isAllDay: task.isAllDay
|
|
332
|
-
};
|
|
333
|
-
}
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: AgendaViewInternalComponent, deps: [{ token: i1.ViewContextService }, { token: i2.ViewStateService }, { token: i3.IntlService }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.NgZone }, { token: i4.PDFService }, { token: i5.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
339
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.14", type: AgendaViewInternalComponent, isStandalone: true, selector: "agenda-view-internal", inputs: { hiddenDays: "hiddenDays", eventTemplate: "eventTemplate", slotClass: "slotClass", eventClass: "eventClass", eventStyles: "eventStyles", agendaTimeTemplate: "agendaTimeTemplate", agendaDateTemplate: "agendaDateTemplate", selectedDateFormat: "selectedDateFormat", selectedShortDateFormat: "selectedShortDateFormat", numberOfDays: "numberOfDays" }, viewQueries: [{ propertyName: "headerWrap", first: true, predicate: ["headerWrap"], descendants: true, read: ElementRef, static: true }, { propertyName: "content", first: true, predicate: ["content"], descendants: true, read: ElementRef, static: true }], usesOnChanges: true, ngImport: i0, template: `
|
|
340
|
-
<table class="k-scheduler-layout k-scheduler-agendaview" role="grid">
|
|
341
|
-
<tbody role="none">
|
|
342
|
-
<tr class="k-scheduler-head">
|
|
343
|
-
<td>
|
|
344
|
-
<div kendoSchedulerAgendaHeader [resources]="groupedResources" #headerWrap></div>
|
|
345
|
-
</td>
|
|
346
|
-
</tr>
|
|
347
|
-
<tr class="k-scheduler-body">
|
|
348
|
-
<td>
|
|
349
|
-
<div kendoSchedulerAgendaList #content
|
|
350
|
-
[editable]="editable"
|
|
351
|
-
[eventTemplate]="eventTemplateRef"
|
|
352
|
-
[slotClass]="slotClass"
|
|
353
|
-
[eventClass]="eventClass"
|
|
354
|
-
[eventStyles]="eventStyles"
|
|
355
|
-
[agendaTimeTemplate]="agendaTimeTemplateRef"
|
|
356
|
-
[agendaDateTemplate]="agendaDateTemplateRef"
|
|
357
|
-
[tasks]="tasks | async">
|
|
358
|
-
</div>
|
|
359
|
-
</td>
|
|
360
|
-
</tr>
|
|
361
|
-
</tbody>
|
|
362
|
-
</table>
|
|
363
|
-
`, isInline: true, dependencies: [{ kind: "component", type: AgendaHeaderComponent, selector: "[kendoSchedulerAgendaHeader]", inputs: ["resources"] }, { kind: "component", type: AgendaListComponent, selector: "[kendoSchedulerAgendaList]", inputs: ["tasks", "eventTemplate", "slotClass", "eventClass", "eventStyles", "agendaTimeTemplate", "agendaDateTemplate", "editable"] }, { kind: "pipe", type: AsyncPipe, name: "async" }] });
|
|
364
|
-
}
|
|
365
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: AgendaViewInternalComponent, decorators: [{
|
|
366
|
-
type: Component,
|
|
367
|
-
args: [{
|
|
368
|
-
// eslint-disable-next-line @angular-eslint/component-selector
|
|
369
|
-
selector: 'agenda-view-internal',
|
|
370
|
-
template: `
|
|
371
|
-
<table class="k-scheduler-layout k-scheduler-agendaview" role="grid">
|
|
372
|
-
<tbody role="none">
|
|
373
|
-
<tr class="k-scheduler-head">
|
|
374
|
-
<td>
|
|
375
|
-
<div kendoSchedulerAgendaHeader [resources]="groupedResources" #headerWrap></div>
|
|
376
|
-
</td>
|
|
377
|
-
</tr>
|
|
378
|
-
<tr class="k-scheduler-body">
|
|
379
|
-
<td>
|
|
380
|
-
<div kendoSchedulerAgendaList #content
|
|
381
|
-
[editable]="editable"
|
|
382
|
-
[eventTemplate]="eventTemplateRef"
|
|
383
|
-
[slotClass]="slotClass"
|
|
384
|
-
[eventClass]="eventClass"
|
|
385
|
-
[eventStyles]="eventStyles"
|
|
386
|
-
[agendaTimeTemplate]="agendaTimeTemplateRef"
|
|
387
|
-
[agendaDateTemplate]="agendaDateTemplateRef"
|
|
388
|
-
[tasks]="tasks | async">
|
|
389
|
-
</div>
|
|
390
|
-
</td>
|
|
391
|
-
</tr>
|
|
392
|
-
</tbody>
|
|
393
|
-
</table>
|
|
394
|
-
`,
|
|
395
|
-
standalone: true,
|
|
396
|
-
imports: [AgendaHeaderComponent, AgendaListComponent, AsyncPipe]
|
|
397
|
-
}]
|
|
398
|
-
}], ctorParameters: () => [{ type: i1.ViewContextService }, { type: i2.ViewStateService }, { type: i3.IntlService }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: i0.NgZone }, { type: i4.PDFService }, { type: i5.LocalizationService }], propDecorators: { hiddenDays: [{
|
|
399
|
-
type: Input
|
|
400
|
-
}], eventTemplate: [{
|
|
401
|
-
type: Input
|
|
402
|
-
}], slotClass: [{
|
|
403
|
-
type: Input
|
|
404
|
-
}], eventClass: [{
|
|
405
|
-
type: Input
|
|
406
|
-
}], eventStyles: [{
|
|
407
|
-
type: Input
|
|
408
|
-
}], agendaTimeTemplate: [{
|
|
409
|
-
type: Input
|
|
410
|
-
}], agendaDateTemplate: [{
|
|
411
|
-
type: Input
|
|
412
|
-
}], selectedDateFormat: [{
|
|
413
|
-
type: Input
|
|
414
|
-
}], selectedShortDateFormat: [{
|
|
415
|
-
type: Input
|
|
416
|
-
}], numberOfDays: [{
|
|
417
|
-
type: Input
|
|
418
|
-
}], headerWrap: [{
|
|
419
|
-
type: ViewChild,
|
|
420
|
-
args: ['headerWrap', { read: ElementRef, static: true }]
|
|
421
|
-
}], content: [{
|
|
422
|
-
type: ViewChild,
|
|
423
|
-
args: ['content', { read: ElementRef, static: true }]
|
|
424
|
-
}] } });
|
|
@@ -1,256 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Component, HostBinding, Input, TemplateRef } from '@angular/core';
|
|
6
|
-
import { IntlService } from '@progress/kendo-angular-intl';
|
|
7
|
-
import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
8
|
-
import { toLocalDate } from '@progress/kendo-date-math';
|
|
9
|
-
import { caretAltLeftIcon, caretAltRightIcon } from '@progress/kendo-svg-icons';
|
|
10
|
-
import { convertNgClassBindings } from '../utils';
|
|
11
|
-
import { AgendaTaskItemComponent } from './agenda-task-item.component';
|
|
12
|
-
import { FocusableDirective } from '../../navigation/focusable.directive';
|
|
13
|
-
import { IconWrapperComponent } from '@progress/kendo-angular-icons';
|
|
14
|
-
import { AgendaHeaderItemComponent } from './agenda-header-item.component';
|
|
15
|
-
import { NgTemplateOutlet, NgClass, NgStyle } from '@angular/common';
|
|
16
|
-
import * as i0 from "@angular/core";
|
|
17
|
-
import * as i1 from "@progress/kendo-angular-intl";
|
|
18
|
-
import * as i2 from "@progress/kendo-angular-l10n";
|
|
19
|
-
/**
|
|
20
|
-
* @hidden
|
|
21
|
-
*/
|
|
22
|
-
export class AgendaListComponent {
|
|
23
|
-
intlService;
|
|
24
|
-
localization;
|
|
25
|
-
classes = true;
|
|
26
|
-
tasks;
|
|
27
|
-
eventTemplate;
|
|
28
|
-
slotClass;
|
|
29
|
-
eventClass;
|
|
30
|
-
eventStyles;
|
|
31
|
-
agendaTimeTemplate;
|
|
32
|
-
agendaDateTemplate;
|
|
33
|
-
editable;
|
|
34
|
-
caretAltLeftIcon = caretAltLeftIcon;
|
|
35
|
-
caretAltRightIcon = caretAltRightIcon;
|
|
36
|
-
constructor(intlService, localization) {
|
|
37
|
-
this.intlService = intlService;
|
|
38
|
-
this.localization = localization;
|
|
39
|
-
}
|
|
40
|
-
extractDataItem(item) {
|
|
41
|
-
return item.type === "group" ? item.dataItem.items[0] : item.dataItem;
|
|
42
|
-
}
|
|
43
|
-
extractDataItemInLocalTime(item) {
|
|
44
|
-
let currentItem;
|
|
45
|
-
if (item.type === "group") {
|
|
46
|
-
currentItem = { ...item.dataItem.items[0] };
|
|
47
|
-
currentItem.start = toLocalDate(item.dataItem.items[0].start);
|
|
48
|
-
currentItem.end = toLocalDate(item.dataItem.items[0].end);
|
|
49
|
-
}
|
|
50
|
-
else {
|
|
51
|
-
currentItem = { ...item.dataItem };
|
|
52
|
-
currentItem.start = toLocalDate(item.dataItem.start);
|
|
53
|
-
currentItem.end = toLocalDate(item.dataItem.end);
|
|
54
|
-
}
|
|
55
|
-
return currentItem;
|
|
56
|
-
}
|
|
57
|
-
formatTime(dataItem) {
|
|
58
|
-
if (dataItem.isAllDay) {
|
|
59
|
-
return this.localization.get('allDay');
|
|
60
|
-
}
|
|
61
|
-
let format = "{0:t}-{1:t}";
|
|
62
|
-
if (dataItem.head) {
|
|
63
|
-
format = "{0:t}";
|
|
64
|
-
}
|
|
65
|
-
else if (dataItem.tail) {
|
|
66
|
-
format = "{1:t}";
|
|
67
|
-
}
|
|
68
|
-
return this.intlService.format(format, toLocalDate(dataItem.start), toLocalDate(dataItem.end));
|
|
69
|
-
}
|
|
70
|
-
trackByFn(index, _item) {
|
|
71
|
-
return index;
|
|
72
|
-
}
|
|
73
|
-
cellClasses(item) {
|
|
74
|
-
const task = this.extractDataItem(item);
|
|
75
|
-
let result = [];
|
|
76
|
-
if (this.slotClass) {
|
|
77
|
-
result = result.concat(convertNgClassBindings(this.slotClass({
|
|
78
|
-
start: task.start,
|
|
79
|
-
end: task.end,
|
|
80
|
-
resources: task.resources,
|
|
81
|
-
event: task.event
|
|
82
|
-
})));
|
|
83
|
-
}
|
|
84
|
-
if (this.eventClass) {
|
|
85
|
-
result = result.concat(convertNgClassBindings(this.eventClass({
|
|
86
|
-
event: task.event,
|
|
87
|
-
resources: task.resources
|
|
88
|
-
})));
|
|
89
|
-
}
|
|
90
|
-
return result;
|
|
91
|
-
}
|
|
92
|
-
getEventStyles(item) {
|
|
93
|
-
if (this.eventStyles) {
|
|
94
|
-
const task = this.extractDataItem(item);
|
|
95
|
-
return this.eventStyles({
|
|
96
|
-
event: task.event,
|
|
97
|
-
resources: task.resources
|
|
98
|
-
});
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
get arrowIcons() {
|
|
102
|
-
return !this.localization.rtl ? ['caret-alt-left', 'caret-alt-right'] : ['caret-alt-right', 'caret-alt-left'];
|
|
103
|
-
}
|
|
104
|
-
get arrowSVGIcons() {
|
|
105
|
-
return !this.localization.rtl ? [this.caretAltLeftIcon, this.caretAltRightIcon] : [this.caretAltRightIcon, this.caretAltLeftIcon];
|
|
106
|
-
}
|
|
107
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: AgendaListComponent, deps: [{ token: i1.IntlService }, { token: i2.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
108
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: AgendaListComponent, isStandalone: true, selector: "[kendoSchedulerAgendaList]", inputs: { tasks: "tasks", eventTemplate: "eventTemplate", slotClass: "slotClass", eventClass: "eventClass", eventStyles: "eventStyles", agendaTimeTemplate: "agendaTimeTemplate", agendaDateTemplate: "agendaDateTemplate", editable: "editable" }, host: { properties: { "class.k-scheduler-content": "this.classes" } }, ngImport: i0, template: `
|
|
109
|
-
<table class="k-scheduler-table" role="none">
|
|
110
|
-
<tbody role="rowgroup">
|
|
111
|
-
@for (group of tasks; track group; let groupIndex = $index) {
|
|
112
|
-
@for (item of group.tasks; track trackByFn(index, item); let index = $index) {
|
|
113
|
-
<tr role="row">
|
|
114
|
-
@for (resource of group.resources; track resource; let resourceIndex = $index) {
|
|
115
|
-
@if (group.spans[resourceIndex] && index === 0) {
|
|
116
|
-
<td class="k-scheduler-groupcolumn k-first" [attr.rowspan]="group.spans[resourceIndex]" role="rowheader">
|
|
117
|
-
{{ resource }}
|
|
118
|
-
</td>
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
@if (item.type === 'group') {
|
|
122
|
-
<td
|
|
123
|
-
[kendoSchedulerAgendaHeaderItem]="item"
|
|
124
|
-
[hasFirstClass]="!group.resources || group.resources.length === 0"
|
|
125
|
-
[agendaDateTemplate]="agendaDateTemplate">
|
|
126
|
-
</td>
|
|
127
|
-
}
|
|
128
|
-
<td class="k-scheduler-timecolumn k-scheduler-cell" role="gridcell">
|
|
129
|
-
@if (!agendaTimeTemplate) {
|
|
130
|
-
<div>
|
|
131
|
-
@if (extractDataItem(item).tail || extractDataItem(item).mid) {
|
|
132
|
-
<kendo-icon-wrapper
|
|
133
|
-
[name]="arrowIcons[0]"
|
|
134
|
-
[svgIcon]="arrowSVGIcons[0]"
|
|
135
|
-
>
|
|
136
|
-
</kendo-icon-wrapper>
|
|
137
|
-
}
|
|
138
|
-
{{ formatTime(extractDataItem(item)) }}
|
|
139
|
-
@if (extractDataItem(item).head || extractDataItem(item).mid) {
|
|
140
|
-
<kendo-icon-wrapper
|
|
141
|
-
[name]="arrowIcons[1]"
|
|
142
|
-
[svgIcon]="arrowSVGIcons[1]"
|
|
143
|
-
>
|
|
144
|
-
</kendo-icon-wrapper>
|
|
145
|
-
}
|
|
146
|
-
</div>
|
|
147
|
-
}
|
|
148
|
-
@if (agendaTimeTemplate) {
|
|
149
|
-
<ng-container [ngTemplateOutlet]="agendaTimeTemplate"
|
|
150
|
-
[ngTemplateOutletContext]="extractDataItemInLocalTime(item)">
|
|
151
|
-
</ng-container>
|
|
152
|
-
}
|
|
153
|
-
</td>
|
|
154
|
-
<td [attr.data-group-index]="groupIndex" [attr.data-task-index]="index" role="gridcell"
|
|
155
|
-
[ngClass]="cellClasses(item)" [ngStyle]="getEventStyles(item)"
|
|
156
|
-
[kendoSchedulerFocusIndex]="groupIndex"
|
|
157
|
-
[id]="item.elementId"
|
|
158
|
-
[kendoSchedulerAgendaTaskItem]="extractDataItem(item)"
|
|
159
|
-
[editable]="editable"
|
|
160
|
-
[eventTemplate]="eventTemplate"
|
|
161
|
-
></td>
|
|
162
|
-
</tr>
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
</tbody>
|
|
166
|
-
</table>
|
|
167
|
-
`, isInline: true, dependencies: [{ kind: "component", type: AgendaHeaderItemComponent, selector: "[kendoSchedulerAgendaHeaderItem]", inputs: ["kendoSchedulerAgendaHeaderItem", "agendaDateTemplate", "hasFirstClass"] }, { kind: "component", type: IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass", "size"], exportAs: ["kendoIconWrapper"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: FocusableDirective, selector: "[kendoSchedulerFocusIndex]", inputs: ["kendoSchedulerFocusIndex", "containerType"] }, { kind: "component", type: AgendaTaskItemComponent, selector: "[kendoSchedulerAgendaTaskItem]", inputs: ["kendoSchedulerAgendaTaskItem", "color", "eventTemplate", "editable"] }] });
|
|
168
|
-
}
|
|
169
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: AgendaListComponent, decorators: [{
|
|
170
|
-
type: Component,
|
|
171
|
-
args: [{
|
|
172
|
-
// eslint-disable-next-line @angular-eslint/component-selector
|
|
173
|
-
selector: '[kendoSchedulerAgendaList]',
|
|
174
|
-
template: `
|
|
175
|
-
<table class="k-scheduler-table" role="none">
|
|
176
|
-
<tbody role="rowgroup">
|
|
177
|
-
@for (group of tasks; track group; let groupIndex = $index) {
|
|
178
|
-
@for (item of group.tasks; track trackByFn(index, item); let index = $index) {
|
|
179
|
-
<tr role="row">
|
|
180
|
-
@for (resource of group.resources; track resource; let resourceIndex = $index) {
|
|
181
|
-
@if (group.spans[resourceIndex] && index === 0) {
|
|
182
|
-
<td class="k-scheduler-groupcolumn k-first" [attr.rowspan]="group.spans[resourceIndex]" role="rowheader">
|
|
183
|
-
{{ resource }}
|
|
184
|
-
</td>
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
@if (item.type === 'group') {
|
|
188
|
-
<td
|
|
189
|
-
[kendoSchedulerAgendaHeaderItem]="item"
|
|
190
|
-
[hasFirstClass]="!group.resources || group.resources.length === 0"
|
|
191
|
-
[agendaDateTemplate]="agendaDateTemplate">
|
|
192
|
-
</td>
|
|
193
|
-
}
|
|
194
|
-
<td class="k-scheduler-timecolumn k-scheduler-cell" role="gridcell">
|
|
195
|
-
@if (!agendaTimeTemplate) {
|
|
196
|
-
<div>
|
|
197
|
-
@if (extractDataItem(item).tail || extractDataItem(item).mid) {
|
|
198
|
-
<kendo-icon-wrapper
|
|
199
|
-
[name]="arrowIcons[0]"
|
|
200
|
-
[svgIcon]="arrowSVGIcons[0]"
|
|
201
|
-
>
|
|
202
|
-
</kendo-icon-wrapper>
|
|
203
|
-
}
|
|
204
|
-
{{ formatTime(extractDataItem(item)) }}
|
|
205
|
-
@if (extractDataItem(item).head || extractDataItem(item).mid) {
|
|
206
|
-
<kendo-icon-wrapper
|
|
207
|
-
[name]="arrowIcons[1]"
|
|
208
|
-
[svgIcon]="arrowSVGIcons[1]"
|
|
209
|
-
>
|
|
210
|
-
</kendo-icon-wrapper>
|
|
211
|
-
}
|
|
212
|
-
</div>
|
|
213
|
-
}
|
|
214
|
-
@if (agendaTimeTemplate) {
|
|
215
|
-
<ng-container [ngTemplateOutlet]="agendaTimeTemplate"
|
|
216
|
-
[ngTemplateOutletContext]="extractDataItemInLocalTime(item)">
|
|
217
|
-
</ng-container>
|
|
218
|
-
}
|
|
219
|
-
</td>
|
|
220
|
-
<td [attr.data-group-index]="groupIndex" [attr.data-task-index]="index" role="gridcell"
|
|
221
|
-
[ngClass]="cellClasses(item)" [ngStyle]="getEventStyles(item)"
|
|
222
|
-
[kendoSchedulerFocusIndex]="groupIndex"
|
|
223
|
-
[id]="item.elementId"
|
|
224
|
-
[kendoSchedulerAgendaTaskItem]="extractDataItem(item)"
|
|
225
|
-
[editable]="editable"
|
|
226
|
-
[eventTemplate]="eventTemplate"
|
|
227
|
-
></td>
|
|
228
|
-
</tr>
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
</tbody>
|
|
232
|
-
</table>
|
|
233
|
-
`,
|
|
234
|
-
standalone: true,
|
|
235
|
-
imports: [AgendaHeaderItemComponent, IconWrapperComponent, NgTemplateOutlet, NgClass, NgStyle, FocusableDirective, AgendaTaskItemComponent]
|
|
236
|
-
}]
|
|
237
|
-
}], ctorParameters: () => [{ type: i1.IntlService }, { type: i2.LocalizationService }], propDecorators: { classes: [{
|
|
238
|
-
type: HostBinding,
|
|
239
|
-
args: ['class.k-scheduler-content']
|
|
240
|
-
}], tasks: [{
|
|
241
|
-
type: Input
|
|
242
|
-
}], eventTemplate: [{
|
|
243
|
-
type: Input
|
|
244
|
-
}], slotClass: [{
|
|
245
|
-
type: Input
|
|
246
|
-
}], eventClass: [{
|
|
247
|
-
type: Input
|
|
248
|
-
}], eventStyles: [{
|
|
249
|
-
type: Input
|
|
250
|
-
}], agendaTimeTemplate: [{
|
|
251
|
-
type: Input
|
|
252
|
-
}], agendaDateTemplate: [{
|
|
253
|
-
type: Input
|
|
254
|
-
}], editable: [{
|
|
255
|
-
type: Input
|
|
256
|
-
}] } });
|