Add (WIP) debug mod page

This commit is contained in:
Paul Frazee
2024-02-07 21:26:28 -08:00
parent 270476a126
commit 15d0f2e90b
14 changed files with 523 additions and 17 deletions
+1 -2
View File
@@ -1,5 +1,4 @@
import {ModerationUI} from '@atproto/api'
import {describeModerationCause} from '../moderation'
// \u2705 = ✅
// \u2713 = ✓
@@ -14,7 +13,7 @@ export function sanitizeDisplayName(
moderation?: ModerationUI,
): string {
if (moderation?.blur) {
return `${describeModerationCause(moderation.cause, 'account').name}`
return ` Display name hidden`
}
if (typeof str === 'string') {
return str.replace(CHECK_MARKS_RE, '').replace(CONTROL_CHARS_RE, '').trim()