Improve view
This commit is contained in:
parent
0952cb2e13
commit
cf691411d7
7 changed files with 39 additions and 20 deletions
src/components
25
src/components/document.lisp
Normal file
25
src/components/document.lisp
Normal file
|
@ -0,0 +1,25 @@
|
|||
(defpackage #:hp/components/document
|
||||
(:use #:cl)
|
||||
(:local-nicknames (#:pi #:piccolo))
|
||||
(:export #:document))
|
||||
(in-package #:hp/components/document)
|
||||
|
||||
(pi:define-element document (title description)
|
||||
(pi:h
|
||||
(html :lang "ja"
|
||||
(head
|
||||
(meta :charset "UTF-8")
|
||||
(script :src "/assets/js/htmx.js")
|
||||
(script :src "/assets/js/htmx-ext/head-support.js")
|
||||
(script :src "/assets/js/alpine.js" :defer t)
|
||||
(link :rel "stylesheet" :type "text/css" :href "/assets/css/dist.css")
|
||||
(link :rel "preconnect" :href "https://fonts.googleapis.com")
|
||||
(link :rel "preconnect" :href "https://fonts.gstatic.com" :crossorigin t)
|
||||
(link
|
||||
:rel "stylesheet"
|
||||
:href "https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;700&display=swap")
|
||||
(title (format nil "~@[~a - ~]skyizwhite.dev" title))
|
||||
(meta
|
||||
:name "description"
|
||||
:content (or description "pakuの個人サイト")))
|
||||
pi:children)))
|
13
src/components/layout.lisp
Normal file
13
src/components/layout.lisp
Normal file
|
@ -0,0 +1,13 @@
|
|||
(defpackage #:hp/components/layout
|
||||
(:use #:cl)
|
||||
(:local-nicknames (#:pi #:piccolo))
|
||||
(:export #:layout))
|
||||
(in-package #:hp/components/layout)
|
||||
|
||||
(pi:define-element layout ()
|
||||
(pi:h
|
||||
(body :hx-ext "head-support"
|
||||
; header
|
||||
(main pi:children)
|
||||
; footer
|
||||
)))
|
Loading…
Add table
Add a link
Reference in a new issue