From 67fbd024f1232840528f35b54068d4f20d2eb1c5 Mon Sep 17 00:00:00 2001 From: ingawei Date: Tue, 20 Sep 2022 23:51:20 -0700 Subject: [PATCH] fix button on right panel being disabled --- web/components/bet-panel.tsx | 1 + web/components/warning-confirmation-button.tsx | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/web/components/bet-panel.tsx b/web/components/bet-panel.tsx index 6721e232..98bcf1af 100644 --- a/web/components/bet-panel.tsx +++ b/web/components/bet-panel.tsx @@ -404,6 +404,7 @@ export function BuyPanel(props: { {user && ( void disabled?: boolean @@ -23,6 +24,7 @@ export function WarningConfirmationButton(props: { isSubmitting, openModalButtonClass, submitButtonClassName, + outcome, } = props if (!warning) { @@ -31,7 +33,7 @@ export function WarningConfirmationButton(props: { className={clsx( openModalButtonClass, isSubmitting ? 'loading' : '', - disabled && 'btn-disabled' + (disabled || !outcome) && 'btn-disabled bg-greyscale-2' )} onClick={onSubmit} >