master
Tudor Stanciu 2020-12-19 01:33:06 +02:00
parent 0409ab947e
commit 43ca37649c
2 changed files with 5 additions and 7 deletions

View File

@ -10,7 +10,7 @@ import {
} from "@material-ui/core"; } from "@material-ui/core";
import { useLocation, useHistory } from "react-router-dom"; import { useLocation, useHistory } from "react-router-dom";
import CustomStepConnector from "./CustomStepConnector"; import CustomStepConnector from "./CustomStepConnector";
import ColorlibStepIcon from "./ColorlibStepIcon"; import StepIcon from "./StepIcon";
const styles = () => ({ const styles = () => ({
stepperCard: { stepperCard: {
@ -56,9 +56,7 @@ const ApplicationStepper = () => {
disabled={step.disabled} disabled={step.disabled}
onClick={() => handleStepClick(step)} onClick={() => handleStepClick(step)}
> >
<StepLabel StepIconComponent={ColorlibStepIcon}> <StepLabel StepIconComponent={StepIcon}>{step.title}</StepLabel>
{step.title}
</StepLabel>
</StepButton> </StepButton>
</Step> </Step>
))} ))}

View File

@ -29,7 +29,7 @@ const useColorlibStepIconStyles = makeStyles({
} }
}); });
function ColorlibStepIcon(props) { function StepIcon(props) {
const classes = useColorlibStepIconStyles(); const classes = useColorlibStepIconStyles();
const { active, completed } = props; const { active, completed } = props;
@ -55,7 +55,7 @@ function ColorlibStepIcon(props) {
); );
} }
ColorlibStepIcon.propTypes = { StepIcon.propTypes = {
/** /**
* Whether this step is active. * Whether this step is active.
*/ */
@ -70,4 +70,4 @@ ColorlibStepIcon.propTypes = {
icon: PropTypes.node icon: PropTypes.node
}; };
export default ColorlibStepIcon; export default StepIcon;