import SwiftUI
import HealthDB
import HealthKitExtensions

struct MentalHealthList: View {

    let database: HealthDatabase

    var body: some View {
        List {
            Text("Anxiety Risk")
                .foregroundStyle(.secondary)
            Text("Depression Risk")
                .foregroundStyle(.secondary)
            QuantitySampleRow<AppleExerciseTime>(database: database, title: "Exercise Minutes")
            CategoryEmptySampleRow<MindfulSession>(database: database, title: "Mindful Minutes")
            Text("Sleep")
                .foregroundStyle(.secondary)
            Text("State of Mind")
                .foregroundStyle(.secondary)
            QuantitySampleRow<TimeInDaylight>(database: database)
        }
        .navigationTitle("Mental Wellbeing")
    }
}

#Preview {
    NavigationStack {
        MentalHealthList(database: .empty)
    }
}
