@xswap-link/sdk 0.12.0 → 0.12.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @xswap-link/xswap-sdk
2
2
 
3
+ ## 0.12.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 0283187: fix connect wallet, fix getTokenBalance
8
+
9
+ ## 0.12.1
10
+
11
+ ### Patch Changes
12
+
13
+ - ea1c153: fixed outline on SafeInput
14
+
3
15
  ## 0.12.0
4
16
 
5
17
  ### Minor Changes
package/dist/index.d.mts CHANGED
@@ -1,4 +1,5 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { Config } from '@wagmi/core';
2
3
  import { BigNumber, ContractReceipt, ContractTransaction } from 'ethers';
3
4
  import { TransactionResponse } from '@ethersproject/providers';
4
5
  import { VersionedTransaction } from '@solana/web3.js';
@@ -206,6 +207,7 @@ type ModalIntegrationPayload = {
206
207
  integratorFee?: number;
207
208
  integratorFeeReceiverAddress?: string;
208
209
  highlightedDstTokens?: string[];
210
+ wagmiConfig?: Config;
209
211
  };
210
212
 
211
213
  type WidgetIntegrationPayload = {
@@ -243,6 +245,7 @@ type WidgetIntegrationPayload = {
243
245
  integratorFee?: number;
244
246
  integratorFeeReceiverAddress?: string;
245
247
  highlightedDstTokens?: string[];
248
+ wagmiConfig?: Config;
246
249
  };
247
250
 
248
251
  type Protocol = {
@@ -448,7 +451,7 @@ declare global {
448
451
  }
449
452
  }
450
453
  }
451
- declare const TxWidgetWCWrapped: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
454
+ declare const TxWidgetWCWrapped: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, wagmiConfig, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
452
455
 
453
456
  interface EvmHandlers {
454
457
  onSuccess?: (data: ContractReceipt) => void;
@@ -504,13 +507,13 @@ type TxStats = {
504
507
  cashback?: string;
505
508
  };
506
509
 
507
- declare const openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, }: ModalIntegrationPayload) => Promise<void>;
510
+ declare const openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, wagmiConfig, }: ModalIntegrationPayload) => Promise<void>;
508
511
 
509
512
  declare const TxWidgetWC: CustomElementConstructor;
510
513
 
511
514
  declare const XPay: {
512
- openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, }: ModalIntegrationPayload) => Promise<void>;
513
- TxWidget: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
515
+ openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, wagmiConfig, }: ModalIntegrationPayload) => Promise<void>;
516
+ TxWidget: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, wagmiConfig, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
514
517
  TxWidgetWC: CustomElementConstructor;
515
518
  };
516
519
 
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { Config } from '@wagmi/core';
2
3
  import { BigNumber, ContractReceipt, ContractTransaction } from 'ethers';
3
4
  import { TransactionResponse } from '@ethersproject/providers';
4
5
  import { VersionedTransaction } from '@solana/web3.js';
@@ -206,6 +207,7 @@ type ModalIntegrationPayload = {
206
207
  integratorFee?: number;
207
208
  integratorFeeReceiverAddress?: string;
208
209
  highlightedDstTokens?: string[];
210
+ wagmiConfig?: Config;
209
211
  };
210
212
 
211
213
  type WidgetIntegrationPayload = {
@@ -243,6 +245,7 @@ type WidgetIntegrationPayload = {
243
245
  integratorFee?: number;
244
246
  integratorFeeReceiverAddress?: string;
245
247
  highlightedDstTokens?: string[];
248
+ wagmiConfig?: Config;
246
249
  };
247
250
 
248
251
  type Protocol = {
@@ -448,7 +451,7 @@ declare global {
448
451
  }
449
452
  }
450
453
  }
451
- declare const TxWidgetWCWrapped: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
454
+ declare const TxWidgetWCWrapped: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, wagmiConfig, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
452
455
 
453
456
  interface EvmHandlers {
454
457
  onSuccess?: (data: ContractReceipt) => void;
@@ -504,13 +507,13 @@ type TxStats = {
504
507
  cashback?: string;
505
508
  };
506
509
 
507
- declare const openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, }: ModalIntegrationPayload) => Promise<void>;
510
+ declare const openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, wagmiConfig, }: ModalIntegrationPayload) => Promise<void>;
508
511
 
509
512
  declare const TxWidgetWC: CustomElementConstructor;
510
513
 
511
514
  declare const XPay: {
512
- openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, }: ModalIntegrationPayload) => Promise<void>;
513
- TxWidget: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
515
+ openTransactionModal: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, bridge, highlightedDstTokens, wagmiConfig, }: ModalIntegrationPayload) => Promise<void>;
516
+ TxWidget: ({ integratorId, dstChain, dstToken, srcChain, srcToken, customContractCalls, desc, dstDisplayToken, lightTheme, defaultWalletPicker, styles, onPendingTransactionsChange, dstTokenLocked, dstChainLocked, srcTokenLocked, srcChainLocked, onDstTokenChange, onDstChainChange, onSrcTokenChange, onSrcChainChange, onConnectWallet, bridge, override, integratorFee, integratorFeeReceiverAddress, highlightedDstTokens, wagmiConfig, }: WidgetIntegrationPayload) => react_jsx_runtime.JSX.Element;
514
517
  TxWidgetWC: CustomElementConstructor;
515
518
  };
516
519