Open saved session: visible progress + clear errors (no silent no-op)
The status line only rendered inside the last-in-memory-session block, so 'Open saved session' processed invisibly — looked like nothing happened. Now: the transcript status (with a spinner) is always shown, the processing(0,0) reconcile phase reads 'Working… (this can take a few minutes)', and invalid picks surface an alert (not a recorded session / already processing / unreadable transcript) instead of doing nothing.
This commit is contained in:
@@ -99,14 +99,19 @@ struct MenuBarView: View {
|
||||
}
|
||||
Spacer()
|
||||
}
|
||||
if !transcriptText.isEmpty {
|
||||
Text(transcriptText).font(.caption).foregroundStyle(transcriptColor)
|
||||
}
|
||||
}
|
||||
|
||||
Button("Open saved session…") { session.openSavedSession() }
|
||||
.buttonStyle(.link).font(.caption)
|
||||
.disabled(transcriptProcessing)
|
||||
HStack(spacing: 6) {
|
||||
Button("Open saved session…") { session.openSavedSession() }
|
||||
.buttonStyle(.link).font(.caption)
|
||||
.disabled(transcriptProcessing)
|
||||
if transcriptProcessing { ProgressView().controlSize(.small) }
|
||||
}
|
||||
|
||||
// Always-visible status (covers "Send to backend" AND "Open saved session").
|
||||
if !transcriptText.isEmpty {
|
||||
Text(transcriptText).font(.caption).foregroundStyle(transcriptColor)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -152,6 +157,7 @@ struct MenuBarView: View {
|
||||
private var transcriptText: String {
|
||||
switch session.transcriptStatus {
|
||||
case .idle: return ""
|
||||
case .processing(_, let t) where t == 0: return "Working… (this can take a few minutes)"
|
||||
case .processing(let d, let t): return "Transcribing… chunk \(d)/\(t)"
|
||||
case .done(let s, let seg): return "Transcript ready · \(s) speakers · \(seg) segments"
|
||||
case .failed(let m): return "Transcript failed: \(m)"
|
||||
|
||||
Reference in New Issue
Block a user