summaryrefslogtreecommitdiff
path: root/src/pages/adventure-awaits.lisp
blob: 8255d2e849b8e757f3f73d9879454617c79a316c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
;;;; adventure-awaits.lisp -- page make to make a new adventure

(in-package :dnd)

(defclass adventure-awaits ()
  ((possible-seers
    :reader possible-seers
    :initarg :possible-seers
    :initform nil)))


(defrender t ((page adventure-awaits))
  (with-page (:title "What sparkles in yer eye?")
    (:h2 "Enscribe your new adventure in the book of the bards.")
    (:div 
     (:form :method "POST" :action "/adventure-awaits" :id "new-adventure-form"
            (:label
             :for "TITLE"
             "To sing of deeds, the bards require a title equal in greatness to the adventure before you.")
            (:br)
            (:input :name "TITLE"
                    :minlength "2"
                    :maxlength "40"
                    :placeholder "Dungeons & Deadlines")
            (when (possible-seers page)
              (:br)
              (:label
               :for "SEERS"
               "Who may act as a seer on this adventure?")
              (:br)
              (render :checkboxes (possible-seers page)))
            
            (:h4 "Describe the adventure you're about to begin:")
            (:textarea  :name "DESCRIPTION" :rows "5" :cols "60")
            (:br)
            (:button :type "submit" "Embark!")))))