s/block/blacklist for e2e
Fixes https://github.com/vector-im/vector-web/issues/2315
This commit is contained in:
parent
1a4163747e
commit
c7fb83ed2d
3 changed files with 17 additions and 17 deletions
|
@ -83,7 +83,7 @@ module.exports = React.createClass({
|
||||||
|
|
||||||
var verificationStatus = (<b>NOT verified</b>);
|
var verificationStatus = (<b>NOT verified</b>);
|
||||||
if (device.isBlocked()) {
|
if (device.isBlocked()) {
|
||||||
verificationStatus = (<b>Blocked</b>);
|
verificationStatus = (<b>Blacklisted</b>);
|
||||||
} else if (device.isVerified()) {
|
} else if (device.isVerified()) {
|
||||||
verificationStatus = "verified";
|
verificationStatus = "verified";
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,7 +49,7 @@ export default React.createClass({
|
||||||
<p>
|
<p>
|
||||||
If it matches, press the verify button below.
|
If it matches, press the verify button below.
|
||||||
If it doesnt, then someone else is intercepting this device
|
If it doesnt, then someone else is intercepting this device
|
||||||
and you probably want to press the block button instead.
|
and you probably want to press the blacklist button instead.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
In future this verification process will be more sophisticated.
|
In future this verification process will be more sophisticated.
|
||||||
|
@ -73,33 +73,33 @@ export default React.createClass({
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
onBlockClick: function() {
|
onBlacklistClick: function() {
|
||||||
MatrixClientPeg.get().setDeviceBlocked(
|
MatrixClientPeg.get().setDeviceBlocked(
|
||||||
this.props.userId, this.props.device.deviceId, true
|
this.props.userId, this.props.device.deviceId, true
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
onUnblockClick: function() {
|
onUnblacklistClick: function() {
|
||||||
MatrixClientPeg.get().setDeviceBlocked(
|
MatrixClientPeg.get().setDeviceBlocked(
|
||||||
this.props.userId, this.props.device.deviceId, false
|
this.props.userId, this.props.device.deviceId, false
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
render: function() {
|
render: function() {
|
||||||
var blockButton = null, verifyButton = null;
|
var blacklistButton = null, verifyButton = null;
|
||||||
|
|
||||||
if (this.props.device.isBlocked()) {
|
if (this.props.device.isBlocked()) {
|
||||||
blockButton = (
|
blacklistButton = (
|
||||||
<button className="mx_MemberDeviceInfo_textButton mx_MemberDeviceInfo_unblock"
|
<button className="mx_MemberDeviceInfo_textButton mx_MemberDeviceInfo_unblacklist"
|
||||||
onClick={this.onUnblockClick}>
|
onClick={this.onUnblacklistClick}>
|
||||||
Unblock
|
Unblacklist
|
||||||
</button>
|
</button>
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
blockButton = (
|
blacklistButton = (
|
||||||
<button className="mx_MemberDeviceInfo_textButton mx_MemberDeviceInfo_block"
|
<button className="mx_MemberDeviceInfo_textButton mx_MemberDeviceInfo_blacklist"
|
||||||
onClick={this.onBlockClick}>
|
onClick={this.onBlacklistClick}>
|
||||||
Block
|
Blacklist
|
||||||
</button>
|
</button>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -115,7 +115,7 @@ export default React.createClass({
|
||||||
verifyButton = (
|
verifyButton = (
|
||||||
<button className="mx_MemberDeviceInfo_textButton mx_MemberDeviceInfo_verify"
|
<button className="mx_MemberDeviceInfo_textButton mx_MemberDeviceInfo_verify"
|
||||||
onClick={this.onVerifyClick}>
|
onClick={this.onVerifyClick}>
|
||||||
Verify
|
Verify...
|
||||||
</button>
|
</button>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -124,7 +124,7 @@ export default React.createClass({
|
||||||
return (
|
return (
|
||||||
<div className="mx_MemberDeviceInfo mx_DeviceVerifyButtons" >
|
<div className="mx_MemberDeviceInfo mx_DeviceVerifyButtons" >
|
||||||
{ verifyButton }
|
{ verifyButton }
|
||||||
{ blockButton }
|
{ blacklistButton }
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
|
@ -24,8 +24,8 @@ export default class MemberDeviceInfo extends React.Component {
|
||||||
|
|
||||||
if (this.props.device.isBlocked()) {
|
if (this.props.device.isBlocked()) {
|
||||||
indicator = (
|
indicator = (
|
||||||
<div className="mx_MemberDeviceInfo_blocked">
|
<div className="mx_MemberDeviceInfo_blacklisted">
|
||||||
<img src="img/e2e-blocked.svg" width="12" height="12" style={{ marginLeft: "-1px" }} alt="Blocked"/>
|
<img src="img/e2e-blocked.svg" width="12" height="12" style={{ marginLeft: "-1px" }} alt="Blacklisted"/>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
} else if (this.props.device.isVerified()) {
|
} else if (this.props.device.isVerified()) {
|
||||||
|
|
Loading…
Reference in a new issue