ParametersMenuView(Update) : parameters page

first acceptable version
pull/11/head
Johan LACHENAL 11 months ago
parent 1962e025bf
commit 0880717b7b

@ -35,7 +35,7 @@ struct DoushiQiPicker<EnumType: RawRepresentable & Identifiable & Hashable>: Vie
Text(title)
.foregroundColor(.black)
.padding()
Spacer()
Spacer() // .frame(width : (20 - CGFloat(title.count)))
Text(selectedOption.rawValue.description)
.foregroundColor(.black)
.padding()

@ -8,7 +8,7 @@
import SwiftUI
enum AIT: String, CaseIterable, Identifiable, Hashable {
case RandomAction = "IA Test"
case RandomAction = "IA Random"
case EasyTrainedAI = "IA Facile"
case MediumTrainedAI = "IA Intermédiaire"
@ -33,6 +33,10 @@ struct ParametersMenuView: View {
@State private var selectedRulesOption: Rules = .Regular
var body: some View {
VStack(alignment: .leading) {
HStack(alignment: .center) {
Text("Paramètres").bold().font(.title)
}.frame(maxWidth: .infinity)
Spacer().frame(maxHeight: 30)
ToggleView()
DoushiQiPicker(title: "Sélectionne une IA :",
selectedOption: $selectedAIOption,

@ -13,7 +13,7 @@ struct ToggleView: View {
Divider().background(Color.gray).padding(.vertical, 1)
Toggle("Dark Mode", isOn: $isDarkMode)
.toggleStyle(SwitchToggleStyle(tint: .blue))
.padding(EdgeInsets(top: 0, leading: 32, bottom: 0, trailing: 32))
.padding(EdgeInsets(top: 0, leading: 48, bottom: 0, trailing: 48))
Divider().background(Color.gray).padding(.vertical, 1)
}
}

Loading…
Cancel
Save