重构: 迁移后端代码到 app 目录,前端移动到 WebUI,添加完整测试套件

主要变更:
- 后端代码从根目录迁移到 app/ 目录
- 前端代码从 frontend/ 重命名为 WebUI/
- 更新所有导入路径以适配新结构
- 提取公共 API 响应函数到 app/api/common.py
- 精简验证器服务代码
- 更新启动脚本和文档

测试:
- 新增完整测试套件 (tests/)
- 单元测试: 模型、仓库层
- 集成测试: 覆盖所有 22+ API 端点
- E2E 测试: 4个完整工作流场景
- 添加 pytest 配置和测试运行脚本
This commit is contained in:
祀梦
2026-04-04 13:32:36 +08:00
parent df3cc87f88
commit 38bd66128b
109 changed files with 2017 additions and 548 deletions

104
WebUI/src/style.css Normal file
View File

@@ -0,0 +1,104 @@
@import './styles/variables.css';
@import './styles/utilities.css';
@import './styles/element-plus.css';
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
line-height: 1.6;
color: var(--text-primary);
background: var(--bg);
overflow-x: hidden;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
a {
text-decoration: none;
color: var(--primary);
transition: var(--transition-base);
}
a:hover {
color: var(--primary-hover);
}
/* 滚动条 - 深色主题 */
::-webkit-scrollbar {
width: 8px;
height: 8px;
}
::-webkit-scrollbar-track {
background-color: var(--bg);
border-radius: var(--radius-sm);
}
::-webkit-scrollbar-thumb {
background-color: var(--border);
border-radius: var(--radius-sm);
transition: var(--transition-base);
}
::-webkit-scrollbar-thumb:hover {
background-color: var(--text-muted);
}
/* 选中文本颜色 */
::selection {
background: rgba(146, 124, 255, 0.3);
color: var(--text-primary);
}
/* 动画定义 */
@keyframes gradientShift {
0%, 100% {
background-position: 0% 50%;
}
50% {
background-position: 100% 50%;
}
}
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
@keyframes shimmer {
0%, 100% {
opacity: 0.3;
}
50% {
opacity: 1;
}
}
@keyframes float {
0%, 100% {
transform: translateY(0);
}
50% {
transform: translateY(-5px);
}
}
@keyframes pulse-glow {
0%, 100% {
box-shadow: 0 0 5px rgba(146, 124, 255, 0.3);
}
50% {
box-shadow: 0 0 20px rgba(146, 124, 255, 0.5);
}
}