2023-12-15 15:41:00 +00:00
|
|
|
//
|
2023-12-22 22:14:21 +00:00
|
|
|
// DashboardView.swift
|
2023-12-15 15:41:00 +00:00
|
|
|
// Jel
|
|
|
|
//
|
|
|
|
// Created by zerocool on 12/12/23.
|
|
|
|
//
|
|
|
|
|
|
|
|
import SwiftUI
|
2023-12-22 22:14:21 +00:00
|
|
|
import JellyfinKit
|
2023-12-15 15:41:00 +00:00
|
|
|
|
2023-12-22 22:14:21 +00:00
|
|
|
struct DashboardView: View {
|
2023-12-15 15:41:00 +00:00
|
|
|
@State var showingSettingsSheet: Bool = false
|
2024-02-21 19:45:48 +00:00
|
|
|
|
2023-12-15 15:41:00 +00:00
|
|
|
|
|
|
|
var body: some View {
|
2023-12-27 18:37:21 +00:00
|
|
|
ScrollView {
|
|
|
|
LazyVStack {
|
|
|
|
Section {
|
|
|
|
NavigationStack {
|
|
|
|
DashboardLibraryView()
|
|
|
|
}
|
|
|
|
} header: {
|
|
|
|
DashboardSectionTitleView("Libraries")
|
2024-01-07 21:41:45 +00:00
|
|
|
.padding([.top, .leading])
|
2023-12-27 18:37:21 +00:00
|
|
|
}
|
2023-12-15 15:41:00 +00:00
|
|
|
}
|
2024-02-21 19:45:48 +00:00
|
|
|
.navigationTitle("Home")
|
|
|
|
.toolbar {
|
|
|
|
ToolbarItem(placement: .topBarTrailing) {
|
|
|
|
Button {
|
|
|
|
showingSettingsSheet.toggle()
|
|
|
|
} label: {
|
|
|
|
Label("Settings", systemImage: "gear")
|
|
|
|
}
|
2023-12-15 15:41:00 +00:00
|
|
|
}
|
|
|
|
}
|
2024-02-21 19:45:48 +00:00
|
|
|
.sheet(isPresented: $showingSettingsSheet) {
|
|
|
|
SettingsView(showingSettingsView: $showingSettingsSheet)
|
|
|
|
}
|
2023-12-27 18:07:20 +00:00
|
|
|
}
|
2023-12-15 15:41:00 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-12-23 05:53:44 +00:00
|
|
|
//#Preview {
|
|
|
|
// DashboardView()
|
|
|
|
//}
|