mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 05:23:35 +00:00
message-edit: Add maxlength attribute for editing topic names.
This commit is contained in:
@@ -710,7 +710,11 @@ export function toggle_resolve_topic(message_id, old_topic_name) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function start_inline_topic_edit($recipient_row) {
|
export function start_inline_topic_edit($recipient_row) {
|
||||||
const $form = $(render_topic_edit_form());
|
const $form = $(
|
||||||
|
render_topic_edit_form({
|
||||||
|
max_topic_length: page_params.max_topic_length,
|
||||||
|
}),
|
||||||
|
);
|
||||||
message_lists.current.show_edit_topic_on_recipient_row($recipient_row, $form);
|
message_lists.current.show_edit_topic_on_recipient_row($recipient_row, $form);
|
||||||
$form.on("keydown", handle_inline_topic_edit_keydown);
|
$form.on("keydown", handle_inline_topic_edit_keydown);
|
||||||
$(".topic_edit_spinner").hide();
|
$(".topic_edit_spinner").hide();
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
<form id="topic_edit_form" class="form-horizontal">
|
<form id="topic_edit_form" class="form-horizontal">
|
||||||
<input type="text" value="" class="inline_topic_edit header-v" id="inline_topic_edit"
|
<input type="text" value="" class="inline_topic_edit header-v" id="inline_topic_edit"
|
||||||
autocomplete="off" />
|
autocomplete="off" maxlength="{{ max_topic_length }}" />
|
||||||
<button type="button" class="topic_edit_save small_square_button animated-purple-button"><i class="fa fa-check" aria-hidden="true"></i></button>
|
<button type="button" class="topic_edit_save small_square_button animated-purple-button"><i class="fa fa-check" aria-hidden="true"></i></button>
|
||||||
<button type="button" class="topic_edit_cancel small_square_button small_square_x"><i class="fa fa-remove" aria-hidden="true"></i></button>
|
<button type="button" class="topic_edit_cancel small_square_button small_square_x"><i class="fa fa-remove" aria-hidden="true"></i></button>
|
||||||
<div class="alert alert-error edit_error" style="display: none"></div>
|
<div class="alert alert-error edit_error" style="display: none"></div>
|
||||||
|
|||||||
Reference in New Issue
Block a user