tods-competition-factory 1.8.26 → 1.8.28

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.
@@ -1706,6 +1706,7 @@ type FindMatchUpType = {
1706
1706
  drawDefinition?: DrawDefinition;
1707
1707
  afterRecoveryTimes?: boolean;
1708
1708
  tournamentRecord: Tournament;
1709
+ nextMatchUps?: boolean;
1709
1710
  inContext?: boolean;
1710
1711
  matchUpId: string;
1711
1712
  eventId?: string;
@@ -1718,7 +1719,7 @@ type FindMatchUpResult = {
1718
1719
  structure?: Structure;
1719
1720
  error?: ErrorType;
1720
1721
  };
1721
- declare function findMatchUp({ participantsProfile, afterRecoveryTimes, tournamentRecord, contextContent, contextProfile, drawDefinition, matchUpId, inContext, eventId, drawId, event, }: FindMatchUpType): FindMatchUpResult;
1722
+ declare function findMatchUp({ participantsProfile, afterRecoveryTimes, tournamentRecord, contextContent, contextProfile, drawDefinition, nextMatchUps, matchUpId, inContext, eventId, drawId, event, }: FindMatchUpType): FindMatchUpResult;
1722
1723
 
1723
1724
  type GetPositionAssignmentsArgs = {
1724
1725
  structureId?: string;
@@ -8479,6 +8479,7 @@ function findMatchUp({
8479
8479
  contextContent,
8480
8480
  contextProfile,
8481
8481
  drawDefinition,
8482
+ nextMatchUps,
8482
8483
  matchUpId,
8483
8484
  inContext,
8484
8485
  eventId,
@@ -8489,8 +8490,8 @@ function findMatchUp({
8489
8490
  return { error: MISSING_TOURNAMENT_RECORD };
8490
8491
  if (typeof matchUpId !== "string")
8491
8492
  return { error: MISSING_MATCHUP_ID };
8492
- if (!drawDefinition || !event) {
8493
- const matchUps = allTournamentMatchUps({ tournamentRecord }).matchUps ?? [];
8493
+ if (!drawDefinition || !event || nextMatchUps) {
8494
+ const matchUps = allTournamentMatchUps({ tournamentRecord, nextMatchUps }).matchUps ?? [];
8494
8495
  const inContextMatchUp = matchUps.find(
8495
8496
  (matchUp2) => matchUp2.matchUpId === matchUpId
8496
8497
  );