SmythOS Studio: Open-Source Visual AI Agent Builder and deployable runtime stack from SmythOS. Start with an intuitive drag-and-drop workspace, extend with custom code, and deploy your agents anywhere — local, cloud, or edge — with full governance and control.
JavaScript a2aagentic-aiai-agentsdevtoolsmcp-clientn8n-alternativeno-codeopen-sourceorchestrationsmythosvisual-builder
Remove deprecated AI chat components to streamline codebase
Salman-Ahamed70705353404a
diff --git a/packages/app/src/react/features/ai-chat/components/chat.tsx b/packages/app/src/react/features/ai-chat/components/chat/chat.tsxsimilarity index 91%rename from packages/app/src/react/features/ai-chat/components/chat.tsxrename to packages/app/src/react/features/ai-chat/components/chat/chat.tsxindex ce2ba5d0..0690c0f9 100644--- a/packages/app/src/react/features/ai-chat/components/chat.tsx+++ b/packages/app/src/react/features/ai-chat/components/chat/chat.tsx@@ -8,9 +8,9 @@ import {UserMessage,} from '@react/features/ai-chat/components';-import { MESSAGE_TYPES } from '../constants';-import '../styles/index.css';-import { IMessage } from '../types/chat';+import { MESSAGE_TYPES } from '../../constants';+import '../../styles/index.css';+import { IMessage } from '../../types/chat';interface IChatProps extends IMessage {avatar: string;diff --git a/packages/app/src/react/features/ai-chat/components/chats-with-group.tsx b/packages/app/src/react/features/ai-chat/components/chat/chats-with-group.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/chats-with-group.tsxrename to packages/app/src/react/features/ai-chat/components/chat/chats-with-group.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/chats.tsx b/packages/app/src/react/features/ai-chat/components/chat/chats.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/chats.tsxrename to packages/app/src/react/features/ai-chat/components/chat/chats.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/code-block.tsx b/packages/app/src/react/features/ai-chat/components/chat/code-block.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/code-block.tsxrename to packages/app/src/react/features/ai-chat/components/chat/code-block.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/error-message.tsx b/packages/app/src/react/features/ai-chat/components/chat/error-message.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/error-message.tsxrename to packages/app/src/react/features/ai-chat/components/chat/error-message.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/chat/index.ts b/packages/app/src/react/features/ai-chat/components/chat/index.tsnew file mode 100644index 00000000..d7344179--- /dev/null+++ b/packages/app/src/react/features/ai-chat/components/chat/index.ts@@ -0,0 +1,11 @@+export * from './chat';+export * from './chats';+export * from './chats-with-group';+export * from './code-block';+export * from './error-message';+export * from './markdown-renderer';+export * from './reply-loader';+export * from './system-message';+export * from './thinking-message';+export * from './typewriter';+export * from './user-message';diff --git a/packages/app/src/react/features/ai-chat/components/markdown-renderer.tsx b/packages/app/src/react/features/ai-chat/components/chat/markdown-renderer.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/markdown-renderer.tsxrename to packages/app/src/react/features/ai-chat/components/chat/markdown-renderer.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/reply-loader.tsx b/packages/app/src/react/features/ai-chat/components/chat/reply-loader.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/reply-loader.tsxrename to packages/app/src/react/features/ai-chat/components/chat/reply-loader.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/system-message.tsx b/packages/app/src/react/features/ai-chat/components/chat/system-message.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/system-message.tsxrename to packages/app/src/react/features/ai-chat/components/chat/system-message.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/thinking-message.tsx b/packages/app/src/react/features/ai-chat/components/chat/thinking-message.tsxsimilarity index 98%rename from packages/app/src/react/features/ai-chat/components/thinking-message.tsxrename to packages/app/src/react/features/ai-chat/components/chat/thinking-message.tsxindex 2ded7ec1..86439391 100644--- a/packages/app/src/react/features/ai-chat/components/thinking-message.tsx+++ b/packages/app/src/react/features/ai-chat/components/chat/thinking-message.tsx@@ -3,7 +3,7 @@ import {formatStatusMessage,} from '@react/features/ai-chat/utils/stream.utils';import { FC, useEffect, useRef, useState } from 'react';-import { IMetaMessages } from '../types/chat';+import { IMetaMessages } from '../../types/chat';interface IProps {data: {diff --git a/packages/app/src/react/features/ai-chat/components/typewriter.tsx b/packages/app/src/react/features/ai-chat/components/chat/typewriter.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/typewriter.tsxrename to packages/app/src/react/features/ai-chat/components/chat/typewriter.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/user-message.tsx b/packages/app/src/react/features/ai-chat/components/chat/user-message.tsxsimilarity index 91%rename from packages/app/src/react/features/ai-chat/components/user-message.tsxrename to packages/app/src/react/features/ai-chat/components/chat/user-message.tsxindex a2b77432..c30b40ef 100644--- a/packages/app/src/react/features/ai-chat/components/user-message.tsx+++ b/packages/app/src/react/features/ai-chat/components/chat/user-message.tsx@@ -1,6 +1,6 @@import { FC } from 'react';-import { IAttachment } from '../types/chat';-import { FileItemPreview } from './FileItemPreview';+import { IAttachment } from '../../types/chat';+import { FileItemPreview } from '../common/FileItemPreview';/*** User Message Component Propertiesdiff --git a/packages/app/src/react/features/ai-chat/components/FileItemPreview.tsx b/packages/app/src/react/features/ai-chat/components/common/FileItemPreview.tsxsimilarity index 99%rename from packages/app/src/react/features/ai-chat/components/FileItemPreview.tsxrename to packages/app/src/react/features/ai-chat/components/common/FileItemPreview.tsxindex d305d3c4..4215c2c2 100644--- a/packages/app/src/react/features/ai-chat/components/FileItemPreview.tsx+++ b/packages/app/src/react/features/ai-chat/components/common/FileItemPreview.tsx@@ -9,7 +9,7 @@ import {FaRegFileWord,FaXmark,} from 'react-icons/fa6';-import type { IAttachment } from '../types/chat';+import type { IAttachment } from '../../types/chat';/** Map of file extensions to their corresponding icons */const FILE_ICONS: Record<string, ReactElement> = {diff --git a/packages/app/src/react/features/ai-chat/components/file-item-preview.tsx b/packages/app/src/react/features/ai-chat/components/common/file-item-preview.tsxsimilarity index 96%rename from packages/app/src/react/features/ai-chat/components/file-item-preview.tsxrename to packages/app/src/react/features/ai-chat/components/common/file-item-preview.tsxindex 509daec0..f6352478 100644--- a/packages/app/src/react/features/ai-chat/components/file-item-preview.tsx+++ b/packages/app/src/react/features/ai-chat/components/common/file-item-preview.tsx@@ -1,5 +1,5 @@-import { CloseIcon } from '@react/features/ai-chat/components/icons';import { IMessageFile } from '@react/features/ai-chat/types/chat.types';+import { CloseIcon } from '@src/react/features/ai-chat/components/common/icons';import classNames from 'classnames';import { FC, useEffect, useMemo, useState } from 'react';import {@@ -53,7 +53,7 @@ const RemoveButton: FC<{ onRemove: () => void }> = ({ onRemove }) => (</button>);-export const FileItemPreview: FC<FileItemPreviewProps> = ({+export const FileItemPreviews: FC<FileItemPreviewProps> = ({file,onRemove,isUploading,diff --git a/packages/app/src/react/features/ai-chat/components/icons.tsx b/packages/app/src/react/features/ai-chat/components/common/icons.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/icons.tsxrename to packages/app/src/react/features/ai-chat/components/common/icons.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/common/index.ts b/packages/app/src/react/features/ai-chat/components/common/index.tsnew file mode 100644index 00000000..598aaf83--- /dev/null+++ b/packages/app/src/react/features/ai-chat/components/common/index.ts@@ -0,0 +1,3 @@+export * from './file-item-preview';+export * from './FileItemPreview';+export * from './icons';diff --git a/packages/app/src/react/features/ai-chat/components/attachment-button.tsx b/packages/app/src/react/features/ai-chat/components/footer/attachment-button.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/attachment-button.tsxrename to packages/app/src/react/features/ai-chat/components/footer/attachment-button.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/error-toast.tsx b/packages/app/src/react/features/ai-chat/components/footer/error-toast.tsxsimilarity index 94%rename from packages/app/src/react/features/ai-chat/components/error-toast.tsxrename to packages/app/src/react/features/ai-chat/components/footer/error-toast.tsxindex 1997f209..0cd7b161 100644--- a/packages/app/src/react/features/ai-chat/components/error-toast.tsx+++ b/packages/app/src/react/features/ai-chat/components/footer/error-toast.tsx@@ -1,6 +1,6 @@import { FC } from 'react';import { FaCircleExclamation } from 'react-icons/fa6';-import { CloseIcon } from './icons';+import { CloseIcon } from '../common/icons';interface ErrorToastProps {message: string;diff --git a/packages/app/src/react/features/ai-chat/components/footer.tsx b/packages/app/src/react/features/ai-chat/components/footer/footer.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/footer.tsxrename to packages/app/src/react/features/ai-chat/components/footer/footer.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/footer/index.ts b/packages/app/src/react/features/ai-chat/components/footer/index.tsnew file mode 100644index 00000000..cb620187--- /dev/null+++ b/packages/app/src/react/features/ai-chat/components/footer/index.ts@@ -0,0 +1,6 @@+export * from './attachment-button';+export * from './error-toast';+export * from './footer';+export * from './input';+export * from './scroll-to-bottom-button';+export * from './send-button';diff --git a/packages/app/src/react/features/ai-chat/components/input.tsx b/packages/app/src/react/features/ai-chat/components/footer/input.tsxsimilarity index 98%rename from packages/app/src/react/features/ai-chat/components/input.tsxrename to packages/app/src/react/features/ai-chat/components/footer/input.tsxindex df97d60d..7aa83f1d 100644--- a/packages/app/src/react/features/ai-chat/components/input.tsx+++ b/packages/app/src/react/features/ai-chat/components/footer/input.tsx@@ -7,10 +7,9 @@ import {useRef,useState,} from 'react';-import '../styles/index.css';+import '../../styles/index.css';import { AttachmentButton, SendButton } from '@react/features/ai-chat/components';-import { FileItemPreview } from '@react/features/ai-chat/components/FileItemPreview';import { CHAT_ACCEPTED_FILE_TYPES } from '@react/features/ai-chat/constants';import { useChatStores, useClipboardPaste } from '@react/features/ai-chat/hooks';import { createFileFromText } from '@react/features/ai-chat/utils';@@ -20,6 +19,7 @@ import {} from '@react/features/ai-chat/utils/scroll-utils';import { MAX_CHAT_MESSAGE_LENGTH } from '@react/shared/constants';import { cn } from '@react/shared/utils/general';+import { FileItemPreview } from '@src/react/features/ai-chat/components/common/FileItemPreview';const TEXTAREA_MAX_HEIGHT = 160;const LARGE_TEXT_THRESHOLD = 4000;diff --git a/packages/app/src/react/features/ai-chat/components/scroll-to-bottom-button.tsx b/packages/app/src/react/features/ai-chat/components/footer/scroll-to-bottom-button.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/scroll-to-bottom-button.tsxrename to packages/app/src/react/features/ai-chat/components/footer/scroll-to-bottom-button.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/send-button.tsx b/packages/app/src/react/features/ai-chat/components/footer/send-button.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/send-button.tsxrename to packages/app/src/react/features/ai-chat/components/footer/send-button.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/header.tsx b/packages/app/src/react/features/ai-chat/components/header/header.tsxsimilarity index 99%rename from packages/app/src/react/features/ai-chat/components/header.tsxrename to packages/app/src/react/features/ai-chat/components/header/header.tsxindex afa4ba37..1a5a5ae6 100644--- a/packages/app/src/react/features/ai-chat/components/header.tsx+++ b/packages/app/src/react/features/ai-chat/components/header/header.tsx@@ -6,9 +6,9 @@ import { IoChevronDown } from 'react-icons/io5';import { Link } from 'react-router-dom';import { Skeleton } from '@react/features/ai-chat/components';-import { CloseIcon } from '@react/features/ai-chat/components/icons';import { DEFAULT_AVATAR_URL } from '@react/features/ai-chat/constants';import { useChatStores } from '@react/features/ai-chat/hooks';+import { CloseIcon } from '@src/react/features/ai-chat/components/common/icons';import { cn } from '@src/react/shared/utils/general';import { Observability } from '@src/shared/observability';import { EVENTS } from '@src/shared/posthog/constants/events';diff --git a/packages/app/src/react/features/ai-chat/components/header/index.ts b/packages/app/src/react/features/ai-chat/components/header/index.tsnew file mode 100644index 00000000..1b8e01c4--- /dev/null+++ b/packages/app/src/react/features/ai-chat/components/header/index.ts@@ -0,0 +1,2 @@+export * from './header';+export * from './skeleton';diff --git a/packages/app/src/react/features/ai-chat/components/skeleton.tsx b/packages/app/src/react/features/ai-chat/components/header/skeleton.tsxsimilarity index 100%rename from packages/app/src/react/features/ai-chat/components/skeleton.tsxrename to packages/app/src/react/features/ai-chat/components/header/skeleton.tsxdiff --git a/packages/app/src/react/features/ai-chat/components/index.ts b/packages/app/src/react/features/ai-chat/components/index.tsindex c15f435e..bbddda1f 100644--- a/packages/app/src/react/features/ai-chat/components/index.ts+++ b/packages/app/src/react/features/ai-chat/components/index.ts@@ -1,21 +1,5 @@-export * from './attachment-button';export * from './chat';-export * from './chats';-export * from './code-block';+export * from './common';export * from './container';-export * from './error-message';-export * from './error-toast';-export * from './file-item-preview';export * from './footer';export * from './header';-export * from './input';-export * from './markdown-renderer';-export * from './chats-with-group';-export * from './reply-loader';-export * from './scroll-to-bottom-button';-export * from './send-button';-export * from './skeleton';-export * from './system-message';-export * from './thinking-message';-export * from './typewriter';-export * from './user-message';