@dhedge/trading-widget 3.2.3 → 3.3.0-alpha.1

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.
Files changed (41) hide show
  1. package/README.md +1 -0
  2. package/core-kit/abi/aave/aave-asset-guard.d.ts +50 -0
  3. package/core-kit/abi/easy-swapper-v2.d.ts +92 -0
  4. package/core-kit/abi/index.d.ts +3 -2
  5. package/core-kit/abi/pool-logic.d.ts +67 -0
  6. package/core-kit/abi/pool-manager-logic.d.ts +19 -0
  7. package/core-kit/const/contracts/polygon.d.ts +2 -0
  8. package/core-kit/hooks/pool/index.d.ts +1 -0
  9. package/core-kit/hooks/pool/multicall/use-pool-manager.dynamic.d.ts +75 -190
  10. package/core-kit/hooks/pool/multicall/use-pool-manager.static.d.ts +57 -0
  11. package/core-kit/hooks/pool/multicall/use-pool.static.d.ts +274 -0
  12. package/core-kit/hooks/pool/multicall/use-pools.dynamic.d.ts +353 -0
  13. package/core-kit/hooks/pool/use-has-dhedge-vault-in-composition.d.ts +64 -0
  14. package/core-kit/hooks/pool/use-pool-dynamic-contract-data.d.ts +1 -0
  15. package/core-kit/hooks/trading/deposit-v2/use-deposit-quote-contract-read.d.ts +92 -0
  16. package/core-kit/hooks/trading/use-swaps-data-query.d.ts +6 -0
  17. package/core-kit/hooks/trading/withdraw-v2/init-step/index.d.ts +1 -1
  18. package/core-kit/hooks/trading/withdraw-v2/init-step/use-fetch-aave-swap-params.d.ts +6 -0
  19. package/core-kit/hooks/trading/withdraw-v2/init-step/use-fetch-init-withdraw-aave-swap-data.d.ts +5 -0
  20. package/core-kit/hooks/trading/withdraw-v2/init-step/use-fetch-init-withdraw-complex-asset-data.d.ts +5 -0
  21. package/core-kit/hooks/trading/withdraw-v2/init-step/use-get-init-withdraw-transaction-arguments.d.ts +10 -0
  22. package/core-kit/hooks/trading/withdraw-v2/use-withdrawal-vault-address.d.ts +92 -0
  23. package/core-kit/hooks/user/multicall/use-user-multicall.d.ts +92 -0
  24. package/core-kit/hooks/web3/use-static-call-query.d.ts +7 -6
  25. package/core-kit/types/contract.types.d.ts +28 -0
  26. package/core-kit/types/index.d.ts +1 -0
  27. package/core-kit/types/web3.types.d.ts +0 -12
  28. package/core-kit/utils/transaction.d.ts +14 -3
  29. package/core-kit/utils/web3.d.ts +0 -2
  30. package/{index-83b0df05.js → index-5ba43d21.js} +9864 -9704
  31. package/index-addee486.cjs +217 -0
  32. package/index.cjs +1 -1
  33. package/index.d.ts +2 -2
  34. package/index.js +45 -45
  35. package/package.json +1 -1
  36. package/{pyth-adapter-99bcb2fd.cjs → pyth-adapter-557e7325.cjs} +1 -1
  37. package/{pyth-adapter-ae1c3eb3.js → pyth-adapter-ae35e010.js} +1 -1
  38. package/trading-widget/providers/config-provider/config-provider.types.d.ts +1 -0
  39. package/core-kit/hooks/trading/withdraw-v2/init-step/use-init-withdraw-transaction-arguments.d.ts +0 -5
  40. package/index-76ee9693.cjs +0 -217
  41. /package/core-kit/abi/{aave-lending-pool.d.ts → aave/aave-lending-pool.d.ts} +0 -0
@@ -227,6 +227,33 @@ declare const getPoolContracts: ({ account, chainId, address, }: PoolContractAcc
227
227
  }];
228
228
  readonly stateMutability: "view";
229
229
  readonly type: "function";
230
+ }, {
231
+ readonly inputs: readonly [{
232
+ readonly internalType: "uint256";
233
+ readonly name: "_fundTokenAmount";
234
+ readonly type: "uint256";
235
+ }, {
236
+ readonly components: readonly [{
237
+ readonly internalType: "address";
238
+ readonly name: "supportedAsset";
239
+ readonly type: "address";
240
+ }, {
241
+ readonly internalType: "bytes";
242
+ readonly name: "withdrawData";
243
+ readonly type: "bytes";
244
+ }, {
245
+ readonly internalType: "uint256";
246
+ readonly name: "slippageTolerance";
247
+ readonly type: "uint256";
248
+ }];
249
+ readonly internalType: "struct IPoolLogic.ComplexAsset[]";
250
+ readonly name: "_complexAssetsData";
251
+ readonly type: "tuple[]";
252
+ }];
253
+ readonly name: "withdrawSafe";
254
+ readonly outputs: readonly [];
255
+ readonly stateMutability: "nonpayable";
256
+ readonly type: "function";
230
257
  }, {
231
258
  readonly inputs: readonly [{
232
259
  readonly internalType: "uint256";
@@ -472,6 +499,33 @@ declare const getPoolContracts: ({ account, chainId, address, }: PoolContractAcc
472
499
  }];
473
500
  readonly stateMutability: "view";
474
501
  readonly type: "function";
502
+ }, {
503
+ readonly inputs: readonly [{
504
+ readonly internalType: "uint256";
505
+ readonly name: "_fundTokenAmount";
506
+ readonly type: "uint256";
507
+ }, {
508
+ readonly components: readonly [{
509
+ readonly internalType: "address";
510
+ readonly name: "supportedAsset";
511
+ readonly type: "address";
512
+ }, {
513
+ readonly internalType: "bytes";
514
+ readonly name: "withdrawData";
515
+ readonly type: "bytes";
516
+ }, {
517
+ readonly internalType: "uint256";
518
+ readonly name: "slippageTolerance";
519
+ readonly type: "uint256";
520
+ }];
521
+ readonly internalType: "struct IPoolLogic.ComplexAsset[]";
522
+ readonly name: "_complexAssetsData";
523
+ readonly type: "tuple[]";
524
+ }];
525
+ readonly name: "withdrawSafe";
526
+ readonly outputs: readonly [];
527
+ readonly stateMutability: "nonpayable";
528
+ readonly type: "function";
475
529
  }, {
476
530
  readonly inputs: readonly [{
477
531
  readonly internalType: "uint256";
@@ -717,6 +771,33 @@ declare const getPoolContracts: ({ account, chainId, address, }: PoolContractAcc
717
771
  }];
718
772
  readonly stateMutability: "view";
719
773
  readonly type: "function";
774
+ }, {
775
+ readonly inputs: readonly [{
776
+ readonly internalType: "uint256";
777
+ readonly name: "_fundTokenAmount";
778
+ readonly type: "uint256";
779
+ }, {
780
+ readonly components: readonly [{
781
+ readonly internalType: "address";
782
+ readonly name: "supportedAsset";
783
+ readonly type: "address";
784
+ }, {
785
+ readonly internalType: "bytes";
786
+ readonly name: "withdrawData";
787
+ readonly type: "bytes";
788
+ }, {
789
+ readonly internalType: "uint256";
790
+ readonly name: "slippageTolerance";
791
+ readonly type: "uint256";
792
+ }];
793
+ readonly internalType: "struct IPoolLogic.ComplexAsset[]";
794
+ readonly name: "_complexAssetsData";
795
+ readonly type: "tuple[]";
796
+ }];
797
+ readonly name: "withdrawSafe";
798
+ readonly outputs: readonly [];
799
+ readonly stateMutability: "nonpayable";
800
+ readonly type: "function";
720
801
  }, {
721
802
  readonly inputs: readonly [{
722
803
  readonly internalType: "uint256";
@@ -734,6 +815,278 @@ declare const getPoolContracts: ({ account, chainId, address, }: PoolContractAcc
734
815
  }];
735
816
  readonly functionName: "getFundSummary";
736
817
  readonly chainId: number;
818
+ }, {
819
+ readonly address: `0x${string}`;
820
+ readonly abi: readonly [{
821
+ readonly inputs: readonly [{
822
+ readonly internalType: "address";
823
+ readonly name: "owner";
824
+ readonly type: "address";
825
+ }, {
826
+ readonly internalType: "address";
827
+ readonly name: "spender";
828
+ readonly type: "address";
829
+ }];
830
+ readonly name: "allowance";
831
+ readonly outputs: readonly [{
832
+ readonly internalType: "uint256";
833
+ readonly name: "";
834
+ readonly type: "uint256";
835
+ }];
836
+ readonly stateMutability: "view";
837
+ readonly type: "function";
838
+ }, {
839
+ readonly inputs: readonly [{
840
+ readonly internalType: "address";
841
+ readonly name: "spender";
842
+ readonly type: "address";
843
+ }, {
844
+ readonly internalType: "uint256";
845
+ readonly name: "amount";
846
+ readonly type: "uint256";
847
+ }];
848
+ readonly name: "approve";
849
+ readonly outputs: readonly [{
850
+ readonly internalType: "bool";
851
+ readonly name: "";
852
+ readonly type: "bool";
853
+ }];
854
+ readonly stateMutability: "nonpayable";
855
+ readonly type: "function";
856
+ }, {
857
+ readonly inputs: readonly [{
858
+ readonly internalType: "address";
859
+ readonly name: "account";
860
+ readonly type: "address";
861
+ }];
862
+ readonly name: "balanceOf";
863
+ readonly outputs: readonly [{
864
+ readonly internalType: "uint256";
865
+ readonly name: "";
866
+ readonly type: "uint256";
867
+ }];
868
+ readonly stateMutability: "view";
869
+ readonly type: "function";
870
+ }, {
871
+ readonly inputs: readonly [{
872
+ readonly internalType: "uint256";
873
+ readonly name: "fundValue";
874
+ readonly type: "uint256";
875
+ }];
876
+ readonly name: "calculateAvailableManagerFee";
877
+ readonly outputs: readonly [{
878
+ readonly internalType: "uint256";
879
+ readonly name: "fee";
880
+ readonly type: "uint256";
881
+ }];
882
+ readonly stateMutability: "view";
883
+ readonly type: "function";
884
+ }, {
885
+ readonly inputs: readonly [];
886
+ readonly name: "decimals";
887
+ readonly outputs: readonly [{
888
+ readonly internalType: "uint8";
889
+ readonly name: "";
890
+ readonly type: "uint8";
891
+ }];
892
+ readonly stateMutability: "view";
893
+ readonly type: "function";
894
+ }, {
895
+ readonly inputs: readonly [{
896
+ readonly internalType: "address";
897
+ readonly name: "_asset";
898
+ readonly type: "address";
899
+ }, {
900
+ readonly internalType: "uint256";
901
+ readonly name: "_amount";
902
+ readonly type: "uint256";
903
+ }];
904
+ readonly name: "deposit";
905
+ readonly outputs: readonly [{
906
+ readonly internalType: "uint256";
907
+ readonly name: "liquidityMinted";
908
+ readonly type: "uint256";
909
+ }];
910
+ readonly stateMutability: "nonpayable";
911
+ readonly type: "function";
912
+ }, {
913
+ readonly inputs: readonly [{
914
+ readonly internalType: "address";
915
+ readonly name: "sender";
916
+ readonly type: "address";
917
+ }];
918
+ readonly name: "getExitRemainingCooldown";
919
+ readonly outputs: readonly [{
920
+ readonly internalType: "uint256";
921
+ readonly name: "remaining";
922
+ readonly type: "uint256";
923
+ }];
924
+ readonly stateMutability: "view";
925
+ readonly type: "function";
926
+ }, {
927
+ readonly inputs: readonly [];
928
+ readonly name: "getFundSummary";
929
+ readonly outputs: readonly [{
930
+ readonly components: readonly [{
931
+ readonly internalType: "string";
932
+ readonly name: "name";
933
+ readonly type: "string";
934
+ }, {
935
+ readonly internalType: "uint256";
936
+ readonly name: "totalSupply";
937
+ readonly type: "uint256";
938
+ }, {
939
+ readonly internalType: "uint256";
940
+ readonly name: "totalFundValue";
941
+ readonly type: "uint256";
942
+ }, {
943
+ readonly internalType: "address";
944
+ readonly name: "manager";
945
+ readonly type: "address";
946
+ }, {
947
+ readonly internalType: "string";
948
+ readonly name: "managerName";
949
+ readonly type: "string";
950
+ }, {
951
+ readonly internalType: "uint256";
952
+ readonly name: "creationTime";
953
+ readonly type: "uint256";
954
+ }, {
955
+ readonly internalType: "bool";
956
+ readonly name: "privatePool";
957
+ readonly type: "bool";
958
+ }, {
959
+ readonly internalType: "uint256";
960
+ readonly name: "performanceFeeNumerator";
961
+ readonly type: "uint256";
962
+ }, {
963
+ readonly internalType: "uint256";
964
+ readonly name: "managerFeeNumerator";
965
+ readonly type: "uint256";
966
+ }, {
967
+ readonly internalType: "uint256";
968
+ readonly name: "managerFeeDenominator";
969
+ readonly type: "uint256";
970
+ }, {
971
+ readonly internalType: "uint256";
972
+ readonly name: "exitFeeNumerator";
973
+ readonly type: "uint256";
974
+ }, {
975
+ readonly internalType: "uint256";
976
+ readonly name: "exitFeeDenominator";
977
+ readonly type: "uint256";
978
+ }, {
979
+ readonly internalType: "uint256";
980
+ readonly name: "entryFeeNumerator";
981
+ readonly type: "uint256";
982
+ }];
983
+ readonly internalType: "struct PoolLogic.FundSummary";
984
+ readonly name: "";
985
+ readonly type: "tuple";
986
+ }];
987
+ readonly stateMutability: "view";
988
+ readonly type: "function";
989
+ }, {
990
+ readonly inputs: readonly [];
991
+ readonly name: "mintManagerFee";
992
+ readonly outputs: readonly [];
993
+ readonly stateMutability: "nonpayable";
994
+ readonly type: "function";
995
+ }, {
996
+ readonly inputs: readonly [];
997
+ readonly name: "name";
998
+ readonly outputs: readonly [{
999
+ readonly internalType: "string";
1000
+ readonly name: "";
1001
+ readonly type: "string";
1002
+ }];
1003
+ readonly stateMutability: "view";
1004
+ readonly type: "function";
1005
+ }, {
1006
+ readonly inputs: readonly [];
1007
+ readonly name: "poolManagerLogic";
1008
+ readonly outputs: readonly [{
1009
+ readonly internalType: "address";
1010
+ readonly name: "";
1011
+ readonly type: "address";
1012
+ }];
1013
+ readonly stateMutability: "view";
1014
+ readonly type: "function";
1015
+ }, {
1016
+ readonly inputs: readonly [];
1017
+ readonly name: "symbol";
1018
+ readonly outputs: readonly [{
1019
+ readonly internalType: "string";
1020
+ readonly name: "";
1021
+ readonly type: "string";
1022
+ }];
1023
+ readonly stateMutability: "view";
1024
+ readonly type: "function";
1025
+ }, {
1026
+ readonly inputs: readonly [];
1027
+ readonly name: "tokenPrice";
1028
+ readonly outputs: readonly [{
1029
+ readonly internalType: "uint256";
1030
+ readonly name: "price";
1031
+ readonly type: "uint256";
1032
+ }];
1033
+ readonly stateMutability: "view";
1034
+ readonly type: "function";
1035
+ }, {
1036
+ readonly inputs: readonly [];
1037
+ readonly name: "totalSupply";
1038
+ readonly outputs: readonly [{
1039
+ readonly internalType: "uint256";
1040
+ readonly name: "";
1041
+ readonly type: "uint256";
1042
+ }];
1043
+ readonly stateMutability: "view";
1044
+ readonly type: "function";
1045
+ }, {
1046
+ readonly inputs: readonly [{
1047
+ readonly internalType: "uint256";
1048
+ readonly name: "_fundTokenAmount";
1049
+ readonly type: "uint256";
1050
+ }, {
1051
+ readonly components: readonly [{
1052
+ readonly internalType: "address";
1053
+ readonly name: "supportedAsset";
1054
+ readonly type: "address";
1055
+ }, {
1056
+ readonly internalType: "bytes";
1057
+ readonly name: "withdrawData";
1058
+ readonly type: "bytes";
1059
+ }, {
1060
+ readonly internalType: "uint256";
1061
+ readonly name: "slippageTolerance";
1062
+ readonly type: "uint256";
1063
+ }];
1064
+ readonly internalType: "struct IPoolLogic.ComplexAsset[]";
1065
+ readonly name: "_complexAssetsData";
1066
+ readonly type: "tuple[]";
1067
+ }];
1068
+ readonly name: "withdrawSafe";
1069
+ readonly outputs: readonly [];
1070
+ readonly stateMutability: "nonpayable";
1071
+ readonly type: "function";
1072
+ }, {
1073
+ readonly inputs: readonly [{
1074
+ readonly internalType: "uint256";
1075
+ readonly name: "_fundTokenAmount";
1076
+ readonly type: "uint256";
1077
+ }, {
1078
+ readonly internalType: "uint256";
1079
+ readonly name: "_slippageTolerance";
1080
+ readonly type: "uint256";
1081
+ }];
1082
+ readonly name: "withdrawSafe";
1083
+ readonly outputs: readonly [];
1084
+ readonly stateMutability: "nonpayable";
1085
+ readonly type: "function";
1086
+ }];
1087
+ readonly functionName: "getExitRemainingCooldown";
1088
+ readonly chainId: number;
1089
+ readonly args: readonly [`0x${string}`];
737
1090
  }];
738
1091
  type PoolsMap = Record<Address, DynamicPoolContractData>;
739
1092
  type UsePoolsDynamicParams = {
@@ -0,0 +1,64 @@
1
+ import type { PoolContractCallParams } from 'core-kit/types';
2
+ export declare const useHasDhedgeVaultInComposition: ({ address, chainId, }: PoolContractCallParams) => import("wagmi").UseReadContractsReturnType<{
3
+ address: `0x${string}`;
4
+ abi: readonly [{
5
+ readonly inputs: readonly [{
6
+ readonly internalType: "address";
7
+ readonly name: "asset";
8
+ readonly type: "address";
9
+ }];
10
+ readonly name: "getAssetPrice";
11
+ readonly outputs: readonly [{
12
+ readonly internalType: "uint256";
13
+ readonly name: "price";
14
+ readonly type: "uint256";
15
+ }];
16
+ readonly stateMutability: "view";
17
+ readonly type: "function";
18
+ }, {
19
+ readonly inputs: readonly [{
20
+ readonly internalType: "address";
21
+ readonly name: "";
22
+ readonly type: "address";
23
+ }];
24
+ readonly name: "isPool";
25
+ readonly outputs: readonly [{
26
+ readonly internalType: "bool";
27
+ readonly name: "";
28
+ readonly type: "bool";
29
+ }];
30
+ readonly stateMutability: "view";
31
+ readonly type: "function";
32
+ }, {
33
+ readonly inputs: readonly [{
34
+ readonly internalType: "address";
35
+ readonly name: "extContract";
36
+ readonly type: "address";
37
+ }];
38
+ readonly name: "getAssetGuard";
39
+ readonly outputs: readonly [{
40
+ readonly internalType: "address";
41
+ readonly name: "guard";
42
+ readonly type: "address";
43
+ }];
44
+ readonly stateMutability: "view";
45
+ readonly type: "function";
46
+ }, {
47
+ readonly inputs: readonly [{
48
+ readonly internalType: "address";
49
+ readonly name: "extContract";
50
+ readonly type: "address";
51
+ }];
52
+ readonly name: "getContractGuard";
53
+ readonly outputs: readonly [{
54
+ readonly internalType: "address";
55
+ readonly name: "guard";
56
+ readonly type: "address";
57
+ }];
58
+ readonly stateMutability: "view";
59
+ readonly type: "function";
60
+ }];
61
+ functionName: string;
62
+ chainId: number;
63
+ args: `0x${string}`[];
64
+ }[], true, boolean>;
@@ -8,6 +8,7 @@ export declare const usePoolDynamicContractData: ({ address, chainId, }: PoolDyn
8
8
  isFetched: boolean;
9
9
  userBalance?: string | undefined;
10
10
  tokenPrice?: string | undefined;
11
+ getExitRemainingCooldown?: string | undefined;
11
12
  totalSupply?: string | undefined;
12
13
  isPrivateVault?: boolean | undefined;
13
14
  performanceFee?: string | undefined;
@@ -439,6 +439,54 @@ export declare const useDepositQuoteContractRead: ({ address, chainId, }: Pick<P
439
439
  }];
440
440
  readonly stateMutability: "view";
441
441
  readonly type: "function";
442
+ }, {
443
+ readonly inputs: readonly [{
444
+ readonly internalType: "address";
445
+ readonly name: "_dHedgeVault";
446
+ readonly type: "address";
447
+ }, {
448
+ readonly internalType: "uint256";
449
+ readonly name: "_amountIn";
450
+ readonly type: "uint256";
451
+ }, {
452
+ readonly components: readonly [{
453
+ readonly internalType: "address";
454
+ readonly name: "supportedAsset";
455
+ readonly type: "address";
456
+ }, {
457
+ readonly internalType: "bytes";
458
+ readonly name: "withdrawData";
459
+ readonly type: "bytes";
460
+ }, {
461
+ readonly internalType: "uint256";
462
+ readonly name: "slippageTolerance";
463
+ readonly type: "uint256";
464
+ }];
465
+ readonly internalType: "struct IPoolLogic.ComplexAsset[]";
466
+ readonly name: "_complexAssetsData";
467
+ readonly type: "tuple[]";
468
+ }];
469
+ readonly name: "initWithdrawal";
470
+ readonly outputs: readonly [{
471
+ readonly components: readonly [{
472
+ readonly internalType: "address";
473
+ readonly name: "token";
474
+ readonly type: "address";
475
+ }, {
476
+ readonly internalType: "uint256";
477
+ readonly name: "balance";
478
+ readonly type: "uint256";
479
+ }];
480
+ readonly internalType: "struct IWithdrawalVault.TrackedAsset[]";
481
+ readonly name: "trackedAssets";
482
+ readonly type: "tuple[]";
483
+ }, {
484
+ readonly internalType: "address";
485
+ readonly name: "vault";
486
+ readonly type: "address";
487
+ }];
488
+ readonly stateMutability: "nonpayable";
489
+ readonly type: "function";
442
490
  }, {
443
491
  readonly inputs: readonly [{
444
492
  readonly internalType: "address";
@@ -682,6 +730,50 @@ export declare const useDepositQuoteContractRead: ({ address, chainId, }: Pick<P
682
730
  }];
683
731
  readonly stateMutability: "nonpayable";
684
732
  readonly type: "function";
733
+ }, {
734
+ readonly inputs: readonly [{
735
+ readonly internalType: "address";
736
+ readonly name: "_dHedgeVault";
737
+ readonly type: "address";
738
+ }, {
739
+ readonly internalType: "uint256";
740
+ readonly name: "_amountIn";
741
+ readonly type: "uint256";
742
+ }, {
743
+ readonly components: readonly [{
744
+ readonly internalType: "address";
745
+ readonly name: "supportedAsset";
746
+ readonly type: "address";
747
+ }, {
748
+ readonly internalType: "bytes";
749
+ readonly name: "withdrawData";
750
+ readonly type: "bytes";
751
+ }, {
752
+ readonly internalType: "uint256";
753
+ readonly name: "slippageTolerance";
754
+ readonly type: "uint256";
755
+ }];
756
+ readonly internalType: "struct IPoolLogic.ComplexAsset[]";
757
+ readonly name: "_complexAssetsData";
758
+ readonly type: "tuple[]";
759
+ }];
760
+ readonly name: "unrollAndClaim";
761
+ readonly outputs: readonly [{
762
+ readonly components: readonly [{
763
+ readonly internalType: "address";
764
+ readonly name: "token";
765
+ readonly type: "address";
766
+ }, {
767
+ readonly internalType: "uint256";
768
+ readonly name: "balance";
769
+ readonly type: "uint256";
770
+ }];
771
+ readonly internalType: "struct IWithdrawalVault.TrackedAsset[]";
772
+ readonly name: "";
773
+ readonly type: "tuple[]";
774
+ }];
775
+ readonly stateMutability: "nonpayable";
776
+ readonly type: "function";
685
777
  }, {
686
778
  readonly inputs: readonly [];
687
779
  readonly name: "weth";
@@ -1,6 +1,12 @@
1
1
  import { type UseQueryOptions } from '@tanstack/react-query';
2
2
  import type { Address } from 'viem';
3
+ import { useGetSwapData } from 'core-kit/hooks/state';
3
4
  import type { SwapDataRequest, SwapDataResponse } from 'core-kit/types';
5
+ export declare const fetchSwapsData: ({ assets, getSwapData, signal, }: {
6
+ assets: Omit<SwapDataRequest, 'fromAddress'>[];
7
+ getSwapData: ReturnType<typeof useGetSwapData>;
8
+ signal: AbortSignal;
9
+ }) => Promise<Record<Address, SwapDataResponse>>;
4
10
  export declare const useSwapsDataQuery: (assets: Omit<SwapDataRequest, 'fromAddress'>[], options?: Omit<UseQueryOptions<Record<Address, SwapDataResponse | null>, Error, Record<Address, SwapDataResponse | null>, [
5
11
  string,
6
12
  Omit<SwapDataRequest, 'fromAddress'>[]
@@ -1,6 +1,6 @@
1
1
  export { useIsMultiAssetWithdraw } from './use-is-multi-asset-withdraw';
2
2
  export { useInitWithdrawAllowance } from './use-init-withdraw-allowance';
3
3
  export { useInitWithdrawTransaction } from './use-init-withdraw-transaction';
4
- export { useInitWithdrawTransactionArguments } from './use-init-withdraw-transaction-arguments';
4
+ export { useInitWithdrawTransactionArgumentsForSimulationOnly, useGetInitWithdrawTransactionArguments, } from './use-get-init-withdraw-transaction-arguments';
5
5
  export { useInitWithdrawEstimatedReceiveAssets } from './use-init-withdraw-estimated-receive-assets';
6
6
  export { useIsUnrollAndClaimTransaction } from './use-is-unroll-and-claim-transaction';
@@ -0,0 +1,6 @@
1
+ import type { CalculateSwapDataParamsResponse, PoolConfig } from 'core-kit/types';
2
+ export interface FetchAaveSwapParamsProps {
3
+ withdrawAmount: bigint;
4
+ slippage: number;
5
+ }
6
+ export declare const useFetchAaveSwapParams: ({ address, chainId, }: Pick<PoolConfig, 'address' | 'chainId'>) => ({ withdrawAmount, slippage, }: FetchAaveSwapParamsProps) => Promise<CalculateSwapDataParamsResponse | undefined>;
@@ -0,0 +1,5 @@
1
+ import type { CalculateSwapDataParamsResponse, PoolConfig } from 'core-kit/types';
2
+ export declare const useFetchInitWithdrawAaveSwapData: ({ chainId, }: Pick<PoolConfig, 'chainId'>) => ({ swapParams, slippage, }: {
3
+ swapParams: CalculateSwapDataParamsResponse | undefined;
4
+ slippage: number;
5
+ }) => Promise<Record<`0x${string}`, import("core-kit/types").SwapDataResponse>>;
@@ -0,0 +1,5 @@
1
+ import type { FetchAaveSwapParamsProps } from 'core-kit/hooks/trading/withdraw-v2/init-step/use-fetch-aave-swap-params';
2
+ import type { ComplexWithdrawAssetData, PoolConfig } from 'core-kit/types';
3
+ export declare const useFetchInitWithdrawComplexAssetData: ({ address, chainId, }: Pick<PoolConfig, 'address' | 'chainId'>) => ({ withdrawAmount, slippage, disabled, }: FetchAaveSwapParamsProps & {
4
+ disabled?: boolean | undefined;
5
+ }) => Promise<ComplexWithdrawAssetData[]>;
@@ -0,0 +1,10 @@
1
+ interface UseGetInitWithdrawTransactionArguments {
2
+ debounceTime?: number;
3
+ }
4
+ export declare const useGetInitWithdrawTransactionArguments: () => () => Promise<(bigint | `0x${string}` | import("../../../../types").ComplexWithdrawAssetData[])[]>;
5
+ export declare const useInitWithdrawTransactionArgumentsForSimulationOnly: ({ debounceTime, }?: UseGetInitWithdrawTransactionArguments) => (bigint | `0x${string}` | {
6
+ supportedAsset: `0x${string}`;
7
+ withdrawData: string;
8
+ slippageTolerance: bigint;
9
+ }[])[];
10
+ export {};