Fix error: chars in editor could end up without any color

This commit is contained in:
2024-01-15 22:44:04 +01:00
parent 6dfbdbb6d4
commit 3314c089ed

View File

@ -67,7 +67,6 @@ export const getCodeMirrorTheme = (theme: {[key: string]: string}): Extension =>
const toposTheme = EditorView.theme({ const toposTheme = EditorView.theme({
"&": { "&": {
color: background, color: background,
// backgroundColor: background,
backgroundColor: "transparent", backgroundColor: "transparent",
fontSize: "24px", fontSize: "24px",
fontFamily: "IBM Plex Mono", fontFamily: "IBM Plex Mono",
@ -76,6 +75,9 @@ export const getCodeMirrorTheme = (theme: {[key: string]: string}): Extension =>
caretColor: cursor, caretColor: cursor,
fontFamily: "IBM Plex Mono", fontFamily: "IBM Plex Mono",
}, },
".cm-line": {
color: `${brightwhite}`,
},
".cm-cursor, .cm-dropCursor": { ".cm-cursor, .cm-dropCursor": {
borderLeftColor: cursor, borderLeftColor: cursor,
}, },