diff --git a/web/src/stream_popover.ts b/web/src/stream_popover.ts index 45c3cbfb21..9dbef6d169 100644 --- a/web/src/stream_popover.ts +++ b/web/src/stream_popover.ts @@ -884,6 +884,7 @@ export async function build_move_topic_to_stream_popover( set_stream_topic_typeahead(); render_selected_stream(); maybe_show_topic_already_exists_warning(); + update_clear_move_topic_button_state(); update_topic_input_placeholder_visibility(topic_input_value); const selected_propagate_mode = String($("#message_move_select_options").val()); void warn_unsubscribed_participants(selected_propagate_mode); @@ -989,7 +990,7 @@ export async function build_move_topic_to_stream_popover( function update_clear_move_topic_button_state(): void { const $clear_topic_name_button = $("#clear_move_topic_new_topic_name"); const topic_input_value = $("input#move-topic-new-topic-name").val(); - if (topic_input_value === "") { + if (topic_input_value === "" || $("input#move-topic-new-topic-name").prop("disabled")) { $clear_topic_name_button.css("visibility", "hidden"); } else { $clear_topic_name_button.css("visibility", "visible"); diff --git a/web/templates/move_topic_to_stream.hbs b/web/templates/move_topic_to_stream.hbs index 2bf0ef2970..7370930c03 100644 --- a/web/templates/move_topic_to_stream.hbs +++ b/web/templates/move_topic_to_stream.hbs @@ -14,11 +14,9 @@ {{> topic_not_mandatory_placeholder_text empty_string_topic_display_name=empty_string_topic_display_name}} - {{#unless disable_topic_input}} - {{/unless}}