Skip to content

Commit 3ab048c

Browse files
committed
Add text-white to vim status
1 parent 2a56058 commit 3ab048c

File tree

1 file changed

+10
-7
lines changed
  • services/app/apps/codebattle/assets/js/widgets/components

1 file changed

+10
-7
lines changed

services/app/apps/codebattle/assets/js/widgets/components/Editor.jsx

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,16 @@ function Editor(props) {
3737
const vimModeRef = useRef(null);
3838

3939
// Wrap your existing "didMount" to store editor and call original if needed
40-
const handleEditorDidMount = React.useCallback((editor, monaco) => {
41-
editorRef.current = editor;
40+
const handleEditorDidMount = React.useCallback(
41+
(editor, monaco) => {
42+
editorRef.current = editor;
4243

43-
if (typeof originalEditorDidMount === 'function') {
44-
originalEditorDidMount(editor, monaco);
45-
}
46-
}, [originalEditorDidMount]);
44+
if (typeof originalEditorDidMount === 'function') {
45+
originalEditorDidMount(editor, monaco);
46+
}
47+
},
48+
[originalEditorDidMount],
49+
);
4750
// Whenever `mode` changes, enable or disable vimMode
4851
useEffect(() => {
4952
// If we haven't mounted the editor yet, exit
@@ -82,7 +85,7 @@ function Editor(props) {
8285

8386
{/* This is for displaying normal/insert mode status in Vim */}
8487
<div
85-
className="bg-dark"
88+
className="bg-dark text-white"
8689
ref={vimStatusRef}
8790
style={{
8891
padding: '4px 8px',

0 commit comments

Comments
 (0)