실시간 차트 보조지표 값 소수점 표시

This commit is contained in:
Macbook
2026-05-30 10:39:50 +09:00
parent 33c2d4b337
commit c7ba13e7ed
23 changed files with 226 additions and 40 deletions
+23 -6
View File
@@ -634,6 +634,7 @@ function App() {
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [appSettingsLoaded, dbLoaded]);
const chartCandleAreaPriceLabels = appDefaults.chartCandleAreaPriceLabels ?? true;
const chartSeriesPriceLabels = appDefaults.chartSeriesPriceLabels ?? true;
const chartVolumeVisible = appDefaults.chartVolumeVisible ?? true;
const chartLiveReceiveHighlight = appDefaults.chartLiveReceiveHighlight ?? true;
@@ -1007,9 +1008,13 @@ function App() {
useEffect(() => {
if (!appSettingsLoaded) return;
managerRef.current?.setSeriesPriceLabelsEnabled(chartSeriesPriceLabels);
slotRefs.current.forEach(slot => slot?.setSeriesPriceLabelsEnabled(chartSeriesPriceLabels));
}, [appSettingsLoaded, chartSeriesPriceLabels]);
managerRef.current?.setCandleAreaPriceLabelsEnabled(chartCandleAreaPriceLabels);
managerRef.current?.setIndicatorAreaPriceLabelsEnabled(chartSeriesPriceLabels);
slotRefs.current.forEach(slot => {
slot?.setCandleAreaPriceLabelsEnabled(chartCandleAreaPriceLabels);
slot?.setIndicatorAreaPriceLabelsEnabled(chartSeriesPriceLabels);
});
}, [appSettingsLoaded, chartCandleAreaPriceLabels, chartSeriesPriceLabels]);
useEffect(() => {
if (!appSettingsLoaded) return;
@@ -1789,6 +1794,7 @@ function App() {
<TrendSearchPage
theme={theme}
chartRealtimeSource={(appDefaults.chartRealtimeSource ?? 'BACKEND_STOMP') as ChartRealtimeSource}
chartCandleAreaPriceLabels={appDefaults.chartCandleAreaPriceLabels}
chartSeriesPriceLabels={appDefaults.chartSeriesPriceLabels}
tickers={marketTickers}
/>
@@ -1858,11 +1864,17 @@ function App() {
onAddIndicatorToChart={handleAddIndicator}
onRemoveIndicatorFromChart={handleRemoveByType}
onIndicatorListOrderChange={handleIndicatorListOrderChange}
chartCandleAreaPriceLabels={chartCandleAreaPriceLabels}
onChartCandleAreaPriceLabels={v => {
saveAppDef({ chartCandleAreaPriceLabels: v });
managerRef.current?.setCandleAreaPriceLabelsEnabled(v);
slotRefs.current.forEach(slot => slot?.setCandleAreaPriceLabelsEnabled(v));
}}
chartSeriesPriceLabels={chartSeriesPriceLabels}
onChartSeriesPriceLabels={v => {
saveAppDef({ chartSeriesPriceLabels: v });
managerRef.current?.setSeriesPriceLabelsEnabled(v);
slotRefs.current.forEach(slot => slot?.setSeriesPriceLabelsEnabled(v));
managerRef.current?.setIndicatorAreaPriceLabelsEnabled(v);
slotRefs.current.forEach(slot => slot?.setIndicatorAreaPriceLabelsEnabled(v));
}}
chartVolumeVisible={chartVolumeVisible}
onChartVolumeVisible={v => {
@@ -2201,6 +2213,7 @@ function App() {
onSymbolChange={activeSlot === 0 ? handleActiveSlotSymbolChange : undefined}
magnetMode={magnetMode}
onTradeOrderRequest={(req, idx) => applyTradeFill(req, idx)}
chartCandleAreaPriceLabels={chartCandleAreaPriceLabels}
chartSeriesPriceLabels={chartSeriesPriceLabels}
chartVolumeVisible={chartVolumeVisible}
chartPaneSeparator={chartPaneSeparator}
@@ -2242,6 +2255,7 @@ function App() {
onSymbolChange={activeSlot === i + 1 ? handleActiveSlotSymbolChange : undefined}
magnetMode={magnetMode}
onTradeOrderRequest={(req, idx) => applyTradeFill(req, idx)}
chartCandleAreaPriceLabels={chartCandleAreaPriceLabels}
chartSeriesPriceLabels={chartSeriesPriceLabels}
chartVolumeVisible={chartVolumeVisible}
chartPaneSeparator={chartPaneSeparator}
@@ -2301,7 +2315,8 @@ function App() {
} else {
pendingRealtimeBarRef.current = null;
}
mgr.setSeriesPriceLabelsEnabled(chartSeriesPriceLabels);
mgr.setCandleAreaPriceLabelsEnabled(chartCandleAreaPriceLabels);
mgr.setIndicatorAreaPriceLabelsEnabled(chartSeriesPriceLabels);
const wrapper = document.querySelector('.chart-wrapper') as HTMLElement | null;
mgr.setVolumeVisible(chartVolumeVisible, wrapper?.clientHeight);
mgr.setPaneSeparatorOptions(chartPaneSeparator);
@@ -2347,6 +2362,8 @@ function App() {
onToggleIndicatorHidden={handleToggleIndicatorHidden}
onOpenIndicatorSettings={id => setSettingsModalId(id)}
volumeVisible={chartVolumeVisible}
candleAreaPriceLabelsEnabled={chartCandleAreaPriceLabels}
indicatorAreaPriceLabelsEnabled={chartSeriesPriceLabels}
paneSeparatorOptions={chartPaneSeparator}
/>
{isSingleLoadingMore && (