From ebbfe22e8b8e1c0e6a42bb83ff72a970ae7fd40b Mon Sep 17 00:00:00 2001 From: Raj Dangol Date: Fri, 8 Mar 2024 13:08:35 -0600 Subject: [PATCH 1/3] restore y-axis label in the analysis page --- app/scripts/components/common/chart/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/scripts/components/common/chart/index.tsx b/app/scripts/components/common/chart/index.tsx index 99ce48d43..25a99157a 100644 --- a/app/scripts/components/common/chart/index.tsx +++ b/app/scripts/components/common/chart/index.tsx @@ -233,7 +233,7 @@ export default forwardRef( className='label-y' value={yAxisLabel} angle={-90} - position='left' + position='insideLeft' /> {renderHighlight && ( From 2848caf432e9f18ac7cbd0d71fe0c866535f3168 Mon Sep 17 00:00:00 2001 From: Raj Dangol Date: Fri, 8 Mar 2024 18:55:57 -0600 Subject: [PATCH 2/3] added width to y axis and offset to label to remove overlapping and label cutoff issue --- app/scripts/components/common/chart/constant.js | 3 +++ app/scripts/components/common/chart/index.tsx | 7 +++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/app/scripts/components/common/chart/constant.js b/app/scripts/components/common/chart/constant.js index 6d7573777..0d5a78969 100644 --- a/app/scripts/components/common/chart/constant.js +++ b/app/scripts/components/common/chart/constant.js @@ -26,3 +26,6 @@ export const brushRelatedConfigs = { labelOffset: -5 } }; + +export const chartYAxisWidth = 80; +export const chartLabelOffset = 8; \ No newline at end of file diff --git a/app/scripts/components/common/chart/index.tsx b/app/scripts/components/common/chart/index.tsx index 25a99157a..1eafd6a0e 100644 --- a/app/scripts/components/common/chart/index.tsx +++ b/app/scripts/components/common/chart/index.tsx @@ -32,7 +32,9 @@ import { highlightColor, legendWidth, brushRelatedConfigs, - brushHeight + brushHeight, + chartYAxisWidth, + chartLabelOffset } from './constant'; import { ChartWrapperRef } from './analysis/utils'; import BrushCustom from './analysis/brush'; @@ -228,12 +230,13 @@ export default forwardRef( position='bottom' /> - getNumForChart(t)}> + getNumForChart(t)}> {renderHighlight && ( From 61af758eedec76d2c1cda0542cc44516d3b988b0 Mon Sep 17 00:00:00 2001 From: Raj Dangol Date: Fri, 8 Mar 2024 19:15:52 -0600 Subject: [PATCH 3/3] fixed lint issue --- app/scripts/components/common/chart/constant.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/scripts/components/common/chart/constant.js b/app/scripts/components/common/chart/constant.js index 0d5a78969..2bcfe4c9b 100644 --- a/app/scripts/components/common/chart/constant.js +++ b/app/scripts/components/common/chart/constant.js @@ -28,4 +28,4 @@ export const brushRelatedConfigs = { }; export const chartYAxisWidth = 80; -export const chartLabelOffset = 8; \ No newline at end of file +export const chartLabelOffset = 8;