blob: 784ee2ab825de24b56c60c423a951695e7b03da0 (
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 SettingsSectionSettingsView: View {
@EnvironmentObject var settings: SettingsManager
var body: some View {
Toggle(isOn: $settings.enableSync) {
Text("Sync with iCloud")
Text("Keep bookmarks, collections, search history, and sources in sync across your devices.")
.font(.caption)
}
.onChange(of: settings.enableSync) { _, _ in
settings.triggerSyncIfNeededForAll()
}
Button("Reset Settings") {
settings.resetToDefaults()
}
.trailingFrame()
}
}
|