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

fix: Avatar에서 에러와 긴 이미지 대응 #276

Merged
merged 2 commits into from
Apr 29, 2024
Merged

Conversation

Doeunnkimm
Copy link
Member

@Doeunnkimm Doeunnkimm commented Apr 29, 2024

🤔 해결하려는 문제가 무엇인가요?

  • 직사각형 프로필 이미지가 늘어지는 문제

🎉 어떻게 해결했나요?

  • Avatar 적용
  • 추가로 Avatar에 에러 이미지 대응도 해뒀어유
가로로 긴 경우 세로로 긴 경우 에러
image image image

📚 Attachment (Option)

  • N/A

Copy link

vercel bot commented Apr 29, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
amazing3-fe ✅ Ready (Inspect) Visit Preview Apr 29, 2024 3:10pm

@Doeunnkimm Doeunnkimm marked this pull request as draft April 29, 2024 15:10
@Doeunnkimm Doeunnkimm marked this pull request as ready for review April 29, 2024 15:11
Copy link

Comment on lines +27 to +30
// eslint-disable-next-line @next/next/no-img-element
<img src={profileImage} width={size} height={size} alt="profile_image" onError={handleAddDefaultImg} />
)}
</div>
Copy link
Member Author

Choose a reason for hiding this comment

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

next/image를 사용하면 onError 하나 때문에 state로 말아서 넣어줘야 해서.. img를 택했는데 다들 의견이 궁금해유~

사용법 관련 블로그

Copy link
Member

Choose a reason for hiding this comment

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

이미지로 해도 좋을듯! 어처피 아바타에 들어가는거니까 괜춘치 않읆까~?

@Doeunnkimm Doeunnkimm merged commit 1beeb37 into main Apr 29, 2024
4 checks passed
@Doeunnkimm Doeunnkimm deleted the fix/avatar-error branch April 29, 2024 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants