Skip to content

feat(vocab): Windows 手改学词卡片靠近输入位置并支持位置选择 - #1265

Merged
H-Chris233 merged 4 commits into
Open-Less:betafrom
HKLHaoBin:feat/issue-1238-vocab-card-anchor
Nov 17, 2026
Merged

H-Chris233 merged 4 commits into
Open-Less:betafrom
HKLHaoBin:feat/issue-1238-vocab-card-anchor

Conversation

@HKLHaoBin

Copy link
Copy Markdown
Collaborator

概述

Closes #1238

Windows 手改学词建议卡默认显示在本次输入的文本光标/焦点输入框附近,并提供保留右下角显示方式的用户选项。

主要改动

  • 按 session 与 observation 关联原始输入目标和建议,避免使用无关应用的最新焦点;在现有 UIA MTA worker 内采集位置,不增加同步插入路径的 UIA 查询。
  • 定位依次降级:有效文本光标 → 可见焦点输入框 → 原输入目标所在屏幕的右下角;按目标屏 DPI 和工作区处理负坐标、任务栏、边缘翻转及约束。
  • 在 设置 → 实验与拓展 → 手改学词/修改学习 的现有子页增加“建议卡片位置”:输入位置附近(默认)/固定右下角。不新增普通设置入口;兼容旧配置、持久化及恢复默认参数。
  • 保持卡片非模态、不抢焦点和逐条确认/绝对到期;处理共享胶囊窗口的定位、命中测试与异步 show/hide 代次。位置选择仅在 Windows 显示,其他平台的呈现方式不变。
  • 增加 Core 配置、纯定位/生命周期和八种语言文案的回归覆盖,并记录调研及实现边界。

验证

  • Review Bugbot:修复审查发现后复审,最终结果为 No bugs found。
  • 用户已安装测试并反馈没有问题。
  • 最终提交 7a3dde0f1c626f0288d548ba32b1e3965e55eac4 的 fork CI 全部必要检查通过,核对了新增回归的实际执行日志。
  • 同一提交的 Windows/macOS 桌面构建 与 Android arm64 构建 成功。
  • 所有编译、测试与产物构建仅在 GitHub Actions 执行,未在本地构建或测试。

特定编辑器的 UIA caret 能力仍取决于 provider;无法取得可靠矩形时正常回退,不承诺所有宿主都能精确贴近光标。用户测试反馈不等同于覆盖完整的编辑器/混合 DPI/输入法候选框矩阵。

🤖 Generated with Claude Code

HKLHaoBin and others added 3 commits October 24, 2026 22:45
Correlate suggestions with the original insertion observation, capture UIA
caret/input rectangles on the MTA worker, and fall back to the source
monitor work area using physical per-monitor geometry.

Keep card moves and clicks nonactivating, fence queued presentation work,
and add standalone geometry, ownership and long-session handoff regressions.

Review Bugbot: both initial findings fixed; re-review found no bugs.
Validation runs through branch-specific GitHub Actions only.

Co-Authored-By: Claude Opus 5 <[email protected]>
Keep the selector in the experimental learning subsection, default old configs to near-input placement, and retain source-screen bottom-right mode. Cover config roundtrips and locale parity; fix fixture and Android compile failures found by Actions.

Co-Authored-By: Claude Opus 5 <[email protected]>
Replace Node-only assertions with equivalent explicit errors so the existing frontend TypeScript build can include the locale regression test without new type dependencies.

Co-Authored-By: Claude Opus 5 <[email protected]>
@H-Chris233 H-Chris233 added area:input Input area area:ui UI area area:ux UX area enhancement New feature or request needs-review Needs review needs-tests Needs tests P2 Medium priority Windows Windows-specific labels Oct 27, 2026
@H-Chris233 H-Chris233 self-assigned this Oct 29, 2026
@appergb appergb added the branch-retained Keep source branch while the pull request remains open label Oct 30, 2026
保留共用观察器的会话与观察代次关联,并将卡片不激活策略接入 Windows 窗口子类模块。补充观察器身份与窗口激活策略的回归检查。
@H-Chris233
H-Chris233 merged commit e4cadfd into Open-Less:beta Nov 17, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:input Input area area:ui UI area area:ux UX area branch-retained Keep source branch while the pull request remains open enhancement New feature or request needs-review Needs review needs-tests Needs tests P2 Medium priority Windows Windows-specific

Projects

None yet

Development

Successfully merging this pull request may close these issues.

功能建议:手改学词的建议卡片希望跟随光标位置显示(目前固定屏幕右下角)

3 participants