diff --git a/frontend/src/tabs/scat/components/ScatMap.tsx b/frontend/src/tabs/scat/components/ScatMap.tsx index 382258a..2bbc86b 100644 --- a/frontend/src/tabs/scat/components/ScatMap.tsx +++ b/frontend/src/tabs/scat/components/ScatMap.tsx @@ -5,7 +5,7 @@ import { PathLayer, ScatterplotLayer } from '@deck.gl/layers' import type { StyleSpecification } from 'maplibre-gl' import 'maplibre-gl/dist/maplibre-gl.css' import type { ScatSegment } from './scatTypes' -import { esiColor, jejuCoastCoords, scatDetailData } from './scatConstants' +import { esiColor, jejuCoastCoords } from './scatConstants' import { hexToRgba } from '@common/components/map/mapUtils' const BASE_STYLE: StyleSpecification = { @@ -102,7 +102,7 @@ function ScatMap({ segments, selectedSeg, onSelectSeg, onOpenPopup }: ScatMapPro const handleClick = useCallback( (seg: ScatSegment) => { onSelectSeg(seg) - onOpenPopup(seg.id % scatDetailData.length) + onOpenPopup(seg.id) }, [onSelectSeg, onOpenPopup], ) diff --git a/frontend/vite.config.ts b/frontend/vite.config.ts index ccf4196..2711f53 100755 --- a/frontend/vite.config.ts +++ b/frontend/vite.config.ts @@ -11,4 +11,11 @@ export default defineConfig({ '@tabs': path.resolve(__dirname, 'src/tabs'), }, }, + build: { + rollupOptions: { + // deck.gl → @loaders.gl/worker-utils가 Node.js child_process를 참조하나 + // 브라우저에서는 해당 코드 경로를 타지 않으므로 undefined shim 허용 + shimMissingExports: true, + }, + }, })