import React from 'react'; import Arrow2 from '../assets/dropdown-arrow.svg'; import Edit from '../assets/edit.svg'; import Trash from '../assets/trash.svg'; function Dropdown({ options, selectedValue, onSelect, size = 'w-32', rounded = 'xl', border = 'border-2', borderColor = 'silver', showEdit, onEdit, showDelete, onDelete, placeholder, }: { options: | string[] | { name: string; id: string; type: string }[] | { label: string; value: string }[] | { value: number; description: string }[]; selectedValue: | string | { label: string; value: string } | { value: number; description: string } | null; onSelect: | ((value: string) => void) | ((value: { name: string; id: string; type: string }) => void) | ((value: { label: string; value: string }) => void) | ((value: { value: number; description: string }) => void); size?: string; rounded?: 'xl' | '3xl'; border?: 'border' | 'border-2'; borderColor?: string; showEdit?: boolean; onEdit?: (value: { name: string; id: string; type: string }) => void; showDelete?: boolean; onDelete?: (value: string) => void; placeholder?: string; }) { const [isOpen, setIsOpen] = React.useState(false); const borderRadius = rounded === 'xl' ? 'rounded-xl' : 'rounded-3xl'; const borderTopRadius = rounded === 'xl' ? 'rounded-t-xl' : 'rounded-t-3xl'; return (