Skip to content
This repository has been archived by the owner on Jan 20, 2025. It is now read-only.

Commit

Permalink
Merge pull request #101 from themoment-team/feature/WorkerCard
Browse files Browse the repository at this point in the history
Add company link at WorkerCard
  • Loading branch information
hyeongrok7874 authored Feb 26, 2023
2 parents 633672c + c754e70 commit 5dab539
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/components/WorkerCard/WorkerCard.styles.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,11 @@ export const Email = styled.a`
}
`;

export const Company = styled.p`
export const CompanyLink = styled.a`
font-weight: 400;
font-size: 1rem;
color: #000000;
text-decoration: none;
@media (max-width: 500px) {
font-size: 0.875rem;
Expand Down
10 changes: 9 additions & 1 deletion src/components/WorkerCard/WorkerCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ interface WorkerCardProps {
devYear: number;
position: string;
userType: 'WORKER' | 'MENTOR';
companyLink: string;
companyName: string;
location: string;
}
Expand All @@ -30,6 +31,7 @@ export const WorkerCardComponent: React.FC<WorkerCardProps> = ({
profileImgUri,
devYear,
position,
companyLink,
companyName,
location,
userType,
Expand Down Expand Up @@ -75,7 +77,13 @@ export const WorkerCardComponent: React.FC<WorkerCardProps> = ({
)}
</S.NameBadgeWrapper>
<S.Email href={`mailto:${email}`}>{subString(email, 25)}</S.Email>
<S.Company>{subString(companyName, 18)}</S.Company>
<S.CompanyLink
href={companyLink}
target="_blank"
rel="noopener noreferrer"
>
{subString(companyName, 18)}
</S.CompanyLink>
</S.ProfileParagraph>
</S.ProfileWrapper>
{!!introduction && (
Expand Down
1 change: 1 addition & 0 deletions src/components/WorkerList/WorkerList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ export const WorkerListComponent: React.FC<WorkerListProps> = ({
position={info.position}
userType={info.userType}
companyName={info.company.name}
companyLink={info.company.homepageUri}
location={info.company.location}
/>
))
Expand Down

1 comment on commit 5dab539

@vercel
Copy link

@vercel vercel bot commented on 5dab539 Feb 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.