From e20c0ceaa2529d8961c019ac67ecfce2c5bea19d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CF=87=C2=B2?= <88190723+ChiTimesChi@users.noreply.github.com> Date: Thu, 16 Jan 2025 17:01:30 +0000 Subject: [PATCH 1/2] fix(synapse-interface): remove RFQ output amount check (#3491) --- .../StateManagedBridge/BridgeTransactionButton.tsx | 11 ----------- .../StateManagedBridge/hooks/useBridgeValidations.ts | 12 ------------ 2 files changed, 23 deletions(-) diff --git a/packages/synapse-interface/components/StateManagedBridge/BridgeTransactionButton.tsx b/packages/synapse-interface/components/StateManagedBridge/BridgeTransactionButton.tsx index d1621313a4..e5837338c0 100644 --- a/packages/synapse-interface/components/StateManagedBridge/BridgeTransactionButton.tsx +++ b/packages/synapse-interface/components/StateManagedBridge/BridgeTransactionButton.tsx @@ -72,7 +72,6 @@ export const BridgeTransactionButton = ({ hasSufficientBalance, doesBridgeStateMatchQuote, isBridgeFeeGreaterThanInput, - isBridgeQuoteAmountGreaterThanInputForRfq, onSelectedChain, } = useBridgeValidations() @@ -83,7 +82,6 @@ export const BridgeTransactionButton = ({ isWalletPending || !hasValidInput || !doesBridgeStateMatchQuote || - isBridgeQuoteAmountGreaterThanInputForRfq || (isConnected && !hasValidQuote) || (isConnected && !hasSufficientBalance) || (isConnected && isQuoteStale) || @@ -175,15 +173,6 @@ export const BridgeTransactionButton = ({ destinationTokenAddressForState: toToken.addresses[toChainId], bridgeQuote, }) - } else if ( - !isLoading && - isBridgeQuoteAmountGreaterThanInputForRfq && - hasValidInput - ) { - buttonProperties = { - label: t('Invalid bridge quote'), - onClick: null, - } } else if (destinationAddress && !isAddress(destinationAddress)) { buttonProperties = { label: t('Invalid Destination address'), diff --git a/packages/synapse-interface/components/StateManagedBridge/hooks/useBridgeValidations.ts b/packages/synapse-interface/components/StateManagedBridge/hooks/useBridgeValidations.ts index 58084cf65b..1dabc31e4d 100644 --- a/packages/synapse-interface/components/StateManagedBridge/hooks/useBridgeValidations.ts +++ b/packages/synapse-interface/components/StateManagedBridge/hooks/useBridgeValidations.ts @@ -76,17 +76,6 @@ export const useBridgeValidations = () => { return stringifiedBridgeQuote === stringifiedBridgeState }, [stringifiedBridgeQuote, stringifiedBridgeState]) - const isBridgeQuoteAmountGreaterThanInputForRfq = useMemo(() => { - return ( - bridgeQuote.bridgeModuleName === 'SynapseRFQ' && - bridgeQuote.outputAmount > debouncedFromValueBigInt - ) - }, [ - bridgeQuote.outputAmount, - bridgeQuote.bridgeModuleName, - debouncedFromValueBigInt, - ]) - const isBridgeFeeGreaterThanInput = useMemo(() => { return ( bridgeQuote.bridgeModuleName !== null && @@ -107,7 +96,6 @@ export const useBridgeValidations = () => { hasSufficientBalance, doesBridgeStateMatchQuote, isBridgeFeeGreaterThanInput, - isBridgeQuoteAmountGreaterThanInputForRfq, onSelectedChain, } } From e80f36ee62f32dae5b19a2acf8c9dc8b0b1bab56 Mon Sep 17 00:00:00 2001 From: ChiTimesChi Date: Thu, 16 Jan 2025 17:05:59 +0000 Subject: [PATCH 2/2] Publish - @synapsecns/synapse-interface@0.41.6 --- packages/synapse-interface/CHANGELOG.md | 11 +++++++++++ packages/synapse-interface/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/synapse-interface/CHANGELOG.md b/packages/synapse-interface/CHANGELOG.md index bf009866d4..73a7047973 100644 --- a/packages/synapse-interface/CHANGELOG.md +++ b/packages/synapse-interface/CHANGELOG.md @@ -3,6 +3,17 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [0.41.6](https://github.com/synapsecns/sanguine/compare/@synapsecns/synapse-interface@0.41.5...@synapsecns/synapse-interface@0.41.6) (2025-01-16) + + +### Bug Fixes + +* **synapse-interface:** remove RFQ output amount check ([#3491](https://github.com/synapsecns/sanguine/issues/3491)) ([e20c0ce](https://github.com/synapsecns/sanguine/commit/e20c0ceaa2529d8961c019ac67ecfce2c5bea19d)) + + + + + ## [0.41.5](https://github.com/synapsecns/sanguine/compare/@synapsecns/synapse-interface@0.41.4...@synapsecns/synapse-interface@0.41.5) (2025-01-13) **Note:** Version bump only for package @synapsecns/synapse-interface diff --git a/packages/synapse-interface/package.json b/packages/synapse-interface/package.json index fa8af0ac84..4f686536ff 100644 --- a/packages/synapse-interface/package.json +++ b/packages/synapse-interface/package.json @@ -1,6 +1,6 @@ { "name": "@synapsecns/synapse-interface", - "version": "0.41.5", + "version": "0.41.6", "private": true, "engines": { "node": ">=18.18.0"