Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active
TypeScript aianthropicartifactsawsazurechatgptchatgpt-cloneclaudeclonedeepseekgeminigooglegpt-5librechatmcpo1openairesponses-apivisionwebui
import { FileSources } from 'librechat-data-provider';
import ImagePreview from './ImagePreview';
import RemoveFile from './RemoveFile';
const Image = ({
imageBase64,
url,
onDelete,
progress = 1,
source = FileSources.local,
removeLabel,
removeDisabled,
}: {
imageBase64?: string;
url?: string;
onDelete: () => void;
progress: number; // between 0 and 1
source?: FileSources;
removeLabel?: string;
removeDisabled?: boolean;
}): React.JSX.Element => {
return (
<div className="group text-text-secondary relative inline-block text-sm">
{/* `flex`, so the button inside is not laid out on a text baseline: the
descender space added ~5px under every thumbnail, which is what left
them sitting higher than the file cards beside them. */}
<div className="border-border-medium relative flex overflow-hidden rounded-2xl border">
<ImagePreview source={source} imageBase64={imageBase64} url={url} progress={progress} />
</div>
<RemoveFile onRemove={onDelete} label={removeLabel} disabled={removeDisabled} />
</div>
);
};
export default Image;