mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-17 14:05:04 +08:00
Handle redaction with no sender
This commit is contained in:
parent
5990e41bd7
commit
cedc0b27a9
@ -25,9 +25,10 @@ module.exports = React.createClass({
|
||||
render: function() {
|
||||
let tooltip = _t("Removed or unknown message type");
|
||||
if (this.props.mxEvent.isRedacted()) {
|
||||
tooltip = _t("Message removed by %(userId)s", {
|
||||
userId: this.props.mxEvent.getUnsigned().redacted_because.sender,
|
||||
});
|
||||
const redactedBecauseUserId = this.props.mxEvent.getUnsigned().redacted_because.sender;
|
||||
tooltip = redactedBecauseUserId ?
|
||||
_t("Message removed by %(userId)s", { userId: redactedBecauseUserId }) :
|
||||
_t("Message removed");
|
||||
}
|
||||
|
||||
const text = this.props.mxEvent.getContent().body;
|
||||
|
@ -200,8 +200,6 @@
|
||||
"Authentication": "Authentication",
|
||||
"Failed to delete device": "Failed to delete device",
|
||||
"Delete": "Delete",
|
||||
"Delete Widget": "Delete Widget",
|
||||
"Deleting a widget removes it for all users in this room. Are you sure you want to delete this widget?": "Deleting a widget removes it for all users in this room. Are you sure you want to delete this widget?",
|
||||
"Disable Notifications": "Disable Notifications",
|
||||
"Enable Notifications": "Enable Notifications",
|
||||
"Cannot add any more widgets": "Cannot add any more widgets",
|
||||
@ -452,6 +450,7 @@
|
||||
"You are about to be taken to a third-party site so you can authenticate your account for use with %(integrationsUrl)s. Do you wish to continue?": "You are about to be taken to a third-party site so you can authenticate your account for use with %(integrationsUrl)s. Do you wish to continue?",
|
||||
"Removed or unknown message type": "Removed or unknown message type",
|
||||
"Message removed by %(userId)s": "Message removed by %(userId)s",
|
||||
"Message removed": "Message removed",
|
||||
"Robot check is currently unavailable on desktop - please use a <a>web browser</a>": "Robot check is currently unavailable on desktop - please use a <a>web browser</a>",
|
||||
"This Home Server would like to make sure you are not a robot": "This Home Server would like to make sure you are not a robot",
|
||||
"Sign in with CAS": "Sign in with CAS",
|
||||
@ -499,6 +498,8 @@
|
||||
"NOTE: Apps are not end-to-end encrypted": "NOTE: Apps are not end-to-end encrypted",
|
||||
"Do you want to load widget from URL:": "Do you want to load widget from URL:",
|
||||
"Allow": "Allow",
|
||||
"Delete Widget": "Delete Widget",
|
||||
"Deleting a widget removes it for all users in this room. Are you sure you want to delete this widget?": "Deleting a widget removes it for all users in this room. Are you sure you want to delete this widget?",
|
||||
"Delete widget": "Delete widget",
|
||||
"Revoke widget access": "Revoke widget access",
|
||||
"Edit": "Edit",
|
||||
@ -678,17 +679,17 @@
|
||||
"Leave %(groupName)s?": "Leave %(groupName)s?",
|
||||
"Leave": "Leave",
|
||||
"Unable to leave room": "Unable to leave room",
|
||||
"Community Settings": "Community Settings",
|
||||
"Add rooms to this community": "Add rooms to this community",
|
||||
"Featured Rooms:": "Featured Rooms:",
|
||||
"Featured Users:": "Featured Users:",
|
||||
"%(inviter)s has invited you to join this community": "%(inviter)s has invited you to join this community",
|
||||
"You are a member of this community": "You are a member of this community",
|
||||
"You are an administrator of this community": "You are an administrator of this community",
|
||||
"You are a member of this community": "You are a member of this community",
|
||||
"Community Member Settings": "Community Member Settings",
|
||||
"Publish this community on your profile": "Publish this community on your profile",
|
||||
"Long Description (HTML)": "Long Description (HTML)",
|
||||
"Description": "Description",
|
||||
"Community Settings": "Community Settings",
|
||||
"Community %(groupId)s not found": "Community %(groupId)s not found",
|
||||
"This Home server does not support communities": "This Home server does not support communities",
|
||||
"Failed to load %(groupId)s": "Failed to load %(groupId)s",
|
||||
|
Loading…
Reference in New Issue
Block a user