import { useState } from 'react'; import { SessionIcon, SessionIconType } from '../icon'; import { SessionDropdownItem, SessionDropDownItemType } from './SessionDropdownItem'; // THIS IS DROPDOWN ACCORDION STYLE OPTIONS SELECTOR ELEMENT, NOT A CONTEXTMENU type Props = { label: string; onClick?: any; expanded?: boolean; options: Array<{ content: string; id?: string; icon?: SessionIconType | null; type?: SessionDropDownItemType; active?: boolean; onClick?: any; }>; dataTestId?: string; }; export const SessionDropdown = (props: Props) => { const { label, options, dataTestId } = props; const [expanded, setExpanded] = useState(!!props.expanded); const chevronOrientation = expanded ? 180 : 0; return (