diff options
| author | Christian Cleberg <[email protected]> | 2026-03-22 20:40:50 -0500 |
|---|---|---|
| committer | Christian Cleberg <[email protected]> | 2026-03-22 20:40:50 -0500 |
| commit | 866f9517dba3c878197b0290dd8b4d1becb153c3 (patch) | |
| tree | 94c9bbb873a628b6df7dd92e6071d2987d50bb28 /Hutch/Views/Settings/SettingsView.swift | |
| parent | e60ff51620affd831202f06f710fcef6e1e92634 (diff) | |
| download | hutch-866f9517dba3c878197b0290dd8b4d1becb153c3.tar.gz hutch-866f9517dba3c878197b0290dd8b4d1becb153c3.tar.bz2 hutch-866f9517dba3c878197b0290dd8b4d1becb153c3.zip | |
feat: add privacy policy link and global swipe actions toggle to Settings
Diffstat (limited to 'Hutch/Views/Settings/SettingsView.swift')
| -rw-r--r-- | Hutch/Views/Settings/SettingsView.swift | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/Hutch/Views/Settings/SettingsView.swift b/Hutch/Views/Settings/SettingsView.swift index 91aa420..30758a8 100644 --- a/Hutch/Views/Settings/SettingsView.swift +++ b/Hutch/Views/Settings/SettingsView.swift @@ -48,6 +48,8 @@ struct SettingsView: View { patSection(viewModel) } + behaviorSection() + // Token / Sign Out tokenSection() @@ -383,6 +385,25 @@ struct SettingsView: View { // MARK: - Token / Sign Out Section @ViewBuilder + private func behaviorSection() -> some View { + Section { + Toggle( + "Swipe actions", + isOn: Binding( + get: { + UserDefaults.standard.object(forKey: AppStorageKeys.swipeActionsEnabled) as? Bool ?? true + }, + set: { UserDefaults.standard.set($0, forKey: AppStorageKeys.swipeActionsEnabled) } + ) + ) + } header: { + Text("Behavior") + } footer: { + Text("When enabled, swipe list rows to quickly take actions like resolving tickets, cancelling builds, and deleting pastes.") + } + } + + @ViewBuilder private func tokenSection() -> some View { Section { HStack { @@ -727,6 +748,10 @@ private struct AboutView: View { Text("Hutch uses your SourceHut personal access token to make requests on your behalf. The token is stored locally in the iOS keychain.") .font(.subheadline) .foregroundStyle(.secondary) + + Link(destination: URL(string: "https://hutch.cleberg.net/privacy.html")!) { + SwiftUI.Label("Privacy Policy", systemImage: "hand.raised") + } } Section("Acknowledgements") { |
