@talken/talkenkit 2.4.15 → 2.4.17
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/abcWallet-54KUGWUZ.js +192 -0
- package/dist/abcWallet-KZHOADBJ.js +192 -0
- package/dist/abcWallet-NZAVB4PI.js +190 -0
- package/dist/chunk-5X3ROW3U.js +8777 -0
- package/dist/chunk-DKA3NVFM.js +8497 -0
- package/dist/chunk-QNZ5HSPM.js +8339 -0
- package/dist/chunk-VE53ZNZV.js +331 -0
- package/dist/components/ConfirmationModal/ApproveSection.css.d.ts +16 -0
- package/dist/components/ConfirmationModal/ApproveSection.d.ts +8 -0
- package/dist/components/ConfirmationModal/NFTPlaceholder.css.d.ts +7 -0
- package/dist/components/ConfirmationModal/NFTPlaceholder.d.ts +8 -0
- package/dist/components/ConfirmationModal/NftApprovalSection.css.d.ts +10 -0
- package/dist/components/ConfirmationModal/NftApprovalSection.d.ts +7 -0
- package/dist/components/ConfirmationModal/SignConfirmationModal.css.d.ts +35 -0
- package/dist/components/ConfirmationModal/SignConfirmationModal.d.ts +17 -0
- package/dist/components/ConfirmationModal/SwapSection.css.d.ts +17 -0
- package/dist/components/ConfirmationModal/SwapSection.d.ts +7 -0
- package/dist/components/ConfirmationModal/TransactionConfirmationModal.css.d.ts +49 -0
- package/dist/components/ConfirmationModal/TransactionConfirmationModal.d.ts +12 -0
- package/dist/components/ConfirmationModal/TransferSection.css.d.ts +17 -0
- package/dist/components/ConfirmationModal/TransferSection.d.ts +7 -0
- package/dist/components/ConfirmationModal/commonStyles.css.d.ts +37 -0
- package/dist/components/ConfirmationModal/constants.d.ts +16 -0
- package/dist/components/ConfirmationModal/index.d.ts +9 -0
- package/dist/components/ConfirmationModal/modalTheme.css.d.ts +20 -0
- package/dist/components/ConfirmationModal/transactionUIRegistry.d.ts +134 -0
- package/dist/components/ConfirmationModal/utils.d.ts +37 -0
- package/dist/components/ConnectOptions/AbcWaasAuth/AbcWaasAuthSections.css.d.ts +1 -0
- package/dist/components/ConnectOptions/AbcWaasAuth/AbcWaasAuthSections.d.ts +1 -1
- package/dist/components/ConnectOptions/AbcWaasAuth/hooks/useAbcWaasAuth.d.ts +2 -25
- package/dist/components/ConnectOptions/AbcWaasAuth/hooks/useAbcWaasSocial.d.ts +1 -47
- package/dist/components/ConnectOptions/PinAuth/hooks/useWalletGeneration.d.ts +4 -21
- package/dist/components/GasFeeModal/GasFeeEditModal.css.d.ts +32 -0
- package/dist/components/GasFeeModal/GasFeeEditModal.d.ts +21 -0
- package/dist/components/GasFeeModal/index.d.ts +3 -0
- package/dist/components/GasFeeModal/modalTheme.css.d.ts +19 -0
- package/dist/components/Icons/Close2.d.ts +7 -0
- package/dist/components/Icons/Copy2.d.ts +4 -0
- package/dist/components/Icons/Dropdown2.d.ts +4 -0
- package/dist/components/Icons/Edit.d.ts +4 -0
- package/dist/components/Icons/InfoCircle.d.ts +4 -0
- package/dist/components/Icons/Kakao.d.ts +2 -0
- package/dist/components/Icons/Minus.d.ts +4 -0
- package/dist/components/Icons/Plus.d.ts +4 -0
- package/dist/components/Icons/SettingsGear.d.ts +4 -0
- package/dist/components/Icons/SpeedHigh.d.ts +4 -0
- package/dist/components/Icons/SpeedLow.d.ts +4 -0
- package/dist/components/Icons/SpeedMedium.d.ts +4 -0
- package/dist/components/RainbowKitProvider/InternalPinProvider.d.ts +7 -9
- package/dist/components/RainbowKitProvider/RainbowKitConfigProvider.d.ts +1 -6
- package/dist/components/RainbowKitProvider/RainbowKitProvider.d.ts +7 -7
- package/dist/components/Toast/Toast.css.d.ts +2 -0
- package/dist/components/Toast/Toast.d.ts +6 -0
- package/dist/components/Toast/index.d.ts +4 -0
- package/dist/components/Toast/useToast.d.ts +10 -0
- package/dist/config/networks.d.ts +10 -0
- package/dist/css/sprinkles.css.d.ts +1 -1
- package/dist/hooks/useSolanaWallet.d.ts +5 -23
- package/dist/hooks/useTronWallet.d.ts +63 -0
- package/dist/index.css +1903 -236
- package/dist/index.d.ts +8 -3
- package/dist/index.js +7557 -3592
- package/dist/klipWallet-RD5Y4UEK.js +8 -0
- package/dist/providers/SignConfirmationProvider/SignConfirmationProvider.d.ts +22 -0
- package/dist/providers/SignConfirmationProvider/index.d.ts +6 -0
- package/dist/providers/SignConfirmationProvider/requestParsers.d.ts +24 -0
- package/dist/providers/SignConfirmationProvider/types.d.ts +91 -0
- package/dist/providers/SignConfirmationProvider/useApiClient.d.ts +15 -0
- package/dist/providers/SignConfirmationProvider/useTransactionResolver.d.ts +18 -0
- package/dist/secure-AEBFSVWE.js +8 -0
- package/dist/services/AbcAgenticWalletService.d.ts +111 -0
- package/dist/services/AbcAuthService.d.ts +26 -20
- package/dist/types/index.d.ts +3 -0
- package/dist/types/token.d.ts +82 -0
- package/dist/utils/abi/abiDecoder.d.ts +144 -0
- package/dist/utils/apiClientFactory.d.ts +21 -0
- package/dist/utils/blockies.d.ts +12 -0
- package/dist/utils/tokenMapper.d.ts +10 -0
- package/dist/wallets/walletConnectors/abcWallet/abcApi.d.ts +4 -1
- package/dist/wallets/walletConnectors/abcWallet/abcApi.js +7 -7
- package/dist/wallets/walletConnectors/abcWallet/abcBitcoinConnector.js +5 -5
- package/dist/wallets/walletConnectors/abcWallet/abcBitcoinProvider.d.ts +6 -8
- package/dist/wallets/walletConnectors/abcWallet/abcBitcoinProvider.js +1 -1
- package/dist/wallets/walletConnectors/abcWallet/abcConnector.js +9 -9
- package/dist/wallets/walletConnectors/abcWallet/abcProvider.d.ts +17 -6
- package/dist/wallets/walletConnectors/abcWallet/abcProvider.js +5 -4
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaProvider.d.ts +11 -34
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaProvider.js +1 -1
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaWalletAdapter.d.ts +3 -11
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaWalletAdapter.js +17 -80
- package/dist/wallets/walletConnectors/abcWallet/abcTronProvider.d.ts +112 -0
- package/dist/wallets/walletConnectors/abcWallet/abcTronProvider.js +11 -0
- package/dist/wallets/walletConnectors/abcWallet/abcWallet.d.ts +2 -0
- package/dist/wallets/walletConnectors/abcWallet/abcWallet.js +11 -10
- package/dist/wallets/walletConnectors/abcWallet/api/AuthApi.d.ts +9 -11
- package/dist/wallets/walletConnectors/abcWallet/api/AuthApi.js +6 -6
- package/dist/wallets/walletConnectors/abcWallet/api/BaseApiClient.d.ts +1 -1
- package/dist/wallets/walletConnectors/abcWallet/api/BaseApiClient.js +5 -5
- package/dist/wallets/walletConnectors/abcWallet/api/BitcoinApi.js +6 -6
- package/dist/wallets/walletConnectors/abcWallet/api/GasApi.d.ts +45 -0
- package/dist/wallets/walletConnectors/abcWallet/api/GasApi.js +12 -0
- package/dist/wallets/walletConnectors/abcWallet/api/SigningApi.js +7 -7
- package/dist/wallets/walletConnectors/abcWallet/api/SolanaApi.d.ts +9 -1
- package/dist/wallets/walletConnectors/abcWallet/api/SolanaApi.js +7 -7
- package/dist/wallets/walletConnectors/abcWallet/api/TalkenApiClient.d.ts +333 -0
- package/dist/wallets/walletConnectors/abcWallet/api/TalkenApiClient.js +11 -0
- package/dist/wallets/walletConnectors/abcWallet/api/TalkenApiSingleton.d.ts +18 -0
- package/dist/wallets/walletConnectors/abcWallet/api/TalkenApiSingleton.js +14 -0
- package/dist/wallets/walletConnectors/abcWallet/api/TransactionApi.d.ts +2 -2
- package/dist/wallets/walletConnectors/abcWallet/api/TransactionApi.js +7 -7
- package/dist/wallets/walletConnectors/abcWallet/api/TronApi.d.ts +102 -0
- package/dist/wallets/walletConnectors/abcWallet/api/TronApi.js +12 -0
- package/dist/wallets/walletConnectors/abcWallet/api/WalletApi.d.ts +4 -2
- package/dist/wallets/walletConnectors/abcWallet/api/WalletApi.js +7 -7
- package/dist/wallets/walletConnectors/abcWallet/api/WalletscanApi.d.ts +60 -0
- package/dist/wallets/walletConnectors/abcWallet/api/WalletscanApi.js +12 -0
- package/dist/wallets/walletConnectors/abcWallet/api/index.d.ts +24 -0
- package/dist/wallets/walletConnectors/abcWallet/api/index.js +35 -17
- package/dist/wallets/walletConnectors/abcWallet/constants.d.ts +39 -1
- package/dist/wallets/walletConnectors/abcWallet/constants.js +5 -1
- package/dist/wallets/walletConnectors/abcWallet/googleAuth.d.ts +6 -0
- package/dist/wallets/walletConnectors/abcWallet/googleAuth.js +37 -1
- package/dist/wallets/walletConnectors/abcWallet/index.d.ts +5 -3
- package/dist/wallets/walletConnectors/abcWallet/index.js +44 -31
- package/dist/wallets/walletConnectors/abcWallet/kakaoAuth.d.ts +27 -0
- package/dist/wallets/walletConnectors/abcWallet/kakaoAuth.js +290 -0
- package/dist/wallets/walletConnectors/abcWallet/networkConfig.d.ts +39 -3
- package/dist/wallets/walletConnectors/abcWallet/networkConfig.js +11 -3
- package/dist/wallets/walletConnectors/abcWallet/secure.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/sessionUtils.js +1 -1
- package/dist/wallets/walletConnectors/abcWallet/types.d.ts +369 -7
- package/dist/wallets/walletConnectors/abcWallet/types.js +5 -3
- package/dist/wallets/walletConnectors/abcWallet/utils.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/walletGeneration.d.ts +10 -19
- package/dist/wallets/walletConnectors/abcWallet/walletGeneration.js +2 -2
- package/dist/wallets/walletConnectors/berasigWallet/berasigWallet.js +2 -2
- package/dist/wallets/walletConnectors/bifrostWallet/bifrostWallet.js +2 -2
- package/dist/wallets/walletConnectors/binanceWallet/binanceWallet.js +2 -2
- package/dist/wallets/walletConnectors/bitgetWallet/bitgetWallet.js +2 -2
- package/dist/wallets/walletConnectors/bybitWallet/bybitWallet.js +2 -2
- package/dist/wallets/walletConnectors/chunk-25V3FW3O.js +282 -0
- package/dist/wallets/walletConnectors/chunk-27346T3J.js +134 -0
- package/dist/wallets/walletConnectors/chunk-5CNLMOB2.js +75 -0
- package/dist/wallets/walletConnectors/chunk-5K45TCAM.js +333 -0
- package/dist/wallets/walletConnectors/chunk-5VDSMZC4.js +286 -0
- package/dist/wallets/walletConnectors/chunk-5W7RBMPH.js +351 -0
- package/dist/wallets/walletConnectors/chunk-5XORKEWE.js +326 -0
- package/dist/wallets/walletConnectors/chunk-63WBO52A.js +77 -0
- package/dist/wallets/walletConnectors/chunk-7IRF225N.js +75 -0
- package/dist/wallets/walletConnectors/chunk-7QHCSJDN.js +726 -0
- package/dist/wallets/walletConnectors/chunk-A27H6PEU.js +739 -0
- package/dist/wallets/walletConnectors/chunk-A4WR3CFN.js +130 -0
- package/dist/wallets/walletConnectors/chunk-A6FUNQWF.js +572 -0
- package/dist/wallets/walletConnectors/chunk-AF4OCS7N.js +46 -0
- package/dist/wallets/walletConnectors/chunk-AFWBXEEC.js +66 -0
- package/dist/wallets/walletConnectors/chunk-AUGP2LJR.js +182 -0
- package/dist/wallets/walletConnectors/chunk-AWLDVQXC.js +317 -0
- package/dist/wallets/walletConnectors/chunk-BLEKTKBN.js +479 -0
- package/dist/wallets/walletConnectors/chunk-BVL6G5HI.js +1757 -0
- package/dist/wallets/walletConnectors/chunk-CMTGEHDI.js +485 -0
- package/dist/wallets/walletConnectors/chunk-D5EFTEOM.js +56 -0
- package/dist/wallets/walletConnectors/chunk-DM5NLSWD.js +346 -0
- package/dist/wallets/walletConnectors/chunk-EBGI4D2T.js +69 -0
- package/dist/wallets/walletConnectors/chunk-EEH2HMFG.js +47 -0
- package/dist/wallets/walletConnectors/chunk-F5JWDBKK.js +47 -0
- package/dist/wallets/walletConnectors/chunk-FN67MIIH.js +75 -0
- package/dist/wallets/walletConnectors/chunk-FWYVBX5F.js +75 -0
- package/dist/wallets/walletConnectors/chunk-GH6ZDY4K.js +58 -0
- package/dist/wallets/walletConnectors/chunk-GIJZMIBD.js +63 -0
- package/dist/wallets/walletConnectors/chunk-GO6OLTNF.js +479 -0
- package/dist/wallets/walletConnectors/chunk-HKXBK3NY.js +75 -0
- package/dist/wallets/walletConnectors/chunk-HMD2WWFQ.js +75 -0
- package/dist/wallets/walletConnectors/chunk-HO5Z2CTL.js +280 -0
- package/dist/wallets/walletConnectors/chunk-I3GFVK5O.js +151 -0
- package/dist/wallets/walletConnectors/chunk-IUHZ5ZCE.js +121 -0
- package/dist/wallets/walletConnectors/chunk-JODNZWWG.js +330 -0
- package/dist/wallets/walletConnectors/chunk-JTST3KMW.js +75 -0
- package/dist/wallets/walletConnectors/chunk-KH2L3ONV.js +1599 -0
- package/dist/wallets/walletConnectors/chunk-LHV22375.js +182 -0
- package/dist/wallets/walletConnectors/chunk-LZZE462U.js +315 -0
- package/dist/wallets/walletConnectors/chunk-MGCRUAHX.js +276 -0
- package/dist/wallets/walletConnectors/chunk-MURSKRMJ.js +63 -0
- package/dist/wallets/walletConnectors/chunk-NG7PSAPX.js +115 -0
- package/dist/wallets/walletConnectors/chunk-NHP6D6AH.js +204 -0
- package/dist/wallets/walletConnectors/chunk-O4AU63LK.js +181 -0
- package/dist/wallets/walletConnectors/chunk-OBS74J5N.js +221 -0
- package/dist/wallets/walletConnectors/chunk-ON4U54WO.js +115 -0
- package/dist/wallets/walletConnectors/chunk-PPYBE5TV.js +276 -0
- package/dist/wallets/walletConnectors/chunk-PWWSAM4G.js +309 -0
- package/dist/wallets/walletConnectors/chunk-QB5GDLRU.js +330 -0
- package/dist/wallets/walletConnectors/chunk-QMLG7MAP.js +107 -0
- package/dist/wallets/walletConnectors/chunk-RGIB7FFH.js +47 -0
- package/dist/wallets/walletConnectors/chunk-SHJBMDP4.js +278 -0
- package/dist/wallets/walletConnectors/chunk-SOBJYYIX.js +484 -0
- package/dist/wallets/walletConnectors/chunk-T66U3ADD.js +58 -0
- package/dist/wallets/walletConnectors/chunk-THCKLFSJ.js +75 -0
- package/dist/wallets/walletConnectors/chunk-TS466TDR.js +286 -0
- package/dist/wallets/walletConnectors/chunk-UJGFYQEV.js +459 -0
- package/dist/wallets/walletConnectors/chunk-UXNEBBUV.js +224 -0
- package/dist/wallets/walletConnectors/chunk-VRCNFVPM.js +276 -0
- package/dist/wallets/walletConnectors/chunk-WODNUC65.js +333 -0
- package/dist/wallets/walletConnectors/chunk-X6A2FSHK.js +484 -0
- package/dist/wallets/walletConnectors/chunk-XVRNEES5.js +1541 -0
- package/dist/wallets/walletConnectors/chunk-XWVM2Y5A.js +306 -0
- package/dist/wallets/walletConnectors/chunk-XXG7ABSJ.js +328 -0
- package/dist/wallets/walletConnectors/chunk-YJH4BHSB.js +254 -0
- package/dist/wallets/walletConnectors/chunk-YRDNIP2H.js +90 -0
- package/dist/wallets/walletConnectors/chunk-YTPAWPCA.js +156 -0
- package/dist/wallets/walletConnectors/chunk-ZCSHD7UG.js +562 -0
- package/dist/wallets/walletConnectors/chunk-ZZCZ3RJU.js +272 -0
- package/dist/wallets/walletConnectors/clvWallet/clvWallet.js +2 -2
- package/dist/wallets/walletConnectors/coin98Wallet/coin98Wallet.js +2 -2
- package/dist/wallets/walletConnectors/coreWallet/coreWallet.js +2 -2
- package/dist/wallets/walletConnectors/foxWallet/foxWallet.js +2 -2
- package/dist/wallets/walletConnectors/frontierWallet/frontierWallet.js +2 -2
- package/dist/wallets/walletConnectors/gateWallet/gateWallet.js +2 -2
- package/dist/wallets/walletConnectors/index.js +62 -61
- package/dist/wallets/walletConnectors/iopayWallet/iopayWallet.js +2 -2
- package/dist/wallets/walletConnectors/kaiaWallet/kaiaWallet.js +2 -2
- package/dist/wallets/walletConnectors/kaikasWallet/kaikasWallet.js +2 -2
- package/dist/wallets/walletConnectors/klipWallet/klipWallet.d.ts +3 -0
- package/dist/wallets/walletConnectors/klipWallet/klipWallet.js +8 -0
- package/dist/wallets/walletConnectors/klipWallet-PPTYYB5G.js +7 -0
- package/dist/wallets/walletConnectors/metaMaskWallet/metaMaskWallet.js +2 -2
- package/dist/wallets/walletConnectors/okxWallet/okxWallet.js +2 -2
- package/dist/wallets/walletConnectors/rainbowWallet/rainbowWallet.js +2 -2
- package/dist/wallets/walletConnectors/roninWallet/roninWallet.js +2 -2
- package/dist/wallets/walletConnectors/safepalWallet/safepalWallet.js +2 -2
- package/dist/wallets/walletConnectors/subWallet/subWallet.js +2 -2
- package/dist/wallets/walletConnectors/tokenPocketWallet/tokenPocketWallet.js +2 -2
- package/dist/wallets/walletConnectors/trustWallet/trustWallet.js +2 -2
- package/dist/wallets/walletConnectors/zealWallet/zealWallet.js +2 -2
- package/dist/wallets/walletConnectors/zerionWallet/zerionWallet.js +2 -2
- package/package.json +2 -1
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Transaction UI Registry
|
|
3
|
+
*
|
|
4
|
+
* Factory pattern for transaction type detection and UI component mapping.
|
|
5
|
+
* Detection is based on Method IDs (function selectors) for reliability.
|
|
6
|
+
*
|
|
7
|
+
* Parameter extraction uses ABIDecoder (selector_index.json) - no duplicate decoders needed.
|
|
8
|
+
* Adding new transaction types:
|
|
9
|
+
* 1. Add method ID to METHOD_IDS constant
|
|
10
|
+
* 2. Add method ID to appropriate registry entry's methodIds array
|
|
11
|
+
* 3. If needed, add function name to FUNCTION_NAME_PATTERNS for fallback detection
|
|
12
|
+
* 4. Add parameter mapping to mapParametersToXxx function if parameter names differ
|
|
13
|
+
*/
|
|
14
|
+
import React from 'react';
|
|
15
|
+
import type { ApproveInfo, NftApprovalInfo, SwapInfo, TransferInfo } from '../../providers/SignConfirmationProvider';
|
|
16
|
+
import type { DecodedTransaction } from '../../utils/abi/abiDecoder';
|
|
17
|
+
/**
|
|
18
|
+
* Simplified transaction types for UI display
|
|
19
|
+
*/
|
|
20
|
+
export type FunctionType = 'transfer' | 'approve' | 'swap' | 'nftApproval' | 'common';
|
|
21
|
+
/**
|
|
22
|
+
* Decoded data for each transaction type
|
|
23
|
+
*/
|
|
24
|
+
export interface DecodedApprove {
|
|
25
|
+
spender: string;
|
|
26
|
+
amount: bigint;
|
|
27
|
+
}
|
|
28
|
+
export interface DecodedTransfer {
|
|
29
|
+
recipient: string;
|
|
30
|
+
amount: bigint;
|
|
31
|
+
}
|
|
32
|
+
export interface DecodedTransferFrom {
|
|
33
|
+
from: string;
|
|
34
|
+
recipient: string;
|
|
35
|
+
amount: bigint;
|
|
36
|
+
}
|
|
37
|
+
export interface DecodedSwap {
|
|
38
|
+
srcToken: string;
|
|
39
|
+
dstToken: string;
|
|
40
|
+
amount: bigint;
|
|
41
|
+
minReturnAmount: bigint;
|
|
42
|
+
}
|
|
43
|
+
export interface DecodedNftApproval {
|
|
44
|
+
operator: string;
|
|
45
|
+
approved: boolean;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* UI configuration for each transaction type
|
|
49
|
+
*/
|
|
50
|
+
export interface TransactionUIConfig {
|
|
51
|
+
title: string;
|
|
52
|
+
button: string;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Props passed to type-specific UI components
|
|
56
|
+
* Union type to support different transaction types
|
|
57
|
+
*/
|
|
58
|
+
export type TransactionSectionProps = {
|
|
59
|
+
type: 'approve';
|
|
60
|
+
approveInfo: ApproveInfo;
|
|
61
|
+
onAmountChange?: (newAmount: string) => void;
|
|
62
|
+
} | {
|
|
63
|
+
type: 'transfer';
|
|
64
|
+
transferInfo: TransferInfo;
|
|
65
|
+
} | {
|
|
66
|
+
type: 'swap';
|
|
67
|
+
swapInfo: SwapInfo;
|
|
68
|
+
} | {
|
|
69
|
+
type: 'nftApproval';
|
|
70
|
+
nftApprovalInfo: NftApprovalInfo;
|
|
71
|
+
};
|
|
72
|
+
/**
|
|
73
|
+
* Map ABIDecoder parameters to DecodedApprove
|
|
74
|
+
* Handles various parameter naming conventions (spender/_spender, amount/_value/value)
|
|
75
|
+
*/
|
|
76
|
+
export declare function mapParametersToApprove(params: Record<string, unknown>): DecodedApprove | null;
|
|
77
|
+
/**
|
|
78
|
+
* Map ABIDecoder parameters to DecodedTransfer
|
|
79
|
+
*/
|
|
80
|
+
export declare function mapParametersToTransfer(params: Record<string, unknown>): DecodedTransfer | null;
|
|
81
|
+
/**
|
|
82
|
+
* Map ABIDecoder parameters to DecodedTransferFrom
|
|
83
|
+
*/
|
|
84
|
+
export declare function mapParametersToTransferFrom(params: Record<string, unknown>): DecodedTransferFrom | null;
|
|
85
|
+
/**
|
|
86
|
+
* Map ABIDecoder parameters to DecodedSwap
|
|
87
|
+
* Handles different DEX parameter conventions:
|
|
88
|
+
* - 1inch V5: desc.srcToken, desc.dstToken, desc.amount, desc.minReturnAmount
|
|
89
|
+
* - Uniswap V2: path[0], path[-1], amountIn, amountOutMin
|
|
90
|
+
* - Uniswap V3: params.tokenIn, params.tokenOut, params.amountIn, params.amountOutMinimum
|
|
91
|
+
*/
|
|
92
|
+
export declare function mapParametersToSwap(params: Record<string, unknown>, _functionName?: string): DecodedSwap | null;
|
|
93
|
+
/**
|
|
94
|
+
* Map ABIDecoder parameters to DecodedNftApproval
|
|
95
|
+
*/
|
|
96
|
+
export declare function mapParametersToNftApproval(params: Record<string, unknown>): DecodedNftApproval | null;
|
|
97
|
+
/**
|
|
98
|
+
* Detect function type from calldata using Method ID
|
|
99
|
+
* Primary detection uses Method ID matching.
|
|
100
|
+
* Falls back to ABIDecoder result if method ID not found in registry.
|
|
101
|
+
*
|
|
102
|
+
* @param data - Transaction calldata (hex string)
|
|
103
|
+
* @param decoded - Decoded transaction from ABIDecoder (optional fallback)
|
|
104
|
+
*/
|
|
105
|
+
export declare function getFunctionType(data: string, decoded?: DecodedTransaction | null): FunctionType;
|
|
106
|
+
/**
|
|
107
|
+
* Get UI configuration for a transaction type
|
|
108
|
+
*/
|
|
109
|
+
export declare function getTransactionConfig(type: FunctionType): TransactionUIConfig;
|
|
110
|
+
/**
|
|
111
|
+
* Get UI component for a transaction type (if exists)
|
|
112
|
+
*/
|
|
113
|
+
export declare function getTransactionComponent(type: FunctionType): React.ComponentType<any> | undefined;
|
|
114
|
+
/**
|
|
115
|
+
* Map ABIDecoder output to typed transaction data
|
|
116
|
+
* Uses decodedFunction.parameters from ABIDecoder instead of re-parsing raw data
|
|
117
|
+
*
|
|
118
|
+
* @param type - Function type (approve, swap, transfer, nftApproval)
|
|
119
|
+
* @param decoded - DecodedTransaction from ABIDecoder
|
|
120
|
+
*/
|
|
121
|
+
export declare function mapDecodedTransaction<T = unknown>(type: FunctionType, decoded: DecodedTransaction | null | undefined): T | null;
|
|
122
|
+
/**
|
|
123
|
+
* @deprecated Use mapDecodedTransaction with ABIDecoder output instead
|
|
124
|
+
* Keeping for backward compatibility - will be removed in future version
|
|
125
|
+
*/
|
|
126
|
+
export declare function decodeTransactionData<T = unknown>(_type: FunctionType, _data: string): T | null;
|
|
127
|
+
/**
|
|
128
|
+
* Format token amount from raw bigint to human-readable string
|
|
129
|
+
*/
|
|
130
|
+
export declare function formatTokenAmount(amount: bigint, decimals: number): string;
|
|
131
|
+
/**
|
|
132
|
+
* Check if amount is unlimited (max uint256)
|
|
133
|
+
*/
|
|
134
|
+
export declare function isUnlimitedAmount(amount: bigint): boolean;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ConfirmationModal shared utilities
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Truncate Ethereum address for display
|
|
6
|
+
* @example truncateAddress('0x1234567890abcdef1234567890abcdef12345678') → '0x1234...5678'
|
|
7
|
+
*/
|
|
8
|
+
export declare function truncateAddress(address: string): string;
|
|
9
|
+
/**
|
|
10
|
+
* Calculate tooltip position relative to modal container
|
|
11
|
+
* Sets CSS custom properties on the tooltip element
|
|
12
|
+
*/
|
|
13
|
+
export declare function calculateTooltipPosition(wrapperRect: DOMRect, modalRect: DOMRect, tooltip: HTMLElement): void;
|
|
14
|
+
/**
|
|
15
|
+
* Handle tooltip positioning on mouse enter
|
|
16
|
+
* Use this in onMouseEnter handler for info icons
|
|
17
|
+
*
|
|
18
|
+
* @param e - Mouse event from the wrapper element
|
|
19
|
+
* @param containerRef - Ref to the section/modal container
|
|
20
|
+
* @param isDirectModalRef - If true, containerRef IS the modal (no need for closest())
|
|
21
|
+
*/
|
|
22
|
+
export declare function handleTooltipMouseEnter(e: React.MouseEvent<HTMLSpanElement>, containerRef: React.RefObject<HTMLElement | null>, isDirectModalRef?: boolean): void;
|
|
23
|
+
/**
|
|
24
|
+
* Convert hex value to Gwei string (uses viem)
|
|
25
|
+
* @example hexToGwei('0x3b9aca00') → '1.00'
|
|
26
|
+
*/
|
|
27
|
+
export declare function hexToGwei(hex: string): string;
|
|
28
|
+
/**
|
|
29
|
+
* Recursively format EIP-712 typed data value for display
|
|
30
|
+
* Handles nested objects, arrays, and truncates addresses
|
|
31
|
+
*
|
|
32
|
+
* @param key - Property key
|
|
33
|
+
* @param value - Property value (can be nested)
|
|
34
|
+
* @param indent - Current indentation level
|
|
35
|
+
* @returns Array of formatted lines
|
|
36
|
+
*/
|
|
37
|
+
export declare function formatTypedDataValue(key: string, value: unknown, indent?: string): string[];
|
|
@@ -4,5 +4,6 @@ export declare const emailInputStyle: string;
|
|
|
4
4
|
export declare const submitButtonStyle: string;
|
|
5
5
|
export declare const submitArrow: string;
|
|
6
6
|
export declare const socialButtonsContainer: string;
|
|
7
|
+
export declare const socialIconWrapper: string;
|
|
7
8
|
export declare const socialButtonStyle: string;
|
|
8
9
|
export declare const socialButtonText: string;
|
|
@@ -11,7 +11,7 @@ export interface AbcWaasAuthSectionsProps {
|
|
|
11
11
|
isAbcWaasLoading: boolean;
|
|
12
12
|
compactModeEnabled: boolean;
|
|
13
13
|
handleEmailSubmit: (email: string) => Promise<void>;
|
|
14
|
-
handleSocialLogin: (provider: 'google' | 'apple') => Promise<void>;
|
|
14
|
+
handleSocialLogin: (provider: 'google' | 'apple' | 'kakao') => Promise<void>;
|
|
15
15
|
handlePasswordSubmit: (e: React.FormEvent) => Promise<void>;
|
|
16
16
|
handleOtpSubmit: (e: React.FormEvent) => Promise<void>;
|
|
17
17
|
handlePasswordSetupSubmit: (e: React.FormEvent) => Promise<void>;
|
|
@@ -36,30 +36,7 @@ export interface UseAbcWaasAuthProps {
|
|
|
36
36
|
/**
|
|
37
37
|
* Custom hook for ABC WaaS authentication logic
|
|
38
38
|
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
* - Password-based login for existing users
|
|
42
|
-
* - OTP verification for new users
|
|
43
|
-
* - Password setup and confirmation for new users
|
|
44
|
-
* - Error handling and state transitions
|
|
45
|
-
*
|
|
46
|
-
* @example
|
|
47
|
-
* ```tsx
|
|
48
|
-
* const abcAuth = useAbcWaasAuth({
|
|
49
|
-
* onAuthSuccess: (loginData) => {
|
|
50
|
-
* console.log('Auth success', loginData);
|
|
51
|
-
* setIsPinCreateModalOpen(true);
|
|
52
|
-
* }
|
|
53
|
-
* });
|
|
54
|
-
*
|
|
55
|
-
* return (
|
|
56
|
-
* <AbcWaasAuthSections
|
|
57
|
-
* abcWaasStep={abcAuth.step}
|
|
58
|
-
* abcWaasEmail={abcAuth.email}
|
|
59
|
-
* handleEmailSubmit={abcAuth.handleEmailSubmit}
|
|
60
|
-
* {...otherProps}
|
|
61
|
-
* />
|
|
62
|
-
* );
|
|
63
|
-
* ```
|
|
39
|
+
* All API calls go through TalkenApiClient → talken-api backend.
|
|
40
|
+
* Server handles secure channel encryption internally.
|
|
64
41
|
*/
|
|
65
42
|
export declare function useAbcWaasAuth(props?: UseAbcWaasAuthProps): UseAbcWaasAuthReturn;
|
|
@@ -1,58 +1,12 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Return type for useAbcWaasSocial hook
|
|
3
|
-
*/
|
|
4
1
|
export interface UseAbcWaasSocialReturn {
|
|
5
|
-
/** Loading state for social login operations */
|
|
6
2
|
isLoading: boolean;
|
|
7
|
-
/** Error message from social login operations */
|
|
8
3
|
error: string;
|
|
9
|
-
/** Handle Google OAuth login flow */
|
|
10
4
|
handleGoogleLogin: () => Promise<void>;
|
|
11
|
-
/** Handle Apple OAuth login flow (not implemented) */
|
|
12
5
|
handleAppleLogin: () => Promise<void>;
|
|
6
|
+
handleKakaoLogin: () => Promise<void>;
|
|
13
7
|
}
|
|
14
|
-
/**
|
|
15
|
-
* Props for useAbcWaasSocial hook
|
|
16
|
-
*/
|
|
17
8
|
export interface UseAbcWaasSocialProps {
|
|
18
|
-
/**
|
|
19
|
-
* Callback when social login succeeds and PIN is required
|
|
20
|
-
* @param loginData - Response from ABC WaaS social login (access_token, uid, email, etc.)
|
|
21
|
-
* @param email - User's email address from social provider
|
|
22
|
-
* @param hasPinStored - Whether user has existing PIN stored in localStorage
|
|
23
|
-
*/
|
|
24
9
|
onPinRequired: (loginData: any, email: string, hasPinStored: boolean) => void;
|
|
25
|
-
/**
|
|
26
|
-
* Callback for setting email after successful login
|
|
27
|
-
* @param email - User's email address from social provider
|
|
28
|
-
*/
|
|
29
10
|
onEmailSet?: (email: string) => void;
|
|
30
11
|
}
|
|
31
|
-
/**
|
|
32
|
-
* Custom hook for ABC WaaS social login (Google, Apple)
|
|
33
|
-
*
|
|
34
|
-
* Handles Google OAuth flow via AbcAuthService, manages login state,
|
|
35
|
-
* saves auth data to localStorage, and triggers PIN creation/verification flow.
|
|
36
|
-
*
|
|
37
|
-
* @example
|
|
38
|
-
* ```tsx
|
|
39
|
-
* const socialAuth = useAbcWaasSocial({
|
|
40
|
-
* onPinRequired: (loginData, email, hasPinStored) => {
|
|
41
|
-
* if (hasPinStored) {
|
|
42
|
-
* showPinVerifyModal();
|
|
43
|
-
* } else {
|
|
44
|
-
* showPinCreateModal();
|
|
45
|
-
* }
|
|
46
|
-
* },
|
|
47
|
-
* onEmailSet: (email) => setEmail(email),
|
|
48
|
-
* });
|
|
49
|
-
*
|
|
50
|
-
* <button onClick={socialAuth.handleGoogleLogin}>
|
|
51
|
-
* {socialAuth.isLoading ? 'Signing in...' : 'Sign in with Google'}
|
|
52
|
-
* </button>
|
|
53
|
-
* ```
|
|
54
|
-
*
|
|
55
|
-
* @param props - Hook configuration
|
|
56
|
-
* @returns Social login handlers and state
|
|
57
|
-
*/
|
|
58
12
|
export declare function useAbcWaasSocial(props: UseAbcWaasSocialProps): UseAbcWaasSocialReturn;
|
|
@@ -41,18 +41,11 @@ export interface UseWalletGenerationProps {
|
|
|
41
41
|
storagePrefix?: string;
|
|
42
42
|
}
|
|
43
43
|
/**
|
|
44
|
-
* Custom hook for multi-chain wallet generation (EVM, Solana, Bitcoin)
|
|
44
|
+
* Custom hook for multi-chain wallet generation (EVM, Solana, Bitcoin, TRON)
|
|
45
45
|
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
* 3. Solana wallet generation via /v3/wallet/generate (with 409 recovery fallback)
|
|
50
|
-
* 4. Solana address retrieval via /wapi/v2/solana/wallet/getAddress
|
|
51
|
-
* 5. Bitcoin address generation via /wapi/v2/btc/address (derived from EVM pubkey)
|
|
52
|
-
* 6. Progress tracking for all 4 steps
|
|
53
|
-
* 7. localStorage persistence (auth_state, wallet, tokens, etc.)
|
|
54
|
-
* 8. PIN hash storage
|
|
55
|
-
* 9. wagmi connector connection
|
|
46
|
+
* Uses TalkenApiClient to generate all chain wallets in a single API call.
|
|
47
|
+
* The talken-api backend handles Secure Channel, EVM generation, pubkey lookup,
|
|
48
|
+
* Solana generation/recovery, and BTC/TRON address derivation internally.
|
|
56
49
|
*
|
|
57
50
|
* @param props - Configuration for wallet generation
|
|
58
51
|
* @returns Hook state and functions for wallet generation
|
|
@@ -63,7 +56,6 @@ export interface UseWalletGenerationProps {
|
|
|
63
56
|
* connectors,
|
|
64
57
|
* connect,
|
|
65
58
|
* onSuccess: () => {
|
|
66
|
-
* // Close modals, reset state
|
|
67
59
|
* onClose();
|
|
68
60
|
* },
|
|
69
61
|
* storagePrefix: 'talkenkit_abc_',
|
|
@@ -80,14 +72,5 @@ export interface UseWalletGenerationProps {
|
|
|
80
72
|
* loginData: { access_token, refresh_token, expires_in }
|
|
81
73
|
* });
|
|
82
74
|
* ```
|
|
83
|
-
*
|
|
84
|
-
* @remarks
|
|
85
|
-
* - EVM wallet uses secp256k1 curve (Ethereum standard)
|
|
86
|
-
* - Solana wallet uses Ed25519 curve (Solana standard)
|
|
87
|
-
* - Bitcoin wallet derives address from EVM public key (same curve)
|
|
88
|
-
* - All wallets share the same PIN hash for encryption
|
|
89
|
-
* - Wallet data encrypted with PIN-based AES-256-GCM
|
|
90
|
-
* - Progress updates occur before each major step
|
|
91
|
-
* - Errors are logged and re-thrown for caller to handle
|
|
92
75
|
*/
|
|
93
76
|
export declare function useWalletGeneration(props: UseWalletGenerationProps): UseWalletGenerationReturn;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
export declare const overlay: string;
|
|
2
|
+
export declare const modal: string;
|
|
3
|
+
export declare const header: string;
|
|
4
|
+
export declare const headerSpacer: string;
|
|
5
|
+
export declare const title: string;
|
|
6
|
+
export declare const closeButton: string;
|
|
7
|
+
export declare const optionTable: string;
|
|
8
|
+
export declare const tableHeader: string;
|
|
9
|
+
export declare const optionRow: string;
|
|
10
|
+
export declare const optionRowSelected: string;
|
|
11
|
+
export declare const optionLabel: string;
|
|
12
|
+
export declare const optionIcon: string;
|
|
13
|
+
export declare const optionTime: string;
|
|
14
|
+
export declare const optionFee: string;
|
|
15
|
+
export declare const optionFeeUnit: string;
|
|
16
|
+
export declare const customRow: string;
|
|
17
|
+
export declare const customRowSelected: string;
|
|
18
|
+
export declare const customLabel: string;
|
|
19
|
+
export declare const customValue: string;
|
|
20
|
+
export declare const customFeeDisplay: string;
|
|
21
|
+
export declare const inputSection: string;
|
|
22
|
+
export declare const inputGroup: string;
|
|
23
|
+
export declare const inputLabel: string;
|
|
24
|
+
export declare const inputWrapper: string;
|
|
25
|
+
export declare const stepButton: string;
|
|
26
|
+
export declare const inputField: string;
|
|
27
|
+
export declare const confirmButton: string;
|
|
28
|
+
export declare const infoIconWrapper: string;
|
|
29
|
+
export declare const infoIcon: string;
|
|
30
|
+
export declare const tooltip: string;
|
|
31
|
+
export declare const tooltipArrow: string;
|
|
32
|
+
export declare const tooltipText: string;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { GasFeePriority, SuggestedGasFees } from '../../wallets/walletConnectors/abcWallet/types';
|
|
3
|
+
export interface GasOption {
|
|
4
|
+
priority: GasFeePriority | 'custom';
|
|
5
|
+
maxFeePerGas?: string;
|
|
6
|
+
maxPriorityFeePerGas?: string;
|
|
7
|
+
gasLimit?: string;
|
|
8
|
+
estimatedBaseFee?: string;
|
|
9
|
+
}
|
|
10
|
+
export interface GasFeeEditModalProps {
|
|
11
|
+
isOpen: boolean;
|
|
12
|
+
onClose: () => void;
|
|
13
|
+
onConfirm: (selectedOption: GasOption) => void;
|
|
14
|
+
currentOption: GasFeePriority | 'custom';
|
|
15
|
+
suggestedGasFees?: SuggestedGasFees;
|
|
16
|
+
currentGasLimit?: string;
|
|
17
|
+
currentMaxFee?: string;
|
|
18
|
+
currentPriorityFee?: string;
|
|
19
|
+
nativeSymbol?: string;
|
|
20
|
+
}
|
|
21
|
+
export declare function GasFeeEditModal({ isOpen, onClose, onConfirm, currentOption, suggestedGasFees, currentGasLimit, currentMaxFee, currentPriorityFee, nativeSymbol, }: GasFeeEditModalProps): React.JSX.Element | null;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export declare const modalVars: {
|
|
2
|
+
colors: {
|
|
3
|
+
background: `var(--${string})`;
|
|
4
|
+
border: `var(--${string})`;
|
|
5
|
+
labelText: `var(--${string})`;
|
|
6
|
+
primaryText: `var(--${string})`;
|
|
7
|
+
secondaryText: `var(--${string})`;
|
|
8
|
+
buttonCancel: `var(--${string})`;
|
|
9
|
+
buttonCancelText: `var(--${string})`;
|
|
10
|
+
buttonConfirm: `var(--${string})`;
|
|
11
|
+
buttonConfirmText: `var(--${string})`;
|
|
12
|
+
tooltipBackground: `var(--${string})`;
|
|
13
|
+
tooltipText: `var(--${string})`;
|
|
14
|
+
systemBlue: `var(--${string})`;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
export declare const darkModeTheme: string;
|
|
18
|
+
export declare const lightModeTheme: string;
|
|
19
|
+
export declare const autoTheme: string;
|
|
@@ -4,15 +4,13 @@ interface InternalPinProviderProps {
|
|
|
4
4
|
disabled?: boolean;
|
|
5
5
|
}
|
|
6
6
|
/**
|
|
7
|
-
* Internal PIN provider
|
|
8
|
-
* Automatically activates for ABC Wallet with RainbowKit theme support
|
|
7
|
+
* Internal PIN provider - passthrough component
|
|
9
8
|
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* - No manual PinProvider needed for basic ABC Wallet functionality
|
|
9
|
+
* Previously showed PIN modal for transaction signing.
|
|
10
|
+
* Transaction PIN is now read directly from localStorage (talkenkit_abc_pin_hash)
|
|
11
|
+
* set during wallet creation/login.
|
|
12
|
+
*
|
|
13
|
+
* PIN input is still required for wallet creation/login via PinAuthFlow.
|
|
16
14
|
*/
|
|
17
|
-
export declare function InternalPinProvider({ children
|
|
15
|
+
export declare function InternalPinProvider({ children }: InternalPinProviderProps): React.JSX.Element;
|
|
18
16
|
export {};
|
|
@@ -1,16 +1,11 @@
|
|
|
1
1
|
import React, { type ReactNode } from 'react';
|
|
2
|
-
export type MobileMode = 'compact-
|
|
2
|
+
export type MobileMode = 'compact-list' | 'full' | 'auto';
|
|
3
3
|
export interface RainbowKitConfig {
|
|
4
4
|
/**
|
|
5
5
|
* Mobile behavior mode
|
|
6
6
|
* @default 'auto'
|
|
7
7
|
*/
|
|
8
8
|
mobileMode: MobileMode;
|
|
9
|
-
/**
|
|
10
|
-
* Wallets to show in compact login mode
|
|
11
|
-
* @default ['abcWallet']
|
|
12
|
-
*/
|
|
13
|
-
compactLoginWallets: string[];
|
|
14
9
|
}
|
|
15
10
|
export interface RainbowKitConfigProviderProps {
|
|
16
11
|
config: RainbowKitConfig;
|
|
@@ -42,18 +42,12 @@ export interface RainbowKitProviderProps {
|
|
|
42
42
|
solanaConfig?: SolanaConfig;
|
|
43
43
|
/**
|
|
44
44
|
* Mobile behavior mode
|
|
45
|
-
* - 'compact-login': Direct to login on mobile (Email/Google only)
|
|
46
45
|
* - 'compact-list': Show compact wallet list on mobile
|
|
47
46
|
* - 'full': Use desktop flow on mobile
|
|
48
47
|
* - 'auto': Auto-detect based on wallet config
|
|
49
48
|
* @default 'auto'
|
|
50
49
|
*/
|
|
51
50
|
mobileMode?: MobileMode;
|
|
52
|
-
/**
|
|
53
|
-
* Wallets to show in compact login mode
|
|
54
|
-
* @default ['abcWallet']
|
|
55
|
-
*/
|
|
56
|
-
compactLoginWallets?: string[];
|
|
57
51
|
/**
|
|
58
52
|
* Auto-reconnect to previously connected wallets on page load
|
|
59
53
|
* Applies to both EVM (wagmi) and Solana (wallet-adapter) wallets
|
|
@@ -61,5 +55,11 @@ export interface RainbowKitProviderProps {
|
|
|
61
55
|
* @default true
|
|
62
56
|
*/
|
|
63
57
|
autoReconnect?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Show sign confirmation modal for ABC Wallet transactions
|
|
60
|
+
* When enabled, displays a confirmation UI before signing transactions
|
|
61
|
+
* @default false
|
|
62
|
+
*/
|
|
63
|
+
showSignConfirmation?: boolean;
|
|
64
64
|
}
|
|
65
|
-
export declare function RainbowKitProvider({ appInfo, avatar, children, coolMode, autoReconnect, disableAutoPinProvider, id, initialChain, locale, modalSize, showRecentTransactions, theme, solanaConfig, mobileMode,
|
|
65
|
+
export declare function RainbowKitProvider({ appInfo, avatar, children, coolMode, autoReconnect, disableAutoPinProvider, id, initialChain, locale, modalSize, showRecentTransactions, theme, solanaConfig, mobileMode, showSignConfirmation, }: RainbowKitProviderProps): React.JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export interface UseToastOptions {
|
|
2
|
+
duration?: number;
|
|
3
|
+
}
|
|
4
|
+
export interface UseToastReturn {
|
|
5
|
+
isVisible: boolean;
|
|
6
|
+
message: string;
|
|
7
|
+
showToast: (message: string) => void;
|
|
8
|
+
hideToast: () => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function useToast(options?: UseToastOptions): UseToastReturn;
|
|
@@ -94,6 +94,16 @@ export declare function chainIdToNetwork(chainId: number): string | undefined;
|
|
|
94
94
|
* getNetworkName(999999, 'polygon') // 'polygon' (custom fallback)
|
|
95
95
|
*/
|
|
96
96
|
export declare function getNetworkName(chainId: number, fallback?: string): string;
|
|
97
|
+
/**
|
|
98
|
+
* Get talken-sdk chainKey from chainId (used by talken-api tx/* endpoints)
|
|
99
|
+
*/
|
|
100
|
+
export declare function getChainKey(chainId: number): string;
|
|
101
|
+
/**
|
|
102
|
+
* Convert ABC WaaS network name to talken-sdk chainKey.
|
|
103
|
+
* e.g. 'kaia_kairos' → 'kaiaKairos', 'ethereum' → 'ethereum'
|
|
104
|
+
* Falls back to the network name if no mapping found.
|
|
105
|
+
*/
|
|
106
|
+
export declare function networkNameToChainKey(network: string): string;
|
|
97
107
|
/**
|
|
98
108
|
* Convert ABC WaaS network parameter to chain ID
|
|
99
109
|
* @param network - ABC WaaS network parameter
|
|
@@ -242,7 +242,7 @@ export declare const mapResponsiveValue: <OutputValue extends string | number |
|
|
|
242
242
|
};
|
|
243
243
|
};
|
|
244
244
|
};
|
|
245
|
-
}, string | number | boolean>>(value: Value, fn: (inputValue: Value extends import("@vanilla-extract/sprinkles").ResponsiveArray<1, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 2, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 4, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 5 | 4, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 5 |
|
|
245
|
+
}, string | number | boolean>>(value: Value, fn: (inputValue: Value extends import("@vanilla-extract/sprinkles").ResponsiveArray<1, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 2, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 4, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 5 | 4, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 5 | 6 | 4, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 5 | 6 | 4 | 7, string | number | boolean | null> | import("@vanilla-extract/sprinkles").ResponsiveArray<1 | 3 | 2 | 5 | 6 | 4 | 8 | 7, string | number | boolean | null> ? NonNullable<Value[number]> : Value extends Partial<Record<string, string | number | boolean>> ? NonNullable<Value[keyof Value]> : Value, key: "smallScreen" | "largeScreen") => OutputValue) => Value extends string | number | boolean ? OutputValue : Partial<Record<"smallScreen" | "largeScreen", OutputValue>>;
|
|
246
246
|
export declare const normalizeResponsiveValue: <Value extends string | number | boolean>(value: import("@vanilla-extract/sprinkles").ConditionalValue<{
|
|
247
247
|
conditions: {
|
|
248
248
|
defaultCondition: "smallScreen";
|