From 912ccefa6352d2143d266cc0b78481a321fa3002 Mon Sep 17 00:00:00 2001 From: Pedro Figueiredo Date: Thu, 5 Sep 2024 17:45:26 +0100 Subject: [PATCH] Address feedback --- .../approve-static-simulation.tsx | 4 +- .../approve/hooks/use-custom-spending-cap.ts | 7 --- .../revoke-static-simulation.tsx | 47 +++++++++++-------- 3 files changed, 30 insertions(+), 28 deletions(-) delete mode 100644 ui/pages/confirmations/components/confirm/info/approve/hooks/use-custom-spending-cap.ts diff --git a/ui/pages/confirmations/components/confirm/info/approve/approve-static-simulation/approve-static-simulation.tsx b/ui/pages/confirmations/components/confirm/info/approve/approve-static-simulation/approve-static-simulation.tsx index 8fd4c55e353a..c7a61eb89c71 100644 --- a/ui/pages/confirmations/components/confirm/info/approve/approve-static-simulation/approve-static-simulation.tsx +++ b/ui/pages/confirmations/components/confirm/info/approve/approve-static-simulation/approve-static-simulation.tsx @@ -65,7 +65,7 @@ export const ApproveStaticSimulation = () => { ); - const simulationElements = ( + const SpendingCapRow = ( @@ -93,6 +93,8 @@ export const ApproveStaticSimulation = () => { ); + const simulationElements = SpendingCapRow; + return ( { - const [customSpendingCap, setCustomSpendingCap] = useState(''); - - return { customSpendingCap, setCustomSpendingCap }; -}; diff --git a/ui/pages/confirmations/components/confirm/info/approve/revoke-static-simulation/revoke-static-simulation.tsx b/ui/pages/confirmations/components/confirm/info/approve/revoke-static-simulation/revoke-static-simulation.tsx index 5e51722a7479..199852538f17 100644 --- a/ui/pages/confirmations/components/confirm/info/approve/revoke-static-simulation/revoke-static-simulation.tsx +++ b/ui/pages/confirmations/components/confirm/info/approve/revoke-static-simulation/revoke-static-simulation.tsx @@ -16,29 +16,36 @@ export const RevokeStaticSimulation = () => { currentConfirmation: TransactionMeta; }; - const simulationElements = ( - <> - - - - - + const TokenContractRow = ( + + + + - + + + ); - - - - - + const SpenderRow = ( + + + + - + + + ); + + const simulationElements = ( + <> + {TokenContractRow} + {SpenderRow} );