Skip to content

Commit bf41a61

Browse files
feat: make phantom great again (#11416)
1 parent 4c5df99 commit bf41a61

File tree

6 files changed

+140
-136
lines changed

6 files changed

+140
-136
lines changed

package.json

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -100,24 +100,24 @@
100100
"@shapeshiftoss/chain-adapters": "workspace:^",
101101
"@shapeshiftoss/contracts": "workspace:^",
102102
"@shapeshiftoss/errors": "workspace:^",
103-
"@shapeshiftoss/hdwallet-coinbase": "1.62.29",
104-
"@shapeshiftoss/hdwallet-core": "1.62.29",
105-
"@shapeshiftoss/hdwallet-gridplus": "1.62.29",
106-
"@shapeshiftoss/hdwallet-keepkey": "1.62.29",
107-
"@shapeshiftoss/hdwallet-keepkey-webusb": "1.62.29",
108-
"@shapeshiftoss/hdwallet-keplr": "1.62.29",
109-
"@shapeshiftoss/hdwallet-ledger": "1.62.29",
110-
"@shapeshiftoss/hdwallet-ledger-webhid": "1.62.29",
111-
"@shapeshiftoss/hdwallet-ledger-webusb": "1.62.29",
112-
"@shapeshiftoss/hdwallet-metamask-multichain": "1.62.29",
113-
"@shapeshiftoss/hdwallet-native": "1.62.29",
114-
"@shapeshiftoss/hdwallet-native-vault": "1.62.29",
115-
"@shapeshiftoss/hdwallet-phantom": "1.62.29",
116-
"@shapeshiftoss/hdwallet-trezor": "1.62.29",
117-
"@shapeshiftoss/hdwallet-trezor-connect": "1.62.29",
118-
"@shapeshiftoss/hdwallet-vultisig": "1.62.29",
119-
"@shapeshiftoss/hdwallet-walletconnect": "1.62.29",
120-
"@shapeshiftoss/hdwallet-walletconnectv2": "1.62.29",
103+
"@shapeshiftoss/hdwallet-coinbase": "1.62.30",
104+
"@shapeshiftoss/hdwallet-core": "1.62.30",
105+
"@shapeshiftoss/hdwallet-gridplus": "1.62.30",
106+
"@shapeshiftoss/hdwallet-keepkey": "1.62.30",
107+
"@shapeshiftoss/hdwallet-keepkey-webusb": "1.62.30",
108+
"@shapeshiftoss/hdwallet-keplr": "1.62.30",
109+
"@shapeshiftoss/hdwallet-ledger": "1.62.30",
110+
"@shapeshiftoss/hdwallet-ledger-webhid": "1.62.30",
111+
"@shapeshiftoss/hdwallet-ledger-webusb": "1.62.30",
112+
"@shapeshiftoss/hdwallet-metamask-multichain": "1.62.30",
113+
"@shapeshiftoss/hdwallet-native": "1.62.30",
114+
"@shapeshiftoss/hdwallet-native-vault": "1.62.30",
115+
"@shapeshiftoss/hdwallet-phantom": "1.62.30",
116+
"@shapeshiftoss/hdwallet-trezor": "1.62.30",
117+
"@shapeshiftoss/hdwallet-trezor-connect": "1.62.30",
118+
"@shapeshiftoss/hdwallet-vultisig": "1.62.30",
119+
"@shapeshiftoss/hdwallet-walletconnect": "1.62.30",
120+
"@shapeshiftoss/hdwallet-walletconnectv2": "1.62.30",
121121
"@shapeshiftoss/swapper": "workspace:^",
122122
"@shapeshiftoss/types": "workspace:^",
123123
"@shapeshiftoss/unchained-client": "workspace:^",

packages/chain-adapters/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@
3131
"dependencies": {
3232
"@mysten/sui": "1.45.0",
3333
"@shapeshiftoss/caip": "workspace:^",
34-
"@shapeshiftoss/hdwallet-core": "1.62.29",
35-
"@shapeshiftoss/hdwallet-ledger": "1.62.29",
34+
"@shapeshiftoss/hdwallet-core": "1.62.30",
35+
"@shapeshiftoss/hdwallet-ledger": "1.62.30",
3636
"@shapeshiftoss/types": "workspace:^",
3737
"@shapeshiftoss/unchained-client": "workspace:^",
3838
"@shapeshiftoss/utils": "workspace:^",

packages/chain-adapters/src/sui/SuiChainAdapter.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -274,9 +274,10 @@ export class ChainAdapter implements IChainAdapter<KnownChainIds.SuiMainnet> {
274274
tx.transferObjects([coin], to)
275275
}
276276

277+
const transactionJson = await tx.toJSON()
278+
277279
const transactionBytes = await tx.build({ client: this.client })
278280

279-
// Build intent message: intent scope (0) + version (0) + app id (0) + tx bytes
280281
const intentMessage = new Uint8Array(3 + transactionBytes.length)
281282
intentMessage[0] = 0 // TransactionData intent scope
282283
intentMessage[1] = 0 // Version
@@ -286,6 +287,7 @@ export class ChainAdapter implements IChainAdapter<KnownChainIds.SuiMainnet> {
286287
return {
287288
addressNList: toAddressNList(this.getBip44Params({ accountNumber })),
288289
intentMessageBytes: intentMessage,
290+
transactionJson,
289291
}
290292
} catch (err) {
291293
return ErrorHandler(err, {

packages/swapper/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
"@shapeshiftoss/caip": "workspace:^",
4040
"@shapeshiftoss/chain-adapters": "workspace:^",
4141
"@shapeshiftoss/contracts": "workspace:^",
42-
"@shapeshiftoss/hdwallet-core": "1.62.29",
42+
"@shapeshiftoss/hdwallet-core": "1.62.30",
4343
"@shapeshiftoss/types": "workspace:^",
4444
"@shapeshiftoss/unchained-client": "workspace:^",
4545
"@shapeshiftoss/utils": "workspace:^",

packages/swapper/src/swappers/CetusSwapper/endpoints.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ export const cetusApi: SwapperApi = {
8383
refreshAllCoins: true,
8484
})
8585

86+
const transactionJson = await txb.toJSON({ client: suiClient })
8687
const transactionBytes = await txb.build({ client: suiClient })
8788

8889
const intentMessage = new Uint8Array(3 + transactionBytes.length)
@@ -104,6 +105,7 @@ export const cetusApi: SwapperApi = {
104105
return {
105106
addressNList,
106107
intentMessageBytes: intentMessage,
108+
transactionJson,
107109
}
108110
},
109111

0 commit comments

Comments
 (0)