iPad: more keyboard shortcuts, a New-chat button, and hover polish

Round out the Mac-parity keyboard/pointer affordances on the iPad split view.

Keyboard shortcuts (hidden buttons in SplitRootView carry them):
- ⌘N — start a new chat: select Home and focus the composer (also defaults the
  project). A one-shot Bool binding threads Home→StartChatComposer and is
  consumed on use, so it grabs focus on ⌘N but never on a later Home appearance
  (handles both "already on Home" via onChange and "switched from a session"
  via onAppear).
- ⌘1–4 — jump to Home / Projects / To-dos / Settings.
- ⌘R — refresh sessions.
- ⌘. — interrupt a running session (Mac's "stop"; otherwise only in the ⋯ menu).

UI:
- A visible "New chat" (compose) button in the sidebar toolbar runs the same
  action, so touch users get the affordance too (gated on control scope).

Hover (pointer):
- .hoverEffect on the transcript tool-call / tool-block rows and the Home
  in-progress session rows (native List rows already hover).

Verified in the iPad simulator: the New-chat action scrolls to + focuses the
composer with the project defaulted. Builds clean.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
2026-07-04 01:18:35 -07:00
co-authored by Claude Opus 4.8
parent fb7aeffcf0
commit 005776685d
5 changed files with 75 additions and 6 deletions
@@ -14,7 +14,9 @@ struct ToolCallCard: View {
var body: some View {
let content = VStack(alignment: .leading, spacing: 8) {
Button { expanded.toggle() } label: { header }.buttonStyle(.plain)
Button { expanded.toggle() } label: { header }
.buttonStyle(.plain)
.hoverEffect(.highlight)
if expanded { details }
}
if inGroup {
@@ -98,6 +100,7 @@ struct ToolBlockCard: View {
VStack(alignment: .leading, spacing: 0) {
header
.contentShape(Rectangle())
.hoverEffect(.highlight)
.onTapGesture { withAnimation(.easeInOut(duration: 0.15)) { expanded.toggle() } }
if expanded {
ForEach(groups, id: \.toolCallID) { group in