You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-08 21:42:24 +03:00
feat: emojify ALL THE THINGS!
This commit is contained in:
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
var React = require('react');
|
||||
|
||||
var TextForEvent = require('../../../TextForEvent');
|
||||
import {emojifyText} from '../../../HtmlUtils';
|
||||
|
||||
module.exports = React.createClass({
|
||||
displayName: 'TextualEvent',
|
||||
@@ -31,11 +32,11 @@ module.exports = React.createClass({
|
||||
|
||||
render: function() {
|
||||
var text = TextForEvent.textForEvent(this.props.mxEvent);
|
||||
if (text == null || text.length == 0) return null;
|
||||
if (text == null || text.length === 0) return null;
|
||||
let textHTML = emojifyText(TextForEvent.textForEvent(this.props.mxEvent));
|
||||
|
||||
return (
|
||||
<div className="mx_TextualEvent">
|
||||
{TextForEvent.textForEvent(this.props.mxEvent)}
|
||||
<div className="mx_TextualEvent" dangerouslySetInnerHTML={textHTML}>
|
||||
</div>
|
||||
);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user