Collapse label appeal flow into ModerationDetailsDialog (#11091)
Co-authored-by: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Eric Bailey <git@esb.lol>
This commit is contained in:
@@ -58,6 +58,21 @@ export function labelIsHideableOffense(
|
||||
return ['!hide', '!takedown'].includes(label.val)
|
||||
}
|
||||
|
||||
/**
|
||||
* Filters out labels that are not user-facing: system labels (val prefixed
|
||||
* with `!`) and the user's own "bot" self-label.
|
||||
*/
|
||||
export function filterUserFacingLabels(
|
||||
labels: ComAtprotoLabelDefs.Label[],
|
||||
currentAccountDid: string | undefined,
|
||||
): ComAtprotoLabelDefs.Label[] {
|
||||
return labels.filter(
|
||||
label =>
|
||||
!label.val.startsWith('!') &&
|
||||
!(label.val === 'bot' && label.src === currentAccountDid),
|
||||
)
|
||||
}
|
||||
|
||||
export function getLabelingServiceTitle({
|
||||
displayName,
|
||||
handle,
|
||||
|
||||
Reference in New Issue
Block a user