@xswap-link/sdk 0.11.3 → 0.11.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/CHANGELOG.md +6 -0
- package/dist/index.global.js +348 -348
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/constants/index.ts +1 -0
- package/src/context/SwapProvider.tsx +7 -2
package/package.json
CHANGED
package/src/constants/index.ts
CHANGED
|
@@ -36,6 +36,7 @@ export const SOLANA_MAINNET_RPC_URL =
|
|
|
36
36
|
export const JUPITER_V6_PROGRAM_ID = new PublicKey(
|
|
37
37
|
"JUP6LkbZbjS1jKKwapdHNy74zcZ3tLUZoi5QNyVTaV4",
|
|
38
38
|
);
|
|
39
|
+
export const DEPLOYER_ADDRESS = "0x8ebD04b2fbA00418Be00329146837dcE51F02c00";
|
|
39
40
|
export const DEFAULT_ECOSYSTEM = Ecosystem.EVM;
|
|
40
41
|
export const NUMBER_INPUT_REGEX = /^[0-9]*[.,]?[0-9]*$/;
|
|
41
42
|
export const SLIPPAGE_PRESETS: number[] = [0.5, 1.5, 3.0];
|
|
@@ -3,6 +3,7 @@ import {
|
|
|
3
3
|
DEFAULT_DESTINATION_CHAIN_ID,
|
|
4
4
|
DEFAULT_REQUEST_ABORT_MSG,
|
|
5
5
|
DEFAULT_SOURCE_CHAIN_ID,
|
|
6
|
+
DEPLOYER_ADDRESS,
|
|
6
7
|
SOLANA_NATIVE_TOKEN_ADDRESS,
|
|
7
8
|
SOLANA_TOKEN_2022_PROGRAM_ID,
|
|
8
9
|
SOLANA_TOKEN_PROGRAM_ID,
|
|
@@ -600,13 +601,17 @@ export const SwapProvider = ({
|
|
|
600
601
|
fromChain: srcChain.chainId,
|
|
601
602
|
toChain: dstChain.chainId,
|
|
602
603
|
fromAddress:
|
|
603
|
-
evmAddress ||
|
|
604
|
+
evmAddress ||
|
|
605
|
+
ADDRESSES[srcChain.chainId]?.FeeCollector ||
|
|
606
|
+
DEPLOYER_ADDRESS,
|
|
604
607
|
toAddress:
|
|
605
608
|
dstChain.ecosystem === Ecosystem.SOLANA
|
|
606
609
|
? solanaAddress ||
|
|
607
610
|
ADDRESSES[dstChain.chainId]?.FeeCollector ||
|
|
608
611
|
""
|
|
609
|
-
: evmAddress ||
|
|
612
|
+
: evmAddress ||
|
|
613
|
+
ADDRESSES[dstChain.chainId]?.FeeCollector ||
|
|
614
|
+
DEPLOYER_ADDRESS,
|
|
610
615
|
fromToken: srcToken.address,
|
|
611
616
|
toToken: dstToken.address,
|
|
612
617
|
fromAmount: srcValueWei,
|