@tradeport/sui-trading-sdk 0.1.38 → 0.1.40
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/CHANGELOG.md +12 -0
- package/dist/index.js +7 -22
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -22
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/methods/claimNfts/claimNfts.ts +1 -0
- package/src/methods/removeCollectionBid/removeCollectionBid.ts +11 -21
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @tradeport/sui-trading-sdk
|
|
2
2
|
|
|
3
|
+
## 0.1.40
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 96c4a13: Fixed remove collection bid getting correct nft type
|
|
8
|
+
|
|
9
|
+
## 0.1.39
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- c43974b: Converting to personal kiosk in claim
|
|
14
|
+
|
|
3
15
|
## 0.1.38
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/dist/index.js
CHANGED
|
@@ -3061,6 +3061,7 @@ var claimNfts = async ({ nftIds, walletAddress, tx: existingTx }, context, useOl
|
|
|
3061
3061
|
tx,
|
|
3062
3062
|
kioskOwner: txData?.claimer,
|
|
3063
3063
|
kiosk: txData?.sellerKiosk,
|
|
3064
|
+
shouldConvertToPersonalKiosk: true,
|
|
3064
3065
|
async runCommands(kioskTx) {
|
|
3065
3066
|
await addClaimAcceptedBidNftWithPurchaseCapTx({ ...txData, kioskTx });
|
|
3066
3067
|
}
|
|
@@ -4065,28 +4066,12 @@ var removeCollectionBid = async ({ bidId }, context) => {
|
|
|
4065
4066
|
const bidsForTracking = [];
|
|
4066
4067
|
const tx = new import_transactions16.Transaction();
|
|
4067
4068
|
for (const bid of res.bids) {
|
|
4068
|
-
|
|
4069
|
-
|
|
4070
|
-
|
|
4071
|
-
|
|
4072
|
-
|
|
4073
|
-
|
|
4074
|
-
"c8e19183-3a9e-4312-939f-c63a1416e344",
|
|
4075
|
-
// Panzerdogs
|
|
4076
|
-
"819eabe2-1565-4c3a-a9f6-1b5fca48e09a"
|
|
4077
|
-
// Panzerdog Tanks
|
|
4078
|
-
]?.includes(bid?.collection_id)) {
|
|
4079
|
-
const collectionWithOneNftRes = await gqlChainRequest({
|
|
4080
|
-
chain: "sui",
|
|
4081
|
-
query: fetchCollectionsByIdWithOneNft,
|
|
4082
|
-
variables: { collectionIds: [bid?.collection_id] }
|
|
4083
|
-
});
|
|
4084
|
-
nftType = getNftTypeFromNft(collectionWithOneNftRes?.collections?.[0]?.nfts?.[0]);
|
|
4085
|
-
} else if (bid?.collection_id === "07231735-96de-4710-8e11-52c61a482578") {
|
|
4086
|
-
nftType = "0x034c162f6b594cb5a1805264dd01ca5d80ce3eca6522e6ee37fd9ebfb9d3ddca::factory::PrimeMachin";
|
|
4087
|
-
} else {
|
|
4088
|
-
nftType = bid?.contract?.properties?.nft_type;
|
|
4089
|
-
}
|
|
4069
|
+
const collectionWithOneNftRes = await gqlChainRequest({
|
|
4070
|
+
chain: "sui",
|
|
4071
|
+
query: fetchCollectionsByIdWithOneNft,
|
|
4072
|
+
variables: { collectionIds: [bid?.collection_id] }
|
|
4073
|
+
});
|
|
4074
|
+
const nftType = bid?.collection_id === "07231735-96de-4710-8e11-52c61a482578" ? "0x034c162f6b594cb5a1805264dd01ca5d80ce3eca6522e6ee37fd9ebfb9d3ddca::factory::PrimeMachin" : getNftTypeFromNft(collectionWithOneNftRes?.collections?.[0]?.nfts?.[0]) || bid?.contract?.properties?.nft_type;
|
|
4090
4075
|
const sharedObjects = await getSharedObjects(nftType);
|
|
4091
4076
|
const txData = {
|
|
4092
4077
|
tx,
|