import Button from "@moduletrace/twui/layout/Button"; import Row from "@moduletrace/twui/layout/Row"; import Stack from "@moduletrace/twui/layout/Stack"; import Span from "@moduletrace/twui/layout/Span"; import { Reply, X } from "lucide-react"; import type { BotMessageWithAttachments } from "@/src/types"; import messagePreview from "@/src/utils/message-preview"; type Props = { message: BotMessageWithAttachments; bot_name: string; onCancel: () => void; }; /** * The message the next one will quote, above the composer, until it is * sent or dropped. */ export default function ComposerReplyPreview({ message, bot_name, onCancel }: Props) { const preview = messagePreview({ text: message.text || "" }) || "A file"; return ( Replying to {message.author == "user" ? "yourself" : bot_name} {preview} ); }