mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-04-27 21:10:29 -04:00
fix lighthouse suggestions: syntax color contrast & crossorigin preloads
This commit is contained in:
parent
fa018564e5
commit
0ee3efdbbe
@ -23,7 +23,6 @@ $link-underline-size: 2px;
|
|||||||
|
|
||||||
// Global Colors
|
// Global Colors
|
||||||
$color-background: #ffffff;
|
$color-background: #ffffff;
|
||||||
$color-gray-background: #fbfbfb;
|
|
||||||
$color-text: #202020;
|
$color-text: #202020;
|
||||||
$color-medium-dark: #494949;
|
$color-medium-dark: #494949;
|
||||||
$color-medium: #5e5e5e;
|
$color-medium: #5e5e5e;
|
||||||
@ -31,6 +30,7 @@ $color-medium-light: #757575;
|
|||||||
$color-light: #d2d2d2;
|
$color-light: #d2d2d2;
|
||||||
$color-kinda-light: #e3e3e3;
|
$color-kinda-light: #e3e3e3;
|
||||||
$color-super-light: #f4f4f4;
|
$color-super-light: #f4f4f4;
|
||||||
|
$color-super-duper-light: #fbfbfb;
|
||||||
$color-links: #0e6dc2;
|
$color-links: #0e6dc2;
|
||||||
|
|
||||||
// For nifty color swapping on svg logo hover in components/_header.scss
|
// For nifty color swapping on svg logo hover in components/_header.scss
|
||||||
|
@ -5,7 +5,7 @@ body {
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
background-color: $color-gray-background; // really just the color of header & footer
|
background-color: $color-super-duper-light; // really just the color of header & footer
|
||||||
color: $color-text;
|
color: $color-text;
|
||||||
font-family: $webfont-sans;
|
font-family: $webfont-sans;
|
||||||
font-kerning: normal;
|
font-kerning: normal;
|
||||||
@ -54,7 +54,7 @@ hr {
|
|||||||
// all code
|
// all code
|
||||||
code {
|
code {
|
||||||
font-family: $webfont-mono;
|
font-family: $webfont-mono;
|
||||||
background: $color-super-light;
|
background: $color-super-duper-light;
|
||||||
font-size: 0.95em;
|
font-size: 0.95em;
|
||||||
letter-spacing: 0;
|
letter-spacing: 0;
|
||||||
page-break-inside: avoid;
|
page-break-inside: avoid;
|
||||||
@ -66,7 +66,7 @@ code {
|
|||||||
|
|
||||||
// code fences
|
// code fences
|
||||||
div.highlight {
|
div.highlight {
|
||||||
background: $color-super-light;
|
background: $color-super-duper-light;
|
||||||
border: 1px solid $color-light;
|
border: 1px solid $color-light;
|
||||||
border-left: 3px solid $color-links;
|
border-left: 3px solid $color-links;
|
||||||
line-height: 1.6;
|
line-height: 1.6;
|
||||||
|
@ -9,7 +9,7 @@ div.highlight span {
|
|||||||
color: #111111;
|
color: #111111;
|
||||||
}
|
}
|
||||||
&.na, &.nc, &.nd, &.ne, &.nf, &.nx {
|
&.na, &.nc, &.nd, &.ne, &.nf, &.nx {
|
||||||
color: #489c44;
|
color: #068200;
|
||||||
}
|
}
|
||||||
&.err, &.nt, &.o, &.ow, &.kn {
|
&.err, &.nt, &.o, &.ow, &.kn {
|
||||||
color: #e8003d;
|
color: #e8003d;
|
||||||
@ -18,7 +18,7 @@ div.highlight span {
|
|||||||
color: #8145ec;
|
color: #8145ec;
|
||||||
}
|
}
|
||||||
&.ld, &.s, &.sa, &.sb, &.sc, &.dl, &.sd, &.s2, &.sh, &.si, &.sx, &.sr, &.s1, &.ss {
|
&.ld, &.s, &.sa, &.sb, &.sc, &.dl, &.sd, &.s2, &.sh, &.si, &.sx, &.sr, &.s1, &.ss {
|
||||||
color: #c17005;
|
color: #b35c00;
|
||||||
}
|
}
|
||||||
&.c, &.ch, &.cm, &.c1, &.cs, &.cp, &.cpf {
|
&.c, &.ch, &.cm, &.c1, &.cs, &.cp, &.cpf {
|
||||||
color: #6b6859;
|
color: #6b6859;
|
||||||
|
@ -1,10 +1,12 @@
|
|||||||
{{ if eq hugo.Environment "production" }}
|
{{ if eq hugo.Environment "production" }}
|
||||||
<link rel="preconnect" href="https://s.jarv.is">
|
<link rel="preconnect" href="https://s.jarv.is" crossorigin="anonymous">
|
||||||
{{ if and .IsPage (eq .Type "notes") }}
|
{{ if and .IsPage (eq .Type "notes") }}
|
||||||
<link rel="preconnect" href="https://utteranc.es">
|
<link rel="preconnect" href="https://utteranc.es" crossorigin="anonymous">
|
||||||
{{ end }}
|
<link rel="preconnect" href="https://api.utteranc.es" crossorigin="anonymous">
|
||||||
|
<link rel="preconnect" href="https://api.github.com" crossorigin="anonymous">
|
||||||
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<link rel="preload" href="{{ "fonts/inter-regular-subset.woff2" | absURL }}" as="font" type="font/woff2" crossorigin>
|
<link rel="preload" href="{{ "fonts/inter-regular-subset.woff2" | absURL }}" as="font" type="font/woff2" crossorigin="anonymous">
|
||||||
<link rel="preload" href="{{ "fonts/inter-medium-subset.woff2" | absURL }}" as="font" type="font/woff2" crossorigin>
|
<link rel="preload" href="{{ "fonts/inter-medium-subset.woff2" | absURL }}" as="font" type="font/woff2" crossorigin="anonymous">
|
||||||
<link rel="preload" href="{{ "fonts/inter-bold-subset.woff2" | absURL }}" as="font" type="font/woff2" crossorigin>
|
<link rel="preload" href="{{ "fonts/inter-bold-subset.woff2" | absURL }}" as="font" type="font/woff2" crossorigin="anonymous">
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
<script data-skip-dnt="true" async defer src="https://s.jarv.is/app.js"></script>
|
<script async defer src="https://s.jarv.is/app.js" data-skip-dnt="true"></script>
|
||||||
<noscript><img src="https://s.jarv.is/image.gif" alt=""></noscript>
|
<noscript><img src="https://s.jarv.is/image.gif" alt=""></noscript>
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
<script src="https://utteranc.es/client.js"
|
<script async defer
|
||||||
repo="{{ .Site.Params.utterancesRepo }}"
|
src="https://utteranc.es/client.js"
|
||||||
issue-term="og:title"
|
data-repo="{{ .Site.Params.utterancesRepo }}"
|
||||||
label="comments"
|
data-issue-term="og:title"
|
||||||
theme="github-light"
|
data-label="comments"
|
||||||
crossorigin="anonymous"
|
data-theme="github-light"
|
||||||
async defer>
|
crossorigin="anonymous"></script>
|
||||||
</script>
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user