@syncfusion/ej2-calendars 29.1.33 → 29.1.39
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/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 +13 -5
- package/dist/es6/ej2-calendars.es2015.js.map +1 -1
- package/dist/es6/ej2-calendars.es5.js +13 -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 +10 -10
- package/src/calendar/calendar.js +11 -4
- package/src/timepicker/timepicker.js +2 -1
|
@@ -1413,12 +1413,18 @@ let CalendarBase = class CalendarBase extends Component {
|
|
|
1413
1413
|
for (let skipIndex = 0; skipIndex < copyValues.length; skipIndex++) {
|
|
1414
1414
|
const tempValue = copyValues[skipIndex];
|
|
1415
1415
|
const type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';
|
|
1416
|
+
let tempValueFormat;
|
|
1416
1417
|
let tempValueString;
|
|
1418
|
+
let tempValueDate;
|
|
1417
1419
|
if (this.calendarMode === 'Gregorian') {
|
|
1418
|
-
|
|
1420
|
+
tempValueFormat = { type: 'date', skeleton: 'yMd' };
|
|
1421
|
+
tempValueString = this.globalize.formatDate(tempValue, tempValueFormat);
|
|
1422
|
+
tempValueDate = this.globalize.parseDate(tempValueString, tempValueFormat);
|
|
1419
1423
|
}
|
|
1420
1424
|
else {
|
|
1421
|
-
|
|
1425
|
+
tempValueFormat = { type: 'date', skeleton: 'yMd', calendar: 'islamic' };
|
|
1426
|
+
tempValueString = this.globalize.formatDate(tempValue, tempValueFormat);
|
|
1427
|
+
tempValueDate = this.globalize.parseDate(tempValueString, tempValueFormat);
|
|
1422
1428
|
}
|
|
1423
1429
|
const minFormatOption = { type: 'date', skeleton: 'yMd', calendar: type };
|
|
1424
1430
|
const minStringValue = this.globalize.formatDate(this.min, minFormatOption);
|
|
@@ -1426,8 +1432,9 @@ let CalendarBase = class CalendarBase extends Component {
|
|
|
1426
1432
|
const maxFormatOption = { type: 'date', skeleton: 'yMd', calendar: type };
|
|
1427
1433
|
const maxStringValue = this.globalize.formatDate(this.max, maxFormatOption);
|
|
1428
1434
|
const maxString = maxStringValue;
|
|
1429
|
-
|
|
1430
|
-
|
|
1435
|
+
const minDate = this.globalize.parseDate(minString, minFormatOption);
|
|
1436
|
+
const maxDate = this.globalize.parseDate(maxString, maxFormatOption);
|
|
1437
|
+
if (+tempValueDate < +minDate || +tempValueDate > +maxDate) {
|
|
1431
1438
|
copyValues.splice(skipIndex, 1);
|
|
1432
1439
|
skipIndex = -1;
|
|
1433
1440
|
}
|
|
@@ -11998,7 +12005,8 @@ let TimePicker = class TimePicker extends Component {
|
|
|
11998
12005
|
const formatStr = null;
|
|
11999
12006
|
let today = this.globalize.formatDate(new Date(), { format: formatStr, skeleton: 'short', type: 'date' });
|
|
12000
12007
|
let value = null;
|
|
12001
|
-
if (typeof val === 'string'
|
|
12008
|
+
if (typeof val === 'string' && !(this.enableMask && this.maskedDateValue &&
|
|
12009
|
+
this.inputElement.value === this.maskedDateValue && !this.value)) {
|
|
12002
12010
|
if (val.toUpperCase().indexOf('AM') > -1 || val.toUpperCase().indexOf('PM') > -1) {
|
|
12003
12011
|
today = this.defaultCulture.formatDate(new Date(), { format: formatStr, skeleton: 'short', type: 'date' });
|
|
12004
12012
|
value = isNaN(+new Date(today + ' ' + val)) ? null : new Date(new Date(today + ' ' + val).setMilliseconds(0));
|