@smartico/public-api 0.0.328 → 0.0.330
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/Base/ClassId.d.ts +2 -2
- package/dist/Raffle/RaffleDraw.d.ts +8 -0
- package/dist/WSAPI/WSAPITypes.d.ts +8 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +21 -9
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +10 -6
- package/dist/index.modern.mjs.map +1 -1
- package/docs/interfaces/RaffleDraw.md +16 -0
- package/docs/interfaces/TRaffleDraw.md +16 -0
- package/docs/interfaces/TStoreItem.md +1 -1
- package/package.json +1 -1
- package/src/Base/ClassId.ts +2 -2
- package/src/Missions/MissionsUtils.ts +1 -1
- package/src/Raffle/GetDrawRunResponse.ts +3 -1
- package/src/Raffle/GetRafflesResponse.ts +2 -0
- package/src/Raffle/RaffleDraw.ts +8 -0
- package/src/WSAPI/WSAPITypes.ts +8 -0
- package/src/index.ts +1 -0
package/dist/Base/ClassId.d.ts
CHANGED
|
@@ -113,8 +113,8 @@ export declare enum ClassId {
|
|
|
113
113
|
RAF_GET_DRAW_HISTORY_RESPONSE = 907,
|
|
114
114
|
RAF_CLAIM_PRIZE_REQUEST = 908,
|
|
115
115
|
RAF_CLAIM_PRIZE_RESPONSE = 909,
|
|
116
|
-
RAF_OPTIN_REQUEST =
|
|
117
|
-
RAF_OPTIN_RESPONSE =
|
|
116
|
+
RAF_OPTIN_REQUEST = 916,
|
|
117
|
+
RAF_OPTIN_RESPONSE = 917,
|
|
118
118
|
REGISTER_PUSH_NOTIFICATIONS_TOKEN_REQ = 1003,
|
|
119
119
|
REGISTER_PUSH_NOTIFICATIONS_TOKEN_RESP = 2003,
|
|
120
120
|
CLIENT_DEBUG_REQUEST = 77777,
|
|
@@ -83,5 +83,13 @@ interface RaffleDraw {
|
|
|
83
83
|
* List of last 5 tickets are collected by current user for this instance of draw.
|
|
84
84
|
*/
|
|
85
85
|
my_last_tickets: RaffleTicket[];
|
|
86
|
+
/**
|
|
87
|
+
* If true, the user has opted-in to the raffle.
|
|
88
|
+
*/
|
|
89
|
+
user_opted_in: boolean;
|
|
90
|
+
/**
|
|
91
|
+
* If true, the user needs to opt-in to the raffle before they can participate.
|
|
92
|
+
*/
|
|
93
|
+
requires_optin: boolean;
|
|
86
94
|
}
|
|
87
95
|
export { RaffleDraw };
|
|
@@ -1130,6 +1130,14 @@ export interface TRaffleDraw {
|
|
|
1130
1130
|
*/
|
|
1131
1131
|
my_tickets_count: number;
|
|
1132
1132
|
my_last_tickets: TRaffleTicket[];
|
|
1133
|
+
/**
|
|
1134
|
+
* If true, the user has opted-in to the raffle.
|
|
1135
|
+
*/
|
|
1136
|
+
user_opted_in: boolean;
|
|
1137
|
+
/**
|
|
1138
|
+
* If true, the user needs to opt-in to the raffle before they can participate.
|
|
1139
|
+
*/
|
|
1140
|
+
requires_optin: boolean;
|
|
1133
1141
|
}
|
|
1134
1142
|
export interface TRaffleDrawRun {
|
|
1135
1143
|
/**
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -137,8 +137,8 @@ exports.ClassId = void 0;
|
|
|
137
137
|
ClassId[ClassId["RAF_GET_DRAW_HISTORY_RESPONSE"] = 907] = "RAF_GET_DRAW_HISTORY_RESPONSE";
|
|
138
138
|
ClassId[ClassId["RAF_CLAIM_PRIZE_REQUEST"] = 908] = "RAF_CLAIM_PRIZE_REQUEST";
|
|
139
139
|
ClassId[ClassId["RAF_CLAIM_PRIZE_RESPONSE"] = 909] = "RAF_CLAIM_PRIZE_RESPONSE";
|
|
140
|
-
ClassId[ClassId["RAF_OPTIN_REQUEST"] =
|
|
141
|
-
ClassId[ClassId["RAF_OPTIN_RESPONSE"] =
|
|
140
|
+
ClassId[ClassId["RAF_OPTIN_REQUEST"] = 916] = "RAF_OPTIN_REQUEST";
|
|
141
|
+
ClassId[ClassId["RAF_OPTIN_RESPONSE"] = 917] = "RAF_OPTIN_RESPONSE";
|
|
142
142
|
/*
|
|
143
143
|
RAF_GET_TICKETS_REQUEST = 902,
|
|
144
144
|
RAF_GET_TICKETS_RESPONSE = 903,
|
|
@@ -1352,7 +1352,7 @@ MissionUtils.replaceTagsFavMissionTask = function (_ref) {
|
|
|
1352
1352
|
suggestedGames = value.map(function (v) {
|
|
1353
1353
|
var cleaned = v.replace(/_/g, ' ').toLowerCase();
|
|
1354
1354
|
return cleaned.charAt(0).toUpperCase() + cleaned.slice(1);
|
|
1355
|
-
}).join('
|
|
1355
|
+
}).join(', ');
|
|
1356
1356
|
}
|
|
1357
1357
|
}
|
|
1358
1358
|
if (operatorsPos.includes(operator)) {
|
|
@@ -1966,7 +1966,9 @@ var drawTransform = function drawTransform(items) {
|
|
|
1966
1966
|
allow_multi_prize_per_ticket: item.allow_multi_prize_per_ticket,
|
|
1967
1967
|
total_tickets_count: item.total_tickets_count,
|
|
1968
1968
|
my_tickets_count: item.my_tickets_count,
|
|
1969
|
-
my_last_tickets: ticketsTransform(item.my_last_tickets)
|
|
1969
|
+
my_last_tickets: ticketsTransform(item.my_last_tickets),
|
|
1970
|
+
user_opted_in: Boolean(item.user_opted_in),
|
|
1971
|
+
requires_optin: Boolean(item.requires_optin)
|
|
1970
1972
|
};
|
|
1971
1973
|
});
|
|
1972
1974
|
};
|
|
@@ -2014,11 +2016,13 @@ var drawRunTransform = function drawRunTransform(res) {
|
|
|
2014
2016
|
allow_multi_prize_per_ticket: res.draw.allow_multi_prize_per_ticket,
|
|
2015
2017
|
total_tickets_count: res.draw.total_tickets_count,
|
|
2016
2018
|
my_tickets_count: res.draw.my_tickets_count,
|
|
2017
|
-
my_last_tickets: ticketsTransform(res.draw.my_last_tickets)
|
|
2019
|
+
my_last_tickets: ticketsTransform(res.draw.my_last_tickets),
|
|
2020
|
+
user_opted_in: Boolean(res.draw.user_opted_in),
|
|
2021
|
+
requires_optin: Boolean(res.draw.requires_optin)
|
|
2018
2022
|
};
|
|
2019
2023
|
};
|
|
2020
2024
|
|
|
2021
|
-
|
|
2025
|
+
exports.RaffleDrawInstanceState = void 0;
|
|
2022
2026
|
(function (RaffleDrawInstanceState) {
|
|
2023
2027
|
/** Draw is open for the tickets collection */
|
|
2024
2028
|
RaffleDrawInstanceState[RaffleDrawInstanceState["Open"] = 1] = "Open";
|
|
@@ -2026,8 +2030,8 @@ var RaffleDrawInstanceState;
|
|
|
2026
2030
|
RaffleDrawInstanceState[RaffleDrawInstanceState["WinnerSelection"] = 2] = "WinnerSelection";
|
|
2027
2031
|
/** Draw is executed and the winners are selected */
|
|
2028
2032
|
RaffleDrawInstanceState[RaffleDrawInstanceState["Executed"] = 3] = "Executed";
|
|
2029
|
-
})(RaffleDrawInstanceState || (RaffleDrawInstanceState = {}));
|
|
2030
|
-
|
|
2033
|
+
})(exports.RaffleDrawInstanceState || (exports.RaffleDrawInstanceState = {}));
|
|
2034
|
+
exports.RaffleDrawTypeExecution = void 0;
|
|
2031
2035
|
(function (RaffleDrawTypeExecution) {
|
|
2032
2036
|
/** Draw is executed only once */
|
|
2033
2037
|
RaffleDrawTypeExecution[RaffleDrawTypeExecution["ExecDate"] = 0] = "ExecDate";
|
|
@@ -2039,7 +2043,7 @@ var RaffleDrawTypeExecution;
|
|
|
2039
2043
|
* often with larger prizes or more importance.
|
|
2040
2044
|
*/
|
|
2041
2045
|
RaffleDrawTypeExecution[RaffleDrawTypeExecution["Grand"] = 2] = "Grand";
|
|
2042
|
-
})(RaffleDrawTypeExecution || (RaffleDrawTypeExecution = {}));
|
|
2046
|
+
})(exports.RaffleDrawTypeExecution || (exports.RaffleDrawTypeExecution = {}));
|
|
2043
2047
|
|
|
2044
2048
|
/** @hidden */
|
|
2045
2049
|
var drawRunHistoryTransform = function drawRunHistoryTransform(res) {
|
|
@@ -5739,9 +5743,13 @@ exports.TournamentRegistrationTypeGetName = TournamentRegistrationTypeGetName;
|
|
|
5739
5743
|
exports.TournamentUtils = TournamentUtils;
|
|
5740
5744
|
exports.UICustomSectionTransform = UICustomSectionTransform;
|
|
5741
5745
|
exports.UserAchievementTransform = UserAchievementTransform;
|
|
5746
|
+
exports.drawRunHistoryTransform = drawRunHistoryTransform;
|
|
5747
|
+
exports.drawRunTransform = drawRunTransform;
|
|
5748
|
+
exports.drawTransform = drawTransform;
|
|
5742
5749
|
exports.enrichUserAchievementsWithBadgeState = enrichUserAchievementsWithBadgeState;
|
|
5743
5750
|
exports.getLeaderBoardTransform = getLeaderBoardTransform;
|
|
5744
5751
|
exports.marketsInfo = marketsInfo;
|
|
5752
|
+
exports.prizeTransform = prizeTransform;
|
|
5745
5753
|
exports.quizAnswerAwayTeamReplacementText = quizAnswerAwayTeamReplacementText;
|
|
5746
5754
|
exports.quizAnswerHomeTeamReplacementText = quizAnswerHomeTeamReplacementText;
|
|
5747
5755
|
exports.quizAnswersTrKeys = quizAnswersTrKeys;
|
|
@@ -5753,5 +5761,9 @@ exports.quizOddReplacementText = quizOddReplacementText;
|
|
|
5753
5761
|
exports.quizOrReplacementText = quizOrReplacementText;
|
|
5754
5762
|
exports.quizSupportedSports = quizSupportedSports;
|
|
5755
5763
|
exports.quizYesReplacementText = quizYesReplacementText;
|
|
5764
|
+
exports.raffleClaimPrizeResponseTransform = raffleClaimPrizeResponseTransform;
|
|
5765
|
+
exports.raffleTransform = raffleTransform;
|
|
5766
|
+
exports.ticketsTransform = ticketsTransform;
|
|
5756
5767
|
exports.tournamentInfoItemTransform = tournamentInfoItemTransform;
|
|
5768
|
+
exports.winnersTransform = winnersTransform;
|
|
5757
5769
|
//# sourceMappingURL=index.js.map
|