Opening Settings focuses search and shows an unsolicited popup

未关闭
#780 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@M4n0x 已经在做这个了。

开始于 2026年11月17日。

  • #781 来自 @M4n0x —— 未关闭

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
25/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
macos, swift

调研方向

Read Sources/StableBar/CustomizationWindow.swift and inspect how CustomizationWindow presents its NSHostingView and selects the initial key view. The issue reports an offscreen activation regression showing that Search settings keeps AppKit's initial focus. Confirm the fix by checking that Settings opens without focusing search, while deliberate search via click, Tab, or ⌘F and focus on returning to an open window still work; pull request #781 is already open.

由索引模型根据 Issue 内容生成。

描述

bug

What happens

Opening Settings immediately focuses Search settings. macOS can then show a suggestion popup even though the user has not started searching.

Steps to reproduce

  1. Close Settings if it is already open.
  2. Open Settings… from StableBar's menu.
  3. Observe the focused search field and unsolicited popup without typing.

Expected

Settings opens without editing a text field. Clicking search, Tab and ⌘F still allow deliberate searching, and returning to an already-open window preserves focus.

Environment

Reported StableBar version was not provided. Investigated against main at 09413500 on macOS 27.2.1.

Evidence

The reporter supplied a screenshot of the focused, empty search field and popup. An offscreen activation regression confirms that the search field retains AppKit's initial focus; the native suggestion panel has not been reproduced live.

Diagnosis

CustomizationWindow in Sources/StableBar/CustomizationWindow.swift presents an NSHostingView without resetting the initial key-view selection. Search is the first editable control in its header.

Related

#608 and #612 concern search-header sizing. #517 concerns keyboard focus indicators in widget popups. Neither covers initial focus when Settings opens.

Triaged by Codex (gpt-6.1-sol).

主要语言
Swift
星标
184
派生
12
平均合并
3 小时 50 分钟
30 天内合并 PR
387

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

Seb-GRAF/StableBar 的其他 Issue

查看 Seb-GRAF/StableBar 的全部 Issue

相似的 Issue

更多 Swift Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。