Comments: hide avatars when the site turns them off
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
调研方向
Start with CommentAvatarView, CommentListItem, CommentDetail, and the detail header in the WordPressComments screens; the issue describes the draft’s proposed CommentAvatar value and its .hidden and .image(URL?) cases. Check how the avatar view handles a missing author_avatar_urls map versus a map without a 96px address. Done means no avatar is drawn when the map is missing, while the grey circle remains when the map exists without that address.
由索引模型根据 Issue 内容生成。
描述
From Claude:
When a self-hosted site turns off Settings → Discussion → Show Avatars, the new comments screens show an empty grey circle for every commenter, where the site owner asked for no avatars at all.
What happens
WordPress leaves author_avatar_urls out of every comment in the REST API while "Show Avatars" is off. It only adds the field to the comments schema when the show_avatars option is on (class-wp-rest-comments-controller.php, get_item_schema()).
Until wordpress-rs 0.9.1, that made the whole comment response fail to parse, so those sites showed no comments. wordpress-rs trunk makes author_avatar_urls optional (Automattic/wordpress-rs#1664), and #26393 adopts it. Comments now load, but the avatar address is nil, and CommentAvatarView draws its placeholder: a plain grey circle.
Who is affected
Anyone viewing comments in the WordPressComments screens (comment list and comment detail) for a site with "Show Avatars" off.
Suggested fix
Treat a missing author_avatar_urls as "avatars are off" and draw no avatar, while keeping the grey circle when the map is there but has no 96px address (the site shows avatars, this author has none to show).
The missing map is a reliable signal. /wp/v2/settings doesn't expose show_avatars, so there's no other way to read the setting. The one exception is a request that uses _fields and leaves author_avatar_urls out; the app doesn't make one today.
A draft is on jkmassel/hide-comment-avatars-when-off, stacked on #26393: a CommentAvatar value (.hidden or .image(URL?)) replaces avatarURL in CommentListItem, CommentDetail and the detail header.
Not covered
The older UIKit comment screens fall back to a Gravatar looked up from the commenter's email when there's no avatar address, which also ignores the setting. That predates #26393 and isn't changed by the draft.
- 主要语言
- Swift
- 星标
- 3.9k
- 派生
- 1.2k
- 平均合并
- 1 天 23 小时
- 30 天内合并 PR
- 136
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
wordpress-mobile/WordPress-iOS 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 82/100
wordpress-mobile/WordPress-iOS#26423 · 1 条评论 ·
维护者通常 1 天内回复
-
[Pri] Low [Status] Ready for Dev [Type] Bug /Me
难度 2/5 1-3 小时 新手友好度 78/100
wordpress-mobile/WordPress-iOS#26279 · 1 条评论 ·
维护者通常 1 天内回复
-
[Pri] Low [Status] Ready for Dev [Type] Bug Share Extension
难度 2/5 1-3 小时 新手友好度 88/100
wordpress-mobile/WordPress-iOS#26276 · 1 条评论 ·
维护者通常 1 天内回复
-
[Pri] Low [Status] Ready for Dev [Type] Bug Blogging Prompts Notifications
难度 2/5 1-3 小时 新手友好度 79/100
wordpress-mobile/WordPress-iOS#26256 · 1 条评论 ·
维护者通常 1 天内回复
-
[Status] Ready for Dev [Type] Bug Reader
难度 2/5 1-3 小时 新手友好度 83/100
wordpress-mobile/WordPress-iOS#26254 · 2 条评论 ·
维护者通常 1 天内回复
查看 wordpress-mobile/WordPress-iOS 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 62/100
-
🎉 Add RemoteCrab未关闭
难度 1/5 1 小时以内 新手友好度 70/100
jaywcjlove/awesome-mac#4999 ·
维护者通常 1 天内回复
-
[Type] Bug
难度 2/5 1-3 小时 新手友好度 74/100
wordpress-mobile/GutenbergKit#940 ·
维护者通常 1 天内回复
-
pending-maintainer-response pending-triage
难度 2/5 1-3 小时 新手友好度 72/100
aws-amplify/amplify-swift#4423 ·
维护者通常 2 天内回复
-
tests
难度 2/5 1-3 小时 新手友好度 82/100
erkamyaman/unslop-anything#80 ·
维护者通常 1 天内回复