aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2020-08-23 23:22:10 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2020-08-23 23:22:10 +0200
commitedaf758b80fed1f5f14cd4b192e661c8863e84bc (patch)
tree9baf17c11a6254e81f29a1c473e5eb86c072aa79
parentAdd rendering of standalone small-cal. (diff)
downloadcalp-edaf758b80fed1f5f14cd4b192e661c8863e84bc.tar.gz
calp-edaf758b80fed1f5f14cd4b192e661c8863e84bc.tar.xz
Move html modules under calp.
-rw-r--r--module/calp/entry-points/html.scm8
-rw-r--r--module/calp/html/caltable.scm (renamed from module/html/caltable.scm)4
-rw-r--r--module/calp/html/components.scm (renamed from module/html/components.scm)2
-rw-r--r--module/calp/html/config.scm (renamed from module/html/config.scm)2
-rw-r--r--module/calp/html/util.scm (renamed from module/html/util.scm)2
-rw-r--r--module/calp/html/vcomponent.scm (renamed from module/html/vcomponent.scm)8
-rw-r--r--module/calp/html/view/calendar.scm (renamed from module/html/view/calendar.scm)12
-rw-r--r--module/calp/html/view/calendar/month.scm (renamed from module/html/view/calendar/month.scm)12
-rw-r--r--module/calp/html/view/calendar/shared.scm (renamed from module/html/view/calendar/shared.scm)8
-rw-r--r--module/calp/html/view/calendar/week.scm (renamed from module/html/view/calendar/week.scm)12
-rw-r--r--module/calp/html/view/search.scm (renamed from module/html/view/search.scm)6
-rw-r--r--module/calp/html/view/small-calendar.scm (renamed from module/html/view/small-calendar.scm)6
-rw-r--r--module/calp/server/routes.scm12
13 files changed, 47 insertions, 47 deletions
diff --git a/module/calp/entry-points/html.scm b/module/calp/entry-points/html.scm
index abaa5f13..b2f613ea 100644
--- a/module/calp/entry-points/html.scm
+++ b/module/calp/entry-points/html.scm
@@ -8,11 +8,11 @@
:use-module ((ice-9 regex) :select (string-match regexp-substitute))
:use-module ((srfi srfi-41) :select (stream-take stream-for-each))
- :use-module ((html view calendar) :select (html-generate))
- :use-module ((html view calendar week)
+ :use-module ((calp html view calendar) :select (html-generate))
+ :use-module ((calp html view calendar week)
:select (render-calendar)
:renamer (lambda _ 'render-calendar-wide))
- :use-module ((html view calendar month)
+ :use-module ((calp html view calendar month)
:select (render-calendar-table))
:use-module ((vcomponent instance methods)
:select (get-calendars get-event-set))
@@ -144,7 +144,7 @@
(lambda ()
(sxml->xml
(re-root-static
- ((@ (html view small-calendar) render-small-calendar)
+ ((@ (calp html view small-calendar) render-small-calendar)
start standalone))))))]
[(wide)
diff --git a/module/html/caltable.scm b/module/calp/html/caltable.scm
index fb2cbe02..65a70252 100644
--- a/module/html/caltable.scm
+++ b/module/calp/html/caltable.scm
@@ -1,6 +1,6 @@
-(define-module (html caltable)
+(define-module (calp html caltable)
:use-module (util)
- :use-module (html util)
+ :use-module (calp html util)
:use-module (datetime)
:use-module (srfi srfi-41)
)
diff --git a/module/html/components.scm b/module/calp/html/components.scm
index 2580ea55..49f00e52 100644
--- a/module/html/components.scm
+++ b/module/calp/html/components.scm
@@ -1,4 +1,4 @@
-(define-module (html components)
+(define-module (calp html components)
:use-module (util)
:use-module (util exceptions)
:export (xhtml-doc)
diff --git a/module/html/config.scm b/module/calp/html/config.scm
index 03e18db7..6f156c98 100644
--- a/module/html/config.scm
+++ b/module/calp/html/config.scm
@@ -1,4 +1,4 @@
-(define-module (html config)
+(define-module (calp html config)
:use-module (util)
:use-module (util config)
)
diff --git a/module/html/util.scm b/module/calp/html/util.scm
index 4e15356a..8410472c 100644
--- a/module/html/util.scm
+++ b/module/calp/html/util.scm
@@ -1,4 +1,4 @@
-(define-module (html util)
+(define-module (calp html util)
:use-module ((base64) :select (base64encode base64decode))
:use-module (util))
diff --git a/module/html/vcomponent.scm b/module/calp/html/vcomponent.scm
index c0bbe8e1..be6b6166 100644
--- a/module/html/vcomponent.scm
+++ b/module/calp/html/vcomponent.scm
@@ -1,12 +1,12 @@
-(define-module (html vcomponent)
+(define-module (calp html vcomponent)
:use-module (util)
:use-module (vcomponent)
:use-module (srfi srfi-1)
:use-module (srfi srfi-41)
:use-module (datetime)
- :use-module (html util)
- :use-module ((html config) :select (edit-mode))
- :use-module ((html components) :select (btn tabset))
+ :use-module (calp html util)
+ :use-module ((calp html config) :select (edit-mode))
+ :use-module ((calp html components) :select (btn tabset))
:use-module ((util color) :select (calculate-fg-color))
:use-module ((vcomponent datetime output)
:select (fmt-time-span
diff --git a/module/html/view/calendar.scm b/module/calp/html/view/calendar.scm
index aa67220c..67a1a7b5 100644
--- a/module/html/view/calendar.scm
+++ b/module/calp/html/view/calendar.scm
@@ -1,4 +1,4 @@
-(define-module (html view calendar)
+(define-module (calp html view calendar)
:use-module (util)
:use-module (vcomponent)
:use-module ((vcomponent datetime)
@@ -6,17 +6,17 @@
:use-module ((vcomponent build)
:select (vcalendar vevent))
:use-module (datetime)
- :use-module (html components)
- :use-module ((html vcomponent)
+ :use-module (calp html components)
+ :use-module ((calp html vcomponent)
:select (popup
calendar-styles
fmt-day
make-block
fmt-single-event
))
- :use-module (html config)
- :use-module (html util)
- :use-module ((html caltable) :select (cal-table))
+ :use-module (calp html config)
+ :use-module (calp html util)
+ :use-module ((calp html caltable) :select (cal-table))
:use-module (util config)
diff --git a/module/html/view/calendar/month.scm b/module/calp/html/view/calendar/month.scm
index 99640a22..ce8957da 100644
--- a/module/html/view/calendar/month.scm
+++ b/module/calp/html/view/calendar/month.scm
@@ -1,16 +1,16 @@
-(define-module (html view calendar month)
+(define-module (calp html view calendar month)
:use-module (util)
:use-module (srfi srfi-1)
:use-module (srfi srfi-41)
:use-module (srfi srfi-41 util)
:use-module (datetime)
- :use-module (html view calendar shared)
- :use-module (html config)
+ :use-module (calp html view calendar shared)
+ :use-module (calp html config)
:use-module (vcomponent)
:use-module ((vcomponent datetime)
:select (really-long-event?
events-between))
- :use-module ((html vcomponent)
+ :use-module ((calp html vcomponent)
:select (make-block))
:use-module ((vcomponent group)
:select (group-stream get-groups-between))
@@ -80,8 +80,8 @@
;; These popups are relative the document root. Can thus be placed anywhere in the DOM.
,@(for event in (stream->list
(events-between start-date end-date events))
- ((@ (html vcomponent) popup) event
- (string-append "popup" ((@ (html util) html-id) event))))
+ ((@ (calp html vcomponent) popup) event
+ (string-append "popup" ((@ (calp html util) html-id) event))))
))
diff --git a/module/html/view/calendar/shared.scm b/module/calp/html/view/calendar/shared.scm
index d1f58460..73698060 100644
--- a/module/html/view/calendar/shared.scm
+++ b/module/calp/html/view/calendar/shared.scm
@@ -1,4 +1,4 @@
-(define-module (html view calendar shared)
+(define-module (calp html view calendar shared)
:use-module (util)
:use-module (srfi srfi-1)
:use-module (vcomponent)
@@ -10,10 +10,10 @@
:select (format-summary))
:use-module (util tree)
:use-module (datetime)
- :use-module (html config)
- :use-module ((html components)
+ :use-module (calp html config)
+ :use-module ((calp html components)
:select (btn tabset))
- :use-module ((html vcomponent)
+ :use-module ((calp html vcomponent)
:select (make-block) )
)
diff --git a/module/html/view/calendar/week.scm b/module/calp/html/view/calendar/week.scm
index 34e8eeb4..ca6aa9f8 100644
--- a/module/html/view/calendar/week.scm
+++ b/module/calp/html/view/calendar/week.scm
@@ -1,18 +1,18 @@
-(define-module (html view calendar week)
+(define-module (calp html view calendar week)
:use-module (util)
:use-module (srfi srfi-1)
:use-module (srfi srfi-41)
:use-module (datetime)
- :use-module (html view calendar shared)
- :use-module (html config)
- :use-module (html util)
+ :use-module (calp html view calendar shared)
+ :use-module (calp html config)
+ :use-module (calp html util)
:use-module (vcomponent)
:use-module ((vcomponent datetime)
:select (long-event?
event-length/day
event-zero-length?
events-between))
- :use-module ((html vcomponent)
+ :use-module ((calp html vcomponent)
:select (make-block) )
:use-module ((vcomponent group)
:select (group-stream get-groups-between))
@@ -46,7 +46,7 @@
,@(for event in (stream->list
(events-between start-date end-date events))
- ((@ (html vcomponent ) popup) event (string-append "popup" (html-id event))))
+ ((@ (calp html vcomponent ) popup) event (string-append "popup" (html-id event))))
)))))
diff --git a/module/html/view/search.scm b/module/calp/html/view/search.scm
index 12d8399f..faefe6dc 100644
--- a/module/html/view/search.scm
+++ b/module/calp/html/view/search.scm
@@ -1,11 +1,11 @@
-(define-module (html view search)
+(define-module (calp html view search)
:use-module (util)
:use-module (vcomponent)
:use-module (vcomponent search)
:use-module ((ice-9 pretty-print) :select (pretty-print))
- :use-module ((html components)
+ :use-module ((calp html components)
:select (xhtml-doc include-css))
- :use-module ((html vcomponent)
+ :use-module ((calp html vcomponent)
:select (compact-event-list))
)
diff --git a/module/html/view/small-calendar.scm b/module/calp/html/view/small-calendar.scm
index e6378176..80cbbaf2 100644
--- a/module/html/view/small-calendar.scm
+++ b/module/calp/html/view/small-calendar.scm
@@ -1,6 +1,6 @@
-(define-module (html view small-calendar)
- :use-module ((html components) :select (xhtml-doc include-css))
- :use-module ((html caltable) :select (cal-table))
+(define-module (calp html view small-calendar)
+ :use-module ((calp html components) :select (xhtml-doc include-css))
+ :use-module ((calp html caltable) :select (cal-table))
:use-module ((datetime) :select (month- month+ remove-day date->string))
)
diff --git a/module/calp/server/routes.scm b/module/calp/server/routes.scm
index 02bbd123..51e5acb2 100644
--- a/module/calp/server/routes.scm
+++ b/module/calp/server/routes.scm
@@ -17,7 +17,7 @@
:use-module (sxml namespace)
- :use-module ((html util) :select (html-unattr))
+ :use-module ((calp html util) :select (html-unattr))
:use-module (web http make-routes)
@@ -28,8 +28,8 @@
:autoload (vcomponent instance) (global-event-object)
- :use-module (html view calendar)
- :use-module ((html view search) :select (search-result-page))
+ :use-module (calp html view calendar)
+ :use-module ((calp html view search) :select (search-result-page))
)
@@ -109,7 +109,7 @@
end-date: (date+ start-date (date day: 6))
next-start: (lambda (d) (date+ d (date day: 7)))
prev-start: (lambda (d) (date- d (date day: 7)))
- render-calendar: (@ (html view calendar week) render-calendar)
+ render-calendar: (@ (calp html view calendar week) render-calendar)
intervaltype: 'week
)))))))
@@ -127,7 +127,7 @@
(date day: 1))
next-start: month+
prev-start: month-
- render-calendar: (@ (html view calendar month)
+ render-calendar: (@ (calp html view calendar month)
render-calendar-table)
pre-start: (start-of-week start-date)
post-end: (end-of-week (end-of-month start-date))
@@ -156,7 +156,7 @@
;; TODO this fails when dtstart is <date>.
;; @var{cal} should be the name of the calendar encoded with
- ;; modified base64. See (html util).
+ ;; modified base64. See (calp html util).
(POST "/insert" (cal data)
(unless (and cal data)