Update code editor to material 3 look (#11628)

This commit is contained in:
Bram Kragten 2022-02-09 23:35:49 +01:00 committed by GitHub
parent f02dd39619
commit 9c9bfa2b77
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,8 +41,10 @@ export const theme = EditorView.theme({
"&": {
color: "var(--primary-text-color)",
backgroundColor:
"var(--code-editor-background-color, var(--card-background-color))",
"var(--code-editor-background-color, var(--mdc-text-field-fill-color, whitesmoke))",
"& ::selection": { backgroundColor: "rgba(var(--rgb-primary-color), 0.3)" },
borderRadius:
"var(--mdc-shape-small, 4px) var(--mdc-shape-small, 4px) 0px 0px",
caretColor: "var(--secondary-text-color)",
height: "var(--code-mirror-height, auto)",
maxHeight: "var(--code-mirror-max-height, unset)",
@ -64,7 +66,10 @@ export const theme = EditorView.theme({
".cm-scroller": { outline: "none" },
".cm-content": { caretColor: "var(--secondary-text-color)" },
".cm-content": {
caretColor: "var(--secondary-text-color)",
paddingTop: "16px",
},
".cm-panels": {
backgroundColor: "var(--primary-background-color)",
@ -166,7 +171,7 @@ export const theme = EditorView.theme({
".cm-gutters": {
backgroundColor:
"var(--paper-dialog-background-color, var(--primary-background-color))",
"var(--code-editor-gutter-color, var(--mdc-text-field-fill-color, whitesmoke))",
color: "var(--paper-dialog-color, var(--secondary-text-color))",
border: "none",
borderRight: