-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.user.css
355 lines (293 loc) · 12.2 KB
/
main.user.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
/* ==UserStyle==
@name Kowbell's Swarm Dark (LOCAL) TODO RENAME
@description Dark theme for P4 Swarm
@version 0.2.0
@license MIT-0
@namespace https://github.com/Kowbell/
@author DJ Schilens foo@bar.com (foobar.com)
@homepageURL https://github.com/Kowbell/Userstyle-SwarmDark
@supportURL https://github.com/Kowbell/Userstyle-SwarmDark/issues
@updateURL https://raw.githubusercontent.com/Kowbell/Userstyle-SwarmDark/master/main.user.css
@preprocessor stylus
@var color bkgCol "Default Background Color" #1e1e1e
@var color txtCol "Default Text Color" #bababa
@var color bkgColHdr "Headers Background Color" #181818
@var color txtColHdr "Headers Text Color" #bababa
@var color bkgColInt "Interactives Background Color (buttons, dropdowns, ...)" #2e2e2e
@var color txtColInt "Interactives Text Color (buttons, dropdowns, ...)" #cacaca
@var color bkgColIntHov "Interactives Background Color - Hovered" #5e5e5e
@var color txtColIntHov "Interactives Text Color - Hovered" #efefef
@var color bkgColIntAct "Interactives Background Color - Active" #63a70a
@var color txtColIntAct "Interactives Text Color - Active" #efefef
@var color bkgColAlt "Alternating Background Color (e.g. for every other item in a sequence)" #2e2e2e
@var color txtColAlt "Alternating Text Color (e.g. for every other item in a sequence)" #cacaca
@var color bkgColHiC "High-Contrast Background Color (editable text areas)" #101010
@var color txtColHiC "High-Contrast Text Color (editable text areas)" #f0f0f0
@var color bkgColCode "Default Code Background" #151515
@var color txtColCode "Default Code Color" #c0c0c0
@var color bkgColCodeAdd "Reviews: Added Code Background" #4b5632
@var color txtColCodeAdd "Reviews: Added Code Color" #c0c0c0
@var color bkgColCodeRmv "Reviews: Removed Code Background" #6f1313
@var color txtColCodeRmv "Reviews: Removed Code Color" #c0c0c0
@var color diffAdd-BkgCol "Diff View: Add: Background" #4b5632
@var color diffAddLeft-BkgCol "Diff View: Add: Background (left side)" #373d29
@var color diffDel-BkgCol "Diff View: Deleted: Background" #6f1313
@var color diffDelLeft-BkgCol "Diff View: Deleted: Background (left side)" #4b1818
==/UserStyle== */
/** * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Color scheme based on VS Code's default Dark+ theme
*
* Adapted from arvatarox's "Swarm Dark" (https://userstyles.org/styles/166448/swarm-dark)
* For editing tips see https://github.com/openstyles/stylus/wiki/UserCSS-authors
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
@-moz-document regexp(".*swarm\\..*\\.com.*") { /* apply to all swarm.whatever.com pages */
/* #region generic ================================================================================ #region generic */
body {
background-color: bkgCol;
color: txtCol;
}
.login-panel {
background-color: #222C;
}
/**
* Most icons are dark gray, so they're hard to see on the dark background.
* This doesn't work in IE or Opera, but should work in FF/Chrome/Safari.
*
* .swarm-icon covers MOST icons, though not all, hence the extra .icon classes here
*/
i {
-webkit-filter: invert(1);
filter: invert(1);
} /* invert all icons */
/** Colored icons, like the upvote/downvotes & flagged-as-task icons, should NOT be inverted! */
.icon-task-open, .icon-task-addressed, .icon-task-verified,
.icon-file-add, .icon-file-edit, .icon-file-delete,
.icon-post-review, .icon-pre-review, .icon-comment-unread,
.icon-vote-up, .icon-vote-down, .icon-required-reviewer,
.icon-vote-up-stale, icon-vote-down-stale,
.icon-white
{
-webkit-filter: invert(0);
filter: invert(0);
} /* dont invert colored icons */
.btn, .input-prepend .add-on {
background-color: bkgColInt;
color: txtColInt;
text-shadow: #222 0px 1px 1px;
}
.btn.active, .btn:active {
background-color: bkgColIntAct;
color: txtColIntAct;
box-shadow: inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(bkgColIntAct, 0.6) !important;
}
.btn:hover, .btn:focus {
background-color: bkgColIntHov;
color: txtColIntHov;
box-shadow: inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(bkgColIntAct, 0.6) !important;
}
.btn-group.open .btn.dropdown-toggle {
background-color: bkgColIntAct !important;
box-shadow: inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(bkgColIntAct, 0.6) !important;
}
.dropdown-menu,
.dropdown-menu > li > a {
background-color: bkgcolInt;
color: txtcolInt;
}
/** Hovered/selected dropdown items should use the 'interactive highlight' col */
.dropdown-menu > li > a:focus, .dropdown-menu > li > a:hover {
background-color: bkgColIntAct !important;
}
/** Interactive text fields (comment entries, search boxes) */
textarea, input[type="text"] {
background-color: bkgColHiC;
color: txtColHiC;
}
/** The glow around selected text inputs */
textarea:focus, input:focus {
border-color: bkgColIntAct !important;
box-shadow: inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(bkgColIntAct, 0.6) !important;
}
/** Also set the nav bar stripe color */
.navbar-inverse .navbar-inner, .navbar-inverse .navbar-inner, .navbar-site .nav .active > a {
border-bottom: solid 4px bkgColIntAct;
}
/* #endregion generic ========================================================================== #endregion generic */
/* #region dashboard ============================================================================ #region dashboard */
/* Alternating colors for the list of reviews in the dashboard */
.table-striped tbody > tr:nth-child(2n+1) > td, .table-striped tbody > tr:nth-child(2n+1) > th {
background-color: bkgColAlt;
}
/** Table header colors need to be specifically overridden */
th, .table th {
color: txtColHdr;
}
/** "There are no reviews currently visible" */
.dashboard .table-striped tr.empty td {
background-color: bkgColAlt;
}
/** "My Projects" widget on the left */
.projects-sidebar tbody {
background-color: bkgColAlt;
color: txtColAlt;
}
/* #endregion dashboard ====================================================================== #endregion dashboard */
/* #region reviews ================================================================================ #region reviews */
/** Header/footer for the review summary box at the top of the page
* e.g. "Review requested x minutes ago, last updated x minutes ago */
.popover.change-info .popover-title, .popover.change-info .popover-footer {
background-color: bkgColHdr;
color: txtColHdr;
}
/** Nested review comments should have alternating colors */
.comments-container .comment-replies .comment-replies-wrapper.odd {
background-color: bkgColAlt;
}
.comments-container .comment-replies .comment-replies-wrapper.even {
background-color: bkgCol;
}
/** Selected Files/Comments/History tab */
.nav-tabs > .active > a,
.nav-tabs > .active > a:hover,
.nav-tabs > .active > a:focus,
.nav-tabs > a, .nav-tabs > a:hover,
.nav-tabs > a:focus {
background-color: inherit;
color: inherit;
border-bottom: 1px bkgCol solid; /* hack; disable this to see why */
}
/** Commit popup (TODO COULDNT TEST THIS WHEN I WAS TIDYING UP) */
.modal {
background-color: #444;
}
.modal-footer {
background-color: #333;
}
/* .textarea, .input {
background-color: bkgCol !important;
color: #CCC;
} */
/* #region reviews: files tab ======================================== #region reviews: files tab */
/** The header for the file-preview-dropdown area
* This will say something like "Change 12345 shelved into mystream/" */
.review-wrapper .version-summary,
.file-metrics b /* those numbers by the edit/add/remove icons on the right */
{
background-color: bkgColHdr;
color: txtColHdr;
}
/** The header/footer "frames" around open files */
.diff-body .context-controls .context-icon-container, /* buttons for e.g. show-one-more-line-above */
.diff-body tr.diff-type-meta, /* filler space between the buttons */
.diff-footer
{
background-color: bkgColHdr;
}
/** Per-file seperator lines in the changelist view */
.diff-wrapper .diff-header, .diff-wrapper .filename,
.diff-wrapper .diff-header-affix > .swarm-icon,
.diff-wrapper .btn-file-read.active
{
border-top-color: #444;
}
/* #endregion reviews: files tab ================================== #endregion reviews: files tab */
/* #region reviews: comments tab ================================= #region reviews: comments tab */
/** inlined code in review comments,
* e.g. "this is my comment text `code code code` blah" */
code {
border: 1px solid #666;
background-color: bkgColCode;
color: txtColCode;
padding: 1px 4px;
font-size: 11px; /* there's some padding, so shrink the text */
}
pre { /* I've only seen <pre> used for multiline code blocks */
background-color: bkgColCode;
color: txtColCode;
}
/** Comments marked read */
.comments-container .comments-table tr.read:not(.closed) td.comment-summary {
background-color: inherit;
}
/** archived comments header/button */
.comments-container .closed-comments-header {
background-color: bkgColHdr;
color: txtColHdr;
}
/** Comments Entry */
.comments-container .comment-form .textarea-wrapper,
.comments-container .comment-form textarea {
background-color: bkgColHiC;
color: txtColHiC;
}
/** Previews of the code around inline comments */
.content-line-value,
.comments-container .content-context .content-line-value {
background-color: bkgColCode;
color: txtColCode;
}
.content-line-add {
background-color: bkgColCodeAdd!important;
color: txtColCodeAdd !important;
}
.content-line-delete {
background-color: bkgColCodeRmv !important;
color: txtColCodeRmv !important;
}
/* #endregion reviews: comments tab =========================== #endregion reviews: comments tab */
/** Diff View content */ /** Diff View content */
.diff-body.diff-sideways .diff-table { /** Code lines */
background-color: bkgCol;
color: txtColCode;
}
.diff-body .line-num { /** Line numbers */
background-color: bkgCol;
}
.table .table { /** inline review comments */
background-color: bkgCol;
}
/** Diff View content */ /** Diff View content */
/** Highlight lines when you mouse over them */ /** Mouse-Over Highlights */
.diff-body table tr.diff.diff-content:hover td { /** Code lines */
background-color: #111 !important; /** MUST BE !important */
}
.diff-body table tr.diff.diff-content:hover td.line-num { /** Line numbers */
color: #DDD;
}
/** Highlight lines when you mouse over them */ /** Mouse-Over Highlights */
/** COLORED LINES FOR ADD/DELETE */
/** TODO THESE COLORS SUCK */
.diff-body .diff-type-delete .line-value {
background-color: diffDelLeft-BkgCol;
}
.diff-body .diff-type-delete.diff-type-edit .line-value,
.diff-body.right-side .diff-type-delete .line-value {
background-color: diffDel-BkgCol;
}
/** Lines marked as add */
.diff-body .diff-type-add .line-value {
background-color: diffAdd-BkgCol;
}
/** Lines marked as add - left side (lighter) */
.diff-body .diff-type-add.diff-type-edit .line-value,
.diff-body.left-side .diff-type-add .line-value {
background-color: diffAddLeft-BkgCol;
}
/** This is the additional highlighting for text in modified lines */
/** TODO there's some potential for some nice styling here, check this out! */
.diff-body.diff-sideways tr.diff-type-edit .line-value span.delete,
.diff-body.diff-sideways tr.diff-type-edit .line-value span.insert,
.diff-body.diff-sideways tr.diff-type-edit.line-end-changed .line-value::after {
background-color: inherit;
}
/** COLORED LINES FOR ADD/DELETE */
/* #endregion reviews ========================================================================== #endregion reviews */
/** TODO DOCUMENT, I think this is showing code in comments */
/* .content-context {
color: #f0f;
} */
/** TODO DOCUMENT, this came with the style */
.diff-scroll {
color: #f0f;
}
} /* @-moz-document domain("swarm.*.com") */