@smartico/public-api 0.0.290 → 0.0.291
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/CustomSections/AchCustomSection.d.ts +14 -1
- package/dist/CustomSections/UICustomSection.d.ts +5 -1
- package/dist/WSAPI/WSAPITypes.d.ts +9 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +30 -10
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +22 -3
- package/dist/index.modern.mjs.map +1 -1
- package/package.json +1 -1
- package/src/CustomSections/AchCustomSection.ts +14 -0
- package/src/CustomSections/UICustomSection.ts +14 -0
- package/src/WSAPI/WSAPITypes.ts +9 -1
- package/src/index.ts +1 -0
|
@@ -9,7 +9,8 @@ export declare enum AchCustomSectionType {
|
|
|
9
9
|
REDIRECT_LINK = 9,
|
|
10
10
|
LOOTBOX_WEEKLY = 10,
|
|
11
11
|
LOOTBOX_CALENDAR_DAYS = 11,
|
|
12
|
-
TREASURE_HUNT = 12
|
|
12
|
+
TREASURE_HUNT = 12,
|
|
13
|
+
RAFFLE = 13
|
|
13
14
|
}
|
|
14
15
|
export declare enum AchCustomLayoutTheme {
|
|
15
16
|
VALENTINES_LIGHT = "valentines-light",
|
|
@@ -29,3 +30,15 @@ export declare enum AchOverviewMissionsFilter {
|
|
|
29
30
|
ALL_EXCEPT_LOCKED = 4,
|
|
30
31
|
ALL_EXCEPT_COMPLETED_AND_LOCKED = 5
|
|
31
32
|
}
|
|
33
|
+
export declare enum LiquidEntityData {
|
|
34
|
+
Missions = 1,
|
|
35
|
+
Store = 2,
|
|
36
|
+
Tournaments = 3,
|
|
37
|
+
MiniGames = 4,
|
|
38
|
+
Levels = 5,
|
|
39
|
+
Jackpots = 6,
|
|
40
|
+
Bonus = 7,
|
|
41
|
+
Leaderboard = 8,
|
|
42
|
+
Badges = 9,
|
|
43
|
+
Tournament = 10
|
|
44
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { TUICustomSection } from '../WSAPI/WSAPITypes';
|
|
2
|
-
import { AchCustomLayoutTheme, AchCustomSectionType, AchMissionsTabsOptions, AchOverviewMissionsFilter } from './AchCustomSection';
|
|
2
|
+
import { AchCustomLayoutTheme, AchCustomSectionType, AchMissionsTabsOptions, AchOverviewMissionsFilter, LiquidEntityData } from './AchCustomSection';
|
|
3
3
|
import { GetCustomSectionsResponse } from './GetCustomSectionsResponse';
|
|
4
4
|
export interface UICustomSection {
|
|
5
5
|
body?: string;
|
|
@@ -12,5 +12,9 @@ export interface UICustomSection {
|
|
|
12
12
|
mission_tabs_options?: AchMissionsTabsOptions;
|
|
13
13
|
overview_missions_filter?: AchOverviewMissionsFilter;
|
|
14
14
|
overview_missions_count?: number;
|
|
15
|
+
liquid_entity_data?: LiquidEntityData[];
|
|
16
|
+
ach_tournament_id?: number;
|
|
17
|
+
show_raw_data?: boolean;
|
|
18
|
+
liquid_template?: number;
|
|
15
19
|
}
|
|
16
20
|
export declare const UICustomSectionTransform: (response: GetCustomSectionsResponse) => TUICustomSection[];
|
|
@@ -3,7 +3,7 @@ import { MiniGamePrizeTypeName, SAWAcknowledgeTypeName, SAWAskForUsername, SAWBu
|
|
|
3
3
|
import { TournamentRegistrationError, TournamentRegistrationStatusName, TournamentRegistrationTypeName } from '../Tournaments';
|
|
4
4
|
import { AchievementAvailabilityStatus } from '../Missions';
|
|
5
5
|
import { LeaderBoardPeriodType } from '../Leaderboard';
|
|
6
|
-
import { AchCustomLayoutTheme, AchCustomSectionType, AchMissionsTabsOptions, AchOverviewMissionsFilter } from '../CustomSections';
|
|
6
|
+
import { AchCustomLayoutTheme, AchCustomSectionType, AchMissionsTabsOptions, AchOverviewMissionsFilter, LiquidEntityData } from '../CustomSections';
|
|
7
7
|
import { PrizeModifiers } from '../MiniGames/PrizeModifiers';
|
|
8
8
|
import { InboxCategories } from '../Inbox/InboxCategories';
|
|
9
9
|
import { RaffleDrawInstanceState, RaffleDrawTypeExecution } from '../Raffle';
|
|
@@ -797,6 +797,14 @@ export interface TUICustomSection {
|
|
|
797
797
|
overview_missions_filter?: AchOverviewMissionsFilter;
|
|
798
798
|
/** Quantity of missions to be shown in overview */
|
|
799
799
|
overview_missions_count?: number;
|
|
800
|
+
/** Data to be used for Liquid templates */
|
|
801
|
+
liquid_entity_data?: LiquidEntityData[];
|
|
802
|
+
/** Tournament ID to be used for Liquid templates */
|
|
803
|
+
ach_tournament_id?: number;
|
|
804
|
+
/** Indicates if the data should be shown as raw data (for Liquid templates) */
|
|
805
|
+
show_raw_data?: boolean;
|
|
806
|
+
/** Liquid template id to be used for Liquid templates */
|
|
807
|
+
liquid_template?: number;
|
|
800
808
|
}
|
|
801
809
|
export interface TBonus {
|
|
802
810
|
/** ID of the bonus */
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -3337,7 +3337,7 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
3337
3337
|
return WSAPI;
|
|
3338
3338
|
}();
|
|
3339
3339
|
|
|
3340
|
-
|
|
3340
|
+
exports.AchCustomSectionType = void 0;
|
|
3341
3341
|
(function (AchCustomSectionType) {
|
|
3342
3342
|
AchCustomSectionType[AchCustomSectionType["HTML_PAGE"] = 1] = "HTML_PAGE";
|
|
3343
3343
|
AchCustomSectionType[AchCustomSectionType["MISSIONS_CATEGORY"] = 2] = "MISSIONS_CATEGORY";
|
|
@@ -3350,28 +3350,42 @@ var AchCustomSectionType;
|
|
|
3350
3350
|
AchCustomSectionType[AchCustomSectionType["LOOTBOX_WEEKLY"] = 10] = "LOOTBOX_WEEKLY";
|
|
3351
3351
|
AchCustomSectionType[AchCustomSectionType["LOOTBOX_CALENDAR_DAYS"] = 11] = "LOOTBOX_CALENDAR_DAYS";
|
|
3352
3352
|
AchCustomSectionType[AchCustomSectionType["TREASURE_HUNT"] = 12] = "TREASURE_HUNT";
|
|
3353
|
-
|
|
3354
|
-
|
|
3353
|
+
AchCustomSectionType[AchCustomSectionType["RAFFLE"] = 13] = "RAFFLE";
|
|
3354
|
+
})(exports.AchCustomSectionType || (exports.AchCustomSectionType = {}));
|
|
3355
|
+
exports.AchCustomLayoutTheme = void 0;
|
|
3355
3356
|
(function (AchCustomLayoutTheme) {
|
|
3356
3357
|
AchCustomLayoutTheme["VALENTINES_LIGHT"] = "valentines-light";
|
|
3357
3358
|
AchCustomLayoutTheme["VALENTINES_DARK"] = "valentines-dark";
|
|
3358
3359
|
AchCustomLayoutTheme["EURO_2024"] = "euro-2024";
|
|
3359
3360
|
AchCustomLayoutTheme["GENERIC"] = "generic";
|
|
3360
|
-
})(AchCustomLayoutTheme || (AchCustomLayoutTheme = {}));
|
|
3361
|
-
|
|
3361
|
+
})(exports.AchCustomLayoutTheme || (exports.AchCustomLayoutTheme = {}));
|
|
3362
|
+
exports.AchMissionsTabsOptions = void 0;
|
|
3362
3363
|
(function (AchMissionsTabsOptions) {
|
|
3363
3364
|
AchMissionsTabsOptions[AchMissionsTabsOptions["ONLY_OVERVIEW"] = 1] = "ONLY_OVERVIEW";
|
|
3364
3365
|
AchMissionsTabsOptions[AchMissionsTabsOptions["NO_OVERVIEW"] = 2] = "NO_OVERVIEW";
|
|
3365
3366
|
AchMissionsTabsOptions[AchMissionsTabsOptions["ALL"] = 3] = "ALL";
|
|
3366
|
-
})(AchMissionsTabsOptions || (AchMissionsTabsOptions = {}));
|
|
3367
|
-
|
|
3367
|
+
})(exports.AchMissionsTabsOptions || (exports.AchMissionsTabsOptions = {}));
|
|
3368
|
+
exports.AchOverviewMissionsFilter = void 0;
|
|
3368
3369
|
(function (AchOverviewMissionsFilter) {
|
|
3369
3370
|
AchOverviewMissionsFilter[AchOverviewMissionsFilter["ANY"] = 1] = "ANY";
|
|
3370
3371
|
AchOverviewMissionsFilter[AchOverviewMissionsFilter["ALL_MISSIONS"] = 2] = "ALL_MISSIONS";
|
|
3371
3372
|
AchOverviewMissionsFilter[AchOverviewMissionsFilter["ALL_EXCEPT_COMPLETED"] = 3] = "ALL_EXCEPT_COMPLETED";
|
|
3372
3373
|
AchOverviewMissionsFilter[AchOverviewMissionsFilter["ALL_EXCEPT_LOCKED"] = 4] = "ALL_EXCEPT_LOCKED";
|
|
3373
3374
|
AchOverviewMissionsFilter[AchOverviewMissionsFilter["ALL_EXCEPT_COMPLETED_AND_LOCKED"] = 5] = "ALL_EXCEPT_COMPLETED_AND_LOCKED";
|
|
3374
|
-
})(AchOverviewMissionsFilter || (AchOverviewMissionsFilter = {}));
|
|
3375
|
+
})(exports.AchOverviewMissionsFilter || (exports.AchOverviewMissionsFilter = {}));
|
|
3376
|
+
exports.LiquidEntityData = void 0;
|
|
3377
|
+
(function (LiquidEntityData) {
|
|
3378
|
+
LiquidEntityData[LiquidEntityData["Missions"] = 1] = "Missions";
|
|
3379
|
+
LiquidEntityData[LiquidEntityData["Store"] = 2] = "Store";
|
|
3380
|
+
LiquidEntityData[LiquidEntityData["Tournaments"] = 3] = "Tournaments";
|
|
3381
|
+
LiquidEntityData[LiquidEntityData["MiniGames"] = 4] = "MiniGames";
|
|
3382
|
+
LiquidEntityData[LiquidEntityData["Levels"] = 5] = "Levels";
|
|
3383
|
+
LiquidEntityData[LiquidEntityData["Jackpots"] = 6] = "Jackpots";
|
|
3384
|
+
LiquidEntityData[LiquidEntityData["Bonus"] = 7] = "Bonus";
|
|
3385
|
+
LiquidEntityData[LiquidEntityData["Leaderboard"] = 8] = "Leaderboard";
|
|
3386
|
+
LiquidEntityData[LiquidEntityData["Badges"] = 9] = "Badges";
|
|
3387
|
+
LiquidEntityData[LiquidEntityData["Tournament"] = 10] = "Tournament";
|
|
3388
|
+
})(exports.LiquidEntityData || (exports.LiquidEntityData = {}));
|
|
3375
3389
|
|
|
3376
3390
|
var UICustomSectionTransform = function UICustomSectionTransform(response) {
|
|
3377
3391
|
var items = [];
|
|
@@ -3379,7 +3393,7 @@ var UICustomSectionTransform = function UICustomSectionTransform(response) {
|
|
|
3379
3393
|
var r = response.customSections[key];
|
|
3380
3394
|
var id = parseInt(key);
|
|
3381
3395
|
if (r.section_type_id !== undefined && r.section_type_id >= 1) {
|
|
3382
|
-
var x = {
|
|
3396
|
+
var x = _extends({
|
|
3383
3397
|
id: id,
|
|
3384
3398
|
body: r.body,
|
|
3385
3399
|
menu_img: r.menu_img,
|
|
@@ -3391,7 +3405,12 @@ var UICustomSectionTransform = function UICustomSectionTransform(response) {
|
|
|
3391
3405
|
overview_missions_count: r.overview_missions_count,
|
|
3392
3406
|
overview_missions_filter: r.overview_missions_filter,
|
|
3393
3407
|
theme: r.theme
|
|
3394
|
-
}
|
|
3408
|
+
}, r.section_type_id === exports.AchCustomSectionType.LEVELS ? {
|
|
3409
|
+
liquid_entity_data: r.liquid_entity_data,
|
|
3410
|
+
ach_tournament_id: r.ach_tournament_id,
|
|
3411
|
+
show_raw_data: r.show_raw_data,
|
|
3412
|
+
liquid_template: r.liquid_template
|
|
3413
|
+
} : {});
|
|
3395
3414
|
items.push(x);
|
|
3396
3415
|
}
|
|
3397
3416
|
});
|
|
@@ -5122,6 +5141,7 @@ exports.TournamentItemsTransform = TournamentItemsTransform;
|
|
|
5122
5141
|
exports.TournamentRegistrationStatusNamed = TournamentRegistrationStatusNamed;
|
|
5123
5142
|
exports.TournamentRegistrationTypeGetName = TournamentRegistrationTypeGetName;
|
|
5124
5143
|
exports.TournamentUtils = TournamentUtils;
|
|
5144
|
+
exports.UICustomSectionTransform = UICustomSectionTransform;
|
|
5125
5145
|
exports.UserAchievementTransform = UserAchievementTransform;
|
|
5126
5146
|
exports.getLeaderBoardTransform = getLeaderBoardTransform;
|
|
5127
5147
|
exports.marketsInfo = marketsInfo;
|