Skip to content

Commit 3155213

Browse files
committed
πŸ§‘β€πŸ’» Modernize CSS
1 parent b347263 commit 3155213

File tree

2 files changed

+256
-237
lines changed

2 files changed

+256
-237
lines changed

β€Žabm/css/abmview.cssβ€Ž

Lines changed: 118 additions & 106 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ body.vscode-dark, body.vscode-high-contrast {
2424
--abm-text-color-data: #FFE;
2525
--abm-text-color-pale: #8A8;
2626
--abm-text-color-good: #6E6;
27-
--abm-text-color-limbo: #DB6;
27+
--abm-text-color-limbo: #68E;
2828
--abm-text-color-limbo-maple: #D6B;
2929
--abm-text-color-busy: #FA0;
3030
--abm-text-color-error: #C44;
@@ -47,7 +47,7 @@ body.vscode-light, body.vscode-high-contrast-light {
4747
--abm-text-color-data: #365;
4848
--abm-text-color-pale: #45F;
4949
--abm-text-color-good: #00D000;
50-
--abm-text-color-limbo: #A80;
50+
--abm-text-color-limbo: #46C;
5151
--abm-text-color-limbo-maple: #A08;
5252
--abm-text-color-busy: #A05900;
5353
--abm-text-color-error: #C00;
@@ -184,28 +184,29 @@ pre {
184184
text-align: center;
185185
background: var(--abm-toolbar-bg);
186186
color: var(--abm-text-color-vers);
187+
span { position: relative; top: -0.6em; }
187188
}
188-
#abm-footer span { position: relative; top: -0.6em; }
189189

190+
/* Info Table Styles */
190191
table#info {
191192
font-size: 14pt;
192193
margin-bottom: 0.5em;
194+
&>tbody>tr>th,
195+
&>tbody>tr>td { padding: 4px; vertical-align: top; }
196+
&>tbody>tr>th {
197+
text-align: right;
198+
white-space: nowrap;
199+
color: var(--abm-text-color-label);
200+
}
201+
div>span { color: var(--abm-text-color-pale); }
193202
}
194-
table#info>tbody>tr>th,
195-
table#info>tbody>tr>td { padding: 4px; vertical-align: top; }
196-
table#info>tbody>tr>th {
197-
text-align: right;
198-
white-space: nowrap;
199-
color: var(--abm-text-color-label);
200-
}
201-
202-
#info div>span { color: var(--abm-text-color-pale); }
203-
204203

205204
/* Button Styles */
206205

207-
button { cursor: pointer; outline: none; }
208-
button img { vertical-align: text-bottom; }
206+
button {
207+
cursor: pointer; outline: none;
208+
img { vertical-align: text-bottom; }
209+
}
209210

210211
#abm-toolbar button, #abm-social a {
211212
display: inline-block;
@@ -217,22 +218,23 @@ button img { vertical-align: text-bottom; }
217218
border: none;
218219
opacity: 0.7;
219220
}
220-
#abm-toolbar button img, #abm-social a>img { padding: 0.25em 0; }
221-
#abm-toolbar button span { display: block; padding-bottom: 0.25em; }
222-
#abm-toolbar button:active,
223-
#abm-toolbar button.active:hover,
224-
#abm-toolbar button.active {
225-
background: var(--abm-tool-bg-active);
226-
opacity: 1.0;
221+
#abm-toolbar {
222+
button img { padding: 0.25em 0; }
223+
button span { display: block; padding-bottom: 0.25em; }
224+
button:active,
225+
button.active:hover,
226+
button.active { background: var(--abm-tool-bg-active); opacity: 1.0; }
227+
button:hover { background: var(--abm-tool-bg-hover); }
228+
229+
/* Blend Modes for middle-gray SVG */
230+
button * { color: #808080; mix-blend-mode: color-dodge; }
231+
button:hover * { mix-blend-mode: difference; }
232+
button:active *,
233+
button.active:hover *,
234+
button.active * { mix-blend-mode: color-dodge; }
227235
}
228-
#abm-toolbar button:hover { background: var(--abm-tool-bg-hover); }
229236

230-
/* Blend Modes for middle-gray SVG */
231-
#abm-toolbar button * { color: #808080; mix-blend-mode: color-dodge; }
232-
#abm-toolbar button:hover * { mix-blend-mode: difference; }
233-
#abm-toolbar button:active *,
234-
#abm-toolbar button.active:hover *,
235-
#abm-toolbar button.active * { mix-blend-mode: color-dodge; }
237+
#abm-social a>img { padding: 0.25em 0; }
236238

237239
#info button>img, #abm-top button>img {
238240
width: 1.1em;
@@ -241,10 +243,13 @@ button img { vertical-align: text-bottom; }
241243
font-size: 90%;
242244
}
243245

244-
#abm-social { padding-top: var(--abm-header-height); margin-top: 2em; }
245-
#abm-social a { display: block; width: 70%; padding: 0 15%; margin: 0 auto 0.5em; }
246-
#abm-social a>span { display: none; }
247-
#abm-social a:hover { background: var(--abm-tool-bg-hover); opacity: 1; }
246+
#abm-social {
247+
padding-top: var(--abm-header-height);
248+
margin-top: 2em;
249+
a { display: block; width: 70%; padding: 0 15%; margin: 0 auto 0.5em; }
250+
a>span { display: none; }
251+
a:hover { background: var(--abm-tool-bg-hover); opacity: 1; }
252+
}
248253

249254
.abm-tool button {
250255
background: rgba(1, 107, 120, 0.5);
@@ -276,22 +281,20 @@ pre.config {
276281
margin: 0;
277282
}
278283

279-
#info-pins a {
280-
display: block;
281-
width: 100%;
284+
#info-pins {
285+
a { display: block; width: 100%; }
286+
a+a { font-size: 66.66%; }
282287
}
283-
#info-pins a+a { font-size: 66.66%; }
284-
285288
/* Environment Caption cell */
286289
.env-more {
287290
display: none;
288291
position: relative;
289292
top: -12px;
290-
}
291-
.env-more span {
292-
height: 0;
293-
margin-left: 1em;
294-
vertical-align: middle;
293+
span {
294+
height: 0;
295+
margin-left: 1em;
296+
vertical-align: middle;
297+
}
295298
}
296299
/* Show the caption for exists or busy */
297300
.exists .env-more,
@@ -306,57 +309,59 @@ pre.config {
306309

307310
/* Environments Sub-Table */
308311
table#info>tbody>tr>td#info-envs { padding: 0; } /* Envs Cell */
309-
#info-envs table td+td { padding-left: 1em; } /* Buttons Cell */
310-
#info-envs table td { padding-bottom: 8px; vertical-align: top; }
312+
#info-envs {
313+
table td+td { padding-left: 1em; } /* Buttons Cell */
314+
table td { padding-bottom: 8px; vertical-align: top; }
311315

312-
/* Environment Name Colors */
313-
#info-envs .env-name { color: var(--abm-text-color-limbo); }
314-
#info-envs .maple .env-name { color: var(--abm-text-color-limbo-maple); }
315-
#info-envs .exists .env-name { color: var(--abm-text-color-good); }
316+
/* Environment Name Colors */
317+
.env-name { color: var(--abm-text-color-limbo); }
318+
.maple .env-name { color: var(--abm-text-color-limbo-maple); }
319+
.exists .env-name { color: var(--abm-text-color-good); }
316320

317-
#info-envs .busy .env-name,
318-
#info-envs .busy.exists .env-name { color: var(--abm-text-color-busy); }
321+
.busy .env-name,
322+
.busy.exists .env-name { color: var(--abm-text-color-busy); }
319323

320-
#info-envs .exists.incomplete .env-name { color: var(--abm-text-color-error); }
324+
.exists.incomplete .env-name { color: var(--abm-text-color-error); }
321325

322-
/* Environment Action Buttons */
326+
/* Environment Action Buttons */
323327

324-
/* Show CLEAN for existing build */
325-
#info-envs button.clean { display: none; }
326-
#info-envs .exists button.clean { display: inline-block; }
327-
#info-envs .exists button.clean.opt { display: none; }
328+
/* Show CLEAN for existing build */
329+
button.clean { display: none; }
330+
.exists button.clean { display: inline-block; }
331+
.exists button.clean.opt { display: none; }
328332

329-
/* More specific selector for alternate function */
330-
#info-envs button.clean.purge,
331-
#info-envs .exists button.clean.purge { display: none; }
332-
#info-envs .exists button.clean.purge.opt { display: inline-block; }
333+
/* More specific selector for alternate function */
334+
button.clean.purge,
335+
.exists button.clean.purge { display: none; }
336+
.exists button.clean.purge.opt { display: inline-block; }
333337

334-
/* Only show 'Upload' or 'Debug' depending on the env */
338+
/* Only show 'Upload' or 'Debug' depending on the env */
335339
button.debug { display: none; }
336-
#info-envs .debug button.debug { display: inline-block; }
337-
338-
/* No upload button for debug or native */
339-
#info-envs .debug button.upload,
340-
#info-envs .native button.debug,
341-
#info-envs .native button.upload { display: none; }
342-
343-
/* Only show the "Run" button for a Native target */
344-
#info-envs button.run,
345-
#info-envs .exists.native.incomplete button.run { display: none; }
346-
#info-envs .exists.native button.run { display: inline-block; }
347-
348-
/* Hide ALL buttons when busy */
349-
#info-envs .busy button,
350-
#info-envs .debug.busy button,
351-
#info-envs .busy.exists button,
352-
#info-envs .debug.busy.exists button,
353-
#info-envs .busy.exists button.clean,
354-
#info-envs .busy.exists button.debug,
355-
#info-envs .busy.exists button.run { display: none; }
356-
357-
/* Show busy indicator when busy */
358-
#info-envs span.progress { display: none; }
359-
#info-envs .busy span.progress { display: inline-block; }
340+
.debug button.debug { display: inline-block; }
341+
342+
/* No upload button for debug or native */
343+
.debug button.upload,
344+
.native button.debug,
345+
.native button.upload { display: none; }
346+
347+
/* Only show the "Run" button for a Native target */
348+
button.run,
349+
.exists.native.incomplete button.run { display: none; }
350+
.exists.native button.run { display: inline-block; }
351+
352+
/* Hide ALL buttons when busy */
353+
.busy button,
354+
.debug.busy button,
355+
.busy.exists button,
356+
.debug.busy.exists button,
357+
.busy.exists button.clean,
358+
.busy.exists button.debug,
359+
.busy.exists button.run { display: none; }
360+
361+
/* Show busy indicator when busy */
362+
span.progress { display: none; }
363+
.busy span.progress { display: inline-block; }
364+
}
360365

361366
/* Hide buttons template and debug text field */
362367
#env-rows-src,
@@ -392,31 +397,38 @@ span.progress {
392397
background-repeat: repeat-x;
393398
}
394399

395-
div.subpanes { margin-top: 0; }
396-
397-
.subpanes>div {
398-
display: none;
399-
width: 100%;
400-
min-height: 400px;
401-
border: 1px solid var(--abm-color-border);
402-
background: #FFF3;
400+
div.subpanes {
401+
margin-top: 0;
402+
&>div {
403+
display: none;
404+
width: 100%;
405+
min-height: 400px;
406+
border: 1px solid var(--abm-color-border);
407+
background: #FFF3;
408+
}
403409
}
404410

405-
div.subtabs { margin-bottom: 0; }
406-
div.subtabs button {
407-
border-radius: 0.25em 0.25em 0 0;
408-
margin: 0 2px 0 0;
409-
color: #EEE;
410-
}
411-
div.subtabs button.active {
412-
background: #3BB175;
413-
color: #FFF;
411+
div.subtabs {
412+
margin-bottom: 0;
413+
button {
414+
border-radius: 0.25em 0.25em 0 0;
415+
margin: 0 2px 0 0;
416+
color: #EEE;
417+
}
418+
button.active {
419+
background: #3BB175;
420+
color: #FFF;
421+
}
414422
}
415423

416424
a.reveal { font-size: small; color: var(--abm-text-color-link); }
417425

418426
div#usb-note { padding: 1em 0; font-size: small; color: var(--abm-text-color-hey); }
419427

420-
form#showy { position: fixed; right: calc(var(--abm-social-width) + 20px); }
421-
form#showy label { display: block; padding: 2px 0; }
422-
form#showy input[type="checkbox"] { position: relative; top: 0.2em; }
428+
form#showy {
429+
position: fixed;
430+
right: calc(var(--abm-social-width) + 20px);
431+
432+
label { display: block; padding: 2px 0; }
433+
input[type="checkbox"] { position: relative; top: 0.2em; }
434+
}

0 commit comments

Comments
Β (0)