diff --git a/src/frontend/src/assets/male-technologist.png b/src/frontend/src/assets/male-technologist.png new file mode 100644 index 000000000..3b5281237 Binary files /dev/null and b/src/frontend/src/assets/male-technologist.png differ diff --git a/src/frontend/src/assets/robot.png b/src/frontend/src/assets/robot.png new file mode 100644 index 000000000..81de3118d Binary files /dev/null and b/src/frontend/src/assets/robot.png differ diff --git a/src/frontend/src/components/cardComponent/index.tsx b/src/frontend/src/components/cardComponent/index.tsx index 83228d92d..276f0a7cd 100644 --- a/src/frontend/src/components/cardComponent/index.tsx +++ b/src/frontend/src/components/cardComponent/index.tsx @@ -47,30 +47,9 @@ export const CardComponent = ({ > {flow.name} {onDelete && ( - - - - - - - Are you sure absolutely sure? - - This action cannot be undone. Are you sure you want to - permanently delete this file from our servers? - - - - - - - + )} diff --git a/src/frontend/src/components/inputComponent/index.tsx b/src/frontend/src/components/inputComponent/index.tsx index d180a5fa0..b5894fe6e 100644 --- a/src/frontend/src/components/inputComponent/index.tsx +++ b/src/frontend/src/components/inputComponent/index.tsx @@ -39,7 +39,7 @@ export default function InputComponent({ if (disableCopyPaste) setDisableCopyPaste(false); }} className={classNames( - " pr-12 ", + " pr-9 ", disabled ? " input-disable " : "", password && !pwdVisible && myValue !== "" ? "password" : "", editNode ? " input-edit-node " : " input-primary ", diff --git a/src/frontend/src/constants.tsx b/src/frontend/src/constants.tsx index 601b2ba23..c823abc1d 100644 --- a/src/frontend/src/constants.tsx +++ b/src/frontend/src/constants.tsx @@ -1,8 +1,10 @@ // src/constants.tsx +import { MessageSquareDashed } from "lucide-react"; import { FlowType } from "./types/flow"; import { TabsState } from "./types/tabs"; import { buildInputs, buildTweaks } from "./utils"; +import { MessageSquare } from "lucide-react"; /** * The base text for subtitle of Export Dialog (Toolbar) @@ -57,6 +59,8 @@ export const CHAT_CANNOT_OPEN_DESCRIPTION = "This is not a chat flow."; export const FLOW_NOT_BUILT_TITLE = "Flow not built"; +export const THOUGHTS_ICON = MessageSquare; + export const FLOW_NOT_BUILT_DESCRIPTION = "Please build the flow before chatting."; diff --git a/src/frontend/src/modals/formModal/chatMessage/index.tsx b/src/frontend/src/modals/formModal/chatMessage/index.tsx index dfd04a585..19cb40d4d 100644 --- a/src/frontend/src/modals/formModal/chatMessage/index.tsx +++ b/src/frontend/src/modals/formModal/chatMessage/index.tsx @@ -3,6 +3,8 @@ import { ChatMessageType } from "../../../types/chat"; import { classNames } from "../../../utils"; import AiIcon from "../../../assets/Gooey Ring-5s-271px.svg"; import AiIconStill from "../../../assets/froze-flow.png"; +import Robot from "../../../assets/robot.png"; +import MaleTechnology from "../../../assets/male-technologist.png"; import FileCard from "../fileComponent"; import ReactMarkdown from "react-markdown"; import rehypeMathjax from "rehype-mathjax"; @@ -10,7 +12,13 @@ import remarkGfm from "remark-gfm"; import remarkMath from "remark-math"; import { CodeBlock } from "./codeBlock"; import Convert from "ansi-to-html"; -import { User2, MessageSquare, ChevronDown } from "lucide-react"; +import { + User2, + MessageSquare, + ChevronDown, + MessageCircle, + MessageSquareDashed, +} from "lucide-react"; import { Accordion, AccordionContent, @@ -18,6 +26,7 @@ import { AccordionTrigger, } from "../../../components/ui/accordion"; import { Badge } from "../../../components/ui/badge"; +import { THOUGHTS_ICON } from "../../../constants"; export default function ChatMessage({ chat, @@ -39,32 +48,30 @@ export default function ChatMessage({ chat.isSend ? "" : " " )} > -
+
{!chat.isSend ? (
-
- 🤖 +
+
- Chatbot
) : (
-
- 👨‍💻 +
+
- User
)}
{!chat.isSend ? ( -
+
- {hidden && ( + {hidden && chat.thought && chat.thought !== "" && (
setHidden((prev) => !prev)} - className="absolute -left-8 -top-5 cursor-pointer" + className="absolute -left-8 -top-3 cursor-pointer" > - +
)} {chat.thought && chat.thought !== "" && !hidden && ( @@ -145,7 +152,7 @@ export default function ChatMessage({ ) : (