chore(react/note_title): delete new notes on escape

This commit is contained in:
Elian Doran
2025-08-21 13:13:48 +03:00
parent 8a543d4513
commit 51e8a80ca3
3 changed files with 33 additions and 25 deletions

View File

@@ -101,7 +101,7 @@ export function useSpacedUpdate(callback: () => Promise<void>, interval = 1000)
// Update callback ref when it changes
useEffect(() => {
callbackRef.current = callback;
});
}, [callback]);
// Create SpacedUpdate instance only once
if (!spacedUpdateRef.current) {