Remove extra file
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
import {View} from 'react-native'
|
import {View} from 'react-native'
|
||||||
|
import {type ComAtprotoLabelDefs} from '@atproto/api'
|
||||||
import {msg} from '@lingui/core/macro'
|
import {msg} from '@lingui/core/macro'
|
||||||
import {useLingui} from '@lingui/react'
|
import {useLingui} from '@lingui/react'
|
||||||
|
|
||||||
import {isBotAccount} from '#/lib/bots'
|
|
||||||
import {atoms as a, useTheme} from '#/alf'
|
import {atoms as a, useTheme} from '#/alf'
|
||||||
import {BotAccountAlert} from '#/components/BotAccountAlert'
|
import {BotAccountAlert} from '#/components/BotAccountAlert'
|
||||||
import {Button} from '#/components/Button'
|
import {Button} from '#/components/Button'
|
||||||
@@ -11,6 +11,15 @@ import {Bot_Filled as RobotIcon} from '#/components/icons/Bot'
|
|||||||
import {useAnalytics} from '#/analytics'
|
import {useAnalytics} from '#/analytics'
|
||||||
import type * as bsky from '#/types/bsky'
|
import type * as bsky from '#/types/bsky'
|
||||||
|
|
||||||
|
export function isBotAccount(profile: {
|
||||||
|
did: string
|
||||||
|
labels?: ComAtprotoLabelDefs.Label[]
|
||||||
|
}): boolean {
|
||||||
|
return (
|
||||||
|
profile.labels?.some(l => l.val === 'bot' && l.src === profile.did) ?? false
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
export function BotBadge({
|
export function BotBadge({
|
||||||
profile,
|
profile,
|
||||||
alwaysShow = false,
|
alwaysShow = false,
|
||||||
|
|||||||
@@ -1,9 +1,8 @@
|
|||||||
import {View} from 'react-native'
|
import {View} from 'react-native'
|
||||||
|
|
||||||
import {isBotAccount} from '#/lib/bots'
|
|
||||||
import {useProfileShadow} from '#/state/cache/profile-shadow'
|
import {useProfileShadow} from '#/state/cache/profile-shadow'
|
||||||
import {atoms as a, type ViewStyleProp} from '#/alf'
|
import {atoms as a, type ViewStyleProp} from '#/alf'
|
||||||
import {BotBadge, BotBadgeButton} from '#/components/BotBadge'
|
import {BotBadge, BotBadgeButton, isBotAccount} from '#/components/BotBadge'
|
||||||
import {useSimpleVerificationState} from '#/components/verification'
|
import {useSimpleVerificationState} from '#/components/verification'
|
||||||
import {VerificationCheck} from '#/components/verification/VerificationCheck'
|
import {VerificationCheck} from '#/components/verification/VerificationCheck'
|
||||||
import {VerificationCheckButton} from '#/components/verification/VerificationCheckButton'
|
import {VerificationCheckButton} from '#/components/verification/VerificationCheckButton'
|
||||||
|
|||||||
@@ -1,10 +0,0 @@
|
|||||||
import {type ComAtprotoLabelDefs} from '@atproto/api'
|
|
||||||
|
|
||||||
export function isBotAccount(profile: {
|
|
||||||
did: string
|
|
||||||
labels?: ComAtprotoLabelDefs.Label[]
|
|
||||||
}): boolean {
|
|
||||||
return (
|
|
||||||
profile.labels?.some(l => l.val === 'bot' && l.src === profile.did) ?? false
|
|
||||||
)
|
|
||||||
}
|
|
||||||
@@ -3,13 +3,13 @@ import {useLingui} from '@lingui/react'
|
|||||||
import {Trans} from '@lingui/react/macro'
|
import {Trans} from '@lingui/react/macro'
|
||||||
import {type NativeStackScreenProps} from '@react-navigation/native-stack'
|
import {type NativeStackScreenProps} from '@react-navigation/native-stack'
|
||||||
|
|
||||||
import {isBotAccount} from '#/lib/bots'
|
|
||||||
import {type CommonNavigatorParams} from '#/lib/routes/types'
|
import {type CommonNavigatorParams} from '#/lib/routes/types'
|
||||||
import {useProfileQuery} from '#/state/queries/profile'
|
import {useProfileQuery} from '#/state/queries/profile'
|
||||||
import {useSession} from '#/state/session'
|
import {useSession} from '#/state/session'
|
||||||
import * as SettingsList from '#/screens/Settings/components/SettingsList'
|
import * as SettingsList from '#/screens/Settings/components/SettingsList'
|
||||||
import {atoms as a, useTheme} from '#/alf'
|
import {atoms as a, useTheme} from '#/alf'
|
||||||
import {AgeAssuranceAccountCard} from '#/components/ageAssurance/AgeAssuranceAccountCard'
|
import {AgeAssuranceAccountCard} from '#/components/ageAssurance/AgeAssuranceAccountCard'
|
||||||
|
import {isBotAccount} from '#/components/BotBadge'
|
||||||
import {useDialogControl} from '#/components/Dialog'
|
import {useDialogControl} from '#/components/Dialog'
|
||||||
import {BirthDateSettingsDialog} from '#/components/dialogs/BirthDateSettings'
|
import {BirthDateSettingsDialog} from '#/components/dialogs/BirthDateSettings'
|
||||||
import {
|
import {
|
||||||
|
|||||||
Reference in New Issue
Block a user