feat: production Docker, Playwright tests, settings API, and bug fixes

- Add user management endpoints (register, list, delete, change password)
- Add API key management (create, list, delete)
- Add settings persistence endpoints (get, put)
- Wire settings dialog to real backend (People, API Keys, System, Security)
- Fix login auth flow (window.location.href for full reload)
- Fix download URLs returning 401 (make public since UUIDs are unguessable)
- Fix border tool shadowColor validation (accept 6-8 hex digits)
- Fix remove-bg alpha matting fallback (retry without on failure)
- Fix AI tool silent fallbacks (report errors instead of no-ops)
- Add checkerboard background to before/after slider for transparency
- Add progress bars to all AI tool components
- Add Playwright E2E test suite (131 tests across 9 test files)
- Rewrite Dockerfile for production (tsx runtime, pre-baked AI models)
- Add .dockerignore for faster builds
- Add proper accessible labels to login form
This commit is contained in:
Siddharth Kumar Sah
2026-03-22 19:28:57 +08:00
parent 06c5ee5996
commit ce03aad10f
37 changed files with 2607 additions and 122 deletions
@@ -88,6 +88,18 @@ export function BlurFacesSettings() {
{processing ? "Detecting Faces..." : "Blur Faces"}
</button>
{/* Progress indicator */}
{processing && (
<div className="space-y-2">
<div className="w-full bg-muted rounded-full h-2 overflow-hidden">
<div className="h-full bg-primary rounded-full animate-pulse" style={{ width: '100%' }} />
</div>
<p className="text-xs text-muted-foreground text-center">
AI processing may take 10-30 seconds...
</p>
</div>
)}
{/* Download */}
{downloadUrl && (
<a
@@ -109,6 +109,18 @@ export function EraseObjectSettings() {
{processing ? "Erasing..." : "Erase Object"}
</button>
{/* Progress indicator */}
{processing && (
<div className="space-y-2">
<div className="w-full bg-muted rounded-full h-2 overflow-hidden">
<div className="h-full bg-primary rounded-full animate-pulse" style={{ width: '100%' }} />
</div>
<p className="text-xs text-muted-foreground text-center">
AI processing may take 10-30 seconds...
</p>
</div>
)}
{/* Download */}
{downloadUrl && (
<a
@@ -128,6 +128,18 @@ export function OcrSettings() {
{processing ? "Extracting Text..." : "Extract Text"}
</button>
{/* Progress indicator */}
{processing && (
<div className="space-y-2">
<div className="w-full bg-muted rounded-full h-2 overflow-hidden">
<div className="h-full bg-primary rounded-full animate-pulse" style={{ width: '100%' }} />
</div>
<p className="text-xs text-muted-foreground text-center">
AI processing may take 10-30 seconds...
</p>
</div>
)}
{/* Result */}
{text !== null && (
<div className="space-y-2">
@@ -92,6 +92,18 @@ export function RemoveBgSettings() {
{processing ? "Removing Background..." : "Remove Background"}
</button>
{/* Progress indicator */}
{processing && (
<div className="space-y-2">
<div className="w-full bg-muted rounded-full h-2 overflow-hidden">
<div className="h-full bg-primary rounded-full animate-pulse" style={{ width: '100%' }} />
</div>
<p className="text-xs text-muted-foreground text-center">
AI processing may take 10-30 seconds...
</p>
</div>
)}
{/* Download */}
{downloadUrl && (
<a
@@ -64,6 +64,18 @@ export function UpscaleSettings() {
{processing ? "Upscaling..." : `Upscale ${scale}x`}
</button>
{/* Progress indicator */}
{processing && (
<div className="space-y-2">
<div className="w-full bg-muted rounded-full h-2 overflow-hidden">
<div className="h-full bg-primary rounded-full animate-pulse" style={{ width: '100%' }} />
</div>
<p className="text-xs text-muted-foreground text-center">
AI processing may take 10-30 seconds...
</p>
</div>
)}
{/* Download */}
{downloadUrl && (
<a