前端:重构 Web UI 代码结构

- 添加 Import Map 支持 Lit 和本地模块的简洁导入
- 创建统一的 API 管理模块 (common/api.js)
- 重命名 styles/ 为 common/ 目录
- 修复分页时列选择被重置的问题
- 将 app.js 重命名为 main.js
- 所有导入路径使用 ~ 别名映射
This commit is contained in:
2025-10-09 15:53:58 +08:00
parent 9249ee6a2f
commit b7e2f970b4
20 changed files with 1349 additions and 421 deletions

View File

@@ -948,10 +948,10 @@ func TestTableWithCompaction(t *testing.T) {
// 获取 Level 统计信息
levelStats := table.compactionManager.GetLevelStats()
for _, stat := range levelStats {
level := stat["level"].(int)
fileCount := stat["file_count"].(int)
totalSize := stat["total_size"].(int64)
score := stat["score"].(float64)
level := stat.Level
fileCount := stat.FileCount
totalSize := stat.TotalSize
score := stat.Score
if fileCount > 0 {
t.Logf("L%d: %d files, %d bytes, score: %.2f", level, fileCount, totalSize, score)