mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-20 00:24:24 +01:00
Fix editor stale callbacks and recent item deletion
This commit is contained in:
@@ -267,10 +267,11 @@ function getExtensions({
|
||||
: []),
|
||||
|
||||
// Handle onFocus
|
||||
// NOTE: These *must* be anonymous functions so the references update properly
|
||||
EditorView.domEventHandlers({
|
||||
focus: onFocus.current,
|
||||
blur: onBlur.current,
|
||||
keydown: onKeyDown.current,
|
||||
focus: () => onFocus.current?.(),
|
||||
blur: () => onBlur.current?.(),
|
||||
keydown: e => onKeyDown.current?.(e),
|
||||
}),
|
||||
|
||||
// Handle onChange
|
||||
|
||||
Reference in New Issue
Block a user