import SwiftUI /// The native interface: feeds beside items, with the player bar under both. /// /// What is not here yet has somewhere to go rather than being missing. The item pane is #4 and /// the management screens are #5; until then the toolbar's Page button opens ipx's own page, /// which is still the whole app in a web view and can do everything this cannot. struct LibraryView: View { @ObservedObject var store: LibraryStore @ObservedObject var playback: Playback var play: (IPX.Entry) -> Void var openPage: () -> Void var body: some View { NavigationSplitView { FeedListView(store: store) .background(Glass.Wash()) } detail: { ItemListView(store: store, playback: playback, play: play) .toolbar { ToolbarItem(placement: .primaryAction) { Button(action: openPage) { Image(systemName: "safari") } .help("Open the full page: settings, the directory, OPML") } } } .tint(Glass.accent) .task { await store.refreshFeeds() store.reload() } .safeAreaInset(edge: .bottom, spacing: 0) { PlayerBarView(playback: playback) } } }