diff options
author | colin <colin@cicadas.surf> | 2023-03-07 19:15:12 -0800 |
---|---|---|
committer | colin <colin@cicadas.surf> | 2023-03-07 19:15:12 -0800 |
commit | efa771e3cc363dae68b57dfcc5c67c511a1d3331 (patch) | |
tree | 99dc6c2b8770a6e0ae87fedf2ba99ac21bf83b7d /src/views | |
parent | e2a60e8d2b8e41bcd2c9a39d8e2210f701b92353 (diff) |
Add: reporting rumors
Diffstat (limited to 'src/views')
-rw-r--r-- | src/views/adventure.lisp | 4 | ||||
-rw-r--r-- | src/views/components.lisp | 5 |
2 files changed, 6 insertions, 3 deletions
diff --git a/src/views/adventure.lisp b/src/views/adventure.lisp index b4980f1..8d4cebc 100644 --- a/src/views/adventure.lisp +++ b/src/views/adventure.lisp @@ -6,3 +6,7 @@ (defrender :inline ((adventure adventure)) (with-html (:a :href (urlpath adventure) (title adventure)))) + +(defrender :option ((adventure adventure)) + (with-html + (:option :value (uid adventure) (title adventure)))) diff --git a/src/views/components.lisp b/src/views/components.lisp index de4cc5c..bb9772d 100644 --- a/src/views/components.lisp +++ b/src/views/components.lisp @@ -19,11 +19,10 @@ the class string for the contained list items." (dolist (item data) (:li :class item-class (render :list-item item)))))) -(defrender :select ((data list) (multiple "false") name class) +(defrender :select ((data list) name class) (with-html (when data - (:select :multiple multiple - :name (or name (format nil "select-~a" (class-of (first data)))) + (:select :name (or name (format nil "select-~a" (class-of (first data)))) :class (or class (format nil "select ~a" (class-of (first data)))) (dolist (item data) (render :option item)))))) |