feat: 开发移动端交互界面(项目与用户管理)#1
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 789eb08285
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const publishNotice = (text: string) => { | ||
| setNotice(text); | ||
| window.setTimeout(() => setNotice(''), 1600); |
There was a problem hiding this comment.
Cancel stale notice timers before showing a new toast
publishNotice schedules a new setTimeout every time without clearing the previous one, so if users trigger two actions within 1.6s (e.g., create project, then advance status), the first timer will clear the second message early and the latest feedback can disappear almost immediately. This makes operation feedback unreliable; store the timeout id and clearTimeout it before starting a new timer.
Useful? React with 👍 / 👎.
Motivation
Description
App.tsx,增加类型定义、初始数据与状态管理,主要维护projects、contacts、topCards、users、messages、notice与showCreate等状态。filteredProjects)、底部弹层新建项目表单(showCreate+createProject)、以及项目状态推进(advanceProjectStage)。toggleExchange)、置顶卡续费(renewTopCard)、会员升级(upgradeMembership)和用户审核/冻结(auditUser/freezeUser)。publishNotice用于操作反馈,并同步更新README.md说明为“移动端交互版 MVP”。Testing
npm run build成功且输出到dist/(构建通过)。npm run dev -- --host 0.0.0.0 --port 4173成功并可访问本地/网络地址(启动通过)。Codex Task