Compare commits

..

3 Commits

Author SHA1 Message Date
ffb45d2013 Mode frontend adjustments 2026-01-06 17:23:47 -07:00
2bf06b94a8 fix: Toggle summary visibility at start of render
Co-authored-by: aider (gemini/gemini-2.5-pro) <aider@aider.chat>
2026-01-06 17:05:39 -07:00
a86c0f4bac feat: Hide queue summary until items are added
Co-authored-by: aider (gemini/gemini-2.5-pro) <aider@aider.chat>
2026-01-06 17:00:50 -07:00
3 changed files with 11 additions and 7 deletions

View File

@@ -95,6 +95,11 @@ function addItem(file){
}
function render(){
const summaryEl = document.getElementById('summary');
if (summaryEl) {
summaryEl.classList.toggle('hidden', items.length === 0);
}
const itemsEl = document.getElementById('items');
itemsEl.innerHTML = items.map(it => `
<div class="rounded-2xl border bg-white dark:bg-gray-800 dark:border-gray-700 p-4 shadow-sm transition-colors">

View File

@@ -20,7 +20,6 @@
<h1 class="text-2xl font-semibold tracking-tight">File Drop Uploader</h1>
<div class="flex items-center gap-2">
<a href="/login" class="rounded-xl border px-4 py-2 text-sm dark:border-gray-600 dark:hover:bg-gray-800 hover:bg-gray-100 transition-colors" aria-label="Login">Login</a>
<span id="pingStatus" class="ml-2 text-sm text-gray-500 dark:text-gray-400 hidden sm:inline"></span>
</div>
</header>
@@ -31,7 +30,7 @@
<!-- Dropzone -->
<section id="dropzone" class="rounded-2xl border-2 border-dashed p-8 md:p-10 text-center bg-white dark:bg-gray-800 dark:border-gray-600 transition-colors">
<div id="dropHint" class="mx-auto h-12 w-12 opacity-70 hidden md:block">
<div id="dropHint" class="mx-auto -mt-10 h-12 w-12 opacity-70 hidden md:block">
<!-- upload icon -->
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M12 16V8m0 0l-3 3m3-3 3 3M4 16a4 4 0 0 0 4 4h8a4 4 0 0 0 4-4v-1a1 1 0 1 0-2 0v1a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2v-1a1 1 0 1 0-2 0v1z"/></svg>
</div>
@@ -51,7 +50,7 @@
</section>
<!-- Queue summary -->
<section id="summary" class="!mt-12 rounded-2xl border bg-white p-4 shadow-sm dark:bg-gray-800 dark:border-gray-700 transition-colors">
<section id="summary" class="hidden !mt-12 rounded-2xl border bg-white p-4 shadow-sm dark:bg-gray-800 dark:border-gray-700 transition-colors">
<div class="flex flex-wrap items-end justify-between gap-2 text-sm">
<!-- Buttons: on small screens show on their own row above -->
<div class="order-1 w-full md:order-2 md:w-auto flex gap-2 justify-end">

View File

@@ -23,7 +23,7 @@
<header class="flex items-center justify-between flex-wrap gap-2">
<h1 class="text-2xl font-semibold tracking-tight">File Drop Uploader</h1>
<div class="flex items-center gap-2">
<a id="linkHome" href="/" class="hidden rounded-xl border px-3 py-1 text-sm dark:border-gray-600">Home</a>
<a id="linkHome" href="/" class="hidden rounded-xl border px-4 py-2 text-sm dark:border-gray-600">Home</a>
</div>
</header>
@@ -55,11 +55,11 @@
<!-- Dropzone and queue copied from index.html -->
<section id="dropzone" class="rounded-2xl border-2 border-dashed p-8 md:p-10 text-center bg-white dark:bg-gray-800 dark:border-gray-600">
<div id="dropHint" class="mx-auto h-12 w-12 opacity-70 hidden md:block">
<div id="dropHint" class="mx-auto -mt-6 h-12 w-12 opacity-70 hidden md:block">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M12 16V8m0 0l-3 3m3-3 3 3M4 16a4 4 0 0 0 4 4h8a4 4 0 0 0 4-4v-1a1 1 0 1 0-2 0v1a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2v-1a1 1 0 1 0-2 0v1z"/></svg>
</div>
<p class="mt-3 font-medium hidden md:block">Drop files here</p>
<p class="text-sm text-gray-600 dark:text-gray-400 hidden md:block">...or</p>
<p class="mb-2 text-sm text-gray-600 dark:text-gray-400 hidden md:block">...or</p>
<div class="mt-3 relative inline-block">
<label class="rounded-2xl bg-black text-white dark:bg-white dark:text-black px-5 py-3 hover:opacity-90 cursor-pointer select-none" aria-label="Choose files">
Choose files
@@ -71,7 +71,7 @@
</div>
</section>
<section id="summary" class="!mt-12 rounded-2xl border bg-white p-4 shadow-sm dark:bg-gray-800 dark:border-gray-700">
<section id="summary" class="hidden !mt-12 rounded-2xl border bg-white p-4 shadow-sm dark:bg-gray-800 dark:border-gray-700">
<div class="flex flex-wrap items-end justify-between gap-2 text-sm">
<!-- Buttons: ensure present on invite page and visible on small screens -->
<div class="order-1 w-full md:order-2 md:w-auto flex gap-2 justify-end">