@syncfusion/ej2-schedule 21.2.10 → 22.1.34
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/.eslintrc.json +1 -0
- package/CHANGELOG.md +14 -0
- package/dist/ej2-schedule.min.js +2 -2
- package/dist/ej2-schedule.umd.min.js +2 -2
- package/dist/ej2-schedule.umd.min.js.map +1 -1
- package/dist/es6/ej2-schedule.es2015.js +50 -26
- package/dist/es6/ej2-schedule.es2015.js.map +1 -1
- package/dist/es6/ej2-schedule.es5.js +51 -27
- package/dist/es6/ej2-schedule.es5.js.map +1 -1
- package/dist/global/ej2-schedule.min.js +2 -2
- package/dist/global/ej2-schedule.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +15 -15
- package/src/recurrence-editor/recurrence-editor-model.d.ts +8 -1
- package/src/recurrence-editor/recurrence-editor.d.ts +17 -0
- package/src/recurrence-editor/recurrence-editor.js +7 -4
- package/src/schedule/actions/keyboard.js +2 -0
- package/src/schedule/base/schedule-model.d.ts +18 -9
- package/src/schedule/base/schedule.d.ts +20 -11
- package/src/schedule/base/schedule.js +14 -5
- package/src/schedule/models/event-settings-model.d.ts +4 -2
- package/src/schedule/models/event-settings.d.ts +4 -2
- package/src/schedule/models/group-model.d.ts +2 -1
- package/src/schedule/models/group.d.ts +2 -1
- package/src/schedule/models/header-rows-model.d.ts +2 -1
- package/src/schedule/models/header-rows.d.ts +2 -1
- package/src/schedule/models/quick-info-templates-model.d.ts +6 -3
- package/src/schedule/models/quick-info-templates.d.ts +6 -3
- package/src/schedule/models/time-scale-model.d.ts +4 -2
- package/src/schedule/models/time-scale.d.ts +4 -2
- package/src/schedule/models/views-model.d.ts +18 -9
- package/src/schedule/models/views.d.ts +18 -9
- package/src/schedule/popups/event-tooltip.js +6 -3
- package/src/schedule/popups/event-window.js +18 -14
- package/src/schedule/popups/quick-popups.js +3 -1
- package/src/schedule/renderer/timeline-view.js +2 -1
- package/styles/bootstrap-dark.css +9 -12
- package/styles/bootstrap.css +9 -12
- package/styles/bootstrap4.css +10 -13
- package/styles/bootstrap5-dark.css +9 -12
- package/styles/bootstrap5.css +9 -12
- package/styles/fabric-dark.css +9 -12
- package/styles/fabric.css +9 -12
- package/styles/fluent-dark.css +9 -12
- package/styles/fluent.css +9 -12
- package/styles/highcontrast-light.css +10 -13
- package/styles/highcontrast.css +10 -13
- package/styles/material-dark.css +9 -12
- package/styles/material.css +9 -12
- package/styles/material3-dark.css +4597 -0
- package/styles/material3-dark.scss +4 -0
- package/styles/material3.css +4653 -0
- package/styles/material3.scss +4 -0
- package/styles/recurrence-editor/_material3-dark-definition.scss +1 -0
- package/styles/recurrence-editor/_material3-definition.scss +13 -0
- package/styles/recurrence-editor/material3-dark.css +593 -0
- package/styles/recurrence-editor/material3-dark.scss +9 -0
- package/styles/recurrence-editor/material3.css +649 -0
- package/styles/recurrence-editor/material3.scss +9 -0
- package/styles/schedule/_bootstrap-dark-definition.scss +3 -2
- package/styles/schedule/_bootstrap-definition.scss +3 -2
- package/styles/schedule/_bootstrap4-definition.scss +3 -2
- package/styles/schedule/_bootstrap5-definition.scss +3 -2
- package/styles/schedule/_fabric-dark-definition.scss +3 -2
- package/styles/schedule/_fabric-definition.scss +3 -2
- package/styles/schedule/_fluent-definition.scss +3 -2
- package/styles/schedule/_fusionnew-definition.scss +3 -2
- package/styles/schedule/_highcontrast-definition.scss +3 -2
- package/styles/schedule/_highcontrast-light-definition.scss +3 -2
- package/styles/schedule/_layout.scss +27 -17
- package/styles/schedule/_material-dark-definition.scss +3 -2
- package/styles/schedule/_material-definition.scss +3 -2
- package/styles/schedule/_material3-dark-definition.scss +1 -0
- package/styles/schedule/_material3-definition.scss +292 -0
- package/styles/schedule/_tailwind-definition.scss +3 -2
- package/styles/schedule/_theme.scss +7 -2
- package/styles/schedule/bootstrap-dark.css +9 -12
- package/styles/schedule/bootstrap.css +9 -12
- package/styles/schedule/bootstrap4.css +10 -13
- package/styles/schedule/bootstrap5-dark.css +9 -12
- package/styles/schedule/bootstrap5.css +9 -12
- package/styles/schedule/fabric-dark.css +9 -12
- package/styles/schedule/fabric.css +9 -12
- package/styles/schedule/fluent-dark.css +9 -12
- package/styles/schedule/fluent.css +9 -12
- package/styles/schedule/highcontrast-light.css +10 -13
- package/styles/schedule/highcontrast.css +10 -13
- package/styles/schedule/icons/_material3-dark.scss +1 -0
- package/styles/schedule/material-dark.css +9 -12
- package/styles/schedule/material.css +9 -12
- package/styles/schedule/material3-dark.css +4191 -0
- package/styles/schedule/material3-dark.scss +16 -0
- package/styles/schedule/material3.css +4247 -0
- package/styles/schedule/material3.scss +17 -0
- package/styles/schedule/tailwind-dark.css +9 -12
- package/styles/schedule/tailwind.css +9 -12
- package/styles/tailwind-dark.css +9 -12
- package/styles/tailwind.css +9 -12
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version :
|
|
3
|
+
* version : 22.1.34
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2020. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-schedule@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-schedule@21.
|
|
3
|
+
"_id": "@syncfusion/ej2-schedule@21.4.0",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-EZAbpScHUedLn/uzkEFqw32MbJvnJZEH0HdWSwd5aamBAKQfk/bVvdFk/KFx+cNb6uRO/ME+NwpDrsVNYIdcGA==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-schedule",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"/@syncfusion/ej2-react-schedule",
|
|
24
24
|
"/@syncfusion/ej2-vue-schedule"
|
|
25
25
|
],
|
|
26
|
-
"_resolved": "https://nexus.syncfusion.com/repository/ej2-
|
|
27
|
-
"_shasum": "
|
|
26
|
+
"_resolved": "https://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-schedule/-/ej2-schedule-21.4.0.tgz",
|
|
27
|
+
"_shasum": "4b5dfc8fd8a5960fc918df9a8bd2ff69c5933424",
|
|
28
28
|
"_spec": "@syncfusion/ej2-schedule@*",
|
|
29
29
|
"_where": "/jenkins/workspace/elease-automation_release_21.1.1/packages/included",
|
|
30
30
|
"author": {
|
|
@@ -35,16 +35,16 @@
|
|
|
35
35
|
},
|
|
36
36
|
"bundleDependencies": false,
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@syncfusion/ej2-base": "~
|
|
39
|
-
"@syncfusion/ej2-buttons": "~
|
|
40
|
-
"@syncfusion/ej2-calendars": "~
|
|
41
|
-
"@syncfusion/ej2-data": "~
|
|
42
|
-
"@syncfusion/ej2-dropdowns": "~
|
|
43
|
-
"@syncfusion/ej2-excel-export": "~
|
|
44
|
-
"@syncfusion/ej2-inputs": "~
|
|
45
|
-
"@syncfusion/ej2-lists": "~
|
|
46
|
-
"@syncfusion/ej2-navigations": "~
|
|
47
|
-
"@syncfusion/ej2-popups": "~
|
|
38
|
+
"@syncfusion/ej2-base": "~22.1.34",
|
|
39
|
+
"@syncfusion/ej2-buttons": "~22.1.34",
|
|
40
|
+
"@syncfusion/ej2-calendars": "~22.1.34",
|
|
41
|
+
"@syncfusion/ej2-data": "~22.1.34",
|
|
42
|
+
"@syncfusion/ej2-dropdowns": "~22.1.34",
|
|
43
|
+
"@syncfusion/ej2-excel-export": "~22.1.34",
|
|
44
|
+
"@syncfusion/ej2-inputs": "~22.1.34",
|
|
45
|
+
"@syncfusion/ej2-lists": "~22.1.34",
|
|
46
|
+
"@syncfusion/ej2-navigations": "~22.1.34",
|
|
47
|
+
"@syncfusion/ej2-popups": "~22.1.34"
|
|
48
48
|
},
|
|
49
49
|
"deprecated": false,
|
|
50
50
|
"description": "Flexible scheduling library with more built-in features and enhanced customization options similar to outlook and google calendar, allowing the users to plan and manage their appointments with efficient data-binding support.",
|
|
@@ -73,6 +73,6 @@
|
|
|
73
73
|
"url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
|
|
74
74
|
},
|
|
75
75
|
"typings": "index.d.ts",
|
|
76
|
-
"version": "
|
|
76
|
+
"version": "22.1.34",
|
|
77
77
|
"sideEffects": false
|
|
78
78
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Component, Property, NotifyPropertyChanges, INotifyPropertyChanged, Event, Browser, detach } from '@syncfusion/ej2-base';import { EmitType, getDefaultDateObject, getValue, cldrData, L10n, isNullOrUndefined, removeClass, addClass } from '@syncfusion/ej2-base';import { DropDownList, ChangeEventArgs } from '@syncfusion/ej2-dropdowns';import { NumericTextBox } from '@syncfusion/ej2-inputs';import { DatePicker, ChangedEventArgs } from '@syncfusion/ej2-calendars';import { Button, RadioButton } from '@syncfusion/ej2-buttons';import { EventHandler, MouseEventArgs, classList } from '@syncfusion/ej2-base';import { EJ2Instance } from '../schedule/base/interface';import { RecRule, extractObjectFromRule, generate, generateSummary, getRecurrenceStringFromDate, getCalendarUtil } from './date-generator';import { CalendarUtil, CalendarType } from '../common/calendar-util';import { capitalizeFirstWord } from '../schedule/base/util';
|
|
2
|
-
import {RepeatType,RecurrenceEditorChangeEventArgs} from "./recurrence-editor";
|
|
2
|
+
import {RepeatType,EndType,RecurrenceEditorChangeEventArgs} from "./recurrence-editor";
|
|
3
3
|
import {ComponentModel} from '@syncfusion/ej2-base';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -14,6 +14,13 @@ export interface RecurrenceEditorModel extends ComponentModel{
|
|
|
14
14
|
*/
|
|
15
15
|
frequencies?: RepeatType[];
|
|
16
16
|
|
|
17
|
+
/**
|
|
18
|
+
* Sets the type of recurrence end for the recurrence pattern on the editor.
|
|
19
|
+
*
|
|
20
|
+
* @default ['never', 'until', 'count']
|
|
21
|
+
*/
|
|
22
|
+
endTypes?: EndType[];
|
|
23
|
+
|
|
17
24
|
/**
|
|
18
25
|
* Sets the first day of the week.
|
|
19
26
|
*
|
|
@@ -21,6 +21,12 @@ export declare class RecurrenceEditor extends Component<HTMLElement> implements
|
|
|
21
21
|
* @default ['none', 'daily', 'weekly', 'monthly', 'yearly']
|
|
22
22
|
*/
|
|
23
23
|
frequencies: RepeatType[];
|
|
24
|
+
/**
|
|
25
|
+
* Sets the type of recurrence end for the recurrence pattern on the editor.
|
|
26
|
+
*
|
|
27
|
+
* @default ['never', 'until', 'count']
|
|
28
|
+
*/
|
|
29
|
+
endTypes: EndType[];
|
|
24
30
|
/**
|
|
25
31
|
* Sets the first day of the week.
|
|
26
32
|
*
|
|
@@ -214,3 +220,14 @@ export interface RecurrenceEditorChangeEventArgs {
|
|
|
214
220
|
* ```
|
|
215
221
|
*/
|
|
216
222
|
export declare type RepeatType = 'none' | 'daily' | 'weekly' | 'monthly' | 'yearly';
|
|
223
|
+
/**
|
|
224
|
+
* Defines the available types of recurrence end for the recurrence editor.
|
|
225
|
+
* ```props
|
|
226
|
+
* The following options are available:
|
|
227
|
+
*
|
|
228
|
+
* never :- Denotes that the recurrence has no end date and continues indefinitely.
|
|
229
|
+
* until :- Denotes that the recurrence ends on a specified date.
|
|
230
|
+
* count :- Denotes that the recurrence ends after a specified number of occurrences.
|
|
231
|
+
* ```
|
|
232
|
+
*/
|
|
233
|
+
export declare type EndType = 'never' | 'until' | 'count';
|
|
@@ -232,7 +232,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
232
232
|
}
|
|
233
233
|
else {
|
|
234
234
|
if (!isNullOrUndefined(this.repeatType.value)) {
|
|
235
|
-
this.startState(this.repeatType.value.toString().toUpperCase(),
|
|
235
|
+
this.startState(this.repeatType.value.toString().toUpperCase(), this.endTypes[0], this.startDate);
|
|
236
236
|
this.updateForm(this.repeatType.value.toString());
|
|
237
237
|
}
|
|
238
238
|
if (this.selectedType > 0) {
|
|
@@ -621,11 +621,10 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
621
621
|
}
|
|
622
622
|
};
|
|
623
623
|
RecurrenceEditor.prototype.getEndData = function () {
|
|
624
|
-
var endData = [NEVER, UNTIL, COUNT];
|
|
625
624
|
// eslint-disable-next-line @typescript-eslint/no-this-alias
|
|
626
625
|
var self = this;
|
|
627
626
|
var dataSource = [];
|
|
628
|
-
|
|
627
|
+
this.endTypes.forEach(function (data) {
|
|
629
628
|
dataSource.push({ text: self.localeObj.getConstant(data), value: data });
|
|
630
629
|
});
|
|
631
630
|
return dataSource;
|
|
@@ -925,7 +924,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
925
924
|
this.monthButtons = [];
|
|
926
925
|
};
|
|
927
926
|
RecurrenceEditor.prototype.resetFields = function () {
|
|
928
|
-
this.startState(NONE,
|
|
927
|
+
this.startState(NONE, this.endTypes[0], this.startDate);
|
|
929
928
|
this.setDefaultValue();
|
|
930
929
|
};
|
|
931
930
|
RecurrenceEditor.prototype.updateRuleUntilDate = function (startDate) {
|
|
@@ -1110,6 +1109,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
1110
1109
|
case 'locale':
|
|
1111
1110
|
case 'frequencies':
|
|
1112
1111
|
case 'firstDayOfWeek':
|
|
1112
|
+
case 'endTypes':
|
|
1113
1113
|
this.refresh();
|
|
1114
1114
|
break;
|
|
1115
1115
|
case 'dateFormat':
|
|
@@ -1121,6 +1121,9 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
1121
1121
|
__decorate([
|
|
1122
1122
|
Property(['none', 'daily', 'weekly', 'monthly', 'yearly'])
|
|
1123
1123
|
], RecurrenceEditor.prototype, "frequencies", void 0);
|
|
1124
|
+
__decorate([
|
|
1125
|
+
Property(['never', 'until', 'count'])
|
|
1126
|
+
], RecurrenceEditor.prototype, "endTypes", void 0);
|
|
1124
1127
|
__decorate([
|
|
1125
1128
|
Property(0)
|
|
1126
1129
|
], RecurrenceEditor.prototype, "firstDayOfWeek", void 0);
|
|
@@ -606,6 +606,7 @@ var KeyboardInteraction = /** @class */ (function () {
|
|
|
606
606
|
return;
|
|
607
607
|
}
|
|
608
608
|
}
|
|
609
|
+
e.preventDefault();
|
|
609
610
|
this.selectCells(isMultiple, targetCell);
|
|
610
611
|
}
|
|
611
612
|
}
|
|
@@ -653,6 +654,7 @@ var KeyboardInteraction = /** @class */ (function () {
|
|
|
653
654
|
return;
|
|
654
655
|
}
|
|
655
656
|
}
|
|
657
|
+
e.preventDefault();
|
|
656
658
|
this.selectCells(isMultiple, targetCell);
|
|
657
659
|
}
|
|
658
660
|
}
|
|
@@ -325,15 +325,17 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
325
325
|
* {% codeBlock src='schedule/dateHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
326
326
|
*
|
|
327
327
|
* @default null
|
|
328
|
+
* @aspType string
|
|
328
329
|
*/
|
|
329
|
-
dateHeaderTemplate?: string;
|
|
330
|
+
dateHeaderTemplate?: string | Function;
|
|
330
331
|
|
|
331
332
|
/**
|
|
332
333
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto the header date range.
|
|
333
334
|
*
|
|
334
335
|
* @default null
|
|
336
|
+
* @aspType string
|
|
335
337
|
*/
|
|
336
|
-
dateRangeTemplate?: string;
|
|
338
|
+
dateRangeTemplate?: string | Function;
|
|
337
339
|
|
|
338
340
|
/**
|
|
339
341
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto
|
|
@@ -342,8 +344,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
342
344
|
* {% codeBlock src='schedule/cellHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
343
345
|
*
|
|
344
346
|
* @default null
|
|
347
|
+
* @aspType string
|
|
345
348
|
*/
|
|
346
|
-
cellHeaderTemplate?: string;
|
|
349
|
+
cellHeaderTemplate?: string | Function;
|
|
347
350
|
|
|
348
351
|
/**
|
|
349
352
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto
|
|
@@ -352,8 +355,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
352
355
|
* {% codeBlock src='schedule/dayHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
353
356
|
*
|
|
354
357
|
* @default null
|
|
358
|
+
* @aspType string
|
|
355
359
|
*/
|
|
356
|
-
dayHeaderTemplate?: string;
|
|
360
|
+
dayHeaderTemplate?: string | Function;
|
|
357
361
|
|
|
358
362
|
/**
|
|
359
363
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto
|
|
@@ -362,8 +366,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
362
366
|
* {% codeBlock src='schedule/monthHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
363
367
|
*
|
|
364
368
|
* @default null
|
|
369
|
+
* @aspType string
|
|
365
370
|
*/
|
|
366
|
-
monthHeaderTemplate?: string;
|
|
371
|
+
monthHeaderTemplate?: string | Function;
|
|
367
372
|
|
|
368
373
|
/**
|
|
369
374
|
* The template option which is used to render the customized work cells on the Schedule. Here, the template accepts either
|
|
@@ -378,8 +383,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
378
383
|
* {% codeBlock src='schedule/cellTemplate/index.md' %}{% endcodeBlock %}
|
|
379
384
|
*
|
|
380
385
|
* @default null
|
|
386
|
+
* @aspType string
|
|
381
387
|
*/
|
|
382
|
-
cellTemplate?: string;
|
|
388
|
+
cellTemplate?: string | Function;
|
|
383
389
|
|
|
384
390
|
/**
|
|
385
391
|
* When set to `true`, makes the Schedule to render in a read only mode. No CRUD actions will be allowed at this time.
|
|
@@ -480,8 +486,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
480
486
|
* {% codeBlock src='schedule/editorTemplate/index.md' %}{% endcodeBlock %}
|
|
481
487
|
*
|
|
482
488
|
* @default null
|
|
489
|
+
* @aspType string
|
|
483
490
|
*/
|
|
484
|
-
editorTemplate?: string;
|
|
491
|
+
editorTemplate?: string | Function;
|
|
485
492
|
|
|
486
493
|
/**
|
|
487
494
|
* The template option to customize the quick window. The three sections of the quick popup whereas the header, content,
|
|
@@ -566,8 +573,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
566
573
|
* {% codeBlock src='schedule/resourceHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
567
574
|
*
|
|
568
575
|
* @default null
|
|
576
|
+
* @aspType string
|
|
569
577
|
*/
|
|
570
|
-
resourceHeaderTemplate?: string;
|
|
578
|
+
resourceHeaderTemplate?: string | Function;
|
|
571
579
|
|
|
572
580
|
/**
|
|
573
581
|
* Template option to customize the header indent bar. Here, the template accepts either
|
|
@@ -578,8 +586,9 @@ export interface ScheduleModel extends ComponentModel{
|
|
|
578
586
|
* {% codeBlock src='schedule/headerIndentTemplate/index.md' %}{% endcodeBlock %}
|
|
579
587
|
*
|
|
580
588
|
* @default null
|
|
589
|
+
* @aspType string
|
|
581
590
|
*/
|
|
582
|
-
headerIndentTemplate?: string;
|
|
591
|
+
headerIndentTemplate?: string | Function;
|
|
583
592
|
|
|
584
593
|
/**
|
|
585
594
|
* Allows defining the group related settings of multiple resources. When this property is non-empty, it means
|
|
@@ -426,14 +426,16 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
426
426
|
* {% codeBlock src='schedule/dateHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
427
427
|
*
|
|
428
428
|
* @default null
|
|
429
|
+
* @aspType string
|
|
429
430
|
*/
|
|
430
|
-
dateHeaderTemplate: string;
|
|
431
|
+
dateHeaderTemplate: string | Function;
|
|
431
432
|
/**
|
|
432
433
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto the header date range.
|
|
433
434
|
*
|
|
434
435
|
* @default null
|
|
436
|
+
* @aspType string
|
|
435
437
|
*/
|
|
436
|
-
dateRangeTemplate: string;
|
|
438
|
+
dateRangeTemplate: string | Function;
|
|
437
439
|
/**
|
|
438
440
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto
|
|
439
441
|
* the month date cells. This template is only applicable for month view day cells.
|
|
@@ -441,8 +443,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
441
443
|
* {% codeBlock src='schedule/cellHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
442
444
|
*
|
|
443
445
|
* @default null
|
|
446
|
+
* @aspType string
|
|
444
447
|
*/
|
|
445
|
-
cellHeaderTemplate: string;
|
|
448
|
+
cellHeaderTemplate: string | Function;
|
|
446
449
|
/**
|
|
447
450
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto
|
|
448
451
|
* the day header cells. This template is only applicable for year view header cells.
|
|
@@ -450,8 +453,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
450
453
|
* {% codeBlock src='schedule/dayHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
451
454
|
*
|
|
452
455
|
* @default null
|
|
456
|
+
* @aspType string
|
|
453
457
|
*/
|
|
454
|
-
dayHeaderTemplate: string;
|
|
458
|
+
dayHeaderTemplate: string | Function;
|
|
455
459
|
/**
|
|
456
460
|
* It accepts either the string or HTMLElement as template design content and parse it appropriately before displaying it onto
|
|
457
461
|
* the month header cells. This template is only applicable for year view header cells.
|
|
@@ -459,8 +463,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
459
463
|
* {% codeBlock src='schedule/monthHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
460
464
|
*
|
|
461
465
|
* @default null
|
|
466
|
+
* @aspType string
|
|
462
467
|
*/
|
|
463
|
-
monthHeaderTemplate: string;
|
|
468
|
+
monthHeaderTemplate: string | Function;
|
|
464
469
|
/**
|
|
465
470
|
* The template option which is used to render the customized work cells on the Schedule. Here, the template accepts either
|
|
466
471
|
* the string or HTMLElement as template design and then the parsed design is displayed onto the work cells.
|
|
@@ -474,8 +479,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
474
479
|
* {% codeBlock src='schedule/cellTemplate/index.md' %}{% endcodeBlock %}
|
|
475
480
|
*
|
|
476
481
|
* @default null
|
|
482
|
+
* @aspType string
|
|
477
483
|
*/
|
|
478
|
-
cellTemplate: string;
|
|
484
|
+
cellTemplate: string | Function;
|
|
479
485
|
/**
|
|
480
486
|
* When set to `true`, makes the Schedule to render in a read only mode. No CRUD actions will be allowed at this time.
|
|
481
487
|
*
|
|
@@ -565,8 +571,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
565
571
|
* {% codeBlock src='schedule/editorTemplate/index.md' %}{% endcodeBlock %}
|
|
566
572
|
*
|
|
567
573
|
* @default null
|
|
574
|
+
* @aspType string
|
|
568
575
|
*/
|
|
569
|
-
editorTemplate: string;
|
|
576
|
+
editorTemplate: string | Function;
|
|
570
577
|
/**
|
|
571
578
|
* The template option to customize the quick window. The three sections of the quick popup whereas the header, content,
|
|
572
579
|
* and footer can be easily customized with individual template option.
|
|
@@ -643,8 +650,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
643
650
|
* {% codeBlock src='schedule/resourceHeaderTemplate/index.md' %}{% endcodeBlock %}
|
|
644
651
|
*
|
|
645
652
|
* @default null
|
|
653
|
+
* @aspType string
|
|
646
654
|
*/
|
|
647
|
-
resourceHeaderTemplate: string;
|
|
655
|
+
resourceHeaderTemplate: string | Function;
|
|
648
656
|
/**
|
|
649
657
|
* Template option to customize the header indent bar. Here, the template accepts either
|
|
650
658
|
* the string or HTMLElement as template design and then the parsed design is displayed onto the header indent cell.
|
|
@@ -654,8 +662,9 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
654
662
|
* {% codeBlock src='schedule/headerIndentTemplate/index.md' %}{% endcodeBlock %}
|
|
655
663
|
*
|
|
656
664
|
* @default null
|
|
665
|
+
* @aspType string
|
|
657
666
|
*/
|
|
658
|
-
headerIndentTemplate: string;
|
|
667
|
+
headerIndentTemplate: string | Function;
|
|
659
668
|
/**
|
|
660
669
|
* Allows defining the group related settings of multiple resources. When this property is non-empty, it means
|
|
661
670
|
* that the resources will be grouped on the schedule layout based on the provided resource names.
|
|
@@ -1271,11 +1280,11 @@ export declare class Schedule extends Component<HTMLElement> implements INotifyP
|
|
|
1271
1280
|
/**
|
|
1272
1281
|
* Method to process the templates
|
|
1273
1282
|
*
|
|
1274
|
-
* @param {string} template Accepts the template in string
|
|
1283
|
+
* @param {string | Function} template Accepts the template in string
|
|
1275
1284
|
* @returns {CallbackFunction} Returns the callback function
|
|
1276
1285
|
* @private
|
|
1277
1286
|
*/
|
|
1278
|
-
templateParser(template: string): CallbackFunction;
|
|
1287
|
+
templateParser(template: string | Function): CallbackFunction;
|
|
1279
1288
|
/**
|
|
1280
1289
|
* Retrieves the selected cells.
|
|
1281
1290
|
*
|
|
@@ -696,7 +696,11 @@ var Schedule = /** @class */ (function (_super) {
|
|
|
696
696
|
};
|
|
697
697
|
}
|
|
698
698
|
this.currentTimezoneDate = this.getCurrentTime();
|
|
699
|
-
this.activeCellsData = {
|
|
699
|
+
this.activeCellsData = {
|
|
700
|
+
startTime: new Date(this.currentTimezoneDate),
|
|
701
|
+
endTime: new Date(this.currentTimezoneDate),
|
|
702
|
+
isAllDay: false
|
|
703
|
+
};
|
|
700
704
|
this.activeEventData = { event: undefined, element: undefined };
|
|
701
705
|
this.getDefaultLocale();
|
|
702
706
|
this.localeObj = new L10n(this.getModuleName(), this.defaultLocale, this.locale);
|
|
@@ -1182,18 +1186,23 @@ var Schedule = /** @class */ (function (_super) {
|
|
|
1182
1186
|
/**
|
|
1183
1187
|
* Method to process the templates
|
|
1184
1188
|
*
|
|
1185
|
-
* @param {string} template Accepts the template in string
|
|
1189
|
+
* @param {string | Function} template Accepts the template in string
|
|
1186
1190
|
* @returns {CallbackFunction} Returns the callback function
|
|
1187
1191
|
* @private
|
|
1188
1192
|
*/
|
|
1189
1193
|
Schedule.prototype.templateParser = function (template) {
|
|
1190
1194
|
if (template) {
|
|
1191
1195
|
try {
|
|
1192
|
-
if (
|
|
1193
|
-
return compile(
|
|
1196
|
+
if (typeof template === 'function') {
|
|
1197
|
+
return compile(template);
|
|
1194
1198
|
}
|
|
1195
1199
|
else {
|
|
1196
|
-
|
|
1200
|
+
if (document.querySelectorAll(template).length) {
|
|
1201
|
+
return compile(document.querySelector(template).innerHTML.trim());
|
|
1202
|
+
}
|
|
1203
|
+
else {
|
|
1204
|
+
return compile(template);
|
|
1205
|
+
}
|
|
1197
1206
|
}
|
|
1198
1207
|
}
|
|
1199
1208
|
catch (error) {
|
|
@@ -11,8 +11,9 @@ export interface EventSettingsModel {
|
|
|
11
11
|
* {% codeBlock src="schedule/event-template-api/index.ts" %}{% endcodeBlock %}
|
|
12
12
|
*
|
|
13
13
|
* @default null
|
|
14
|
+
* @aspType string
|
|
14
15
|
*/
|
|
15
|
-
template?: string;
|
|
16
|
+
template?: string | Function;
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* With this property, the event data will be bound to Schedule.
|
|
@@ -73,8 +74,9 @@ export interface EventSettingsModel {
|
|
|
73
74
|
* {% codeBlock src="schedule/tooltip-template-api/index.ts" %}{% endcodeBlock %}
|
|
74
75
|
*
|
|
75
76
|
* @default null
|
|
77
|
+
* @aspType string
|
|
76
78
|
*/
|
|
77
|
-
tooltipTemplate?: string;
|
|
79
|
+
tooltipTemplate?: string | Function;
|
|
78
80
|
|
|
79
81
|
/**
|
|
80
82
|
* Defines the resource name, to decides the color of which particular resource level is to be applied on appointments, when
|
|
@@ -13,8 +13,9 @@ export declare class EventSettings extends ChildProperty<EventSettings> {
|
|
|
13
13
|
* {% codeBlock src="schedule/event-template-api/index.ts" %}{% endcodeBlock %}
|
|
14
14
|
*
|
|
15
15
|
* @default null
|
|
16
|
+
* @aspType string
|
|
16
17
|
*/
|
|
17
|
-
template: string;
|
|
18
|
+
template: string | Function;
|
|
18
19
|
/**
|
|
19
20
|
* With this property, the event data will be bound to Schedule.
|
|
20
21
|
* The event data can be passed either as an array of JavaScript objects,
|
|
@@ -68,8 +69,9 @@ export declare class EventSettings extends ChildProperty<EventSettings> {
|
|
|
68
69
|
* {% codeBlock src="schedule/tooltip-template-api/index.ts" %}{% endcodeBlock %}
|
|
69
70
|
*
|
|
70
71
|
* @default null
|
|
72
|
+
* @aspType string
|
|
71
73
|
*/
|
|
72
|
-
tooltipTemplate: string;
|
|
74
|
+
tooltipTemplate: string | Function;
|
|
73
75
|
/**
|
|
74
76
|
* Defines the resource name, to decides the color of which particular resource level is to be applied on appointments, when
|
|
75
77
|
* grouping is enabled on scheduler.
|
|
@@ -51,8 +51,9 @@ export interface GroupModel {
|
|
|
51
51
|
* can be accessed within this template code.
|
|
52
52
|
*
|
|
53
53
|
* @default null
|
|
54
|
+
* @aspType string
|
|
54
55
|
*/
|
|
55
|
-
headerTooltipTemplate?: string;
|
|
56
|
+
headerTooltipTemplate?: string | Function;
|
|
56
57
|
|
|
57
58
|
/**
|
|
58
59
|
* Decides whether to show/hide the non-working days. It is set to `false` by default and when set to `true`, it hides the non-working days.
|
|
@@ -44,8 +44,9 @@ export declare class Group extends ChildProperty<Group> {
|
|
|
44
44
|
* can be accessed within this template code.
|
|
45
45
|
*
|
|
46
46
|
* @default null
|
|
47
|
+
* @aspType string
|
|
47
48
|
*/
|
|
48
|
-
headerTooltipTemplate: string;
|
|
49
|
+
headerTooltipTemplate: string | Function;
|
|
49
50
|
/**
|
|
50
51
|
* Decides whether to show/hide the non-working days. It is set to `false` by default and when set to `true`, it hides the non-working days.
|
|
51
52
|
* This property is applicable for `Day`, `Week`, `WorkWeek` and `month` views, which are grouped under date.
|
|
@@ -20,21 +20,24 @@ export interface QuickInfoTemplatesModel {
|
|
|
20
20
|
* Template option to customize the header section of quick popup.
|
|
21
21
|
*
|
|
22
22
|
* @default null
|
|
23
|
+
* @aspType string
|
|
23
24
|
*/
|
|
24
|
-
header?: string;
|
|
25
|
+
header?: string | Function;
|
|
25
26
|
|
|
26
27
|
/**
|
|
27
28
|
* Template option to customize the content area of the quick popup.
|
|
28
29
|
*
|
|
29
30
|
* @default null
|
|
31
|
+
* @aspType string
|
|
30
32
|
*/
|
|
31
|
-
content?: string;
|
|
33
|
+
content?: string | Function;
|
|
32
34
|
|
|
33
35
|
/**
|
|
34
36
|
* Template option to customize the footer section of quick popup.
|
|
35
37
|
*
|
|
36
38
|
* @default null
|
|
39
|
+
* @aspType string
|
|
37
40
|
*/
|
|
38
|
-
footer?: string;
|
|
41
|
+
footer?: string | Function;
|
|
39
42
|
|
|
40
43
|
}
|
|
@@ -18,18 +18,21 @@ export declare class QuickInfoTemplates extends ChildProperty<QuickInfoTemplates
|
|
|
18
18
|
* Template option to customize the header section of quick popup.
|
|
19
19
|
*
|
|
20
20
|
* @default null
|
|
21
|
+
* @aspType string
|
|
21
22
|
*/
|
|
22
|
-
header: string;
|
|
23
|
+
header: string | Function;
|
|
23
24
|
/**
|
|
24
25
|
* Template option to customize the content area of the quick popup.
|
|
25
26
|
*
|
|
26
27
|
* @default null
|
|
28
|
+
* @aspType string
|
|
27
29
|
*/
|
|
28
|
-
content: string;
|
|
30
|
+
content: string | Function;
|
|
29
31
|
/**
|
|
30
32
|
* Template option to customize the footer section of quick popup.
|
|
31
33
|
*
|
|
32
34
|
* @default null
|
|
35
|
+
* @aspType string
|
|
33
36
|
*/
|
|
34
|
-
footer: string;
|
|
37
|
+
footer: string | Function;
|
|
35
38
|
}
|
|
@@ -34,8 +34,9 @@ export interface TimeScaleModel {
|
|
|
34
34
|
* onto the time cells. The time details can be accessed within this template.
|
|
35
35
|
*
|
|
36
36
|
* @default null
|
|
37
|
+
* @aspType string
|
|
37
38
|
*/
|
|
38
|
-
minorSlotTemplate?: string;
|
|
39
|
+
minorSlotTemplate?: string | Function;
|
|
39
40
|
|
|
40
41
|
/**
|
|
41
42
|
* The template option to be applied for major time slot. Here, the
|
|
@@ -43,7 +44,8 @@ export interface TimeScaleModel {
|
|
|
43
44
|
* onto the time cells. The time details can be accessed within this template.
|
|
44
45
|
*
|
|
45
46
|
* @default null
|
|
47
|
+
* @aspType string
|
|
46
48
|
*/
|
|
47
|
-
majorSlotTemplate?: string;
|
|
49
|
+
majorSlotTemplate?: string | Function;
|
|
48
50
|
|
|
49
51
|
}
|
|
@@ -29,14 +29,16 @@ export declare class TimeScale extends ChildProperty<TimeScale> {
|
|
|
29
29
|
* onto the time cells. The time details can be accessed within this template.
|
|
30
30
|
*
|
|
31
31
|
* @default null
|
|
32
|
+
* @aspType string
|
|
32
33
|
*/
|
|
33
|
-
minorSlotTemplate: string;
|
|
34
|
+
minorSlotTemplate: string | Function;
|
|
34
35
|
/**
|
|
35
36
|
* The template option to be applied for major time slot. Here, the
|
|
36
37
|
* template accepts either the string or HTMLElement as template design and then the parsed design is displayed
|
|
37
38
|
* onto the time cells. The time details can be accessed within this template.
|
|
38
39
|
*
|
|
39
40
|
* @default null
|
|
41
|
+
* @aspType string
|
|
40
42
|
*/
|
|
41
|
-
majorSlotTemplate: string;
|
|
43
|
+
majorSlotTemplate: string | Function;
|
|
42
44
|
}
|