Skip to content

Commit

Permalink
chore: ui fixes for proof of work
Browse files Browse the repository at this point in the history
  • Loading branch information
jordan-ae committed Jan 4, 2025
1 parent 47cf11e commit ad58497
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 4 deletions.
23 changes: 19 additions & 4 deletions src/people/widgetViews/summaries/wantedSummaries/CodingBounty.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -881,10 +881,25 @@ function MobileView(props: CodingBountiesProps) {
{proofs[bountyID]?.length ? (
<ul>
{proofs[bountyID].map((proof: any, index: any) => (
<li
key={index}
dangerouslySetInnerHTML={{ __html: proof.description }}
/>
<li key={index}>
{proof.description
.split(/(https?:\/\/[^\s]+)/)
.map((part: string, i: number) => {
if (part.match(/https?:\/\/[^\s]+/)) {
return (
<a
key={i}
href={part}
target="_blank"
rel="noopener noreferrer"
>
{part}
</a>
);
}
return part;
})}
</li>
))}
</ul>
) : (
Expand Down
2 changes: 2 additions & 0 deletions src/people/widgetViews/summaries/wantedSummaries/style.ts
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,7 @@ export const ProofContainer = styled.div`

export const Section = styled.div`
flex: 1;
margin-top: 60px;
`;

export const Title = styled.h2`
Expand All @@ -339,6 +340,7 @@ export const Description = styled.span`
line-height: 1.5;
resize: vertical;
margin-bottom: 16px;
max-width: 70%;
`;

export const Link = styled.a`
Expand Down

0 comments on commit ad58497

Please sign in to comment.