2
0

🛂 Only show suspicious bot claim for no…

This commit is contained in:
Baptiste Arnaud
2024-03-15 09:28:51 +01:00
parent f6a419c119
commit 001e696bf6

View File

@ -1,12 +1,15 @@
import { TextLink } from '@/components/TextLink'
import { useUser } from '@/features/account/hooks/useUser'
import { useWorkspace } from '@/features/workspace/WorkspaceProvider'
import { HStack, Text } from '@chakra-ui/react'
import { Plan } from '@typebot.io/prisma'
type Props = {
typebotId: string
}
export const SuspectedTypebotBanner = ({ typebotId }: Props) => {
const { user } = useUser()
const { workspace } = useWorkspace()
if (!user?.email) return null
@ -24,16 +27,20 @@ export const SuspectedTypebotBanner = ({ typebotId }: Props) => {
<Text fontWeight="bold">
Our anti-scam system flagged your typebot. It is currently being
reviewed manually.
<br />
If you think that&apos;s a mistake,{' '}
<TextLink
href={`https://typebot.co/claim-non-scam?Email=${encodeURIComponent(
user.email
)}&typebotId=${typebotId}`}
>
contact us
</TextLink>
.
{workspace?.plan !== Plan.FREE ? (
<>
<br />
If you think that&apos;s a mistake,{' '}
<TextLink
href={`https://typebot.co/claim-non-scam?Email=${encodeURIComponent(
user.email
)}&typebotId=${typebotId}`}
>
contact us
</TextLink>
.
</>
) : null}
</Text>
</HStack>
)