SpecialX
ef2040edf4
docs(spec): 组件化重构专项设计文档 v1
2026-07-06 17:44:15 +08:00
SpecialX
be31da6223
docs(cache): 缓存策略落地实施计划 + 修正 INVALIDATION_MAP 占位符一致性
2026-07-05 01:37:15 +08:00
SpecialX
8afd7af6dc
docs(cache): 缓存策略落地专项设计文档 v1 - 全栈缓存策略一致性(服务端数据缓存+客户端 TanStack Query+失效编排)
2026-07-05 01:30:59 +08:00
SpecialX
214ebec976
refactor(design-tokens): 全量体系化重建设计令牌
...
Primitive + Semantic 双层令牌架构,HEX->HSL,明暗双份,@theme inline 暴露为 Tailwind 类。
- 新建 src/app/styles/tokens/ 6 个令牌文件(primitive/semantic-light/semantic-dark/lesson-preparation/tailwind-theme/index)
- globals.css 改为 @import 引入,477->258 行
- 清理 91 处 #hex 硬编码颜色 -> hsl(var(--*))
- 清理 10 处硬编码字体 -> var(--font-family-*)
- 清理 100 文件 Tailwind 任意值(Tier 1 映射/Tier 3 注释豁免)
- 清理 M3 Surface 死代码,升级 --lp-* 令牌(HEX->HSL + 暗色补全)
- 新建 ESLint 自定义规则 no-hardcoded-design-tokens(单词边界正则)
- eslint.config.mjs 新增 no-restricted-syntax 禁止 #hex + 自定义规则加载(pathToFileURL)
- 项目规则新增设计令牌规范强制章节
- 架构图 004/005 同步设计令牌体系节点
- known-issues.md 追加设计令牌问题分类(7 个规则表)
验证: tsc --noEmit 0 errors, npm run lint 0 errors/12 warnings(均为既有问题)
2026-07-05 01:03:19 +08:00
SpecialX
a1c283e10d
docs(lesson-preparation): 备课编辑器无边记纸感重构设计
...
新增设计文档,定义正文节点改造为真实 Tiptap 富文本编辑器、三栏布局(结构树 + 纸 + 详情面板)、节点展开到正文、师生交互节点、Tiptap Mark 锚点系统、v3→v4 数据迁移。
2026-07-04 10:58:55 +08:00
SpecialX
e4254f0f8e
docs: update architecture map and add lesson-preparation usage fixes design
...
- Update architecture impact map (004) and data (005) with new modules
- Add lesson-preparation usage fixes design spec
- Add teacher web test post-audit report
2026-06-24 12:01:35 +08:00
SpecialX
27db170c0a
docs: update architecture docs, audit reports, and bug tracking
...
- Update architecture impact map, data, feature checklist, gap audit
- Add audit reports for dashboard, exam-homework, grades-diagnostic, settings-profile, textbooks
- Update bug reports (admin, teacher, lesson-preparation, others, shared)
- Update coding standards, DR plan, design docs, and README
2026-06-23 17:36:18 +08:00
SpecialX
58656da983
feat(textbooks): 知识图谱功能全面重构 — 前置依赖 + dagre 布局 + React Flow 可视化 + 师生双视角
...
将教材模块图谱从基本无用状态升级为完整知识图谱可视化系统。
数据层:新增 knowledgePointPrerequisites 表(复合主键+双外键 cascade);新增 data-access-graph.ts(server-only)知识点关联聚合、学生/班级掌握度查询;utils.ts 新增 hasCycleAfterAddingEdge(DFS 循环依赖检测)。
业务层:3 个新 Server Action(getKnowledgeGraphDataAction 三视图模式、createPrerequisiteAction 含循环检测、deletePrerequisiteAction);graph-layout.ts 重写为 dagre 分层有向图布局。
视图层:knowledge-graph.tsx 重写为 React Flow 主组件(全书视图+搜索高亮+关联节点高亮+章节着色);4 个新组件(graph-kp-node/graph-prerequisite-edge/graph-toolbar/graph-node-detail-panel);use-graph-data.ts 派生值模式避免 effect 中 setState。
架构:严格三层架构,客户端通过 Server Action 间接访问 server-only 数据层;权限校验+ i18n 全覆盖;架构文档 004/005 同步。
测试:utils.test.ts 新增 5 个循环检测测试,graph-layout.test.ts 重写 5 个 dagre 布局测试,全部 30 个教材模块单元测试通过。
附带提交 drizzle/0005 error-book 迁移文件以保持 journal 一致性。
2026-06-23 00:13:03 +08:00