feat: handle close on blur

This commit is contained in:
Yunus M 2025-06-14 22:34:40 +05:30 committed by SagarRajput-7
parent 5c06429ebe
commit 4e06d7757b
2 changed files with 9 additions and 2 deletions

View File

@ -225,7 +225,7 @@ function HavingFilter({ onClose }: { onClose: () => void }): JSX.Element {
},
],
defaultKeymap: true,
closeOnBlur: false,
closeOnBlur: true,
maxRenderedOptions: 200,
activateOnTyping: true,
}),
@ -269,6 +269,9 @@ function HavingFilter({ onClose }: { onClose: () => void }): JSX.Element {
}}
onBlur={(): void => {
setIsFocused(false);
if (editorRef.current) {
closeCompletion(editorRef.current);
}
}}
/>
<Button

View File

@ -405,7 +405,7 @@ function QueryAggregationSelect(): JSX.Element {
},
],
defaultKeymap: true,
closeOnBlur: false,
closeOnBlur: true,
maxRenderedOptions: 50,
activateOnTyping: true,
}),
@ -447,6 +447,10 @@ function QueryAggregationSelect(): JSX.Element {
}}
onBlur={(): void => {
setIsFocused(false);
if (editorRef.current) {
closeCompletion(editorRef.current);
}
}}
/>
</div>