Skip to content

Commit 0d0a60e

Browse files
committed
feat: styling according to figma
1 parent 8e5b49d commit 0d0a60e

File tree

3 files changed

+16
-22
lines changed

3 files changed

+16
-22
lines changed

web/src/components/ExtraStatsDisplay.tsx

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ import { StyledSkeleton } from "components/StyledSkeleton";
55

66
const Container = styled.div`
77
display: flex;
8-
max-width: 380px;
9-
align-items: center;
108
gap: 8px;
9+
align-items: center;
10+
margin-top: 24px;
1111
`;
1212

1313
const SVGContainer = styled.div`
14+
display: flex;
1415
height: 14px;
1516
width: 14px;
16-
display: flex;
1717
align-items: center;
1818
justify-content: center;
1919
svg {
@@ -24,10 +24,14 @@ const SVGContainer = styled.div`
2424
const TextContainer = styled.div`
2525
display: flex;
2626
align-items: center;
27-
gap: 4px;
28-
p {
29-
min-width: 60px;
30-
}
27+
gap: 8px;
28+
flex-wrap: wrap;
29+
`;
30+
31+
const StyledP = styled.p`
32+
font-size: 14px;
33+
font-weight: 600;
34+
margin: 0;
3135
`;
3236

3337
export interface IExtraStatsDisplay {
@@ -42,7 +46,7 @@ const ExtraStatsDisplay: React.FC<IExtraStatsDisplay> = ({ title, text, icon: Ic
4246
<SVGContainer>{<Icon />}</SVGContainer>
4347
<TextContainer>
4448
<label>{title}:</label>
45-
<p>{text !== null ? text : <StyledSkeleton />}</p>
49+
<StyledP>{text !== null ? text : <StyledSkeleton />}</StyledP>
4650
</TextContainer>
4751
</Container>
4852
);

web/src/pages/Home/CourtOverview/ExtraStats.tsx

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,18 @@
11
import React from "react";
2-
import styled, { css } from "styled-components";
2+
import styled from "styled-components";
33

44
import LawBalance from "svgs/icons/law-balance.svg";
55
import LongArrowUp from "svgs/icons/long-arrow-up.svg";
66

77
import { useHomePageExtraStats, HomePageExtraStatsType } from "hooks/queries/useHomePageExtraStats";
88

9-
import { landscapeStyle } from "styles/landscapeStyle";
10-
import { responsiveSize } from "styles/responsiveSize";
11-
129
import ExtraStatsDisplay from "components/ExtraStatsDisplay";
1310

1411
const StyledCard = styled.div`
15-
padding-left: ${responsiveSize(16, 64)};
16-
padding-right: ${responsiveSize(16, 64)};
1712
display: flex;
18-
justify-content: space-between;
1913
flex-wrap: wrap;
20-
21-
${landscapeStyle(
22-
() => css`
23-
padding-bottom: 0px;
24-
gap: 8px;
25-
`
26-
)}
14+
gap: 0 32px;
15+
justify-content: center;
2716
`;
2817

2918
interface IStat {

web/src/pages/Home/CourtOverview/Header.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { responsiveSize } from "styles/responsiveSize";
1111

1212
const StyledHeader = styled.div`
1313
display: flex;
14+
flex-wrap: wrap;
1415
justify-content: space-between;
1516
`;
1617

0 commit comments

Comments
 (0)