Skip to content

Commit

Permalink
[Fix/BAR-273] 리다이렉트 오류 수정 (#92)
Browse files Browse the repository at this point in the history
fix: 리다이렉트 오류 수정
  • Loading branch information
dmswl98 authored Feb 24, 2024
1 parent 27b05f5 commit c912b30
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/components/Layout/components/UserButton.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import Link from 'next/link';
import { useRouter } from 'next/navigation';

import Button from '@components/Button';
import Icon from '@components/Icon';
import { ROUTES } from '@constants/routes';
import { COLORS } from '@styles/tokens';
Expand All @@ -8,11 +9,18 @@ import * as styles from '../style.css';
import ProfileButton from './ProfileButton';

const UserButton = () => {
const router = useRouter();

return (
<div className={styles.userButton}>
<Link href={ROUTES.ARCHIVE} className={styles.archive}>
<Button
onClick={() => {
router.push(ROUTES.ARCHIVE);
}}
className={styles.archive}
>
<Icon icon="bookmark" color={COLORS['Grey/400']} />
</Link>
</Button>
<ProfileButton />
</div>
);
Expand Down

0 comments on commit c912b30

Please sign in to comment.