tods-competition-factory 1.8.36 → 1.8.37
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/forge/generate.mjs +16 -10
- package/dist/forge/generate.mjs.map +1 -1
- package/dist/forge/query.d.ts +3 -1
- package/dist/forge/query.mjs +16 -10
- package/dist/forge/query.mjs.map +1 -1
- package/dist/forge/transform.mjs +8 -5
- package/dist/forge/transform.mjs.map +1 -1
- package/dist/index.mjs +21 -11
- package/dist/index.mjs.map +1 -1
- package/dist/tods-competition-factory.development.cjs.js +29 -11
- 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/package.json +4 -4
|
@@ -2929,7 +2929,7 @@ var matchUpFormatCode = {
|
|
|
2929
2929
|
};
|
|
2930
2930
|
|
|
2931
2931
|
function factoryVersion() {
|
|
2932
|
-
return '1.8.
|
|
2932
|
+
return '1.8.37';
|
|
2933
2933
|
}
|
|
2934
2934
|
|
|
2935
2935
|
function getObjectTieFormat(obj) {
|
|
@@ -17454,7 +17454,7 @@ function addNationalityCode(_a) {
|
|
|
17454
17454
|
function addIndividualParticipants(_a) {
|
|
17455
17455
|
var e_1, _b, e_2, _c;
|
|
17456
17456
|
var _d;
|
|
17457
|
-
var participantMap = _a.participantMap;
|
|
17457
|
+
var participantMap = _a.participantMap, template = _a.template;
|
|
17458
17458
|
var participantObjects = Object.values(participantMap);
|
|
17459
17459
|
try {
|
|
17460
17460
|
for (var participantObjects_1 = __values(participantObjects), participantObjects_1_1 = participantObjects_1.next(); !participantObjects_1_1.done; participantObjects_1_1 = participantObjects_1.next()) {
|
|
@@ -17465,7 +17465,8 @@ function addIndividualParticipants(_a) {
|
|
|
17465
17465
|
try {
|
|
17466
17466
|
for (var _e = (e_2 = void 0, __values(participant.individualParticipantIds)), _f = _e.next(); !_f.done; _f = _e.next()) {
|
|
17467
17467
|
var participantId = _f.value;
|
|
17468
|
-
|
|
17468
|
+
var source = participantMap[participantId].participant;
|
|
17469
|
+
participant.individualParticipants.push(template ? attributeFilter({ template: template, source: source }) : source);
|
|
17469
17470
|
}
|
|
17470
17471
|
}
|
|
17471
17472
|
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
@@ -17652,8 +17653,12 @@ function getParticipantMap(_a) {
|
|
|
17652
17653
|
}
|
|
17653
17654
|
finally { if (e_2) throw e_2.error; }
|
|
17654
17655
|
}
|
|
17655
|
-
if (withIndividualParticipants)
|
|
17656
|
-
|
|
17656
|
+
if (withIndividualParticipants) {
|
|
17657
|
+
var template = isObject(withIndividualParticipants)
|
|
17658
|
+
? withIndividualParticipants
|
|
17659
|
+
: undefined;
|
|
17660
|
+
addIndividualParticipants({ participantMap: participantMap, template: template });
|
|
17661
|
+
}
|
|
17657
17662
|
return { participantMap: participantMap };
|
|
17658
17663
|
}
|
|
17659
17664
|
function signedIn(participant) {
|
|
@@ -17719,7 +17724,7 @@ function initializeParticipantId(_a) {
|
|
|
17719
17724
|
participantMap[participantId] = {
|
|
17720
17725
|
structureParticipation: {},
|
|
17721
17726
|
potentialMatchUps: {},
|
|
17722
|
-
scheduleConflicts:
|
|
17727
|
+
scheduleConflicts: {},
|
|
17723
17728
|
scheduleItems: [],
|
|
17724
17729
|
participant: {
|
|
17725
17730
|
groupParticipantIds: [],
|
|
@@ -30276,10 +30281,13 @@ function getParticipantEntries(params) {
|
|
|
30276
30281
|
timeStringMinutes(notBeforeTime);
|
|
30277
30282
|
// if there is a time overlap capture both the prior matchUpId and the conflicted matchUpId
|
|
30278
30283
|
if (timeOverlap && !(bothPotential && sameDraw) && itemIsPrior) {
|
|
30279
|
-
|
|
30284
|
+
var key = [scheduleItem.matchUpId, consideredItem.matchUpId]
|
|
30285
|
+
.sort()
|
|
30286
|
+
.join('|');
|
|
30287
|
+
participantAggregator.scheduleConflicts[key] = {
|
|
30280
30288
|
priorScheduledMatchUpId: scheduleItem.matchUpId,
|
|
30281
30289
|
matchUpIdWithConflict: consideredItem.matchUpId,
|
|
30282
|
-
}
|
|
30290
|
+
};
|
|
30283
30291
|
}
|
|
30284
30292
|
}
|
|
30285
30293
|
}
|
|
@@ -30300,7 +30308,7 @@ function getParticipantEntries(params) {
|
|
|
30300
30308
|
finally { if (e_9) throw e_9.error; }
|
|
30301
30309
|
}
|
|
30302
30310
|
var pid = participantAggregator.participant.participantId;
|
|
30303
|
-
if (participantAggregator.scheduleConflicts.length) {
|
|
30311
|
+
if (Object.keys(participantAggregator.scheduleConflicts).length) {
|
|
30304
30312
|
participantIdsWithConflicts.push(pid);
|
|
30305
30313
|
}
|
|
30306
30314
|
participantMap[pid].scheduleConflicts =
|
|
@@ -30555,7 +30563,9 @@ function getParticipants$1(params) {
|
|
|
30555
30563
|
draw.opponents = participantOpponents.filter(function (opponent) { return opponent.drawId === draw.drawId; });
|
|
30556
30564
|
});
|
|
30557
30565
|
}
|
|
30558
|
-
return definedAttributes(__assign(__assign({}, participant), { scheduleConflicts: scheduleAnalysis
|
|
30566
|
+
return definedAttributes(__assign(__assign({}, participant), { scheduleConflicts: scheduleAnalysis
|
|
30567
|
+
? Object.values(scheduleConflicts)
|
|
30568
|
+
: undefined, draws: withDraws || withRankingProfile ? participantDraws : undefined, events: withEvents || withRankingProfile ? Object.values(events) : undefined, matchUps: withMatchUps || withRankingProfile
|
|
30559
30569
|
? Object.values(matchUps)
|
|
30560
30570
|
: undefined, opponents: withOpponents ? participantOpponents : undefined, potentialMatchUps: nextMatchUps
|
|
30561
30571
|
? Object.values(potentialMatchUps)
|
|
@@ -30585,6 +30595,9 @@ function getParticipants$1(params) {
|
|
|
30585
30595
|
tournamentRecord: tournamentRecord,
|
|
30586
30596
|
});
|
|
30587
30597
|
if (withIndividualParticipants) {
|
|
30598
|
+
var template_1 = isObject(withIndividualParticipants)
|
|
30599
|
+
? withIndividualParticipants
|
|
30600
|
+
: undefined;
|
|
30588
30601
|
try {
|
|
30589
30602
|
for (var filteredParticipants_1 = __values(filteredParticipants), filteredParticipants_1_1 = filteredParticipants_1.next(); !filteredParticipants_1_1.done; filteredParticipants_1_1 = filteredParticipants_1.next()) {
|
|
30590
30603
|
var participant = filteredParticipants_1_1.value;
|
|
@@ -30593,7 +30606,8 @@ function getParticipants$1(params) {
|
|
|
30593
30606
|
var individualParticipantId = _j.value;
|
|
30594
30607
|
if (!participant.individualParticipants)
|
|
30595
30608
|
participant.individualParticipants = [];
|
|
30596
|
-
|
|
30609
|
+
var source = ppMap.get(individualParticipantId);
|
|
30610
|
+
participant.individualParticipants.push(template_1 ? attributeFilter({ template: template_1, source: source }) : source);
|
|
30597
30611
|
}
|
|
30598
30612
|
}
|
|
30599
30613
|
catch (e_3_1) { e_3 = { error: e_3_1 }; }
|
|
@@ -67806,6 +67820,7 @@ var lastNames = [
|
|
|
67806
67820
|
"Ampleforth",
|
|
67807
67821
|
"Atreides",
|
|
67808
67822
|
"Austen",
|
|
67823
|
+
"Bach",
|
|
67809
67824
|
"Banks",
|
|
67810
67825
|
"Barrington",
|
|
67811
67826
|
"Batty",
|
|
@@ -67836,6 +67851,7 @@ var lastNames = [
|
|
|
67836
67851
|
"Eisenstein",
|
|
67837
67852
|
"Eldritch",
|
|
67838
67853
|
"Elliot",
|
|
67854
|
+
"Escher",
|
|
67839
67855
|
"Eyre",
|
|
67840
67856
|
"Faulkner",
|
|
67841
67857
|
"Fukuoka",
|
|
@@ -68005,6 +68021,7 @@ var firstMale = [
|
|
|
68005
68021
|
"James",
|
|
68006
68022
|
"Jared",
|
|
68007
68023
|
"Joe",
|
|
68024
|
+
"Johann",
|
|
68008
68025
|
"Julian",
|
|
68009
68026
|
"John Michael",
|
|
68010
68027
|
"Jonathan",
|
|
@@ -68015,6 +68032,7 @@ var firstMale = [
|
|
|
68015
68032
|
"Malachi",
|
|
68016
68033
|
"Mark",
|
|
68017
68034
|
"Masanobu",
|
|
68035
|
+
"Maurits",
|
|
68018
68036
|
"Michael",
|
|
68019
68037
|
"Mustapha",
|
|
68020
68038
|
"Neil",
|