From 7fcfee286b16615cbce24ff5351f201948de0a9a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=EA=B9=80=EC=84=9D=EC=A7=84=28maru=29?=
<102217654+SEOKKAMONI@users.noreply.github.com>
Date: Wed, 1 May 2024 00:46:08 +0900
Subject: [PATCH] =?UTF-8?q?feat(client):=20=ED=94=84=EB=A1=9C=ED=95=84=20?=
=?UTF-8?q?=EC=B9=B4=EB=93=9C=20=EC=BB=B4=ED=8F=AC=EB=84=8C=ED=8A=B8?=
=?UTF-8?q?=EC=97=90=20=ED=8F=AC=ED=8A=B8=ED=8F=B4=EB=A6=AC=EC=98=A4,=20?=
=?UTF-8?q?=EC=9D=B4=EB=A0=A5=EC=84=9C,=20=EA=B9=83=ED=97=88=EB=B8=8C=20?=
=?UTF-8?q?=EC=9E=85=EB=A0=A5=20=EC=9C=A0=EB=AC=B4=20=ED=91=9C=EC=8B=9C=20?=
=?UTF-8?q?(#386)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* feat(client): 프로필 카드 컴포넌트에 포트폴리오, 이력서, 깃허브 입력 유무 표시
* feat(client): 아이콘 마다 툴팁 추가
---
.../client/public/assets/svgs/github_icon.svg | 3 +
apps/client/public/next.svg | 1 -
apps/client/public/vercel.svg | 1 -
.../src/components/common/Header/index.tsx | 8 +--
.../components/profile/ProfileCard/index.tsx | 72 +++++++++++++++----
.../components/profile/ProfileList/index.tsx | 3 +
.../profile/ProfileNavigationBar/index.tsx | 1 +
.../hooks/api/profile/useGetProfileList.ts | 14 ++--
packages/ui/src/Tooltip/index.tsx | 16 ++---
9 files changed, 83 insertions(+), 36 deletions(-)
create mode 100644 apps/client/public/assets/svgs/github_icon.svg
delete mode 100644 apps/client/public/next.svg
delete mode 100644 apps/client/public/vercel.svg
diff --git a/apps/client/public/assets/svgs/github_icon.svg b/apps/client/public/assets/svgs/github_icon.svg
new file mode 100644
index 00000000..935ba676
--- /dev/null
+++ b/apps/client/public/assets/svgs/github_icon.svg
@@ -0,0 +1,3 @@
+
diff --git a/apps/client/public/next.svg b/apps/client/public/next.svg
deleted file mode 100644
index 5174b28c..00000000
--- a/apps/client/public/next.svg
+++ /dev/null
@@ -1 +0,0 @@
-
\ No newline at end of file
diff --git a/apps/client/public/vercel.svg b/apps/client/public/vercel.svg
deleted file mode 100644
index d2f84222..00000000
--- a/apps/client/public/vercel.svg
+++ /dev/null
@@ -1 +0,0 @@
-
\ No newline at end of file
diff --git a/apps/client/src/components/common/Header/index.tsx b/apps/client/src/components/common/Header/index.tsx
index ca666a1e..ce465fad 100644
--- a/apps/client/src/components/common/Header/index.tsx
+++ b/apps/client/src/components/common/Header/index.tsx
@@ -39,9 +39,7 @@ const Header = () => {
{!isLoading && (
{user.isLogin && (
-
-
-
+
)}
{user.isLogin ? (
+
+ {portfolioUrl && (
+
+ {({ ref }) => {
+ return (
+
+ );
+ }}
+
+ )}
+ {resumeUrl && (
+
+ {({ ref }) => {
+ return (
+
+ );
+ }}
+
+ )}
+ {githubId && (
+
+ {({ ref }) => {
+ return (
+
+ );
+ }}
+
+ )}
+
);
};
@@ -75,6 +116,7 @@ const ProfileCard = ({
export default ProfileCard;
const StyledProfileCard = styled.div`
+ position: relative;
transition: all 0.25s ease;
padding: 16px;
border-radius: 8px;
@@ -90,3 +132,9 @@ const StyledProfileImage = styled(Image)`
border-radius: 8px;
object-fit: cover;
`;
+
+const StyledProfilePresenceCheck = styled(Stack)`
+ position: absolute;
+ right: 16px;
+ bottom: 16px;
+`;
diff --git a/apps/client/src/components/profile/ProfileList/index.tsx b/apps/client/src/components/profile/ProfileList/index.tsx
index 02ca56de..0f939b24 100644
--- a/apps/client/src/components/profile/ProfileList/index.tsx
+++ b/apps/client/src/components/profile/ProfileList/index.tsx
@@ -40,6 +40,9 @@ const ProfileList = ({ major, isRecruited, cardinal }: ProfileListProps) => {
userId={profile.userId}
company={profile.company}
introduction={profile.introduction}
+ portfolioUrl={profile.portfolioUrl}
+ githubId={profile.githubId}
+ resumeUrl={profile.resumeUrl}
/>
))}
diff --git a/apps/client/src/components/profile/ProfileNavigationBar/index.tsx b/apps/client/src/components/profile/ProfileNavigationBar/index.tsx
index 9a088455..e7fe6061 100644
--- a/apps/client/src/components/profile/ProfileNavigationBar/index.tsx
+++ b/apps/client/src/components/profile/ProfileNavigationBar/index.tsx
@@ -162,6 +162,7 @@ const StyledProfileNavigationBar = styled.div`
${({ theme }) => css`
border-bottom: 1px solid ${theme.colors.gray200};
background-color: ${theme.colors.white};
+ z-index: ${theme.zIndex.component3};
`}
`;
diff --git a/apps/client/src/hooks/api/profile/useGetProfileList.ts b/apps/client/src/hooks/api/profile/useGetProfileList.ts
index bca485aa..1867ba5a 100644
--- a/apps/client/src/hooks/api/profile/useGetProfileList.ts
+++ b/apps/client/src/hooks/api/profile/useGetProfileList.ts
@@ -12,15 +12,17 @@ export type GetProfileListParams = {
export type GetProfileListResponse = {
id: number;
- userId: number;
name: string;
- admissionYear: number;
imageUrl: string;
- major: Major;
- introduction: string;
- company: string;
- isRecruited: boolean;
cardinal: number;
+ major: Major;
+ profileId: number;
+ userId: number;
+ company?: string;
+ introduction?: string;
+ githubId?: string;
+ portfolioUrl?: string;
+ resumeUrl?: string;
};
export const PROFILE_LIST_QUERY_KEY = 'profileList';
diff --git a/packages/ui/src/Tooltip/index.tsx b/packages/ui/src/Tooltip/index.tsx
index d378ab65..66cb4df3 100644
--- a/packages/ui/src/Tooltip/index.tsx
+++ b/packages/ui/src/Tooltip/index.tsx
@@ -102,14 +102,12 @@ const Tooltip = ({
});
return (
- <>
-
- {children({
- ref: refs.setReference,
- onOpen: openTooltip,
- referenceProps: getReferenceProps(),
- })}
-
+
+ {children({
+ ref: refs.setReference,
+ onOpen: openTooltip,
+ referenceProps: getReferenceProps(),
+ })}
- >
+
);
};