mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
fix(ui): fix add node autoconnect
The new select component appears to close itself before calling the onchange handler. This short-circuits the autoconnect logic. Tweaked so the ordering is correct.
This commit is contained in:
parent
3428ea1b3c
commit
3fe332e85f
@ -155,8 +155,9 @@ const AddNodePopover = () => {
|
||||
return;
|
||||
}
|
||||
addNode(v.value);
|
||||
dispatch(addNodePopoverClosed());
|
||||
},
|
||||
[addNode]
|
||||
[addNode, dispatch]
|
||||
);
|
||||
|
||||
const onClose = useCallback(() => {
|
||||
@ -235,6 +236,7 @@ const AddNodePopover = () => {
|
||||
onMenuClose={onClose}
|
||||
onKeyDown={onKeyDown}
|
||||
inputRef={inputRef}
|
||||
closeMenuOnSelect={false}
|
||||
/>
|
||||
</InvPopoverBody>
|
||||
</InvPopoverContent>
|
||||
|
Loading…
Reference in New Issue
Block a user