@syncfusion/ej2-calendars 21.1.38 → 21.2.3
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/CHANGELOG.md +10 -0
- package/dist/ej2-calendars.min.js +2 -2
- package/dist/ej2-calendars.umd.min.js +2 -2
- package/dist/ej2-calendars.umd.min.js.map +1 -1
- package/dist/es6/ej2-calendars.es2015.js +20 -5
- package/dist/es6/ej2-calendars.es2015.js.map +1 -1
- package/dist/es6/ej2-calendars.es5.js +20 -5
- package/dist/es6/ej2-calendars.es5.js.map +1 -1
- package/dist/global/ej2-calendars.min.js +2 -2
- package/dist/global/ej2-calendars.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +11 -14
- package/src/calendar/calendar.js +5 -2
- package/src/datepicker/datepicker.js +4 -1
- package/src/datetimepicker/datetimepicker.js +6 -1
- package/src/timepicker/timepicker.js +5 -1
|
@@ -810,7 +810,7 @@ var CalendarBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
810
810
|
addClass([tdEle], SELECTED);
|
|
811
811
|
}
|
|
812
812
|
this.updateFocus(otherMnthBool, disabledCls, localDate, tdEle, currentDate);
|
|
813
|
-
if (date.getFullYear() === todayDate.getFullYear() && date.getMonth() === todayDate.getMonth()
|
|
813
|
+
if (!isNullOrUndefined(date) && date.getFullYear() === todayDate.getFullYear() && date.getMonth() === todayDate.getMonth()
|
|
814
814
|
&& date.getDate() === todayDate.getDate()) {
|
|
815
815
|
addClass([tdEle], TODAY);
|
|
816
816
|
}
|
|
@@ -943,7 +943,10 @@ var CalendarBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
943
943
|
var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';
|
|
944
944
|
var dateFormatOptions = { skeleton: 'full', type: 'dateTime', calendar: type };
|
|
945
945
|
var date = this.globalize.parseDate(this.globalize.formatDate(localDate, dateFormatOptions), dateFormatOptions);
|
|
946
|
-
var value
|
|
946
|
+
var value;
|
|
947
|
+
if (!isNullOrUndefined(date)) {
|
|
948
|
+
value = date.valueOf();
|
|
949
|
+
}
|
|
947
950
|
var attrs = {
|
|
948
951
|
className: CELL, attrs: { 'id': '' + getUniqueID('' + value), 'aria-selected': 'false' }
|
|
949
952
|
};
|
|
@@ -3301,10 +3304,13 @@ var DatePicker = /** @__PURE__ @class */ (function (_super) {
|
|
|
3301
3304
|
this.createInput();
|
|
3302
3305
|
this.updateHtmlAttributeToWrapper();
|
|
3303
3306
|
this.setAllowEdit();
|
|
3304
|
-
this.updateInput(true);
|
|
3305
3307
|
if (this.enableMask && !this.value && this.maskedDateValue && (this.floatLabelType === 'Always' || !this.floatLabelType || !this.placeholder)) {
|
|
3308
|
+
this.updateInput(true);
|
|
3306
3309
|
this.updateInputValue(this.maskedDateValue);
|
|
3307
3310
|
}
|
|
3311
|
+
else if (!this.enableMask) {
|
|
3312
|
+
this.updateInput(true);
|
|
3313
|
+
}
|
|
3308
3314
|
this.previousElementValue = this.inputElement.value;
|
|
3309
3315
|
this.previousDate = !isNullOrUndefined(this.value) ? new Date(+this.value) : null;
|
|
3310
3316
|
this.inputElement.setAttribute('value', this.inputElement.value);
|
|
@@ -12003,7 +12009,7 @@ var TimePicker = /** @__PURE__ @class */ (function (_super) {
|
|
|
12003
12009
|
this.invalidValueString = null;
|
|
12004
12010
|
this.checkInvalidValue(newProp.value);
|
|
12005
12011
|
newProp.value = this.value;
|
|
12006
|
-
if (!this.invalidValueString) {
|
|
12012
|
+
if (!this.invalidValueString && !this.enableMask) {
|
|
12007
12013
|
if (typeof newProp.value === 'string') {
|
|
12008
12014
|
this.setProperties({ value: this.checkDateValue(new Date(newProp.value)) }, true);
|
|
12009
12015
|
newProp.value = this.value;
|
|
@@ -12016,6 +12022,10 @@ var TimePicker = /** @__PURE__ @class */ (function (_super) {
|
|
|
12016
12022
|
this.initValue = newProp.value;
|
|
12017
12023
|
newProp.value = this.compareFormatChange(this.checkValue(newProp.value));
|
|
12018
12024
|
}
|
|
12025
|
+
else if (this.enableMask) {
|
|
12026
|
+
this.updateInputValue(this.maskedDateValue);
|
|
12027
|
+
this.checkErrorState(this.maskedDateValue);
|
|
12028
|
+
}
|
|
12019
12029
|
else {
|
|
12020
12030
|
this.updateInputValue(this.invalidValueString);
|
|
12021
12031
|
this.checkErrorState(this.invalidValueString);
|
|
@@ -13527,7 +13537,12 @@ var DateTimePicker = /** @__PURE__ @class */ (function (_super) {
|
|
|
13527
13537
|
this.checkInvalidValue(newProp.value);
|
|
13528
13538
|
newProp.value = this.value;
|
|
13529
13539
|
newProp.value = this.validateValue(newProp.value);
|
|
13530
|
-
|
|
13540
|
+
if (this.enableMask) {
|
|
13541
|
+
Input.setValue(this.maskedDateValue, this.inputElement, this.floatLabelType, this.showClearButton);
|
|
13542
|
+
}
|
|
13543
|
+
else {
|
|
13544
|
+
Input.setValue(this.getFormattedValue(newProp.value), this.inputElement, this.floatLabelType, this.showClearButton);
|
|
13545
|
+
}
|
|
13531
13546
|
this.valueWithMinutes = newProp.value;
|
|
13532
13547
|
this.setProperties({ value: newProp.value }, true);
|
|
13533
13548
|
if (this.popupObj) {
|