Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
  • Loading branch information
andire120 committed Jan 8, 2025
1 parent 613c3cb commit f8696e8
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/routes/oven/(time)/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
import { page } from '$app/stores';
import { onMount } from 'svelte';
const ASSETS_PREFIX = '/src/public/element/otherthing/otherelement';
const BASE_PATH = '/src/public/element/otherthing/otherelement'; // public 폴더 내부 경로만 지정
// 이미지 경로를 동적으로 생성하는 함수
const getImagePath = (filename) => `${BASE_PATH}/${filename}`;
import background from "/src/public/element/otherthing/otherelement/background.png";
import next from '/src/public/element/otherthing/otherelement/nextbotten.png';
Expand All @@ -12,10 +15,10 @@
import danger from '/src/public/element/otherthing/otherelement/choseoven.png';
const ovenImages = {
'thr': `${ASSETS_PREFIX}/oven1.png`,
'one': `${ASSETS_PREFIX}/oven2.png`,
'onethr': `${ASSETS_PREFIX}/oven3.png`,
'eig': `${ASSETS_PREFIX}/oven4.png`
'thr': getImagePath('oven1.png'),
'one': getImagePath('oven2.png'),
'onethr': getImagePath('oven3.png'),
'eig': getImagePath('oven4.png'),
};
const timeMapping = {
Expand Down

0 comments on commit f8696e8

Please sign in to comment.