summaryrefslogtreecommitdiffstats
path: root/web/react/utils/text_formatting.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/utils/text_formatting.jsx')
-rw-r--r--web/react/utils/text_formatting.jsx9
1 files changed, 9 insertions, 0 deletions
diff --git a/web/react/utils/text_formatting.jsx b/web/react/utils/text_formatting.jsx
index d79aeed68..5c2e68f1e 100644
--- a/web/react/utils/text_formatting.jsx
+++ b/web/react/utils/text_formatting.jsx
@@ -69,6 +69,15 @@ export function doFormatText(text, options) {
return output;
}
+export function doFormatEmoticons(text) {
+ const tokens = new Map();
+
+ let output = Emoticons.handleEmoticons(text, tokens);
+ output = replaceTokens(output, tokens);
+
+ return output;
+}
+
export function sanitizeHtml(text) {
let output = text;