mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 04:53:36 +00:00
filter-topic: Fix Escape keyboard handling in "Filter topics" input.
Previously, pressing Esc while the "Filter topics" input was empty would de-focus the input. Pressing Esc again would trigger the "BACK TO CHANNEL" action, hiding the zoomed topic. However, this behavior was broken as the input was not triggering any blur event, making Esc a noop. This commit restores the expected behavior by ensuring the blur event is properly triggered, allowing Esc to function as intended.
This commit is contained in:
committed by
Tim Abbott
parent
aef9f1d331
commit
021d6cb169
@@ -389,6 +389,7 @@ export function clear_topic_search(e: JQuery.Event): void {
|
||||
search_pill_widget?.clear(true);
|
||||
|
||||
const $input = $("#topic_filter_query");
|
||||
$input.trigger("blur");
|
||||
// Since the `clear` function of the search_pill_widget
|
||||
// takes care of clearing both the text content and the
|
||||
// pills, we just need to trigger an input event on the
|
||||
|
||||
Reference in New Issue
Block a user