mirror of
https://github.com/zulip/zulip.git
synced 2025-11-07 23:43:43 +00:00
compose: Use insert_syntax_and_focus to insert text in compose textarea.
Use compose_ui.insert_syntax_and_focus() when we need to insert text inline-ly followed by the focus to compose textarea because it does this job more smartly(it take cares of spaces).
This commit is contained in:
committed by
Tim Abbott
parent
c995c1a36a
commit
dcac002213
@@ -320,7 +320,7 @@ exports.reply_with_mention = function (opts) {
|
||||
exports.respond_to_message(opts);
|
||||
var message = current_msg_list.selected_message();
|
||||
var mention = '@**' + message.sender_full_name + '**';
|
||||
$('#compose-textarea').val(mention + ' ');
|
||||
compose_ui.insert_syntax_and_focus(mention);
|
||||
};
|
||||
|
||||
exports.on_topic_narrow = function () {
|
||||
|
||||
Reference in New Issue
Block a user