import SwiftUI

struct HistoryView: View {

    let manager: HistoryManagerProtocol

    var body: some View {
        NavigationView {
            List(manager.loadEntries()) { entry in
                HistoryListItem(entry: entry)
            }
            .navigationTitle("History")
        }
    }
}

struct HistoryView_Previews: PreviewProvider {
    static var previews: some View {
        HistoryView(manager: HistoryManagerMock())
    }
}
