fix invalid html issues

add doctype. remove duplicate main tag from page-builder. change spans to divs where there are p children
This commit is contained in:
sorrel 2024-02-08 22:34:57 -05:00
parent fd9152ab0e
commit 70b25cf2af
3 changed files with 57 additions and 48 deletions

View file

@ -176,7 +176,9 @@
(define (make-page resource static-write)
(string->bytes/utf-8
(static-write
(fragment->page resource))))
(string-append
"<!DOCTYPE html>\n"
(fragment->page resource)))))
(define (fragment->page resource)
(xexpr->string

View file

@ -1,6 +1,7 @@
(main
(article
((id "oxaliq-dot-net-index"))
(noscript
(span
(div
((class "noscript"))
(p "hey! yr not letting yr browser execute javascript served by my page.")
(p "that's cool!")
@ -24,42 +25,48 @@
a nice time building this little thing ")
(p " i hope you have a nice time looking at things here")
(hr)
(p (span ((class "hx-target"))
(a ((href "/this")
(hx-get "/hx/this")
(hx-target "closest span")
(hx-swap "innerHTML"))
"(how i build this little page)")))
(p (span ((class "hx-target"))
(a ((href "/now")
(hx-get "/hx/now")
(hx-target "closest span")
(hx-swap "innerHTML"))
(div ((class "hx-target"))
(p
(a ((href "/this")
(hx-get "/hx/this")
(hx-target "closest div.hx-target")
(hx-swap "innerHTML"))
"(how i build this little page)")))
(div ((class "hx-target"))
(p
(a ((href "/now")
(hx-get "/hx/now")
(hx-target "closest div.hx-target")
(hx-swap "innerHTML"))
"(what i'm doing)")))
(p (span ((class "hx-target"))
(a ((href "/about")
(hx-get "/hx/about")
(hx-target "closest span")
(hx-swap "innerHTML"))
"(who i am)")))
(p (span ((class "hx-target"))
(a ((href "/contact")
(hx-get "/hx/contact")
(hx-target "closest span")
(hx-swap "innerHTML"))
(div ((class "hx-target"))
(p
(a ((href "/about")
(hx-get "/hx/about")
(hx-target "closest div.hx-target")
(hx-swap "innerHTML"))
"(who i am)")))
(div ((class "hx-target"))
(p
(a ((href "/contact")
(hx-get "/hx/contact")
(hx-target "closest div.hx-target")
(hx-swap "innerHTML"))
"(how to say hi to me)")))
(p (span ((class "hx-target"))
(a ((href "/very-earnest-disclaimer")
(hx-get "/hx/very-earnest-disclaimer")
(hx-target "closest span")
(hx-swap "innerHTML"))
(div ((class "hx-target"))
(p
(a ((href "/very-earnest-disclaimer")
(hx-get "/hx/very-earnest-disclaimer")
(hx-target "closest div.hx-target")
(hx-swap "innerHTML"))
"(a very earnest disclaimer)")))
; (p (span ((class "hx-target"))
; (a ((href "/links")
; (hx-get "/hx/links")
; (hx-target "closest span")
; (hx-swap "innerHTML"))
; "(some things i think are neat)")))
; (div ((class "hx-target"))
; (p
; (a ((href "/links")
; (hx-get "/hx/links")
; (hx-target "closest div.hx-target")
; (hx-swap "innerHTML"))
; "(some things i think are neat)")))
(p (a ((href "static/license/license.txt"))
"license"))
(p (a ((href "/tagged"))

View file

@ -35,26 +35,26 @@ h1, h2, h3, h4, h5 {
font-family: 'Courier New', Courier, monospace;
color: var(--background-color);
background-color: var(--visited-link-color);
padding: 2 10;
padding: 2px 10px;
}
h5 {
margin: 2 0;
margin: 2px 0px;
}
span.noscript p {
div.noscript p {
font-family: 'Courier New', Courier, monospace;
font-size: small;
}
span.hx-target section {
div.hx-target section {
border: solid 1px var(--link-color);
border-radius: 4px;
padding: 5 10;
margin: 3;
padding: 5px 10px;
margin: 3px;
}
span.hx-target footer {
div.hx-target footer {
display: none;
}
@ -78,7 +78,7 @@ a:not(.ascii a):not(a[hx-get*="hx"])::before {
}
body {
max-width: 600;
max-width: 600px;
margin: auto;
font-size: medium;
font-family: sans-serif;
@ -128,21 +128,21 @@ nav a {
}
p {
margin: 12 0;
margin: 12px 0px;
}
ul.tag-list {
display: flex;
flex-direction: row;
flex-wrap: wrap;
margin: 6 0;
padding: 0;
margin: 6px 0px;
padding: 0px;
}
li.tag-item {
list-style-type: none;
flex-basis: fit-content;
margin: 0 6;
margin: 0px 6px;
}
img {