mirror of
https://github.com/elyby/accounts-frontend.git
synced 2025-05-31 14:11:58 +05:30
Create app namespace for all absolute requires of app modules. Move all packages under packages yarn workspace
This commit is contained in:
28
packages/app/components/ui/stepper/Stepper.tsx
Normal file
28
packages/app/components/ui/stepper/Stepper.tsx
Normal file
@@ -0,0 +1,28 @@
|
||||
import React from 'react';
|
||||
import classNames from 'classnames';
|
||||
import { Color, COLOR_GREEN } from 'app/components/ui';
|
||||
|
||||
import styles from './stepper.scss';
|
||||
|
||||
export default function Stepper({
|
||||
totalSteps,
|
||||
activeStep,
|
||||
color = COLOR_GREEN,
|
||||
}: {
|
||||
totalSteps: number;
|
||||
activeStep: number;
|
||||
color?: Color;
|
||||
}) {
|
||||
return (
|
||||
<div className={classNames(styles.steps, styles[`${color}Steps`])}>
|
||||
{new Array(totalSteps).fill(0).map((_, step) => (
|
||||
<div
|
||||
className={classNames(styles.step, {
|
||||
[styles.activeStep]: step <= activeStep,
|
||||
})}
|
||||
key={step}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user