import { Feather } from 'lucide-react'; import { EModelEndpoint, alternateName } from 'librechat-data-provider'; import { Sparkles, BedrockIcon, AnthropicIcon, AzureMinimalIcon, OpenAIMinimalIcon, GoogleMinimalIcon, CustomMinimalIcon, } from '@librechat/client'; import UnknownIcon from '~/hooks/Endpoint/UnknownIcon'; import { IconProps } from '~/common'; import { cn } from '~/utils'; const MinimalIcon: React.FC = (props) => { const { size = 30, iconURL = '', iconClassName, error } = props; let endpoint = 'default'; // Default value for endpoint if (typeof props.endpoint === 'string') { endpoint = props.endpoint; } const endpointIcons = { [EModelEndpoint.azureOpenAI]: { icon: , name: props.chatGptLabel ?? 'ChatGPT', }, [EModelEndpoint.openAI]: { icon: , name: props.chatGptLabel ?? 'ChatGPT', }, [EModelEndpoint.google]: { icon: , name: props.modelLabel ?? 'Google' }, [EModelEndpoint.anthropic]: { icon: , name: props.modelLabel ?? 'Claude', }, [EModelEndpoint.custom]: { icon: , name: 'Custom', }, [EModelEndpoint.assistants]: { icon: , name: 'Assistant' }, [EModelEndpoint.azureAssistants]: { icon: , name: 'Assistant' }, [EModelEndpoint.agents]: { icon: , name: props.modelLabel ?? alternateName[EModelEndpoint.agents], }, [EModelEndpoint.bedrock]: { icon: , name: props.modelLabel ?? alternateName[EModelEndpoint.bedrock], }, default: { icon: , name: endpoint, }, }; let { icon, name } = endpointIcons[endpoint] ?? endpointIcons.default; if (iconURL && endpointIcons[iconURL] != null) { ({ icon, name } = endpointIcons[iconURL]); } return ( ); }; export default MinimalIcon;