diff options
-rw-r--r-- | fussy.lisp | 38 |
1 files changed, 27 insertions, 11 deletions
@@ -337,16 +337,22 @@ that they are not loaded during image gen.") (defparameter +themes-per-page+ 21) +(defun nav () + (html:with-html + (:nav + (:a :href "/" "Fussy")))) + (defun page-nav (page page-count) + "relative pagination nav to current page." (html:with-html - (:nav - (dotimes (pg (ceiling (/ page-count +themes-per-page+))) - (if (= pg page) - (:span (format nil " ~a " (1+ pg))) - (:span " " - (:a :href (format nil "/?page=~a" pg) - (format nil "~a" (1+ pg))) - " ")))))) + (:div + (dotimes (pg (ceiling (/ page-count +themes-per-page+))) + (if (= pg page) + (:span (format nil " ~a " (1+ pg))) + (:span " " + (:a :href (format nil "?page=~a" pg) + (format nil "~a" (1+ pg))) + " ")))))) (defun theme-preview-image (theme &optional variant) (html:with-html @@ -357,8 +363,8 @@ that they are not loaded during image gen.") (defun theme-preview-card (theme) (html:with-html (:div :class "card" - (:a :href (url-path theme) (:h4 theme)) - (theme-preview-image theme)))) + (:a :href (url-path theme) (:h4 theme) + (theme-preview-image theme))))) (defun style () (html:with-html @@ -395,7 +401,12 @@ img { (defparameter +style-css+ " +html, body { + height: 100%; +} + .main { + height: 100%; width: 100%; background-color: #eeeeff; } @@ -477,8 +488,11 @@ h1 { (:div :class "main" (:h1 "FUSSY") (:p :class "center" - "Emacs Themes Gallery for your Daily Procrastination Needs") + "Emacs Themes Gallery for your Daily Procrastination Needs." (:br) + (write-to-string (length all-themes)) " themes and counting...") + (nav) (page-nav page (length all-themes)) + (:div ) (:div :class "container" (dolist (theme themes) (theme-preview-card theme))))))))) @@ -510,6 +524,7 @@ h1 { (:body (:div :class "main" (:h1 (package-namestring pkg) ) + (nav) (:div :class "info" (:dl (:dt "Description") @@ -539,6 +554,7 @@ h1 { (:body (:div :class "main" (:h1 theme) + (nav) (:div (:p "A theme in the package " (:a :href (url-path pkg) (package-namestring pkg)))) |