Skip to content

feat(panel): add click-to-jump on permission approval card#108

Merged
wxtsky merged 5 commits intowxtsky:mainfrom
GeorgeDong32:001-permission-dialog-navigation
Apr 23, 2026
Merged

feat(panel): add click-to-jump on permission approval card#108
wxtsky merged 5 commits intowxtsky:mainfrom
GeorgeDong32:001-permission-dialog-navigation

Conversation

@GeorgeDong32
Copy link
Copy Markdown
Contributor

Summary

  • 点击权限审批卡片可跳转到对应终端窗口,与 SessionCard 行为一致
  • Session 为 nil 时播放错误音效 + 摇晃动画反馈
  • 远程会话静默跳过(无本地终端可跳转)
  • 跳转验证成功后可自动收起面板(取决于 autoCollapseAfterSessionJump 设置)
  • 提取 JumpAnimationHelper 命名空间统一管理动画工具

已在本地测试正常。

Changes

  • ApprovalBar 新增 sessionsessionIdappState 参数支持跳转功能
  • 新增 handleCardClick() 复用 SessionCard.handleSessionClick() 逻辑
  • 统一 nil session 和 validation failed 的错误反馈模式
  • jumpFailureShakeSequencerunShake 封装为 JumpAnimationHelper enum

Test plan

  • Build succeeds with no new warnings
  • All 103 tests pass (including updated JumpAnimationHelper.shakeSequence test)
  • Manual: click approval card → terminal window activates
  • Manual: nil session → error sound + shake animation
  • Manual: remote session → silent skip, no crash
  • Manual: Allow/Deny/Dismiss buttons still work correctly

Allow users to click the approval card to jump to the corresponding
terminal window, consistent with SessionCard behavior. Skip jump for
remote sessions. Show shake animation on failure.
… click

When the session no longer exists but the approval card is still displayed,
clicking the card now shows shake animation and error sound instead of
silently doing nothing. Improves user experience for edge case scenarios.
- Extract runJumpFailureShakeAnimation to shared file-level helper
- Add detailed comments for ApprovalBar click-to-jump logic
- Document nil/remote/valid session handling and validation retries
…mespace

- Group jumpFailureShakeSequence and runShake into private enum
- Eliminate file-level private functions per code review suggestion
- Both ApprovalBar and SessionCard delegate to JumpAnimationHelper.runShake
Wrap sound + shake in single @mainactor task block for consistency
with .failed case pattern
nguyenvanduocit pushed a commit to nguyenvanduocit/CodeIsland that referenced this pull request Apr 20, 2026
- T-036 (watch): click-to-jump on ApprovalBar — upstream PR wxtsky#108 open
- T-037 (high/XS): stale PermissionDenied hook after Claude Code downgrade

https://claude.ai/code/session_01WLDmSiJRYxdYhpxnC7gEkr
@wxtsky wxtsky merged commit 4aac30f into wxtsky:main Apr 23, 2026
wxtsky added a commit that referenced this pull request Apr 23, 2026
- Core models become Sendable so cross-queue captures in the panel
  view (added in #108) stop warning: SessionSnapshot, ChatMessage,
  ToolHistoryEntry, SubagentState, and AgentStatus are all plain
  value types with no reference-type fields, so conformance is safe.
- KimiView.swift: a path value that's only read gets let instead of var.
- TerminalVisibilityDetector.swift: session.source is non-optional
  (defaults to "claude"), so the `?? "claude"` fallback is unreachable.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
nguyenvanduocit pushed a commit to nguyenvanduocit/CodeIsland that referenced this pull request Apr 24, 2026
v1.0.22 released Apr 23. Key updates:
- T-034/T-037: upstream fix in adf41b6 (JSONMinimalEditor) — promote
- T-035/T-039: upstream fix in 0850f35 (Terminal.app + Spaces) — promote
- T-036: PR wxtsky#108 merged in 4aac30f — remove watch gate
- T-038: PR wxtsky#113 abandoned; upstream chose Sparkle (not viable for us)
- T-019: upstream fix via tool_use_id cache in 0a6ab92 → T-040
- New T-040: tool_use_id dedup cache (fixes burst permission rejection)
- New T-041: default mascot + IDE smart-suppress fix
- New T-042: watch PR wxtsky#126 (configurable auto-approve tools)
- New T-043: approval card rendering fix for macOS 26

https://claude.ai/code/session_01YHDH9QNxJeh96CuKhDUHUQ
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.

2 participants