Skip to content

Commit

Permalink
Minor fixes on Steppers component styles
Browse files Browse the repository at this point in the history
  • Loading branch information
hervedombya committed Dec 13, 2023
1 parent 71dcdb6 commit 97cd36a
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/lib/components/steppers/Steppers.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,18 @@ const Circle = styled.div`
`;
} else {
return css`
background-color: ${defaultTheme.gray};
background-color: ${getThemePropSelector('buttonSecondary')};
color: ${defaultTheme.white};
`;
}
}};
`;
const StepHeader = styled.span`
padding: 8px;
color: ${getThemePropSelector('textPrimary')};
color: ${(props) =>
props.active
? getThemePropSelector('textPrimary')
: getThemePropSelector('textSecondary')};
`;
const StepContent = styled.div`
padding: ${defaultTheme.padding.small};
Expand All @@ -76,7 +79,7 @@ const BottomBar = styled.hr`
flex-grow: 1;
margin: 0;
border: none;
margin: 2px 14px;
margin: 4px 14px;
${(props) => {
if (props.completed) {
Expand All @@ -103,6 +106,7 @@ function Step(props: StepProps) {
inProgress,
} = props;
const circleContent = completed ? <Icon name="Check" /> : index + 1;

return (
<StepContainer>
<Panel>
Expand All @@ -116,7 +120,9 @@ function Step(props: StepProps) {
{!isLast && <BottomBar completed={completed} />}
</Panel>
<Panel>
<StepHeader completed={completed}>{title}</StepHeader>
<StepHeader completed={completed} active={active}>
{title}
</StepHeader>
{active && <StepContent>{content}</StepContent>}
</Panel>
</StepContainer>
Expand Down

0 comments on commit 97cd36a

Please sign in to comment.