Files
mue/src/components/modals/welcome/ProgressBar.jsx
David Ralph 361fae7f25 feat: add work in progress 7.0 code
Co-authored-by: Alex Sparkes <turbomarshmello@gmail.com>
2022-04-08 14:48:36 +01:00

17 lines
423 B
JavaScript

export default function ProgressBar({ count, currentTab, switchTab }) {
return (
<div className="progressbar">
{count.map((num) => {
let className = 'step';
const index = count.indexOf(num);
if (index === currentTab) {
className = 'step active';
}
return <div className={className} key={index} onClick={() => switchTab(index)} />;
})}
</div>
);
}