From 75cd1411388db8ed69f8de3e996d8b3c1febd99a Mon Sep 17 00:00:00 2001 From: Baptiste Arnaud Date: Mon, 15 Apr 2024 08:32:25 +0200 Subject: [PATCH] :children_crossing: Improve zapier, make.com block content feedback --- .../integrations/makeCom/components/MakeComContent.tsx | 7 ++----- .../pabbly/components/PabblyConnectContent.tsx | 7 ++----- .../integrations/zapier/components/ZapierContent.tsx | 7 ++----- 3 files changed, 6 insertions(+), 15 deletions(-) diff --git a/apps/builder/src/features/blocks/integrations/makeCom/components/MakeComContent.tsx b/apps/builder/src/features/blocks/integrations/makeCom/components/MakeComContent.tsx index f6f9289f627..b8b5ad87579 100644 --- a/apps/builder/src/features/blocks/integrations/makeCom/components/MakeComContent.tsx +++ b/apps/builder/src/features/blocks/integrations/makeCom/components/MakeComContent.tsx @@ -1,19 +1,16 @@ import { Text } from '@chakra-ui/react' import { MakeComBlock } from '@typebot.io/schemas' -import { isNotDefined } from '@typebot.io/lib' type Props = { block: MakeComBlock } export const MakeComContent = ({ block }: Props) => { - const webhook = block.options?.webhook - - if (isNotDefined(webhook?.body)) + if (!block.options?.webhook?.url) return Configure... return ( - {webhook?.url ? 'Trigger scenario' : 'Disabled'} + Trigger scenario ) } diff --git a/apps/builder/src/features/blocks/integrations/pabbly/components/PabblyConnectContent.tsx b/apps/builder/src/features/blocks/integrations/pabbly/components/PabblyConnectContent.tsx index fa68f17c76f..279905f556d 100644 --- a/apps/builder/src/features/blocks/integrations/pabbly/components/PabblyConnectContent.tsx +++ b/apps/builder/src/features/blocks/integrations/pabbly/components/PabblyConnectContent.tsx @@ -1,19 +1,16 @@ import { Text } from '@chakra-ui/react' import { PabblyConnectBlock } from '@typebot.io/schemas' -import { isNotDefined } from '@typebot.io/lib' type Props = { block: PabblyConnectBlock } export const PabblyConnectContent = ({ block }: Props) => { - const webhook = block.options?.webhook - - if (isNotDefined(webhook?.body)) + if (!block.options?.webhook?.url) return Configure... return ( - {webhook?.url ? 'Trigger scenario' : 'Disabled'} + Trigger scenario ) } diff --git a/apps/builder/src/features/blocks/integrations/zapier/components/ZapierContent.tsx b/apps/builder/src/features/blocks/integrations/zapier/components/ZapierContent.tsx index 40d890df976..bc6dc821ee0 100644 --- a/apps/builder/src/features/blocks/integrations/zapier/components/ZapierContent.tsx +++ b/apps/builder/src/features/blocks/integrations/zapier/components/ZapierContent.tsx @@ -1,19 +1,16 @@ import { Text } from '@chakra-ui/react' import { ZapierBlock } from '@typebot.io/schemas' -import { isNotDefined } from '@typebot.io/lib' type Props = { block: ZapierBlock } export const ZapierContent = ({ block }: Props) => { - const webhook = block.options?.webhook - - if (isNotDefined(webhook?.body)) + if (!block.options?.webhook?.url) return Configure... return ( - {webhook?.url ? 'Trigger zap' : 'Disabled'} + Trigger zap ) }