diff --git a/src/component/OracleSuggestor.tsx b/src/component/OracleSuggestor.tsx index f029d7f..d5b39cc 100644 --- a/src/component/OracleSuggestor.tsx +++ b/src/component/OracleSuggestor.tsx @@ -207,6 +207,16 @@ const OracleSuggestor = () => { return `${baseUrl}${address}`; }; + const handleNetworkChange = (selectedOption: any) => { + setSelectedNetwork(selectedOption || networkOptions[0]); + // Reset collateral and loan asset states + setCollateralAsset(""); + setLoanAsset(""); + setCollateralAssetTouched(false); + setLoanAssetTouched(false); + setShowOracleDetails(false); // Hide oracle details when network changes + }; + return (
- Feed Information: -
-- Base Vault:{" "} - {oracleItem.oracle.data.baseVault} -
-- Quote Vault:{" "} - {oracleItem.oracle.data.quoteVault} -
-- Base Vault Conversion Sample:{" "} - {oracleItem.oracle.data.baseVaultConversionSample} -
-- Quote Vault Conversion Sample:{" "} - {oracleItem.oracle.data.quoteVaultConversionSample} + {oracleItem.oracle.data ? ( + <> +
+ Feed Information: +
++ Base Vault:{" "} + {oracleItem.oracle.data.baseVault} +
++ Quote Vault:{" "} + {oracleItem.oracle.data.quoteVault} +
++ Base Vault Conversion Sample:{" "} + {oracleItem.oracle.data.baseVaultConversionSample} +
++ Quote Vault Conversion Sample:{" "} + {oracleItem.oracle.data.quoteVaultConversionSample} +
++ No info is provided on this oracle. Do not use it!
-