2
0

feat(editor): Custom icon on typebot

This commit is contained in:
Baptiste Arnaud
2022-04-01 16:28:09 +02:00
parent 3585e63c48
commit 525887a32c
22 changed files with 2113 additions and 56 deletions

View File

@ -30,7 +30,12 @@ export const useSharedTypebots = ({
onError: (error: Error) => void
}) => {
const { data, error, mutate } = useSWR<
{ sharedTypebots: Pick<Typebot, 'name' | 'id' | 'publishedTypebotId'>[] },
{
sharedTypebots: Pick<
Typebot,
'name' | 'id' | 'publishedTypebotId' | 'icon'
>[]
},
Error
>(userId ? `/api/users/${userId}/sharedTypebots` : null, fetcher)
if (error) onError(error)