(color: string | undefined, opacity: number | undefined)
| 3390 | const plotHeightCss = Math.max(0, plotBottomCss - plotTopCss); |
| 3391 | |
| 3392 | const resolveAnnotationRgba = (color: string | undefined, opacity: number | undefined): readonly [number, number, number, number] => { |
| 3393 | const base = |
| 3394 | parseCssColorToRgba01(color ?? currentOptions.theme.textColor) ?? |
| 3395 | parseCssColorToRgba01(currentOptions.theme.textColor) ?? |
| 3396 | ([1, 1, 1, 1] as const); |
| 3397 | const o = opacity == null ? 1 : clamp01(opacity); |
| 3398 | return [clamp01(base[0]), clamp01(base[1]), clamp01(base[2]), clamp01(base[3] * o)] as const; |
| 3399 | }; |
| 3400 | |
| 3401 | const annotations: ReadonlyArray<AnnotationConfig> = hasCartesianSeries ? (currentOptions.annotations ?? []) : []; |
| 3402 |
no test coverage detected