diff --git a/Shared/Localizable.xcstrings b/Shared/Localizable.xcstrings index caf45c43c..0a88d3c10 100644 --- a/Shared/Localizable.xcstrings +++ b/Shared/Localizable.xcstrings @@ -48,6 +48,9 @@ "Account Stats" : { "comment" : "Account Stats screen title" }, + "Account Stats Help" : { + "comment" : "Help link" + }, "Accounts" : { "comment" : "Preferences" }, diff --git a/iOS/AccountStats/AccountStatsView.swift b/iOS/AccountStats/AccountStatsView.swift index fed01e234..3c5122fbe 100644 --- a/iOS/AccountStats/AccountStatsView.swift +++ b/iOS/AccountStats/AccountStatsView.swift @@ -51,13 +51,22 @@ struct AccountStatsView: View { Text(NSLocalizedString("Vacuuming…", comment: "Vacuum status text")) .foregroundStyle(.secondary) } + .frame(maxWidth: .infinity) } else { Button(NSLocalizedString("Vacuum Databases", comment: "Vacuum databases button")) { vacuum() } + .frame(maxWidth: .infinity) } } footer: { Text(NSLocalizedString("Vacuuming may make databases faster.", comment: "Vacuum explanation")) + .frame(maxWidth: .infinity, alignment: .center) + .multilineTextAlignment(.center) + } + + Section { + } footer: { + helpLinkFooter } } .navigationTitle(NSLocalizedString("Account Stats", comment: "Account Stats screen title")) @@ -72,13 +81,6 @@ struct AccountStatsView: View { } .disabled(isVacuuming) } - ToolbarItem(placement: .topBarTrailing) { - Button { - showHelp = true - } label: { - Label(NSLocalizedString("Help", comment: "Help"), systemImage: "questionmark.circle") - } - } } .sheet(isPresented: $showHelp) { SafariView(url: Self.helpURL) @@ -116,6 +118,15 @@ private extension AccountStatsView { var id: String { label } } + var helpLinkFooter: some View { + Button(NSLocalizedString("Account Stats Help", comment: "Help link")) { + showHelp = true + } + .font(.subheadline) + .frame(maxWidth: .infinity) + .padding(.top, 8) + } + func statsRow(_ item: StatItem, isBold: Bool) -> some View { HStack { Text(item.label)