mirror of
https://github.com/cranci1/Sora.git
synced 2026-04-18 23:22:08 +00:00
fix
This commit is contained in:
parent
78f9b0f5e9
commit
d60ac5351d
1 changed files with 15 additions and 14 deletions
|
|
@ -37,27 +37,28 @@ struct DownloadView: View {
|
|||
|
||||
var body: some View {
|
||||
NavigationView {
|
||||
VStack(spacing: 0) {
|
||||
Spacer()
|
||||
.frame(height: 20)
|
||||
CustomDownloadHeader(
|
||||
selectedTab: $selectedTab,
|
||||
searchText: $searchText,
|
||||
isSearchActive: $isSearchActive,
|
||||
sortOption: $sortOption,
|
||||
showSortMenu: selectedTab == 1 && !jsController.savedAssets.isEmpty
|
||||
)
|
||||
|
||||
Group {
|
||||
if selectedTab == 0 {
|
||||
activeDownloadsView
|
||||
.transition(.opacity)
|
||||
} else {
|
||||
downloadedContentView
|
||||
.transition(.opacity)
|
||||
}
|
||||
}
|
||||
.animation(.easeInOut(duration: 0.2), value: selectedTab)
|
||||
.safeAreaInset(edge: .top) {
|
||||
VStack(spacing: 0) {
|
||||
CustomDownloadHeader(
|
||||
selectedTab: $selectedTab,
|
||||
searchText: $searchText,
|
||||
isSearchActive: $isSearchActive,
|
||||
sortOption: $sortOption,
|
||||
showSortMenu: selectedTab == 1 && !jsController.savedAssets.isEmpty
|
||||
)
|
||||
Divider()
|
||||
}
|
||||
.background(.ultraThinMaterial)
|
||||
}
|
||||
.navigationBarHidden(true)
|
||||
.animation(.easeInOut(duration: 0.2), value: selectedTab)
|
||||
.alert(NSLocalizedString("Delete Download", comment: ""), isPresented: $showDeleteAlert) {
|
||||
Button(NSLocalizedString("Delete", comment: ""), role: .destructive) {
|
||||
if let asset = assetToDelete {
|
||||
|
|
|
|||
Loading…
Reference in a new issue