Add Stop Button Implementation

Nucleic-Session: 1449BBC5-E23C-4D04-BB12-321F41ED2F11
Co-authored-by: Nucleic <[email protected]>
This commit is contained in:
2026-07-06 17:36:33 -07:00
co-authored by Nucleic
parent 20b60b566a
commit 6f38baef34
@@ -362,6 +362,18 @@ struct SessionDetailView: View {
.textFieldStyle(.plain)
.lineLimit(1...4)
.padding(.vertical, 3)
// Stop the in-flight turn (the Mac's ⌘. / "Interrupt"). Shown only
// while running and at control scope; send stays at the far right so
// its position never shifts. Mirrors `interruptShortcut`.
if running && store.canControl {
Button { store.interrupt(sessionID) } label: {
Image(systemName: "stop.circle.fill")
.font(.title2)
.foregroundStyle(.red)
}
.disabled(!store.connectivity.isLive)
.accessibilityLabel("Stop")
}
Button {
store.sendInput(draft, to: sessionID)
draft = ""