-
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.
Merge branch 'develop' of https://github.com/yourssu/Soomsil-Web into…
… feat/#201-drawer-service-remove
- Loading branch information
Showing
50 changed files
with
750 additions
and
477 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
File renamed without changes
This file was deleted.
Oops, something went wrong.
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,31 @@ | ||
import * as Dialog from '@radix-ui/react-dialog'; | ||
import styled, { keyframes } from 'styled-components'; | ||
|
||
import { Z_INDEX } from '@/constants/zIndex.constant'; | ||
|
||
const overlayShow = keyframes({ | ||
from: { opacity: 0 }, | ||
to: { opacity: 1 }, | ||
}); | ||
|
||
export const StyledDialogOverlay = styled(Dialog.Overlay)` | ||
background-color: rgba(0, 0, 0, 0.4); | ||
position: fixed; | ||
inset: 0; | ||
animation: ${overlayShow} 150ms cubic-bezier(0.16, 1, 0.3, 1); | ||
z-index: ${Z_INDEX.dialog}; | ||
`; | ||
|
||
export const StyledDialogContent = styled(Dialog.Content)` | ||
background-color: ${({ theme }) => theme.color.buttonBright}; | ||
box-shadow: 0rem 0rem 0.375rem 0rem rgba(61, 61, 61, 0.2); | ||
border-radius: 0.5rem; | ||
position: fixed; | ||
top: 50%; | ||
left: 50%; | ||
transform: translate(-50%, -50%); | ||
padding: 1.5rem; | ||
z-index: ${Z_INDEX.dialog}; | ||
`; |
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 @@ | ||
import * as Dialog from '@radix-ui/react-dialog'; | ||
import { useRecoilState } from 'recoil'; | ||
|
||
import { DIALOG } from '@/constants/dialog.constant.tsx'; | ||
import { DialogState } from '@/recoil/DialogState'; | ||
|
||
import { StyledDialogContent, StyledDialogOverlay } from './CustomDialog.style'; | ||
|
||
export const CustomDialog = () => { | ||
const [dialog, setDialog] = useRecoilState(DialogState); | ||
|
||
const handleClose = () => { | ||
setDialog(null); | ||
}; | ||
|
||
return ( | ||
<> | ||
{dialog && ( | ||
<Dialog.Root modal={true} open={dialog.open} onOpenChange={handleClose}> | ||
<Dialog.Portal> | ||
<StyledDialogOverlay /> | ||
<StyledDialogContent>{DIALOG[dialog.type]}</StyledDialogContent> | ||
</Dialog.Portal> | ||
</Dialog.Root> | ||
)} | ||
</> | ||
); | ||
}; |
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 styled from 'styled-components'; | ||
|
||
export const StyledContainer = styled.div` | ||
display: flex; | ||
flex-direction: column; | ||
gap: 8px; | ||
align-items: center; | ||
`; | ||
|
||
export const StyledTitle = styled.p` | ||
white-space: pre-line; | ||
text-align: center; | ||
${({ theme }) => theme.typo.body1}; | ||
color: ${({ theme }) => theme.color.textPrimary}; | ||
`; | ||
|
||
export const StyledButtonContainer = styled.div` | ||
display: flex; | ||
gap: 8px; | ||
`; |
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,39 @@ | ||
import { DialogClose } from '@radix-ui/react-dialog'; | ||
import { BoxButton } from '@yourssu/design-system-react'; | ||
import { useNavigate } from 'react-router-dom'; | ||
|
||
import Ppussung from '@/assets/defaultProfile.png'; | ||
import { ProfileSvg } from '@/components/ProfileSvg/ProfileSVG'; | ||
|
||
import { StyledContainer, StyledButtonContainer, StyledTitle } from './LoginDialog.style'; | ||
|
||
export const LoginDialog = () => { | ||
const navigate = useNavigate(); | ||
|
||
return ( | ||
<StyledContainer> | ||
<ProfileSvg imageUrl={Ppussung} /> | ||
<StyledTitle>{'로그인이 필요한 서비스입니다.\n로그인하시겠어요?'}</StyledTitle> | ||
<StyledButtonContainer> | ||
<DialogClose asChild> | ||
<BoxButton | ||
rounding={4} | ||
size="large" | ||
variant="filled" | ||
width="10.75rem" | ||
onClick={() => { | ||
navigate('/login'); | ||
}} | ||
> | ||
예 | ||
</BoxButton> | ||
</DialogClose> | ||
<DialogClose asChild> | ||
<BoxButton rounding={4} size="large" variant="line" width="10.75rem"> | ||
아니오 | ||
</BoxButton> | ||
</DialogClose> | ||
</StyledButtonContainer> | ||
</StyledContainer> | ||
); | ||
}; |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
44 changes: 44 additions & 0 deletions
44
src/components/ProfileDropdownMenu/ProfileDropdownMenu.style.ts
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,44 @@ | ||
import * as DropdownMenu from '@radix-ui/react-dropdown-menu'; | ||
import styled, { css } from 'styled-components'; | ||
|
||
import { Z_INDEX } from '@/constants/zIndex.constant'; | ||
|
||
export const StyledProfileDropdownContent = styled(DropdownMenu.Content)` | ||
display: flex; | ||
flex-direction: column; | ||
align-items: flex-start; | ||
width: fit-content; | ||
padding: 1rem 0.75rem; | ||
gap: 1rem; | ||
z-index: ${Z_INDEX.dropdown}; | ||
border-radius: 0.25rem; | ||
border: 1px solid ${({ theme }) => theme.color.borderThin}; | ||
background-color: ${({ theme }) => theme.color.bgNormal}; | ||
box-shadow: 0px 1px 3px 0px rgba(107, 114, 128, 0.4); | ||
`; | ||
|
||
export const StyledProfileDropdownNickname = styled(DropdownMenu.Item)` | ||
${({ theme }) => css` | ||
${theme.typo.body1} | ||
color: ${theme.color.textPrimary}; | ||
`} | ||
`; | ||
|
||
export const StyledProfileDropdownEmail = styled(DropdownMenu.Item)` | ||
${({ theme }) => css` | ||
${theme.typo.caption0} | ||
color: ${theme.color.textDisabled}; | ||
`} | ||
`; | ||
|
||
export const StyledProfileDropdownItem = styled(DropdownMenu.Item)` | ||
${({ theme }) => css` | ||
${theme.typo.body2} | ||
color: ${theme.color.textPrimary}; | ||
&: hover { | ||
color: ${theme.color.textPointed}; | ||
} | ||
`} | ||
`; |
Oops, something went wrong.