@kimafinance/kima-transaction-widget 1.3.2 → 1.3.4

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/index.cjs CHANGED
@@ -4327,7 +4327,7 @@ function useCurrencyOptions(isSourceChain) {
4327
4327
  const transactionOption = (0, import_react_redux21.useSelector)(selectTransactionOption);
4328
4328
  const networks = (0, import_react_redux21.useSelector)(selectNetworks);
4329
4329
  const output = (0, import_react107.useMemo)(() => {
4330
- console.log("useCurrencyOptions: networks:", networks, isSourceChain);
4330
+ console.log("useCurrencyOptions: networks: ", networks);
4331
4331
  const networkTokenList = networks.find((network) => network.id === chain.id) || networks[0];
4332
4332
  console.log(
4333
4333
  "useCurrencyOptions: networkTokenList: ",
@@ -4942,15 +4942,22 @@ var TransactionWidget = ({ theme }) => {
4942
4942
  const { data, error } = useGetTxData_default(txId, dAppOption, backendUrl);
4943
4943
  const transactionSourceChain = (0, import_react121.useMemo)(
4944
4944
  () => networks.find(
4945
- (network) => mode === "status" /* status */ ? network.shortName === data?.sourceChain : sourceChain
4945
+ (network) => network.shortName === (mode === "status" /* status */ ? data?.sourceChain : sourceChain.shortName)
4946
4946
  ),
4947
- [data, mode]
4947
+ [data, mode, sourceChain]
4948
4948
  );
4949
4949
  const transactionTargetChain = (0, import_react121.useMemo)(
4950
4950
  () => networks.find(
4951
- (network) => mode === "status" /* status */ ? network.shortName === data?.targetChain : targetChain
4951
+ (network) => network.shortName === (mode === "status" /* status */ ? data?.targetChain : targetChain.shortName)
4952
4952
  ),
4953
- [data, mode]
4953
+ [data, mode, targetChain]
4954
+ );
4955
+ console.log(
4956
+ "tx details: ",
4957
+ networks,
4958
+ transactionSourceChain,
4959
+ transactionTargetChain,
4960
+ data
4954
4961
  );
4955
4962
  const isValidTxId = (0, import_react121.useMemo)(() => {
4956
4963
  return !(!txId || typeof txId === "string" && txId.length === 0 || typeof txId === "number" && txId < 0);