blob: 0916c994235aa4310760adcce9f61484c8dbf477 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
import SwiftUI
struct SettingsSettingsView: View {
@EnvironmentObject var settings: SettingsManager
var body: some View {
Toggle(isOn: $settings.enableICloudSync) {
Text("Sync with iCloud")
Text("Keep bookmarks, search history, and providers consistent across all your devices.")
.font(.caption)
}
.onChange(of: settings.enableICloudSync) { _, _ in
settings.syncToICloud()
}
Button("Reset to Defaults") {
settings.resetToDefaults()
}
.trailingFrame()
}
}
|