Updated the Speaking Generation to save the topic as well

This commit is contained in:
Tiago Ribeiro
2024-02-13 16:26:56 +00:00
parent b7cd1fb141
commit 64b1d9266e

View File

@@ -70,7 +70,7 @@ const PartTab = ({
playSound(isError ? "error" : "check");
if (isError) return toast.error("Something went wrong, please try to generate the video again.");
setPart({...part, result: result.data, gender, avatar});
setPart({...part, result: {...result.data, topic: part?.topic}, gender, avatar});
})
.catch((e) => {
toast.error("Something went wrong!");
@@ -79,6 +79,8 @@ const PartTab = ({
.finally(() => setIsLoading(false));
};
useEffect(() => console.log(part), [part]);
return (
<Tab.Panel className="w-full bg-ielts-speaking/20 min-h-[600px] h-full rounded-xl p-6 flex flex-col gap-4">
<div className="flex flex-col gap-3 w-full">