@@ -26,18 +26,33 @@ const StyledCard = styled(Card)`
26
26
height: auto;
27
27
` ;
28
28
29
- const TextContainer = styled . div `
29
+ const TopContent = styled . div `
30
+ display: flex;
31
+ flex-direction: column;
30
32
padding: ${ responsiveSize ( 8 , 24 ) } ;
33
+ gap: 8px;
34
+ overflow-wrap: break-word;
35
+
31
36
> * {
32
37
overflow-wrap: break-word;
33
38
margin: 0;
34
39
}
35
- > h3 {
40
+ p {
41
+ margin: 0;
42
+ }
43
+ h3 {
36
44
display: inline-block;
37
- margin: 0px 4px ;
45
+ margin: 0 ;
38
46
}
39
47
` ;
40
48
49
+ const IndexAndName = styled . div `
50
+ display: flex;
51
+ flex-direction: row;
52
+ align-items: center;
53
+ gap: 6px;
54
+ ` ;
55
+
41
56
const Index = styled . p `
42
57
display: inline-block;
43
58
` ;
@@ -49,6 +64,9 @@ const StyledReactMarkdown = styled(ReactMarkdown)`
49
64
code {
50
65
color: ${ ( { theme } ) => theme . secondaryText } ;
51
66
}
67
+ p {
68
+ margin: 0;
69
+ }
52
70
` ;
53
71
54
72
const BottomShade = styled . div `
@@ -65,25 +83,7 @@ const BottomShade = styled.div`
65
83
}
66
84
` ;
67
85
68
- const AccountContainer = styled . div `
69
- display: flex;
70
- flex-direction: row;
71
- gap: 8px;
72
- align-items: center;
73
-
74
- canvas {
75
- width: 24px;
76
- height: 24px;
77
- }
78
-
79
- > * {
80
- flex-basis: 1;
81
- flex-shrink: 0;
82
- margin: 0;
83
- }
84
- ` ;
85
-
86
- const LeftContent = styled . div `
86
+ const BottomLeftContent = styled . div `
87
87
display: block;
88
88
89
89
& > *:not(:last-child) {
@@ -105,21 +105,45 @@ const LeftContent = styled.div`
105
105
) }
106
106
` ;
107
107
108
+ const AccountContainer = styled . div `
109
+ display: flex;
110
+ flex-direction: row;
111
+ gap: 8px;
112
+ align-items: center;
113
+
114
+ canvas {
115
+ width: 24px;
116
+ height: 24px;
117
+ }
118
+
119
+ > * {
120
+ flex-basis: 1;
121
+ flex-shrink: 0;
122
+ margin: 0;
123
+ }
124
+ ` ;
125
+
108
126
const HoverStyle = css `
109
127
:hover {
110
128
text-decoration: underline;
111
129
color: ${ ( { theme } ) => theme . primaryBlue } ;
112
130
cursor: pointer;
113
131
}
132
+ :hover {
133
+ label {
134
+ text-decoration: underline;
135
+ color: ${ ( { theme } ) => theme . primaryBlue } ;
136
+ cursor: pointer;
137
+ }
138
+ }
114
139
` ;
115
140
116
141
const Address = styled . p `
117
142
${ HoverStyle }
118
143
margin: 0;
119
144
` ;
120
145
121
- const Timestamp = styled . label `
122
- color: ${ ( { theme } ) => theme . secondaryText } ;
146
+ const StyledExternalLink = styled ( ExternalLink ) `
123
147
${ HoverStyle }
124
148
` ;
125
149
@@ -191,29 +215,25 @@ const EvidenceCard: React.FC<IEvidenceCard> = ({
191
215
192
216
return (
193
217
< StyledCard >
194
- < TextContainer >
195
- < Index > #{ index } :</ Index >
196
- { name && description ? (
197
- < >
198
- < h3 > { name } </ h3 >
199
- < StyledReactMarkdown > { description } </ StyledReactMarkdown >
200
- </ >
201
- ) : (
202
- < p > { evidence } </ p >
203
- ) }
204
- </ TextContainer >
218
+ < TopContent >
219
+ < IndexAndName >
220
+ < Index > #{ index } : </ Index >
221
+ < h3 > { name } </ h3 >
222
+ </ IndexAndName >
223
+ { name && description ? < StyledReactMarkdown > { description } </ StyledReactMarkdown > : < p > { evidence } </ p > }
224
+ </ TopContent >
205
225
< BottomShade >
206
- < LeftContent >
226
+ < BottomLeftContent >
207
227
< AccountContainer >
208
228
< Identicon size = "24" string = { sender } />
209
229
< ExternalLink to = { addressExplorerLink } rel = "noopener noreferrer" target = "_blank" >
210
230
< Address > { shortenAddress ( sender ) } </ Address >
211
231
</ ExternalLink >
212
232
</ AccountContainer >
213
- < ExternalLink to = { transactionExplorerLink } rel = "noopener noreferrer" target = "_blank" >
214
- < Timestamp > { formatDate ( Number ( timestamp ) , true ) } </ Timestamp >
215
- </ ExternalLink >
216
- </ LeftContent >
233
+ < StyledExternalLink to = { transactionExplorerLink } rel = "noopener noreferrer" target = "_blank" >
234
+ < label > { formatDate ( Number ( timestamp ) , true ) } </ label >
235
+ </ StyledExternalLink >
236
+ </ BottomLeftContent >
217
237
{ fileURI && fileURI !== "-" ? (
218
238
< FileLinkContainer >
219
239
< StyledInternalLink to = { `attachment/?url=${ getIpfsUrl ( fileURI ) } ` } >
0 commit comments