This repository was archived by the owner on Sep 11, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,10 +21,10 @@ var sanitizeHtml = require('sanitize-html');
2121var highlight = require ( 'highlight.js' ) ;
2222var linkifyMatrix = require ( './linkify-matrix' ) ;
2323import escape from 'lodash/escape' ;
24- import { unicodeToImage , unicodeRegexp } from 'emojione' ;
24+ import emojione from 'emojione' ;
2525import classNames from 'classnames' ;
2626
27- const EMOJI_REGEX = new RegExp ( unicodeRegexp + "+" , "gi" ) ;
27+ const EMOJI_REGEX = new RegExp ( emojione . unicodeRegexp + "+" , "gi" ) ;
2828
2929var sanitizeHtmlParams = {
3030 allowedTags : [
@@ -209,7 +209,8 @@ module.exports = {
209209 } ;
210210 }
211211 safeBody = sanitizeHtml ( body , sanitizeHtmlParams ) ;
212- safeBody = unicodeToImage ( safeBody ) ;
212+ emojione . imageType = 'svg' ;
213+ safeBody = emojione . unicodeToImage ( safeBody ) ;
213214 }
214215 finally {
215216 delete sanitizeHtmlParams . textFilter ;
You can’t perform that action at this time.
0 commit comments