Skip to content

Commit

Permalink
design : empty 미션 대응 및 css 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
wade3420 committed Jan 28, 2024
1 parent 857b5d4 commit c3abcfc
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 5 deletions.
16 changes: 12 additions & 4 deletions src/app/home/FollowMissionList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import Link from 'next/link';
import { useFollowMissions } from '@/apis/follow';
import { MissionListSkeleton } from '@/app/home/home.styles';
import MissionBadge from '@/app/home/MissionBadge';
import MissionEmptyList from '@/app/home/MissionEmptyList';
import Empty from '@/components/Empty/Empty';
import { TwoLineListItem } from '@/components/ListItem';
import { MISSION_CATEGORY_LABEL } from '@/constants/mission';
import { ROUTER } from '@/constants/router';
Expand All @@ -15,7 +15,7 @@ interface FollowMissionListProps {

function FollowMissionList({ followId }: FollowMissionListProps) {
return (
<div className={containerCss}>
<div>
<h2 className={headingCss}>
<span>미션 목록</span>
</h2>
Expand All @@ -34,7 +34,15 @@ const headingCss = flex({
color: 'text.primary',
});

const containerCss = css({});
const containerCss = css({
height: '100%',
width: '100%',
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
flexDirection: 'column',
padding: '60px 0',
});

const listCss = flex({
flexDirection: 'column',
Expand All @@ -54,7 +62,7 @@ export function MissionFollowListInner({ followId }: { followId: number }) {
if (!data || data.followMissions.length === 0) {
return (
<div className={containerCss}>
<MissionEmptyList />
<Empty type="notice" title={'아직 등록된 미션이 없어요.'} description={''} image={'docs'} />
</div>
);
}
Expand Down
2 changes: 1 addition & 1 deletion src/app/home/MissionEmptyList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ function MissionEmptyList() {

export default MissionEmptyList;

const containerCss = flex({ flex: 1, justifyContent: 'center', alignItems: 'center' });
const containerCss = flex({ justifyContent: 'center', alignItems: 'center' });
1 change: 1 addition & 0 deletions src/app/home/MissionInnerList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,5 @@ export default MissionListInner;

const containerCss = css({
height: '100%',
padding: '60px 0',
});

0 comments on commit c3abcfc

Please sign in to comment.