{#snippet target()}
{/snippet}
{#if ($profile?.user && amMod($profile.user, item.community)) || ($profile?.user && isAdmin($profile.user))}
{#if !item.community.local && !amMod($profile.user, item.community)}
{$t('moderation.labelInstanceOnly')}
{:else}
{$t('moderation.label')}
{/if}
remove(item)}>
{#snippet prefix()}
{/snippet}
{#if isCommentView(item)}
{item.comment.removed
? $t('moderation.restore')
: $t('moderation.remove')}
{:else}
{item.post.removed ? $t('moderation.restore') : $t('moderation.remove')}
{/if}
{#if $profile?.user && $profile.user?.local_user_view.person.id != item.creator.id}
ban(item.creator_banned_from_community, item.creator, item.community)}
>
{#snippet prefix()}
{/snippet}
{item.creator_banned_from_community
? $t('moderation.ban.unbanFromCommunity')
: $t('moderation.ban.banFromCommunity')}
{:else if isCommentView(item)}
{
if (!$profile.jwt) return
item.comment = (
await feature(
!item.comment.distinguished,
item.comment,
$profile.jwt,
)
).comment_view.comment
}}
>
{#snippet prefix()}
{/snippet}
{item.comment.distinguished
? $t('moderation.unfeature')
: $t('moderation.feature')}
{/if}
{/if}
{#if $profile?.user && isAdmin($profile.user)}
{$t('admin.label')}
remove(item, true)}>
{#snippet prefix()}
{/snippet}
{$t('admin.purge')}
{/if}