This commit is contained in:
2024-01-24 18:01:48 +08:00
parent 9bf9c770f1
commit 87fcb12960
5 changed files with 10 additions and 11 deletions

View File

@@ -6,7 +6,6 @@ import { EditorView } from "@codemirror/view"
import { oneDark } from "../themes/oneDark"
import { smoothy } from "../themes/smoothy"
import { LANGUAGE } from "~/utils/types"
import { isDark } from "../composables/dark"
const styleTheme = EditorView.baseTheme({
"& .cm-scroller": {
@@ -38,6 +37,9 @@ const props = withDefaults(defineProps<Props>(), {
})
const code = ref(props.modelValue)
const isDark = useDark()
watch(
() => props.modelValue,
(v) => {