Files
FruitServer/docs/plans/INBOX.md
T

20 lines
1.5 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
## [已处理] 2026-10-20 | K40-B 评论需登录:未登录点输入框即引导登录(仅 App 端)
**用户指令(2026-10-20,原文)**:
> 「还有评论也需要登录后才能评论」
**现状**:`DramaCommentsSheet._post()` 已有 `ensureSignedIn`,但输入框可直接聚焦输入,用户输完点发送才被拦,体验上像「能评论」。
**口径(只改 Flutter,不动后端、不改接口)**
1. 未登录时点击评论输入框:不聚焦、不弹键盘,直接走 `ensureSignedIn` 登录闸;登录成功返回后自动聚焦输入框,取消则保持失焦。
2. 未登录时点发送:直接走登录闸,不放行空内容提示;已登录行为不变(空内容不提交)。
3. 未登录时输入框 hint 显示「登录后参与评论」(新增 l10n `commentLoginHint`:zh 登录后参与评论 / en Sign in to comment / id Masuk untuk berkomentar),已登录仍用 `writeComment`。
4. 回复、点赞、删除、举报等既有登录闸保持不变;评论列表匿名可读不变。
**测试/门禁**
- 新增:未登录点输入框出现登录闸且焦点未获取;登录后点输入框可正常聚焦;未登录点发送不产生评论;
- 既有评论用例保持通过;
- `dart analyze lib test` 零告警 + `flutter test` 全过 + `flutter build apk --debug`。
**流程**:从 `develop` 拉 `fix/flutter-k40-comment-auth`;作者 `Zhou Weidong <502333560@qq.com>`;`--no-ff` 合回 develop 并 push;PROGRESS 留痕;真机验收由用户执行。