diff --git a/public/ProfileTestImage.jpg b/public/ProfileTestImage.jpg new file mode 100644 index 00000000..3d7e85d8 Binary files /dev/null and b/public/ProfileTestImage.jpg differ diff --git a/src/components/Card/CommentCard.tsx b/src/components/Card/CommentCard.tsx new file mode 100644 index 00000000..3975f828 --- /dev/null +++ b/src/components/Card/CommentCard.tsx @@ -0,0 +1,41 @@ +import React from 'react'; +import Image from 'next/image'; +import { CommentCardProps } from '@/types/CommentCardTypes'; +import { sizeStyles, textSizeStyles, gapStyles, paddingStyles, contentWidthStyles } from '@/styles/CommentCardStyles'; + +function CommentCard({ status }: CommentCardProps) { + return ( +
+
+
+
+ 프로필 이미지{' '} +
+
+
+
+
+
지킬과 하이드
+
1시간 전
+
+ {status === 'edit' && ( +
+
수정
+
삭제
+
+ )} +
+
+ 오늘 하루 우울했었는데 덕분에 많은 힘 얻고 갑니다. 연금술사 책 다시 사서 오랜만에 읽어봐야겠어요! +
+
+
+
+ ); +} + +export default CommentCard; diff --git a/src/styles/CommentCardStyles.ts b/src/styles/CommentCardStyles.ts new file mode 100644 index 00000000..6d7a6a66 --- /dev/null +++ b/src/styles/CommentCardStyles.ts @@ -0,0 +1,44 @@ +export const sizeStyles = { + sm: 'w-[360px] h-[130px]', + md: 'md:w-[384px] md:h-[162px]', + lg: 'lg:w-[640px] lg:h-[176px]', +}; + +export const textSizeStyles = { + sm: { + name: 'text-xs', + time: 'text-xs', + action: 'text-xs', + content: 'text-sm', + }, + md: { + name: 'md:text-sm', + time: 'md:text-sm', + action: 'md:text-sm', + content: 'md:text-base', + }, + lg: { + name: 'lg:text-base', + time: 'lg:text-base', + action: 'lg:text-base', + content: 'lg:text-xl', + }, +}; + +export const gapStyles = { + sm: 'gap-2', + md: 'md:gap-3', + lg: 'lg:gap-4', +}; + +export const paddingStyles = { + sm: 'py-4 px-6', // 위아래 16px, 양 옆 24px + md: 'md:p-6', // 위아래, 양옆 24px + lg: 'lg:py-[35px] lg:px-6', // 위아래 35px, 양 옆 24px +}; + +export const contentWidthStyles = { + sm: 'w-[248px]', + md: 'md:w-[272px]', + lg: 'lg:w-[528px]', +}; diff --git a/src/types/CommentCardTypes.ts b/src/types/CommentCardTypes.ts new file mode 100644 index 00000000..abb0a28b --- /dev/null +++ b/src/types/CommentCardTypes.ts @@ -0,0 +1,3 @@ +export interface CommentCardProps { + status: 'edit' | 'complete'; +}