@opexa/portal-sdk 0.59.109 → 0.59.111
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 +8 -22
- package/dist/{chunk-K6UZEYMR.js → chunk-DSBYVM5T.js} +4 -4
- package/dist/{chunk-K6UZEYMR.js.map → chunk-DSBYVM5T.js.map} +1 -1
- package/dist/index.cjs +42 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +11 -3
- package/dist/index.d.ts +11 -3
- package/dist/index.js +41 -11
- package/dist/index.js.map +1 -1
- package/dist/services/index.cjs +2 -2
- package/dist/services/index.cjs.map +1 -1
- package/dist/services/index.d.cts +2 -2
- package/dist/services/index.d.ts +2 -2
- package/dist/services/index.js +1 -1
- package/dist/{types-D80A3vyd.d.ts → types-LlyaAtr8.d.ts} +2 -2
- package/dist/{types-B_6SgrP-.d.cts → types-ujZqvY5s.d.cts} +2 -2
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3435,7 +3435,7 @@ var WALLET_GAMES_QUERY = gql`
|
|
|
3435
3435
|
}
|
|
3436
3436
|
`;
|
|
3437
3437
|
var _GAMES_NEXT_QUERY = gql`
|
|
3438
|
-
query
|
|
3438
|
+
query _games($first: Int, $after: Cursor, $filter: _GameFilterInput) {
|
|
3439
3439
|
_games(first: $first, after: $after, filter: $filter) {
|
|
3440
3440
|
totalCount
|
|
3441
3441
|
pageInfo {
|
|
@@ -3468,7 +3468,7 @@ var _GAMES_NEXT_QUERY = gql`
|
|
|
3468
3468
|
}
|
|
3469
3469
|
`;
|
|
3470
3470
|
var _GAMES_NEXT_QUERY__STAGING = gql`
|
|
3471
|
-
query
|
|
3471
|
+
query _games($first: Int, $after: Cursor, $filter: _GameFilterInput) {
|
|
3472
3472
|
_games(first: $first, after: $after, filter: $filter) {
|
|
3473
3473
|
totalCount
|
|
3474
3474
|
pageInfo {
|
|
@@ -8720,6 +8720,7 @@ var Transformer = class {
|
|
|
8720
8720
|
latestBetRecord: this.latestBetRecord.bind(this),
|
|
8721
8721
|
transactionRecord: this.transactionRecord.bind(this),
|
|
8722
8722
|
game: this.game.bind(this),
|
|
8723
|
+
_games: this._games.bind(this),
|
|
8723
8724
|
gameSession: this.gameSession.bind(this),
|
|
8724
8725
|
promo: this.promo.bind(this),
|
|
8725
8726
|
cashback: this.cashback.bind(this),
|
|
@@ -9897,6 +9898,39 @@ var Transformer = class {
|
|
|
9897
9898
|
};
|
|
9898
9899
|
return o;
|
|
9899
9900
|
}
|
|
9901
|
+
_games(data) {
|
|
9902
|
+
const games = data.edges.flatMap(({ cursor, node }) => {
|
|
9903
|
+
if (node.hidden || node.status !== "ACTIVE" || !node.type || !node.provider) {
|
|
9904
|
+
return [];
|
|
9905
|
+
}
|
|
9906
|
+
const name = node.displayName?.trim() || node.name;
|
|
9907
|
+
if (!name) return [];
|
|
9908
|
+
const imageId = objectId.ObjectId.from(node.id).toString("hex");
|
|
9909
|
+
const fallback = `${ENDPOINTS.production.static}/images/${node.provider.toLowerCase()}/thumbnail-${imageId}.webp`;
|
|
9910
|
+
return [
|
|
9911
|
+
{
|
|
9912
|
+
id: node.id,
|
|
9913
|
+
// Wallet's ID is the launch/favorite reference; reference is a provider code.
|
|
9914
|
+
reference: node.id,
|
|
9915
|
+
name,
|
|
9916
|
+
type: node.type,
|
|
9917
|
+
provider: node.provider,
|
|
9918
|
+
images: [
|
|
9919
|
+
...new Set(node.image ? [node.image, fallback] : [fallback])
|
|
9920
|
+
],
|
|
9921
|
+
tags: [],
|
|
9922
|
+
favorite: false,
|
|
9923
|
+
cursor
|
|
9924
|
+
}
|
|
9925
|
+
];
|
|
9926
|
+
});
|
|
9927
|
+
return {
|
|
9928
|
+
_games: games,
|
|
9929
|
+
totalCount: data.totalCount,
|
|
9930
|
+
hasNextPage: data.pageInfo.hasNextPage,
|
|
9931
|
+
endCursor: data.pageInfo.endCursor ?? void 0
|
|
9932
|
+
};
|
|
9933
|
+
}
|
|
9900
9934
|
gameSession(data) {
|
|
9901
9935
|
const o = {
|
|
9902
9936
|
id: data.id,
|
|
@@ -12298,7 +12332,11 @@ var Sdk = class {
|
|
|
12298
12332
|
}
|
|
12299
12333
|
};
|
|
12300
12334
|
}
|
|
12301
|
-
|
|
12335
|
+
/**
|
|
12336
|
+
* Fetches the Wallet-backed platform game catalog with cursor pagination.
|
|
12337
|
+
* Search is applied to `displayName.contains` alongside the supplied filters.
|
|
12338
|
+
*/
|
|
12339
|
+
async _games__next(input) {
|
|
12302
12340
|
let variables;
|
|
12303
12341
|
if (input) {
|
|
12304
12342
|
const { search, ...rest } = input;
|
|
@@ -12317,15 +12355,7 @@ var Sdk = class {
|
|
|
12317
12355
|
if (!res.ok) return res;
|
|
12318
12356
|
return {
|
|
12319
12357
|
ok: true,
|
|
12320
|
-
data:
|
|
12321
|
-
platformGames: res.data.edges.map(({ cursor, node }) => ({
|
|
12322
|
-
...node,
|
|
12323
|
-
cursor
|
|
12324
|
-
})),
|
|
12325
|
-
totalCount: res.data.totalCount,
|
|
12326
|
-
hasNextPage: res.data.pageInfo.hasNextPage,
|
|
12327
|
-
endCursor: res.data.pageInfo.endCursor ?? void 0
|
|
12328
|
-
}
|
|
12358
|
+
data: this.transformer.transform._games(res.data)
|
|
12329
12359
|
};
|
|
12330
12360
|
}
|
|
12331
12361
|
async gameGroups(input) {
|