Skip to content

Commit e11d895

Browse files
committed
fix: img.d.ts 내 png 모듈 타입 선언 추가
1 parent 3fc258a commit e11d895

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/app/test/result/page.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import MateImage from '@assets/images/test/test_img_large_EAJ.png';
99
import KakaoBtn from '@components/common/button/kakaoBtn/KakaoBtn';
1010
import Bubble from '@components/common/bubble/Bubble';
1111
import ResultCard from '@components/test/resultCard/ResultCard';
12-
import bgImage from '@assets/images/test/test_result_img.png';
1312

1413
const ResultPage = () => {
1514
const text = `누가 뭐 하자고 해도 잠깐의 망설임이 먼저 찾아와요.\n조용한 카페 창가 자리나 집 안의 오후 햇살처럼, 잔잔한 순간에 마음이 풀려요.\n시끌벅적한 대화보다 차 한 잔의 여유가 훨씬 오래 남는 편이에요.\n그래서 명상이나 차담 같은 고요한 프로그램이 잘 어울려요.\n누군가와 대화하지 않아도 그 공간이 나를 이해해 주는 느낌이 드니까요.`;
@@ -19,7 +18,7 @@ const ResultPage = () => {
1918

2019
return (
2120
<div className={styles.page}>
22-
<section className={styles.resultSection} style={{ backgroundImage: `url(${bgImage.src})` }}>
21+
<section className={styles.resultSection}>
2322
<h1 className={styles.title}>잔잔호수형 목탁이</h1>
2423
<h3 className={styles.subtitle}>차분하면서도 편안한 곳을 좋아해요.</h3>
2524

src/img.d.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,9 @@ declare module '*.svg' {
22
const ReactComponent: React.FC<React.SVGProps<SVGSVGElement>>;
33
export default ReactComponent;
44
}
5+
6+
declare module '*.png' {
7+
import { StaticImageData } from 'next/image';
8+
const content: StaticImageData;
9+
export default content;
10+
}

0 commit comments

Comments
 (0)