More useful block-state information in embeds (#1150)

* More useful block-state information in embeds

* Tune copy
This commit is contained in:
Paul Frazee 2023-08-10 16:25:11 -07:00 committed by GitHub
parent ac6f6eef66
commit e5b7a894a3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 32 additions and 10 deletions

View file

@ -18,16 +18,23 @@ export function describeModerationCause(
}
if (cause.type === 'blocking') {
return {
name: 'Blocked User',
name: 'User Blocked',
description: 'You have blocked this user. You cannot view their content.',
}
}
if (cause.type === 'blocked-by') {
return {
name: 'Blocking You',
name: 'User Blocking You',
description: 'This user has blocked you. You cannot view their content.',
}
}
if (cause.type === 'block-other') {
return {
name: 'Content Not Available',
description:
'This content is not available because one of the users involved has blocked the other.',
}
}
if (cause.type === 'muted') {
if (cause.source.type === 'list') {
return {