From 8cc4006d6b9f66c81d99a5621cc93d18ae1c9189 Mon Sep 17 00:00:00 2001 From: Collection50 Date: Wed, 12 Jun 2024 11:44:14 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20=ED=94=84=EB=A1=9C=ED=95=84=20=EC=82=AC?= =?UTF-8?q?=EC=9A=A9=EC=9E=90=20=EC=9D=B4=EB=AF=B8=EC=A7=80=20API=20?= =?UTF-8?q?=EC=97=B0=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../[postId]/components/PostDetailFetcher/types.ts | 1 + .../[postId]/components/PostDetailHeader/index.tsx | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/app/blog/[blogId]/post/[postId]/components/PostDetailFetcher/types.ts b/src/app/blog/[blogId]/post/[postId]/components/PostDetailFetcher/types.ts index 0809ad7..d4bb630 100644 --- a/src/app/blog/[blogId]/post/[postId]/components/PostDetailFetcher/types.ts +++ b/src/app/blog/[blogId]/post/[postId]/components/PostDetailFetcher/types.ts @@ -27,6 +27,7 @@ export interface PostDetailResponse { categoryName: string; photoUrls: string[]; + profile: string; postStickerItems: Sticker[]; postHashtags: string[]; diff --git a/src/app/blog/[blogId]/post/[postId]/components/PostDetailHeader/index.tsx b/src/app/blog/[blogId]/post/[postId]/components/PostDetailHeader/index.tsx index b73f8ca..402bc35 100644 --- a/src/app/blog/[blogId]/post/[postId]/components/PostDetailHeader/index.tsx +++ b/src/app/blog/[blogId]/post/[postId]/components/PostDetailHeader/index.tsx @@ -5,13 +5,14 @@ import { motion } from 'framer-motion'; import { Button, Copy, Input } from '@/components/Common'; import { formatDate } from '@/utils'; import { usePortal } from '@/hooks'; +import Image from 'next/image'; import { usePostDetailContext } from '../PostDetailFetcher/PostDetailContext'; import { useHandlePostDetail } from './hooks'; export default function PostDetailHeader({ postId }: { postId: string }) { const { - postDetail: { title, createdAt, memberId, nickname }, + postDetail: { title, createdAt, memberId, nickname, profile }, loginMemberId, } = usePostDetailContext(); @@ -50,7 +51,14 @@ export default function PostDetailHeader({ postId }: { postId: string }) {
-
+ profile} + src={profile} + width={30} + height={30} + alt="profile alt" + className="rounded-full" + />

{nickname}

{formatDate(createdAt)}