From ea7e7f92c334e3ec4a93392357cdea146f474137 Mon Sep 17 00:00:00 2001 From: caymaynard <131637116+caymaynard@users.noreply.github.com> Date: Thu, 22 Aug 2024 05:30:54 +1000 Subject: [PATCH] fix(combobox): prevent opening on input with triggerMode="manual" (#465) --- packages/core/src/combobox/combobox-base.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/core/src/combobox/combobox-base.tsx b/packages/core/src/combobox/combobox-base.tsx index 98706978..776aea1c 100644 --- a/packages/core/src/combobox/combobox-base.tsx +++ b/packages/core/src/combobox/combobox-base.tsx @@ -596,6 +596,12 @@ export function ComboboxBase< focusStrategy: FocusStrategy | boolean, triggerMode?: ComboboxTriggerMode, ) => { + + // If set to only open manually, ignore other triggers + if (local.triggerMode === 'manual' && triggerMode !== 'manual') { + return; + } + // Show all option if menu is manually opened. const showAllOptions = setShowAllOptions(triggerMode === "manual");