Show progress while the Start workflow intent runs
This commit is contained in:
@@ -169,11 +169,20 @@ struct QuickRunPage: View {
|
|||||||
.disabled(starting)
|
.disabled(starting)
|
||||||
Spacer()
|
Spacer()
|
||||||
if let choice {
|
if let choice {
|
||||||
Button("Start") {
|
if starting {
|
||||||
|
ProgressView()
|
||||||
|
}
|
||||||
|
Button {
|
||||||
start(choice, prompt)
|
start(choice, prompt)
|
||||||
|
} label: {
|
||||||
|
ZStack {
|
||||||
|
Text("Starting…")
|
||||||
|
.hidden()
|
||||||
|
Text(starting ? "Starting…" : "Start")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.buttonStyle(WebButtonStyle(primary: true))
|
.buttonStyle(WebButtonStyle(primary: true))
|
||||||
.disabled(prompt.isEmpty || starting)
|
.disabled(prompt.isEmpty)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.font(Fonts.font(15, weight: 700))
|
.font(Fonts.font(15, weight: 700))
|
||||||
|
|||||||
Reference in New Issue
Block a user