Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
left_sidebar: Rename topic search element ID for clarity.
Aman Agrawalf87abce4876c
diff --git a/web/src/hotkey.js b/web/src/hotkey.jsindex f5717644b71..809ca19cd80 100644--- a/web/src/hotkey.js+++ b/web/src/hotkey.js@@ -355,7 +355,7 @@ export function process_escape_key(e) {// When the input is focused, we blur and clear the input. A second "Esc"// will zoom out, handled below.- if (stream_list.is_zoomed_in() && $("#filter-topic-input").is(":focus")) {+ if (stream_list.is_zoomed_in() && $("#left-sidebar-filter-topic-input").is(":focus")) {topic_list.clear_topic_search(e);return true;}diff --git a/web/src/stream_list.ts b/web/src/stream_list.tsindex 728949b42e9..a40ca70e46d 100644--- a/web/src/stream_list.ts+++ b/web/src/stream_list.ts@@ -418,7 +418,7 @@ export function zoom_in_topics(options: {stream_id: number | undefined}): void {$elt.show();// Add search box for topics list.$elt.children("div.bottom_left_row").append($(render_filter_topics()));- $("#filter-topic-input").trigger("focus");+ $("#left-sidebar-filter-topic-input").trigger("focus");} else {$elt.hide();}diff --git a/web/styles/left_sidebar.css b/web/styles/left_sidebar.cssindex c3b3016235a..9c45db58caf 100644--- a/web/styles/left_sidebar.css+++ b/web/styles/left_sidebar.css@@ -1254,7 +1254,8 @@ li.top_left_scheduled_messages {overflow: hidden;}-#filter-topic-input:placeholder-shown + #clear_search_topic_button {+#left-sidebar-filter-topic-input:placeholder-shown+ + #clear_search_topic_button {visibility: hidden;}diff --git a/web/templates/filter_topics.hbs b/web/templates/filter_topics.hbsindex 7e3b0340ab7..026f1bfbb2d 100644--- a/web/templates/filter_topics.hbs+++ b/web/templates/filter_topics.hbs@@ -1,5 +1,5 @@<div class="topic_search_section filter-topics left-sidebar-filter-row">- <input class="topic-list-filter home-page-input filter_text_input" id="filter-topic-input" type="text" autocomplete="off" placeholder="{{t 'Filter topics'}}" />+ <input class="topic-list-filter home-page-input filter_text_input" id="left-sidebar-filter-topic-input" type="text" autocomplete="off" placeholder="{{t 'Filter topics'}}" /><button type="button" class="clear_search_button" id="clear_search_topic_button"><i class="zulip-icon zulip-icon-close" aria-hidden="true"></i></button>