aboutsummaryrefslogtreecommitdiff
path: root/module/output/html.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2020-06-30 01:16:35 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2020-07-07 13:10:38 +0200
commit0539154c382cfdfe78d9d39d5fe0bbae2047b67d (patch)
tree284fc6d59a2a47991ec14e627fe585c3f6d80998 /module/output/html.scm
parentHTTP POST insertion works. (diff)
downloadcalp-0539154c382cfdfe78d9d39d5fe0bbae2047b67d.tar.gz
calp-0539154c382cfdfe78d9d39d5fe0bbae2047b67d.tar.xz
Add basic event creation from HTML.
Diffstat (limited to 'module/output/html.scm')
-rw-r--r--module/output/html.scm19
1 files changed, 18 insertions, 1 deletions
diff --git a/module/output/html.scm b/module/output/html.scm
index 9cdd874a..5c963482 100644
--- a/module/output/html.scm
+++ b/module/output/html.scm
@@ -758,7 +758,24 @@
(compose (cut date/-time<? <> start-date)
(extract 'DTSTART))
(cdr (stream-car evs))))))
- ,@(stream->list (stream-map fmt-day evs))))))))
+ ,@(stream->list (stream-map fmt-day evs))))
+ (template (@ (id "popup-template"))
+ (div (@ (class "popup-container"))
+ (div (@ (class "popup"))
+ (nav (@ (class "popup-control CAL_Calendar"))
+ (button (@ (title "Stäng") (onclick "") (class "btn close-tooltip")) (div "×")))
+ (form
+ (article (@ (class "eventtext CAL_bg_Calendar"))
+ (h3 (input (@ (type "text")
+ (name "summary")
+ (placeholder "Summary")
+ (required))))
+ (div (div (input (@ (type "time") (name "dtstart") (required)))
+ " — "
+ (input (@ (type "time") (name "dtend") (required))))
+ (textarea (@ (name "description")
+ (placeholder "Description")) "")
+ (input (@ (type "submit")))))))))))))
;; file existing but is of wrong type,