From 1965895da8b5e90647fc5419b32f53ba63ceefa7 Mon Sep 17 00:00:00 2001 From: Ed Ward Date: Tue, 31 Aug 2021 21:39:51 +0200 Subject: [PATCH] CSS: Clearer difference between menus and buttons, more elegant code --- source/css/common.css | 39 +++++++++++---------------- source/css/screen.css | 12 --------- source/images/checkbox-checked.png | Bin 227 -> 0 bytes source/images/checkbox-unchecked.png | Bin 155 -> 0 bytes 4 files changed, 15 insertions(+), 36 deletions(-) delete mode 100644 source/images/checkbox-checked.png delete mode 100644 source/images/checkbox-unchecked.png diff --git a/source/css/common.css b/source/css/common.css index 0de80fc..32495d7 100644 --- a/source/css/common.css +++ b/source/css/common.css @@ -1,5 +1,4 @@ - body { line-height: normal; } @@ -9,14 +8,14 @@ kbd { min-width: 1em; padding: .2em .3em; font: normal .8em/1 sans-serif; - text-align: center; text-decoration: none; border-radius: .3em; - background: rgb(250, 250, 250); + background: rgb(210, 210, 210); background: linear-gradient(to top, rgb(210, 210, 210), rgb(255, 255, 255)); color: rgb(50, 50, 50); white-space: nowrap; - text-transform: capitalize; + text-shadow: 0 0 2px rgb(255, 255, 255); + box-shadow: inset 0 0 1px rgb(255, 255, 255), inset 0 0 .4em rgb(200, 200, 200), 0 .1em 0 rgb(130, 130, 130), 0 .11em 0 rgba(0, 0, 0, .4), 0 .1em .11em rgba(0, 0, 0, .9); } kbd.def { @@ -34,7 +33,7 @@ kbd.osc { kbd.input { background: none; - border-radius: 0; + border-radius: unset; } kbd.cmd { @@ -44,45 +43,37 @@ kbd.cmd { text-transform: none; background: rgb(220, 220, 220); text-align: left; + color: #999999; + text-shadow: none; + box-shadow: none; } kbd.cmd.lin:before { content: 'user@linux:~ '; - color: #999999; } kbd.cmd.mac:before { content: 'MacBook:~/Desktop User\$ '; - color: #999999; } kbd.cmd.win:before { content: 'C:\\Users\\myAccount> '; - color: #999999; } -kbd.optoff, -kbd.option { - border: none; - background: none; - margin: 0 1em 0 0; - vertical-align: middle; +kbd.menu, +kbd.option, +kbd.optoff { + border-radius: unset; + background: rgb(240, 240, 240); + box-shadow: inset 0 0 1px rgb(255, 255, 255), inset 0 0 .4em rgb(200, 200, 200), 0 .1em 0 rgb(130, 130, 130), 0 .11em 0 rgba(0, 0, 0, .4); } kbd.optoff:before { - content: url('../images/checkbox-unchecked.png'); + content: '\2610\00a0'; } kbd.option:before { - content: url('../images/checkbox-checked.png'); -} - -kbd.menu { - border: none; - background: none; - font-weight: bold; - font-stretch: extra-condensed; - white-space: normal; + content: '\2611\00a0'; } kbd.osc { diff --git a/source/css/screen.css b/source/css/screen.css index acc41d0..c6cff7e 100644 --- a/source/css/screen.css +++ b/source/css/screen.css @@ -173,7 +173,6 @@ body { font-size: .9em; line-height: .9em; } -} #content figcaption.center { text-align: center; @@ -213,17 +212,6 @@ body { width: 100%; } -kbd { - text-shadow: 0 0 2px rgb(255, 255, 255); - box-shadow: inset 0 0 1px rgb(255, 255, 255), inset 0 0 .4em rgb(200, 200, 200), 0 .1em 0 rgb(130, 130, 130), 0 .11em 0 rgba(0, 0, 0, .4), 0 .1em .11em rgba(0, 0, 0, .9); -} - - -kbd.cmd { - text-shadow: none; - box-shadow: none; -} - #content p.center { text-align:center; } diff --git a/source/images/checkbox-checked.png b/source/images/checkbox-checked.png deleted file mode 100644 index d0b769004b18bad941b69e2b314e309097a1b10d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 227 zcmeAS@N?(olHy`uVBq!ia0vp^{2!lvI6;x#X;^) z4C~IxyaaL#0(?STB_$)M#(iZ!^IjTc@p!u1lY3Wm|G4CFem0P%skVQB7UZf;Y}%D V^Ua<$tAK_xc)I$ztaD0e0su`9NGAXQ diff --git a/source/images/checkbox-unchecked.png b/source/images/checkbox-unchecked.png deleted file mode 100644 index d28b0579eae1c3406b97976a927e1f401af76225..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 155 zcmeAS@N?(olHy`uVBq!ia0vp^{2!lvI6;x#X;^) z4C~IxyaaND0(?STB_$T?o{|;OXk;vd$@?2>=csCA