Skip to content

Commit 3a3b318

Browse files
committed
feat: 설문 없을 때 배경 이미지 적용
1 parent 70d1e01 commit 3a3b318

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

public/images/survey/base.webp

1.98 MB
Binary file not shown.

src/pages/survey/base.page.tsx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { type NextPage } from 'next';
2+
import Image from 'next/image';
23
import Link from 'next/link';
34
import { css, type Theme } from '@emotion/react';
45

@@ -19,6 +20,10 @@ const SurveyBasePage: NextPage = () => {
1920
<Link href="/survey/create" css={linkCss}>
2021
<Button color="blue">폼 생성하기</Button>
2122
</Link>
23+
24+
<div css={backgroundImageWrapperCss}>
25+
<Image quality={100} src="/images/survey/base.webp" alt="배경" fill objectFit="cover" />
26+
</div>
2227
</main>
2328

2429
<BottomBar />
@@ -49,3 +54,13 @@ const h1Css = (theme: Theme) => css`
4954
const linkCss = css`
5055
text-decoration: none;
5156
`;
57+
58+
const backgroundImageWrapperCss = (theme: Theme) => css`
59+
position: absolute;
60+
z-index: ${theme.zIndex.belowDefault};
61+
top: 0;
62+
left: 0;
63+
64+
width: 100%;
65+
height: 100%;
66+
`;

0 commit comments

Comments
 (0)