Skip to content
7 changes: 6 additions & 1 deletion src/components/ButtonWithDropdownMenu/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,12 @@ function ButtonWithDropdownMenu<IValueType>({
onClose={() => setIsMenuVisible(false)}
onItemSelected={() => setIsMenuVisible(false)}
anchorPosition={popoverAnchorPosition}
anchorRef={caretButton}
anchorRef={() => {
if (caretButton === null) {
return;
}
return caretButton;
}}
withoutOverlay
anchorAlignment={anchorAlignment}
headerText={menuHeaderText}
Expand Down