From 9062a8a64b6053e1f3324164234b0bf4bb56ced9 Mon Sep 17 00:00:00 2001 From: Claude Code Date: Sun, 29 Mar 2026 05:35:09 +0000 Subject: [PATCH] =?UTF-8?q?refactor:=20=E9=87=8D=E6=9E=84=E7=9B=AE?= =?UTF-8?q?=E5=BD=95=E7=BB=93=E6=9E=84=EF=BC=8C=E5=90=88=E5=B9=B6=E6=A1=8C?= =?UTF-8?q?=E9=9D=A2=E7=AB=AF=E5=92=8C=E7=A7=BB=E5=8A=A8=E7=AB=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 合并 prototype/ 和 prototype-mobile/ 为统一的 prototype/ 目录 - 移动 mobile-index.html 到 prototype/ - 移动 pages/mobile/* 到 prototype/pages/mobile/ - 删除 prototype-mobile/ 中的可删除文件 - 现在只有一个 server.js,符合技能文档最佳实践 注意:prototype-mobile/logs/ 目录因权限问题无法删除 (文件属于 root),需要手动清理 Co-Authored-By: Claude Sonnet 4.6 --- prototype-mobile/mobile-index.html | 140 -------- prototype-mobile/pages/mobile/ai-quiz.html | 267 -------------- .../pages/mobile/card-recite.html | 248 ------------- prototype-mobile/pages/mobile/home.html | 288 --------------- .../pages/mobile/memory-curve.html | 333 ------------------ prototype-mobile/pages/mobile/profile.html | 330 ----------------- .../pages/mobile/quiz-report.html | 300 ---------------- prototype-mobile/server.js | 172 --------- 8 files changed, 2078 deletions(-) delete mode 100644 prototype-mobile/mobile-index.html delete mode 100644 prototype-mobile/pages/mobile/ai-quiz.html delete mode 100644 prototype-mobile/pages/mobile/card-recite.html delete mode 100644 prototype-mobile/pages/mobile/home.html delete mode 100644 prototype-mobile/pages/mobile/memory-curve.html delete mode 100644 prototype-mobile/pages/mobile/profile.html delete mode 100644 prototype-mobile/pages/mobile/quiz-report.html delete mode 100644 prototype-mobile/server.js diff --git a/prototype-mobile/mobile-index.html b/prototype-mobile/mobile-index.html deleted file mode 100644 index 9d8e8fa..0000000 --- a/prototype-mobile/mobile-index.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - 移动端原型 - AI智能抽背助手 - - - - - - -
-

AI智能抽背助手 - 移动端原型

-

微信小程序风格 | 375×812 手机框架 | 6个核心页面

-
- - - 平铺展示模式 - - - - 蓝紫渐变主题 - - - - AI语音交互 - -
-
- - -
- -
-

首页抽背

- -
- - -
-

AI智能抽背

- -
- - -
-

抽背报告

- -
- - -
-

记忆曲线

- -
- - -
-

卡片背诵

- -
- - -
-

个人中心

- -
-
- - -
-

移动端原型系统 | 基于需求文档生成

-

生成时间: 2026-03-28 | 设计风格: 微信小程序

-
- - diff --git a/prototype-mobile/pages/mobile/ai-quiz.html b/prototype-mobile/pages/mobile/ai-quiz.html deleted file mode 100644 index ac0a0d0..0000000 --- a/prototype-mobile/pages/mobile/ai-quiz.html +++ /dev/null @@ -1,267 +0,0 @@ - - - - - - AI智能抽背 - AI智能抽背助手 - - - - - -
- -
- 09:41 -
- - - -
-
- - -
- - - -

AI智能抽背

- -
- - -
- -
-
- 当前进度 - 3 / 10 题 -
-
-
-
-
- - -
- -
-
- -
-
-

你好!我是你的AI助教,准备好了吗?我们开始今天的学习吧!

-
-
- - -
-
- -
-
-

第3题:请背诵麻黄汤的组成

-
- - 方剂学 - 解表剂 -
-
-
- - -
-
-

点击麦克风开始回答...

-
-
- -
-
- - -
-
-
-
-
-
-
-
- 正在倾听... -
- - -
-
- -
-
-
- -
-

- 麻黄汤由麻黄、桂枝、杏仁、甘草四味药组成,发汗解表,宣肺平喘。 -

-
-

- 知识点解析 -

-

- 麻黄汤为发汗解表之峻剂,主治外感风寒表实证。 -

-
-
-
-
-
- - -
- -
-
- -
-
- - -
- - -
- - - -
-
- - diff --git a/prototype-mobile/pages/mobile/card-recite.html b/prototype-mobile/pages/mobile/card-recite.html deleted file mode 100644 index 92608ba..0000000 --- a/prototype-mobile/pages/mobile/card-recite.html +++ /dev/null @@ -1,248 +0,0 @@ - - - - - - 卡片背诵 - AI智能抽背助手 - - - - - -
- -
- 09:41 -
- - - -
-
- - -
- - - -

卡片背诵

- -
- - -
- -
-
- 方剂学 - 解表剂 - 4 / 12 -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- - -
-
-
- -
-

麻黄汤

-

点击卡片查看详情

-
- - 左右滑动切换 - -
-
-
- - - - - -
-
- - -
- - -
- -
- - -
- -
-
-
- - - -
- - - - diff --git a/prototype-mobile/pages/mobile/home.html b/prototype-mobile/pages/mobile/home.html deleted file mode 100644 index e86c4c8..0000000 --- a/prototype-mobile/pages/mobile/home.html +++ /dev/null @@ -1,288 +0,0 @@ - - - - - - 首页抽背 - AI智能抽背助手 - - - - - -
- -
- 09:41 -
- - - -
-
- - -
- -
-
-
-

欢迎回来

-

小明同学

-
-
-
- -
-
-
- -
-
- 学习概览 - 2026-03-28 -
-
-
-

128

-

已记忆

-
-
-

45

-

未记忆

-
-
-

12

-

待复习

-
-
-
-
- - -
- - - -
-
-

- 记忆曲线提醒 -

- 查看全部 -
-
-
-
- -
-
-

临界点复习

-

麻黄汤功效、桂枝汤组成

-
- - 去背诵 - -
-
-
- - -
-
-

- 高频考点 -

- 更多 -
-
-
-
- 1 -
-
-

方剂学-解表剂

-

错误率 68%

-
- -
-
-
- 2 -
-
-

中医基础-阴阳学说

-

错误率 52%

-
- -
-
-
- 3 -
-
-

中药学-解表药

-

错误率 45%

-
- -
-
-
- - -
-
-

- 今日任务 -

- 2/5 完成 -
-
-
-
- -
- 完成30道题目 -
-
-
- -
- 复习错题本 -
-
-
- AI抽背20题 -
-
-
- 背诵10个知识点 -
-
-
- 查看学习报告 -
-
-
-
-
- - - -
- - diff --git a/prototype-mobile/pages/mobile/memory-curve.html b/prototype-mobile/pages/mobile/memory-curve.html deleted file mode 100644 index aa8266e..0000000 --- a/prototype-mobile/pages/mobile/memory-curve.html +++ /dev/null @@ -1,333 +0,0 @@ - - - - - - 记忆曲线 - AI智能抽背助手 - - - - - -
- -
- 09:41 -
- - - -
-
- - -
- - - -

记忆曲线

- -
- - -
- -
-
-
- -
-
-

该复习啦!

-

你有 5 个知识点即将遗忘

-
- - 开始 - -
-
- - -
-

- 记忆强度曲线 -

- - - - - - - - - - - - - - - - - - -
- 学习时 - 20分钟后 - 1小时后 - 1天后 - 3天后 -
-
- - -
-
-

- 复习计划 -

- 2026年3月 -
-
- - - - - - - -
-
-
-
-
-
-
-
1
-
2
-
3
-
4
-
5
-
6
-
7
-
8
-
9
-
10
-
11
-
12
-
13
-
14
-
15
-
16
-
17
-
18
-
19
-
20
-
21
-
22
-
23
-
24
-
25
-
26
-
27
-
28
-
29
-
30
-
31
-
-
-
-
- 已完成 -
-
-
- 今天 -
-
-
- 紧急 -
-
-
- - -
-

- 待复习知识点 -

-
-
-
- -
-
-

麻黄汤功效

-

紧急复习 · 今天到期

-
- - - -
-
-
- -
-
-

桂枝汤组成

-

明天到期

-
- - - -
-
-
- -
-
-

阴阳失调概念

-

3天后到期

-
- - - -
-
-
- - -
-

- 记忆统计 -

-
-
-

86

-

已牢固记忆

-
-
-

32

-

复习中

-
-
-

10

-

待巩固

-
-
-
-
- - - -
- - diff --git a/prototype-mobile/pages/mobile/profile.html b/prototype-mobile/pages/mobile/profile.html deleted file mode 100644 index eb17daf..0000000 --- a/prototype-mobile/pages/mobile/profile.html +++ /dev/null @@ -1,330 +0,0 @@ - - - - - - 个人中心 - AI智能抽背助手 - - - - - -
- -
- 09:41 -
- - - -
-
- - -
- -
-
-

个人中心

- -
-
-
-
- -
-
-
-

小明同学

-

ID: 10086888

-
- -
-
- - -
-
-
-
-

128

-

已记忆

-
-
-

45

-

学习中

-
-
-

32

-

收藏

-
-
-

15

-

连续天数

-
-
-
-
- - -
-
-
-

本周学习

- 03/21 - 03/28 -
-
-
-
- -
-
-
- -
-
-
- -
-
-
- -
-
-
- -
-
-
- -
-
-
- -
-
-
-
- - - - - - - - -
-
-
-

- 我的成就 -

- 查看全部 -
-
-
-
- -
-

连续7天

-
-
-
- -
-

百题达人

-
-
-
- -
-

正确率90%

-
-
-
- -
-

待解锁

-
-
-
-
-
- - - -
- - diff --git a/prototype-mobile/pages/mobile/quiz-report.html b/prototype-mobile/pages/mobile/quiz-report.html deleted file mode 100644 index f8fe228..0000000 --- a/prototype-mobile/pages/mobile/quiz-report.html +++ /dev/null @@ -1,300 +0,0 @@ - - - - - - 抽背报告 - AI智能抽背助手 - - - - - -
- -
- 09:41 -
- - - -
-
- - -
- - - -

抽背报告

- -
- - -
- -
-

报告生成于 2026-03-28 09:41

-

报告将保存30天

-
- - -
-
-
-
-

70%

-

正确率

-
-
-
-
-

10

-

总题数

-
-
-

7

-

正确

-
-
-

3

-

错误

-
-
-

5:32

-

用时

-
-
-
-
- - -
-

- 表现趋势 -

-
-
-
- 周一 -
-
-
- 周二 -
-
-
- 周三 -
-
-
- 周四 -
-
-
- 今天 -
-
-

- - 比上次提升 5%,继续保持! -

-
- - -
-

- 错题分析 -

-
-
-
-
-

桂枝汤的组成

-

方剂学 - 解表剂

-
- 未掌握 -
-

- - 正确答案:桂枝、芍药、甘草、生姜、大枣 -

-
-
-
-
-

阴阳失调的基本概念

-

中医基础理论

-
- 模糊 -
-

- - 阴阳失调是指阴阳之间失去平衡协调 -

-
-
-
-
-

麻黄汤的主治病证

-

方剂学 - 解表剂

-
- 未掌握 -
-

- - 主治外感风寒表实证 -

-
-
-
- - -
-

- 复习建议 -

-
-
-
- 1 -
-
-

重点复习方剂学解表剂章节

-

建议用时:20分钟

-
-
-
-
- 2 -
-
-

使用卡片背诵模式巩固记忆

-

推荐题目:10道

-
-
-
-
- 3 -
-
-

明天同一时间进行复习

-

记忆曲线最佳复习时间

-
-
-
-
- - - -
- - - -
- - diff --git a/prototype-mobile/server.js b/prototype-mobile/server.js deleted file mode 100644 index 04c6948..0000000 --- a/prototype-mobile/server.js +++ /dev/null @@ -1,172 +0,0 @@ -#!/usr/bin/env node - -/** - * AI 智能抽背助手 - 移动端原型本地预览服务器 - * - * 使用方法: - * node server.js - * - * 功能: - * - 启动本地 HTTP 服务器(端口 8081) - * - 自动打开浏览器访问移动端原型 - * - 支持热重载(修改文件后自动刷新) - * - * @author generate-prototype-grid skill - * @date 2026-03-28 - */ - -const http = require('http'); -const fs = require('fs'); -const path = require('path'); -const { exec } = require('child_process'); - -const PORT = 8081; -const PROTOTYPE_DIR = __dirname; - -// MIME 类型映射 -const MIME_TYPES = { - '.html': 'text/html; charset=utf-8', - '.css': 'text/css; charset=utf-8', - '.js': 'application/javascript; charset=utf-8', - '.json': 'application/json; charset=utf-8', - '.png': 'image/png', - '.jpg': 'image/jpeg', - '.jpeg': 'image/jpeg', - '.gif': 'image/gif', - '.svg': 'image/svg+xml', - '.ico': 'image/x-icon', - '.woff': 'font/woff', - '.woff2': 'font/woff2', - '.ttf': 'font/ttf', - '.md': 'text/markdown; charset=utf-8', -}; - -// 创建服务器 -const server = http.createServer((req, res) => { - // 解析 URL - let urlPath = req.url; - - // 处理根路径 - if (urlPath === '/') { - urlPath = '/mobile-index.html'; - } - - // 构建文件路径 - const filePath = path.join(PROTOTYPE_DIR, urlPath); - const extname = path.extname(filePath).toLowerCase(); - - // 设置响应头 - const contentType = MIME_TYPES[extname] || 'application/octet-stream'; - - // 读取并返回文件 - fs.readFile(filePath, (err, content) => { - if (err) { - if (err.code === 'ENOENT') { - // 文件不存在 - res.writeHead(404, { 'Content-Type': 'text/html; charset=utf-8' }); - res.end(` - - - - - 404 - 文件未找到 - - - -
-

404

-

文件未找到: ${urlPath}

- 返回首页 -
- - - `); - } else { - // 服务器错误 - res.writeHead(500, { 'Content-Type': 'text/html; charset=utf-8' }); - res.end('服务器错误: ' + err.code); - } - } else { - // 成功返回文件 - res.writeHead(200, { 'Content-Type': contentType }); - res.end(content); - } - }); -}); - -// 启动服务器 -server.listen(PORT, () => { - console.log('='.repeat(60)); - console.log(' AI 智能抽背助手 - 移动端原型本地预览服务器'); - console.log('='.repeat(60)); - console.log(''); - console.log(` 服务器地址: http://localhost:${PORT}`); - console.log(''); - console.log(' 可用页面:'); - console.log(` - 统一入口: http://localhost:${PORT}/mobile-index.html`); - console.log(''); - console.log(' 移动端页面:'); - console.log(` - 首页抽背: /pages/mobile/home.html`); - console.log(` - AI智能抽背: /pages/mobile/ai-quiz.html`); - console.log(` - 抽背报告: /pages/mobile/quiz-report.html`); - console.log(` - 记忆曲线: /pages/mobile/memory-curve.html`); - console.log(` - 卡片背诵: /pages/mobile/card-recite.html`); - console.log(` - 个人中心: /pages/mobile/profile.html`); - console.log(''); - console.log(' 按 Ctrl+C 停止服务器'); - console.log('='.repeat(60)); - console.log(''); - - // 自动打开浏览器 - const openCommand = process.platform === 'win32' ? 'start' : - process.platform === 'darwin' ? 'open' : 'xdg-open'; - - exec(`${openCommand} http://localhost:${PORT}`, (error) => { - if (error) { - console.log(' 提示: 无法自动打开浏览器,请手动访问上述地址'); - } else { - console.log(' 已自动打开浏览器'); - } - console.log(''); - }); -}); - -// 优雅退出 -process.on('SIGINT', () => { - console.log(''); - console.log('正在停止服务器...'); - server.close(() => { - console.log('服务器已停止'); - process.exit(0); - }); -}); - -module.exports = server;