Dropdown keys and pointer events

This commit is contained in:
Gregory Schier
2023-04-10 16:02:29 -07:00
parent 8069094201
commit 7e98b6d853
8 changed files with 21 additions and 5 deletions

View File

@@ -25,6 +25,7 @@ export type DropdownItemSeparator = {
export type DropdownItem =
| {
key: string;
type?: 'default';
label: ReactNode;
variant?: 'danger';
@@ -306,7 +307,7 @@ const Menu = forwardRef<Omit<DropdownRef, 'open' | 'isOpen' | 'toggle'>, MenuPro
focused={i === selectedIndex}
onFocus={handleFocus}
onSelect={handleSelect}
key={i + item.label}
key={item.key}
item={item}
/>
);