@@ -4,8 +4,9 @@ import { StdFee } from '@interchainjs/cosmos-types/types';
44import { isDeliverTxSuccess } from '@interchainjs/cosmos/utils/asserts'
55import { useToast , type CustomToast } from './useToast' ;
66import { assetLists } from '@chain-registry/v2' ;
7- import { toEncoders } from '@interchainjs/cosmos/utils'
8- import { MsgDelegate , MsgUndelegate } from 'interchainjs/cosmos/staking/v1beta1/tx'
7+ import { toEncoders , toConverters } from '@interchainjs/cosmos/utils'
8+ import { MsgDelegate , MsgUndelegate , MsgBeginRedelegate } from 'interchainjs/cosmos/staking/v1beta1/tx'
9+ import { MsgWithdrawDelegatorReward } from 'interchainjs/cosmos/distribution/v1beta1/tx'
910
1011const txRaw = cosmos . tx . v1beta1 . TxRaw ;
1112
@@ -55,13 +56,14 @@ export const useTx = (chainName: string) => {
5556 amount : [
5657 {
5758 denom : denomUnit ?. denom ! ,
58- amount : ( BigInt ( 10 ** ( denomUnit ?. exponent || 6 ) ) / 100n ) . toString ( )
59+ amount : ( BigInt ( 10 ** ( denomUnit ?. exponent || 6 ) ) / 10n ) . toString ( )
5960 }
6061 ] ,
61- gas : '200000 '
62+ gas : '800000 '
6263 }
6364 client = await getSigningClient ( ) ;
64- client . addEncoders ( toEncoders ( MsgDelegate , MsgUndelegate ) )
65+ client . addEncoders ( toEncoders ( MsgDelegate , MsgUndelegate , MsgBeginRedelegate , MsgWithdrawDelegatorReward ) )
66+ client . addConverters ( toConverters ( MsgDelegate , MsgUndelegate , MsgBeginRedelegate , MsgWithdrawDelegatorReward ) )
6567 signed = await client . sign ( address , msgs , fee , '' ) ;
6668 } catch ( e : any ) {
6769 console . error ( e ) ;
0 commit comments