struct ContentView: View {
   @Environment(ApplicationData.self) private var appData
   @State private var showSheet: Bool = false

   var body: some View {
      NavigationStack {
         List(appData.userData) { book in
            CellBook(book: book)
         }
         .navigationTitle(Text("Books"))
         .toolbarTitleDisplayMode(.inlineLarge)
         .toolbar {
            ToolbarItem(placement: .topBarTrailing) {
               Button(action: {
                  showSheet = true
               }, label: { Image(systemName: "plus") })
            }
         }
         .sheet(isPresented: $showSheet) {
            AddBookView()
         }
      }
   }
}