@@ -3,7 +3,7 @@ import React, { useState, useRef } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import './Message.scss';
|
||||
|
||||
import linkifyHtml from 'linkify-html';
|
||||
import linkifyHtml from 'linkifyjs/html';
|
||||
import parse from 'html-react-parser';
|
||||
import twemoji from 'twemoji';
|
||||
import dateFormat from 'dateformat';
|
||||
@@ -106,8 +106,8 @@ function MessageBody({
|
||||
if (typeof body !== 'string') return <div className="message__body">{body}</div>;
|
||||
|
||||
let content = isCustomHTML ? sanitizeCustomHtml(body) : body;
|
||||
content = linkifyHtml(content, { target: '_blank', rel: 'noreferrer noopener' });
|
||||
if (!isCustomHTML) content = sanitizeText(body);
|
||||
content = linkifyHtml(content, { target: '_blank', rel: 'noreferrer noopener' });
|
||||
content = twemoji.parse(content);
|
||||
|
||||
const parsed = parse(content);
|
||||
|
||||
@@ -2,7 +2,7 @@ import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import './RoomIntro.scss';
|
||||
|
||||
import Linkify from 'linkify-react';
|
||||
import Linkify from 'linkifyjs/react';
|
||||
import colorMXID from '../../../util/colorMXID';
|
||||
|
||||
import Text from '../../atoms/text/Text';
|
||||
|
||||
@@ -2,7 +2,7 @@ import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import './RoomTile.scss';
|
||||
|
||||
import Linkify from 'linkify-react';
|
||||
import Linkify from 'linkifyjs/react';
|
||||
import colorMXID from '../../../util/colorMXID';
|
||||
|
||||
import Text from '../../atoms/text/Text';
|
||||
|
||||
Reference in New Issue
Block a user