UNPKG

@veracity/vui

Version:

Veracity UI is a React component library crafted for use within Veracity applications and pages. Based on Styled Components and @xstyled.

29 lines (27 loc) 950 B
import { useStyleConfig } from "../core/theme.js"; import vui from "../core/vui.js"; import { Button } from "../button/button.js"; import { jsx } from "react/jsx-runtime"; //#region src/chat/chatInputButton.tsx /** * Displays a chat input button. */ const ChatInputButton = vui((props, ref) => { const styles = useStyleConfig("Chat", props); const { status = "default", onSend, onStop } = props; return /* @__PURE__ */ jsx(Button, { disabled: status === "disabled" || status === "processing" && !onStop, h: "100%", icon: status === "processing" && onStop ? "falStopCircle" : "falChevronCircleRight", ml: 1, onClick: () => status === "processing" ? onStop?.() : onSend?.(), ref, variant: "tertiary", ...styles?.inputButton }); }); ChatInputButton.displayName = "ChatInputButton"; //#endregion export { ChatInputButton, ChatInputButton as default }; globalThis.__vuiVersion__ = "5.3.1" //# sourceMappingURL=chatInputButton.js.map