@ -83,12 +83,20 @@ struct TableStructureView: View {
Section {
Section {
LabeledContent {
LabeledContent {
StepperView ( count : $ teamCount , minimum : 4 , maximum : 128 )
StepperView ( count : $ teamCount , minimum : 4 , maximum : 128 ) {
} submitFollowUpAction : {
_verifyValueIntegrity ( )
}
} label : {
} label : {
Text ( " Nombre d'équipes " )
Text ( " Nombre d'équipes " )
}
}
LabeledContent {
LabeledContent {
StepperView ( count : $ groupStageCount , minimum : 0 , maximum : maxGroupStages )
StepperView ( count : $ groupStageCount , minimum : 0 , maximum : maxGroupStages ) {
} submitFollowUpAction : {
_verifyValueIntegrity ( )
}
} label : {
} label : {
Text ( " Nombre de poules " )
Text ( " Nombre de poules " )
}
}
@ -100,21 +108,33 @@ struct TableStructureView: View {
if ( teamCount / groupStageCount ) > 1 {
if ( teamCount / groupStageCount ) > 1 {
Section {
Section {
LabeledContent {
LabeledContent {
StepperView ( count : $ teamsPerGroupStage , minimum : 2 , maximum : ( teamCount / groupStageCount ) )
StepperView ( count : $ teamsPerGroupStage , minimum : 2 , maximum : ( teamCount / groupStageCount ) ) {
} submitFollowUpAction : {
_verifyValueIntegrity ( )
}
} label : {
} label : {
Text ( " Équipes par poule " )
Text ( " Équipes par poule " )
}
}
if structurePreset != . doubleGroupStage {
if structurePreset != . doubleGroupStage {
LabeledContent {
LabeledContent {
StepperView ( count : $ qualifiedPerGroupStage , minimum : 0 , maximum : ( teamsPerGroupStage - 1 ) )
StepperView ( count : $ qualifiedPerGroupStage , minimum : 0 , maximum : ( teamsPerGroupStage - 1 ) ) {
} submitFollowUpAction : {
_verifyValueIntegrity ( )
}
} label : {
} label : {
Text ( " Qualifié \( qualifiedPerGroupStage . pluralSuffix ) par poule " )
Text ( " Qualifié \( qualifiedPerGroupStage . pluralSuffix ) par poule " )
}
}
if qualifiedPerGroupStage < teamsPerGroupStage - 1 {
if qualifiedPerGroupStage < teamsPerGroupStage - 1 {
LabeledContent {
LabeledContent {
StepperView ( count : $ groupStageAdditionalQualified , minimum : 0 , maximum : maxMoreQualified )
StepperView ( count : $ groupStageAdditionalQualified , minimum : 0 , maximum : maxMoreQualified ) {
} submitFollowUpAction : {
_verifyValueIntegrity ( )
}
} label : {
} label : {
Text ( " Qualifié \( groupStageAdditionalQualified . pluralSuffix ) supplémentaires " )
Text ( " Qualifié \( groupStageAdditionalQualified . pluralSuffix ) supplémentaires " )
Text ( moreQualifiedLabel )
Text ( moreQualifiedLabel )
@ -311,14 +331,9 @@ struct TableStructureView: View {
updatedElements . insert ( . groupStageAdditionalQualified )
updatedElements . insert ( . groupStageAdditionalQualified )
} else {
} else {
updatedElements . remove ( . groupStageAdditionalQualified )
updatedElements . remove ( . groupStageAdditionalQualified )
} }
. toolbar {
ToolbarItem ( placement : . keyboard ) {
Button ( " Confirmer " ) {
stepperFieldIsFocused = false
_verifyValueIntegrity ( )
}
}
}
}
. toolbar {
ToolbarItem ( placement : . confirmationAction ) {
ToolbarItem ( placement : . confirmationAction ) {
if tournament . state ( ) = = . initial {
if tournament . state ( ) = = . initial {
ButtonValidateView {
ButtonValidateView {