forked from PhantomOfLINUX/POL_Front
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
116 additions
and
29 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
"use client" | ||
import Link from "next/link" | ||
import { logoutLocally } from "@/utils/logoutUtils/LogoutUtils" | ||
import React from "react" | ||
|
||
type logoutType = { | ||
accessToken: string, | ||
} | ||
|
||
const HeaderAnalyzeBtn: React.FC<logoutType> = ({ accessToken }) => { | ||
|
||
return ( | ||
<button type="button" className="headerBtn"> | ||
<Link href="/">내 풀이 분석</Link> | ||
</button> | ||
|
||
) | ||
} | ||
|
||
export default HeaderAnalyzeBtn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
"use client" | ||
|
||
import React from "react"; | ||
|
||
import { useRouter } from "next/navigation"; | ||
|
||
|
||
const HeaderMockTestBtn = ({accessToken}:{accessToken:string}) => { | ||
|
||
const router = useRouter(); | ||
const goProblemSolve = () => { | ||
const queryParams = new URLSearchParams(); | ||
|
||
['isCompleted', 'stageGroupTypes', 'difficultyLevels'].forEach(key => { | ||
const value = localStorage.getItem(key); | ||
if (value) queryParams.set(key, value); | ||
}); | ||
|
||
router.push(`/challengelist?${queryParams.toString()}`); | ||
} | ||
return ( | ||
<button onClick={goProblemSolve} | ||
className="headerBtn"> | ||
모의고사<br />풀어보기 | ||
</button> | ||
) | ||
} | ||
|
||
export default HeaderMockTestBtn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
"use client" | ||
|
||
import React from "react"; | ||
|
||
import { useRouter } from "next/navigation"; | ||
|
||
const HeaderProblemBtn = ({accessToken}:{accessToken:string}) => { | ||
|
||
const router = useRouter(); | ||
const goProblemSolve = () => { | ||
const queryParams = new URLSearchParams(); | ||
|
||
['isCompleted', 'stageGroupTypes', 'difficultyLevels'].forEach(key => { | ||
const value = localStorage.getItem(key); | ||
if (value) queryParams.set(key, value); | ||
}); | ||
|
||
router.push(`/challengelist${queryParams.toString() ? `?${queryParams}` : ''}`); | ||
} | ||
return ( | ||
<button onClick={goProblemSolve} | ||
className="headerBtn"> | ||
문제 풀어보기 | ||
</button> | ||
) | ||
} | ||
|
||
export default HeaderProblemBtn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 12 additions & 12 deletions
24
src/components/problemStage/problemStageSelect/ProblemStageSelectLi.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters