From 9591c7b3f3b5072cdb79cc51a2aa935523aae540 Mon Sep 17 00:00:00 2001 From: Ted Palmer Date: Mon, 11 Nov 2024 09:39:29 -0500 Subject: [PATCH 1/2] Remove route selector from single chain mode --- .../ui/src/components/widgets/SwapWidget/index.tsx | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/packages/ui/src/components/widgets/SwapWidget/index.tsx b/packages/ui/src/components/widgets/SwapWidget/index.tsx index b825e316..6fe506f0 100644 --- a/packages/ui/src/components/widgets/SwapWidget/index.tsx +++ b/packages/ui/src/components/widgets/SwapWidget/index.tsx @@ -240,7 +240,8 @@ const SwapWidget: FC = ({ const promptSwitchRoute = (isCapacityExceededError || isCouldNotExecuteError) && - supportsExternalLiquidity + supportsExternalLiquidity && + !isSingleChainLocked return ( = ({ tradeType === 'EXACT_INPUT' ? amountInputValue : amountInputValue - ? formatFixedLength(amountInputValue, 8) - : amountInputValue + ? formatFixedLength(amountInputValue, 8) + : amountInputValue } setValue={(e) => { setAmountInputValue(e) @@ -671,8 +672,8 @@ const SwapWidget: FC = ({ tradeType === 'EXPECTED_OUTPUT' ? amountOutputValue : amountOutputValue - ? formatFixedLength(amountOutputValue, 8) - : amountOutputValue + ? formatFixedLength(amountOutputValue, 8) + : amountOutputValue } setValue={(e) => { setAmountOutputValue(e) @@ -836,7 +837,7 @@ const SwapWidget: FC = ({ - {error && !isFetchingPrice ? ( + {error && !isFetchingPrice && !isSingleChainLocked ? ( Date: Mon, 11 Nov 2024 09:39:49 -0500 Subject: [PATCH 2/2] feat: changeset --- .changeset/angry-penguins-kneel.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/angry-penguins-kneel.md diff --git a/.changeset/angry-penguins-kneel.md b/.changeset/angry-penguins-kneel.md new file mode 100644 index 00000000..ecdd9447 --- /dev/null +++ b/.changeset/angry-penguins-kneel.md @@ -0,0 +1,5 @@ +--- +'@reservoir0x/relay-kit-ui': patch +--- + +Remove route selector from single chain mode