From 968b1751fd5d45517c9296178a51ead1de250324 Mon Sep 17 00:00:00 2001 From: Eliseu Amaro Date: Wed, 12 Jan 2022 16:42:33 +0000 Subject: [PATCH] [CSS] Further styling optimizations, compacting common rules. Removed select dropdown images, since they are no longer required --- public/assets/default_theme/css/reset.css | 67 ++++++++++++++---- .../default_theme/css/widgets/sections.css | 38 +++++----- .../default_theme/images/select_drop_dark.png | Bin 552 -> 0 bytes .../images/select_drop_light.png | Bin 734 -> 0 bytes 4 files changed, 74 insertions(+), 31 deletions(-) delete mode 100644 public/assets/default_theme/images/select_drop_dark.png delete mode 100644 public/assets/default_theme/images/select_drop_light.png diff --git a/public/assets/default_theme/css/reset.css b/public/assets/default_theme/css/reset.css index 86257ad34a..b8a1eec377 100644 --- a/public/assets/default_theme/css/reset.css +++ b/public/assets/default_theme/css/reset.css @@ -2,38 +2,44 @@ box-sizing: border-box !important; max-width: 100%; } + body, html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; background-color: var(--background-hard); background-attachment: fixed; - font-family: 'Open Sans',sans-serif; + font-family: 'Open Sans', sans-serif; font-size: var(--unit); display: flex; flex-direction: column; } + body, input, select, textarea { color: var(--foreground); } + :link, :visited { text-decoration: none; color: currentColor; } + hr { all: unset; display: block; height: 1px; background-color: var(--border) !important; } + ol, ul { list-style: none; } + blockquote, body, fieldset, @@ -46,46 +52,59 @@ textarea { padding: 0; border: 0; } + fieldset { all: unset; } + :link img, :visited img, a img { border: 0; } + address { font-style: normal; } + :focus { outline: 0; } + ::-moz-focus-inner { border: 0; } + details summary { cursor: pointer !important; } + details summary > * { margin: unset; padding: unset; } + details > summary { list-style: none; } + details > summary::-webkit-details-marker { display: none; } + @supports not(-ms-ime-align:auto) { details summary { cursor: pointer; } } + [hidden] { display: none; } -html {font-size: 100%;} /*16px*/ +html { + font-size: 100%; +} body { font-family: 'Open Sans', sans-serif; @@ -95,17 +114,28 @@ body { p { all: unset; - font-family: 'Open Sans',sans-serif; + font-family: 'Open Sans', sans-serif; margin-bottom: 1rem; } -h1, h2, h3, h4, h5, legend { +h1, +h2, +h3, +h4, +h5, +legend { margin: 3rem 0 1.38rem; font-family: 'Poppins', sans-serif; font-weight: 600; line-height: 1.3; } -h1:first-child, h2:first-child, h3:first-child, h4:first-child, h5:first-child, legend:first-child { + +h1:first-child, +h2:first-child, +h3:first-child, +h4:first-child, +h5:first-child, +legend:first-child { margin-top: initial; } @@ -114,44 +144,57 @@ h1 { font-size: 1.383rem; } -h2 {font-size: 1.296rem;} +h2 { + font-size: 1.296rem; +} -h3 {font-size: 1.215rem;} +h3 { + font-size: 1.215rem; +} -h4 {font-size: 1.138rem;} +h4 { + font-size: 1.138rem; +} -h5 {font-size: 1.067rem;} +h5 { + font-size: 1.067rem; +} legend { font-size: 1.296em; } -small, .text_small { - font-family: 'Open Sans',sans-serif; +.text_small, +small { + font-family: 'Open Sans', sans-serif; font-size: 0.937rem; } input[type=password], input[type=text], textarea { - font-family: 'Open Sans',sans-serif; + font-family: 'Open Sans', sans-serif; font-weight: 400; padding: 4px 6px; } + ul { text-decoration: none; margin: 0; padding: 0; list-style: none; } + li { margin: 0; padding: 0; } + a:focus, a:hover { text-decoration: underline; } + *:focus-visible { box-shadow: var(--shadow-inset-accent); } \ No newline at end of file diff --git a/public/assets/default_theme/css/widgets/sections.css b/public/assets/default_theme/css/widgets/sections.css index 9a48b25168..2a9dd6ac74 100644 --- a/public/assets/default_theme/css/widgets/sections.css +++ b/public/assets/default_theme/css/widgets/sections.css @@ -42,18 +42,18 @@ opacity: 0.66; } -.profile-stats-subscriptions, -.profile-stats-subscribers { +.profile-stats-subscribers, +.profile-stats-subscriptions { display: block; } -.profile-stats-subscriptions strong, -.profile-stats-subscribers strong { +.profile-stats-subscribers strong, +.profile-stats-subscriptions strong { margin-right: 4px; } -.profile-info-url, -.profile-bio { +.profile-bio, +.profile-info-url { word-break: break-all; } @@ -62,8 +62,7 @@ } .profile-tags { - margin: unset; - margin-top: 4px; + margin: 4px unset unset; } .button-container { @@ -180,26 +179,27 @@ border: 2px solid var(--border); } -.section-widget-title-details summary, -.section-widget-subtitle-details summary { +.section-widget-subtitle-details summary, +.section-widget-title-details summary { display: inline-block; width: 100%; border-radius: var(--s); background: var(--gradient); } -.section-widget-title-details summary > *, -.section-widget-subtitle-details summary > * { + +.section-widget-subtitle-details summary > *, +.section-widget-title-details summary > * { display: inline-block; vertical-align: baseline; } -.section-widget-title-details summary > *:last-child, -.section-widget-subtitle-details summary > *:last-child { +.section-widget-subtitle-details summary > *:last-child, +.section-widget-title-details summary > *:last-child { margin-right: 4px; } -.section-widget-title-details summary:after, -.section-widget-subtitle-details summary:after { +.section-widget-subtitle-details summary:after, +.section-widget-title-details summary:after { content: "\2193"; float: right; } @@ -272,10 +272,10 @@ textarea.form-row-widget { resize: vertical; } -.form-row-widget-error, -.form-error, .alert, -.alert-danger { +.alert-danger, +.form-error, +.form-row-widget-error { display: inline-block; font-style: italic; border: solid 2px #ff6347; diff --git a/public/assets/default_theme/images/select_drop_dark.png b/public/assets/default_theme/images/select_drop_dark.png deleted file mode 100644 index 532b98136d0939958971ec6ed1b4685dba7fd511..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 552 zcmV+@0@wYCP)`&=}p87TM9C4DusmmS2$c*c^Xb2EDj{D9jtQRT!4)Mhp`vyZVn z3ZZh`Dw!ajb4S7Z!OXq~x7q}4w`FY|_yW8MvZ|ds10MX}fKA{sJ>)-(k)|$OO4<*S zMYfRuleBMU7fg8i>6Ma6sw6#@bSlXuHR_HgYEFZrN}cU!U#jE06Qoyj7$~_rnQLw& z6UTFyC^^SViRWT>--@<&HQ?^PwX}g&7Y;gfp~MbWA|51_u7~oqq@ivGtc^0LLwA1_ zHS=!WsU}Jn_Cjnl!9ZEt%QdSqV3KM{19v|Op}Z{{UBCDfNrT8;^e23(iPDAb3A0eH zw{z~wkxU#W;Ua$6t9X!CacsEzS+u^1>x~lc%|MtaUD!>pU^mBlM>26F>1Y}8g(fvk qcoA*jKmYUD3*!5*+Wr23dxyVTmcg~B^yk(90000==3iD diff --git a/public/assets/default_theme/images/select_drop_light.png b/public/assets/default_theme/images/select_drop_light.png deleted file mode 100644 index 78153f3e14b7e9fcbf9bc9d7c2e7c48952b45740..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 734 zcmV<40wMj0P)ve#XQ-zhqdJ&1xuFM@&~nAqZOySq&?uZK=*T(i5`MWJ9H2${^h^SpoNnasdB{&z^j z@kMsCpi}R&heesi-EOxXMNz9LiVI;FM$WlVRRdKuQ4|S4mSrj;PDBc0OrGa?76id0 z%d+ucFc<+xO#?81>-Bm!!!Udf^nea<0f>M=MCJyqstOc9226kr0X(YrtVSRJE%k zRZc2%sH$5&!&SDCiioJ{7AHCg>Ud@eO8gUAYu^CZSfUD*>^~$)atp}4^FIQZMW~+O z*g3bkLKRd*#5uPK98)8{5{v!=0Z{b&{g=j=yQ*4dGL>wyM5MlH`te>}aranu@R_%2f5yRNraak7YIEGtp!Ts!oE@X!J3T9^A~eM$r2Rk7?%#{hIXoqns;+5;~7{_o@Q`1)`-O#OG`ExXhK