1
0
mirror of https://github.com/oceanprotocol/market.git synced 2024-12-02 05:57:29 +01:00

add preview success condition

This commit is contained in:
Matthias Kretschmann 2021-11-26 10:17:50 +00:00
parent dcb8a0c6c6
commit 11412c2d66
Signed by: m
GPG Key ID: 606EEEF3C479A91F
2 changed files with 3 additions and 2 deletions

View File

@ -90,4 +90,5 @@
.success.current:before {
background: var(--font-color-heading);
border-color: var(--brand-alert-green);
}

View File

@ -21,7 +21,8 @@ export default function Navigation(): ReactElement {
const isSuccessServices = errors.services === undefined
const isSuccessPricing =
errors.pricing === undefined && touched.pricing?.price
const isSuccessPreview = false
const isSuccessPreview =
isSuccessMetadata && isSuccessServices && isSuccessPricing
const isSuccess =
(step === 1 && isSuccessMetadata) ||
@ -38,7 +39,6 @@ export default function Navigation(): ReactElement {
<li
key={step.title}
onClick={() => handleStepClick(step.step)}
// TODO: add success class for all steps
className={`${
values.user.stepCurrent === step.step ? styles.current : null
} ${getSuccessClass(step.step)}`}