Add configurable terminal profiles
This commit is contained in:
@@ -8,10 +8,7 @@ import { OpenCodeIcon } from "@/components/icons/opencode-icon";
|
||||
import { OmpIcon } from "@/components/icons/omp-icon";
|
||||
import { PiIcon } from "@/components/icons/pi-icon";
|
||||
import { ACP_PROVIDER_CATALOG } from "@/data/acp-provider-catalog";
|
||||
import {
|
||||
resolveProviderIconName,
|
||||
type BuiltinProviderIconName,
|
||||
} from "@/components/provider-icon-name";
|
||||
import { resolveProviderIconName } from "@/components/provider-icon-name";
|
||||
|
||||
export interface ProviderIconProps {
|
||||
size: number;
|
||||
@@ -20,7 +17,7 @@ export interface ProviderIconProps {
|
||||
|
||||
export type ProviderIconComponent = ComponentType<ProviderIconProps>;
|
||||
|
||||
const BUILTIN_PROVIDER_ICONS: Record<BuiltinProviderIconName, ProviderIconComponent> = {
|
||||
const BUILTIN_PROVIDER_ICONS: Record<string, ProviderIconComponent> = {
|
||||
claude: ClaudeIcon as unknown as ProviderIconComponent,
|
||||
codex: CodexIcon as unknown as ProviderIconComponent,
|
||||
copilot: CopilotIcon as unknown as ProviderIconComponent,
|
||||
@@ -53,7 +50,10 @@ function getCatalogProviderIcon(provider: string): ProviderIconComponent {
|
||||
if (cached) {
|
||||
return cached;
|
||||
}
|
||||
const iconSvg = CATALOG_ICON_SVGS.get(provider) ?? "";
|
||||
const iconSvg = CATALOG_ICON_SVGS.get(provider);
|
||||
if (!iconSvg) {
|
||||
return Bot;
|
||||
}
|
||||
const icon = createCatalogIcon(provider, iconSvg);
|
||||
catalogIconComponents.set(provider, icon);
|
||||
return icon;
|
||||
|
||||
Reference in New Issue
Block a user