From d8bc0cdedac964a431d21431403f9fc0118fa5ea Mon Sep 17 00:00:00 2001 From: Barry Gitarts Date: Thu, 29 Aug 2019 11:55:33 -0400 Subject: [PATCH] add enableEthereum catch --- src/components/projects/FundProject.jsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/components/projects/FundProject.jsx b/src/components/projects/FundProject.jsx index d79f77d..cb175b7 100644 --- a/src/components/projects/FundProject.jsx +++ b/src/components/projects/FundProject.jsx @@ -80,13 +80,14 @@ const SubmissionSection = ({ classes, projectData, projectId, profileData, start const createdDate = getDateCreated(projectAge) const percentToGoal = manifest ? formatPercent(Number(totalPledged) / Number(manifest.goal)) : formatPercent(0) const isCreator = projectData.creator === account - const buttonText = account ? 'Fund' : 'Connect & Fund' return ( { + const activeStep = stepperProgress(values, projectData, submissionState) + if (!activeStep) return enableEthereum() const { amount } = values const { goalToken } = manifest const { chainReadibleFn } = getTokenByAddress(goalToken) @@ -127,7 +128,6 @@ const SubmissionSection = ({ classes, projectData, projectId, profileData, start handleChange, handleBlur, handleSubmit, - isSubmitting }) => { const { firstHalf, secondHalf, fullWidth } = classes const usdValue = manifest ? convertTokenAmountUsd(manifest.goalToken, values.amount, prices) : 0 @@ -188,7 +188,7 @@ const SubmissionSection = ({ classes, projectData, projectId, profileData, start {`${totalPledged ? convertTokenAmountUsd(manifest.goalToken, totalPledged, prices) : '$0'} of ${convertTokenAmountUsd(manifest.goalToken, manifest.goal, prices)} USD`} -
+ {!!activeStep &&
{getTokenLabel(manifest.goalToken)}
-
- +
} + }