From 4ced747e8dffdf577e349766162af1fd3e51ef1d Mon Sep 17 00:00:00 2001 From: Bill He Date: Mon, 29 Jan 2024 14:56:48 -0800 Subject: [PATCH] Address feedback --- src/components/TimeoutButton.tsx | 6 +++--- .../AccountManagementForms/DepositForm.tsx | 2 +- .../SourceSelectMenu.tsx | 17 ++++++++-------- .../AccountManagementForms/WithdrawForm.tsx | 2 +- src/views/forms/NobleDeposit.tsx | 20 ++++++++++++------- 5 files changed, 27 insertions(+), 20 deletions(-) diff --git a/src/components/TimeoutButton.tsx b/src/components/TimeoutButton.tsx index d18b568..4e0c4e6 100644 --- a/src/components/TimeoutButton.tsx +++ b/src/components/TimeoutButton.tsx @@ -8,7 +8,7 @@ import { Button, type ButtonStateConfig, type ButtonProps } from '@/components/B type ElementProps = { timeoutInSeconds: number; - finalSlot?: ReactNode; + slotFinal?: ReactNode; } & ButtonProps; export type TimeoutButtonProps = ElementProps; @@ -16,7 +16,7 @@ export type TimeoutButtonProps = ElementProps; export const TimeoutButton = ({ children, timeoutInSeconds, - finalSlot, + slotFinal, ...otherProps }: TimeoutButtonProps) => { const [timeoutDeadline] = useState(Date.now() + timeoutInSeconds * 1000); @@ -25,7 +25,7 @@ export const TimeoutButton = ({ const secondsLeft = Math.max(0, (timeoutDeadline - now) / 1000); - if (finalSlot && secondsLeft <= 0) return finalSlot; + if (slotFinal && secondsLeft <= 0) return slotFinal; return (