@smartico/public-api 0.0.142 → 0.0.144
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/README.md +14 -1
- package/dist/CustomSections/AchCustomSection.d.ts +27 -0
- package/dist/CustomSections/GetCustomSectionsRequest.d.ts +3 -0
- package/dist/CustomSections/GetCustomSectionsResponse.d.ts +7 -0
- package/dist/CustomSections/UICustomSection.d.ts +15 -0
- package/dist/CustomSections/index.d.ts +4 -0
- package/dist/Missions/AchievementPublicMeta.d.ts +1 -0
- package/dist/Missions/UserAchievement.d.ts +1 -0
- package/dist/Quiz/MarketsAnswers.d.ts +38 -0
- package/dist/Quiz/MarketsInfo.d.ts +4 -12
- package/dist/Quiz/MarketsPerSport.d.ts +4 -4
- package/dist/Quiz/MarketsType.d.ts +1 -1
- package/dist/Quiz/index.d.ts +1 -1
- package/dist/SmarticoAPI.d.ts +4 -1
- package/dist/WSAPI/WSAPI.d.ts +22 -1
- package/dist/WSAPI/WSAPITypes.d.ts +25 -0
- package/dist/index.js +310 -203
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +199 -109
- package/dist/index.modern.mjs.map +1 -1
- package/docs/README.md +1 -0
- package/docs/classes/WSAPI.md +28 -0
- package/docs/interfaces/TMissionOrBadge.md +8 -0
- package/docs/interfaces/TUICustomSection.md +81 -0
- package/package.json +1 -1
- package/src/Core/CoreUtils.ts +2 -2
- package/src/CustomSections/AchCustomSection.ts +30 -0
- package/src/CustomSections/GetCustomSectionsRequest.ts +5 -0
- package/src/CustomSections/GetCustomSectionsResponse.ts +7 -0
- package/src/CustomSections/UICustomSection.ts +34 -0
- package/src/CustomSections/index.ts +4 -0
- package/src/Missions/AchievementPublicMeta.ts +1 -0
- package/src/Missions/UserAchievement.ts +3 -1
- package/src/Quiz/MarketsAnswers.ts +40 -0
- package/src/Quiz/MarketsInfo.ts +50 -59
- package/src/Quiz/MarketsPerSport.ts +29 -29
- package/src/Quiz/MarketsType.ts +1 -1
- package/src/Quiz/index.ts +1 -1
- package/src/SmarticoAPI.ts +12 -2
- package/src/WSAPI/WSAPI.ts +26 -1
- package/src/WSAPI/WSAPITypes.ts +27 -0
- package/src/Quiz/MarketsAnswersType.ts +0 -22
package/docs/README.md
CHANGED
|
@@ -56,6 +56,7 @@
|
|
|
56
56
|
- [LeaderBoardUserT](interfaces/LeaderBoardUserT.md)
|
|
57
57
|
- [UserLevelExtraCountersT](interfaces/UserLevelExtraCountersT.md)
|
|
58
58
|
- [TSegmentCheckResult](interfaces/TSegmentCheckResult.md)
|
|
59
|
+
- [TUICustomSection](interfaces/TUICustomSection.md)
|
|
59
60
|
|
|
60
61
|
## General API
|
|
61
62
|
|
package/docs/classes/WSAPI.md
CHANGED
|
@@ -189,6 +189,7 @@ _smartico.api.getStoreItems().then((result) => {
|
|
|
189
189
|
_smartico.vapi('EN').getStoreItems().then((result) => {
|
|
190
190
|
console.log(result);
|
|
191
191
|
});
|
|
192
|
+
```
|
|
192
193
|
|
|
193
194
|
#### Returns
|
|
194
195
|
|
|
@@ -240,6 +241,7 @@ _smartico.api.getStoreCategories().then((result) => {
|
|
|
240
241
|
_smartico.vapi('EN').getStoreCategories().then((result) => {
|
|
241
242
|
console.log(result);
|
|
242
243
|
});
|
|
244
|
+
```
|
|
243
245
|
|
|
244
246
|
#### Returns
|
|
245
247
|
|
|
@@ -305,6 +307,32 @@ _smartico.vapi('EN').getAchCategories().then((result) => {
|
|
|
305
307
|
|
|
306
308
|
___
|
|
307
309
|
|
|
310
|
+
### getCustomSections
|
|
311
|
+
|
|
312
|
+
▸ **getCustomSections**(): `Promise`<[`TUICustomSection`](../interfaces/TUICustomSection.md)[]\>
|
|
313
|
+
|
|
314
|
+
Returns list of custom sections
|
|
315
|
+
|
|
316
|
+
**Example**:
|
|
317
|
+
```
|
|
318
|
+
_smartico.api.getCustomSections().then((result) => {
|
|
319
|
+
console.log(result);
|
|
320
|
+
});
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
**Example in the Visitor mode**:
|
|
324
|
+
```
|
|
325
|
+
_smartico.vapi('EN').getCustomSections().then((result) => {
|
|
326
|
+
console.log(result);
|
|
327
|
+
});
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
#### Returns
|
|
331
|
+
|
|
332
|
+
`Promise`<[`TUICustomSection`](../interfaces/TUICustomSection.md)[]\>
|
|
333
|
+
|
|
334
|
+
___
|
|
335
|
+
|
|
308
336
|
### getMiniGames
|
|
309
337
|
|
|
310
338
|
▸ **getMiniGames**(`«destructured»?`): `Promise`<[`TMiniGameTemplate`](../interfaces/TMiniGameTemplate.md)[]\>
|
|
@@ -269,3 +269,11 @@ ___
|
|
|
269
269
|
• `Optional` **completed\_this\_month**: `boolean`
|
|
270
270
|
|
|
271
271
|
Flag for mission/badge indicating that mission/badge completed this month
|
|
272
|
+
|
|
273
|
+
___
|
|
274
|
+
|
|
275
|
+
### custom\_section\_type\_id
|
|
276
|
+
|
|
277
|
+
• `Optional` **custom\_section\_type\_id**: `number`
|
|
278
|
+
|
|
279
|
+
ID of specific Custom Section type
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
# Interface: TUICustomSection
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
### body
|
|
6
|
+
|
|
7
|
+
• `Optional` **body**: `string`
|
|
8
|
+
|
|
9
|
+
The body of the custom section
|
|
10
|
+
|
|
11
|
+
___
|
|
12
|
+
|
|
13
|
+
### menu\_img
|
|
14
|
+
|
|
15
|
+
• `Optional` **menu\_img**: `string`
|
|
16
|
+
|
|
17
|
+
The image of the custom section
|
|
18
|
+
|
|
19
|
+
___
|
|
20
|
+
|
|
21
|
+
### menu\_name
|
|
22
|
+
|
|
23
|
+
• `Optional` **menu\_name**: `string`
|
|
24
|
+
|
|
25
|
+
The name of the custom section
|
|
26
|
+
|
|
27
|
+
___
|
|
28
|
+
|
|
29
|
+
### custom\_skin\_images
|
|
30
|
+
|
|
31
|
+
• `Optional` **custom\_skin\_images**: `string`
|
|
32
|
+
|
|
33
|
+
Custom images for custom section
|
|
34
|
+
|
|
35
|
+
___
|
|
36
|
+
|
|
37
|
+
### section\_type\_id
|
|
38
|
+
|
|
39
|
+
• `Optional` **section\_type\_id**: `AchCustomSectionType`
|
|
40
|
+
|
|
41
|
+
The particular type of custom section, can be Missions, Tournaments, Lootbox and etc
|
|
42
|
+
|
|
43
|
+
___
|
|
44
|
+
|
|
45
|
+
### theme
|
|
46
|
+
|
|
47
|
+
• `Optional` **theme**: `AchCustomLayoutTheme`
|
|
48
|
+
|
|
49
|
+
Theme of the custom section
|
|
50
|
+
|
|
51
|
+
___
|
|
52
|
+
|
|
53
|
+
### generic\_custom\_css
|
|
54
|
+
|
|
55
|
+
• `Optional` **generic\_custom\_css**: `string`
|
|
56
|
+
|
|
57
|
+
Custom css for the custom section
|
|
58
|
+
|
|
59
|
+
___
|
|
60
|
+
|
|
61
|
+
### mission\_tabs\_options
|
|
62
|
+
|
|
63
|
+
• `Optional` **mission\_tabs\_options**: `AchMissionsTabsOptions`
|
|
64
|
+
|
|
65
|
+
Tabs that can be shown in custom section, e.g Overview, No Overview, All tabs
|
|
66
|
+
|
|
67
|
+
___
|
|
68
|
+
|
|
69
|
+
### overview\_missions\_filter
|
|
70
|
+
|
|
71
|
+
• `Optional` **overview\_missions\_filter**: `AchOverviewMissionsFilter`
|
|
72
|
+
|
|
73
|
+
Filter that allow to show missions by criteria
|
|
74
|
+
|
|
75
|
+
___
|
|
76
|
+
|
|
77
|
+
### overview\_missions\_count
|
|
78
|
+
|
|
79
|
+
• `Optional` **overview\_missions\_count**: `number`
|
|
80
|
+
|
|
81
|
+
Quantity of missions to be shown in overview
|
package/package.json
CHANGED
package/src/Core/CoreUtils.ts
CHANGED
|
@@ -15,7 +15,7 @@ class CoreUtils {
|
|
|
15
15
|
|
|
16
16
|
public static currencySymbol(currency: string) {
|
|
17
17
|
return {
|
|
18
|
-
[currency
|
|
18
|
+
[currency?.toUpperCase()]: currency?.toUpperCase(),
|
|
19
19
|
USD: "$", // United States Dollar
|
|
20
20
|
EUR: "€", // Euro
|
|
21
21
|
JPY: "¥", // Japanese Yen
|
|
@@ -36,7 +36,7 @@ class CoreUtils {
|
|
|
36
36
|
RUB: "₽", // Russian Ruble
|
|
37
37
|
BRL: "R$", // Brazilian Real
|
|
38
38
|
ZAR: "R", // South African Rand
|
|
39
|
-
}[currency
|
|
39
|
+
}[currency?.toUpperCase()];
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export enum AchCustomSectionType {
|
|
2
|
+
HTML_PAGE = 1,
|
|
3
|
+
MISSIONS_CATEGORY = 2,
|
|
4
|
+
TOURNAMENTS_CATEGORY = 3,
|
|
5
|
+
LEVELS = 4,
|
|
6
|
+
MINI_GAMES = 5,
|
|
7
|
+
MISSION_CUSTOM_LAYOUT = 6,
|
|
8
|
+
MATCH_X = 7,
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export enum AchCustomLayoutTheme {
|
|
12
|
+
VALENTINES_LIGHT = 'valentines-light',
|
|
13
|
+
VALENTINES_DARK = 'valentines-dark',
|
|
14
|
+
EURO_2024 = 'euro-2024',
|
|
15
|
+
GENERIC = 'generic',
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export enum AchMissionsTabsOptions {
|
|
19
|
+
ONLY_OVERVIEW = 1,
|
|
20
|
+
NO_OVERVIEW = 2,
|
|
21
|
+
ALL = 3,
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export enum AchOverviewMissionsFilter {
|
|
25
|
+
ANY = 1,
|
|
26
|
+
ALL_MISSIONS = 2,
|
|
27
|
+
ALL_EXCEPT_COMPLETED = 3,
|
|
28
|
+
ALL_EXCEPT_LOCKED = 4,
|
|
29
|
+
ALL_EXCEPT_COMPLETED_AND_LOCKED = 5,
|
|
30
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { TUICustomSection } from "../WSAPI/WSAPITypes";
|
|
2
|
+
import { AchCustomLayoutTheme, AchCustomSectionType, AchMissionsTabsOptions, AchOverviewMissionsFilter } from "./AchCustomSection";
|
|
3
|
+
|
|
4
|
+
export interface UICustomSection {
|
|
5
|
+
|
|
6
|
+
body?: string;
|
|
7
|
+
menu_img?: string;
|
|
8
|
+
menu_name?: string;
|
|
9
|
+
custom_skin_images?: string;
|
|
10
|
+
section_type_id?: AchCustomSectionType;
|
|
11
|
+
theme?: AchCustomLayoutTheme;
|
|
12
|
+
generic_custom_css?: string;
|
|
13
|
+
mission_tabs_options?: AchMissionsTabsOptions;
|
|
14
|
+
overview_missions_filter?: AchOverviewMissionsFilter;
|
|
15
|
+
overview_missions_count?: number;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export const UICustomSectionTransform = (items: UICustomSection[]): TUICustomSection[] => {
|
|
19
|
+
return items.filter(r => r.section_type_id !== undefined && r.section_type_id >= 1).map( r => {
|
|
20
|
+
const x: TUICustomSection = {
|
|
21
|
+
body: r.body,
|
|
22
|
+
menu_img: r.menu_img,
|
|
23
|
+
menu_name: r.menu_name,
|
|
24
|
+
section_type_id: r.section_type_id,
|
|
25
|
+
custom_skin_images: r.custom_skin_images,
|
|
26
|
+
generic_custom_css: r.generic_custom_css,
|
|
27
|
+
mission_tabs_options: r.mission_tabs_options,
|
|
28
|
+
overview_missions_count: r.overview_missions_count,
|
|
29
|
+
overview_missions_filter: r.overview_missions_filter,
|
|
30
|
+
theme: r.theme
|
|
31
|
+
}
|
|
32
|
+
return x;
|
|
33
|
+
})
|
|
34
|
+
}
|
|
@@ -41,6 +41,7 @@ export interface UserAchievement {
|
|
|
41
41
|
completed_today?: boolean;
|
|
42
42
|
completed_this_week?: boolean;
|
|
43
43
|
completed_this_month?: boolean;
|
|
44
|
+
custom_section_type_id?: number;
|
|
44
45
|
}
|
|
45
46
|
|
|
46
47
|
|
|
@@ -103,7 +104,8 @@ export const UserAchievementTransform = (items: UserAchievement[]): TMissionOrBa
|
|
|
103
104
|
complete_date_ts: r.complete_date_ts,
|
|
104
105
|
completed_today: completedToday,
|
|
105
106
|
completed_this_week: completedThisWeek,
|
|
106
|
-
completed_this_month: completedThisMonth
|
|
107
|
+
completed_this_month: completedThisMonth,
|
|
108
|
+
custom_section_type_id: r.ach_public_meta.custom_section_type_id,
|
|
107
109
|
}
|
|
108
110
|
return x;
|
|
109
111
|
});
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export enum QuizAnswersValueType {
|
|
2
|
+
HomeTeam = '1',
|
|
3
|
+
AwayTeam = '2',
|
|
4
|
+
Draw = 'x',
|
|
5
|
+
HomeTeamHomeTeam = '1/1',
|
|
6
|
+
HomeTeamDraw = '1/x',
|
|
7
|
+
HomeTeamAwayTeam = '1/2',
|
|
8
|
+
DrawHomeTeam = 'x/1',
|
|
9
|
+
DrawDraw = 'x/x',
|
|
10
|
+
DrawAwayTeam = 'x/2',
|
|
11
|
+
AwayTeamHomeTeam = '2/1',
|
|
12
|
+
AwayTeamDraw = '2/x',
|
|
13
|
+
AwayTeamAwayTeam = '2/2',
|
|
14
|
+
Yes = 'yes',
|
|
15
|
+
No = 'no',
|
|
16
|
+
Odd = 'odd',
|
|
17
|
+
Even = 'even',
|
|
18
|
+
HomeOdd = '1/odd',
|
|
19
|
+
HomeEven = '1/even',
|
|
20
|
+
AwayOdd = '2/odd',
|
|
21
|
+
AwayEven = '2/even',
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export const quizAnswerHomeTeamReplacementText = '{quiz_home_team}';
|
|
25
|
+
export const quizAnswerAwayTeamReplacementText = '{quiz_away_team}';
|
|
26
|
+
export const quizDrawReplacementText = '{quiz_draw}';
|
|
27
|
+
export const quizYesReplacementText = '{yes}';
|
|
28
|
+
export const quizNoReplacementText = '{no}';
|
|
29
|
+
export const quizOddReplacementText = '{odd}';
|
|
30
|
+
export const quizEvenReplacementText = '{even}';
|
|
31
|
+
export const quizOrReplacementText = '{or}';
|
|
32
|
+
|
|
33
|
+
export const quizAnswersTrKeys = {
|
|
34
|
+
[quizDrawReplacementText]: 'quizAnswer_draw',
|
|
35
|
+
[quizYesReplacementText]: 'quizAnswer_yes',
|
|
36
|
+
[quizNoReplacementText]: 'quizAnswer_no',
|
|
37
|
+
[quizOddReplacementText]: 'quizAnswer_odd',
|
|
38
|
+
[quizEvenReplacementText]: 'quizAnswer_even',
|
|
39
|
+
[quizOrReplacementText]: 'quizAnswer_or',
|
|
40
|
+
}
|
package/src/Quiz/MarketsInfo.ts
CHANGED
|
@@ -1,193 +1,184 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export const quizAnswerHomeTeamReplacementText = '{quiz_home_team}';
|
|
5
|
-
export const quizAnswerAwayTeamReplacementText = '{quiz_away_team}';
|
|
6
|
-
export const quizDrawReplacementText = '{quiz_draw}';
|
|
7
|
-
export const quizYesReplacementText = '{yes}';
|
|
8
|
-
export const quizNoReplacementText = '{no}';
|
|
9
|
-
export const quizOddReplacementText = '{odd}';
|
|
10
|
-
export const quizEvenReplacementText = '{even}';
|
|
11
|
-
export const quizOrReplacementText = '{or}';
|
|
1
|
+
import { QuizAnswersValueType, quizAnswerAwayTeamReplacementText, quizAnswerHomeTeamReplacementText, quizDrawReplacementText, quizEvenReplacementText, quizNoReplacementText, quizOddReplacementText, quizOrReplacementText, quizYesReplacementText } from "./MarketsAnswers";
|
|
2
|
+
import { SAWGPMarketType } from "./MarketsType";
|
|
12
3
|
|
|
13
4
|
const yesNoAnswers = [
|
|
14
|
-
{ text: quizYesReplacementText, value:
|
|
15
|
-
{ text: quizNoReplacementText, value:
|
|
5
|
+
{ text: quizYesReplacementText, value: QuizAnswersValueType.Yes },
|
|
6
|
+
{ text: quizNoReplacementText, value: QuizAnswersValueType.No }
|
|
16
7
|
]
|
|
17
8
|
|
|
18
9
|
const homeAwayAnswers = [
|
|
19
|
-
{ text: quizAnswerHomeTeamReplacementText, value:
|
|
20
|
-
{ text: quizAnswerAwayTeamReplacementText, value:
|
|
10
|
+
{ text: quizAnswerHomeTeamReplacementText, value: QuizAnswersValueType.HomeTeam },
|
|
11
|
+
{ text: quizAnswerAwayTeamReplacementText, value: QuizAnswersValueType.AwayTeam }
|
|
21
12
|
]
|
|
22
13
|
|
|
23
14
|
const homeAwayDrawAnswers = [
|
|
24
15
|
...homeAwayAnswers,
|
|
25
|
-
{ text: quizDrawReplacementText, value:
|
|
16
|
+
{ text: quizDrawReplacementText, value: QuizAnswersValueType.Draw },
|
|
26
17
|
]
|
|
27
18
|
|
|
28
19
|
export const marketsInfo = [
|
|
29
20
|
{
|
|
30
|
-
type:
|
|
21
|
+
type: SAWGPMarketType.OneXTwo,
|
|
31
22
|
name: '1x2',
|
|
32
23
|
question: { text: 'Who will win the match ?', trKey: 'quizQuestion_1x2'},
|
|
33
24
|
answers: homeAwayDrawAnswers
|
|
34
25
|
},
|
|
35
26
|
{
|
|
36
|
-
type:
|
|
27
|
+
type: SAWGPMarketType.OneXTwoHalftime,
|
|
37
28
|
name: '1x2 Halftime',
|
|
38
29
|
question: { text: 'Who will lead the first half of the match ?', trKey: 'quizQuestion_x2half' },
|
|
39
30
|
answers: homeAwayDrawAnswers
|
|
40
31
|
},
|
|
41
32
|
{
|
|
42
|
-
type:
|
|
33
|
+
type: SAWGPMarketType.HalftimeFulltime,
|
|
43
34
|
name: 'Halftime / Fulltime',
|
|
44
35
|
question: { text: 'Who will lead the first half and who will win the match ?', trKey: 'quizQuestion__HalftimeFulltime' },
|
|
45
36
|
answers: [
|
|
46
|
-
{ text: `${quizAnswerHomeTeamReplacementText} / ${quizAnswerHomeTeamReplacementText}`, value:
|
|
47
|
-
{ text: `${quizAnswerHomeTeamReplacementText} / ${quizDrawReplacementText}`, value:
|
|
48
|
-
{ text: `${quizAnswerHomeTeamReplacementText} / ${quizAnswerAwayTeamReplacementText}`, value:
|
|
49
|
-
{ text: `${quizDrawReplacementText} / ${quizAnswerHomeTeamReplacementText}`, value:
|
|
50
|
-
{ text: `${quizDrawReplacementText} / ${quizDrawReplacementText}`, value:
|
|
51
|
-
{ text: `${quizDrawReplacementText} / ${quizAnswerAwayTeamReplacementText}`, value:
|
|
52
|
-
{ text: `${quizAnswerAwayTeamReplacementText} / ${quizAnswerHomeTeamReplacementText}`, value:
|
|
53
|
-
{ text: `${quizAnswerAwayTeamReplacementText} / ${quizDrawReplacementText}`, value:
|
|
54
|
-
{ text: `${quizAnswerAwayTeamReplacementText} / ${quizAnswerAwayTeamReplacementText}`, value:
|
|
37
|
+
{ text: `${quizAnswerHomeTeamReplacementText} / ${quizAnswerHomeTeamReplacementText}`, value: QuizAnswersValueType.HomeTeamHomeTeam },
|
|
38
|
+
{ text: `${quizAnswerHomeTeamReplacementText} / ${quizDrawReplacementText}`, value: QuizAnswersValueType.HomeTeamDraw },
|
|
39
|
+
{ text: `${quizAnswerHomeTeamReplacementText} / ${quizAnswerAwayTeamReplacementText}`, value: QuizAnswersValueType.HomeTeamAwayTeam },
|
|
40
|
+
{ text: `${quizDrawReplacementText} / ${quizAnswerHomeTeamReplacementText}`, value: QuizAnswersValueType.DrawHomeTeam },
|
|
41
|
+
{ text: `${quizDrawReplacementText} / ${quizDrawReplacementText}`, value: QuizAnswersValueType.DrawDraw },
|
|
42
|
+
{ text: `${quizDrawReplacementText} / ${quizAnswerAwayTeamReplacementText}`, value: QuizAnswersValueType.DrawAwayTeam },
|
|
43
|
+
{ text: `${quizAnswerAwayTeamReplacementText} / ${quizAnswerHomeTeamReplacementText}`, value: QuizAnswersValueType.AwayTeamHomeTeam },
|
|
44
|
+
{ text: `${quizAnswerAwayTeamReplacementText} / ${quizDrawReplacementText}`, value: QuizAnswersValueType.AwayTeamDraw },
|
|
45
|
+
{ text: `${quizAnswerAwayTeamReplacementText} / ${quizAnswerAwayTeamReplacementText}`, value: QuizAnswersValueType.AwayTeamAwayTeam }
|
|
55
46
|
]
|
|
56
47
|
},
|
|
57
48
|
{
|
|
58
|
-
type:
|
|
49
|
+
type: SAWGPMarketType.FirstGoal,
|
|
59
50
|
name: 'First Goal',
|
|
60
51
|
question: { text: 'Who will score the first goal ?', trKey: 'quizQuestion_firstGoal' },
|
|
61
52
|
answers: homeAwayDrawAnswers
|
|
62
53
|
},
|
|
63
54
|
{
|
|
64
|
-
type:
|
|
55
|
+
type: SAWGPMarketType.LastGoal,
|
|
65
56
|
name: 'Last Goal',
|
|
66
57
|
question: { text: 'Who will score the last goal ?', trKey: 'quizQuestion_lastGoal' },
|
|
67
58
|
answers: homeAwayAnswers
|
|
68
59
|
},
|
|
69
60
|
{
|
|
70
|
-
type:
|
|
61
|
+
type: SAWGPMarketType.DoubleChance,
|
|
71
62
|
name: 'Double Chance',
|
|
72
|
-
question: { text: 'Who will win the match? Choose a combination:
|
|
63
|
+
question: { text: 'Who will win the match? Choose a combination:', trKey: 'quizQuestion_doubleChance' },
|
|
73
64
|
answers: [
|
|
74
|
-
{ text: `${quizDrawReplacementText} ${quizOrReplacementText} ${quizAnswerHomeTeamReplacementText}`, value:
|
|
75
|
-
{ text: `${quizAnswerHomeTeamReplacementText} ${quizOrReplacementText} ${quizAnswerAwayTeamReplacementText}`, value:
|
|
76
|
-
{ text: `${quizDrawReplacementText} ${quizOrReplacementText} ${quizAnswerAwayTeamReplacementText}`, value:
|
|
65
|
+
{ text: `${quizDrawReplacementText} ${quizOrReplacementText} ${quizAnswerHomeTeamReplacementText}`, value: QuizAnswersValueType.HomeTeamDraw },
|
|
66
|
+
{ text: `${quizAnswerHomeTeamReplacementText} ${quizOrReplacementText} ${quizAnswerAwayTeamReplacementText}`, value: QuizAnswersValueType.HomeTeamAwayTeam },
|
|
67
|
+
{ text: `${quizDrawReplacementText} ${quizOrReplacementText} ${quizAnswerAwayTeamReplacementText}`, value: QuizAnswersValueType.AwayTeamDraw }
|
|
77
68
|
]
|
|
78
69
|
},
|
|
79
70
|
{
|
|
80
|
-
type:
|
|
71
|
+
type: SAWGPMarketType.OverUnder2_5,
|
|
81
72
|
name: 'Over/Under 2.5',
|
|
82
73
|
question: { text: 'Will there be 3 or more goals in the match?', trKey: 'quizQuestion_overUnder2_5' },
|
|
83
74
|
answers: yesNoAnswers
|
|
84
75
|
},
|
|
85
76
|
{
|
|
86
|
-
type:
|
|
77
|
+
type: SAWGPMarketType.OverUnder1_5Halftime,
|
|
87
78
|
name: 'Over/Under 1.5 Halftime',
|
|
88
79
|
question: { text: 'Will there be 2 or more goals in the first half?', trKey: 'quizQuestion_overUnder1_5Halftime' },
|
|
89
80
|
answers: yesNoAnswers
|
|
90
81
|
},
|
|
91
82
|
{
|
|
92
|
-
type:
|
|
83
|
+
type: SAWGPMarketType.OverUnder1_5__2ndHalf,
|
|
93
84
|
name: 'Over/Under 1.5 2nd Half',
|
|
94
85
|
question: { text: 'Will there be 2 or more goals in the second half?', trKey: 'quizQuestion_overUnder1_5__2ndHalf' },
|
|
95
86
|
answers: yesNoAnswers
|
|
96
87
|
},
|
|
97
88
|
{
|
|
98
|
-
type:
|
|
89
|
+
type: SAWGPMarketType.RedCard,
|
|
99
90
|
name: 'Red Card',
|
|
100
91
|
question: { text: 'Will there be a red card in the match?', trKey: 'quizQuestion_redCard' },
|
|
101
92
|
answers: yesNoAnswers
|
|
102
93
|
},
|
|
103
94
|
{
|
|
104
|
-
type:
|
|
95
|
+
type: SAWGPMarketType.TotalCorners8_5,
|
|
105
96
|
name: 'Total Corners 8.5',
|
|
106
97
|
question: { text: 'Will there be 9 or more corners in the match?', trKey: 'quizQuestion_totalCorners8_5' },
|
|
107
98
|
answers: yesNoAnswers
|
|
108
99
|
},
|
|
109
100
|
{
|
|
110
|
-
type:
|
|
101
|
+
type: SAWGPMarketType.TotalCorners9_5,
|
|
111
102
|
name: 'Total Corners 9.5',
|
|
112
103
|
question: { text: 'Will there be 10 or more corners in the match?', trKey: 'quizQuestion_totalCorners9_5' },
|
|
113
104
|
answers: yesNoAnswers
|
|
114
105
|
},
|
|
115
106
|
{
|
|
116
|
-
type:
|
|
107
|
+
type: SAWGPMarketType.Corners1x2,
|
|
117
108
|
name: 'Corners 1x2',
|
|
118
109
|
question: { text: 'Which team will have more corners in the match?', trKey: 'quizQuestion_corners1x2' },
|
|
119
110
|
answers: homeAwayAnswers
|
|
120
111
|
},
|
|
121
112
|
{
|
|
122
|
-
type:
|
|
113
|
+
type: SAWGPMarketType.One_Two,
|
|
123
114
|
name: '1-2',
|
|
124
115
|
question: { text: 'Who will win the match ?', trKey: 'quizQuestion_1-2'},
|
|
125
116
|
answers: homeAwayAnswers
|
|
126
117
|
},
|
|
127
118
|
{
|
|
128
|
-
type:
|
|
119
|
+
type: SAWGPMarketType.Overtime,
|
|
129
120
|
name: 'Overtime',
|
|
130
121
|
question: { text: 'Will there be overtime in the match?', trKey: 'quizQuestion_overtime' },
|
|
131
122
|
answers: yesNoAnswers
|
|
132
123
|
},
|
|
133
124
|
{
|
|
134
|
-
type:
|
|
125
|
+
type: SAWGPMarketType.OddEven,
|
|
135
126
|
name: 'Odd/Even',
|
|
136
127
|
question: { text: 'Is the sum of all points scored in the game going to be an odd number or even?', trKey: 'quizQuestion_oddEven' },
|
|
137
128
|
answers: [
|
|
138
|
-
{ text: quizOddReplacementText, value:
|
|
139
|
-
{ text: quizEvenReplacementText, value:
|
|
129
|
+
{ text: quizOddReplacementText, value: QuizAnswersValueType.Odd },
|
|
130
|
+
{ text: quizEvenReplacementText, value: QuizAnswersValueType.Even }
|
|
140
131
|
]
|
|
141
132
|
},
|
|
142
133
|
{
|
|
143
|
-
type:
|
|
134
|
+
type: SAWGPMarketType.OddEvenHomeAway,
|
|
144
135
|
name: 'Odd/Even Home/Away',
|
|
145
136
|
question: { text: 'Which team will win and what will be the sum of the points (Odd or Even)?', trKey: 'quizQuestion_oddEvenHomeAway' },
|
|
146
137
|
answers: [
|
|
147
|
-
{ text: `${quizAnswerHomeTeamReplacementText} - ${quizOddReplacementText}`, value:
|
|
148
|
-
{ text: `${quizAnswerHomeTeamReplacementText} - ${quizEvenReplacementText}`, value:
|
|
149
|
-
{ text: `${quizAnswerAwayTeamReplacementText} - ${quizOddReplacementText}`, value:
|
|
150
|
-
{ text: `${quizAnswerAwayTeamReplacementText} - ${quizEvenReplacementText}`, value:
|
|
138
|
+
{ text: `${quizAnswerHomeTeamReplacementText} - ${quizOddReplacementText}`, value: QuizAnswersValueType.HomeOdd },
|
|
139
|
+
{ text: `${quizAnswerHomeTeamReplacementText} - ${quizEvenReplacementText}`, value: QuizAnswersValueType.HomeEven },
|
|
140
|
+
{ text: `${quizAnswerAwayTeamReplacementText} - ${quizOddReplacementText}`, value: QuizAnswersValueType.AwayOdd },
|
|
141
|
+
{ text: `${quizAnswerAwayTeamReplacementText} - ${quizEvenReplacementText}`, value: QuizAnswersValueType.AwayEven }
|
|
151
142
|
]
|
|
152
143
|
},
|
|
153
144
|
{
|
|
154
|
-
type:
|
|
145
|
+
type: SAWGPMarketType.FirstSet,
|
|
155
146
|
name: 'First Set',
|
|
156
147
|
question: { text: 'Who will win the first set ?', trKey: 'quizQuestion_firstSet' },
|
|
157
148
|
answers: homeAwayAnswers
|
|
158
149
|
},
|
|
159
150
|
{
|
|
160
|
-
type:
|
|
151
|
+
type: SAWGPMarketType.SecondSet,
|
|
161
152
|
name: 'Second Set',
|
|
162
153
|
question: { text: 'Who will win the second set ?', trKey: 'quizQuestion_secondSet' },
|
|
163
154
|
answers: homeAwayAnswers
|
|
164
155
|
},
|
|
165
156
|
{
|
|
166
|
-
type:
|
|
157
|
+
type: SAWGPMarketType.ThirdSet,
|
|
167
158
|
name: 'Third Set',
|
|
168
159
|
question: { text: 'Who will win the third set ?', trKey: 'quizQuestion_thirdSet' },
|
|
169
160
|
answers: homeAwayAnswers
|
|
170
161
|
},
|
|
171
162
|
{
|
|
172
|
-
type:
|
|
163
|
+
type: SAWGPMarketType.FourthSet,
|
|
173
164
|
name: 'Fourth Set',
|
|
174
165
|
question: { text: 'Who will win the fourth set ?', trKey: 'quizQuestion_fourthSet' },
|
|
175
166
|
answers: homeAwayAnswers
|
|
176
167
|
},
|
|
177
168
|
{
|
|
178
|
-
type:
|
|
169
|
+
type: SAWGPMarketType.FifthSet,
|
|
179
170
|
name: 'Fifth Set',
|
|
180
171
|
question: { text: 'Who will win the fifth set ?', trKey: 'quizQuestion_fifthSet' },
|
|
181
172
|
answers: homeAwayAnswers
|
|
182
173
|
},
|
|
183
174
|
{
|
|
184
|
-
type:
|
|
175
|
+
type: SAWGPMarketType.PlayerOneWinsOneSet,
|
|
185
176
|
name: 'Player One Wins One Set',
|
|
186
177
|
question: { text: 'Will Player One win at least one set?', trKey: 'quizQuestion_playerOneWinsOneSet' },
|
|
187
178
|
answers: yesNoAnswers
|
|
188
179
|
},
|
|
189
180
|
{
|
|
190
|
-
type:
|
|
181
|
+
type: SAWGPMarketType.PlayerTwoWinsOneSet,
|
|
191
182
|
name: 'Player Two Wins One Set',
|
|
192
183
|
question: { text: 'Will Player Two win at least one set?', trKey: 'quizQuestion_playerTwoWinsOneSet' },
|
|
193
184
|
answers: yesNoAnswers
|
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SAWGPMarketType } from "./MarketsType";
|
|
2
2
|
import { QuizSportType } from "./SportTypes";
|
|
3
3
|
|
|
4
4
|
export const QuizMarketPerSport = {
|
|
5
5
|
[QuizSportType.Basketball]: [
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
SAWGPMarketType.One_Two,
|
|
7
|
+
SAWGPMarketType.Overtime,
|
|
8
|
+
SAWGPMarketType.OneXTwo,
|
|
9
|
+
SAWGPMarketType.OddEven,
|
|
10
|
+
SAWGPMarketType.OddEvenHomeAway,
|
|
11
|
+
SAWGPMarketType.DoubleChance,
|
|
12
12
|
],
|
|
13
13
|
[QuizSportType.Soccer]: [
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
14
|
+
SAWGPMarketType.OneXTwo,
|
|
15
|
+
SAWGPMarketType.OneXTwoHalftime,
|
|
16
|
+
SAWGPMarketType.HalftimeFulltime,
|
|
17
|
+
SAWGPMarketType.FirstGoal,
|
|
18
|
+
SAWGPMarketType.LastGoal,
|
|
19
|
+
SAWGPMarketType.DoubleChance,
|
|
20
|
+
SAWGPMarketType.OverUnder2_5,
|
|
21
|
+
SAWGPMarketType.OverUnder1_5Halftime,
|
|
22
|
+
SAWGPMarketType.OverUnder1_5__2ndHalf,
|
|
23
|
+
SAWGPMarketType.RedCard,
|
|
24
|
+
SAWGPMarketType.TotalCorners8_5,
|
|
25
|
+
SAWGPMarketType.TotalCorners9_5,
|
|
26
|
+
SAWGPMarketType.Corners1x2,
|
|
27
27
|
],
|
|
28
28
|
[QuizSportType.Tennis]: [
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
29
|
+
SAWGPMarketType.One_Two,
|
|
30
|
+
SAWGPMarketType.FirstSet,
|
|
31
|
+
SAWGPMarketType.SecondSet,
|
|
32
|
+
SAWGPMarketType.ThirdSet,
|
|
33
|
+
SAWGPMarketType.FourthSet,
|
|
34
|
+
SAWGPMarketType.FifthSet,
|
|
35
|
+
SAWGPMarketType.PlayerOneWinsOneSet,
|
|
36
|
+
SAWGPMarketType.PlayerTwoWinsOneSet,
|
|
37
|
+
SAWGPMarketType.OddEven
|
|
38
38
|
]
|
|
39
39
|
}
|
package/src/Quiz/MarketsType.ts
CHANGED
package/src/Quiz/index.ts
CHANGED