From 4b5ec2a5709404feb51ccc3900c0770ba81929bf Mon Sep 17 00:00:00 2001 From: Pjotr Prins Date: Fri, 22 Sep 2023 17:43:09 -0500 Subject: Markdown and edit button --- web/css/gn-lite.css | 5 +++-- web/view/brand/aging.scm | 6 ++++++ web/view/markdown.scm | 10 ++++++---- 3 files changed, 15 insertions(+), 6 deletions(-) diff --git a/web/css/gn-lite.css b/web/css/gn-lite.css index 3ce6ace..4eb2968 100644 --- a/web/css/gn-lite.css +++ b/web/css/gn-lite.css @@ -3,6 +3,7 @@ padding: 20px; } -.button_align_right{ - float:right; +.button-align-right{ + float: right; + padding: 5px; } diff --git a/web/view/brand/aging.scm b/web/view/brand/aging.scm index e4e72e6..19db4d7 100644 --- a/web/view/brand/aging.scm +++ b/web/view/brand/aging.scm @@ -37,6 +37,12 @@ (type "text/css") (href "/css/pico.css") )) + (link + (@ (rel "stylesheet") + (media "screen") + (type "text/css") + (href "/css/gn-lite.css") + )) ,@head) (body ;; (header (p "TEST")) diff --git a/web/view/markdown.scm b/web/view/markdown.scm index 4dbedb2..2af2b26 100644 --- a/web/view/markdown.scm +++ b/web/view/markdown.scm @@ -46,8 +46,10 @@ "Parse a github markdown file that is formed like genenetwork/gn-docs/general/brand/aging/home.md" (match-let (((project repo page ...) (string-split path #\/))) `(div (@ (class "markdown")) - (div (@ (class "button_align_right")) - (a (@ (href ,(form-github-edit-url project repo page)) (role "button")) "edit text")) ,(commonmark->sxml - (fetch-raw-file (pk (form-github-raw-url project repo (pk page))))))) -) + (fetch-raw-file (pk (form-github-raw-url project repo (pk page))))) + (p + (div (@ (class "button-align-right")) + (a (@ (href ,(form-github-edit-url project repo page)) (role "button")) "edit"))) + (br) + (br)))) -- cgit v1.2.3