import { XIcon } from "lucide-react";
import { cn } from "@/lib/utils";
/**
* Shared visual for a `/skill` activation, used both as a removable chip in the
* composer and as a read-only chip in the chat transcript. Keeping a single
* source of truth means the two stay in lockstep instead of drifting apart in
* their Tailwind classes.
*/
const CHIP_BASE_CLASS =
"border-primary/20 bg-primary/10 text-primary inline-flex h-6 shrink-0 items-center rounded-md border px-1.5 font-mono text-xs leading-none font-medium shadow-xs";
export function SlashSkillChip({
name,
className,
onRemove,
removeLabel,
}: {
name: string;
className?: string;
/** When provided, the chip renders as a removable button with a close icon. */
onRemove?: () => void;
removeLabel?: string;
}) {
if (onRemove) {
return (
);
}
return (
/{name}
);
}