feat(mobile): 集成 Flutter 移动端 - #2
Merged
Merged
Conversation
- 将后端、前端、UI 展示站、部署文档、规则文档和示例资源迁移到统一目录\n- 同步 Docker、docker-compose、CI/CD、README 与规则索引中的路径\n- 保持前端、后端和文档变更的独立触发范围\n\nChecklist:\n- [x] 根目录重构改动已检查,未包含移动端代码\n- [x] 前端 npm test 57/57 通过,npm run build 通过\n- [x] 后端 pytest 已执行;当前环境因缺少 langgraph、langchain_core、torch 等依赖在收集阶段阻塞,未伪造通过\n- [x] git diff --cached --check 通过
Add the current Flutter implementation under the repository root mobile/ directory, including ESP32 provisioning and upload protocol support.
- 将上游 Flutter 应用从根目录 mobile/ 移动到 apps/mobile/\n- 删除 Gradle 问题报告、Playwright 临时文件和开发过程文档\n- 补充移动端临时产物忽略规则,避免生成文件再次进入仓库\n\nChecklist:\n- [x] 原作者的 Flutter commit 已保留,未改写 Author\n- [x] 移动端路径已统一为 apps/mobile/\n- [x] 已删除已知构建产物和临时开发文件\n- [x] apps/mobile/.gitignore 已同步更新\n- [x] git diff --cached --check 通过
- 使用安全存储保存 Session,并迁移旧版本的明文 Cookie\n- 限制 API 请求同源携带认证信息,防止跨域图片泄露 Session\n- 增加请求超时、401 清理、退出失败清理和 BLE debug 日志保护\n- 补充安全存储注入测试、同源校验测试和过期 Session 测试\n\nChecklist:\n- [x] Session 新写入路径使用 flutter_secure_storage\n- [x] 跨域 URL 不携带或保存 Cookie,相关测试已补充\n- [x] 退出、401 和 BLE 日志行为已同步\n- [x] Dart 格式检查通过\n- [x] flutter pub get 已执行,但当前环境因 pub.dev TLS 错误阻塞
- 在缺少 key.properties 时跳过发布签名配置,保证 debug 配置不崩溃\n- 增加不含秘密的 key.properties.example,明确 release 签名字段\n- 关闭生产 Android manifest 的全局明文 HTTP\n\nChecklist:\n- [x] key.properties 和 keystore 继续被忽略\n- [x] 无发布密钥时不会强制转换空配置\n- [x] production manifest 不再允许全局 cleartext HTTP\n- [x] Android 配置变更已通过 git diff --check
- 将 Flutter 默认 README 替换为项目启动、权限、测试和签名说明\n- 在根 README 和测试构建规则中登记 apps/mobile\n- 增加独立 Mobile CI,覆盖依赖、格式、分析、测试和 Android debug 构建\n\nChecklist:\n- [x] apps/mobile README 已说明 API_BASE_URL、BLE 权限和 release 签名\n- [x] 根目录结构和测试构建规则已同步移动端路径\n- [x] Mobile CI 仅监听 apps/mobile/** 和自身 workflow\n- [x] 文档与 workflow 变更已执行 git diff --check
- 按项目 Dart formatter 统一移动端 lib 和 test 的格式\n- 保持业务行为不变,降低后续分析和 review 噪声\n\nChecklist:\n- [x] dart format --output=none --set-exit-if-changed apps/mobile/lib apps/mobile/test 通过\n- [x] git diff --cached --check 通过\n- [x] 本次提交不包含构建产物或密钥
- 删除 Android manifest 中随上游提交带入的行尾空白\n\nChecklist:\n- [x] git diff --cached --check 通过\n- [x] 仅清理格式,不改变权限或运行行为
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Import the Flutter mobile app from upstream PR xiaozhejiya#144 into this fork and organize it under
apps/mobile/. The original upstream commit739a187keeps ConanWanglu as the Author; follow-up maintenance commits are by IDhammaI.Changes
flutter_secure_storage, migrate legacy SharedPreferences data, and remove plaintext copies.key.properties.example.Verification
flutter analyze --no-fatal-infos --fatal-warnings, 63 Flutter tests, Android debug APK).git diff --check: passed.Local Flutter
pub getwas previously affected by a pub.dev TLS handshake issue; TLS verification was not disabled. GitHub Actions resolved dependencies in a clean environment and completed all mobile checks.This PR targets this fork's
main. Upstream PR xiaozhejiya#144 was not approved, merged, or closed.