From 6378ec653851fe03a3c275a22b4da52e0b809798 Mon Sep 17 00:00:00 2001 From: JellyWang <38491708+ezailWang@users.noreply.github.com> Date: Thu, 5 Sep 2024 10:38:28 +0800 Subject: [PATCH] Fix/swap some bugs fix (#5721) --- packages/kit-bg/src/services/ServiceSwap.ts | 1 + .../src/components/TokenListItem/index.tsx | 17 ++++++--- .../Swap/components/SwapPopularTokenGroup.tsx | 6 ++-- .../kit/src/views/Swap/hooks/useSwapQuote.ts | 2 -- .../Swap/pages/components/SwapQuoteResult.tsx | 11 ++++-- .../Swap/pages/modal/SwapTokenSelectModal.tsx | 13 +++++-- .../types/swap/SwapProvider.constants.ts | 36 +++++++++++++++++++ 7 files changed, 72 insertions(+), 14 deletions(-) diff --git a/packages/kit-bg/src/services/ServiceSwap.ts b/packages/kit-bg/src/services/ServiceSwap.ts index 539753af7b4..a62b8e2d22c 100644 --- a/packages/kit-bg/src/services/ServiceSwap.ts +++ b/packages/kit-bg/src/services/ServiceSwap.ts @@ -392,6 +392,7 @@ export default class ServiceSwap extends ServiceBase { } @backgroundMethod() + @toastIfError() async fetchQuotesEvents({ fromToken, toToken, diff --git a/packages/kit/src/components/TokenListItem/index.tsx b/packages/kit/src/components/TokenListItem/index.tsx index 95abdd671b4..2b86719ca6e 100644 --- a/packages/kit/src/components/TokenListItem/index.tsx +++ b/packages/kit/src/components/TokenListItem/index.tsx @@ -37,9 +37,6 @@ export function TokenListItem({ return ( - + ( - + {tokens.map((token) => (