[OCaml] Mobile-friendly clone of cgit.
style switch syntax theme to gruvbox dark hard contrast
Replace the GitHub-dark-inspired palette with gruvbox dark hard contrast: - Keywords/storage: bright red (#fb4934) - Strings: bright green (#b8bb26) - Comments: gray (#928374), italic - Constants/numbers: purple (#d3869b) - Functions: aqua (#8ec07c) - Types: yellow (#fabd2f) - Variables: blue (#83a598) - Tags: orange (#fe8019) - Punctuation: foreground (#ebdbb2) - Diff insertions: green | deletions: red Palette sourced from https://github.com/morhetz/gruvbox
lib/static/syntax-theme.css
@@ -1,122 +1,135 @@
1
1
/* ==========================================================================
2
Removed:
Syntax highlighting theme (server-rendered via hilite + TextMate grammars)
2
Added:
Syntax highlighting theme: Gruvbox Dark Hard Contrast
3
3
4
Removed:
Colour palette for source code tokens. Selectors use attribute-contains
5
Removed:
(class*=) to match hilite's hierarchical scope-based class names in a
6
Removed:
language-agnostic way.
4
Added:
Colour palette from https://github.com/morhetz/gruvbox
5
Added:
Background #1d2021 | Foreground #ebdbb2
6
Added:
7
Added:
Bright: red #fb4934 | green #b8bb26 | yellow #fabd2f | blue #83a598
8
Added:
purple #d3869b | aqua #8ec07c | orange #fe8019
9
Added:
Neutral: red #cc241d | green #98971a | yellow #d79921 | blue #458588
10
Added:
purple #b16286 | aqua #689d6a | orange #d65d0e
11
Added:
Gray: #928374 | Light fg: #fbf1c7
7
12
========================================================================== */
8
13
9
14
/* Keywords: control flow, storage, operators */
10
15
[class*="-keyword"] {
11
Removed:
color: #ff7b72;
16
Added:
color: #fb4934;
12
17
}
13
18
14
19
[class*="-storage-type"],
15
20
[class*="-storage-modifier"] {
16
Removed:
color: #ff7b72;
21
Added:
color: #fb4934;
17
22
}
18
23
19
24
/* Strings */
20
25
[class*="-string"] {
21
Removed:
color: #a5d6ff;
26
Added:
color: #b8bb26;
22
27
}
23
28
24
29
/* Comments */
25
30
[class*="-comment"] {
26
Removed:
color: #8b949e;
31
Added:
color: #928374;
27
32
font-style: italic;
28
33
}
29
34
30
35
/* Constants: numbers, booleans, language constants */
31
36
[class*="-constant-numeric"],
32
37
[class*="-constant-language"] {
33
Removed:
color: #79c0ff;
38
Added:
color: #d3869b;
34
39
}
35
40
36
41
[class*="-constant-character"] {
37
Removed:
color: #a5d6ff;
42
Added:
color: #b8bb26;
38
43
}
39
44
40
45
/* Entity names: functions, classes, types, tags */
41
Removed:
[class*="-entity-name-function"],
46
Added:
[class*="-entity-name-function"] {
47
Added:
color: #8ec07c;
48
Added:
}
49
Added:
42
50
[class*="-entity-name-type"] {
43
Removed:
color: #d2a8ff;
51
Added:
color: #fabd2f;
44
52
}
45
53
46
54
[class*="-entity-name-tag"] {
47
Removed:
color: #7ee787;
55
Added:
color: #fe8019;
48
56
}
49
57
50
58
[class*="-entity-other-attribute-name"] {
51
Removed:
color: #79c0ff;
59
Added:
color: #83a598;
52
60
}
53
61
54
62
/* Support: built-in functions, types */
55
Removed:
[class*="-support-function"],
63
Added:
[class*="-support-function"] {
64
Added:
color: #8ec07c;
65
Added:
}
66
Added:
56
67
[class*="-support-type"] {
57
Removed:
color: #79c0ff;
68
Added:
color: #fabd2f;
58
69
}
59
70
60
71
[class*="-support-class"] {
61
Removed:
color: #d2a8ff;
72
Added:
color: #fabd2f;
62
73
}
63
74
64
75
/* Variables */
65
76
[class*="-variable-language"],
66
77
[class*="-variable-other-constant"] {
67
Removed:
color: #ffa657;
78
Added:
color: #83a598;
68
79
}
69
80
70
81
[class*="-variable-parameter"] {
71
Removed:
color: #ffa657;
82
Added:
color: #83a598;
72
83
}
73
84
74
Removed:
/* Punctuation — keep subdued */
85
Added:
/* Punctuation — subdued foreground */
75
86
[class*="-punctuation"] {
76
Removed:
color: #c9d1d9;
87
Added:
color: #ebdbb2;
77
88
}
78
89
79
Removed:
/* Meta — structural, usually inherits */
90
Added:
/* Meta — structural, inherits from parent or children */
80
91
[class*="-meta"] {
81
Removed:
/* no color override — inherits from parent or children */
92
Added:
/* no color override */
82
93
}
83
94
84
95
/* Markup (markdown, HTML) */
85
96
[class*="-markup-heading"] {
86
Removed:
color: #79c0ff;
97
Added:
color: #fe8019;
87
98
font-weight: bold;
88
99
}
89
100
90
101
[class*="-markup-bold"] {
102
Added:
color: #fabd2f;
91
103
font-weight: bold;
92
104
}
93
105
94
106
[class*="-markup-italic"] {
107
Added:
color: #83a598;
95
108
font-style: italic;
96
109
}
97
110
98
111
[class*="-markup-inline-raw"],
99
112
[class*="-markup-fenced-code"] {
100
Removed:
color: #a5d6ff;
113
Added:
color: #8ec07c;
101
114
}
102
115
103
116
[class*="-markup-deleted"] {
104
Removed:
color: #ffa198;
105
Removed:
background-color: rgba(255, 129, 130, 0.1);
117
Added:
color: #fb4934;
118
Added:
background-color: rgba(251, 73, 52, 0.1);
106
119
}
107
120
108
121
[class*="-markup-inserted"] {
109
Removed:
color: #7ee787;
110
Removed:
background-color: rgba(63, 185, 80, 0.1);
122
Added:
color: #b8bb26;
123
Added:
background-color: rgba(184, 187, 38, 0.1);
111
124
}
112
125
113
126
/* Diff specific */
114
127
[class*="-punctuation-definition-inserted"],
115
128
[class*="-markup-inserted"] {
116
Removed:
color: #7ee787;
129
Added:
color: #b8bb26;
117
130
}
118
131
119
132
[class*="-punctuation-definition-deleted"],
120
133
[class*="-markup-deleted"] {
121
Removed:
color: #ffa198;
134
Added:
color: #fb4934;
122
135
}