From 7b218bfd759f415dc695bfafe197f1ef965f489d Mon Sep 17 00:00:00 2001 From: Shadowfacts Date: Thu, 4 May 2023 10:16:15 -0400 Subject: [PATCH] Fix spinner on Send Report button being misplaced Closes #377 --- Tusker/Screens/Report/ReportView.swift | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/Tusker/Screens/Report/ReportView.swift b/Tusker/Screens/Report/ReportView.swift index 14b5ede9..9f784981 100644 --- a/Tusker/Screens/Report/ReportView.swift +++ b/Tusker/Screens/Report/ReportView.swift @@ -143,14 +143,16 @@ struct ReportView: View { .appGroupedListRowBackground() Button(action: self.sendReport) { - if isReporting { - Text("Sending Report") + let label = Text(isReporting ? "Sending Report" : "Send Report") + HStack { + label Spacer() - ProgressView() - .progressViewStyle(.circular) - } else { - Text("Send Report") + if isReporting { + ProgressView() + .progressViewStyle(.circular) + } } + .accessibilityLabel(label) } .disabled(isReporting) .appGroupedListRowBackground()