TimelineChart: Fix rendering of small boxes (#72775) (#80420)

This commit is contained in:
Tamás Nyíri
2024-01-12 19:59:46 +01:00
committed by GitHub
parent 235c747472
commit 11662e18b3

View File

@@ -133,10 +133,8 @@ export function getConfig(opts: TimelineCoreOptions) {
value: number | null,
discrete: boolean
) {
// do not render super small boxes
if (boxWidth < 1) {
return;
}
// clamp width to allow small boxes to be rendered
boxWidth = Math.max(1, boxWidth);
const valueColor = getValueColor(seriesIdx + 1, value);
const fieldConfig = getFieldConfig(seriesIdx);