Repository navigation
feat(mail): manage and sync Cloudflare domains and addresses - #4
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: be2f9a0063
ℹ️ 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".
| syncNotice = ''; | ||
| try { | ||
| const result = await requestJson<{ sync: { domainsCreated: number; addressesCreated: number; | ||
| warnings: Array<{ domainName: string; code: string }> } }>('/api/workspace/mail-identities/sync', { method: 'POST' }); |
There was a problem hiding this comment.
Render local identities before awaiting provider sync
When Cloudflare is slow or unavailable, this awaited sync keeps loading true and delays copying the already-successful GET response into domains and addresses; since the server-side discovery deadline is 25 seconds, opening the page or manually retrying can hide all saved configuration for that entire period. Apply the initial GET result before starting discovery and update it again after sync so provider latency does not make local identity management temporarily unavailable.
Useful? React with 👍 / 👎.
进入域名和邮箱地址页面时,自动发现 Cloudflare 中指向本收信 Worker 的已有配置;同时支持核验并接入新域名、编辑域名策略和邮箱名称/签名。重复同步保留现有启停、删除及操作状态,不接管外部规则,也不自动启用发信。
修复 Workers 原生 fetch 的接收者绑定问题,避免真实同步请求失败;同步提示区分 Token 权限、连接、超时和限流,接口仅返回安全的错误类别。
WebKit 测试使用可见、可用控件的键盘操作,并为标签创建唯一数据以兼容串行重试;本机两个场景连续运行三轮,6 项全部通过。
界面截图使用本地合成数据;手机截图展示单个域名同步失败时保留已有配置的提示。