Skip to content

Commit 72de2fb

Browse files
committed
fix: editor autocomplete higlight styling
1 parent 621cb1f commit 72de2fb

File tree

1 file changed

+5
-4
lines changed
  • web-common/src/components/editor

1 file changed

+5
-4
lines changed

web-common/src/components/editor/theme.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
import { EditorView } from "@codemirror/view";
2-
import type { Extension } from "@codemirror/state";
31
import { HighlightStyle, syntaxHighlighting } from "@codemirror/language";
2+
import type { Extension } from "@codemirror/state";
3+
import { EditorView } from "@codemirror/view";
44
import { tags as t } from "@lezer/highlight";
55

66
const blue = "var(--color-blue-800)";
77
const purple = "var(--color-purple-700)";
88
const invalid = "var(--color-red-600)";
99
const emerald = "var(--color-emerald-700)";
10+
const emeraldHighlight = "var(--color-emerald-400)";
1011
const gray = "var(--fg-muted)";
1112
const amber = "var(--color-amber-600)";
1213
const highlightBackground = "var(--line-highlight)";
@@ -102,9 +103,9 @@ export const editorTheme = EditorView.theme(
102103
borderBottomColor: tooltipBackground,
103104
},
104105
".cm-tooltip-autocomplete": {
106+
padding: "0",
105107
"& > ul > li[aria-selected]": {
106-
backgroundColor: highlightBackground,
107-
color: emerald,
108+
color: emeraldHighlight,
108109
},
109110
},
110111
},

0 commit comments

Comments
 (0)