From 78ec26f0ee892bc81dd5eb6db6a067737bf6252a Mon Sep 17 00:00:00 2001 From: Francesco <100066266+cranci1@users.noreply.github.com> Date: Sat, 31 May 2025 18:35:49 +0200 Subject: [PATCH] =?UTF-8?q?does=20ts=20even=20work=20=F0=9F=98=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SearchView/SearchViewComponents.swift | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/Sora/Views/SearchView/SearchViewComponents.swift b/Sora/Views/SearchView/SearchViewComponents.swift index 2209d24..45f3739 100644 --- a/Sora/Views/SearchView/SearchViewComponents.swift +++ b/Sora/Views/SearchView/SearchViewComponents.swift @@ -135,8 +135,7 @@ struct SearchContentView: View { onHistoryItemDeleted: onHistoryItemDeleted, onClearHistory: onClearHistory ) - .navigationTitle("Search") - .navigationBarTitleDisplayMode(.large) + .frame(maxWidth: .infinity, maxHeight: .infinity) } .navigationViewStyle(.stack) } @@ -170,7 +169,7 @@ struct SearchContent: View { .foregroundColor(.secondary) } .padding() - .frame(maxWidth: .infinity) + .frame(maxWidth: .infinity, maxHeight: .infinity) .background(Color(.systemBackground)) .shadow(color: Color.black.opacity(0.1), radius: 2, y: 1) } @@ -204,6 +203,18 @@ struct SearchContent: View { } } .padding(.vertical) + } else { + VStack(spacing: 8) { + Image(systemName: "magnifyingglass") + .font(.largeTitle) + .foregroundColor(.secondary) + Text("Start Searching") + .font(.headline) + Text("Enter a search term to begin") + .font(.caption) + .foregroundColor(.secondary) + } + .frame(maxWidth: .infinity, maxHeight: .infinity) } } else { if let module = selectedModule { @@ -225,5 +236,6 @@ struct SearchContent: View { } } } + .frame(maxWidth: .infinity, maxHeight: .infinity) } }