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

Add company link at WorkerCard #101

Merged
merged 5 commits into from
Feb 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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)}
hyeongrok7874 marked this conversation as resolved.
Show resolved Hide resolved
</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