Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feat] 쇼케이스 페이지 club profile card 구현 #52

Merged
merged 17 commits into from
Jul 9, 2024

Conversation

Bowoon1216
Copy link
Contributor

@Bowoon1216 Bowoon1216 commented Jul 9, 2024

해당 이슈 번호

closed #47


체크리스트

  • 🔀 PR 제목의 형식을 잘 작성했나요? e.g. [feat] PR을 등록한다.
  • 💯 테스트는 잘 통과했나요?
  • 🏗️ 빌드는 성공했나요?
  • 🧹 불필요한 코드는 제거했나요?
  • ✅ 컨벤션을 지켰나요?
  • 💭 이슈는 등록했나요?
  • 🏷️ 라벨은 등록했나요?
  • 💻 git rebase를 사용했나요?
  • 🙇‍♂️ 리뷰어를 지정했나요?

📌 질문할 부분

  • 프로필의 default image를 쇼케이스 폴더안에 constant 폴더로 분리했습니다 !

캡쳐

image

Copy link
Member

@namdaeun namdaeun left a comment

Choose a reason for hiding this comment

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

LGTM 깔끔 굿이에용

detail: '안녕하세요 티키입니다. 저희는 멋진 웹사이트를 제작합니다.',
Image: Image,
},
argTypes: {},
Copy link
Member

Choose a reason for hiding this comment

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

  argTypes: {
    title: {
      control: {
        type: 'text',
      },
    },
    detail: {
      control: {
        type: 'text',
      },
    },
  },

요런식으로 컨트롤 타입도 지정해주면 스토리북을 더 잘 활용할 수 있을 것 같아요 !

Copy link
Contributor Author

Choose a reason for hiding this comment

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

오호라 감사합니다!!

Copy link
Contributor

@rtttr1 rtttr1 left a comment

Choose a reason for hiding this comment

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

반박불가.

Copy link
Contributor

@cindy-chaewon cindy-chaewon left a comment

Choose a reason for hiding this comment

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

깔꿈!! RGTM!!

Copy link
Contributor

@wuzoo wuzoo left a comment

Choose a reason for hiding this comment

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

LGTM~ 반영할 것만 해주세요

Comment on lines 8 to 12
interface ClubProfileCardProps {
title: string;
detail: string;
Image: React.FunctionComponent<React.SVGProps<SVGSVGElement>>;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

카드에서 img로 활용할 녀석들은 svg가 아니라 png 혹은 jpg가 될 것 같아서 이렇게 svgr 컴포넌트를 넘겨주는게 아니라 imgUrl을 넘겨주도록 구현하는게 맞을 것 같아요 !

prop으로 이미지 url을 가져오고, img 태그를 활용하여 src 속성에 대입해주는 것이 올바를 것 같습니다.

Copy link
Contributor

Choose a reason for hiding this comment

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

img 태그를 활용하는 과정에서, 최상위 컨테이너 요소를 width 100%를 적용한 후 그 안에서 img태그는 width 백퍼, object-fit 적용, aspect-ratio를 활용한 레이아웃 시프트 방지 등을 적용하면 좋을 것 같습니다.

Copy link
Member

Choose a reason for hiding this comment

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

맞네요...svg로 받아오는 걸 체크 못했는데 역시 주용님 !

Copy link
Contributor Author

Choose a reason for hiding this comment

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

넵! 적용했습니다 ~ 👍

Comment on lines 19 to 25
<section css={containerStyle}>
<img src={imageUrl ? imageUrl : defaultImage} alt={`${title}-image`} css={imageStyle} />
<div css={descriptionStyle}>
<p css={titleStyle}>{title}</p>
<p css={detailStyle}>{detail}</p>
</div>
</section>
Copy link
Contributor

Choose a reason for hiding this comment

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

section 태그가 맞을까요 ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

article 태그가 더 적합할 것 같아서 바꿨습니다 😶‍🌫️ 👍

Comment on lines 5 to 15
export const containerStyle = css({ width: '24.35rem' });

export const imageStyle = css({
width: '100%',
height: '14rem',

borderRadius: '16px 16px 0px 0px',

objectFit: 'none',
aspectRatio: 16 / 9,
});
Copy link
Contributor

Choose a reason for hiding this comment

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

Card의 컨테이너 속성이 100%가 되어야 할 것 같습니다 !

imgwidth만 백퍼를 적용한 후, aspectRatio 적용하면 될 것 같아요.
또한 objectFit cover 로 !

Copy link
Contributor Author

Choose a reason for hiding this comment

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

넵! 수정했습니다! 감사합니다~~ 👍

@Bowoon1216 Bowoon1216 merged commit 1fc9998 into develop Jul 9, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

showcase 페이지 ClubProfileCard 동아리 소개 컴포넌트 구현
5 participants