Drafts system implemented

This commit is contained in:
2026-08-05 17:16:09 -05:00
parent 2d21fddb70
commit a03c865fa1
13 changed files with 419 additions and 75 deletions
+2
View File
@@ -21,6 +21,7 @@
function init(options) {
const opts = options || {};
const pending = opts.pending || [];
const draftUuid = opts.draftUuid || '';
const csrf = getCookie('csrftoken');
const csrfHeader = csrf ? { 'X-CSRFToken': csrf } : {};
@@ -112,6 +113,7 @@
const fd = new FormData();
fd.append('file', file);
fd.append('kind', z.kind);
if (draftUuid) fd.append('draft_uuid', draftUuid);
const xhr = new XMLHttpRequest();
xhr.open('POST', '/api/uploads/');