feat: Trim whitespace from message bodies and enhance emoji usage integration

This commit is contained in:
2026-05-13 05:17:23 +10:00
parent 38a43a3a99
commit aaf8089ba6
5 changed files with 50 additions and 4 deletions

View File

@@ -80,7 +80,7 @@ export function MText({ edited, content, renderBody, renderUrlsPreview, style }:
const { body, formatted_body: customBody } = content;
if (typeof body !== 'string') return <BrokenContent />;
const trimmedBody = trimReplyFromBody(body);
const trimmedBody = trimReplyFromBody(body).trim();
const urlsMatch = renderUrlsPreview && trimmedBody.match(URL_REG);
const urls = urlsMatch ? [...new Set(urlsMatch)] : undefined;