From ffd54fa70fbfa7ad152d32dab053009a6a52c7ab Mon Sep 17 00:00:00 2001 From: ecwu Date: Wed, 25 Dec 2024 15:24:04 +0800 Subject: [PATCH] Refactor TTSButton to use custom Button component and update icons for better UI consistency --- src/tts.tsx | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/tts.tsx b/src/tts.tsx index 6848507..903c96c 100644 --- a/src/tts.tsx +++ b/src/tts.tsx @@ -4,6 +4,8 @@ import { useMemo, useState } from "preact/hooks"; import { addTotalCost } from "@/utils/totalCost"; import { ChatStore, ChatStoreMessage } from "@/types/chatstore"; import { Message, getMessageText } from "@/chatgpt"; +import { AudioLinesIcon, LoaderCircleIcon } from "lucide-react"; +import { Button } from "./components/ui/button"; interface TTSProps { chatStore: ChatStore; @@ -25,14 +27,16 @@ export function TTSPlay(props: TTSPlayProps) { return <>; } if (props.chat.audio instanceof Blob) { - return