-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #96 from KakaoTech-BootCamp-Team-2/dev
🚀 Deploy
- Loading branch information
Showing
9 changed files
with
113 additions
and
15 deletions.
There are no files selected for viewing
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
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,30 @@ | ||
import React from "react"; | ||
|
||
function LoginPage() { | ||
const handleLogin = async () => { | ||
try { | ||
console.log("Attempting to redirect to OAuth provider..."); | ||
|
||
// Redirection URL 로그 추가 | ||
// const redirectUrl = `https://kauth.kakao.com/oauth/authorize?client_id=${kakaoClientId}&redirect_uri=${redirectUri}&response_type=code`; | ||
const redirectUrl = | ||
"https://api.kaboo.site:8081/oauth2/authorization/kakao"; | ||
console.log("Redirect URL:", redirectUrl); | ||
|
||
window.location.href = redirectUrl; | ||
|
||
console.log(res); | ||
} catch (error) { | ||
console.error("Error during redirection:", error); | ||
} | ||
}; | ||
|
||
return ( | ||
<div> | ||
<h2>Login Page</h2> | ||
<button onClick={handleLogin}>Login with kakao</button> | ||
</div> | ||
); | ||
} | ||
|
||
export default LoginPage; |
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,22 @@ | ||
/** @jsxImportSource @emotion/react */ | ||
import { css } from "@emotion/react"; | ||
|
||
export const StyledDiv = ({ children }) => { | ||
const defaultYellow = "#FFF496"; | ||
const defaultBrown = "#715F00"; | ||
const liteBrwon = "#D3CBA1"; | ||
const black = "#000"; | ||
return ( | ||
<div | ||
css={css` | ||
background-color: ${defaultYellow}; | ||
font-size: 24px; | ||
border-radius: 20px; | ||
display: flex; | ||
gap: 20px; | ||
`} | ||
> | ||
{children} | ||
</div> | ||
); | ||
}; |
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 @@ | ||
import React from "react"; | ||
import * as main from "./HomeMain_styled"; | ||
import Header from "../../components/Header"; | ||
|
||
function HomeMain() { | ||
const test = async () => { | ||
const res = await instance.get("/api/auth/member/all"); | ||
console.log(res); | ||
}; | ||
React.useEffect(() => { | ||
test(); | ||
}, []); | ||
return ( | ||
<main.Container> | ||
<main.Main></main.Main> | ||
</main.Container> | ||
); | ||
} | ||
|
||
export default HomeMain; |
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