1/* 2 * gruvbox-light 3 * author morhetz 4 * From github.com/codemirror/codemirror5/blob/master/theme/gruvbox-light.css 5 */ 6import { tags as t } from '@lezer/highlight'; 7import { createTheme } from './theme-helper.mjs'; 8 9export const settings = { 10 light: true, 11 background: '#fbf1c7', 12 lineBackground: '#fbf1c799', 13 foreground: '#3c3836', 14 muted: '#3c383650', 15 caret: '#af3a03', 16 selection: '#ebdbb2', 17 selectionMatch: '#bdae93', 18 lineHighlight: '#ebdbb2', 19 gutterBackground: '#ebdbb2', 20 gutterForeground: '#665c54', 21 gutterBorder: 'transparent', 22}; 23 24export default createTheme({ 25 theme: 'light', 26 settings: { 27 background: '#fbf1c7', 28 foreground: '#3c3836', 29 muted: '#3c383650', 30 caret: '#af3a03', 31 selection: '#bdae9391', 32 selectionMatch: '#bdae9391', 33 lineHighlight: '#a37f2238', 34 gutterBackground: '#ebdbb2', 35 gutterForeground: '#665c54', 36 gutterBorder: 'transparent', 37 }, 38 styles: [ 39 { tag: t.keyword, color: '#9d0006' }, 40 { 41 tag: [t.name, t.deleted, t.character, t.propertyName, t.macroName], 42 color: '#427b58', 43 }, 44 { tag: [t.variableName], color: '#076678' }, 45 { tag: [t.function(t.variableName)], color: '#79740e', fontStyle: 'bold' }, 46 { tag: [t.labelName], color: '#3c3836' }, 47 { 48 tag: [t.color, t.constant(t.name), t.standard(t.name)], 49 color: '#8f3f71', 50 }, 51 { tag: [t.definition(t.name), t.separator], color: '#3c3836' }, 52 { tag: [t.brace], color: '#3c3836' }, 53 { 54 tag: [t.annotation], 55 color: '#9d0006', 56 }, 57 { 58 tag: [t.number, t.changed, t.annotation, t.modifier, t.self, t.namespace], 59 color: '#8f3f71', 60 }, 61 { 62 tag: [t.typeName, t.className], 63 color: '#b57614', 64 }, 65 { 66 tag: [t.operator, t.operatorKeyword], 67 color: '#9d0006', 68 }, 69 { 70 tag: [t.tagName], 71 color: '#427b58', 72 fontStyle: 'bold', 73 }, 74 { 75 tag: [t.squareBracket], 76 color: '#af3a03', 77 }, 78 { 79 tag: [t.angleBracket], 80 color: '#076678', 81 }, 82 { 83 tag: [t.attributeName], 84 color: '#427b58', 85 }, 86 { 87 tag: [t.regexp], 88 color: '#427b58', 89 }, 90 { 91 tag: [t.quote], 92 color: '#928374', 93 }, 94 { tag: [t.string], color: '#3c3836' }, 95 { 96 tag: t.link, 97 color: '#7c6f64', 98 textDecoration: 'underline', 99 textUnderlinePosition: 'under', 100 }, 101 { 102 tag: [t.url, t.escape, t.special(t.string)], 103 color: '#8f3f71', 104 }, 105 { tag: [t.meta], color: '#b57614' }, 106 { tag: [t.comment], color: '#928374', fontStyle: 'italic' }, 107 { tag: t.strong, fontWeight: 'bold', color: '#af3a03' }, 108 { tag: t.emphasis, fontStyle: 'italic', color: '#79740e' }, 109 { tag: t.strikethrough, textDecoration: 'line-through' }, 110 { tag: t.heading, fontWeight: 'bold', color: '#79740e' }, 111 { tag: [t.heading1, t.heading2], fontWeight: 'bold', color: '#79740e' }, 112 { 113 tag: [t.heading3, t.heading4], 114 fontWeight: 'bold', 115 color: '#b57614', 116 }, 117 { 118 tag: [t.heading5, t.heading6], 119 color: '#b57614', 120 }, 121 { tag: [t.atom, t.bool, t.special(t.variableName)], color: '#8f3f71' }, 122 { 123 tag: [t.processingInstruction, t.inserted], 124 color: '#076678', 125 }, 126 { 127 tag: [t.contentSeparator], 128 color: '#9d0006', 129 }, 130 { tag: t.invalid, color: '#af3a03', borderBottom: `1px dotted #9d0006` }, 131 ], 132});