@acorex/components 16.20.12 → 16.20.14

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.
@@ -1048,24 +1048,24 @@ class AXCalendarBoxComponent {
1048
1048
  dir;
1049
1049
  _min;
1050
1050
  set min(v) {
1051
+ this._min = v;
1051
1052
  if (v) {
1052
1053
  this.focusedValue = this.today;
1053
1054
  this.viewRange = this.today.month.range;
1054
1055
  this.navigate(0);
1055
1056
  }
1056
- this._min = v;
1057
1057
  }
1058
1058
  get min() {
1059
1059
  return this._min;
1060
1060
  }
1061
1061
  _max;
1062
1062
  set max(v) {
1063
+ this._max = v;
1063
1064
  if (v) {
1064
1065
  this.focusedValue = this.today;
1065
1066
  this.viewRange = this.today.month.range;
1066
1067
  this.navigate(0);
1067
1068
  }
1068
- this._max = v;
1069
1069
  }
1070
1070
  get max() {
1071
1071
  return this._max;
@@ -15350,35 +15350,14 @@ class AXTimePickerComponent extends AXBaseTextComponent {
15350
15350
  this.input.nativeElement.focus();
15351
15351
  }
15352
15352
  handleInputBlur(e) {
15353
- if (this.textValue.indexOf('-') !== -1) {
15354
- switch (this.type) {
15355
- case 'HHmmss':
15356
- this.textValue = '--:--:--';
15357
- break;
15358
- case 'HHmm':
15359
- this.textValue = '--:--';
15360
- break;
15361
- case 'HH':
15362
- this.textValue = '--';
15363
- break;
15364
- case 'hhmmss':
15365
- this.textValue = '--:--:--';
15366
- break;
15367
- case 'hhmm':
15368
- this.textValue = '--:--';
15369
- break;
15370
- case 'hh':
15371
- this.textValue = '--';
15372
- break;
15373
- case 'hhmmssam':
15374
- this.textValue = this.valueSam;
15375
- break;
15376
- case 'hhmmam':
15377
- this.textValue = this.valueMam;
15378
- break;
15379
- case 'hham':
15380
- this.textValue = this.valueHam;
15381
- break;
15353
+ if (this.type === 'HHmm') {
15354
+ const v = this.textValue;
15355
+ if ((v && /^\d{2}[::](-|-_|__|--)$/.test(v)) || /^\d{2}:\D\D$/.test(v)) {
15356
+ const hour = Number(v.substring(0, 2));
15357
+ if (hour >= 0 && hour <= 23) {
15358
+ this.value = `${v.substring(0, 2)}:00`;
15359
+ return;
15360
+ }
15382
15361
  }
15383
15362
  }
15384
15363
  }