all repos

mugit @ 9c82bda

🐮 git server that your cow will love

mugit/web/static/style.css (view raw)

Oleksandr Smirnov Oleksandr Smirnov
olexsmir@gmail.com
ui: hint links more clearly, 3 months ago
1
:root {
2
  --white: #fff;
3
  --light: #f4f4f4;
4
  --cyan: #509c93;
5
  --light-gray: #eee;
6
  --medium-gray: #ddd;
7
  --gray: #6a6a6a;
8
  --dark: #444;
9
  --darker: #222;
10
  --diff-add: green;
11
  --diff-del: red;
12
13
  --sans-font: -apple-system, BlinkMacSystemFont, "Inter", "Roboto", "Segoe UI", sans-serif;
14
  --mono-font: 'SF Mono', SFMono-Regular, ui-monospace, 'DejaVu Sans Mono', 'Roboto Mono', Menlo, Consolas, monospace;
15
}
16
17
@media (prefers-color-scheme: dark) {
18
  :root {
19
    color-scheme: dark light;
20
    --light: #181818;
21
    --cyan: #76c7c0;
22
    --light-gray: #333;
23
    --medium-gray: #444;
24
    --gray: #aaa;
25
    --dark: #ddd;
26
    --darker: #f4f4f4;
27
    --white: #000;
28
  }
29
}
30
31
* {
32
  box-sizing: border-box;
33
  padding: 0;
34
  margin: 0;
35
}
36
37
html {
38
  background: var(--white);
39
  -webkit-text-size-adjust: none;
40
  -webkit-font-smoothing: antialiased;
41
  -moz-osx-font-smoothing: grayscale;
42
  font-family: var(--sans-font);
43
  font-weight: 400;
44
}
45
46
body {
47
  max-width: 1200px;
48
  padding: 0 13px;
49
  margin: 40px auto;
50
}
51
52
::selection {
53
  background: var(--medium-gray);
54
}
55
56
a {
57
  text-decoration: none;
58
  word-wrap: break-word;
59
  color: var(--darker);
60
  border-bottom: 0;
61
}
62
63
a:hover { border-bottom: 1.5px solid var(--gray); }
64
.link { border-bottom: 1.5px solid var(--medium-gray); }
65
66
pre {
67
  font-family: var(--mono-font);
68
  overflow-x: auto;
69
  tab-size: 4;
70
  -moz-tab-size: 4;
71
}
72
73
main, footer {
74
  padding: 0;
75
  line-height: 160%;
76
}
77
78
h2 { font-weight: 400; }
79
strong { font-weight: 500; }
80
81
main h1 { padding: 10px 0 10px 0; }
82
main h2 { font-size: 18px; }
83
main h3 { font-size: 1.15rem; }
84
main h2, h3 { padding: 20px 0 0.4rem 0; }
85
86
nav { padding: 0.4rem 0 1.5rem 0; }
87
nav ul {
88
  list-style: none;
89
  padding-bottom: 20px;
90
}
91
92
nav ul li {
93
  padding-right: 10px;
94
  display: inline-block;
95
}
96
97
/* utilities */
98
99
.nowrap { white-space: nowrap; }
100
.fill { width: 100%; }
101
.muted { color: var(--gray); }
102
103
.size { text-align: right; }
104
105
.mode,
106
.size,
107
.commit-hash,
108
.commit-email,
109
.diff-type {
110
  font-family: var(--mono-font);
111
}
112
113
/* tables */
114
.table {
115
  width: 100%;
116
  border-collapse: collapse;
117
  table-layout: auto;
118
}
119
120
.table th {
121
  text-align: left;
122
  font-weight: 500;
123
  border-bottom: 1.5px solid var(--medium-gray);
124
  padding: 0.25em 0.5em;
125
}
126
127
.table td {
128
  border-bottom: 1px solid var(--light-gray);
129
  padding: 0.25em 0.5em;
130
  vertical-align: top;
131
}
132
133
.table tbody tr:hover {
134
  background: var(--light);
135
}
136
137
.table tbody tr.nohover:hover {
138
  background: transparent;
139
}
140
141
/* tooltip */
142
.tooltip {
143
  display: none;
144
  position: absolute;
145
  left: 0;
146
  top: 100%;
147
  margin-top: 0.25rem;
148
  padding: 0.5rem 0.7rem;
149
  background: var(--white);
150
  border: 1px solid var(--medium-gray);
151
  border-radius: 4px;
152
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
153
  z-index: 10;
154
  font-size: 0.85em;
155
  line-height: 1.3;
156
  max-width: 48ch;
157
  white-space: nowrap;
158
}
159
160
.author, .age { position: relative; }
161
162
.author:hover .tooltip,
163
.author:focus-within .tooltip,
164
.age:hover .tooltip,
165
.age:focus-within .tooltip {
166
  display: block;
167
}
168
169
/* box */
170
.box {
171
  background: var(--light-gray);
172
  padding: 0.6rem;
173
}
174
175
.box + .box {
176
  margin-top: 0.8rem;
177
}
178
179
/* repo header */
180
.repo-header { margin-bottom: 1.25rem; }
181
182
.repo-breadcrumb,
183
.repo-breadcrumb a {
184
  color: var(--gray);
185
}
186
187
.repo-breadcrumb:before { content: "<"; }
188
189
.repo-name {
190
  font-size: 1.6rem;
191
  line-height: 1.1;
192
  margin-top: 0.25rem;
193
}
194
195
.repo-header .desc { margin-top: 0.35rem; }
196
.repo-header .repo-nav { padding: 0.5rem 0 0 0; }
197
.repo-header .repo-nav ul { padding-bottom: 0; }
198
199
/* index page */
200
.index { margin-top: 2em; }
201
202
/* repo index */
203
.repo-index {
204
  display: flex;
205
  gap: 1.25rem;
206
  align-items: flex-start;
207
}
208
209
.repo-index-main {
210
  flex: 0 0 72ch;
211
}
212
213
.repo-index-main .box {
214
  width: 100%;
215
}
216
217
.repo-index-side {
218
  flex: 0 0 26rem;
219
  min-width: 0;
220
}
221
222
.repo-index-side h2 {
223
  font-size: 1.4rem;
224
  padding: 0;
225
}
226
227
/* log page */
228
.log td.author .author-short {
229
  display: inline-block;
230
  max-width: 25ch;
231
  overflow: hidden;
232
  text-overflow: ellipsis;
233
  vertical-align: top;
234
}
235
236
/* tree */
237
.tree,
238
.log,
239
.repo-index {
240
  margin-bottom: 2em;
241
}
242
243
/* file View */
244
.file-wrapper {
245
  display: flex;
246
  flex-direction: row;
247
  gap: 1rem;
248
  padding: 0 0.5rem;
249
  background: var(--light-gray);
250
  overflow-x: auto;
251
}
252
253
.line-numbers {
254
  white-space: pre-line;
255
  -moz-user-select: -moz-none;
256
  -khtml-user-select: none;
257
  -webkit-user-select: none;
258
  -o-user-select: none;
259
  user-select: none;
260
  padding-right: 1ch;
261
}
262
263
.file-content {
264
  padding-left: 1.5ch;
265
  overflow-y: hidden;
266
  overflow-x: auto;
267
}
268
269
.line-numbers pre,
270
.file-content pre {
271
  margin: 0;
272
  line-height: 1.5;
273
}
274
275
/* commit */
276
.commit { margin-bottom: 1rem; }
277
278
.commit pre {
279
  padding-bottom: 0;
280
  white-space: pre-wrap;
281
}
282
283
.commit .box { margin-bottom: 0.25rem; }
284
.commit .commit-info {
285
  padding-bottom: 0.25rem;
286
}
287
288
.commit-message {
289
  margin-top: 0.25rem;
290
  font-size: 1rem;
291
  line-height: 1.35;
292
  margin-bottom: 1rem;
293
}
294
295
.commit-info {
296
  color: var(--gray);
297
  font-size: 0.85rem;
298
}
299
300
.commit-date { float: right; }
301
302
.commit-email:before { content: '<'; }
303
.commit-email:after { content: '>'; }
304
305
.commit-refs {
306
  margin: 0.5rem 0 1rem 0;
307
}
308
309
.commit-refs td {
310
  padding: 0.15rem 0.5rem 0.15rem 0;
311
  border: none;
312
}
313
314
.commit-refs td.label {
315
  padding-right: 1rem;
316
}
317
318
/* diff */
319
.diff {
320
  margin: 1rem 0 1rem 0;
321
  padding: 0.6rem;
322
  border-bottom: 1.5px solid var(--medium-gray);
323
  background: var(--light-gray);
324
}
325
326
.diff-stat { padding: 1rem 0 1rem 0; }
327
.diff-add { color: var(--diff-add); }
328
.diff-del { color: var(--diff-del); }
329
.diff-mod { color: var(--cyan); }
330
.diff-noop { color: var(--gray); }
331
332
.jump { margin-top: 0.5rem; }
333
.jump-table { margin-top: 0.25rem; }
334
335
.jump-table td {
336
  padding: 0.15rem 0.5rem;
337
  border-color: var(--medium-gray);
338
}
339
340
.jump-table .diff-type {
341
  width: 2ch;
342
}
343
344
/* refs */
345
.ref {
346
  font-size: 1rem;
347
  color: var(--gray);
348
  display: inline-block;
349
  padding-top: 0.7em;
350
}
351
352
.refs pre {
353
  padding-bottom: 0.5rem;
354
  white-space: pre-wrap;
355
}
356
357
.refs strong {
358
  padding-right: 1em;
359
}
360
361
/* readme */
362
.readme { padding: 0.6rem 0; }
363
.readme pre { white-space: pre-wrap; }
364
.readme ul  { padding: revert; }
365
.readme img { max-width: 100%; }
366
367
@media (max-width: 600px) {
368
  .repo-index {
369
    flex-direction: column;
370
  }
371
372
  .repo-index-main,
373
  .repo-index-side {
374
    flex: none;
375
    width: 100%;
376
  }
377
378
  .commit-info:not(:last-child) {
379
    padding-bottom: 1.5rem;
380
  }
381
382
  pre {
383
    font-size: 0.8rem;
384
  }
385
}