Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Show a gray shield when encrypted by deleted session (#6119)
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonBrandner authored Nov 1, 2021
1 parent 459b5cc commit 5202c0a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 22 deletions.
20 changes: 2 additions & 18 deletions res/css/views/rooms/_EventTile.scss
Original file line number Diff line number Diff line change
Expand Up @@ -432,31 +432,15 @@ $left-gutter: 64px;
}
}

.mx_EventTile_e2eIcon_undecryptable, .mx_EventTile_e2eIcon_unverified {
.mx_EventTile_e2eIcon_warning {
&::after {
mask-image: url('$(res)/img/e2e/warning.svg');
background-color: $notice-primary-color;
}
opacity: 1;
}

.mx_EventTile_e2eIcon_unknown {
&::after {
mask-image: url('$(res)/img/e2e/warning.svg');
background-color: $notice-primary-color;
}
opacity: 1;
}

.mx_EventTile_e2eIcon_unencrypted {
&::after {
mask-image: url('$(res)/img/e2e/warning.svg');
background-color: $notice-primary-color;
}
opacity: 1;
}

.mx_EventTile_e2eIcon_unauthenticated {
.mx_EventTile_e2eIcon_normal {
&::after {
mask-image: url('$(res)/img/e2e/normal.svg');
background-color: $composer-e2e-icon-color;
Expand Down
8 changes: 4 additions & 4 deletions src/components/views/rooms/EventTile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1405,25 +1405,25 @@ export function haveTileForEvent(e: MatrixEvent, showHiddenEvents?: boolean) {

function E2ePadlockUndecryptable(props) {
return (
<E2ePadlock title={_t("This message cannot be decrypted")} icon="undecryptable" {...props} />
<E2ePadlock title={_t("This message cannot be decrypted")} icon="warning" {...props} />
);
}

function E2ePadlockUnverified(props) {
return (
<E2ePadlock title={_t("Encrypted by an unverified session")} icon="unverified" {...props} />
<E2ePadlock title={_t("Encrypted by an unverified session")} icon="warning" {...props} />
);
}

function E2ePadlockUnencrypted(props) {
return (
<E2ePadlock title={_t("Unencrypted")} icon="unencrypted" {...props} />
<E2ePadlock title={_t("Unencrypted")} icon="warning" {...props} />
);
}

function E2ePadlockUnknown(props) {
return (
<E2ePadlock title={_t("Encrypted by a deleted session")} icon="unknown" {...props} />
<E2ePadlock title={_t("Encrypted by a deleted session")} icon="normal" {...props} />
);
}

Expand Down

0 comments on commit 5202c0a

Please sign in to comment.