tods-competition-factory 0.167.0 → 0.168.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/tods-competition-factory.development.cjs.js +27 -33
- package/dist/tods-competition-factory.development.cjs.js.map +1 -1
- package/dist/tods-competition-factory.production.cjs.min.js +1 -1
- package/dist/tods-competition-factory.production.cjs.min.js.map +1 -1
- package/dist/tods-competition-factory.production.esm.min.js +1 -1
- package/dist/tods-competition-factory.production.esm.min.js.map +1 -1
- package/package.json +2 -2
|
@@ -249,7 +249,7 @@ const matchUpFormatCode = {
|
|
|
249
249
|
};
|
|
250
250
|
|
|
251
251
|
function factoryVersion() {
|
|
252
|
-
return '0.
|
|
252
|
+
return '0.168.0';
|
|
253
253
|
}
|
|
254
254
|
|
|
255
255
|
function isPowerOf2(n) {
|
|
@@ -20910,41 +20910,35 @@ function assignSeed({
|
|
|
20910
20910
|
};
|
|
20911
20911
|
}
|
|
20912
20912
|
|
|
20913
|
-
if (seedNumbers.includes(seedNumber)
|
|
20914
|
-
|
|
20915
|
-
seedNumber
|
|
20916
|
-
|
|
20913
|
+
if (!seedNumbers.includes(seedNumber)) {
|
|
20914
|
+
seedAssignments.push({
|
|
20915
|
+
seedNumber,
|
|
20916
|
+
seedValue
|
|
20917
|
+
});
|
|
20918
|
+
}
|
|
20917
20919
|
|
|
20918
|
-
|
|
20919
|
-
|
|
20920
|
-
|
|
20921
|
-
|
|
20922
|
-
|
|
20923
|
-
}
|
|
20920
|
+
let success;
|
|
20921
|
+
seedAssignments.forEach(assignment => {
|
|
20922
|
+
// ensure that this participantId is not assigned to any other seedNumber
|
|
20923
|
+
if (assignment.participantId === participantId && assignment.seedNumber !== seedNumber) {
|
|
20924
|
+
assignment.participantId = undefined;
|
|
20925
|
+
} // assign participantId to target seedNumber
|
|
20924
20926
|
|
|
20925
|
-
let success;
|
|
20926
|
-
seedAssignments.forEach(assignment => {
|
|
20927
|
-
// ensure that this participantId is not assigned to any other seedNumber
|
|
20928
|
-
if (assignment.participantId === participantId && assignment.seedNumber !== seedNumber) {
|
|
20929
|
-
assignment.participantId = undefined;
|
|
20930
|
-
} // assign participantId to target seedNumber
|
|
20931
20927
|
|
|
20928
|
+
if (assignment.seedNumber === seedNumber) {
|
|
20929
|
+
assignment.participantId = participantId;
|
|
20930
|
+
assignment.seedValue = seedValue || seedNumber;
|
|
20931
|
+
success = true;
|
|
20932
|
+
}
|
|
20933
|
+
});
|
|
20932
20934
|
|
|
20933
|
-
|
|
20934
|
-
|
|
20935
|
-
|
|
20936
|
-
|
|
20937
|
-
}
|
|
20935
|
+
if (success) {
|
|
20936
|
+
modifyDrawNotice({
|
|
20937
|
+
drawDefinition,
|
|
20938
|
+
structureIds: [structureId]
|
|
20938
20939
|
});
|
|
20939
|
-
|
|
20940
|
-
|
|
20941
|
-
modifyDrawNotice({
|
|
20942
|
-
drawDefinition,
|
|
20943
|
-
structureIds: [structureId]
|
|
20944
|
-
});
|
|
20945
|
-
return { ...SUCCESS
|
|
20946
|
-
};
|
|
20947
|
-
}
|
|
20940
|
+
return { ...SUCCESS
|
|
20941
|
+
};
|
|
20948
20942
|
}
|
|
20949
20943
|
|
|
20950
20944
|
return {
|
|
@@ -21531,8 +21525,8 @@ function directLoser(params) {
|
|
|
21531
21525
|
const {
|
|
21532
21526
|
positionAssignments: sourcePositionAssignments
|
|
21533
21527
|
} = structureAssignedDrawPositions({
|
|
21534
|
-
|
|
21535
|
-
|
|
21528
|
+
structureId: sourceStructureId,
|
|
21529
|
+
drawDefinition
|
|
21536
21530
|
});
|
|
21537
21531
|
const relevantAssignment = sourcePositionAssignments.find(assignment => assignment.drawPosition === loserDrawPosition);
|
|
21538
21532
|
const loserParticipantId = relevantAssignment === null || relevantAssignment === void 0 ? void 0 : relevantAssignment.participantId;
|