@dodoex/widgets 2.6.7 → 3.0.0-beta.0
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/b3f16b2626f03378.svg +10 -0
- package/dist/cjs/b3f16b2626f03378.svg +10 -0
- package/dist/cjs/failed-list-e6c1e563-7122998d.cjs +1 -0
- package/dist/cjs/helper-889c5e9a.cjs +1 -0
- package/dist/cjs/index-183743c8.cjs +45 -0
- package/dist/cjs/index-1904ef51.cjs +50 -0
- package/dist/cjs/index-19cf4c6e.cjs +50 -0
- package/dist/cjs/index-1a21b21a.cjs +45 -0
- package/dist/cjs/index-246a9973.cjs +50 -0
- package/dist/cjs/index-256d5f78.cjs +12 -0
- package/dist/cjs/index-39149ce7.cjs +45 -0
- package/dist/cjs/index-4190bae6.cjs +58 -0
- package/dist/cjs/index-457c65f3.cjs +78 -0
- package/dist/cjs/index-5eca89d2.cjs +50 -0
- package/dist/cjs/index-64af8ffd.cjs +45 -0
- package/dist/cjs/index-f2a80623.cjs +45 -0
- package/dist/cjs/index.cjs +1 -45
- package/dist/cjs/locales/en-US.js +1 -1
- package/dist/cjs/locales/zh-CN.js +1 -1
- package/dist/cjs/lottie-01f67a00.cjs +1 -0
- package/dist/cjs/lottie-09dbe581.cjs +1 -0
- package/dist/cjs/lottie-2035df95.cjs +1 -0
- package/dist/cjs/lottie-7e742196.cjs +1 -0
- package/dist/cjs/lottie-924a2436.cjs +1 -0
- package/dist/cjs/lottie-b9cf6aee.cjs +1 -0
- package/dist/cjs/lottie-c4b6404b.cjs +1 -0
- package/dist/cjs/lottie-ed4f1473.cjs +1 -0
- package/dist/cjs/lottie-edc8e0b8.cjs +1 -0
- package/dist/cjs/lottie-f516f300.cjs +1 -0
- package/dist/cjs/no-found-89a3b4af-9c7e1488.cjs +1 -0
- package/dist/cjs/no-result-01c60834-3e379801.cjs +1 -0
- package/dist/cjs/src/components/AddressWithLinkAndCopy.d.ts +22 -0
- package/dist/cjs/src/components/AutoButton.d.ts +7 -0
- package/dist/cjs/src/components/Bridge/SelectBridgeDialog/RouteCard.d.ts +1 -2
- package/dist/cjs/src/components/Confirm.d.ts +15 -0
- package/dist/cjs/src/components/ConnectWallet/ConnectWalletDialog.d.ts +5 -0
- package/dist/cjs/src/components/ConnectWallet/NeedConnectButton.d.ts +8 -0
- package/dist/cjs/src/components/ConnectWallet/OpenConnectWalletInfo.d.ts +2 -0
- package/dist/cjs/src/components/CopyTooltipToast.d.ts +9 -0
- package/dist/cjs/src/components/DataCard/DataCardGroup.d.ts +9 -0
- package/dist/cjs/src/components/Dialog.d.ts +1 -0
- package/dist/cjs/src/components/GoBack.d.ts +6 -0
- package/dist/cjs/src/components/HowItWorks.d.ts +11 -0
- package/dist/cjs/src/components/List/EmptyList.d.ts +7 -0
- package/dist/cjs/src/components/List/FailedList.d.ts +6 -0
- package/dist/cjs/src/components/RiskDialog.d.ts +7 -0
- package/dist/cjs/src/components/SelectChain.d.ts +12 -0
- package/dist/cjs/src/components/Swap/components/ConnectWallet/index.d.ts +1 -3
- package/dist/cjs/src/components/Swap/components/Dialog.d.ts +2 -1
- package/dist/cjs/src/components/Swap/components/TokenCard/BalanceText.d.ts +4 -2
- package/dist/cjs/src/components/Swap/components/TokenCard/NumberInput.d.ts +12 -9
- package/dist/cjs/src/components/Swap/components/TokenCard/PercentageSelectButtonGroup.d.ts +7 -0
- package/dist/cjs/src/components/Swap/components/TokenCard/TokenLogoCollapse.d.ts +4 -3
- package/dist/cjs/src/components/Swap/components/TokenCard/TokenPickerDialog.d.ts +6 -1
- package/dist/cjs/src/components/Swap/components/TokenCard/index.d.ts +16 -3
- package/dist/cjs/src/components/Swap/index.d.ts +1 -3
- package/dist/cjs/src/components/Token/TokenItem.d.ts +9 -0
- package/dist/cjs/src/components/TokenLogo.d.ts +3 -1
- package/dist/cjs/src/components/TokenLogoPair.d.ts +17 -0
- package/dist/cjs/src/components/TokenLogoSimple.d.ts +13 -0
- package/dist/cjs/src/components/TokenPicker/TokenItem.d.ts +3 -1
- package/dist/cjs/src/components/TokenPicker/TokenSearchLoadingSkelton.d.ts +2 -0
- package/dist/cjs/src/components/TokenPicker/index.d.ts +8 -3
- package/dist/cjs/src/components/TokenStatusButton.d.ts +7 -0
- package/dist/cjs/src/components/Widget/index.d.ts +3 -1
- package/dist/cjs/src/components/WidgetConfirm.d.ts +15 -0
- package/dist/cjs/src/components/WidgetContainer.d.ts +3 -0
- package/dist/cjs/src/components/WidgetDialog.d.ts +15 -0
- package/dist/cjs/src/components/chart/components/BaseButton.d.ts +5 -0
- package/dist/cjs/src/components/chart/components/Display.d.ts +9 -0
- package/dist/cjs/src/components/chart/components/Input.d.ts +7 -0
- package/dist/cjs/src/components/chart/components/NumberInput.d.ts +6 -0
- package/dist/cjs/src/components/chart/components/TogglePriceIcon.d.ts +8 -0
- package/dist/cjs/src/components/chart/components/TokenLogo.d.ts +5 -0
- package/dist/cjs/src/components/chart/depth-chart/DepthChartKonva.d.ts +30 -0
- package/dist/cjs/src/components/chart/depth-chart/__tests__/utils.test.d.ts +1 -0
- package/dist/cjs/src/components/chart/depth-chart/helper.d.ts +125 -0
- package/dist/cjs/src/components/chart/depth-chart/index.d.ts +18 -0
- package/dist/cjs/src/components/chart/depth-chart/index.styled.d.ts +29 -0
- package/dist/cjs/src/components/chart/depth-chart/useDepthLinePoints.d.ts +21 -0
- package/dist/cjs/src/components/chart/depth-chart/useGridLinePoints.d.ts +9 -0
- package/dist/cjs/src/components/chart/depth-chart/useHorizontalLabelPoints.d.ts +15 -0
- package/dist/cjs/src/components/chart/depth-chart/utils.d.ts +19 -0
- package/dist/cjs/src/components/chart/depth-chart-v2/index.d.ts +10 -0
- package/dist/cjs/src/components/chart/depth-chart-v2/index.styled.d.ts +15 -0
- package/dist/cjs/src/components/chart/hooks/usePreventWheel.d.ts +9 -0
- package/dist/cjs/src/components/chart/i18n.d.ts +1 -0
- package/dist/cjs/src/components/chart/liquidity-chart/LiquidityChartKonva.d.ts +28 -0
- package/dist/cjs/src/components/chart/liquidity-chart/__tests__/helper.test.d.ts +1 -0
- package/dist/cjs/src/components/chart/liquidity-chart/helper.d.ts +47 -0
- package/dist/cjs/src/components/chart/liquidity-chart/index.d.ts +17 -0
- package/dist/cjs/src/components/chart/liquidity-chart/index.styled.d.ts +9 -0
- package/dist/cjs/src/components/chart/liquidity-chart/useGridLine.d.ts +8 -0
- package/dist/cjs/src/components/chart/liquidity-chart/useHorizontalLabel.d.ts +10 -0
- package/dist/cjs/src/components/chart/liquidity-chart/useLiquidityLine.d.ts +18 -0
- package/dist/cjs/src/components/chart/liquidity-chart/useMiddleLine.d.ts +6 -0
- package/dist/cjs/src/components/chart/liquidity-chart/usePoints.d.ts +39 -0
- package/dist/cjs/src/components/chart/utils.d.ts +3 -0
- package/dist/cjs/src/constants/api.d.ts +5 -0
- package/dist/cjs/src/constants/chainList.d.ts +1 -0
- package/dist/cjs/src/constants/chains.d.ts +24 -31
- package/dist/cjs/src/constants/localstorage.d.ts +2 -0
- package/dist/cjs/src/constants/pool.d.ts +7 -0
- package/dist/cjs/src/constants/sessionStorage.d.ts +2 -0
- package/dist/cjs/src/hooks/Bridge/useExecuteBridgeRoute.d.ts +2 -1
- package/dist/cjs/src/hooks/Chain/useChainList.d.ts +2 -0
- package/dist/cjs/src/hooks/Chain/useChainList.test.d.ts +1 -0
- package/dist/cjs/src/hooks/ConnectWallet/useWalletInfo.d.ts +6 -0
- package/dist/cjs/src/hooks/Submission/types.d.ts +31 -2
- package/dist/cjs/src/hooks/Submission/useBalanceUpdateLoading.d.ts +15 -0
- package/dist/cjs/src/hooks/Submission/useExecution.d.ts +3 -2
- package/dist/cjs/src/hooks/Swap/useFetchFiatPrice.d.ts +3 -3
- package/dist/cjs/src/hooks/Token/useTokenList.d.ts +9 -3
- package/dist/cjs/src/hooks/Token/useTokenListDefaultToken.d.ts +30 -0
- package/dist/cjs/src/hooks/Token/useTokenListFetchBalance.d.ts +5 -2
- package/dist/cjs/src/hooks/Token/useTokenStatus.d.ts +20 -0
- package/dist/cjs/src/hooks/Token/useTokenStatus.test.d.ts +1 -0
- package/dist/cjs/src/hooks/contract/index.d.ts +0 -2
- package/dist/cjs/src/hooks/contract/useFetchETHBalance.d.ts +21 -1
- package/dist/cjs/src/hooks/contract/useFetchTokens.d.ts +4 -10
- package/dist/cjs/src/hooks/contract/wallet.d.ts +1 -1
- package/dist/cjs/src/hooks/style/useWidgetDevice.d.ts +6 -0
- package/dist/cjs/src/hooks/usePrevious.d.ts +1 -0
- package/dist/cjs/src/index.d.ts +6 -0
- package/dist/cjs/src/providers/GlobalConfigContext.d.ts +21 -0
- package/dist/cjs/src/providers/i18n.d.ts +9 -0
- package/dist/cjs/src/providers/queryClient/index.d.ts +2 -0
- package/dist/cjs/src/providers/queryClient.d.ts +2 -0
- package/dist/cjs/src/router/index.d.ts +9 -0
- package/dist/cjs/src/router/types.d.ts +35 -0
- package/dist/cjs/src/store/actions/token.d.ts +1 -8
- package/dist/cjs/src/store/actions/wallet.d.ts +2 -0
- package/dist/cjs/src/store/index.d.ts +7 -1
- package/dist/cjs/src/store/reducers/token.d.ts +0 -7
- package/dist/cjs/src/store/reducers/wallet.d.ts +4 -0
- package/dist/cjs/src/store/selectors/token.d.ts +0 -10
- package/dist/cjs/src/store/selectors/wallet.d.ts +5 -2
- package/dist/cjs/src/utils/address.d.ts +2 -2
- package/dist/cjs/src/utils/bytes.d.ts +3 -0
- package/dist/cjs/src/utils/formatter.d.ts +24 -1
- package/dist/cjs/src/utils/token.d.ts +21 -0
- package/dist/cjs/src/utils/utils.d.ts +1 -0
- package/dist/cjs/src/widgets/MiningWidget/LpTokenMiningOperate/index.d.ts +7 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/AssociateMine.d.ts +20 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/ClaimButton.d.ts +5 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/GetLpLink.d.ts +5 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/RewardListCard.d.ts +8 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/StakeButton.d.ts +9 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/UnstakeButton.d.ts +8 -0
- package/dist/cjs/src/widgets/MiningWidget/OperateArea/index.d.ts +13 -0
- package/dist/cjs/src/widgets/MiningWidget/helper.d.ts +2 -0
- package/dist/cjs/src/widgets/MiningWidget/hooks/useClaimMiningSubmit.d.ts +4 -0
- package/dist/cjs/src/widgets/MiningWidget/hooks/useRewardListAmount.d.ts +17 -0
- package/dist/cjs/src/widgets/MiningWidget/hooks/useStakeMiningSubmit.d.ts +5 -0
- package/dist/cjs/src/widgets/MiningWidget/hooks/useStatusAndStartBlockNumber.d.ts +13 -0
- package/dist/cjs/src/widgets/MiningWidget/hooks/useUnstakeMiningSubmit.d.ts +5 -0
- package/dist/cjs/src/widgets/MiningWidget/types.d.ts +58 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/ConfirmInfoDialog.d.ts +10 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/DepthAndLiquidityChart.d.ts +11 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/DepthChartWrapper.d.ts +11 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/EmptyChart.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/FeeRateCard.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/FixedInitPriceConfirm.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/LqSettingsShow.d.ts +13 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/RadioButton.d.ts +12 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/RadioButtonIcon.d.ts +4 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/RadioButtonTag.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/SectionTitle.d.ts +7 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/SelectAndInput.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/StepTitle.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/components/VersionChartExample.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/contract/useCreatePoolSubmit.d.ts +14 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/useCreatePmm.d.ts +26 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/useDefaultTokens.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/useFeeRateList.d.ts +13 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/useSlippageCoefficientList.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/useValidation.d.ts +4 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/hooks/useVersionList.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/index.d.ts +2 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/operate-widgets/BottomButtonGroup.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/operate-widgets/FeeRateSetting.d.ts +7 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/operate-widgets/InitPriceSetting.d.ts +12 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/operate-widgets/SlippageCoefficientSetting.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/operate-widgets/VersionSelect.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/reducer.d.ts +78 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/types.d.ts +35 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolCreate/utils.d.ts +18 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/BaseQuotePie.d.ts +24 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/ChartInfo.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/LiquidityProvidersTable.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/ParametersTable.d.ts +15 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/SwapsTable.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/index.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/Overview.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/StatBarChart.d.ts +10 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/TitleInfo.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/components/TotalLiquidity.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/hooks/useLiquidityProviders.d.ts +159 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/hooks/usePoolDashboard.d.ts +290 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/hooks/usePoolDayData.d.ts +166 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/hooks/usePoolSwapList.d.ts +245 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolDetail/index.d.ts +2 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/AddLiquidity.d.ts +12 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/MyCreated.d.ts +11 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/MyLiquidity.d.ts +11 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/AddingOrRemovingBtn.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/FilterAddressTags.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/FilterTokenTags.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/LiquidityTable.d.ts +3 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/LoadingCard.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/PoolApyTooltip.d.ts +18 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/TokenAndPoolFilter.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/components/TokenListPoolItem.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/hooks/usePoolListFilterChainId.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/hooks/usePoolListFilterTokenAndPool.d.ts +48 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/hooks/usePoolListTabs.d.ts +15 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolList/index.d.ts +2 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolModify/SectionTitle.d.ts +4 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolModify/index.d.ts +2 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolModify/operate-widgets/BottomButtonGroup.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolModify/operate-widgets/FeeRateSetting.d.ts +7 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/AddPoolOperate.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/Footer.d.ts +18 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/LiquidityInfo.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/PoolOperateInner.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/Ratio.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/RemovePoolOperate.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/SlippageSetting.d.ts +18 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/ComparePrice.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/LiquidityInfo.d.ts +10 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/OperateBtn.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/Ratio.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/SliderPercentageCard.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/SlippageSetting.d.ts +18 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/components/TokenList.d.ts +12 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/useCheckToken.d.ts +13 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/useComparePrice.d.ts +19 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/useLiquidityOperateAmount.d.ts +46 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/usePercentageRemove.d.ts +26 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/usePoolOperateTabs.d.ts +12 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/usePoolOrMiningTabs.d.ts +14 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/hooks/useRemoveLiquidityTokenStatus.d.ts +33 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/index.d.ts +14 -0
- package/dist/cjs/src/widgets/PoolWidget/PoolOperate/types.d.ts +17 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/contract/getModifyDPPPoolParams.d.ts +86 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/contract/useModifyDppPool.d.ts +22 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/contract/useOperateLiquidity.d.ts +36 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/contract/useWithdrawInfo.d.ts +33 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/usePoolBalanceInfo.d.ts +48 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/usePoolDetail.d.ts +341 -0
- package/dist/cjs/src/widgets/PoolWidget/hooks/usePoolTypeTag.d.ts +16 -0
- package/dist/cjs/src/widgets/PoolWidget/index.d.ts +2 -0
- package/dist/cjs/src/widgets/PoolWidget/list/AddLiquidity.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/list/components/FilterAddressTags.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/list/components/FilterTokenTags.d.ts +8 -0
- package/dist/cjs/src/widgets/PoolWidget/list/components/LoadingCard.d.ts +5 -0
- package/dist/cjs/src/widgets/PoolWidget/list/components/PoolApyTooltip.d.ts +17 -0
- package/dist/cjs/src/widgets/PoolWidget/list/components/TokenAndPoolFilter.d.ts +9 -0
- package/dist/cjs/src/widgets/PoolWidget/list/components/TokenListPoolItem.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/list/hooks/usePoolListFilterChainId.d.ts +6 -0
- package/dist/cjs/src/widgets/PoolWidget/list/hooks/usePoolListFilterTokenAndPool.d.ts +58 -0
- package/dist/cjs/src/widgets/PoolWidget/list/hooks/usePoolListTabs.d.ts +15 -0
- package/dist/cjs/src/widgets/PoolWidget/utils.d.ts +17 -0
- package/dist/failed-list-e6c1e563-478d73e0.js +1 -0
- package/dist/helper-7cc29594.js +1 -0
- package/dist/index-0e954ab8.js +45 -0
- package/dist/index-41db7f0e.js +45 -0
- package/dist/index-ae19eed4.js +12 -0
- package/dist/index-b07aac90.js +45 -0
- package/dist/index-c1a581ca.js +50 -0
- package/dist/index-c9dbe645.js +50 -0
- package/dist/index-cdf23d80.js +50 -0
- package/dist/index-d9d9a2cd.js +78 -0
- package/dist/index-db2c9b8f.js +58 -0
- package/dist/index-e58d24e5.js +50 -0
- package/dist/index-ee546021.js +45 -0
- package/dist/index-f055c418.js +45 -0
- package/dist/index.js +1 -45
- package/dist/locales/en-US.js +1 -1
- package/dist/locales/zh-CN.js +1 -1
- package/dist/lottie-0a7cf033.js +1 -0
- package/dist/lottie-449d7c9a.js +1 -0
- package/dist/lottie-48250155.js +1 -0
- package/dist/lottie-9678ebc9.js +1 -0
- package/dist/lottie-9b618308.js +1 -0
- package/dist/lottie-b4708423.js +1 -0
- package/dist/lottie-baaed8fa.js +1 -0
- package/dist/lottie-d6631244.js +1 -0
- package/dist/lottie-ed5a9dfd.js +1 -0
- package/dist/lottie-f76894b7.js +1 -0
- package/dist/no-found-89a3b4af-763d58f5.js +1 -0
- package/dist/no-result-01c60834-7921d2fa.js +1 -0
- package/dist/src/components/AddressWithLinkAndCopy.d.ts +22 -0
- package/dist/src/components/AutoButton.d.ts +7 -0
- package/dist/src/components/Bridge/SelectBridgeDialog/RouteCard.d.ts +1 -2
- package/dist/src/components/Confirm.d.ts +15 -0
- package/dist/src/components/ConnectWallet/ConnectWalletDialog.d.ts +5 -0
- package/dist/src/components/ConnectWallet/NeedConnectButton.d.ts +8 -0
- package/dist/src/components/ConnectWallet/OpenConnectWalletInfo.d.ts +2 -0
- package/dist/src/components/CopyTooltipToast.d.ts +9 -0
- package/dist/src/components/DataCard/DataCardGroup.d.ts +9 -0
- package/dist/src/components/Dialog.d.ts +1 -0
- package/dist/src/components/GoBack.d.ts +6 -0
- package/dist/src/components/HowItWorks.d.ts +11 -0
- package/dist/src/components/List/EmptyList.d.ts +7 -0
- package/dist/src/components/List/FailedList.d.ts +6 -0
- package/dist/src/components/RiskDialog.d.ts +7 -0
- package/dist/src/components/SelectChain.d.ts +12 -0
- package/dist/src/components/Swap/components/ConnectWallet/index.d.ts +1 -3
- package/dist/src/components/Swap/components/Dialog.d.ts +2 -1
- package/dist/src/components/Swap/components/TokenCard/BalanceText.d.ts +4 -2
- package/dist/src/components/Swap/components/TokenCard/NumberInput.d.ts +12 -9
- package/dist/src/components/Swap/components/TokenCard/PercentageSelectButtonGroup.d.ts +7 -0
- package/dist/src/components/Swap/components/TokenCard/TokenLogoCollapse.d.ts +4 -3
- package/dist/src/components/Swap/components/TokenCard/TokenPickerDialog.d.ts +6 -1
- package/dist/src/components/Swap/components/TokenCard/index.d.ts +16 -3
- package/dist/src/components/Swap/index.d.ts +1 -3
- package/dist/src/components/Token/TokenItem.d.ts +9 -0
- package/dist/src/components/TokenLogo.d.ts +3 -1
- package/dist/src/components/TokenLogoPair.d.ts +17 -0
- package/dist/src/components/TokenLogoSimple.d.ts +13 -0
- package/dist/src/components/TokenPicker/TokenItem.d.ts +3 -1
- package/dist/src/components/TokenPicker/TokenSearchLoadingSkelton.d.ts +2 -0
- package/dist/src/components/TokenPicker/index.d.ts +8 -3
- package/dist/src/components/TokenStatusButton.d.ts +7 -0
- package/dist/src/components/Widget/index.d.ts +3 -1
- package/dist/src/components/WidgetConfirm.d.ts +15 -0
- package/dist/src/components/WidgetContainer.d.ts +3 -0
- package/dist/src/components/WidgetDialog.d.ts +15 -0
- package/dist/src/components/chart/components/BaseButton.d.ts +5 -0
- package/dist/src/components/chart/components/Display.d.ts +9 -0
- package/dist/src/components/chart/components/Input.d.ts +7 -0
- package/dist/src/components/chart/components/NumberInput.d.ts +6 -0
- package/dist/src/components/chart/components/TogglePriceIcon.d.ts +8 -0
- package/dist/src/components/chart/components/TokenLogo.d.ts +5 -0
- package/dist/src/components/chart/depth-chart/DepthChartKonva.d.ts +30 -0
- package/dist/src/components/chart/depth-chart/__tests__/utils.test.d.ts +1 -0
- package/dist/src/components/chart/depth-chart/helper.d.ts +125 -0
- package/dist/src/components/chart/depth-chart/index.d.ts +18 -0
- package/dist/src/components/chart/depth-chart/index.styled.d.ts +29 -0
- package/dist/src/components/chart/depth-chart/useDepthLinePoints.d.ts +21 -0
- package/dist/src/components/chart/depth-chart/useGridLinePoints.d.ts +9 -0
- package/dist/src/components/chart/depth-chart/useHorizontalLabelPoints.d.ts +15 -0
- package/dist/src/components/chart/depth-chart/utils.d.ts +19 -0
- package/dist/src/components/chart/depth-chart-v2/index.d.ts +10 -0
- package/dist/src/components/chart/depth-chart-v2/index.styled.d.ts +15 -0
- package/dist/src/components/chart/hooks/usePreventWheel.d.ts +9 -0
- package/dist/src/components/chart/i18n.d.ts +1 -0
- package/dist/src/components/chart/liquidity-chart/LiquidityChartKonva.d.ts +28 -0
- package/dist/src/components/chart/liquidity-chart/__tests__/helper.test.d.ts +1 -0
- package/dist/src/components/chart/liquidity-chart/helper.d.ts +47 -0
- package/dist/src/components/chart/liquidity-chart/index.d.ts +17 -0
- package/dist/src/components/chart/liquidity-chart/index.styled.d.ts +9 -0
- package/dist/src/components/chart/liquidity-chart/useGridLine.d.ts +8 -0
- package/dist/src/components/chart/liquidity-chart/useHorizontalLabel.d.ts +10 -0
- package/dist/src/components/chart/liquidity-chart/useLiquidityLine.d.ts +18 -0
- package/dist/src/components/chart/liquidity-chart/useMiddleLine.d.ts +6 -0
- package/dist/src/components/chart/liquidity-chart/usePoints.d.ts +39 -0
- package/dist/src/components/chart/utils.d.ts +3 -0
- package/dist/src/constants/api.d.ts +5 -0
- package/dist/src/constants/chainList.d.ts +1 -0
- package/dist/src/constants/chains.d.ts +24 -31
- package/dist/src/constants/localstorage.d.ts +2 -0
- package/dist/src/constants/pool.d.ts +7 -0
- package/dist/src/constants/sessionStorage.d.ts +2 -0
- package/dist/src/hooks/Bridge/useExecuteBridgeRoute.d.ts +2 -1
- package/dist/src/hooks/Chain/useChainList.d.ts +2 -0
- package/dist/src/hooks/Chain/useChainList.test.d.ts +1 -0
- package/dist/src/hooks/ConnectWallet/useWalletInfo.d.ts +6 -0
- package/dist/src/hooks/Submission/types.d.ts +31 -2
- package/dist/src/hooks/Submission/useBalanceUpdateLoading.d.ts +15 -0
- package/dist/src/hooks/Submission/useExecution.d.ts +3 -2
- package/dist/src/hooks/Swap/useFetchFiatPrice.d.ts +3 -3
- package/dist/src/hooks/Token/useTokenList.d.ts +9 -3
- package/dist/src/hooks/Token/useTokenListDefaultToken.d.ts +30 -0
- package/dist/src/hooks/Token/useTokenListFetchBalance.d.ts +5 -2
- package/dist/src/hooks/Token/useTokenStatus.d.ts +20 -0
- package/dist/src/hooks/Token/useTokenStatus.test.d.ts +1 -0
- package/dist/src/hooks/contract/index.d.ts +0 -2
- package/dist/src/hooks/contract/useFetchETHBalance.d.ts +21 -1
- package/dist/src/hooks/contract/useFetchTokens.d.ts +4 -10
- package/dist/src/hooks/contract/wallet.d.ts +1 -1
- package/dist/src/hooks/style/useWidgetDevice.d.ts +6 -0
- package/dist/src/hooks/usePrevious.d.ts +1 -0
- package/dist/src/index.d.ts +6 -0
- package/dist/src/providers/GlobalConfigContext.d.ts +21 -0
- package/dist/src/providers/i18n.d.ts +9 -0
- package/dist/src/providers/queryClient/index.d.ts +2 -0
- package/dist/src/providers/queryClient.d.ts +2 -0
- package/dist/src/router/index.d.ts +9 -0
- package/dist/src/router/types.d.ts +35 -0
- package/dist/src/store/actions/token.d.ts +1 -8
- package/dist/src/store/actions/wallet.d.ts +2 -0
- package/dist/src/store/index.d.ts +7 -1
- package/dist/src/store/reducers/token.d.ts +0 -7
- package/dist/src/store/reducers/wallet.d.ts +4 -0
- package/dist/src/store/selectors/token.d.ts +0 -10
- package/dist/src/store/selectors/wallet.d.ts +5 -2
- package/dist/src/utils/address.d.ts +2 -2
- package/dist/src/utils/bytes.d.ts +3 -0
- package/dist/src/utils/formatter.d.ts +24 -1
- package/dist/src/utils/token.d.ts +21 -0
- package/dist/src/utils/utils.d.ts +1 -0
- package/dist/src/widgets/MiningWidget/LpTokenMiningOperate/index.d.ts +7 -0
- package/dist/src/widgets/MiningWidget/OperateArea/AssociateMine.d.ts +20 -0
- package/dist/src/widgets/MiningWidget/OperateArea/ClaimButton.d.ts +5 -0
- package/dist/src/widgets/MiningWidget/OperateArea/GetLpLink.d.ts +5 -0
- package/dist/src/widgets/MiningWidget/OperateArea/RewardListCard.d.ts +8 -0
- package/dist/src/widgets/MiningWidget/OperateArea/StakeButton.d.ts +9 -0
- package/dist/src/widgets/MiningWidget/OperateArea/UnstakeButton.d.ts +8 -0
- package/dist/src/widgets/MiningWidget/OperateArea/index.d.ts +13 -0
- package/dist/src/widgets/MiningWidget/helper.d.ts +2 -0
- package/dist/src/widgets/MiningWidget/hooks/useClaimMiningSubmit.d.ts +4 -0
- package/dist/src/widgets/MiningWidget/hooks/useRewardListAmount.d.ts +17 -0
- package/dist/src/widgets/MiningWidget/hooks/useStakeMiningSubmit.d.ts +5 -0
- package/dist/src/widgets/MiningWidget/hooks/useStatusAndStartBlockNumber.d.ts +13 -0
- package/dist/src/widgets/MiningWidget/hooks/useUnstakeMiningSubmit.d.ts +5 -0
- package/dist/src/widgets/MiningWidget/types.d.ts +58 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/ConfirmInfoDialog.d.ts +10 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/DepthAndLiquidityChart.d.ts +11 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/DepthChartWrapper.d.ts +11 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/EmptyChart.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/FeeRateCard.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/FixedInitPriceConfirm.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/LqSettingsShow.d.ts +13 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/RadioButton.d.ts +12 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/RadioButtonIcon.d.ts +4 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/RadioButtonTag.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/SectionTitle.d.ts +7 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/SelectAndInput.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/StepTitle.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/components/VersionChartExample.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/contract/useCreatePoolSubmit.d.ts +14 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/useCreatePmm.d.ts +26 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/useDefaultTokens.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/useFeeRateList.d.ts +13 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/useSlippageCoefficientList.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/useValidation.d.ts +4 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/hooks/useVersionList.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/index.d.ts +2 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/operate-widgets/BottomButtonGroup.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/operate-widgets/FeeRateSetting.d.ts +7 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/operate-widgets/InitPriceSetting.d.ts +12 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/operate-widgets/SlippageCoefficientSetting.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/operate-widgets/VersionSelect.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/reducer.d.ts +78 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/types.d.ts +35 -0
- package/dist/src/widgets/PoolWidget/PoolCreate/utils.d.ts +18 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/BaseQuotePie.d.ts +24 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/ChartInfo.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/LiquidityProvidersTable.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/ParametersTable.d.ts +15 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/SwapsTable.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/MoreDetail/index.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/Overview.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/StatBarChart.d.ts +10 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/TitleInfo.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/components/TotalLiquidity.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/hooks/useLiquidityProviders.d.ts +159 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/hooks/usePoolDashboard.d.ts +290 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/hooks/usePoolDayData.d.ts +166 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/hooks/usePoolSwapList.d.ts +245 -0
- package/dist/src/widgets/PoolWidget/PoolDetail/index.d.ts +2 -0
- package/dist/src/widgets/PoolWidget/PoolList/AddLiquidity.d.ts +12 -0
- package/dist/src/widgets/PoolWidget/PoolList/MyCreated.d.ts +11 -0
- package/dist/src/widgets/PoolWidget/PoolList/MyLiquidity.d.ts +11 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/AddingOrRemovingBtn.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/FilterAddressTags.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/FilterTokenTags.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/LiquidityTable.d.ts +3 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/LoadingCard.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/PoolApyTooltip.d.ts +18 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/TokenAndPoolFilter.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/PoolList/components/TokenListPoolItem.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolList/hooks/usePoolListFilterChainId.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolList/hooks/usePoolListFilterTokenAndPool.d.ts +48 -0
- package/dist/src/widgets/PoolWidget/PoolList/hooks/usePoolListTabs.d.ts +15 -0
- package/dist/src/widgets/PoolWidget/PoolList/index.d.ts +2 -0
- package/dist/src/widgets/PoolWidget/PoolModify/SectionTitle.d.ts +4 -0
- package/dist/src/widgets/PoolWidget/PoolModify/index.d.ts +2 -0
- package/dist/src/widgets/PoolWidget/PoolModify/operate-widgets/BottomButtonGroup.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolModify/operate-widgets/FeeRateSetting.d.ts +7 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/AddPoolOperate.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/Footer.d.ts +18 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/LiquidityInfo.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/PoolOperateInner.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/Ratio.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/RemovePoolOperate.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/SlippageSetting.d.ts +18 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/ComparePrice.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/LiquidityInfo.d.ts +10 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/OperateBtn.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/Ratio.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/SliderPercentageCard.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/SlippageSetting.d.ts +18 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/components/TokenList.d.ts +12 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/useCheckToken.d.ts +13 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/useComparePrice.d.ts +19 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/useLiquidityOperateAmount.d.ts +46 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/usePercentageRemove.d.ts +26 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/usePoolOperateTabs.d.ts +12 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/usePoolOrMiningTabs.d.ts +14 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/hooks/useRemoveLiquidityTokenStatus.d.ts +33 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/index.d.ts +14 -0
- package/dist/src/widgets/PoolWidget/PoolOperate/types.d.ts +17 -0
- package/dist/src/widgets/PoolWidget/hooks/contract/getModifyDPPPoolParams.d.ts +86 -0
- package/dist/src/widgets/PoolWidget/hooks/contract/useModifyDppPool.d.ts +22 -0
- package/dist/src/widgets/PoolWidget/hooks/contract/useOperateLiquidity.d.ts +36 -0
- package/dist/src/widgets/PoolWidget/hooks/contract/useWithdrawInfo.d.ts +33 -0
- package/dist/src/widgets/PoolWidget/hooks/usePoolBalanceInfo.d.ts +48 -0
- package/dist/src/widgets/PoolWidget/hooks/usePoolDetail.d.ts +341 -0
- package/dist/src/widgets/PoolWidget/hooks/usePoolTypeTag.d.ts +16 -0
- package/dist/src/widgets/PoolWidget/index.d.ts +2 -0
- package/dist/src/widgets/PoolWidget/list/AddLiquidity.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/list/components/FilterAddressTags.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/list/components/FilterTokenTags.d.ts +8 -0
- package/dist/src/widgets/PoolWidget/list/components/LoadingCard.d.ts +5 -0
- package/dist/src/widgets/PoolWidget/list/components/PoolApyTooltip.d.ts +17 -0
- package/dist/src/widgets/PoolWidget/list/components/TokenAndPoolFilter.d.ts +9 -0
- package/dist/src/widgets/PoolWidget/list/components/TokenListPoolItem.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/list/hooks/usePoolListFilterChainId.d.ts +6 -0
- package/dist/src/widgets/PoolWidget/list/hooks/usePoolListFilterTokenAndPool.d.ts +58 -0
- package/dist/src/widgets/PoolWidget/list/hooks/usePoolListTabs.d.ts +15 -0
- package/dist/src/widgets/PoolWidget/utils.d.ts +17 -0
- package/package.json +12 -2
- package/dist/cjs/tokenList-ee5e15c8.cjs +0 -1
- package/dist/tokenList-4ef211de.js +0 -1
|
@@ -3,13 +3,14 @@ import { BigNumber } from 'bignumber.js';
|
|
|
3
3
|
* format to readable number, like: 0.00 -> 0, 1.00 -> 1, 1.235 -> 1.23, 1.230 -> 1.23
|
|
4
4
|
* @param input
|
|
5
5
|
*/
|
|
6
|
-
export declare function formatReadableNumber({ input, showDecimals, showPrecisionDecimals, showIntegerOnly, showDecimalsOnly, noGroupSeparator, }: {
|
|
6
|
+
export declare function formatReadableNumber({ input, showDecimals, showPrecisionDecimals, showIntegerOnly, showDecimalsOnly, noGroupSeparator, roundingMode, }: {
|
|
7
7
|
input: BigNumber | number | string;
|
|
8
8
|
showDecimals?: number;
|
|
9
9
|
showIntegerOnly?: boolean;
|
|
10
10
|
showDecimalsOnly?: boolean;
|
|
11
11
|
showPrecisionDecimals?: number;
|
|
12
12
|
noGroupSeparator?: boolean;
|
|
13
|
+
roundingMode?: BigNumber.RoundingMode;
|
|
13
14
|
}): string;
|
|
14
15
|
export declare function formatTokenAmountNumber({ input, decimals, showPrecisionDecimals, noGroupSeparator, }: {
|
|
15
16
|
input?: BigNumber | number | string | null;
|
|
@@ -23,3 +24,25 @@ export declare const toWei: (amount: BigNumber | string | number, decimals: numb
|
|
|
23
24
|
export declare const byWei: (amount: BigNumber | string | number, decimals: number) => BigNumber;
|
|
24
25
|
export declare const getDecimalLimit: (decimals: number | undefined | null) => number;
|
|
25
26
|
export declare function getIntegerNumber(v: number): number;
|
|
27
|
+
/**
|
|
28
|
+
* format to short number, like: -0.12 -> 0, 0.0000123->0.000012, 123.234 -> 123.23, 1234.12 -> 1.23K, 1000000.123->1.00M
|
|
29
|
+
* @param n
|
|
30
|
+
*/
|
|
31
|
+
export declare function formatShortNumber(n?: BigNumber, showDecimals?: number): string;
|
|
32
|
+
export declare function formatExponentialNotation(n?: BigNumber): string;
|
|
33
|
+
/**
|
|
34
|
+
* format to percentage number
|
|
35
|
+
* @param param0 input number
|
|
36
|
+
*/
|
|
37
|
+
export declare function formatPercentageNumber({ input, showDecimals,
|
|
38
|
+
/** The percentage is rounded by default. */
|
|
39
|
+
roundingMode, }: {
|
|
40
|
+
input?: BigNumber | string | number | null;
|
|
41
|
+
showDecimals?: number;
|
|
42
|
+
roundingMode?: BigNumber.RoundingMode;
|
|
43
|
+
}): string;
|
|
44
|
+
export declare const formatApy: (amount: BigNumber, showDecimals?: number) => string;
|
|
45
|
+
export declare function formatUnknownTokenSymbol(token?: {
|
|
46
|
+
symbol: string;
|
|
47
|
+
name: string;
|
|
48
|
+
} | null): string;
|
|
@@ -7,3 +7,24 @@ export declare const getSwapTxValue: ({ tokenAmount, tokenAddress, chainId, }: {
|
|
|
7
7
|
tokenAddress: string;
|
|
8
8
|
chainId: ChainId;
|
|
9
9
|
}) => string;
|
|
10
|
+
export declare function getTokenPairCompareText({ fromToken, toToken, fromFiatPrice, toFiatPrice, reverse, showDecimals, }: {
|
|
11
|
+
fromToken: TokenInfo | undefined;
|
|
12
|
+
toToken: TokenInfo | undefined;
|
|
13
|
+
fromFiatPrice: BigNumber | undefined;
|
|
14
|
+
toFiatPrice: BigNumber | undefined;
|
|
15
|
+
reverse?: boolean;
|
|
16
|
+
showDecimals?: number;
|
|
17
|
+
}): {
|
|
18
|
+
comparePrice: BigNumber | null;
|
|
19
|
+
comparePriceText: string;
|
|
20
|
+
loading: boolean;
|
|
21
|
+
};
|
|
22
|
+
export declare function getShowDecimals(decimals: string | number): 6 | 4;
|
|
23
|
+
export declare function convertFetchTokenToTokenInfo(token: {
|
|
24
|
+
id?: string | null;
|
|
25
|
+
address?: string | null;
|
|
26
|
+
symbol?: string | null;
|
|
27
|
+
name?: string | null;
|
|
28
|
+
decimals?: number | null;
|
|
29
|
+
logoImg?: string | null | undefined;
|
|
30
|
+
} | undefined | null, chainId: ChainId | number): TokenInfo | null | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const increaseArray: (len: number) => string[];
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import BigNumber from 'bignumber.js';
|
|
3
|
+
import type { TokenInfo } from '../../../hooks/Token';
|
|
4
|
+
import { FetchMiningListItem } from '../types';
|
|
5
|
+
declare type Tokens = Array<TokenInfo & {
|
|
6
|
+
symbolEle?: string;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function AssociatedMine({ chainId, loading, miningItem, miningContractAddress, stakedTokenUSD, miningTitle, associatedMineSectionShort, stakedTokenList, rewardTokenList, isEnded, }: {
|
|
9
|
+
chainId: number;
|
|
10
|
+
loading?: boolean;
|
|
11
|
+
miningItem: FetchMiningListItem;
|
|
12
|
+
miningContractAddress: string;
|
|
13
|
+
miningTitle: string | undefined;
|
|
14
|
+
associatedMineSectionShort?: boolean;
|
|
15
|
+
stakedTokenUSD: BigNumber | undefined;
|
|
16
|
+
stakedTokenList: Tokens;
|
|
17
|
+
rewardTokenList: Tokens;
|
|
18
|
+
isEnded?: boolean;
|
|
19
|
+
}): JSX.Element;
|
|
20
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { BoxProps } from '@dodoex/components';
|
|
3
|
+
import { FetchMiningListItem } from '../types';
|
|
4
|
+
export declare function RewardListCard({ miningItem, loading, sx, }: {
|
|
5
|
+
miningItem: FetchMiningListItem;
|
|
6
|
+
loading?: boolean;
|
|
7
|
+
sx?: BoxProps['sx'];
|
|
8
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FetchMiningListItem } from '../types';
|
|
3
|
+
import { usePoolBalanceInfo } from '../../PoolWidget/hooks/usePoolBalanceInfo';
|
|
4
|
+
export declare function StakeButton({ goLpLink, amount, miningItem, balanceInfo, }: {
|
|
5
|
+
amount: string;
|
|
6
|
+
miningItem: FetchMiningListItem;
|
|
7
|
+
balanceInfo: ReturnType<typeof usePoolBalanceInfo>;
|
|
8
|
+
goLpLink?: () => Promise<void> | void;
|
|
9
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import BigNumber from 'bignumber.js';
|
|
3
|
+
import { FetchMiningListItem } from '../types';
|
|
4
|
+
export default function UnstakeButton({ amount, miningItem, overrideBalance, }: {
|
|
5
|
+
amount: string;
|
|
6
|
+
miningItem: FetchMiningListItem;
|
|
7
|
+
overrideBalance: BigNumber | undefined | null;
|
|
8
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { FetchMiningListItem, OperateType } from '../types';
|
|
2
|
+
import { MiningStatusE } from '@dodoex/api';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
export default function OperateArea({ chainId, status, loading, operateType, setOperateType, miningItem, associatedMineSectionVisible, goLpLink, }: {
|
|
5
|
+
chainId: number;
|
|
6
|
+
status: MiningStatusE;
|
|
7
|
+
loading?: boolean;
|
|
8
|
+
operateType: OperateType;
|
|
9
|
+
setOperateType: React.Dispatch<React.SetStateAction<OperateType>>;
|
|
10
|
+
miningItem: FetchMiningListItem;
|
|
11
|
+
associatedMineSectionVisible?: boolean;
|
|
12
|
+
goLpLink?: () => void;
|
|
13
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { FetchMiningListItem } from '../types';
|
|
2
|
+
export declare const useClaimMiningSubmit: ({ miningItem, }: {
|
|
3
|
+
miningItem: FetchMiningListItem;
|
|
4
|
+
}) => import("@tanstack/react-query/build/legacy/types").UseMutationResult<import("../../../hooks/Submission/types").ExecutionResult | undefined, Error, void, unknown>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { FetchMiningListItem } from '../types';
|
|
2
|
+
import BigNumber from 'bignumber.js';
|
|
3
|
+
export declare function useRewardListAmount({ miningItem, }: {
|
|
4
|
+
miningItem: FetchMiningListItem;
|
|
5
|
+
}): {
|
|
6
|
+
data: {
|
|
7
|
+
amount: BigNumber | null | undefined;
|
|
8
|
+
address: string;
|
|
9
|
+
symbol: string;
|
|
10
|
+
decimals: number;
|
|
11
|
+
usdPrice: string;
|
|
12
|
+
}[];
|
|
13
|
+
pending: boolean;
|
|
14
|
+
error: boolean;
|
|
15
|
+
totalReward: BigNumber;
|
|
16
|
+
totalRewardUSD: BigNumber;
|
|
17
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { FetchMiningListItem } from '../types';
|
|
2
|
+
export declare const useStakeMiningSubmit: ({ miningItem, amount, }: {
|
|
3
|
+
miningItem: FetchMiningListItem;
|
|
4
|
+
amount: string;
|
|
5
|
+
}) => import("@tanstack/react-query/build/legacy/types").UseMutationResult<import("../../../hooks/Submission/types").ExecutionResult | undefined, Error, void, unknown>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { MiningStatusE } from '@dodoex/api';
|
|
2
|
+
import { FetchMiningListItem } from '../types';
|
|
3
|
+
export declare function useStatusAndStartBlockNumber({ miningItem, }: {
|
|
4
|
+
miningItem: FetchMiningListItem;
|
|
5
|
+
}): {
|
|
6
|
+
status: MiningStatusE;
|
|
7
|
+
miningStatusList: {
|
|
8
|
+
status: MiningStatusE;
|
|
9
|
+
firstStartTime: import("bignumber.js").BigNumber | undefined;
|
|
10
|
+
lastEndTime: import("bignumber.js").BigNumber | undefined;
|
|
11
|
+
currentTime: import("bignumber.js").BigNumber;
|
|
12
|
+
}[];
|
|
13
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { FetchMiningListItem } from '../types';
|
|
2
|
+
export declare const useUnstakeMiningSubmit: ({ miningItem, amount, }: {
|
|
3
|
+
miningItem: FetchMiningListItem;
|
|
4
|
+
amount: string;
|
|
5
|
+
}) => import("@tanstack/react-query/build/legacy/types").UseMutationResult<import("../../../hooks/Submission/types").ExecutionResult | undefined, Error, void, unknown>;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { ExcludeNone, MiningApi } from '@dodoex/api';
|
|
2
|
+
import BigNumber from 'bignumber.js';
|
|
3
|
+
export declare type FetchMiningList = ExcludeNone<ReturnType<Exclude<typeof MiningApi.graphql.fetchMiningList['__apiType'], undefined>>['mining_list']>['list'];
|
|
4
|
+
export declare type FetchMiningListItem = ExcludeNone<FetchMiningList>[0] | undefined;
|
|
5
|
+
export declare type OperateType = null | 'stake' | 'unstake' | 'claim';
|
|
6
|
+
export interface MiningTokenI {
|
|
7
|
+
address: string | undefined;
|
|
8
|
+
decimals: number | undefined;
|
|
9
|
+
symbol: string | undefined;
|
|
10
|
+
}
|
|
11
|
+
/** The original token corresponding to lptoken has a price */
|
|
12
|
+
export interface MiningERC20TokenI extends MiningTokenI {
|
|
13
|
+
usdPrice: BigNumber | undefined;
|
|
14
|
+
logoImg: string | undefined;
|
|
15
|
+
}
|
|
16
|
+
/** lptoken, a token obtained by pledging the original token, has no price */
|
|
17
|
+
export interface MiningLpTokenI extends MiningTokenI {
|
|
18
|
+
}
|
|
19
|
+
/** Reward tokens */
|
|
20
|
+
export interface MiningRewardTokenI extends MiningERC20TokenI {
|
|
21
|
+
/**
|
|
22
|
+
* Block height when rewards start to be released: If not configured, it defaults to undefined and is considered to have ended.
|
|
23
|
+
*/
|
|
24
|
+
startBlock: BigNumber | undefined;
|
|
25
|
+
/**
|
|
26
|
+
* The timestamp corresponding to the block height when rewards start to be released; unit: seconds
|
|
27
|
+
*/
|
|
28
|
+
startTime: BigNumber | undefined;
|
|
29
|
+
/**
|
|
30
|
+
* Block height released after reward ends: If not configured, it defaults to undefined and is considered to have ended.
|
|
31
|
+
*/
|
|
32
|
+
endBlock: BigNumber | undefined;
|
|
33
|
+
/**
|
|
34
|
+
* The timestamp corresponding to the block height released after the reward ends; unit: seconds
|
|
35
|
+
*/
|
|
36
|
+
endTime: BigNumber | undefined;
|
|
37
|
+
/** The number of rewards released per block */
|
|
38
|
+
rewardPerBlock: BigNumber | undefined;
|
|
39
|
+
/** The apy returned by the interface is inaccurate and not timely. It is only used for initial rendering and subsequent front-end calculations */
|
|
40
|
+
initialApr: BigNumber | undefined;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* One mining project may correspond to multiple mining contracts. For example, classic mining bilateral pledge can obtain respective lpToken and then pledge them into different mining contracts. This mining project is equivalent to two mining projects, 1 to 2 , but the front end needs to be displayed on a card
|
|
44
|
+
*
|
|
45
|
+
* Avoid using identifiers such as base or quote in the data structure, and use array records to record this kind of 1-to-2 mining.
|
|
46
|
+
*/
|
|
47
|
+
export interface MiningMiningI {
|
|
48
|
+
/** lpToken.address-miningContractAddress */
|
|
49
|
+
id: string;
|
|
50
|
+
sourceToken: Array<MiningERC20TokenI>;
|
|
51
|
+
lpToken: MiningLpTokenI;
|
|
52
|
+
/** Mining contract: one mining contract corresponds to one lptoken */
|
|
53
|
+
miningContractAddress: string | undefined;
|
|
54
|
+
/**
|
|
55
|
+
* The v2 version has only one reward token; v3 may have multiple;
|
|
56
|
+
*/
|
|
57
|
+
rewardTokenList: MiningRewardTokenI[];
|
|
58
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { StateProps } from '../reducer';
|
|
3
|
+
export default function ConfirmInfoDialog({ on, onClose, state, onConfirm, isModify, loading, }: {
|
|
4
|
+
on: boolean;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
state: StateProps;
|
|
7
|
+
onConfirm: () => void;
|
|
8
|
+
isModify?: boolean;
|
|
9
|
+
loading?: boolean;
|
|
10
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { PMMModel, PmmModelParams } from '@dodoex/api';
|
|
3
|
+
import { BigNumber } from 'bignumber.js';
|
|
4
|
+
import { TokenInfo } from '../../../../hooks/Token';
|
|
5
|
+
export default function DepthAndLiquidityChart({ baseToken, quoteToken, pmmParams, pmmModel, midPrice, }: {
|
|
6
|
+
baseToken: TokenInfo | null;
|
|
7
|
+
quoteToken: TokenInfo | null;
|
|
8
|
+
pmmParams?: PmmModelParams;
|
|
9
|
+
pmmModel?: PMMModel;
|
|
10
|
+
midPrice?: BigNumber;
|
|
11
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { StateProps } from '../reducer';
|
|
3
|
+
export declare function DepthChartWrapper({ selectedVersion, baseToken, quoteToken, initPrice, slippageCoefficient, baseAmount, quoteAmount, }: {
|
|
4
|
+
selectedVersion: StateProps['selectedVersion'];
|
|
5
|
+
baseToken: StateProps['baseToken'];
|
|
6
|
+
quoteToken: StateProps['quoteToken'];
|
|
7
|
+
initPrice: StateProps['initPrice'];
|
|
8
|
+
slippageCoefficient: StateProps['slippageCoefficient'];
|
|
9
|
+
baseAmount: StateProps['baseAmount'];
|
|
10
|
+
quoteAmount: StateProps['quoteAmount'];
|
|
11
|
+
}): JSX.Element | null;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { StateProps } from '../reducer';
|
|
3
|
+
import { SectionStatusT } from '../types';
|
|
4
|
+
export declare function LqSettingsShow({ status, selectedVersion, baseToken, quoteToken, initPrice, slippageCoefficient, baseAmount, quoteAmount, }: {
|
|
5
|
+
status: SectionStatusT;
|
|
6
|
+
selectedVersion: StateProps['selectedVersion'];
|
|
7
|
+
baseToken: StateProps['baseToken'];
|
|
8
|
+
quoteToken: StateProps['quoteToken'];
|
|
9
|
+
initPrice: StateProps['initPrice'];
|
|
10
|
+
slippageCoefficient: StateProps['slippageCoefficient'];
|
|
11
|
+
baseAmount: StateProps['baseAmount'];
|
|
12
|
+
quoteAmount: StateProps['quoteAmount'];
|
|
13
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { BoxProps } from '@dodoex/components';
|
|
3
|
+
export default function RadioButton({ title, subTitle, description, selected, onClick, children, sx, titleSx, }: {
|
|
4
|
+
title: string;
|
|
5
|
+
subTitle?: React.ReactNode;
|
|
6
|
+
description: string;
|
|
7
|
+
selected: boolean;
|
|
8
|
+
onClick: () => void;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
sx?: BoxProps['sx'];
|
|
11
|
+
titleSx?: BoxProps['sx'];
|
|
12
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare function SelectAndInput({ errorMsg, isCustomized, onClick, value, onChange, }: {
|
|
3
|
+
errorMsg: string;
|
|
4
|
+
isCustomized: boolean;
|
|
5
|
+
onClick: () => void;
|
|
6
|
+
value: string;
|
|
7
|
+
onChange: (v: string) => void;
|
|
8
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { TokenInfo } from '../../../../../hooks/Token';
|
|
2
|
+
import { Version as PoolVersionE } from '../../types';
|
|
3
|
+
export declare const useCreatePoolSubmit: ({ selectedVersion, baseToken, quoteToken, baseAmount, quoteAmount, feeRate, initPrice, slippageCoefficient, }: {
|
|
4
|
+
selectedVersion: PoolVersionE;
|
|
5
|
+
baseToken: TokenInfo | null;
|
|
6
|
+
quoteToken: TokenInfo | null;
|
|
7
|
+
baseAmount: string;
|
|
8
|
+
quoteAmount: string;
|
|
9
|
+
feeRate: string;
|
|
10
|
+
initPrice: string;
|
|
11
|
+
slippageCoefficient: string;
|
|
12
|
+
}) => {
|
|
13
|
+
getCreateParams: () => Promise<any>;
|
|
14
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Version } from '../types';
|
|
2
|
+
export declare enum PoolTemplate {
|
|
3
|
+
standard = 1,
|
|
4
|
+
singleToken = 2,
|
|
5
|
+
pagged = 3,
|
|
6
|
+
marketMaker = 4
|
|
7
|
+
}
|
|
8
|
+
export declare const useCreatePmm: ({ selectedVersion, baseAmount, quoteAmount, initPrice, slippageCoefficient, }: {
|
|
9
|
+
selectedVersion: Version;
|
|
10
|
+
baseAmount?: string | undefined;
|
|
11
|
+
quoteAmount?: string | undefined;
|
|
12
|
+
initPrice: string;
|
|
13
|
+
slippageCoefficient: string;
|
|
14
|
+
}) => {
|
|
15
|
+
pmmParams: {
|
|
16
|
+
i: number;
|
|
17
|
+
k: number;
|
|
18
|
+
b: number;
|
|
19
|
+
b0: number;
|
|
20
|
+
q: number;
|
|
21
|
+
q0: number;
|
|
22
|
+
R: number;
|
|
23
|
+
} | undefined;
|
|
24
|
+
pmmModel: import("@dodoex/api").PMMModel | undefined;
|
|
25
|
+
midPrice: import("bignumber.js").BigNumber | undefined;
|
|
26
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { RadioButtonT } from '../types';
|
|
2
|
+
export declare const getFeeRateList: () => ({
|
|
3
|
+
title: string;
|
|
4
|
+
description: string;
|
|
5
|
+
value: string;
|
|
6
|
+
tag?: undefined;
|
|
7
|
+
} | {
|
|
8
|
+
title: string;
|
|
9
|
+
description: string;
|
|
10
|
+
value: string;
|
|
11
|
+
tag: string;
|
|
12
|
+
})[];
|
|
13
|
+
export declare function useFeeRateList(): RadioButtonT[];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { RadioButtonT } from '../types';
|
|
2
|
+
import { StateProps } from '../reducer';
|
|
3
|
+
export declare const getDefaultSlippageCoefficientList: ({ selectedVersion, }: {
|
|
4
|
+
selectedVersion: StateProps['selectedVersion'];
|
|
5
|
+
}) => string[];
|
|
6
|
+
export declare function useSlippageCoefficientList({ selectedVersion, }: {
|
|
7
|
+
selectedVersion: StateProps['selectedVersion'];
|
|
8
|
+
}): RadioButtonT[];
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Version } from '../types';
|
|
2
|
+
export declare const validFeeRate: (feeRateStr?: string) => string;
|
|
3
|
+
export declare const validSlippageCoefficient: (slippageCoefficientStr: string, selectedVersion: Version) => string;
|
|
4
|
+
export declare function validInitPrice(selectedVersion: Version, initPrice: string, quoteTokenDecimals: number): string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Dispatch } from 'react';
|
|
2
|
+
import { Actions, StateProps } from '../reducer';
|
|
3
|
+
export declare function FeeRateSetting({ dispatch, feeRate, isFeeRateCustomized: isCustomized, }: {
|
|
4
|
+
dispatch: Dispatch<Actions>;
|
|
5
|
+
feeRate: StateProps['feeRate'];
|
|
6
|
+
isFeeRateCustomized: StateProps['isFeeRateCustomized'];
|
|
7
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Dispatch } from 'react';
|
|
2
|
+
import { Actions, StateProps } from '../reducer';
|
|
3
|
+
export declare function InitPriceSetting({ isEdit, selectedVersion, isFixedRatio, leftTokenAddress, baseToken, quoteToken, fixedRatioPrice, dispatch, }: {
|
|
4
|
+
isEdit?: boolean;
|
|
5
|
+
selectedVersion: StateProps['selectedVersion'];
|
|
6
|
+
isFixedRatio: StateProps['isFixedRatio'];
|
|
7
|
+
leftTokenAddress: StateProps['leftTokenAddress'];
|
|
8
|
+
baseToken: StateProps['baseToken'];
|
|
9
|
+
quoteToken: StateProps['quoteToken'];
|
|
10
|
+
fixedRatioPrice: StateProps['fixedRatioPrice'];
|
|
11
|
+
dispatch: Dispatch<Actions>;
|
|
12
|
+
}): JSX.Element;
|
package/dist/src/widgets/PoolWidget/PoolCreate/operate-widgets/SlippageCoefficientSetting.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Dispatch } from 'react';
|
|
2
|
+
import { Actions, StateProps } from '../reducer';
|
|
3
|
+
export declare function SlippageCoefficientSetting({ dispatch, slippageCoefficient, selectedVersion, isCustomized, }: {
|
|
4
|
+
dispatch: Dispatch<Actions>;
|
|
5
|
+
slippageCoefficient: StateProps['slippageCoefficient'];
|
|
6
|
+
selectedVersion: StateProps['selectedVersion'];
|
|
7
|
+
isCustomized: StateProps['isSlippageCoefficientCustomized'];
|
|
8
|
+
}): JSX.Element;
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { Version } from './types';
|
|
2
|
+
import { TokenInfo } from '../../../hooks/Token';
|
|
3
|
+
export interface StateProps {
|
|
4
|
+
currentStep: 0 | 1 | 2;
|
|
5
|
+
selectedVersion: Version;
|
|
6
|
+
baseToken: TokenInfo | null;
|
|
7
|
+
quoteToken: TokenInfo | null;
|
|
8
|
+
baseAmount: string;
|
|
9
|
+
quoteAmount: string;
|
|
10
|
+
/**
|
|
11
|
+
* Whether to fix the exchange rate fixedRatioPrice to the current legal currency price, true means no modification is allowed
|
|
12
|
+
* single-token is not fixed by default and cannot be fixed, and can be modified
|
|
13
|
+
* After fixing, when modifying the quantity, standard needs to keep the ratio of baseAmount, quoteAmount, fixedRatioPrice unchanged. Pegged needs to be linked regardless of whether it is fixed or not. dpp does not need to, and the three can be modified independently.
|
|
14
|
+
*/
|
|
15
|
+
isFixedRatio: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* PmmState.i
|
|
18
|
+
* The value of standard pool is always DEFAULT_INIT_PRICE_STANDARD
|
|
19
|
+
* Other types can be modified, the initial value is DEFAULT_INIT_PRICE
|
|
20
|
+
* The value of this field for single-token, pegged and dpp types is synchronized with fixedRatioPrice
|
|
21
|
+
*/
|
|
22
|
+
initPrice: string;
|
|
23
|
+
/**
|
|
24
|
+
* Exchange rate, price, exchange ratio, price ratio
|
|
25
|
+
* Except for single-token types, use the initial fiat price to initialize this field
|
|
26
|
+
* single-token defaults to empty, others default to 1
|
|
27
|
+
*/
|
|
28
|
+
fixedRatioPrice: string;
|
|
29
|
+
/** The token on the left side of the exchange rate input box */
|
|
30
|
+
leftTokenAddress: TokenInfo['address'] | undefined;
|
|
31
|
+
slippageCoefficient: string;
|
|
32
|
+
isSlippageCoefficientCustomized: boolean;
|
|
33
|
+
feeRate: string | '0.01' | '0.3' | '1';
|
|
34
|
+
isFeeRateCustomized: boolean;
|
|
35
|
+
}
|
|
36
|
+
declare type Pool = any;
|
|
37
|
+
export declare enum Types {
|
|
38
|
+
SetCurrentStep = 1,
|
|
39
|
+
SelectNewVersion = 2,
|
|
40
|
+
UpdateBaseToken = 3,
|
|
41
|
+
UpdateQuoteToken = 4,
|
|
42
|
+
SwitchTokens = 5,
|
|
43
|
+
UpdateBaseAmount = 6,
|
|
44
|
+
UpdateQuoteAmount = 7,
|
|
45
|
+
UpdateIsFixedRatio = 8,
|
|
46
|
+
UpdateFixedRatioPrice = 9,
|
|
47
|
+
InitFixedRatioPrice = 10,
|
|
48
|
+
ToggleLeftToken = 11,
|
|
49
|
+
UpdateSlippageCoefficient = 12,
|
|
50
|
+
UpdateIsSlippageCoefficientCustomized = 13,
|
|
51
|
+
UpdateFeeRate = 14,
|
|
52
|
+
UpdateIsFeeRateCustomized = 15,
|
|
53
|
+
InitEditParameters = 16
|
|
54
|
+
}
|
|
55
|
+
declare type Payload = {
|
|
56
|
+
[Types.SetCurrentStep]: StateProps['currentStep'];
|
|
57
|
+
[Types.SelectNewVersion]: Version;
|
|
58
|
+
[Types.UpdateBaseToken]: TokenInfo;
|
|
59
|
+
[Types.UpdateQuoteToken]: TokenInfo;
|
|
60
|
+
[Types.SwitchTokens]: undefined;
|
|
61
|
+
[Types.UpdateBaseAmount]: string;
|
|
62
|
+
[Types.UpdateQuoteAmount]: string;
|
|
63
|
+
[Types.UpdateIsFixedRatio]: boolean;
|
|
64
|
+
[Types.UpdateFixedRatioPrice]: string;
|
|
65
|
+
[Types.InitFixedRatioPrice]: {
|
|
66
|
+
baseTokenFiatPrice: number | undefined;
|
|
67
|
+
quoteTokenFiatPrice: number | undefined;
|
|
68
|
+
};
|
|
69
|
+
[Types.ToggleLeftToken]: undefined;
|
|
70
|
+
[Types.UpdateSlippageCoefficient]: string;
|
|
71
|
+
[Types.UpdateIsSlippageCoefficientCustomized]: boolean;
|
|
72
|
+
[Types.UpdateFeeRate]: StateProps['feeRate'];
|
|
73
|
+
[Types.UpdateIsFeeRateCustomized]: boolean;
|
|
74
|
+
[Types.InitEditParameters]: Pool;
|
|
75
|
+
};
|
|
76
|
+
export declare type Actions = ActionMap<Payload>[keyof ActionMap<Payload>];
|
|
77
|
+
export declare function reducer(state: StateProps, action: Actions): StateProps;
|
|
78
|
+
export {};
|