|
|
@ -1,7 +1,4 @@
|
|
|
|
import SwiftUI
|
|
|
|
import SwiftUI
|
|
|
|
#if DEBUG
|
|
|
|
|
|
|
|
import DouShouQiModel
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
struct HistoricView: View {
|
|
|
|
struct HistoricView: View {
|
|
|
|
|
|
|
|
|
|
|
@ -11,15 +8,19 @@ struct HistoricView: View {
|
|
|
|
VStack {
|
|
|
|
VStack {
|
|
|
|
TitlePageFrame(Text: "Historic", ImageWidth: 200, ImageHeight: 200)
|
|
|
|
TitlePageFrame(Text: "Historic", ImageWidth: 200, ImageHeight: 200)
|
|
|
|
|
|
|
|
|
|
|
|
VStack {
|
|
|
|
// Afficher chaque groupe de dates dans une section distincte
|
|
|
|
List(historicListVM.historicList) { historicVM in
|
|
|
|
ForEach(historicListVM.groupByDate().sorted(by: { $0.key > $1.key }), id: \.key) { key, historicVMs in
|
|
|
|
GameResumeFrame(historicVm: historicVM)
|
|
|
|
VStack(alignment: .leading) {
|
|
|
|
|
|
|
|
Text(key) // Affiche la date comme titre de section
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List(historicVMs) { historicVM in
|
|
|
|
|
|
|
|
GameResumeFrame(historicVm: historicVM)
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.padding(.horizontal, 10)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
.padding(.horizontal, 10)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Spacer()
|
|
|
|
Spacer()
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|