mirror of https://github.com/vector-im/riot-web
Merge remote-tracking branch 'origin/develop' into develop
commit
f8db8fdd9b
|
@ -118,6 +118,9 @@ function textForTopicEvent(ev) {
|
||||||
function textForRoomNameEvent(ev) {
|
function textForRoomNameEvent(ev) {
|
||||||
var senderDisplayName = ev.sender && ev.sender.name ? ev.sender.name : ev.getSender();
|
var senderDisplayName = ev.sender && ev.sender.name ? ev.sender.name : ev.getSender();
|
||||||
|
|
||||||
|
if (!ev.getContent().name || ev.getContent().name.trim().length === 0) {
|
||||||
|
return _t('%(senderDisplayName)s removed the room name.', {senderDisplayName: senderDisplayName});
|
||||||
|
}
|
||||||
return _t('%(senderDisplayName)s changed the room name to %(roomName)s.', {senderDisplayName: senderDisplayName, roomName: ev.getContent().name});
|
return _t('%(senderDisplayName)s changed the room name to %(roomName)s.', {senderDisplayName: senderDisplayName, roomName: ev.getContent().name});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1502,8 +1502,7 @@ module.exports = React.createClass({
|
||||||
<Loader />
|
<Loader />
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
var inviterName = undefined;
|
var inviterName = undefined;
|
||||||
if (this.props.oobData) {
|
if (this.props.oobData) {
|
||||||
inviterName = this.props.oobData.inviterName;
|
inviterName = this.props.oobData.inviterName;
|
||||||
|
@ -1622,13 +1621,15 @@ module.exports = React.createClass({
|
||||||
}
|
}
|
||||||
|
|
||||||
let aux = null;
|
let aux = null;
|
||||||
if (this.state.forwardingEvent !== null) {
|
let hideCancel = false;
|
||||||
aux = <ForwardMessage onCancelClick={this.onCancelClick} currentRoomId={this.state.room.roomId} mxEvent={this.state.forwardingEvent} />;
|
if (this.state.editingRoomSettings) {
|
||||||
} else if (this.state.editingRoomSettings) {
|
|
||||||
aux = <RoomSettings ref="room_settings" onSaveClick={this.onSettingsSaveClick} onCancelClick={this.onCancelClick} room={this.state.room} />;
|
aux = <RoomSettings ref="room_settings" onSaveClick={this.onSettingsSaveClick} onCancelClick={this.onCancelClick} room={this.state.room} />;
|
||||||
} else if (this.state.uploadingRoomSettings) {
|
} else if (this.state.uploadingRoomSettings) {
|
||||||
aux = <Loader/>;
|
aux = <Loader/>;
|
||||||
|
} else if (this.state.forwardingEvent !== null) {
|
||||||
|
aux = <ForwardMessage onCancelClick={this.onCancelClick} currentRoomId={this.state.room.roomId} mxEvent={this.state.forwardingEvent} />;
|
||||||
} else if (this.state.searching) {
|
} else if (this.state.searching) {
|
||||||
|
hideCancel = true; // has own cancel
|
||||||
aux = <SearchBar ref="search_bar" searchInProgress={this.state.searchInProgress } onCancelClick={this.onCancelSearchClick} onSearch={this.onSearch}/>;
|
aux = <SearchBar ref="search_bar" searchInProgress={this.state.searchInProgress } onCancelClick={this.onCancelSearchClick} onSearch={this.onSearch}/>;
|
||||||
} else if (!myMember || myMember.membership !== "join") {
|
} else if (!myMember || myMember.membership !== "join") {
|
||||||
// We do have a room object for this room, but we're not currently in it.
|
// We do have a room object for this room, but we're not currently in it.
|
||||||
|
@ -1641,6 +1642,7 @@ module.exports = React.createClass({
|
||||||
if (this.props.thirdPartyInvite) {
|
if (this.props.thirdPartyInvite) {
|
||||||
invitedEmail = this.props.thirdPartyInvite.invitedEmail;
|
invitedEmail = this.props.thirdPartyInvite.invitedEmail;
|
||||||
}
|
}
|
||||||
|
hideCancel = true;
|
||||||
aux = (
|
aux = (
|
||||||
<RoomPreviewBar onJoinClick={this.onJoinButtonClicked}
|
<RoomPreviewBar onJoinClick={this.onJoinButtonClicked}
|
||||||
onForgetClick={ this.onForgetClick }
|
onForgetClick={ this.onForgetClick }
|
||||||
|
@ -1787,13 +1789,10 @@ module.exports = React.createClass({
|
||||||
onSearchClick={this.onSearchClick}
|
onSearchClick={this.onSearchClick}
|
||||||
onSettingsClick={this.onSettingsClick}
|
onSettingsClick={this.onSettingsClick}
|
||||||
onSaveClick={this.onSettingsSaveClick}
|
onSaveClick={this.onSettingsSaveClick}
|
||||||
onCancelClick={aux ? this.onCancelClick : null}
|
onCancelClick={(aux && !hideCancel) ? this.onCancelClick : null}
|
||||||
onForgetClick={
|
onForgetClick={(myMember && myMember.membership === "leave") ? this.onForgetClick : null}
|
||||||
(myMember && myMember.membership === "leave") ? this.onForgetClick : null
|
onLeaveClick={(myMember && myMember.membership === "join") ? this.onLeaveClick : null}
|
||||||
}
|
/>
|
||||||
onLeaveClick={
|
|
||||||
(myMember && myMember.membership === "join") ? this.onLeaveClick : null
|
|
||||||
} />
|
|
||||||
{ auxPanel }
|
{ auxPanel }
|
||||||
{ topUnreadMessagesBar }
|
{ topUnreadMessagesBar }
|
||||||
{ messagePanel }
|
{ messagePanel }
|
||||||
|
|
|
@ -174,6 +174,7 @@
|
||||||
"%(senderName)s changed their profile picture.": "%(senderName)s changed their profile picture.",
|
"%(senderName)s changed their profile picture.": "%(senderName)s changed their profile picture.",
|
||||||
"%(senderName)s changed the power level of %(powerLevelDiffText)s.": "%(senderName)s changed the power level of %(powerLevelDiffText)s.",
|
"%(senderName)s changed the power level of %(powerLevelDiffText)s.": "%(senderName)s changed the power level of %(powerLevelDiffText)s.",
|
||||||
"%(senderDisplayName)s changed the room name to %(roomName)s.": "%(senderDisplayName)s changed the room name to %(roomName)s.",
|
"%(senderDisplayName)s changed the room name to %(roomName)s.": "%(senderDisplayName)s changed the room name to %(roomName)s.",
|
||||||
|
"%(senderDisplayName)s removed the room name.": "%(senderDisplayName)s removed the room name.",
|
||||||
"%(senderDisplayName)s changed the topic to \"%(topic)s\".": "%(senderDisplayName)s changed the topic to \"%(topic)s\".",
|
"%(senderDisplayName)s changed the topic to \"%(topic)s\".": "%(senderDisplayName)s changed the topic to \"%(topic)s\".",
|
||||||
"Changes to who can read history will only apply to future messages in this room": "Changes to who can read history will only apply to future messages in this room",
|
"Changes to who can read history will only apply to future messages in this room": "Changes to who can read history will only apply to future messages in this room",
|
||||||
"Changes your display nickname": "Changes your display nickname",
|
"Changes your display nickname": "Changes your display nickname",
|
||||||
|
|
Loading…
Reference in New Issue