diff --git a/DHBW-Service/Views/Tabs/HomeView.swift b/DHBW-Service/Views/Tabs/HomeView.swift index 2744b75..5449f90 100644 --- a/DHBW-Service/Views/Tabs/HomeView.swift +++ b/DHBW-Service/Views/Tabs/HomeView.swift @@ -44,14 +44,16 @@ struct HomeView: View { VStack { Text("today".localized(tableName: "HomeView")) .font(/*@START_MENU_TOKEN@*/.title/*@END_MENU_TOKEN@*/) - .frame(maxWidth: .infinity) + .frame(maxWidth: .infinity, alignment: .leading) VStack { if(!todaysEvents.isEmpty){ ForEach(todaysEvents, id: \.self) { exam in Text(exam.value(forKey: "summary") as! String) + .frame(maxWidth: .infinity, alignment: .leading) } } else { Text("noLectures".localized(tableName: "HomeView")) + .frame(maxWidth: .infinity, alignment: .leading) } } } @@ -64,14 +66,16 @@ struct HomeView: View { VStack { Text("tomorrow".localized(tableName: "HomeView")) .font(/*@START_MENU_TOKEN@*/.title/*@END_MENU_TOKEN@*/) - .frame(maxWidth: .infinity) + .frame(maxWidth: .infinity, alignment: .leading) VStack { if(!tomorrowsEvents.isEmpty){ ForEach(tomorrowsEvents, id: \.self) { exam in Text(exam.value(forKey: "summary") as! String) + .frame(maxWidth: .infinity, alignment: .leading) } } else { Text("noLectures".localized(tableName: "HomeView")) + .frame(maxWidth: .infinity, alignment: .leading) } } } @@ -91,14 +95,16 @@ struct HomeView: View { VStack { Text("upcomingExams".localized(tableName: "HomeView")) .font(/*@START_MENU_TOKEN@*/.title/*@END_MENU_TOKEN@*/) - .frame(maxWidth: .infinity) + .frame(maxWidth: .infinity, alignment: .leading) VStack { if(!upcomingExams.isEmpty){ ForEach(upcomingExams, id: \.self) { exam in Text(exam.value(forKey: "summary") as! String) + .frame(maxWidth: .infinity, alignment: .leading) } } else { Text("noExams".localized(tableName: "HomeView")) + .frame(maxWidth: .infinity, alignment: .leading) } } } @@ -116,7 +122,9 @@ struct HomeView: View { } } .navigationBarTitle(Text("Home")) - }.onAppear{ + } + .navigationViewStyle(StackNavigationViewStyle()) + .onAppear{ self.readFromCoreData() self.todaysEvents = getTodaysEvents() self.tomorrowsEvents = getTomorrowsEvents() diff --git a/DHBW-Service/Views/Tabs/LecturePlanList.swift b/DHBW-Service/Views/Tabs/LecturePlanList.swift index 5587cb2..f9fb747 100644 --- a/DHBW-Service/Views/Tabs/LecturePlanList.swift +++ b/DHBW-Service/Views/Tabs/LecturePlanList.swift @@ -55,7 +55,9 @@ struct LecturePlanList: View { // Text("Switch order") // } // }) - }.onAppear{ + } + .navigationViewStyle(StackNavigationViewStyle()) + .onAppear{ let sectionSortDescriptor = NSSortDescriptor(key: "startDate", ascending: true) let sortDescriptors = [sectionSortDescriptor] self.events = [] diff --git a/DHBW-Service/Views/Tabs/SettingsMain.swift b/DHBW-Service/Views/Tabs/SettingsMain.swift index cc2c9af..6d1d224 100644 --- a/DHBW-Service/Views/Tabs/SettingsMain.swift +++ b/DHBW-Service/Views/Tabs/SettingsMain.swift @@ -30,6 +30,7 @@ struct SettingsMain: View { .navigationTitle("settings".localized(tableName: "General", plural: false)) .listStyle(GroupedListStyle()) } + .navigationViewStyle(StackNavigationViewStyle()) .alert(isPresented: $showLogoutConfirmationAlert, content: { Alert( title: Text("logout".localized(tableName: "General", plural: false)),