Allow user to choose from existing DMs on new chat
When creating a new chat with one person, show a dialog that asks the user whether they'd like to use an existing chat or actually create a new room. Fixes https://github.com/vector-im/riot-web/issues/2760
This commit is contained in:
parent
6a007d01a1
commit
ca5c2fb82e
4 changed files with 142 additions and 24 deletions
|
@ -35,6 +35,7 @@ module.exports = React.createClass({
|
|||
propTypes: {
|
||||
connectDragSource: React.PropTypes.func,
|
||||
connectDropTarget: React.PropTypes.func,
|
||||
onClick: React.PropTypes.func,
|
||||
isDragging: React.PropTypes.bool,
|
||||
|
||||
room: React.PropTypes.object.isRequired,
|
||||
|
@ -104,6 +105,9 @@ module.exports = React.createClass({
|
|||
action: 'view_room',
|
||||
room_id: this.props.room.roomId,
|
||||
});
|
||||
if (this.props.onClick) {
|
||||
this.props.onClick();
|
||||
}
|
||||
},
|
||||
|
||||
onMouseEnter: function() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue