import { clsx } from 'clsx/lite'; import { Command } from 'cmdk'; import { ReactNode } from 'react'; import Spinner from '../components/Spinner'; export default function CommandKItem({ label, value, keywords, onSelect, accessory, annotation, annotationAria, loading, disabled, }: { label: ReactNode value: string keywords?: string[] onSelect: () => void accessory?: ReactNode annotation?: ReactNode annotationAria?: string loading?: boolean disabled?: boolean }) { return (
{accessory} {label} {annotation && !loading && {annotation} } {loading && }
); }