feat(ui): drag-drop capture onto the main panel

Drops into #main POST /api/capture/upload one file at a time, with
space_id pre-filled from localStorage.last_space_id (set whenever the
space view renders).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
root
2026-06-01 03:56:30 +10:00
parent d7f9bde5e9
commit 063c29a835
3 changed files with 45 additions and 0 deletions

View File

@@ -9,6 +9,7 @@ import { renderTopbar } from './components/topbar.js';
import { renderRightrail } from './components/rightrail.js';
import { emit } from './state.js';
import { el, mount } from './dom.js';
import { attachDropzone } from './components/dropzone.js';
const VIEWS = {
home: () => import('./views/home.js'),
@@ -56,6 +57,7 @@ async function init() {
renderTopbar(document.getElementById('topbar'));
renderSidebar(document.getElementById('sidebar'));
renderRightrail(document.getElementById('rightrail'));
attachDropzone(document.getElementById('main'));
route(renderView);
pollPending();
setInterval(pollPending, 15000);