실시간 지도 마커 업데이트 구현 및 마커 종류에 트럭 추가

This commit is contained in:
dohyeons
2025-11-17 15:05:59 +09:00
parent 227ab1904c
commit 542f2ccc96
5 changed files with 160 additions and 73 deletions

View File

@@ -455,7 +455,10 @@ export function WidgetConfigSidebar({ element, isOpen, onClose, onApply }: Widge
<Label htmlFor="refresh-interval" className="mb-2 block text-xs font-semibold">
</Label>
<Select value={refreshInterval.toString()} onValueChange={(value) => setRefreshInterval(parseInt(value))}>
<Select
value={refreshInterval.toString()}
onValueChange={(value) => setRefreshInterval(parseInt(value))}
>
<SelectTrigger id="refresh-interval" className="h-9 text-sm">
<SelectValue placeholder="간격 선택" />
</SelectTrigger>
@@ -605,20 +608,20 @@ export function WidgetConfigSidebar({ element, isOpen, onClose, onApply }: Widge
<Button variant="outline" onClick={onClose} className="h-9 flex-1 text-sm">
</Button>
<Button
onClick={handleApply}
<Button
onClick={handleApply}
className="h-9 flex-1 text-sm"
disabled={
// 다중 데이터 소스 위젯: 데이터 소스가 있는데 endpoint가 비어있으면 비활성화
// (데이터 소스가 없는 건 OK - 연결 해제하는 경우)
(element?.subtype === "map-summary-v2" ||
element?.subtype === "chart" ||
element?.subtype === "list-v2" ||
element?.subtype === "custom-metric-v2" ||
element?.subtype === "risk-alert-v2") &&
dataSources &&
dataSources.length > 0 &&
dataSources.some(ds => ds.type === "api" && !ds.endpoint)
(element?.subtype === "map-summary-v2" ||
element?.subtype === "chart" ||
element?.subtype === "list-v2" ||
element?.subtype === "custom-metric-v2" ||
element?.subtype === "risk-alert-v2") &&
dataSources &&
dataSources.length > 0 &&
dataSources.some((ds) => ds.type === "api" && !ds.endpoint)
}
>