-
Notifications
You must be signed in to change notification settings - Fork 2
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] 휴지통페이지 디자인 QA + 팀용량 api #457
Conversation
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 convertUnit = 1024 * 1024; |
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.
상수니까 리랜더링에 영향 안받게 함수 밖으로 빼버리거나 파일 분리하는게 좋겠네요!
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.
보우니 큐에이 해결 고생하셧슴다!
{ onSuccess: () => usageRefetch() } | ||
); |
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.
onSuccess시에도 성공했다는 토스트 띄워주는 건 어떵가요 ?
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.
이게 deletemutation이라 성공했을 때 토스트가 뜨도록 설정해놨습니다!
const capacity = (data?.data?.capacity || 0) / convertUnit / convertUnit; | ||
const availableUsage = capacity - (data?.data?.usage || 0) / convertUnit; | ||
|
||
const modifiedCapacity = Math.floor(capacity * 1000) / 1000; | ||
const modifiedAvailableUsage = Math.ceil(availableUsage * 1000) / 1000; |
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.
요게 GB로 변환하는 로직이라면 util로 분리하고 호출해서 값을 리턴하는 방식이 가독성이 더 높아질 것 같습니다!
그리고 api 관련 훅이니까 hook/api에 위치하는 게 좋을 것 가타요!
…to style/deleted/#446-QA
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.
고생하셧슴당 ~
apps/client/src/page/drive/index.tsx
Outdated
useEffect(() => { | ||
usageRefetch(); | ||
}, [filteredResult, usageRefetch]); | ||
|
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.
filteredResult
를 쿼리 키에 넣어서 자동으로 리패치하도록 하는 것이 더 좋을 것 같아요 !
해당 이슈 번호
closed #446
체크리스트
💎 PR Point
그리구 팀용량 api를 받아와서 GB로 단위 변환하여 출력했습니다.
단위 변환과 사용가능 용량 계산 하는 유틸함수를 만들었습니다.
📌스크린샷 (선택)