mirror of
https://github.com/element-hq/element-web
synced 2024-11-26 11:15:53 +03:00
only try to syntax highlight html
This commit is contained in:
parent
9038b984ff
commit
01641543da
2 changed files with 8 additions and 4 deletions
|
@ -26,11 +26,13 @@ module.exports = React.createClass({
|
||||||
mixins: [MNoticeTileController],
|
mixins: [MNoticeTileController],
|
||||||
|
|
||||||
componentDidMount: function() {
|
componentDidMount: function() {
|
||||||
HtmlUtils.highlightDom(this.getDOMNode());
|
if (this.props.mxEvent.getContent().format === "org.matrix.custom.html")
|
||||||
|
HtmlUtils.highlightDom(this.getDOMNode());
|
||||||
},
|
},
|
||||||
|
|
||||||
componentDidUpdate: function() {
|
componentDidUpdate: function() {
|
||||||
HtmlUtils.highlightDom(this.getDOMNode());
|
if (this.props.mxEvent.getContent().format === "org.matrix.custom.html")
|
||||||
|
HtmlUtils.highlightDom(this.getDOMNode());
|
||||||
},
|
},
|
||||||
|
|
||||||
shouldComponentUpdate: function(nextProps) {
|
shouldComponentUpdate: function(nextProps) {
|
||||||
|
|
|
@ -26,11 +26,13 @@ module.exports = React.createClass({
|
||||||
mixins: [MTextTileController],
|
mixins: [MTextTileController],
|
||||||
|
|
||||||
componentDidMount: function() {
|
componentDidMount: function() {
|
||||||
HtmlUtils.highlightDom(this.getDOMNode());
|
if (this.props.mxEvent.getContent().format === "org.matrix.custom.html")
|
||||||
|
HtmlUtils.highlightDom(this.getDOMNode());
|
||||||
},
|
},
|
||||||
|
|
||||||
componentDidUpdate: function() {
|
componentDidUpdate: function() {
|
||||||
HtmlUtils.highlightDom(this.getDOMNode());
|
if (this.props.mxEvent.getContent().format === "org.matrix.custom.html")
|
||||||
|
HtmlUtils.highlightDom(this.getDOMNode());
|
||||||
},
|
},
|
||||||
|
|
||||||
shouldComponentUpdate: function(nextProps) {
|
shouldComponentUpdate: function(nextProps) {
|
||||||
|
|
Loading…
Reference in a new issue