@cetusprotocol/terminal 0.0.1 → 0.0.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/dist/cetus-swap.cjs.js +34 -34
- package/dist/cetus-swap.cjs.js.gz +0 -0
- package/dist/cetus-swap.es.js +19207 -20672
- package/dist/cetus-swap.es.js.gz +0 -0
- package/dist/cetus-swap.umd.js +34 -34
- package/dist/cetus-swap.umd.js.gz +0 -0
- package/dist/components/swap/SwapTrade.d.ts +2 -1
- package/dist/components/swap/TokenSelectModal/{ImportDialog.d.ts → WarnTokenDialog.d.ts} +2 -2
- package/dist/hooks/swap/useSwap.d.ts +1 -1
- package/dist/hooks/swap/useSwapHelper.d.ts +3 -0
- package/dist/stores/swap.d.ts +3 -0
- package/dist/style.css +1 -1
- package/dist/style.css.gz +0 -0
- package/dist/types/common.d.ts +7 -0
- package/package.json +5 -4
|
Binary file
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
type SwapTradeProps = {
|
|
2
2
|
refreshCount: number;
|
|
3
3
|
customWallet?: any;
|
|
4
|
+
initProps?: any;
|
|
4
5
|
};
|
|
5
|
-
export default function SwapTrade({ refreshCount, customWallet, }: SwapTradeProps): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export default function SwapTrade({ refreshCount, customWallet, initProps, }: SwapTradeProps): import("react/jsx-runtime").JSX.Element;
|
|
6
7
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Token } from '../../../types';
|
|
2
|
-
export default function
|
|
2
|
+
export default function WarnTokenDialog({ onClose, token, onSureClick, }: {
|
|
3
3
|
token: Token;
|
|
4
4
|
onClose: () => void;
|
|
5
|
-
|
|
5
|
+
onSureClick: () => void;
|
|
6
6
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -6,7 +6,7 @@ export declare function useSwapHook(): {
|
|
|
6
6
|
toBalanceInfo: import('../../types').TokenBalance | undefined;
|
|
7
7
|
fromAmountValue: string;
|
|
8
8
|
toAmountValue: string;
|
|
9
|
-
doSwapAction: (data: SwapRouterData) => Promise<void>;
|
|
9
|
+
doSwapAction: (data: SwapRouterData, partner?: string) => Promise<void>;
|
|
10
10
|
reCalculateRouteData: () => void;
|
|
11
11
|
refreshMarketPrice: () => void;
|
|
12
12
|
scamsText: string | undefined;
|
|
@@ -43,3 +43,6 @@ export declare function useGetSwapPrice(direct: boolean, fromAmount?: string, to
|
|
|
43
43
|
export default function useCheckTokenScamsAlert(coinInfo?: Token): {
|
|
44
44
|
isScamsCoin: boolean | undefined;
|
|
45
45
|
};
|
|
46
|
+
export declare function useCheckCustomCoinPair(): {
|
|
47
|
+
isCustomMode: boolean;
|
|
48
|
+
};
|
package/dist/stores/swap.d.ts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { SwapRouterData, Token } from '../types/common';
|
|
2
2
|
interface SwapState {
|
|
3
|
+
defaultFromCoin: Token | undefined;
|
|
4
|
+
defaultToCoin: Token | undefined;
|
|
5
|
+
setDefaultCoin: (from: Token | undefined, to: Token | undefined) => void;
|
|
3
6
|
fromCoin: Token | undefined;
|
|
4
7
|
toCoin: Token | undefined;
|
|
5
8
|
setFromCoin: (value: Token | undefined) => void;
|