주가 표시형식 수정
This commit is contained in:
@@ -7,12 +7,11 @@ import { formatNowClock, useDisplayTimezone } from '../utils/timezone';
|
||||
import type { OrderbookDisplayUnit, WsStatus } from '../hooks/useUpbitOrderbook';
|
||||
import type { RecentTrade } from '../hooks/useUpbitRecentTrades';
|
||||
import { getKoreanName } from '../utils/marketNameCache';
|
||||
import { formatUpbitKrwPrice } from '../utils/safeFormat';
|
||||
|
||||
function fmtPrice(p: number): string {
|
||||
if (p == null || !isFinite(p)) return '-';
|
||||
if (p >= 1_000) return p.toLocaleString('ko-KR', { maximumFractionDigits: 0 });
|
||||
if (p >= 1) return p.toFixed(2);
|
||||
return p.toFixed(6);
|
||||
return formatUpbitKrwPrice(p, '-');
|
||||
}
|
||||
|
||||
function fmtSize(s: number): string {
|
||||
|
||||
Reference in New Issue
Block a user