-
Notifications
You must be signed in to change notification settings - Fork 3
feat: #45/이달의 차트 투표 모달창 레이아웃 구현 #140
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
doctor-taco
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오 좋습니다! 수고하셨어요!👍
hyeonjiroh
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
정말 많은 일이 있었네요... 고생 많으셨습니다!
| }; | ||
| }, []); | ||
|
|
||
| if (title.includes('아이돌') && window.innerWidth <= 375) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
저희 tailwind.config.js 파일 확인해보시면
screens: {
pc: '1200px',
tablet: '768px',
mobile: '375px',
},
모바일 화면 breakpoint가 375라 375px 이상이 모바일 화면인 것으로 알고 있습니다. 그래서 innerWidth가 768px 미만일 때 모바일 버전 투표 모달창을 보여주도록 조건을 바꿔줘야 할 것 같습니다!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
그리고 지금은 화면이 375px 이하일 때 '차트 투표하기를 눌렀을 경우에만 제대로 모바일 버전 모달창이 나오는 것 같습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
그래서 여기서도 반응형을 사용하는 건 어떨까 싶습니다
const [isMobile, setIsMobile] = useState(false);
...
useEffect(() => {
const handleResize = () => {
setIsMobile(window.innerWidth < 768);
};
window.addEventListener('resize', handleResize);
return () => window.removeEventListener('resize', handleResize);
}, []);
|
아 그리고 아직 구현 안 하신 걸 수도 있지만, 투표 모달창에서 스크롤바 없애는 게 더 깔끔하고 좋을 것 같습니다! |




#️⃣ Issue Number
#45
📝 요약(Summary)
파일명 변경
이달의 차트 투표 모달창 레이아웃 구현
🛠️ PR 유형
어떤 변경 사항이 있나요?
📸스크린샷 (선택)
PC 버전


태블릿 버전


모바일 버전


💬 공유사항
css 추가 수정 예정입니다.
무한 스크롤 구현 예정입니다.
전체 작업이 끝난 후 시간 여유가 생긴다면 재사용성 고려해 코드 수정해 보겠습니다!