From a9806d3f5eee5872633ead71ec125bcaed13ec30 Mon Sep 17 00:00:00 2001 From: Macbook Date: Tue, 2 Jun 2026 12:42:29 +0900 Subject: [PATCH] =?UTF-8?q?=EB=94=94=EB=B2=84=EA=B7=B8:=20maxPriceDiff=20?= =?UTF-8?q?=EB=B0=8F=20=EC=A4=91=EA=B0=84/=EB=A7=88=EC=A7=80=EB=A7=89=20?= =?UTF-8?q?=EB=8D=B0=EC=9D=B4=ED=84=B0=20=ED=8F=AC=EC=9D=B8=ED=8A=B8=20?= =?UTF-8?q?=EB=A1=9C=EA=B7=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Cursor --- frontend/src/utils/IchimokuCloudPlugin.ts | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/frontend/src/utils/IchimokuCloudPlugin.ts b/frontend/src/utils/IchimokuCloudPlugin.ts index a6da9ee..1dc76cd 100644 --- a/frontend/src/utils/IchimokuCloudPlugin.ts +++ b/frontend/src/utils/IchimokuCloudPlugin.ts @@ -71,18 +71,14 @@ class CloudRenderer implements IPrimitivePaneRenderer { // eslint-disable-next-line @typescript-eslint/no-explicit-any target.useBitmapCoordinateSpace(({ context: ctx, horizontalPixelRatio: hpr, verticalPixelRatio: vpr }: any) => { - // 첫 번째 데이터 포인트 좌표 확인 - const d0 = this._data[0]; - const d1 = this._data[1]; - const tx0 = timeScale.timeToCoordinate(d0.time as Time); - const tx1 = timeScale.timeToCoordinate(d1.time as Time); - const ay0 = this._series.priceToCoordinate(d0.spanA); - const by0 = this._series.priceToCoordinate(d0.spanB); - console.log('[IchimokuCloud] coords: x0=', tx0, 'x1=', tx1, - 'spanA_price=', d0.spanA, 'spanA_y=', ay0, - 'spanB_price=', d0.spanB, 'spanB_y=', by0, - 'hpr=', hpr, 'vpr=', vpr, - 'canvas_w=', ctx.canvas?.width, 'canvas_h=', ctx.canvas?.height); + // spanA/spanB 차이 진단 + const maxPriceDiff = Math.max(...this._data.map(d => Math.abs(d.spanA - d.spanB))); + const mid = this._data[Math.floor(this._data.length / 2)]; + const last = this._data[this._data.length - 1]; + console.log('[IchimokuCloud] DATA CHECK: maxPriceDiff=', maxPriceDiff, + '| mid[', Math.floor(this._data.length / 2), '] spanA=', mid.spanA, 'spanB=', mid.spanB, + '| last spanA=', last.spanA, 'spanB=', last.spanB, + 'canvas_w=', ctx.canvas?.width, 'canvas_h=', ctx.canvas?.height, 'hpr=', hpr, 'vpr=', vpr); let drawn = 0, skippedTime = 0, skippedPrice = 0; for (let i = 0; i < this._data.length - 1; i++) {