mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 05:23:35 +00:00
markdown: Parse '/me' for multi-line messages.
Previously, messages with more than one line did not parse '/me' at the beginning of the message. Since there's a reasonable way to render multi-line messages, this commit adds support for doing so. This change does potentially break with the expected behavior of other slash commands, but it seems worth providing useful functionality over a blind focus on consistency. Fixes #11025.
This commit is contained in:
@@ -136,9 +136,8 @@ exports.add_topic_links = function (message) {
|
||||
|
||||
exports.is_status_message = function (raw_content, content) {
|
||||
return raw_content.indexOf('/me ') === 0 &&
|
||||
raw_content.indexOf('\n') === -1 &&
|
||||
content.indexOf('<p>') === 0 &&
|
||||
content.lastIndexOf('</p>') === content.length - 4;
|
||||
content.indexOf('</p>') !== -1;
|
||||
};
|
||||
|
||||
function handleUnicodeEmoji(unicode_emoji) {
|
||||
|
||||
Reference in New Issue
Block a user