@typus/typus-sdk 1.8.41 → 1.8.43-upgrade
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/src/auto-bid/view-function.d.ts +0 -2
- package/dist/src/auto-bid/view-function.js +7 -76
- package/dist/src/constants/constant.d.ts +0 -3
- package/dist/src/constants/constant.js +1 -8
- package/dist/src/constants/token.d.ts +1 -1
- package/dist/src/constants/token.js +12 -0
- package/dist/src/dice/fetch.d.ts +0 -4
- package/dist/src/dice/fetch.js +59 -116
- package/dist/src/typus/airdrop/view-function.js +5 -8
- package/dist/src/typus/leaderboard/view-function.js +5 -8
- package/dist/src/typus/tails-staking/view-function.js +10 -14
- package/dist/src/typus/user/view-function.js +5 -6
- package/dist/src/typus-dov-single-v2/function/bidding.d.ts +4 -3
- package/dist/src/typus-dov-single-v2/function/bidding.js +10 -11
- package/dist/src/typus-dov-single-v2/function/token.js +1 -1
- package/dist/src/typus-dov-single-v2/history/index.d.ts +0 -1
- package/dist/src/typus-dov-single-v2/history/index.js +0 -1
- package/dist/src/typus-dov-single-v2/history/user-history.d.ts +2 -3
- package/dist/src/typus-dov-single-v2/history/user-history.js +122 -184
- package/dist/src/typus-dov-single-v2/otc-entry.js +5 -6
- package/dist/src/typus-dov-single-v2/user-entry.d.ts +1 -1
- package/dist/src/typus-dov-single-v2/view-function.js +29 -27
- package/dist/src/typus-hedge/view-function.js +10 -10
- package/dist/src/typus-launch/airdrop/view-function.js +3 -5
- package/dist/src/typus-launch/auction/view-function.js +17 -16
- package/dist/src/typus-launch/funding-vault/view-function.js +20 -18
- package/dist/src/typus-launch/improvement-proposal/view-function.js +17 -18
- package/dist/src/typus-launch/ve-typus/view-function.js +15 -15
- package/dist/src/typus-safu/view-function.js +13 -13
- package/dist/src/utils/api/price.js +1 -1
- package/dist/src/utils/graphQl.d.ts +24 -0
- package/dist/src/utils/graphQl.js +129 -0
- package/dist/src/utils/index.d.ts +1 -0
- package/dist/src/utils/index.js +1 -0
- package/dist/src/utils/oracle.js +13 -14
- package/dist/src/utils/pyth/constant.js +4 -0
- package/dist/src/utils/sponsoredTx.d.ts +2 -2
- package/dist/src/utils/typusConfig.d.ts +4 -0
- package/dist/src/utils/typusConfig.js +33 -31
- package/package.json +9 -10
- package/dist/src/dice/view-function.d.ts +0 -1
- package/dist/src/dice/view-function.js +0 -20
- package/dist/src/typus-dov-single-v2/history/vault-history.d.ts +0 -123
- package/dist/src/typus-dov-single-v2/history/vault-history.js +0 -307
- package/dist/src/typus-nft/fetch.d.ts +0 -70
- package/dist/src/typus-nft/fetch.js +0 -631
- package/dist/src/typus-nft/index.d.ts +0 -2
- package/dist/src/typus-nft/index.js +0 -18
- package/dist/src/typus-nft/user-entry.d.ts +0 -57
- package/dist/src/typus-nft/user-entry.js +0 -161
|
@@ -84,7 +84,6 @@ var utils_1 = require("../../../src/utils");
|
|
|
84
84
|
var auto_bid_1 = require("../../../src/auto-bid");
|
|
85
85
|
var lodash_1 = require("lodash");
|
|
86
86
|
var token_1 = require("./token");
|
|
87
|
-
var client_1 = require("@mysten/sui/client");
|
|
88
87
|
var constants_1 = require("../../../src/constants");
|
|
89
88
|
var bignumber_js_1 = __importDefault(require("bignumber.js"));
|
|
90
89
|
var moment_1 = __importDefault(require("moment"));
|
|
@@ -401,30 +400,30 @@ var parseBid = function (bidVaultInfo, bidShare, auction, oTokenPrice, isAutoBid
|
|
|
401
400
|
exports.parseBid = parseBid;
|
|
402
401
|
function getUserOwnedObjects(config, user) {
|
|
403
402
|
return __awaiter(this, void 0, void 0, function () {
|
|
404
|
-
var provider, result, hasNextPage, data,
|
|
403
|
+
var provider, result, hasNextPage, data, cursor;
|
|
405
404
|
return __generator(this, function (_a) {
|
|
406
405
|
switch (_a.label) {
|
|
407
406
|
case 0:
|
|
408
|
-
provider =
|
|
409
|
-
return [4 /*yield*/, provider.
|
|
407
|
+
provider = config.gRpcClient();
|
|
408
|
+
return [4 /*yield*/, provider.listOwnedObjects({ owner: user, include: { content: true } })];
|
|
410
409
|
case 1:
|
|
411
410
|
result = _a.sent();
|
|
412
411
|
hasNextPage = result.hasNextPage;
|
|
413
|
-
data = result.
|
|
414
|
-
|
|
412
|
+
data = result.objects;
|
|
413
|
+
cursor = result.cursor;
|
|
415
414
|
_a.label = 2;
|
|
416
415
|
case 2:
|
|
417
416
|
if (!hasNextPage) return [3 /*break*/, 4];
|
|
418
|
-
return [4 /*yield*/, provider.
|
|
417
|
+
return [4 /*yield*/, provider.listOwnedObjects({
|
|
419
418
|
owner: user,
|
|
420
|
-
cursor:
|
|
421
|
-
|
|
419
|
+
cursor: cursor,
|
|
420
|
+
include: { content: true },
|
|
422
421
|
})];
|
|
423
422
|
case 3:
|
|
424
423
|
result = _a.sent();
|
|
425
|
-
data = __spreadArray(__spreadArray([], __read(data), false), __read(result.
|
|
424
|
+
data = __spreadArray(__spreadArray([], __read(data), false), __read(result.objects), false);
|
|
426
425
|
hasNextPage = result.hasNextPage;
|
|
427
|
-
|
|
426
|
+
cursor = result.cursor;
|
|
428
427
|
return [3 /*break*/, 2];
|
|
429
428
|
case 4: return [2 /*return*/, data];
|
|
430
429
|
}
|
|
@@ -37,6 +37,6 @@ var getTokenName = function (_a) {
|
|
|
37
37
|
else {
|
|
38
38
|
tokenName = (_c = exports.UnwrappedToken[token]) !== null && _c !== void 0 ? _c : token;
|
|
39
39
|
}
|
|
40
|
-
return million ? (_d = exports.MillionToken[tokenName]) !== null && _d !== void 0 ? _d : tokenName : (_e = exports.RemoveMillionToken[tokenName]) !== null && _e !== void 0 ? _e : tokenName;
|
|
40
|
+
return million ? ((_d = exports.MillionToken[tokenName]) !== null && _d !== void 0 ? _d : tokenName) : ((_e = exports.RemoveMillionToken[tokenName]) !== null && _e !== void 0 ? _e : tokenName);
|
|
41
41
|
};
|
|
42
42
|
exports.getTokenName = getTokenName;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { EventId, SuiClient, SuiEvent } from "@mysten/sui/client";
|
|
2
1
|
import { Vault } from "../../../src/typus-dov-single-v2";
|
|
3
2
|
import { TOKEN } from "../../../src/constants";
|
|
4
3
|
export { getNewBidFromSentio, getExerciseFromSentio } from "../../../src/utils/api/sentio/events";
|
|
5
|
-
|
|
6
|
-
export declare function
|
|
4
|
+
import { SuiGraphQLClient } from "@mysten/sui/graphql";
|
|
5
|
+
export declare function getUserEvents(graphQlClient: SuiGraphQLClient, sender: string, cursor?: string | null): Promise<import("../../../src/utils/graphQl").Event[]>;
|
|
7
6
|
export interface TxHistory {
|
|
8
7
|
Index: string | undefined;
|
|
9
8
|
Action: string | undefined;
|