Refactor, create service-assets
This commit is contained in:
145
crates/service/service-webpage/css/blocks.scss
Normal file
145
crates/service/service-webpage/css/blocks.scss
Normal file
@@ -0,0 +1,145 @@
|
||||
ul {
|
||||
list-style: none;
|
||||
margin-top: 0.5rem;
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
li {
|
||||
margin-bottom: 0.25rem;
|
||||
}
|
||||
|
||||
li p {
|
||||
margin-bottom: 0.2rem;
|
||||
}
|
||||
|
||||
/* Bonus space after last li */
|
||||
//li:last-child {
|
||||
// margin-bottom: 3rem;
|
||||
//}
|
||||
|
||||
ul li::marker {
|
||||
content: "> ";
|
||||
color: var(--metaColor);
|
||||
}
|
||||
|
||||
ul li:hover::marker {
|
||||
content: ">> ";
|
||||
font-weight: 1000;
|
||||
color: var(--linkColor);
|
||||
transition: 100ms;
|
||||
}
|
||||
|
||||
|
||||
.titleList li {
|
||||
margin-bottom: .75rem;
|
||||
}
|
||||
|
||||
|
||||
blockquote {
|
||||
border-left: .5rem solid var(--metaColor);
|
||||
margin: 1rem;
|
||||
padding: 0 0 0 1rem
|
||||
}
|
||||
|
||||
|
||||
textarea {
|
||||
border: 2px dotted;
|
||||
outline: 0;
|
||||
resize: none;
|
||||
overflow: auto;
|
||||
background-color: var(--bgColor)
|
||||
}
|
||||
|
||||
|
||||
|
||||
pre .wrap {
|
||||
overflow: hidden;
|
||||
overflow-wrap: break-word;
|
||||
word-break: break-all;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
pre :not(.wrap) {
|
||||
padding: 1rem;
|
||||
font-style: monospace;
|
||||
white-space: pre;
|
||||
overflow: scroll;
|
||||
display: block;
|
||||
border: solid .2rem transparent;
|
||||
transition: 150ms;
|
||||
counter-reset: line;
|
||||
}
|
||||
|
||||
pre:hover {
|
||||
border: solid .2rem var(--lightBgColor);
|
||||
}
|
||||
|
||||
pre span:first-of-type:before {
|
||||
border-top: 1px dashed var(--lightBgColor);
|
||||
}
|
||||
|
||||
pre span:before {
|
||||
counter-increment: line;
|
||||
content: counter(line, decimal-leading-zero);
|
||||
display: inline-block;
|
||||
border-right: 1px solid var(--lightBgColor);
|
||||
border-bottom: 1px dashed var(--lightBgColor);
|
||||
padding: 0 .5em;
|
||||
margin-right: .5em;
|
||||
color: #888
|
||||
}
|
||||
|
||||
p code,
|
||||
li code,
|
||||
div code {
|
||||
padding: .2rem .4rem .2rem .4rem;
|
||||
font-size: 85%;
|
||||
border-radius: .3rem;
|
||||
color: var(--codeFgColor);
|
||||
background-color: var(--codeBgColor);
|
||||
}
|
||||
|
||||
pre code {
|
||||
padding: 0;
|
||||
border-radius: 0;
|
||||
color: inherit;
|
||||
background-color: inherit;
|
||||
}
|
||||
|
||||
|
||||
table {
|
||||
table-layout: fixed;
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
border: none;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
margin-bottom: 1rem;
|
||||
line-height: 1.1
|
||||
}
|
||||
|
||||
thead th:first-child {
|
||||
width: 20%
|
||||
}
|
||||
|
||||
td,
|
||||
th {
|
||||
text-align: left
|
||||
}
|
||||
|
||||
th {
|
||||
font-weight: 400
|
||||
}
|
||||
|
||||
|
||||
td,
|
||||
th {
|
||||
padding: .5rem;
|
||||
border: dashed .1rem var(--metaColor)
|
||||
}
|
||||
|
||||
.metaData,
|
||||
hr,
|
||||
textarea {
|
||||
color: var(--metaColor)
|
||||
}
|
||||
32
crates/service/service-webpage/css/images.scss
Normal file
32
crates/service/service-webpage/css/images.scss
Normal file
@@ -0,0 +1,32 @@
|
||||
img {
|
||||
max-width: 90%;
|
||||
height: auto;
|
||||
margin: .2rem;
|
||||
padding: .2rem;
|
||||
border-radius: 15px;
|
||||
border: solid .2rem transparent;
|
||||
transition: 150ms;
|
||||
image-rendering: pixelated;
|
||||
}
|
||||
|
||||
img:hover {
|
||||
border: solid .2rem var(--metaColor);
|
||||
transform: scale(1.02);
|
||||
}
|
||||
|
||||
|
||||
.icons {
|
||||
width: 2.0rem;
|
||||
height: 2.0rem;
|
||||
aspect-ratio: 1/1;
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
color: var(--fgColor);
|
||||
fill: var(--fgColor);
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.icons__background:hover {
|
||||
background-color: transparent;
|
||||
color: var(--metaColor);
|
||||
}
|
||||
119
crates/service/service-webpage/css/main.scss
Normal file
119
crates/service/service-webpage/css/main.scss
Normal file
@@ -0,0 +1,119 @@
|
||||
@import "text";
|
||||
@import "blocks";
|
||||
@import "images";
|
||||
@import "special";
|
||||
|
||||
:root {
|
||||
// Misc colors
|
||||
--bgColor: #121212;
|
||||
--lightBgColor: #3a3f46;
|
||||
--fgColor: #ebebeb;
|
||||
--metaColor: #6199bb;
|
||||
--lightMetaColor: #638c86;
|
||||
--linkColor: #e4dab3;
|
||||
--codeBgColor: #292929;
|
||||
--codeFgColor: var(--fgColor);
|
||||
|
||||
// Main colors
|
||||
--grey: #696969;
|
||||
|
||||
// Accent colors, used only manally
|
||||
--green: #a2c579;
|
||||
--magenta: #ad79c5;
|
||||
--orange: #e86a33;
|
||||
--yellow: #e8bc00;
|
||||
--pink: #fa9f83;
|
||||
}
|
||||
|
||||
::selection,
|
||||
::-moz-selection {
|
||||
color: var(--bgColor);
|
||||
background: var(--metaColor);
|
||||
}
|
||||
|
||||
html {
|
||||
-webkit-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
font-size: 62.5%;
|
||||
scrollbar-color: var(--metaColor) var(--bgColor);
|
||||
scrollbar-width: auto;
|
||||
background: var(--bgColor);
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: "Fira";
|
||||
font-size: 1.6rem;
|
||||
line-height: 1.35;
|
||||
max-width: 64rem;
|
||||
margin: auto;
|
||||
overflow-wrap: break-word;
|
||||
background: var(--bgColor);
|
||||
color: var(--fgColor);
|
||||
}
|
||||
|
||||
div.wrapper {
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
hr.footline {
|
||||
border: 1pt solid;
|
||||
}
|
||||
|
||||
hr {
|
||||
border: 1pt dashed;
|
||||
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
iframe {
|
||||
max-width: 90%;
|
||||
}
|
||||
|
||||
|
||||
.footContainer {
|
||||
padding-top: 0;
|
||||
padding-bottom: 1em;
|
||||
padding-left: 1em;
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
@media (max-width: 650px) {
|
||||
.wrapper {
|
||||
margin: 1rem;
|
||||
}
|
||||
}
|
||||
|
||||
// Loading spinner (three dots)
|
||||
.htmx-indicator {
|
||||
display: none;
|
||||
}
|
||||
.htmx-request .htmx-indicator,
|
||||
.htmx-request.htmx-indicator {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
padding: 8px 0;
|
||||
}
|
||||
|
||||
@keyframes dot-bounce {
|
||||
0%, 80%, 100% { opacity: 0.2; transform: scale(0.8); }
|
||||
40% { opacity: 1; transform: scale(1); }
|
||||
}
|
||||
|
||||
.search-meta {
|
||||
font-size: 1.2rem;
|
||||
color: var(--grey);
|
||||
margin: 0 0 1.5em 0;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#search-results {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
#search-results ul {
|
||||
margin-top: 1.5em;
|
||||
}
|
||||
88
crates/service/service-webpage/css/special.scss
Normal file
88
crates/service/service-webpage/css/special.scss
Normal file
@@ -0,0 +1,88 @@
|
||||
.handout-li-links {
|
||||
color: var(--grey);
|
||||
}
|
||||
|
||||
.handout-li-links a {
|
||||
@extend a;
|
||||
text-decoration: underline;
|
||||
text-underline-offset: 1.5pt;
|
||||
padding-left: 1ex;
|
||||
padding-right: 1ex;
|
||||
}
|
||||
|
||||
// Only do hover magic on mouse devices
|
||||
@media(hover: hover) and (pointer: fine) {
|
||||
.handout-ul li:hover {
|
||||
margin-left: 1ex;
|
||||
transition: 50ms;
|
||||
}
|
||||
|
||||
.handout-ul li {
|
||||
transition: 50ms;
|
||||
transition-delay: 50ms;
|
||||
}
|
||||
|
||||
.handout-ul li:hover .handout-li-links {
|
||||
display: inline-block;
|
||||
opacity: 1;
|
||||
transition: 100ms;
|
||||
}
|
||||
|
||||
.handout-ul li .handout-li-links {
|
||||
transition-delay: 50ms;
|
||||
transition: 100ms;
|
||||
opacity: 0;
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Email obfuscation
|
||||
// Works with "{{ email_*() }}" shortcodes.
|
||||
.eobf {
|
||||
@extend a;
|
||||
}
|
||||
|
||||
.eobf:hover {
|
||||
@extend a, :hover;
|
||||
}
|
||||
|
||||
// Change icon on hover
|
||||
.eobf #eobf-kb,
|
||||
.eobf:hover #eobf-en {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.eobf #eobf-en,
|
||||
.eobf:hover #eobf-kb {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
// Hover text
|
||||
.eobf:hover span:before {
|
||||
unicode-bidi: bidi-override;
|
||||
direction: ltr;
|
||||
content: attr(data-h);
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Text for email_beta
|
||||
.eobf-beta span:before {
|
||||
content: "mo" attr(data-a) "teb" "\0040" attr(data-b) "m";
|
||||
unicode-bidi: bidi-override;
|
||||
direction: rtl;
|
||||
}
|
||||
|
||||
// Text for email_goog
|
||||
.eobf-goog span:before {
|
||||
content: "mo" attr(data-a) "mg" "\0040" attr(data-b) "p." attr(data-c) "m";
|
||||
unicode-bidi: bidi-override;
|
||||
direction: rtl;
|
||||
}
|
||||
|
||||
// Text for email_this
|
||||
.eobf-this span:before {
|
||||
content: attr(data-a);
|
||||
}
|
||||
87
crates/service/service-webpage/css/text.scss
Normal file
87
crates/service/service-webpage/css/text.scss
Normal file
@@ -0,0 +1,87 @@
|
||||
h1 {
|
||||
font-size: 3.5rem;
|
||||
margin-top: 1ex;
|
||||
margin-bottom: 1ex;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 2.5rem;
|
||||
margin-top: 1ex;
|
||||
margin-bottom: 0.5ex;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-size: 2rem;
|
||||
}
|
||||
|
||||
h3::before {
|
||||
color: var(--lightMetaColor);
|
||||
content: '## '
|
||||
}
|
||||
|
||||
h1::before,
|
||||
h2::before,
|
||||
h4::before,
|
||||
h5::before,
|
||||
h6::before {
|
||||
color: var(--metaColor);
|
||||
content: '# '
|
||||
}
|
||||
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
border-radius: .3rem;
|
||||
padding: 0 .2ex 0 .2ex;
|
||||
color: var(--linkColor);
|
||||
transition: 150ms;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
background-color: var(--linkColor);
|
||||
color: var(--bgColor);
|
||||
transition: 150ms;
|
||||
}
|
||||
|
||||
footer {
|
||||
font-size: 1.4rem;
|
||||
clear: both;
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
footer {
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.footnote-item p {
|
||||
display: inline;
|
||||
padding: 0 0 0 1rem;
|
||||
}
|
||||
|
||||
hr.footnotes-sep {
|
||||
margin: 5rem 0 0 0;
|
||||
}
|
||||
|
||||
.footnote-ref > a {
|
||||
padding: 0 2pt 0.8rem 2pt !important;
|
||||
}
|
||||
|
||||
a.footnote-backref, .footnote-ref > a
|
||||
{
|
||||
color: var(--metaColor);
|
||||
padding: 0 2pt 0 2pt;
|
||||
}
|
||||
|
||||
a.footnote-backref:hover,
|
||||
.footnote-ref > a:hover
|
||||
{
|
||||
color: var(--bgColor);
|
||||
background-color: var(--metaColor);
|
||||
}
|
||||
|
||||
.footContainer {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
Reference in New Issue
Block a user