Basic theme re-snarfed from activitypub.rocks site
ea0e9c38e5
But without the styles this time!
This commit is contained in:
parent
e1a58527fe
commit
a063816e55
2 changed files with 72 additions and 3 deletions
71
haunt.scm
71
haunt.scm
|
@ -1,17 +1,82 @@
|
|||
(use-modules (haunt asset)
|
||||
(haunt artifact)
|
||||
(haunt html)
|
||||
(haunt builder blog)
|
||||
(haunt builder atom)
|
||||
(haunt builder assets)
|
||||
(haunt reader commonmark)
|
||||
(haunt site))
|
||||
|
||||
(site #:title "Built with Guile"
|
||||
(define* (base-layout site body
|
||||
#:key title big-logo)
|
||||
`((doctype "html")
|
||||
(head
|
||||
(meta (@ (charset "utf-8")))
|
||||
(title ,(if title
|
||||
(string-append title " -- Hippo")
|
||||
(site-title site)))
|
||||
;; css
|
||||
(link (@ (rel "stylesheet")
|
||||
(href "/static/style.css")))
|
||||
;; atom feed
|
||||
(link (@ (rel "alternate")
|
||||
(title "Hippo's blog")
|
||||
(type "application/atom+xml")
|
||||
(href "/feed.xml"))))
|
||||
(body
|
||||
(div (@ (class "main-wrapper"))
|
||||
(header (@ (id "site-header"))
|
||||
;; 8sync logo
|
||||
(div (@ (class "header-logo-wrapper"))
|
||||
"Hippo")
|
||||
)
|
||||
(div (@ (class "site-main-content"))
|
||||
,body))
|
||||
;; TODO: Link to source.
|
||||
(div (@ (class "footer"))
|
||||
(a (@ (href "https://git.disroot.org/badrihippo/badrihippo.thekambattu.rocks"))
|
||||
"Site contents")
|
||||
" dual licensed under "
|
||||
(a (@ (href "https://creativecommons.org/licenses/by-sa/4.0/"))
|
||||
"Creative Commons 4.0 International")
|
||||
" and "
|
||||
(a (@ (href "http://www.gnu.org/licenses/gpl-3.0.en.html"))
|
||||
"the GNU GPL, version 3 or any later version")
|
||||
". Powered by "
|
||||
(a (@ (href "http://haunt.dthompson.us/"))
|
||||
"Haunt")
|
||||
"."))))
|
||||
|
||||
(define (index-content posts)
|
||||
`(div
|
||||
;; Main intro
|
||||
(div (@ (class "content-box bigger-text"))
|
||||
(p "Welcome to my page!")
|
||||
(p
|
||||
"You can also visit my "
|
||||
(a (@ (href "/blog"))
|
||||
"blog")
|
||||
".")
|
||||
)
|
||||
|
||||
))
|
||||
|
||||
(define (index-page site posts)
|
||||
(serialized-artifact
|
||||
"index.html"
|
||||
(base-layout site
|
||||
(index-content posts)
|
||||
#:big-logo #t)
|
||||
sxml->html))
|
||||
|
||||
(site #:title "Hippo"
|
||||
#:domain "badrihippo.thekambattu.rocks"
|
||||
#:default-metadata
|
||||
'((author . "Badri Sunderarajan")
|
||||
(email . "badrihippo@disroot.org"))
|
||||
#:readers (list commonmark-reader)
|
||||
#:builders (list (blog)
|
||||
#:builders (list (blog #:prefix "/blog")
|
||||
index-page
|
||||
(atom-feed)
|
||||
(atom-feeds-by-tag)
|
||||
(static-directory "images")))
|
||||
(static-directory "static")))
|
||||
|
|
4
static/style.css
Normal file
4
static/style.css
Normal file
|
@ -0,0 +1,4 @@
|
|||
#site-header {
|
||||
color: darkgreen;
|
||||
font-weight:bold;
|
||||
}
|
Loading…
Reference in a new issue