oxios 1.12.0

Oxios Agent OS — Agent Operating System powered by oxi-sdk
import {
  Activity,
  Bell,
  Bot,
  Brain,
  Calendar,
  Cpu,
  Database,
  Eye,
  Gauge,
  Globe,
  KeyRound,
  ListOrdered,
  MessageSquare,
  Monitor,
  Send,
  Server,
  Shield,
  Sparkles,
  Terminal,
  Wallet,
  Zap,
} from 'lucide-react'
import type { SectionIconKey } from './field-defs'

const ICON_MAP: Record<SectionIconKey, React.ComponentType<{ className?: string }>> = {
  engine: Bot,
  kernel: Cpu,
  exec: Terminal,
  security: Shield,
  orchestrator: Zap,
  context: Brain,
  gateway: Globe,
  session: Monitor,
  logging: Server,
  memory: Database,
  channels: Send,
  audit: Eye,
  update: Sparkles,
  calendar: Calendar,
  otel: Activity,
  agentLog: ListOrdered,
  resourceMonitor: Gauge,
  browser: Globe,
  budget: Wallet,
  secrets: KeyRound,
  notifications: Bell,
}

/** Generic fallback used when an id is unknown. */
const Fallback = MessageSquare

interface SectionIconProps {
  iconKey: SectionIconKey | string
  className?: string
}

/**
 * Renders the Lucide icon mapped to a section's `iconKey`. Centralised
 * here so the rail, the section tabs, and the section card all share
 * the same icon vocabulary.
 */
export function SectionIcon({ iconKey, className }: SectionIconProps) {
  const Icon = ICON_MAP[iconKey as SectionIconKey] ?? Fallback
  return <Icon className={className} />
}