NetNewsWire/Multiplatform/macOS/Preferences/Preference Panes/Advanced/AdvancedPreferencesView.swift

47 lines
1.3 KiB
Swift
Raw Normal View History

//
// AdvancedPreferencesView.swift
// macOS
//
// Created by Stuart Breckenridge on 27/6/20.
//
import SwiftUI
struct AdvancedPreferencesView: View {
2020-07-02 03:57:36 +02:00
@EnvironmentObject private var preferences: AppDefaults
var body: some View {
2020-07-12 12:53:37 +02:00
Form {
Toggle("Check for app updates automatically", isOn: $preferences.checkForUpdatesAutomatically)
Toggle("Download Test Builds", isOn: $preferences.downloadTestBuilds)
2020-07-12 12:53:37 +02:00
Text("If youre not sure, don't enable test builds. Test builds may have bugs, which may include crashing bugs and data loss.")
.foregroundColor(.secondary)
.lineLimit(3)
.padding(.bottom, 8)
HStack {
Spacer()
Button("Check for Updates", action: {})
Spacer()
2020-07-12 12:53:37 +02:00
}.padding(.bottom, 8)
Toggle("Send Crash Logs Automatically", isOn: $preferences.sendCrashLogs)
HStack {
Spacer()
2020-07-12 12:53:37 +02:00
Button("Privacy Policy", action: {
NSWorkspace.shared.open(URL(string: "https://ranchero.com/netnewswire/privacypolicy")!)
})
Spacer()
}.padding(.top, 12)
2020-07-12 12:53:37 +02:00
}.frame(width: 400, alignment: .center)
}
}