Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 49 additions & 1 deletion src/App.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -340,6 +340,23 @@ We also need to update [${RESOURCE_BACKUP_NAME}](https://github.com/${REPO_FULL_
<img class="trust-logo-img" src="https://github.com/user-attachments/assets/a6150c4c-149e-4cae-888b-8b92be6e003f" alt="OpenHands" height="28" />
<span class="trust-logo-text">Netflix</span>
<img class="trust-logo-img" src="https://github.com/user-attachments/assets/c02f7be0-8c2e-4d27-aea7-7c024bfaebc0" alt="OpenAI Agents SDK" height="28" />
<img class="trust-logo-img trust-logo-svg" src="https://cdn.jsdelivr.net/npm/@lobehub/icons-static-svg@latest/icons/adobe-text.svg" alt="Adobe" height="28" />
<span class="trust-logo-text trust-logo-icon">
<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 0C5.381-.008.008 5.352 0 11.971V12c0 6.64 5.359 12 12 12 6.64 0 12-5.36 12-12 0-6.641-5.36-12-12-12zm0 20.801c-4.846.015-8.786-3.904-8.801-8.75V12c-.014-4.846 3.904-8.786 8.75-8.801H12c4.847-.014 8.786 3.904 8.801 8.75V12c.015 4.847-3.904 8.786-8.75 8.801H12zm5.44-11.76c0 1.359-1.12 2.479-2.481 2.479-1.366-.007-2.472-1.113-2.479-2.479 0-1.361 1.12-2.481 2.479-2.481 1.361 0 2.481 1.12 2.481 2.481zm0 5.919c0 1.36-1.12 2.48-2.481 2.48-1.367-.008-2.473-1.114-2.479-2.48 0-1.359 1.12-2.479 2.479-2.479 1.361-.001 2.481 1.12 2.481 2.479zm-5.919 0c0 1.36-1.12 2.48-2.479 2.48-1.368-.007-2.475-1.113-2.481-2.48 0-1.359 1.12-2.479 2.481-2.479 1.358-.001 2.479 1.12 2.479 2.479zm0-5.919c0 1.359-1.12 2.479-2.479 2.479-1.367-.007-2.475-1.112-2.481-2.479 0-1.361 1.12-2.481 2.481-2.481 1.358 0 2.479 1.12 2.479 2.481z"/></svg>
Twilio
</span>
<span class="trust-logo-text trust-logo-icon">
<svg width="22" height="22" viewBox="0 0 24 24" fill="currentColor"><circle cx="12" cy="12" r="12"/><text x="12" y="16.5" text-anchor="middle" fill="white" font-size="13" font-weight="700" font-family="Arial,sans-serif">Z</text></svg>
Zurich
</span>
<img class="trust-logo-img trust-logo-svg" src="https://cdn.jsdelivr.net/npm/@lobehub/icons-static-svg@latest/icons/zapier-text.svg" alt="Zapier" height="28" />
<span class="trust-logo-text">Rocket Money</span>
<span class="trust-logo-text" style="font-style: italic;">Lemonade</span>
<span class="trust-logo-text trust-logo-icon">
<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M17.47 6.07a6.26 6.26 0 00-3.24-3.47A6.04 6.04 0 0011.32 2c-3.36 0-6.2 2.76-6.2 6.36a7.1 7.1 0 001.65 4.52L12 22l5.24-9.12a7.1 7.1 0 001.64-4.52c0-.77-.14-1.54-.41-2.29zM12 11.13a2.89 2.89 0 110-5.78 2.89 2.89 0 010 5.78z"/></svg>
The Weather Company
</span>
<span class="trust-logo-text" style="font-weight: 300; letter-spacing: 0.15em;">samsara</span>
</div>
</div>

Expand Down Expand Up @@ -809,6 +826,37 @@ curl http://0.0.0.0:4000/v1/chat/completions \
letter-spacing: 0.04em;
}

.trust-logo-icon {
display: inline-flex;
align-items: center;
gap: 0.35rem;
}

.trust-logo-icon svg {
flex-shrink: 0;
}

.trust-logo-svg {
filter: brightness(0);
opacity: 0.45;
}

.trust-logo-svg:hover {
filter: brightness(0);
opacity: 0.8;
}

@media (prefers-color-scheme: dark) {
.trust-logo-svg {
filter: brightness(0) invert(1);
opacity: 0.5;
}
.trust-logo-svg:hover {
filter: brightness(0) invert(1);
opacity: 0.9;
}
}

/* Search Section */
.search-section {
max-width: 1400px;
Expand Down Expand Up @@ -1090,7 +1138,7 @@ curl http://0.0.0.0:4000/v1/chat/completions \
width: 28px;
height: 28px;
border-radius: 6px;
background-color: var(--bg-secondary);
background-color: #ffffff;
display: flex;
align-items: center;
justify-content: center;
Expand Down
2 changes: 1 addition & 1 deletion src/ProviderDropdown.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@
height: 24px;
border-radius: 50%;
object-fit: contain;
background-color: var(--bg-color);
background-color: #ffffff;
padding: 3px;
flex-shrink: 0;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
Expand Down
2 changes: 1 addition & 1 deletion src/Providers.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@

.provider-avatar {
width: 40px; height: 40px; border-radius: 10px;
background-color: var(--bg-secondary); display: flex; align-items: center;
background-color: #ffffff; display: flex; align-items: center;
justify-content: center; flex-shrink: 0; overflow: hidden;
position: relative; padding: 6px; border: 1px solid var(--border-color);
}
Expand Down
90 changes: 74 additions & 16 deletions src/providers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,49 +33,107 @@ export function getProviderInitial(provider: string): string {
return provider.charAt(0).toUpperCase();
}

const LOBEHUB_CDN = "https://cdn.jsdelivr.net/npm/@lobehub/icons-static-svg@latest/icons";
const LITELLM_LOGOS = "https://raw.githubusercontent.com/BerriAI/litellm/main/ui/litellm-dashboard/public/assets/logos";

/**
* Get the logo URL for a provider from the LiteLLM GitHub repository
* Returns null if no logo is available for the provider
* Get the logo URL for a provider.
* Uses LobeHub icon CDN for most providers, falls back to LiteLLM repo for a few.
* Returns null if no logo is available.
*/
export function getProviderLogo(provider: string): string | null {
if (!provider) return null;

// Map provider names to their logo filenames in the LiteLLM repo (actual files from GitHub)
const providerLogoMap: { [key: string]: string } = {
"openai": "openai_small.svg",
"azure": "microsoft_azure.svg",

const lobehubMap: { [key: string]: string } = {
"openai": "openai.svg",
"azure": "azure.svg",
"azure_ai": "azureai.svg",
"azure_text": "azure.svg",
"anthropic": "anthropic.svg",
"bedrock": "bedrock.svg",
"bedrock_converse": "bedrock.svg",
"vertex_ai": "google.svg",
"vertexai": "google.svg",
"cohere": "cohere.svg",
"cohere_chat": "cohere.svg",
"groq": "groq.svg",
"mistral": "mistral.svg",
"deepinfra": "deepinfra.png",
"databricks": "databricks.svg",
"deepinfra": "deepinfra.svg",
"fireworks_ai": "fireworks.svg",
"fireworks": "fireworks.svg",
"ollama": "ollama.svg",
"openrouter": "openrouter.svg",
"deepseek": "deepseek.svg",
"cerebras": "cerebras.svg",
"oracle": "oracle.svg",
"text-completion-openai": "openai_small.svg",
"text-completion-openai": "openai.svg",
"text-completion-codestral": "mistral.svg",
"codestral": "mistral.svg",
"sagemaker": "aws.svg",
"aws": "aws.svg",
"aws_polly": "aws.svg",
"google": "google.svg",
"gemini": "google.svg",
"google_pse": "google.svg",
"palm": "palm.svg",
"ai21": "ai21.svg",
"aleph_alpha": "alephalpha.svg",
"anyscale": "anyscale.svg",
"assemblyai": "assemblyai.svg",
"cloudflare": "cloudflare.svg",
"elevenlabs": "elevenlabs.svg",
"exa_ai": "exa.svg",
"fal_ai": "fal.svg",
"featherless_ai": "featherless.svg",
"friendliai": "friendli.svg",
"github_copilot": "githubcopilot.svg",
"huggingface": "huggingface.svg",
"hyperbolic": "hyperbolic.svg",
"jina_ai": "jina.svg",
"lambda_ai": "lambda.svg",
"meta_llama": "meta.svg",
"minimax": "minimax.svg",
"moonshot": "moonshot.svg",
"morph": "morph.svg",
"novita": "novita.svg",
"nvidia_nim": "nvidia.svg",
"perplexity": "perplexity.svg",
"recraft": "recraft.svg",
"replicate": "replicate.svg",
"runwayml": "runway.svg",
"sambanova": "sambanova.svg",
"snowflake": "snowflake.svg",
"stability": "stability.svg",
"tavily": "tavily.svg",
"together_ai": "together.svg",
"v0": "v0.svg",
"vercel_ai_gateway": "vercel.svg",
"volcengine": "volcengine.svg",
"voyage": "voyage.svg",
"watsonx": "ibm.svg",
"xai": "xai.svg",
"zai": "zai.svg",
"amazon_nova": "nova.svg",
"chatgpt": "openai.svg",
"dashscope": "alibaba.svg",
};

const litellmMap: { [key: string]: string } = {
"databricks": "databricks.svg",
"oracle": "oracle.svg",
};

const lowerProvider = provider.toLowerCase();
const logoFilename = providerLogoMap[lowerProvider];

if (logoFilename) {
return `https://raw.githubusercontent.com/BerriAI/litellm/main/ui/litellm-dashboard/public/assets/logos/${logoFilename}`;

const lobeFile = lobehubMap[lowerProvider];
if (lobeFile) {
return `${LOBEHUB_CDN}/${lobeFile}`;
}


const litellmFile = litellmMap[lowerProvider];
if (litellmFile) {
return `${LITELLM_LOGOS}/${litellmFile}`;
}

return null;
}