(
seriesIndex: number,
dataIndex: number,
point: OHLCDataPoint
)
| 2389 | }; |
| 2390 | |
| 2391 | const buildCandlestickTooltipParams = ( |
| 2392 | seriesIndex: number, |
| 2393 | dataIndex: number, |
| 2394 | point: OHLCDataPoint |
| 2395 | ): TooltipParams => { |
| 2396 | const s = currentOptions.series[seriesIndex]; |
| 2397 | if (isTupleOHLCDataPoint(point)) { |
| 2398 | return { |
| 2399 | seriesName: s?.name ?? '', |
| 2400 | seriesIndex, |
| 2401 | dataIndex, |
| 2402 | value: [point[0], point[1], point[2], point[3], point[4]] as const, |
| 2403 | color: s?.color ?? '#888', |
| 2404 | }; |
| 2405 | } else { |
| 2406 | return { |
| 2407 | seriesName: s?.name ?? '', |
| 2408 | seriesIndex, |
| 2409 | dataIndex, |
| 2410 | value: [point.timestamp, point.open, point.close, point.low, point.high] as const, |
| 2411 | color: s?.color ?? '#888', |
| 2412 | }; |
| 2413 | } |
| 2414 | }; |
| 2415 | |
| 2416 | // Helper: Find pie slice at pointer position (extracted to avoid duplication) |
| 2417 | const findPieSliceAtPointer = ( |
no test coverage detected