This commit is contained in:
anlicheng 2025-04-01 20:33:24 +08:00
parent d95c35992f
commit 7753040a6f

View File

@ -9,11 +9,10 @@ import SwiftUI
import Observation
struct SearchView: View {
@AppStorage("userId") private var userId: String = Utils.defaultUserId()
@Environment(\.dismiss) var dismiss
@State var model = SearchModel()
@State var searchText: String = ""
@FocusState private var isSearchFocused: Bool
@AppStorage("userId") private var userId: String = Utils.defaultUserId()
var body: some View {
VStack {
@ -54,12 +53,13 @@ struct SearchView: View {
}
}
}
Spacer()
}
.navigationTitle("")
.navigationBarBackButtonHidden(true)
.ignoresSafeArea(edges: [.bottom])
.padding(8)
.ignoresSafeArea(edges: .bottom)
.task {
await model.search(userId: userId, name: "第二季")
}
@ -83,7 +83,7 @@ extension SearchView {
image
.resizable()
.aspectRatio(contentMode: .fill)
.frame(width: 370, height: 180)
.frame(height: 180)
.clipped()
default:
Image("ph_img_big")