diff --git a/web/src/app/chat/components/message-list-view.tsx b/web/src/app/chat/components/message-list-view.tsx index c4f2bf8..8d8c279 100644 --- a/web/src/app/chat/components/message-list-view.tsx +++ b/web/src/app/chat/components/message-list-view.tsx @@ -328,7 +328,7 @@ function PlanCard({ - + {`### ${ plan.title !== undefined && plan.title !== "" ? plan.title @@ -404,6 +404,9 @@ function PodcastCard({ const isGenerating = useMemo(() => { return message.isStreaming; }, [message.isStreaming]); + const hasError = useMemo(() => { + return data?.error !== undefined; + }, [data]); const [isPlaying, setIsPlaying] = useState(false); return ( @@ -411,15 +414,21 @@ function PodcastCard({
{isGenerating ? : } - - {isGenerating - ? "Generating podcast..." - : isPlaying - ? "Now playing podcast..." - : "Podcast"} - + {!hasError ? ( + + {isGenerating + ? "Generating podcast..." + : isPlaying + ? "Now playing podcast..." + : "Podcast"} + + ) : ( +
+ Error when generating podcast. Please try again. +
+ )}
- {!isGenerating && ( + {!hasError && !isGenerating && (