-
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.
- Loading branch information
1 parent
b6c8181
commit 260a562
Showing
12 changed files
with
232 additions
and
2 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 { FunctionComponent, PropsWithChildren } from 'react' | ||
import type { Metadata } from 'next' | ||
import Icon from '@/shared/components/custom/icon' | ||
|
||
export const metadata: Metadata = {} | ||
|
||
interface LayoutProps extends PropsWithChildren {} | ||
|
||
const Layout: FunctionComponent<LayoutProps> = ({ children }) => { | ||
return ( | ||
<> | ||
<header className="flex h-[54px] w-full max-w-mobile items-center justify-between bg-background-base-02 px-[18px]"> | ||
<Icon name="logo" className="h-[36px]" /> | ||
</header> | ||
{children} | ||
</> | ||
) | ||
} | ||
|
||
export default Layout |
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,24 @@ | ||
/* eslint-disable @typescript-eslint/no-unused-vars */ | ||
import AvailableInviteView from '@/features/invite/screen/available-invite' | ||
import UnavailableInviteView from '@/features/invite/screen/unavailable-invite' | ||
|
||
interface Props { | ||
params: { | ||
code: string | ||
} | ||
} | ||
|
||
const InvitePage = ({ params }: Props) => { | ||
const code = params.code | ||
// 링크 유효기간 체크 | ||
// 유효성에 따라 다른 page view 보여주기 | ||
const isValid = false | ||
|
||
return ( | ||
<main className="flex h-[calc(100dvh-54px)] w-full flex-col items-center overflow-y-auto overflow-x-hidden bg-background-base-02 px-[43px] scrollbar-hide"> | ||
{isValid ? <AvailableInviteView code={code} /> : <UnavailableInviteView />} | ||
</main> | ||
) | ||
} | ||
|
||
export default InvitePage |
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 { FunctionComponent, PropsWithChildren } from 'react' | ||
import type { Metadata } from 'next' | ||
import Icon from '@/shared/components/custom/icon' | ||
|
||
export const metadata: Metadata = {} | ||
|
||
interface LayoutProps extends PropsWithChildren {} | ||
|
||
const Layout: FunctionComponent<LayoutProps> = ({ children }) => { | ||
return ( | ||
<> | ||
<header className="flex h-[54px] w-full max-w-mobile items-center justify-between bg-background-base-02 px-[18px]"> | ||
<Icon name="logo" className="h-[36px]" /> | ||
</header> | ||
{children} | ||
</> | ||
) | ||
} | ||
|
||
export default Layout |
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,25 @@ | ||
/* eslint-disable @typescript-eslint/no-unused-vars */ | ||
import SocialLogin from '@/features/auth/social-login' | ||
import Text from '@/shared/components/ui/text' | ||
|
||
interface Props { | ||
searchParams?: { | ||
code: string | ||
} | ||
} | ||
|
||
const InviteSignUpPage = ({ searchParams }: Props) => { | ||
// 유효한 코드일 경우 전달됨 | ||
|
||
return ( | ||
<main className="flex-center h-[calc(100dvh-54px)] w-full flex-col overflow-y-auto overflow-x-hidden bg-background-base-02 px-[16px] scrollbar-hide"> | ||
<Text as={'h2'} typography="title1"> | ||
3초만에 픽토스 시작하기 | ||
</Text> | ||
|
||
<SocialLogin /> | ||
</main> | ||
) | ||
} | ||
|
||
export default InviteSignUpPage |
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 |
---|---|---|
|
@@ -60,7 +60,7 @@ const AccountPage = async () => { | |
<Text typography="subtitle2-medium">카카오 로그인</Text> | ||
|
||
{/* 구글 로그인 */} | ||
{/* <Icon name="google" className="size-[20px]" /> | ||
{/* <Icon name="google-with-background" className="size-[20px]" /> | ||
<Text typography="subtitle2-medium">구글 로그인</Text> | ||
<Text typography="text2-medium" className="font-suit text-text-caption"> | ||
[email protected] | ||
|
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,31 @@ | ||
'use client' | ||
|
||
import Icon from '@/shared/components/custom/icon' | ||
import { Button } from '@/shared/components/ui/button' | ||
import Text from '@/shared/components/ui/text' | ||
import { signIn } from 'next-auth/react' | ||
|
||
const SocialLogin = () => { | ||
return ( | ||
<div className="my-[64px] flex w-full flex-col items-center"> | ||
<Button | ||
className="w-full gap-[12px] rounded-full bg-white py-[13.5px] hover:bg-white" | ||
onClick={() => signIn('google')} | ||
> | ||
<Icon name="google" /> | ||
<Text typography="text1-bold" color="primary"> | ||
Google로 로그인 | ||
</Text> | ||
</Button> | ||
<Button | ||
className="mt-[14px] w-full gap-[16px] rounded-full bg-[#FBE44D] py-[13.5px] text-[#3C1E1E] hover:bg-[#FBE44D]/80" | ||
onClick={() => signIn('kakao')} | ||
> | ||
<Icon name="kakao" /> | ||
<Text typography="text1-bold">카카오로 로그인</Text> | ||
</Button> | ||
</div> | ||
) | ||
} | ||
|
||
export default SocialLogin |
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,42 @@ | ||
import { Button } from '@/shared/components/ui/button' | ||
import Text from '@/shared/components/ui/text' | ||
import Image from 'next/image' | ||
import Link from 'next/link' | ||
|
||
const AvailableInviteView = ({ code }: { code: string }) => { | ||
return ( | ||
<> | ||
<Image | ||
src={'/images/invite-letter.png'} | ||
alt="" | ||
width={198} | ||
height={210} | ||
className="my-[29px]" | ||
/> | ||
|
||
<Text typography="title1" className="mb-[8px]"> | ||
{'픽토스'}님이 보내신 | ||
</Text> | ||
|
||
<Text typography="title1" className="mb-[16px]"> | ||
{'픽토스'}{' '} | ||
<Text as="span" color="special"> | ||
PRO | ||
</Text>{' '} | ||
무료 이용권 | ||
</Text> | ||
|
||
<Text typography="text1-medium" color="sub" className="text-center"> | ||
하루 5분으로 내가 배운 것을 기억하세요 <br /> | ||
노트필기, 수업 기록, 저장한 자료 등 <br /> | ||
픽토스 PRO에서는 마음껏 퀴즈로 만들 수 있어요 | ||
</Text> | ||
|
||
<Link href={'/invite/sign-up' + '?code=' + code} className="w-full max-w-[280px]"> | ||
<Button className="mx-[5px] my-[56px] w-full max-w-[280px]">바로 받기</Button> | ||
</Link> | ||
</> | ||
) | ||
} | ||
|
||
export default AvailableInviteView |
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,38 @@ | ||
import { Button } from '@/shared/components/ui/button' | ||
import Text from '@/shared/components/ui/text' | ||
import Image from 'next/image' | ||
import Link from 'next/link' | ||
|
||
const UnavailableInviteView = () => { | ||
return ( | ||
<> | ||
<Image | ||
src={'/images/no-invite-letter.png'} | ||
alt="" | ||
width={133} | ||
height={92} | ||
className="my-[84px]" | ||
/> | ||
|
||
<Text typography="title1" className="mb-[8px]"> | ||
이런! | ||
</Text> | ||
|
||
<Text typography="title1" className="mb-[16px]"> | ||
초대장이 사라졌어요 | ||
</Text> | ||
|
||
<Text typography="text1-medium" color="sub" className="text-center"> | ||
링크 유효기간이 만료되어, 새로운 초대 링크가 필요해요 <br /> | ||
픽토스 PRO 무료 이용권을 받고 싶다면 <br /> | ||
친구에게 링크를 다시 요청해보세요 | ||
</Text> | ||
|
||
<Link href={'/invite/sign-up'} className="w-full max-w-[280px]"> | ||
<Button className="mx-[5px] my-[56px] w-full max-w-[280px]">그냥 바로 가입하기</Button> | ||
</Link> | ||
</> | ||
) | ||
} | ||
|
||
export default UnavailableInviteView |
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