diff --git a/src/components/ui/chat/chat-bubble.tsx b/src/components/ui/chat/chat-bubble.tsx index e22a1e2..9a70e58 100644 --- a/src/components/ui/chat/chat-bubble.tsx +++ b/src/components/ui/chat/chat-bubble.tsx @@ -23,7 +23,7 @@ const chatBubbleVariant = cva( variant: "received", layout: "default", }, - }, + } ); interface ChatBubbleProps @@ -35,7 +35,7 @@ const ChatBubble = React.forwardRef(
( variant, layout, } as React.ComponentProps) - : child, + : child )}
- ), + ) ); ChatBubble.displayName = "ChatBubble"; @@ -102,25 +102,28 @@ const ChatBubbleMessage = React.forwardRef< >( ( { className, variant, layout, isLoading = false, children, ...props }, - ref, + ref ) => (
{isLoading ? ( -
- -
+ <> + {children} +
+ +
+ ) : ( children )}
- ), + ) ); ChatBubbleMessage.displayName = "ChatBubbleMessage"; @@ -181,7 +184,7 @@ const ChatBubbleActionWrapper = React.forwardRef< variant === "sent" ? "-left-1 -translate-x-full flex-row-reverse" : "-right-1 translate-x-full", - className, + className )} {...props} > diff --git a/src/pages/Chatbox.tsx b/src/pages/Chatbox.tsx index 8ae90d9..1cd9148 100644 --- a/src/pages/Chatbox.tsx +++ b/src/pages/Chatbox.tsx @@ -680,7 +680,9 @@ export default function ChatBOX(props: { ))} {showGenerating && ( - + + {generatingMessage} + )}