@kris701/ez-ui 1.2.15 → 1.2.16

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.
@@ -3421,8 +3421,7 @@ class EzUITablePresets {
3421
3421
  const current = this.currentPreset();
3422
3422
  if (current?.id == id) {
3423
3423
  if (presets.length > 0) {
3424
- this.currentPreset.set(presets[0]);
3425
- this.onPresetChange.emit(presets[0]);
3424
+ this.selectPreset(presets[0].id);
3426
3425
  }
3427
3426
  else {
3428
3427
  this.currentPreset.set(null);
@@ -3430,6 +3429,8 @@ class EzUITablePresets {
3430
3429
  }
3431
3430
  }
3432
3431
  this.savePresets();
3432
+ if (presets.length == 0)
3433
+ this.table.clearFilters();
3433
3434
  }
3434
3435
  savePresets() {
3435
3436
  if (this.storageKey) {
@@ -4307,8 +4308,8 @@ class EzUITableDateFilter {
4307
4308
  }
4308
4309
  this.filterType.set(type);
4309
4310
  let forceReapply = false;
4310
- if (typeof filter.value[0] == 'string') {
4311
- this.value = TuiDay.jsonParse(filter.value[0]);
4311
+ if (typeof filter.value == 'string') {
4312
+ this.value = TuiDay.jsonParse(filter.value);
4312
4313
  forceReapply = true;
4313
4314
  }
4314
4315
  else {