import { useEffect, useState } from 'react'; import { EmptyState, EmptyStateFooter, EmptyStateBody, EmptyStateActions, Progress, Button } from '@patternfly/react-core'; import { Wizard as WizardDeprecated } from '@patternfly/react-core/deprecated'; // eslint-disable-next-line patternfly-react/import-tokens-icons import { CogsIcon } from '@patternfly/react-icons'; import layout from '@patternfly/react-styles/css/layouts/Bullseye/bullseye'; interface finishedProps { onClose: () => void; } const FinishedStep: React.FunctionComponent = (props: finishedProps) => { const [percent, setPercent] = useState(0); const tick = () => { setPercent((prevPercent) => { if (prevPercent < 100) { return prevPercent + 20; } else { return prevPercent; } }); }; useEffect(() => { const interval = setInterval(() => tick(), 1000); if (percent >= 100) { clearInterval(interval); } return () => clearInterval(interval); }, [percent]); return (
Description can be used to further elaborate on the validation step, or give the user a better idea of how long the process will take.
); }; export const WizardFinished: React.FunctionComponent = () => { const closeWizard = () => { // eslint-disable-next-line no-console console.log('close wizard'); }; const steps = [ { name: 'First step', component:

Step 1 content

}, { name: 'Second step', component:

Step 2 content

}, { name: 'Third step', component:

Step 3 content

}, { name: 'Fourth step', component:

Step 4 content

}, { name: 'Review', component:

Review step content

, nextButtonText: 'Finish' }, { name: 'Finish', component: , isFinishedStep: true } ]; const title = 'Finished wizard example'; return ( ); };