add map selection..

This commit is contained in:
2026-08-12 15:40:08 +09:00
parent c010d0c913
commit 54d3eb7014
3 changed files with 8 additions and 3 deletions
+2 -2
View File
@@ -819,7 +819,7 @@ function LocalPcWorkspaceMockup({
{ {
key: 'nav2-platform-slam-2d', key: 'nav2-platform-slam-2d',
platformKey: 'NAV2', platformKey: 'NAV2',
name: '새 2D SLAM', name: '새 2D 맵',
description: '2D LiDAR로 새 지도를 생성합니다.', description: '2D LiDAR로 새 지도를 생성합니다.',
worldFile: '', worldFile: '',
viewerModel: 'turtlebot3_world', viewerModel: 'turtlebot3_world',
@@ -829,7 +829,7 @@ function LocalPcWorkspaceMockup({
{ {
key: 'nav2-platform-slam-3d', key: 'nav2-platform-slam-3d',
platformKey: 'NAV2', platformKey: 'NAV2',
name: '새 3D SLAM', name: '새 3D 맵',
description: '3D LiDAR 포인트 클라우드로 새 지도를 생성합니다.', description: '3D LiDAR 포인트 클라우드로 새 지도를 생성합니다.',
worldFile: '', worldFile: '',
viewerModel: 'turtlebot3_world', viewerModel: 'turtlebot3_world',
@@ -218,7 +218,7 @@ export default function ModuleListView({
<div className="flex min-w-0 items-center gap-2"> <div className="flex min-w-0 items-center gap-2">
<div className="min-w-0 text-right"> <div className="min-w-0 text-right">
<span className={['block text-[10px] font-bold', dark ? 'text-white/40' : 'text-[#788396]'].join(' ')}>현재 맵</span> <span className={['block text-[10px] font-bold', dark ? 'text-white/40' : 'text-[#788396]'].join(' ')}>현재 맵</span>
<strong className={['block max-w-[176px] truncate text-[12px] font-bold', dark ? 'text-white/85' : 'text-[#263247]'].join(' ')}>{selectedMap.name}</strong> <strong className={['block max-w-[176px] truncate text-[12px] font-bold', dark ? 'text-white/85' : 'text-[#263247]'].join(' ')}>{selectedMap.name} ({selectedMap.saved ? '주행' : 'SLAM'})</strong>
</div> </div>
<WorkspaceMapPreview map={selectedMap} selected={false} compact borderless /> <WorkspaceMapPreview map={selectedMap} selected={false} compact borderless />
</div> </div>
@@ -241,6 +241,7 @@ export default function WorldMapSelectorModal({ weekNumber, initialScope = 'simu
const mapDimension = map.saved const mapDimension = map.saved
? (map.runtimeKind === 'PLATFORM_3D' ? '3D' : '2D') ? (map.runtimeKind === 'PLATFORM_3D' ? '3D' : '2D')
: null : null
const mapUsage = map.saved ? '주행' : 'SLAM'
return ( return (
<button <button
key={map.key} key={map.key}
@@ -263,6 +264,10 @@ export default function WorldMapSelectorModal({ weekNumber, initialScope = 'simu
)} )}
</span> </span>
<span className="mt-1 block text-[12px] leading-5 text-white/50">{map.description}</span> <span className="mt-1 block text-[12px] leading-5 text-white/50">{map.description}</span>
<span className={[
'mt-1.5 inline-flex rounded px-1.5 py-0.5 text-[10px] font-bold',
mapUsage === '주행' ? 'bg-emerald-400/15 text-emerald-200' : 'bg-sky-400/15 text-sky-200',
].join(' ')}>{mapUsage}</span>
</span> </span>
{map.saved && map.createdAt && <span className="absolute bottom-3 right-4 text-[11px] font-medium text-white/35">{new Date(map.createdAt).toLocaleString('ko-KR', { dateStyle: 'short', timeStyle: 'short' })}</span>} {map.saved && map.createdAt && <span className="absolute bottom-3 right-4 text-[11px] font-medium text-white/35">{new Date(map.createdAt).toLocaleString('ko-KR', { dateStyle: 'short', timeStyle: 'short' })}</span>}
{selected && <Check className="absolute right-4 top-3 size-4 text-[#7eabff]" />} {selected && <Check className="absolute right-4 top-3 size-4 text-[#7eabff]" />}