0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-03-29 12:08:12 +00:00
This commit is contained in:
Víctor Losada Hernández
2026-03-29 00:21:30 +01:00
parent 83406479a7
commit 8b347bafbc
4 changed files with 12 additions and 12 deletions

View File

@@ -174,7 +174,7 @@ const CodeEditor = forwardRef(
highlightActiveLine(), highlightActiveLine(),
highlightActiveLineGutter(), highlightActiveLineGutter(),
highlightCompartment.of([customHighlightPlugin,highlightExtension]), highlightCompartment.of([customHighlightPlugin, highlightExtension]),
themeCompartment.of(themeExtension), themeCompartment.of(themeExtension),
...(tab !== 'brewStyles' ? [autocompleteEmoji] : []), ...(tab !== 'brewStyles' ? [autocompleteEmoji] : []),
search(), search(),
@@ -323,15 +323,15 @@ const CodeEditor = forwardRef(
undo : ()=>undo(viewRef.current), undo : ()=>undo(viewRef.current),
redo : ()=>redo(viewRef.current), redo : ()=>redo(viewRef.current),
historySize : () => { historySize : ()=>{
const view = viewRef.current; const view = viewRef.current;
if (!view) return { done: 0, undone: 0 }; if(!view) return { done: 0, undone: 0 };
return { return {
done: undoDepth(view.state), done : undoDepth(view.state),
undone: redoDepth(view.state), undone : redoDepth(view.state),
}; };
}, },
focus : ()=>viewRef.current.focus(), focus : ()=>viewRef.current.focus(),
})); }));