-
Notifications
You must be signed in to change notification settings - Fork 3
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
1 parent
2ddf3fc
commit 630739d
Showing
3 changed files
with
47 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
SUPABASE_URL = https://raqpvvgsmwarxhaialcz.supabase.co | ||
REACT_APP_ANON_KEY = eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InJhcXB2dmdzbXdhcnhoYWlhbGN6Iiwicm9sZSI6ImFub24iLCJpYXQiOjE2OTYxODg2MTgsImV4cCI6MjAxMTc2NDYxOH0.triHI7DNSzNeAibtktBZ1b2wQuwnd0WL7R_yZYOJbPc |
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 |
---|---|---|
@@ -1,7 +1,30 @@ | ||
<<<<<<< HEAD | ||
export default function Profile() { | ||
return ( | ||
<main> | ||
<div>Profile</div> | ||
</main> | ||
); | ||
} | ||
======= | ||
'use client'; | ||
import { LogOutButton, GlobalStyle } from './style'; | ||
import { createClient } from '@supabase/supabase-js'; | ||
|
||
export default function Profile() { | ||
return ( | ||
<main> | ||
<GlobalStyle /> | ||
<LogOutButton onClick={() => signOut()}>Sign Out</LogOutButton> | ||
</main> | ||
); | ||
} | ||
|
||
async function signOut() { | ||
const supabase = createClient( | ||
'https://raqpvvgsmwarxhaialcz.supabase.co', | ||
'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InJhcXB2dmdzbXdhcnhoYWlhbGN6Iiwicm9sZSI6ImFub24iLCJpYXQiOjE2OTYxODg2MTgsImV4cCI6MjAxMTc2NDYxOH0.triHI7DNSzNeAibtktBZ1b2wQuwnd0WL7R_yZYOJbPc', | ||
); | ||
const { error } = await supabase.auth.signOut(); | ||
} | ||
>>>>>>> 22db8ee (refactor:changed folder name) |
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 @@ | ||
import styled, { createGlobalStyle } from 'styled-components'; | ||
|
||
export const GlobalStyle = createGlobalStyle` | ||
body { | ||
background:white; | ||
} | ||
`; | ||
|
||
export const LogOutButton = styled.button` | ||
background: #00507f; | ||
color: #fff; | ||
text-align: center; | ||
font-family: Inter; | ||
font-size: 20px; | ||
font-style: normal; | ||
font-weight: 500; | ||
line-height: normal; | ||
border: transparent; | ||
border-radius: 5px; | ||
width: 300px; | ||
height: 50px; | ||
`; |