Files
orca/mobile/src/session/MobileNativeChatToolIcon.tsx
T

47 lines
981 B
TypeScript

import {
Bot,
Brain,
Eye,
Folder,
Globe,
ListChecks,
MessageSquareMore,
Pencil,
Plug,
Search,
SquareTerminal,
Wrench,
type LucideIcon
} from 'lucide-react-native'
import type { NativeChatToolIconName } from '../../../src/shared/native-chat-tool-icon'
/** Desktop parity: `NativeChatToolIcon`'s glyph table. */
const GLYPHS: Record<NativeChatToolIconName, LucideIcon> = {
eye: Eye,
search: Search,
folder: Folder,
'square-terminal': SquareTerminal,
pencil: Pencil,
globe: Globe,
plug: Plug,
bot: Bot,
'list-checks': ListChecks,
wrench: Wrench,
'message-square-more': MessageSquareMore,
brain: Brain
}
/** A tool category's glyph. Decorative: the word beside it names the row. */
export function MobileNativeChatToolGlyph({
name,
size,
color
}: {
name: NativeChatToolIconName
size: number
color: string
}): React.JSX.Element {
const Glyph = GLYPHS[name]
return <Glyph size={size} color={color} strokeWidth={2} />
}