Skip to content

Commit 25dce8a

Browse files
authoredJan 27, 2025··
Merge pull request #1849 from kleros/refactor(frontend)/header-styling
Refactor: header styling and reactmarkdown
2 parents 47e2cd6 + b5a85e6 commit 25dce8a

File tree

2 files changed

+18
-12
lines changed

2 files changed

+18
-12
lines changed
 

‎web/src/pages/Courts/CourtDetails/Description.tsx

+12-8
Original file line numberDiff line numberDiff line change
@@ -17,32 +17,36 @@ const Container = styled.div`
1717
const TextContainer = styled.div`
1818
width: 100%;
1919
padding: 12px 0;
20+
`;
2021

22+
const StyledReactMarkdown = styled(ReactMarkdown)`
2123
p {
2224
word-break: break-word;
2325
}
2426
25-
li {
26-
line-height: 1.5em;
27-
margin-top: 0.5em;
27+
ul,
28+
ol {
29+
li + li {
30+
margin-top: 8px;
31+
}
2832
}
2933
3034
h1 {
3135
margin: 16px 0 16px 0;
32-
font-size: 24px;
33-
line-height: 32px;
36+
font-size: 20px;
37+
line-height: 26px;
3438
}
3539
3640
h2 {
3741
margin: 16px 0 16px 0;
3842
font-size: 20px;
39-
line-height: 24px;
43+
line-height: 26px;
4044
}
4145
4246
h3 {
4347
margin: 16px 0 16px 0;
4448
font-size: 18px;
45-
line-height: 20px;
49+
line-height: 24px;
4650
}
4751
4852
a {
@@ -128,6 +132,6 @@ const Description: React.FC = () => {
128132
};
129133

130134
const formatMarkdown = (markdown?: string) =>
131-
markdown ? <ReactMarkdown>{markdown.replace(/\n/g, " \n")}</ReactMarkdown> : <StyledSkeleton />;
135+
markdown ? <StyledReactMarkdown>{markdown.replace(/\n/g, " \n")}</StyledReactMarkdown> : <StyledSkeleton />;
132136

133137
export default Description;

‎web/src/styles/global-style.ts

+6-4
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export const GlobalStyle = createGlobalStyle`
4646
4747
h2 {
4848
margin: 0 0 16px 0;
49-
font-weight: 600;
49+
font-weight: 400;
5050
font-size: 24px;
5151
line-height: 32px;
5252
color: ${({ theme }) => theme.primaryText};
@@ -93,7 +93,7 @@ export const GlobalStyle = createGlobalStyle`
9393
color: ${({ theme }) => theme.primaryBlue};
9494
transition: color 0.1s;
9595
}
96-
96+
9797
hr {
9898
opacity: 1;
9999
border: 1px solid ${({ theme }) => theme.stroke};
@@ -102,12 +102,14 @@ export const GlobalStyle = createGlobalStyle`
102102
svg, img {
103103
display: inline-block;
104104
vertical-align: middle;
105-
visibility: visible;
106-
105+
visibility: visible;
107106
}
108107
109108
ul, ol {
110109
li {
110+
font-weight: 400;
111+
font-size: 16px;
112+
line-height: 24px;
111113
color: ${({ theme }) => theme.primaryText};
112114
}
113115
}

0 commit comments

Comments
 (0)
Please sign in to comment.