Skip to content

Commit

Permalink
Added no search results (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
joeldavidw authored Jul 30, 2024
1 parent 5eb9328 commit 10862a6
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion Chronos/App/Tabs/Tokens/TokensTab.swift
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ struct TokensTab: View {
}
.overlay(
Group {
if tokenPairs.isEmpty {
if tokenPairs.isEmpty && searchQuery.isEmpty {
VStack {
Image(systemName: "qrcode.viewfinder")
.font(.system(size: 64))
Expand All @@ -135,6 +135,20 @@ struct TokensTab: View {
.padding(.top, 4)
}
.padding(.horizontal, 24)
} else if !searchQuery.isEmpty {
VStack {
Image(systemName: "magnifyingglass")
.font(.system(size: 64))
.foregroundColor(.gray)
.opacity(0.8)

Text("No results found")
.padding(.top, 4)
.multilineTextAlignment(.center)
.foregroundColor(.gray)
.opacity(0.8)
}
.padding(.horizontal, 24)
}
}
)
Expand Down

0 comments on commit 10862a6

Please sign in to comment.