From de370d7f0c9fa01cbc4a7824fe74ce93eb29f5bb Mon Sep 17 00:00:00 2001 From: volodfast Date: Tue, 7 Feb 2023 17:29:11 +0200 Subject: [PATCH] feat: increase chart point visibility (#2185) --- frontend/src/components/Graph/index.tsx | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/frontend/src/components/Graph/index.tsx b/frontend/src/components/Graph/index.tsx index 20ffc5a22c..2b6435d106 100644 --- a/frontend/src/components/Graph/index.tsx +++ b/frontend/src/components/Graph/index.tsx @@ -240,6 +240,16 @@ function Graph({ tension: 0, cubicInterpolationMode: 'monotone', }, + point: { + // eslint-disable-next-line @typescript-eslint/no-explicit-any + hoverBackgroundColor: (ctx: any) => { + if (ctx?.element?.options?.borderColor) { + return ctx.element.options.borderColor; + } + return 'rgba(0,0,0,0.1)'; + }, + hoverRadius: 5, + }, }, onClick: (event, element, chart) => { if (onClickHandler) {