import { Icon } from "@iconify/react" import { Button, DropdownMenu } from "@ivtui/base" interface DropdownProps { options: { label: string; value: string }[] value: string onChange: (value: string) => void placeholder: string disabled?: boolean size?: "1" | "2" | "3" title?: string } export function Dropdown({ options, value, onChange, placeholder, disabled, size = "2", title, }: React.PropsWithChildren) { const selectedOption = options.find(opt => opt.value === value) const handleOptionSelect = (optionValue: string) => { if (!disabled && optionValue !== value) { onChange(optionValue) } } return ( {options.map(option => ( handleOptionSelect(option.value)} className={option.value === value ? "bg-gray-100" : ""} > {option.label} {option.value === value && } ))} ) }