Skip to content

fix: allow anonymous opt-out before sign-in - #33

Merged
VelvetAbyss merged 1 commit into
mainfrom
codex/seo-p1-counts-public-optout
Oct 22, 2026
Merged

VelvetAbyss merged 1 commit into
mainfrom
codex/seo-p1-counts-public-optout

Conversation

@VelvetAbyss

Copy link
Copy Markdown
Owner

生产验收发现未登录访客点击匿名计数开关会被现有 AuthInteractionGate 拦截并要求登录。本次仅将匿名计数设置标记为可公开操作,沿用法律页面现有的 data-auth-preview-allowed 机制,访客可直接关闭匿名计数。其他私有操作继续受登录拦截。

增加强制 isGated=true 的中英文集成回归,验证关闭生效、选择存储、没有登录提示,且相邻私有按钮仍被阻止。定向 11 项与 lint 已通过;标准 verify 正在运行,合并前等待完整 CI。

仅包含该组件一行改动及回归测试,保留其他未提交改动。生产复验将记录实际未登录开关操作。

@vercel

vercel Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
focus-go Ready Ready Preview Oct 22, 2026 1:15pm UTC

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-22T13:14:23.107181Z ee478aa PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ee478aa3a1

ℹ️ 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 enabled = useSyncExternalStore(subscribeAnonymousCounts, anonymousCountsEnabled, () => false)
const zh = language === 'zh'
return <section className="rounded-[var(--radius-lg)] border p-5" aria-labelledby="anonymous-counts-title">
return <section className="rounded-[var(--radius-lg)] border p-5" aria-labelledby="anonymous-counts-title" data-auth-preview-allowed="true">

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Expose the opt-out through the guest navigation path

For a signed-out production visitor entering Settings normally, this exemption is never reachable: SettingsRoute initializes activeSection to appearance at line 606, while the Legal TabsTrigger at lines 1109–1125 is itself inside AuthInteractionGate and lacks data-auth-preview-allowed, so the gate intercepts its role="tab" interaction before openSection can navigate. Only manually entering /workspace/settings/legal exposes this switch, and the new test misses the problem by rendering AnonymousCountsSetting directly; allow guest navigation to the Legal section or put the opt-out in an already reachable view.

Useful? React with 👍 / 👎.

@VelvetAbyss
VelvetAbyss merged commit a3bec9f into main Oct 22, 2026
3 checks passed

This branch was successfully deployed

1 active deployment
Preview — ee478aa3 Deployed Oct 22, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant