diff --git a/src/skins/vector/views/molecules/EventAsTextTile.js b/src/skins/vector/views/molecules/EventAsTextTile.js index 445303e4a1..fe79dd3aae 100644 --- a/src/skins/vector/views/molecules/EventAsTextTile.js +++ b/src/skins/vector/views/molecules/EventAsTextTile.js @@ -19,22 +19,22 @@ limitations under the License. var React = require('react'); var EventAsTextTileController = require('matrix-react-sdk/lib/controllers/molecules/EventAsTextTile') -var sdk = require('matrix-react-sdk') var TextForEvent = require('matrix-react-sdk/lib/TextForEvent'); module.exports = React.createClass({ displayName: 'EventAsTextTile', mixins: [EventAsTextTileController], - render: function() { - var MessageTimestamp = sdk.getComponent('atoms.MessageTimestamp'); - var MemberAvatar = sdk.getComponent('atoms.MemberAvatar'); + statics: { + needsSenderProfile: function() { + return false; + } + }, + render: function() { var text = TextForEvent.textForEvent(this.props.mxEvent); if (text == null || text.length == 0) return null; - var timestamp = this.props.last ? : null; - var avatar = this.props.mxEvent.sender ? : null; return (
{TextForEvent.textForEvent(this.props.mxEvent)} diff --git a/src/skins/vector/views/molecules/EventTile.js b/src/skins/vector/views/molecules/EventTile.js index 534af3c7c8..1b1642bde4 100644 --- a/src/skins/vector/views/molecules/EventTile.js +++ b/src/skins/vector/views/molecules/EventTile.js @@ -114,7 +114,9 @@ module.exports = React.createClass({
); } - sender = ; + if (EventTileType.needsSenderProfile()) { + sender = ; + } } return (
diff --git a/src/skins/vector/views/molecules/MessageTile.js b/src/skins/vector/views/molecules/MessageTile.js index 5e83505029..44f5b63564 100644 --- a/src/skins/vector/views/molecules/MessageTile.js +++ b/src/skins/vector/views/molecules/MessageTile.js @@ -28,6 +28,12 @@ module.exports = React.createClass({ displayName: 'MessageTile', mixins: [MessageTileController], + statics: { + needsSenderProfile: function() { + return true; + } + }, + render: function() { var UnknownMessageTile = sdk.getComponent('molecules.UnknownMessageTile');