summaryrefslogtreecommitdiff
path: root/Sora/Views/Settings/Section/SettingsSectionSearchView.swift
diff options
context:
space:
mode:
Diffstat (limited to 'Sora/Views/Settings/Section/SettingsSectionSearchView.swift')
-rw-r--r--Sora/Views/Settings/Section/SettingsSectionSearchView.swift18
1 files changed, 18 insertions, 0 deletions
diff --git a/Sora/Views/Settings/Section/SettingsSectionSearchView.swift b/Sora/Views/Settings/Section/SettingsSectionSearchView.swift
new file mode 100644
index 0000000..6249c4a
--- /dev/null
+++ b/Sora/Views/Settings/Section/SettingsSectionSearchView.swift
@@ -0,0 +1,18 @@
+import SwiftUI
+
+struct SettingsSectionSearchView: View {
+ @EnvironmentObject var settings: SettingsManager
+
+ var body: some View {
+ Picker("Suggestion Mode", selection: $settings.searchSuggestionsMode) {
+ ForEach(SettingsSearchSuggestionsMode.allCases, id: \.self) { type in
+ Text(type.rawValue.capitalized).tag(type)
+ }
+ }
+
+ Button("Clear History") {
+ settings.searchHistory.removeAll()
+ }
+ .trailingFrame()
+ }
+}