diff --git a/libs/barista-components/filter-field/src/filter-field.ts b/libs/barista-components/filter-field/src/filter-field.ts index 098f7d1363..23ec71475a 100644 --- a/libs/barista-components/filter-field/src/filter-field.ts +++ b/libs/barista-components/filter-field/src/filter-field.ts @@ -1107,6 +1107,16 @@ export class DtFilterField this._removeFilter(this._currentFilterValues); this._currentFilterValues = []; this._filterByLabel = ''; + + // If the current def is a range during the reset, + // we need to handle a couple of extra things about the range, i.e. + // closing it and restoring the focus. + if (isDtRangeDef(this._currentDef)) { + if (this._filterfieldRange.isOpen) { + this._filterfieldRangeTrigger.closePanel(); + this.focus(); + } + } } this._currentDef = def; this._updateControl();