Adapt new navigation to Mac app

This commit is contained in:
Angelo Stavrow 2021-10-08 14:29:18 -04:00
parent 0c41416314
commit ba898b6ac6
No known key found for this signature in database
GPG Key ID: 1A49C7064E060EEE
2 changed files with 6 additions and 2 deletions

View File

@ -35,12 +35,12 @@ struct ContentView: View {
.help("Create a new local draft.") .help("Create a new local draft.")
} }
#else #else
CollectionListView(selectedCollection: model.selectedCollection) CollectionListView()
#endif #endif
#if os(macOS) #if os(macOS)
ZStack { ZStack {
PostListView() PostListView(selectedCollection: model.selectedCollection, showAllPosts: model.showAllPosts)
if model.isProcessingRequest { if model.isProcessingRequest {
ZStack { ZStack {
Color(NSColor.controlBackgroundColor).opacity(0.75) Color(NSColor.controlBackgroundColor).opacity(0.75)

View File

@ -159,6 +159,10 @@ struct PostListView: View {
model.account.server == "https://write.as" ? "Anonymous" : "Drafts" model.account.server == "https://write.as" ? "Anonymous" : "Drafts"
) )
) )
.onAppear {
model.selectedCollection = selectedCollection
model.showAllPosts = showAllPosts
}
#endif #endif
} }
} }