From ff707705e3409f45c2fefd06910ecd02ee1ae442 Mon Sep 17 00:00:00 2001 From: Macbook Date: Wed, 24 Jun 2026 00:23:25 +0900 Subject: [PATCH] =?UTF-8?q?=EC=A0=84=EB=9E=B5=ED=8F=89=EA=B0=80=20?= =?UTF-8?q?=ED=99=94=EB=A9=B4=20=EC=BA=94=EB=93=A4=20=EC=84=A0=ED=83=9D?= =?UTF-8?q?=EB=B4=89=20=EC=9D=B4=EB=8F=99=EC=8B=9C=20=EC=9C=84=EC=B9=98?= =?UTF-8?q?=EA=B3=A0=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StrategyEvaluationChart.tsx | 21 ------------------- 1 file changed, 21 deletions(-) diff --git a/frontend/src/components/strategyEvaluation/StrategyEvaluationChart.tsx b/frontend/src/components/strategyEvaluation/StrategyEvaluationChart.tsx index a963527..1d3158c 100644 --- a/frontend/src/components/strategyEvaluation/StrategyEvaluationChart.tsx +++ b/frontend/src/components/strategyEvaluation/StrategyEvaluationChart.tsx @@ -531,27 +531,6 @@ const StrategyEvaluationChart: React.FC = ({ emitEvalWindowMeta, ]); - const scrollToBar = useCallback((barIdx: number) => { - const mgr = managerRef.current; - if (!mgr?.hasMainSeries() || barIdx < 0 || barIdx >= bars.length) return; - const bar = bars[barIdx]; - const barSec = timeframeBarSeconds(timeframe); - const pad = Math.max(barSec * 48, 3600); - mgr.applyVisibleTimeRange(bar.time - pad, bar.time + Math.max(barSec * 8, 600)); - }, [bars, timeframe]); - - const prevSelectedBarIndexRef = useRef(selectedBarIndex); - useEffect(() => { - prevSelectedBarIndexRef.current = -1; - }, [market, timeframe, strategy?.id, paramsRevision]); - - useEffect(() => { - if (bars.length === 0) return; - if (prevSelectedBarIndexRef.current === selectedBarIndex) return; - prevSelectedBarIndexRef.current = selectedBarIndex; - scrollToBar(selectedBarIndex); - }, [selectedBarIndex, bars.length, scrollToBar]); - const onManagerReady = useCallback((mgr: ChartManager) => { managerRef.current = mgr; setChartMgr(mgr);