mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
Added back bounds check
This commit is contained in:
parent
c9951cd86b
commit
84a001720c
@ -157,11 +157,13 @@ export const Flow = () => {
|
||||
}, []);
|
||||
|
||||
const onMouseMove = useCallback((event: MouseEvent<HTMLDivElement>) => {
|
||||
const pos = $flow.get()?.screenToFlowPosition({
|
||||
x: event.clientX,
|
||||
y: event.clientY,
|
||||
});
|
||||
cursorPosition.current = pos;
|
||||
if (flowWrapper.current?.getBoundingClientRect()) {
|
||||
const pos = $flow.get()?.screenToFlowPosition({
|
||||
x: event.clientX,
|
||||
y: event.clientY,
|
||||
});
|
||||
cursorPosition.current = pos;
|
||||
}
|
||||
}, []);
|
||||
|
||||
// #region Updatable Edges
|
||||
|
Loading…
Reference in New Issue
Block a user