-
Notifications
You must be signed in to change notification settings - Fork 2
랭킹페이지 페이지네이션 API 연결 구현 완료 #26
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
base: develop
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
'<!DOCTYPE html>\n<html lang="en">\n <head>\n <title>HTML from Tag</title>\n </head>\n <body>\n <form action="actionFile.php" method="get">\n First name:\n <input type="text" name="first_name" value="" maxlength="100" />\n <br />\n Last name:\n <input type="text" name="last_name" value="" maxlength="100" />\n <input type="submit" value="Submit" />\n </form>\n </body>\n</html>', | ||
'<!DOCTYPE html>\n<html lang="en">\n <head>\n <title>Table Sample</title>\n </head>\n <body>\n <table border="1">\n <tbody>\n <tr>\n <td>first cell</td>\n <td>second cell</td>\n </tr>\n <tr>\n <td>third cell</td>\n <td>fourth cell</td>\n </tr>\n </tbody>\n </table>\n </body>\n</html>', | ||
|
||
// c | ||
"#include <stdio.h>\n\n int main(){\n\n printf(“Hello world” );\n return 0;\n}", | ||
"#include <stdio.h>\n\nint main() {\n printf(“Hello world”);\n return 0;\n}", |
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.
앗 미세한 오타들을 잘 잡아주셨네요! 이 라인에 printf("Hello world!")
를 보시면 큰따옴표가 양쪽 모양이 다른 일반적인 문서의 큰따옴표로 돼 있어서 실제 입력할 때는 큰따옴표를 입력해도 오타로 인식하더라구요. 아마 요 부분 그냥 코드에디터 상에서 지웠다가 큰 따옴표 입력해주시면 고쳐질 것 같아요!
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.
네네 수정해보겠습니다!
src/pages/Leaderboard/index.js
Outdated
const [offSet, setOffSet] = useState(2); | ||
|
||
|
||
const topRanks = useRanks(1, pageSize, languageNo, grammarNo).ranks; |
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.
앗 topRanks
같은 경우 고정적으로 pageSize
2로 해서 받아와도 될 것 같은데 어떻게 생각하시나용
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.
앗 그러네요! 반영해서 수정해보도록 하겠습니다!
…/github.com/jaychang99/tadak-frontend into Feature_Issue#11_Leaderboard_Pagination_API
@@ -37,11 +37,11 @@ function LeaderBoard({ ranks, pageNumber, pageSize }) { | |||
{ranks && | |||
ranks.map((rank, index) => ( | |||
<LeaderBoardItem | |||
rank={(pageNumber == 1) ? index + 1 + TOP_DISPLAY_USER : index + 1 + pageSize} | |||
rank={rank.ranking} |
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.
오홍 맞네요 이제 API 자체에서 ranking 을 주니까 pageSize
와 pageNumber
로 계산을 안 해도 돼서 좋군요. 그러면 prop 에서도 받아오지 않아도 좋을 것 같은데 어떻게 생각하시나용?
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.
확인했습니다 본 thread 는 resolve 하겟습니다!
src/pages/Leaderboard/index.js
Outdated
@@ -8,7 +8,7 @@ import { | |||
} from "pages/Leaderboard/styles"; | |||
import React, { useState, useEffect } from "react"; | |||
import { defaultFadeInVariants, staggerHalf, staggerQuarter } from "styles/motions"; | |||
import { filterProps, motion } from "framer-motion"; | |||
import { motion } from "framer-motion"; |
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.
지금 보니까 이 motion
도 아래에서 안 쓰이는 것 같은데 확인 한번 해 주실 수 있나용 이건 아마 제가 import 해둔거같긴한데... ㅜ.ㅜ 헛헛
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.
저도 처음에 그런 줄 알고 지웠다가 오류가 나서 봤더니 motion.div에서 쓰이는 것 같더라구요 ,,,,
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.
앗 맞네요 밑에 <motion.div>
가 있네요..헛헛 😅 코드 가 접혀져서 못 봤나보네요 죄송함니다...ㅋㅋ
src/pages/Leaderboard/index.js
Outdated
<> | ||
<LeaderBoard ranks={(pageNumber == 1) ? ranks.slice(2) : ranks} pageNumber={pageNumber} pageSize={pageSize}></LeaderBoard> | ||
<LeaderBoard ranks={(pageNumber === 1) ? ranks.slice(2) : ranks} pageNumber={pageNumber} pageSize={LEADERBOARD_PAGE_SIZE}></LeaderBoard> |
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.
API 에 이제 ranking
이 추가되어서 요기 이제 pageNumber
랑 pageSize
넘기지 않아도 되지 않을까용?
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.
네네 안 남겨도 될 것 같습니다
늦은 시간에도 고생하셨습니다! 추가적인 부분도 comment 달아놓았습니다! |
src/pages/Login/index.js 에서 try-catch 부분 제외하고 수정 완료해서 push 해두었습니다! |
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.
LGTM 😄 수고많으셨씁니다!
src/pages/Leaderboard/index.js
Outdated
@@ -8,7 +8,7 @@ import { | |||
} from "pages/Leaderboard/styles"; | |||
import React, { useState, useEffect } from "react"; | |||
import { defaultFadeInVariants, staggerHalf, staggerQuarter } from "styles/motions"; | |||
import { filterProps, motion } from "framer-motion"; | |||
import { motion } from "framer-motion"; |
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.
앗 맞네요 밑에 <motion.div>
가 있네요..헛헛 😅 코드 가 접혀져서 못 봤나보네요 죄송함니다...ㅋㅋ
@@ -37,11 +37,11 @@ function LeaderBoard({ ranks, pageNumber, pageSize }) { | |||
{ranks && | |||
ranks.map((rank, index) => ( | |||
<LeaderBoardItem | |||
rank={(pageNumber == 1) ? index + 1 + TOP_DISPLAY_USER : index + 1 + pageSize} | |||
rank={rank.ranking} |
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.
확인했습니다 본 thread 는 resolve 하겟습니다!
Related to #11
체크 리스트
작업 내역
비고