@@ -14,24 +14,20 @@ import { StyledSkeleton } from "components/StyledSkeleton";
1414
1515import AliasDisplay from "./Alias" ;
1616import { Divider } from "../Divider" ;
17+ import { ExternalLink } from "../ExternalLink" ;
1718
1819const StyledH1 = styled . h1 `
1920 margin: 0;
2021 word-wrap: break-word;
2122` ;
2223
23- const QuestionAndDescription = styled . div `
24- display: flex;
25- flex-direction: column;
26- word-wrap: break-word;
27- div:first-child p:first-of-type {
28- font-size: 16px;
29- font-weight: 400;
24+ const ReactMarkdownWrapper = styled . div `
25+ & p:first-of-type {
3026 margin: 0;
3127 }
3228` ;
3329
34- const VotingOptions = styled ( QuestionAndDescription ) `
30+ const VotingOptions = styled . div `
3531 display: flex;
3632 flex-direction: column;
3733 gap: 8px;
@@ -51,19 +47,6 @@ const Answer = styled.div`
5147 display: flex;
5248 flex-wrap: wrap;
5349 gap: 6px;
54- > label {
55- max-width: 100%;
56- }
57- ` ;
58-
59- const StyledSmall = styled . small `
60- color: ${ ( { theme } ) => theme . secondaryText } ;
61- font-weight: 400;
62- ` ;
63-
64- const StyledLabel = styled . label `
65- color: ${ ( { theme } ) => theme . primaryText } ;
66- font-weight: 600;
6750` ;
6851
6952const AliasesContainer = styled . div `
@@ -83,26 +66,29 @@ export const DisputeContext: React.FC<IDisputeContext> = ({ disputeDetails, isRp
8366 < >
8467 < StyledH1 > { isUndefined ( disputeDetails ) ? < StyledSkeleton /> : ( disputeDetails ?. title ?? errMsg ) } </ StyledH1 >
8568 { ! isUndefined ( disputeDetails ) && (
86- < QuestionAndDescription >
87- < ReactMarkdown > { disputeDetails ?. question } </ ReactMarkdown >
88- < ReactMarkdown > { disputeDetails ?. description } </ ReactMarkdown >
89- </ QuestionAndDescription >
69+ < >
70+ < ReactMarkdownWrapper >
71+ < ReactMarkdown > { disputeDetails ?. question } </ ReactMarkdown >
72+ </ ReactMarkdownWrapper >
73+ < ReactMarkdownWrapper >
74+ < ReactMarkdown > { disputeDetails ?. description } </ ReactMarkdown >
75+ </ ReactMarkdownWrapper >
76+ </ >
9077 ) }
9178 { isUndefined ( disputeDetails ?. frontendUrl ) ? null : (
92- < a href = { disputeDetails ?. frontendUrl } target = "_blank" rel = "noreferrer" >
79+ < ExternalLink href = { disputeDetails ?. frontendUrl } target = "_blank" rel = "noreferrer" >
9380 Go to arbitrable
94- </ a >
81+ </ ExternalLink >
9582 ) }
9683 < VotingOptions >
9784 { isUndefined ( disputeDetails ) ? null : < AnswersHeader > Voting Options</ AnswersHeader > }
9885 < AnswersContainer >
9986 { disputeDetails ?. answers ?. map ( ( answer : IAnswer , i : number ) => (
10087 < Answer key = { answer . title } >
101- < StyledSmall > { i + 1 + `.` } </ StyledSmall >
102- < StyledLabel >
103- { answer . title }
88+ < small >
89+ < label > { i + 1 } .</ label > { answer . title }
10490 { answer . description . trim ( ) ? ` - ${ answer . description } ` : null }
105- </ StyledLabel >
91+ </ small >
10692 </ Answer >
10793 ) ) }
10894 </ AnswersContainer >
0 commit comments