A webmail client. Forked from https://git.sr.ht/~migadu/alps
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

92 lines
3.4 KiB

  1. {{template "head.html" .}}
  2. {{template "nav.html" .}}
  3. {{template "util.html" .}}
  4. <div class="page-wrap">
  5. {{ template "aside" . }}
  6. <div class="container">
  7. <main class="create-update">
  8. <form method="post" enctype="multipart/form-data" id="compose-form">
  9. <input type="hidden" name="message_id" value="{{.Message.MessageID}}">
  10. <input type="hidden" name="in_reply_to" value="{{.Message.InReplyTo}}">
  11. <div class="headers no-js">
  12. <label>From</label>
  13. <input type="email" name="from" id="from" value="{{.Message.From}}" />
  14. <label>To</label>
  15. <input
  16. type="email"
  17. name="to"
  18. id="to"
  19. value="{{.Message.ToString}}"
  20. multiple
  21. list="emails"
  22. {{ if not .Message.To }} autofocus{{ end }}
  23. />
  24. <label>Subject</label>
  25. <input type="text" name="subject" id="subject" value="{{.Message.Subject}}" {{ if .Message.To }} autofocus{{ end }}/>
  26. <label>Attachments</label>
  27. <input type="file" name="attachments" id="attachments" multiple>
  28. <div
  29. id="attachment-list"
  30. {{ if .Message.Attachments }}
  31. style="display: none;"
  32. {{ end }}
  33. >
  34. <div class="help">Drag and drop attachments here</div>
  35. {{range .Message.Attachments}}
  36. <div class="upload">
  37. <label class="filename">
  38. <input type="checkbox" name="prev_attachments" value="{{.Node.PathString}}" checked>
  39. {{.Filename}}
  40. </label>
  41. </div>
  42. {{end}}
  43. <!--
  44. <div class="upload">
  45. <span class="progress"></span>
  46. <span class="filename">foobar.pdf</span>
  47. <span class="error"></span>
  48. <span class="size">1234 KiB</span>
  49. <button>&times;</button>
  50. </div>
  51. -->
  52. </div>
  53. <input type="hidden" id="attachment-uuids" name="attachment-uuids" value="" />
  54. </div>
  55. <div class="text">
  56. <textarea name="text" class="body">{{.Message.Text}}</textarea>
  57. <div id="send-progress" style="display: none">
  58. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path d="M288 39.056v16.659c0 10.804 7.281 20.159 17.686 23.066C383.204 100.434 440 171.518 440 256c0 101.689-82.295 184-184 184-101.689 0-184-82.295-184-184 0-84.47 56.786-155.564 134.312-177.219C216.719 75.874 224 66.517 224 55.712V39.064c0-15.709-14.834-27.153-30.046-23.234C86.603 43.482 7.394 141.206 8.003 257.332c.72 137.052 111.477 246.956 248.531 246.667C393.255 503.711 504 392.788 504 256c0-115.633-79.14-212.779-186.211-240.236C302.678 11.889 288 23.456 288 39.056z"/></svg>
  59. <span>Sending message...</span>
  60. </div>
  61. </div>
  62. <datalist id="emails">
  63. {{range .Extra.EmailSuggestions}}
  64. <option value="{{.}}">
  65. {{end}}
  66. </datalist>
  67. <div class="actions">
  68. <button id="send-button" type="submit">Send Message</button>
  69. <button id="save-button" type="submit" name="save_as_draft">Save as draft</button>
  70. <a class="button-link" href="/mailbox/INBOX">Cancel</a>
  71. </div>
  72. </form>
  73. </main>
  74. </div>
  75. </div>
  76. <script src="/themes/alps/assets/compose.js"></script>
  77. {{template "foot.html"}}