Skip to content

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.

Update FileItemPreview component styles and structure for improved UI consistency

Salman-Ahamede5876793d910
diff --git a/packages/app/src/react/features/ai-chat/components/FileItemPreview.tsx b/packages/app/src/react/features/ai-chat/components/FileItemPreview.tsx
index 4fb06db9..d305d3c4 100644
--- a/packages/app/src/react/features/ai-chat/components/FileItemPreview.tsx
+++ b/packages/app/src/react/features/ai-chat/components/FileItemPreview.tsx
@@ -226,17 +226,18 @@ export const FileItemPreview: FC<IFileItemPreviewProps> = memo(
}
// Render file icon preview for non-image files
+
return (
<div className="relative inline-block group mt-4">
{onRemove && (
- <div className="absolute -top-2 -right-2 group-hover:[&>button]:opacity-100">
+ <div className="absolute -top-2 -right-2 z-10 group-hover:[&>button]:opacity-100">
<RemoveButton onRemove={onRemove} />
</div>
)}
<div className="flex items-center gap-4 text-sm bg-white rounded-lg border border-[#E5E7EB] px-2 py-1 overflow-hidden w-40 min-w-32 max-h-[52px]">
- <div className="flex items-center justify-center bg-[#45C9A9] rounded-lg p-2 shrink-0">
+ <div className="flex items-center justify-center bg-primary-100 rounded-lg p-2 flex-shrink-0">
{isUploading ? (
- <div className="animate-spin rounded-full border-2 border-white border-t-transparent" />
+ <div className="animate-spin rounded-full h-6 w-6 border-solid border-2 border-white border-t-transparent" />
) : (
fileIcon
)}