import React, { useState } from 'react'; import { TFile } from 'librechat-data-provider/dist/types'; import { CheckMark, TrashIcon, Button } from '@librechat/client'; import VectorStoreButton from '../VectorStore/VectorStoreButton'; import { CircleIcon, Clock3Icon, InfoIcon } from 'lucide-react'; import DeleteIconButton from '../DeleteIconButton'; import { TThread, TVectorStore } from '~/common'; import { useParams } from 'react-router-dom'; const tempFile: TFile = { filename: 'File1.jpg', object: 'file', bytes: 10000, createdAt: '2022-01-01T10:00:00', _id: '1', type: 'image', usage: 12, user: 'abc', file_id: 'file_id', embedded: true, filepath: 'filepath', }; const tempThreads: TThread[] = [ { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, { id: 'thead_id', createdAt: '2022-01-01T10:00:00' }, ]; const tempVectorStoresAttached: TVectorStore[] = [ { name: 'vector 1', created_at: '2022-01-01T10:00:00', _id: 'id', object: 'vector_store' }, { name: 'vector 1', created_at: '2022-01-01T10:00:00', _id: 'id', object: 'vector_store' }, { name: 'vector 1', created_at: '2022-01-01T10:00:00', _id: 'id', object: 'vector_store' }, ]; export default function FilePreview() { const [file, setFile] = useState(tempFile); const [threads, setThreads] = useState(tempThreads); const [vectorStoresAttached, setVectorStoresAttached] = useState(tempVectorStoresAttached); const params = useParams(); return (