mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-04-16 23:40:32 +08:00
fix(editor): update theme mode for MonacoEditor to use 'light' instead of 'vs' in multiple components #5440
This commit is contained in:
parent
3db69bd816
commit
d0d35da2f1
@ -192,7 +192,7 @@ export const EditorViewer = <T extends Language>(props: Props<T>) => {
|
|||||||
>
|
>
|
||||||
<MonacoEditor
|
<MonacoEditor
|
||||||
language={language}
|
language={language}
|
||||||
theme={themeMode === "light" ? "vs" : "vs-dark"}
|
theme={themeMode === "light" ? "light" : "vs-dark"}
|
||||||
options={{
|
options={{
|
||||||
tabSize: ["yaml", "javascript", "css"].includes(language) ? 2 : 4, // 根据语言类型设置缩进大小
|
tabSize: ["yaml", "javascript", "css"].includes(language) ? 2 : 4, // 根据语言类型设置缩进大小
|
||||||
minimap: {
|
minimap: {
|
||||||
|
|||||||
@ -1092,7 +1092,7 @@ export const GroupsEditorViewer = (props: Props) => {
|
|||||||
height="100%"
|
height="100%"
|
||||||
language="yaml"
|
language="yaml"
|
||||||
value={currData}
|
value={currData}
|
||||||
theme={themeMode === "light" ? "vs" : "vs-dark"}
|
theme={themeMode === "light" ? "light" : "vs-dark"}
|
||||||
options={{
|
options={{
|
||||||
tabSize: 2, // 根据语言类型设置缩进大小
|
tabSize: 2, // 根据语言类型设置缩进大小
|
||||||
minimap: {
|
minimap: {
|
||||||
|
|||||||
@ -473,7 +473,7 @@ export const ProxiesEditorViewer = (props: Props) => {
|
|||||||
height="100%"
|
height="100%"
|
||||||
language="yaml"
|
language="yaml"
|
||||||
value={currData}
|
value={currData}
|
||||||
theme={themeMode === "light" ? "vs" : "vs-dark"}
|
theme={themeMode === "light" ? "light" : "vs-dark"}
|
||||||
options={{
|
options={{
|
||||||
tabSize: 2, // 根据语言类型设置缩进大小
|
tabSize: 2, // 根据语言类型设置缩进大小
|
||||||
minimap: {
|
minimap: {
|
||||||
|
|||||||
@ -789,7 +789,7 @@ export const RulesEditorViewer = (props: Props) => {
|
|||||||
height="100%"
|
height="100%"
|
||||||
language="yaml"
|
language="yaml"
|
||||||
value={currData}
|
value={currData}
|
||||||
theme={themeMode === "light" ? "vs" : "vs-dark"}
|
theme={themeMode === "light" ? "light" : "vs-dark"}
|
||||||
options={{
|
options={{
|
||||||
tabSize: 2, // 根据语言类型设置缩进大小
|
tabSize: 2, // 根据语言类型设置缩进大小
|
||||||
minimap: {
|
minimap: {
|
||||||
|
|||||||
@ -1040,7 +1040,7 @@ export function DnsViewer({ ref }: { ref?: Ref<DialogRef> }) {
|
|||||||
height="100vh"
|
height="100vh"
|
||||||
language="yaml"
|
language="yaml"
|
||||||
value={yamlContent}
|
value={yamlContent}
|
||||||
theme={themeMode === "light" ? "vs" : "vs-dark"}
|
theme={themeMode === "light" ? "light" : "vs-dark"}
|
||||||
className="flex-grow"
|
className="flex-grow"
|
||||||
options={{
|
options={{
|
||||||
tabSize: 2,
|
tabSize: 2,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user