diff options
author | Tom Willemse | 2013-05-21 21:19:29 +0200 |
---|---|---|
committer | Tom Willemse | 2013-05-21 21:19:29 +0200 |
commit | a5eb8e2da51934ee10f0aa17496838c3999bd5c5 (patch) | |
tree | 6be693a3fc3c1c12e8477eabc997abb42a745b64 /scrumelo.el | |
parent | bf8518848de97aed928513f4a7b62f1157e5d52c (diff) | |
download | scrumelo-a5eb8e2da51934ee10f0aa17496838c3999bd5c5.tar.gz scrumelo-a5eb8e2da51934ee10f0aa17496838c3999bd5c5.zip |
Hide new story form
Use jQuery to allow it to be toggled between visible and invisible.
Diffstat (limited to 'scrumelo.el')
-rw-r--r-- | scrumelo.el | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/scrumelo.el b/scrumelo.el index aedcb2e..52b1493 100644 --- a/scrumelo.el +++ b/scrumelo.el @@ -59,7 +59,8 @@ (defun scrumelo--js-list () "Return a list of all required JS files." (list (scrumelo--js scrumelo-bootstrap-js-location) - (scrumelo--js scrumelo-jquery-js-location))) + (scrumelo--js scrumelo-jquery-js-location) + (scrumelo--js "js/scrumelo.js"))) (defun scrumelo--story () "Return a description of the current org heading as a scrum story." @@ -101,8 +102,11 @@ `(form (@ (method "POST") (action "/stories/new/")) (fieldset - (legend "New story") - (div (@ (style "text-align: center;")) + (legend (@ (class "toggle") + (data-show "new-story")) "New story") + (div (@ (id "new-story") + (class "hide") + (style "text-align: center;")) (div (@ (class "input-prepend input-append")) (span (@ (class "add-on")) "As a ") (input (@ (class "input-medium") (type "text") @@ -150,7 +154,8 @@ "Send the right requests in HTTPCON to the right functions." (elnode-dispatcher httpcon - '(("^/$" . scrumelo-backlog-page) + `(("^/$" . scrumelo-backlog-page) + ("^/js/scrumelo.js" . ,(elnode-make-send-file "js/scrumelo.js")) ("^/stories/new/$" . scrumelo-new-story)))) (elnode-start 'scrumelo-handler :port 8028 :host "localhost") |