Skip to content

Commit

Permalink
refactor: Change method name format.
Browse files Browse the repository at this point in the history
  • Loading branch information
mheggelund committed Feb 27, 2024
1 parent f93e988 commit 380a0e8
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
13 changes: 12 additions & 1 deletion src/components/CaseCardComponent/CaseCardComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,23 @@ export const CaseCardComponent = ({
localList?: ComputeCaseDto[];
addCase?: (methodType: string) => void;
}) => {
const formattedTitle = () => {
let res = '';
if (title === 'Indicator') {
res = 'Indicator';
} else if (title === 'Net-To-Gross') {
res = 'Net-to-gross';
} else if (title === 'ContiniousParameter') {
res = 'Continious parameter';
}
return res;
};
return (
<Styled.CaseBorder>
<Styled.Wrapper>
<Styled.ButtonGroup>
<Styled.Title>
<Typography variant="h4">{title}</Typography>
<Typography variant="h4">{formattedTitle()}</Typography>
<Typography variant="h6">{subTitle}</Typography>
</Styled.Title>
<AddCaseButtons
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ export const ComputeVariogram = () => {
}
>
<Icon data={ADD} size={18}></Icon>
Net-To-Gross
Net-to-gross
</Button>
<Button
variant="outlined"
Expand All @@ -128,7 +128,7 @@ export const ComputeVariogram = () => {
}
>
<Icon data={ADD} size={18}></Icon>
ContiniousParameter
Continious parameter
</Button>
</Styled.ButtonGroup>
<Styled.ButtonGroup>
Expand Down

0 comments on commit 380a0e8

Please sign in to comment.