feat: complete web application — FastAPI backend + Vue 3 SPA frontend

- Full FastAPI backend with JWT auth, file management, processing pipeline,
  memory CRUD, barcode mappings, config management, cloud sync
- Vue 3 + Element Plus frontend with dashboard, task history, HTTP logs,
  memory editor, barcode editor, config editor, sync page
- HTTP request logging middleware with SQLite persistence
- Task history tracking with progress and retry support
- File metadata recording for upload/download operations
- WebAuth section in config.ini for bcrypt password storage
- Bug fix: logs.py count query returns tuple not dict

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-05-05 11:59:07 +08:00
parent 79522d8356
commit dedc3b4183
46 changed files with 6971 additions and 9 deletions
+172
View File
@@ -0,0 +1,172 @@
/* ═══════════════════════════════════════════
益选 OCR — Industrial Command Center Theme
═══════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,500;0,9..40,700;1,9..40,400&family=JetBrains+Mono:wght@400;500&display=swap');
:root {
/* Core palette */
--bg-dark: #0f1117;
--bg-sidebar: #161922;
--bg-card: #ffffff;
--bg-page: #f0f2f5;
--bg-hover: #f7f8fa;
/* Amber accent system */
--amber-50: #fff8e1;
--amber-100: #ffecb3;
--amber-400: #ffca28;
--amber-500: #ffc107;
--amber-600: #ffb300;
/* Semantic */
--primary: #2563eb;
--primary-hover: #1d4ed8;
--success: #10b981;
--warning: #f59e0b;
--danger: #ef4444;
--info: #6366f1;
/* Text */
--text-primary: #111827;
--text-secondary: #6b7280;
--text-muted: #9ca3af;
--text-inverse: #e5e7eb;
--text-sidebar: #94a3b8;
--text-sidebar-active: #ffffff;
/* Borders & shadows */
--border-light: #e5e7eb;
--border-subtle: #f3f4f6;
--shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
--shadow-md: 0 4px 12px rgba(0,0,0,0.06);
--shadow-lg: 0 8px 24px rgba(0,0,0,0.08);
--shadow-glow: 0 0 20px rgba(255,193,7,0.15);
/* Typography */
--font-sans: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
--font-mono: 'JetBrains Mono', 'Fira Code', monospace;
/* Transitions */
--ease-out: cubic-bezier(0.16, 1, 0.3, 1);
--ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: var(--font-sans);
background: var(--bg-page);
color: var(--text-primary);
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
/* Element Plus overrides */
.el-card {
border: 1px solid var(--border-light) !important;
border-radius: 12px !important;
box-shadow: var(--shadow-sm) !important;
transition: box-shadow 0.2s var(--ease-out) !important;
}
.el-card:hover {
box-shadow: var(--shadow-md) !important;
}
.el-button--primary {
background: var(--primary) !important;
border-color: var(--primary) !important;
font-weight: 500;
border-radius: 8px;
transition: all 0.2s var(--ease-out);
}
.el-button--primary:hover {
background: var(--primary-hover) !important;
transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(37,99,235,0.3);
}
.el-table {
--el-table-border-color: var(--border-light);
--el-table-header-bg-color: #fafbfc;
border-radius: 8px;
overflow: hidden;
}
.el-table th.el-table__cell {
font-weight: 600;
font-size: 12px;
text-transform: uppercase;
letter-spacing: 0.5px;
color: var(--text-secondary);
}
.el-progress-bar__outer {
border-radius: 6px;
}
.el-progress-bar__inner {
border-radius: 6px;
transition: width 0.4s var(--ease-out);
}
.el-tag {
border-radius: 6px;
font-weight: 500;
}
/* Scrollbar */
::-webkit-scrollbar {
width: 6px;
height: 6px;
}
::-webkit-scrollbar-track {
background: transparent;
}
::-webkit-scrollbar-thumb {
background: #d1d5db;
border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
background: #9ca3af;
}
/* Animations */
@keyframes fadeInUp {
from {
opacity: 0;
transform: translateY(12px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
@keyframes shimmer {
0% { background-position: -200% 0; }
100% { background-position: 200% 0; }
}
@keyframes pulse-glow {
0%, 100% { box-shadow: 0 0 0 0 rgba(255,193,7,0); }
50% { box-shadow: 0 0 16px 4px rgba(255,193,7,0.15); }
}
.animate-in {
animation: fadeInUp 0.4s var(--ease-out) both;
}
.animate-in-delay-1 { animation-delay: 0.05s; }
.animate-in-delay-2 { animation-delay: 0.1s; }
.animate-in-delay-3 { animation-delay: 0.15s; }
.animate-in-delay-4 { animation-delay: 0.2s; }