aboutsummaryrefslogtreecommitdiff
path: root/themes/alps/assets
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2020-11-13 11:55:56 -0500
committerDrew DeVault <sir@cmpwn.com>2020-11-13 11:55:56 -0500
commit1321cea241e0fa3f3ac7da38b7364b46e0858f11 (patch)
treeaa911c04a4797097ac78483ba2799c82c222e4a8 /themes/alps/assets
parent12547e26540a123f72df347bb87f6d9505480ac2 (diff)
downloadalps-1321cea241e0fa3f3ac7da38b7364b46e0858f11.tar.gz
alps-1321cea241e0fa3f3ac7da38b7364b46e0858f11.zip
Redirect to edit draft after saving message
Diffstat (limited to 'themes/alps/assets')
-rw-r--r--themes/alps/assets/compose.js10
1 files changed, 7 insertions, 3 deletions
diff --git a/themes/alps/assets/compose.js b/themes/alps/assets/compose.js
index e6f057f..a980d77 100644
--- a/themes/alps/assets/compose.js
+++ b/themes/alps/assets/compose.js
@@ -1,3 +1,6 @@
+const sendButton = document.getElementById("send-button"),
+ saveButton = document.getElementById("save-button");
+
const composeForm = document.getElementById("compose-form");
const sendProgress = document.getElementById("send-progress");
composeForm.addEventListener("submit", ev => {
@@ -6,6 +9,10 @@ composeForm.addEventListener("submit", ev => {
sendProgress.style.display = 'flex';
});
+saveButton.addEventListener("click", ev => {
+ sendProgress.querySelector(".info").innerText = "Saving draft...";
+});
+
let attachments = [];
const headers = document.querySelector(".create-update .headers");
@@ -41,9 +48,6 @@ function dragNOP(e) {
e.preventDefault();
}
-const sendButton = document.getElementById("send-button"),
- saveButton = document.getElementById("save-button");
-
const attachmentUUIDsNode = document.getElementById("attachment-uuids");
function updateState() {
let complete = true;