@dodoex/widgets 3.0.4-ve33.1 → 3.0.4-ve33.11
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/cjs/locales/en-US.js +1 -1
- package/dist/cjs/locales/zh-CN.js +1 -1
- package/dist/{helper-C3H6B4Oy.cjs → helper-BASM7Iwr.cjs} +1 -1
- package/dist/{helper-0RKQSgE1.js → helper-BASXTlaZ.js} +1 -1
- package/dist/{index-8b78r-JT.js → index-BPaBKoXS.js} +1 -1
- package/dist/index-CjO6DZLb.js +32 -0
- package/dist/index-DH1Xhcg6.cjs +32 -0
- package/dist/{index-DdE6aa-k.cjs → index-mk0U3yyv.cjs} +1 -1
- package/dist/{index-D9uctpVh.js → index-r9aOMH8w.js} +1 -1
- package/dist/{index-CsquFrM1.cjs → index-zX4IFul3.cjs} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/locales/en-US.js +1 -1
- package/dist/locales/zh-CN.js +1 -1
- package/dist/types/components/AddressWithLinkAndCopy.d.ts +3 -1
- package/dist/types/components/CardWidgets.d.ts +2 -1
- package/dist/types/components/SimpleItemInfo.d.ts +4 -0
- package/dist/types/components/Swap/components/Dialog.d.ts +3 -0
- package/dist/types/components/Swap/components/ReviewDialog.d.ts +1 -2
- package/dist/types/components/Swap/components/SwapSettingsDialog/index.d.ts +1 -4
- package/dist/types/components/Swap/components/TokenCard/NumberInput.d.ts +1 -0
- package/dist/types/components/Swap/components/TokenCard/TokenLpCard.d.ts +32 -0
- package/dist/types/components/Swap/components/TokenCard/index.d.ts +2 -1
- package/dist/types/components/Swap/index.d.ts +1 -4
- package/dist/types/components/Token/TokenItem.d.ts +2 -1
- package/dist/types/components/TokenSelect.d.ts +5 -2
- package/dist/types/components/TokenStatusButton.d.ts +1 -1
- package/dist/types/components/Widget/index.d.ts +1 -0
- package/dist/types/components/WidgetContainer.d.ts +1 -1
- package/dist/types/constants/api.d.ts +1 -1
- package/dist/types/constants/swap.d.ts +3 -0
- package/dist/types/hooks/Submission/types.d.ts +21 -1
- package/dist/types/hooks/Swap/useFetchRoutePrice.d.ts +1 -3
- package/dist/types/hooks/Swap/useSlippageLimit.d.ts +1 -1
- package/dist/types/hooks/Swap/useSwapSettingStore.d.ts +1 -0
- package/dist/types/hooks/Token/usePoolTokenSort.d.ts +24 -0
- package/dist/types/hooks/useGraphQLRequests.d.ts +0 -1
- package/dist/types/index.d.ts +40 -23
- package/dist/types/utils/formatter.d.ts +2 -2
- package/dist/types/utils/fractions/fraction.d.ts +24 -0
- package/dist/types/utils/fractions/index.d.ts +3 -0
- package/dist/types/utils/fractions/percent.d.ts +14 -0
- package/dist/types/utils/fractions/price.d.ts +29 -0
- package/dist/types/utils/fractions/types.d.ts +7 -0
- package/dist/types/widgets/PoolWidget/utils.d.ts +2 -0
- package/dist/types/widgets/ve33/Ve33IncentiveDetail/AddIncentiveDialog.d.ts +13 -0
- package/dist/types/widgets/ve33/Ve33IncentiveDetail/Dashboard.d.ts +1 -0
- package/dist/types/widgets/ve33/Ve33IncentiveDetail/PoolInfo.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33IncentiveDetail/index.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33IncentiveList/CardList.d.ts +10 -0
- package/dist/types/widgets/ve33/Ve33IncentiveList/TableList.d.ts +11 -0
- package/dist/types/widgets/ve33/Ve33IncentiveList/index.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33LockList/CardList.d.ts +11 -0
- package/dist/types/widgets/ve33/Ve33LockList/ClaimLockDialog.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33LockList/LockManageDialog.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33LockList/MergeDialog.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33LockList/TableList.d.ts +10 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useClaimBribes.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useClaimRebases.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useExtendLock.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useFetchUserLocks.d.ts +282 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useIncreaseLock.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useMergeLock.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33LockList/hooks/useTransferLock.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33LockList/index.d.ts +1 -0
- package/dist/types/widgets/ve33/Ve33LockOperate/hooks/useCreateLock.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33LockOperate/hooks/useFetchUserTotalVeNFT.d.ts +8 -0
- package/dist/types/widgets/ve33/Ve33LockOperate/index.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33LockOperate/utils.d.ts +21 -0
- package/dist/types/widgets/ve33/Ve33PoolDetail/MyAssets.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33PoolDetail/MyPosition.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33PoolDetail/PoolInfo.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33PoolDetail/index.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33PoolDetail/useVe33V3Positions.d.ts +79 -0
- package/dist/types/widgets/ve33/Ve33PoolList/CardList.d.ts +13 -0
- package/dist/types/widgets/ve33/Ve33PoolList/TableList.d.ts +14 -0
- package/dist/types/widgets/ve33/Ve33PoolList/index.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33PoolOperate.d.ts +2 -0
- package/dist/types/widgets/ve33/Ve33StakeDialog.d.ts +11 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/AddPoolOperate.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/RemovePoolOperate.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/components/ComparePrice.d.ts +8 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/components/OperateBtn.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/components/SliderPercentageCard.d.ts +8 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/components/SlippageSetting.d.ts +18 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/components/V2ConfirmDialog.d.ts +19 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/useComparePrice.d.ts +19 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/useLiquidityOperateAmount.d.ts +86 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/usePercentageRemove.d.ts +25 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/usePoolOperateTabs.d.ts +12 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/useVe33V2AddLiquidity.d.ts +12 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/useVe33V2BalanceInfo.d.ts +36 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/useVe33V2RemoveLiquidity.d.ts +12 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/hooks/useWithdrawInfo.d.ts +25 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/index.d.ts +15 -0
- package/dist/types/widgets/ve33/Ve33V2PoolOperate/types.d.ts +22 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/Ve33V3AddLiquidity.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/Badge/RangeBadge.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/ClaimButton.d.ts +9 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/InRangeDot.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/InputStepCounter.d.ts +17 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/Area.d.ts +10 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/AxisBottom.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/Brush.d.ts +13 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/Chart.d.ts +2 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/Line.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/Zoom.d.ts +12 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/index.d.ts +19 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/svg.d.ts +22 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/types.d.ts +50 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/usePrevious.d.ts +1 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/LiquidityChartRangeInput/utils.d.ts +14 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/MyLiquidity.d.ts +10 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/PositionManage.d.ts +8 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/PositionPreview.d.ts +14 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/PositionSelectedRangePreview.d.ts +11 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/RangeRatioSelect.d.ts +2 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/RangeSelector.d.ts +21 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/RateToggle.d.ts +9 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/RemoveButton.d.ts +12 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/ReviewModal.d.ts +18 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/TokenAndEtherscan.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/TokenPairSelect.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/shared.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/components/widgets.d.ts +56 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/constants/misc.d.ts +17 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/useAddVe33V3Liquidity.d.ts +15 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/usePoolActiveLiquidityChartData.d.ts +37 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/usePriceRangeRatioSelect.d.ts +28 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/useRemoveVe33V3Liquidity.d.ts +14 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/useSetRange.d.ts +36 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/useVe33V3Amounts.d.ts +19 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/hooks/useVe33V3Pair.d.ts +58 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/index.d.ts +5 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/types.d.ts +10 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/calldata.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/computeSurroundingTicks.d.ts +4 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/constants.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/encodeSqrtRatioX96.d.ts +9 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/formatTickPrice.d.ts +1 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/fullMath.d.ts +8 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/getPositionAmount.d.ts +39 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/getPositionAmountWithSlippage.d.ts +23 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/getTickToPrice.d.ts +10 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/maxLiquidityForAmounts.d.ts +22 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/mostSignificantBit.d.ts +2 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/nearestUsableTick.d.ts +6 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/slippage.d.ts +3 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/sqrt.d.ts +7 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/sqrtPriceMath.d.ts +13 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/tickMath.d.ts +34 -0
- package/dist/types/widgets/ve33/Ve33V3PoolOperate/utils/tryParseTick.d.ts +4 -0
- package/dist/types/widgets/ve33/VotePoolList/CardList.d.ts +12 -0
- package/dist/types/widgets/ve33/VotePoolList/SetVotePowerDialog.d.ts +12 -0
- package/dist/types/widgets/ve33/VotePoolList/TableList.d.ts +12 -0
- package/dist/types/widgets/ve33/VotePoolList/hooks/useVoteVe33.d.ts +7 -0
- package/dist/types/widgets/ve33/VotePoolList/index.d.ts +1 -0
- package/dist/types/widgets/ve33/VotePoolList/widgets.d.ts +35 -0
- package/dist/types/widgets/ve33/components/GoBack.d.ts +4 -0
- package/dist/types/widgets/ve33/components/LockSlider.d.ts +5 -0
- package/dist/types/widgets/ve33/components/PoolHead.d.ts +8 -0
- package/dist/types/widgets/ve33/components/PoolTokenInfo.d.ts +11 -0
- package/dist/types/widgets/ve33/components/PoolTypeTag.d.ts +8 -0
- package/dist/types/widgets/ve33/components/widgets.d.ts +5 -0
- package/dist/types/widgets/ve33/config.d.ts +62 -0
- package/dist/types/widgets/ve33/constants.d.ts +21 -0
- package/dist/types/widgets/ve33/hooks/usePoolColors.d.ts +11 -0
- package/dist/types/widgets/ve33/hooks/useVe33PositionAmounts.d.ts +17 -0
- package/dist/types/widgets/ve33/hooks/useVe33V2ClaimEmissions.d.ts +4 -0
- package/dist/types/widgets/ve33/hooks/useVe33V2ClaimTradingFees.d.ts +4 -0
- package/dist/types/widgets/ve33/hooks/useVe33V2Stake.d.ts +5 -0
- package/dist/types/widgets/ve33/hooks/useVe33V2UnStake.d.ts +5 -0
- package/dist/types/widgets/ve33/hooks/useVe33V3ClaimEmissions.d.ts +5 -0
- package/dist/types/widgets/ve33/hooks/useVe33V3ClaimTradingFees.d.ts +4 -0
- package/dist/types/widgets/ve33/hooks/useVe33V3Stake.d.ts +5 -0
- package/dist/types/widgets/ve33/hooks/useVe33V3StakeApproveStatus.d.ts +17 -0
- package/dist/types/widgets/ve33/hooks/useVe33V3UnStake.d.ts +5 -0
- package/dist/types/widgets/ve33/hooks/useVotePoolFilters.d.ts +13 -0
- package/dist/types/widgets/ve33/hooks/useVoteTabs.d.ts +12 -0
- package/dist/types/widgets/ve33/types.d.ts +38 -0
- package/dist/types/widgets/ve33/utils.d.ts +9 -0
- package/package.json +10 -10
- package/dist/index-CHBBNnLK.cjs +0 -31
- package/dist/index-a6XIfxp-.js +0 -31
- package/dist/types/hooks/Swap/useFetchRoutePrice.test.d.ts +0 -1
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { BoxProps } from '@dodoex/components';
|
|
2
|
+
declare const gapValues: {
|
|
3
|
+
xs: string;
|
|
4
|
+
sm: string;
|
|
5
|
+
md: string;
|
|
6
|
+
lg: string;
|
|
7
|
+
xl: string;
|
|
8
|
+
};
|
|
9
|
+
export type Gap = keyof typeof gapValues;
|
|
10
|
+
export interface YellowCardProps {
|
|
11
|
+
children?: React.ReactNode;
|
|
12
|
+
}
|
|
13
|
+
export declare const Card: ({ children, sx, }: {
|
|
14
|
+
sx?: BoxProps["sx"];
|
|
15
|
+
children?: React.ReactNode;
|
|
16
|
+
}) => JSX.Element;
|
|
17
|
+
export declare const LightCard: ({ children, border, sx, }: {
|
|
18
|
+
sx?: BoxProps["sx"];
|
|
19
|
+
border?: boolean;
|
|
20
|
+
children?: React.ReactNode;
|
|
21
|
+
}) => JSX.Element;
|
|
22
|
+
export declare const YellowCard: ({ children }: YellowCardProps) => JSX.Element;
|
|
23
|
+
export declare function ColumnCenter({ gap, flex, children, style, }: {
|
|
24
|
+
gap?: Gap | string;
|
|
25
|
+
flex?: string;
|
|
26
|
+
children: React.ReactNode;
|
|
27
|
+
style?: BoxProps['sx'];
|
|
28
|
+
}): JSX.Element;
|
|
29
|
+
export declare function AutoColumn({ gap, justify, grow, children, style, }: {
|
|
30
|
+
gap?: Gap | string;
|
|
31
|
+
justify?: 'stretch' | 'center' | 'start' | 'end' | 'flex-start' | 'flex-end' | 'space-between';
|
|
32
|
+
grow?: true;
|
|
33
|
+
children: React.ReactNode;
|
|
34
|
+
style?: BoxProps['sx'];
|
|
35
|
+
}): JSX.Element;
|
|
36
|
+
export declare function Row({ gap, children, sx, }: {
|
|
37
|
+
gap?: Gap | string;
|
|
38
|
+
children: React.ReactNode;
|
|
39
|
+
sx?: BoxProps['sx'];
|
|
40
|
+
}): JSX.Element;
|
|
41
|
+
export declare function RowBetween({ children, style, }: {
|
|
42
|
+
children: React.ReactNode;
|
|
43
|
+
style?: BoxProps['sx'];
|
|
44
|
+
}): JSX.Element;
|
|
45
|
+
export declare function RowFixed({ gap, justify, children, sx, }: {
|
|
46
|
+
gap?: string;
|
|
47
|
+
justify?: string;
|
|
48
|
+
children: React.ReactNode;
|
|
49
|
+
sx?: BoxProps['sx'];
|
|
50
|
+
}): JSX.Element;
|
|
51
|
+
export declare function DynamicSection({ children, disabled, sx, }: {
|
|
52
|
+
children: React.ReactNode;
|
|
53
|
+
disabled?: boolean;
|
|
54
|
+
sx?: BoxProps['sx'];
|
|
55
|
+
}): JSX.Element;
|
|
56
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
import { Percent } from '../../../../utils/fractions';
|
|
3
|
+
export declare const ZERO_ADDRESS = "0x0000000000000000000000000000000000000000";
|
|
4
|
+
export declare const DEFAULT_DEADLINE_FROM_NOW: number;
|
|
5
|
+
export declare const L2_DEADLINE_FROM_NOW: number;
|
|
6
|
+
export declare const DEFAULT_TXN_DISMISS_MS = 10000;
|
|
7
|
+
export declare const L2_TXN_DISMISS_MS = 5000;
|
|
8
|
+
export declare const BIG_INT_ZERO: JSBI;
|
|
9
|
+
export declare const BIPS_BASE = 10000;
|
|
10
|
+
export declare const ONE_BIPS: Percent;
|
|
11
|
+
export declare const ALLOWED_PRICE_IMPACT_LOW: Percent;
|
|
12
|
+
export declare const ALLOWED_PRICE_IMPACT_MEDIUM: Percent;
|
|
13
|
+
export declare const ALLOWED_PRICE_IMPACT_HIGH: Percent;
|
|
14
|
+
export declare const PRICE_IMPACT_WITHOUT_FEE_CONFIRM_MIN: Percent;
|
|
15
|
+
export declare const BLOCKED_PRICE_IMPACT_NON_EXPERT: Percent;
|
|
16
|
+
export declare const ZERO_PERCENT: Percent;
|
|
17
|
+
export declare const ONE_HUNDRED_PERCENT: Percent;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { useVe33V3Pair } from './useVe33V3Pair';
|
|
2
|
+
export declare function useAddVe33V3Liquidity(): import("@tanstack/react-query").UseMutationResult<import("../../../../hooks/Submission/types").ExecutionResult | undefined, Error, {
|
|
3
|
+
recipient?: string;
|
|
4
|
+
pool?: ReturnType<typeof useVe33V3Pair>;
|
|
5
|
+
tokenId?: number | string;
|
|
6
|
+
amount0: string;
|
|
7
|
+
amount1: string;
|
|
8
|
+
sqrtPriceX96: string;
|
|
9
|
+
tickSpacing: number;
|
|
10
|
+
tickLower: number;
|
|
11
|
+
tickUpper: number;
|
|
12
|
+
amount0Min: string;
|
|
13
|
+
amount1Min: string;
|
|
14
|
+
successBack?: () => void;
|
|
15
|
+
}, unknown>;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
3
|
+
import { ChartEntry } from '../components/LiquidityChartRangeInput/types';
|
|
4
|
+
import { Price } from '../../../../utils/fractions';
|
|
5
|
+
export interface TickProcessed {
|
|
6
|
+
tick: number;
|
|
7
|
+
liquidityActive: JSBI;
|
|
8
|
+
liquidityNet: JSBI;
|
|
9
|
+
price0: string;
|
|
10
|
+
sdkPrice: Price;
|
|
11
|
+
}
|
|
12
|
+
export interface FetchTicks {
|
|
13
|
+
ticks: Array<{
|
|
14
|
+
id: string;
|
|
15
|
+
liquidityNet: string;
|
|
16
|
+
poolAddress?: string;
|
|
17
|
+
price0: string;
|
|
18
|
+
price1: string;
|
|
19
|
+
tickIdx: string;
|
|
20
|
+
}> | undefined | null;
|
|
21
|
+
isLoading: boolean;
|
|
22
|
+
isError: boolean;
|
|
23
|
+
refetch: () => void;
|
|
24
|
+
}
|
|
25
|
+
export declare function usePoolActiveLiquidityChartData({ tickCurrent, liquidity, fetchTicks, token0, token1, }: {
|
|
26
|
+
tickCurrent: number | undefined;
|
|
27
|
+
liquidity: string | undefined;
|
|
28
|
+
fetchTicks?: FetchTicks;
|
|
29
|
+
token0: TokenInfo | undefined;
|
|
30
|
+
token1: TokenInfo | undefined;
|
|
31
|
+
}): {
|
|
32
|
+
hidden: boolean;
|
|
33
|
+
isLoading: boolean;
|
|
34
|
+
error: boolean;
|
|
35
|
+
data: TickProcessed[] | undefined;
|
|
36
|
+
formattedData: ChartEntry[] | undefined;
|
|
37
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Price } from '../../../../utils/fractions';
|
|
2
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
3
|
+
import { Bound } from '../types';
|
|
4
|
+
export interface PriceRangeRatioSelectProps {
|
|
5
|
+
totalApr: bigint | undefined;
|
|
6
|
+
currentPrice?: string;
|
|
7
|
+
tickSpacing?: number;
|
|
8
|
+
priceLower: Price | undefined;
|
|
9
|
+
priceUpper: Price | undefined;
|
|
10
|
+
token0: TokenInfo | undefined;
|
|
11
|
+
token1: TokenInfo | undefined;
|
|
12
|
+
tickSpaceLimits: {
|
|
13
|
+
[bound in Bound]?: number | undefined;
|
|
14
|
+
};
|
|
15
|
+
onLeftRangeInput: (typedValue: string) => void;
|
|
16
|
+
onRightRangeInput: (typedValue: string) => void;
|
|
17
|
+
handleSetFullRange: () => void;
|
|
18
|
+
}
|
|
19
|
+
export declare function usePriceRangeRatioSelect({ totalApr, currentPrice, tickSpacing, priceLower, priceUpper, token0, token1, tickSpaceLimits, onLeftRangeInput, onRightRangeInput, handleSetFullRange, }: PriceRangeRatioSelectProps): {
|
|
20
|
+
options: {
|
|
21
|
+
type: string;
|
|
22
|
+
ratio: string;
|
|
23
|
+
apr: string;
|
|
24
|
+
borderRadius: string;
|
|
25
|
+
active: boolean;
|
|
26
|
+
onClick: () => void;
|
|
27
|
+
}[];
|
|
28
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import BigNumber from 'bignumber.js';
|
|
2
|
+
export declare function useRemoveVe33V3Liquidity(): import("@tanstack/react-query").UseMutationResult<import("../../../../hooks/Submission/types").ExecutionResult | undefined, Error, {
|
|
3
|
+
chainId?: number;
|
|
4
|
+
tokenId?: number | string;
|
|
5
|
+
amount0Min: string;
|
|
6
|
+
amount1Min: string;
|
|
7
|
+
newLiquidity: string;
|
|
8
|
+
collectOptions: {
|
|
9
|
+
expectedCurrencyOwed0: BigNumber;
|
|
10
|
+
expectedCurrencyOwed1: BigNumber;
|
|
11
|
+
recipient: string;
|
|
12
|
+
};
|
|
13
|
+
successBack?: () => void;
|
|
14
|
+
}, unknown>;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Price } from '../../../../utils/fractions';
|
|
4
|
+
export declare function useSetRange({ tickCurrent, token0, token1, sorted, tickSpacing, price, }: {
|
|
5
|
+
tickCurrent: number | undefined;
|
|
6
|
+
token0: TokenInfo | undefined;
|
|
7
|
+
token1: TokenInfo | undefined;
|
|
8
|
+
sorted: boolean;
|
|
9
|
+
tickSpacing: number;
|
|
10
|
+
price?: Price;
|
|
11
|
+
}): {
|
|
12
|
+
tickSpaceLimits: {
|
|
13
|
+
LOWER: number | undefined;
|
|
14
|
+
UPPER: number | undefined;
|
|
15
|
+
};
|
|
16
|
+
ticksAtLimit: {
|
|
17
|
+
LOWER: boolean;
|
|
18
|
+
UPPER: boolean;
|
|
19
|
+
};
|
|
20
|
+
tickLower: number;
|
|
21
|
+
tickUpper: number;
|
|
22
|
+
priceLower: Price | undefined;
|
|
23
|
+
priceUpper: Price | undefined;
|
|
24
|
+
leftRangeTypedValue: string | boolean;
|
|
25
|
+
rightRangeTypedValue: string | boolean;
|
|
26
|
+
invalidRange: boolean;
|
|
27
|
+
outOfRange: boolean;
|
|
28
|
+
getDecrementLower: () => string;
|
|
29
|
+
getIncrementLower: () => string;
|
|
30
|
+
getDecrementUpper: () => string;
|
|
31
|
+
getIncrementUpper: () => string;
|
|
32
|
+
handleSetFullRange: () => void;
|
|
33
|
+
handleRateToggle: () => void;
|
|
34
|
+
onLeftRangeInput: React.Dispatch<React.SetStateAction<string | boolean>>;
|
|
35
|
+
onRightRangeInput: React.Dispatch<React.SetStateAction<string | boolean>>;
|
|
36
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
2
|
+
import JSBI from 'jsbi';
|
|
3
|
+
export declare function useVe33V3Amounts({ baseToken, quoteToken, sqrtRatioX96, tickCurrent, tickLower, tickUpper, }: {
|
|
4
|
+
baseToken: TokenInfo | undefined;
|
|
5
|
+
quoteToken: TokenInfo | undefined;
|
|
6
|
+
sqrtRatioX96: JSBI | undefined;
|
|
7
|
+
tickCurrent: number | undefined;
|
|
8
|
+
tickLower: number | undefined;
|
|
9
|
+
tickUpper: number | undefined;
|
|
10
|
+
}): {
|
|
11
|
+
readonly: boolean;
|
|
12
|
+
baseAmount: string;
|
|
13
|
+
quoteAmount: string;
|
|
14
|
+
handleChangeBaseAmount: (value: string) => void;
|
|
15
|
+
handleChangeQuoteAmount: (value: string) => void;
|
|
16
|
+
handleBlurBaseAmount: (value: string) => void;
|
|
17
|
+
handleBlurQuoteAmount: (value: string) => void;
|
|
18
|
+
reset: () => void;
|
|
19
|
+
};
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
2
|
+
import { Price } from '../../../../utils/fractions';
|
|
3
|
+
export declare function useVe33V3Pair({ address, baseToken, quoteToken, startPriceTypedValue, }: {
|
|
4
|
+
address: string | undefined;
|
|
5
|
+
baseToken: TokenInfo | undefined;
|
|
6
|
+
quoteToken: TokenInfo | undefined;
|
|
7
|
+
startPriceTypedValue?: string;
|
|
8
|
+
}): {
|
|
9
|
+
chainId: undefined;
|
|
10
|
+
isRearTokenA: boolean;
|
|
11
|
+
token0: undefined;
|
|
12
|
+
token1: undefined;
|
|
13
|
+
token0Wrapped: undefined;
|
|
14
|
+
token1Wrapped: undefined;
|
|
15
|
+
isBaseTokenNative: boolean;
|
|
16
|
+
isQuoteTokenNative: boolean;
|
|
17
|
+
address: string | undefined;
|
|
18
|
+
fetchTickSpacing: import("@tanstack/react-query").UseQueryResult<bigint, Error>;
|
|
19
|
+
fetchGlobalState: import("@tanstack/react-query").UseQueryResult<{
|
|
20
|
+
sqrtPriceX96: bigint;
|
|
21
|
+
tick: bigint;
|
|
22
|
+
observationIndex: bigint;
|
|
23
|
+
observationCardinality: bigint;
|
|
24
|
+
observationCardinalityNext: bigint;
|
|
25
|
+
unlocked: boolean;
|
|
26
|
+
}, Error>;
|
|
27
|
+
fetchLiquidity: import("@tanstack/react-query").UseQueryResult<bigint, Error>;
|
|
28
|
+
currentTick: number | undefined;
|
|
29
|
+
currentSqrt: string | undefined;
|
|
30
|
+
price: Price | undefined;
|
|
31
|
+
reversePrice: string | undefined;
|
|
32
|
+
tickSpacing: number;
|
|
33
|
+
} | {
|
|
34
|
+
chainId: import("@dodoex/api").ChainId;
|
|
35
|
+
isRearTokenA: boolean;
|
|
36
|
+
token0: TokenInfo;
|
|
37
|
+
token1: TokenInfo;
|
|
38
|
+
token0Wrapped: TokenInfo;
|
|
39
|
+
token1Wrapped: TokenInfo;
|
|
40
|
+
isBaseTokenNative: boolean;
|
|
41
|
+
isQuoteTokenNative: boolean;
|
|
42
|
+
address: string | undefined;
|
|
43
|
+
fetchTickSpacing: import("@tanstack/react-query").UseQueryResult<bigint, Error>;
|
|
44
|
+
fetchGlobalState: import("@tanstack/react-query").UseQueryResult<{
|
|
45
|
+
sqrtPriceX96: bigint;
|
|
46
|
+
tick: bigint;
|
|
47
|
+
observationIndex: bigint;
|
|
48
|
+
observationCardinality: bigint;
|
|
49
|
+
observationCardinalityNext: bigint;
|
|
50
|
+
unlocked: boolean;
|
|
51
|
+
}, Error>;
|
|
52
|
+
fetchLiquidity: import("@tanstack/react-query").UseQueryResult<bigint, Error>;
|
|
53
|
+
currentTick: number | undefined;
|
|
54
|
+
currentSqrt: string | undefined;
|
|
55
|
+
price: Price | undefined;
|
|
56
|
+
reversePrice: string | undefined;
|
|
57
|
+
tickSpacing: number;
|
|
58
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PoolOperateProps } from '../Ve33V2PoolOperate';
|
|
2
|
+
export default function Ve33V3PoolOperateDialog({ modal, ...props }: PoolOperateProps & {
|
|
3
|
+
modal?: boolean;
|
|
4
|
+
}): JSX.Element;
|
|
5
|
+
export declare function Ve33V3PoolOperate({ sx, pool, operate, account, errorRefetch, submittedBack, onClose, }: PoolOperateProps): JSX.Element;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Ticks } from '@dodoex/api';
|
|
2
|
+
import { TickProcessed } from '../hooks/usePoolTickData';
|
|
3
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
4
|
+
export default function computeSurroundingTicks(token0: TokenInfo, token1: TokenInfo, activeTickProcessed: TickProcessed, sortedTickData: Ticks, pivot: number, ascending: boolean): TickProcessed[];
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
import { BigintIsh } from './constants';
|
|
3
|
+
/**
|
|
4
|
+
* Returns the sqrt ratio as a Q64.96 corresponding to a given ratio of amount1 and amount0
|
|
5
|
+
* @param amount1 The numerator amount i.e., the amount of token1
|
|
6
|
+
* @param amount0 The denominator amount i.e., the amount of token0
|
|
7
|
+
* @returns The sqrt ratio
|
|
8
|
+
*/
|
|
9
|
+
export declare function encodeSqrtRatioX96(amount1: BigintIsh, amount0: BigintIsh): JSBI;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function formatAmountWithAlphabetSymbol(amount: string | undefined, decimals?: number): string;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
import { BigintIsh } from './constants';
|
|
3
|
+
export declare function getPositionAmount0({ tickCurrent, tickLower, tickUpper, liquidity, roundUp, sqrtRatioX96: sqrtRatioX96Props, }: {
|
|
4
|
+
tickCurrent: number;
|
|
5
|
+
tickLower: number;
|
|
6
|
+
tickUpper: number;
|
|
7
|
+
liquidity: number | bigint | JSBI | string;
|
|
8
|
+
roundUp?: boolean;
|
|
9
|
+
sqrtRatioX96?: JSBI | bigint;
|
|
10
|
+
}): JSBI;
|
|
11
|
+
export declare function getPositionAmount1({ tickCurrent, tickLower, tickUpper, liquidity, roundUp, sqrtRatioX96: sqrtRatioX96Props, }: {
|
|
12
|
+
tickCurrent: number;
|
|
13
|
+
tickLower: number;
|
|
14
|
+
tickUpper: number;
|
|
15
|
+
liquidity: number | bigint | JSBI | string;
|
|
16
|
+
roundUp?: boolean;
|
|
17
|
+
sqrtRatioX96?: bigint;
|
|
18
|
+
}): JSBI;
|
|
19
|
+
export declare function getPositionAmountFromAmount0({ sqrtRatioX96, tickCurrent, tickLower, tickUpper, amount0, useFullPrecision, }: {
|
|
20
|
+
sqrtRatioX96: JSBI;
|
|
21
|
+
tickCurrent: number;
|
|
22
|
+
tickLower: number;
|
|
23
|
+
tickUpper: number;
|
|
24
|
+
amount0: BigintIsh;
|
|
25
|
+
useFullPrecision: boolean;
|
|
26
|
+
}): {
|
|
27
|
+
amount0: JSBI;
|
|
28
|
+
amount1: JSBI;
|
|
29
|
+
};
|
|
30
|
+
export declare function getPositionAmountFromAmount1({ sqrtRatioX96, tickCurrent, tickLower, tickUpper, amount1, }: {
|
|
31
|
+
sqrtRatioX96: JSBI;
|
|
32
|
+
tickCurrent: number;
|
|
33
|
+
tickLower: number;
|
|
34
|
+
tickUpper: number;
|
|
35
|
+
amount1: BigintIsh;
|
|
36
|
+
}): {
|
|
37
|
+
amount0: JSBI;
|
|
38
|
+
amount1: JSBI;
|
|
39
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
import { Percent } from '../../../../utils/fractions';
|
|
3
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
4
|
+
/**
|
|
5
|
+
* Returns the minimum amounts that must be sent in order to safely mint the amount of liquidity held by the position
|
|
6
|
+
* with the given slippage tolerance
|
|
7
|
+
* @param slippageTolerance Tolerance of unfavorable slippage from the current price
|
|
8
|
+
* @returns The amounts, with slippage
|
|
9
|
+
*/
|
|
10
|
+
export declare function mintAmountsWithSlippage(tickCurrent: number, slippageTolerance: Percent, tickLower: number, tickUpper: number, baseToken: TokenInfo, quoteToken: TokenInfo, amount0: string, amount1: string): {
|
|
11
|
+
amount0: JSBI;
|
|
12
|
+
amount1: JSBI;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Returns the minimum amounts that should be requested in order to safely burn the amount of liquidity held by the
|
|
16
|
+
* position with the given slippage tolerance
|
|
17
|
+
* @param slippageTolerance tolerance of unfavorable slippage from the current price
|
|
18
|
+
* @returns The amounts, with slippage
|
|
19
|
+
*/
|
|
20
|
+
export declare function burnAmountsWithSlippage(tickCurrent: number, slippageTolerance: Percent, tickLower: number, tickUpper: number, liquidity: number | bigint | JSBI | string, baseToken: TokenInfo, quoteToken: TokenInfo): Readonly<{
|
|
21
|
+
amount0: JSBI;
|
|
22
|
+
amount1: JSBI;
|
|
23
|
+
}>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
2
|
+
import { Price } from '../../../../utils/fractions';
|
|
3
|
+
/**
|
|
4
|
+
* Returns the first tick for which the given price is greater than or equal to the tick price
|
|
5
|
+
* @param price for which to return the closest tick that represents a price less than or equal to the input price,
|
|
6
|
+
* i.e. the price of the returned tick is less than or equal to the input price
|
|
7
|
+
*/
|
|
8
|
+
export declare function priceToClosestTick(price: Price): number;
|
|
9
|
+
export declare function tickToPrice(baseToken: TokenInfo, quoteToken: TokenInfo, tickCurrent: number | bigint): Price;
|
|
10
|
+
export declare function getTickToPrice(baseToken?: TokenInfo, quoteToken?: TokenInfo, tickCurrent?: number | bigint): string | undefined;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
import { BigintIsh } from './constants';
|
|
3
|
+
/**
|
|
4
|
+
* Computes the maximum amount of liquidity received for a given amount of token0, token1,
|
|
5
|
+
* and the prices at the tick boundaries.
|
|
6
|
+
* @param sqrtRatioCurrentX96 the current price
|
|
7
|
+
* @param sqrtRatioAX96 price at lower boundary
|
|
8
|
+
* @param sqrtRatioBX96 price at upper boundary
|
|
9
|
+
* @param amount0 token0 amount
|
|
10
|
+
* @param amount1 token1 amount
|
|
11
|
+
* @param useFullPrecision if false, liquidity will be maximized according to what the router can calculate,
|
|
12
|
+
* not what core can theoretically support
|
|
13
|
+
*/
|
|
14
|
+
export declare function maxLiquidityForAmounts(sqrtRatioCurrentX96: JSBI, sqrtRatioAX96: JSBI, sqrtRatioBX96: JSBI, amount0: BigintIsh, amount1: BigintIsh, useFullPrecision: boolean): JSBI;
|
|
15
|
+
export declare function getLiquidityByAmounts({ sqrtRatioX96, tickLower, tickUpper, amount0, amount1, useFullPrecision, }: {
|
|
16
|
+
sqrtRatioX96: JSBI;
|
|
17
|
+
tickLower: number;
|
|
18
|
+
tickUpper: number;
|
|
19
|
+
amount0: BigintIsh;
|
|
20
|
+
amount1: BigintIsh;
|
|
21
|
+
useFullPrecision: boolean;
|
|
22
|
+
}): JSBI;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Returns the closest tick that is nearest a given tick and usable for the given tick spacing
|
|
3
|
+
* @param tick the target tick
|
|
4
|
+
* @param tickSpacing the spacing of the pool
|
|
5
|
+
*/
|
|
6
|
+
export declare function nearestUsableTick(tick: number, tickSpacing: number): number;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
export declare abstract class SqrtPriceMath {
|
|
3
|
+
/**
|
|
4
|
+
* Cannot be constructed.
|
|
5
|
+
*/
|
|
6
|
+
private constructor();
|
|
7
|
+
static getAmount0Delta(sqrtRatioAX96: JSBI, sqrtRatioBX96: JSBI, liquidity: JSBI, roundUp: boolean): JSBI;
|
|
8
|
+
static getAmount1Delta(sqrtRatioAX96: JSBI, sqrtRatioBX96: JSBI, liquidity: JSBI, roundUp: boolean): JSBI;
|
|
9
|
+
static getNextSqrtPriceFromInput(sqrtPX96: JSBI, liquidity: JSBI, amountIn: JSBI, zeroForOne: boolean): JSBI;
|
|
10
|
+
static getNextSqrtPriceFromOutput(sqrtPX96: JSBI, liquidity: JSBI, amountOut: JSBI, zeroForOne: boolean): JSBI;
|
|
11
|
+
private static getNextSqrtPriceFromAmount0RoundingUp;
|
|
12
|
+
private static getNextSqrtPriceFromAmount1RoundingDown;
|
|
13
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import JSBI from 'jsbi';
|
|
2
|
+
export declare abstract class TickMath {
|
|
3
|
+
/**
|
|
4
|
+
* Cannot be constructed.
|
|
5
|
+
*/
|
|
6
|
+
private constructor();
|
|
7
|
+
/**
|
|
8
|
+
* The minimum tick that can be used on any pool.
|
|
9
|
+
*/
|
|
10
|
+
static MIN_TICK: number;
|
|
11
|
+
/**
|
|
12
|
+
* The maximum tick that can be used on any pool.
|
|
13
|
+
*/
|
|
14
|
+
static MAX_TICK: number;
|
|
15
|
+
/**
|
|
16
|
+
* The sqrt ratio corresponding to the minimum tick that could be used on any pool.
|
|
17
|
+
*/
|
|
18
|
+
static MIN_SQRT_RATIO: JSBI;
|
|
19
|
+
/**
|
|
20
|
+
* The sqrt ratio corresponding to the maximum tick that could be used on any pool.
|
|
21
|
+
*/
|
|
22
|
+
static MAX_SQRT_RATIO: JSBI;
|
|
23
|
+
/**
|
|
24
|
+
* Returns the sqrt ratio as a Q64.96 for the given tick. The sqrt ratio is computed as sqrt(1.0001)^tick
|
|
25
|
+
* @param tick the tick for which to compute the sqrt ratio
|
|
26
|
+
*/
|
|
27
|
+
static getSqrtRatioAtTick(tick: number): JSBI;
|
|
28
|
+
/**
|
|
29
|
+
* Returns the tick corresponding to a given sqrt ratio, s.t. #getSqrtRatioAtTick(tick) <= sqrtRatioX96
|
|
30
|
+
* and #getSqrtRatioAtTick(tick + 1) > sqrtRatioX96
|
|
31
|
+
* @param sqrtRatioX96 the sqrt ratio as a Q64.96 for which to compute the tick
|
|
32
|
+
*/
|
|
33
|
+
static getTickAtSqrtRatio(sqrtRatioX96: JSBI): number;
|
|
34
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
2
|
+
import { Price } from '../../../../utils/fractions';
|
|
3
|
+
export declare function tryParsePrice(baseToken?: TokenInfo, quoteToken?: TokenInfo, value?: string): Price | undefined;
|
|
4
|
+
export declare function tryParseTick(baseToken?: TokenInfo, quoteToken?: TokenInfo, value?: string, tickSpacing?: number): number | undefined;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { VotePoolInfoI } from '../types';
|
|
2
|
+
export interface CardListProps {
|
|
3
|
+
poolList: VotePoolInfoI[];
|
|
4
|
+
onSelectPool: (item: VotePoolInfoI) => void;
|
|
5
|
+
selectedPoolList: string[];
|
|
6
|
+
}
|
|
7
|
+
export declare const CardList: ({ poolList, ...props }: CardListProps) => JSX.Element;
|
|
8
|
+
export declare function CardItem({ item, onSelectPool, selectedPoolList, }: {
|
|
9
|
+
item?: VotePoolInfoI;
|
|
10
|
+
onSelectPool?: (item: VotePoolInfoI) => void;
|
|
11
|
+
selectedPoolList?: string[];
|
|
12
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { VotePoolInfoI } from '../types';
|
|
2
|
+
import { Lock } from '../Ve33LockList/hooks/useFetchUserLocks';
|
|
3
|
+
export default function SetVotePowerDialog({ chainId, account, open, onClose, data, lock, setLock, refetch, }: {
|
|
4
|
+
chainId: number | undefined;
|
|
5
|
+
account: string | undefined;
|
|
6
|
+
open: boolean;
|
|
7
|
+
onClose: () => void;
|
|
8
|
+
data: Array<VotePoolInfoI>;
|
|
9
|
+
lock: Lock | null;
|
|
10
|
+
setLock: (lock: Lock | null) => void;
|
|
11
|
+
refetch?: () => void;
|
|
12
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ChainId } from '@dodoex/api';
|
|
2
|
+
import { VotePoolInfoI } from '../types';
|
|
3
|
+
export interface TableListProps {
|
|
4
|
+
chainId: ChainId;
|
|
5
|
+
poolList: VotePoolInfoI[];
|
|
6
|
+
hasMore?: boolean;
|
|
7
|
+
loadMore?: () => void;
|
|
8
|
+
loadMoreLoading?: boolean;
|
|
9
|
+
onSelectPool: (item: VotePoolInfoI) => void;
|
|
10
|
+
selectedPoolList: string[];
|
|
11
|
+
}
|
|
12
|
+
export declare const TableList: ({ chainId, poolList, hasMore, loadMore, loadMoreLoading, onSelectPool, selectedPoolList, }: TableListProps) => JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const VotePoolList: () => JSX.Element;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { VotePoolInfoI } from '../types';
|
|
2
|
+
import { Lock } from '../Ve33LockList/hooks/useFetchUserLocks';
|
|
3
|
+
export declare function VAPRWidgets({ item }: {
|
|
4
|
+
item: VotePoolInfoI;
|
|
5
|
+
}): JSX.Element;
|
|
6
|
+
export declare function IncentivesWidgets({ item, showLogo, singleLine, }: {
|
|
7
|
+
item: VotePoolInfoI;
|
|
8
|
+
showLogo?: boolean;
|
|
9
|
+
singleLine?: boolean;
|
|
10
|
+
}): JSX.Element;
|
|
11
|
+
export declare function FeesWidgets({ item, showLogo, }: {
|
|
12
|
+
item: VotePoolInfoI;
|
|
13
|
+
showLogo?: boolean;
|
|
14
|
+
}): JSX.Element;
|
|
15
|
+
export declare function TotalVoteWidgets({ item, showLogo, singleLine, }: {
|
|
16
|
+
item: VotePoolInfoI;
|
|
17
|
+
showLogo?: boolean;
|
|
18
|
+
singleLine?: boolean;
|
|
19
|
+
}): JSX.Element;
|
|
20
|
+
export declare function MyVoteWidgets({ label, value, onChange, onBlur, loading, veNFTAmount, veNFTSymbol, }: {
|
|
21
|
+
label?: string;
|
|
22
|
+
value: number | undefined;
|
|
23
|
+
onChange: (v: number | undefined) => void;
|
|
24
|
+
onBlur?: () => void;
|
|
25
|
+
loading?: boolean;
|
|
26
|
+
veNFTAmount: number | string;
|
|
27
|
+
veNFTSymbol: string;
|
|
28
|
+
}): JSX.Element;
|
|
29
|
+
export declare function SelectLock({ fullWidth, chainId, account, selectedLock, setSelectedLock, }: {
|
|
30
|
+
fullWidth?: boolean;
|
|
31
|
+
chainId: number | undefined;
|
|
32
|
+
account: string | undefined;
|
|
33
|
+
selectedLock: Lock | null;
|
|
34
|
+
setSelectedLock: (lock: Lock | null) => void;
|
|
35
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ChainId } from '@dodoex/api';
|
|
2
|
+
import { Ve33PoolInfoI } from '../types';
|
|
3
|
+
export interface PoolHeadProps {
|
|
4
|
+
chainId: ChainId;
|
|
5
|
+
poolInfo: Ve33PoolInfoI;
|
|
6
|
+
size?: 'small' | 'medium';
|
|
7
|
+
}
|
|
8
|
+
export declare const PoolHead: ({ chainId, poolInfo, size, }: PoolHeadProps) => JSX.Element;
|