press/click: refuse a zero-area target instead of tapping its origin
维护者通常 1 天内回复
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 20/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- typescript
调研方向
Start with packages/selectors/src/interaction-touch-point.ts and the existing interaction touch point tests in packages/selectors; the issue names this entry point but not a specific test file. Check how zero width or height is classified and use the existing typed reason for an unresolvable point. Add the requested regression test and command level case showing press refuses without dispatching a tap. An open linked pull request already covers this work.
由索引模型根据 Issue 内容生成。
描述
A selector that resolves to a zero-size node is tapped at the node's origin, and the command reports success.
Found on a physical iPhone in #1296 (comment). On SpringBoard home page 2, the page-1 icons stay in the tree with 0×0 rects and hittable: false. press 'label="Clock"' resolves to (0, 0), taps there, and reports success.
Cause on main: normalizeRect (packages/kernel/src/rect-center.ts) refuses only a negative width or height, so a 0×0 rect passes. resolveInteractionTouchPoint (packages/selectors/src/interaction-touch-point.ts) then returns the rect's center as a resolved point.
Required behavior:
resolveInteractionTouchPointreturnsinvalidfor a target with zero width or zero height. Do not changenormalizeRect, because other readers use zero-size rects legitimately.- A zero-area target refuses the interaction with the existing typed reason for an unresolvable point. Do not match error text.
- A regression test in
packages/selectorsfails before the fix and passes after it. Add one command-level case that showspressrefuses and does not dispatch a tap.
- 主要语言
- TypeScript
- 星标
- 5.1k
- 派生
- 339
- 平均合并
- 12 小时 22 分钟
- 30 天内合并 PR
- 701
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
callstack/agent-device 的其他 Issue
-
Limrun iOS fill reports success but drops non-ASCII text可能已有人在做 @mvanhorn 于 3 天前认领。 未关闭bug ready-for-agent
难度 2/5 1-3 小时 新手友好度 87/100
callstack/agent-device#3819 · 2 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
callstack/agent-device#1869 ·
维护者通常 1 天内回复
-
bug
难度 4/5 3-5 天 新手友好度 48/100
callstack/agent-device#3931 ·
维护者通常 1 天内回复
-
bug needs-info
难度 4/5 3-5 天 新手友好度 55/100
callstack/agent-device#3929 · 1 条评论 ·
维护者通常 1 天内回复
-
bug
难度 5/5 一周以上 新手友好度 35/100
callstack/agent-device#3924 · 1 条评论 ·
维护者通常 1 天内回复
查看 callstack/agent-device 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
awesome-dsh-plugin/awesome-dsh-plugin#9184 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 85/100
farion1231/cc-switch#8829 ·
维护者通常 1 天内回复
-
[core-client] Remove unused hand-maintained transport helpers after the definition-table cutover未关闭doc-audit enhancement
难度 2/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 85/100