From 6c86ce82a99de0e374946b010baa45297df73755 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20Zag=C3=B3rski?= Date: Wed, 27 Sep 2023 10:54:14 +0200 Subject: [PATCH] fix timeseries chart xAxis label styling --- .../components/TimeSeriesChart.js | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/packages/react-ui/src/widgets/TimeSeriesWidgetUI/components/TimeSeriesChart.js b/packages/react-ui/src/widgets/TimeSeriesWidgetUI/components/TimeSeriesChart.js index 3880b0a2e..bf212ec61 100644 --- a/packages/react-ui/src/widgets/TimeSeriesWidgetUI/components/TimeSeriesChart.js +++ b/packages/react-ui/src/widgets/TimeSeriesWidgetUI/components/TimeSeriesChart.js @@ -80,6 +80,20 @@ export default function TimeSeriesChart({ opacity: 0.2 } }, + axisLabel: { + fontSize: theme.typography.caption.fontSize, + fontFamily: theme.typography.caption.fontFamily, + fontWeight: theme.typography.fontWeightRegular, + // https://echarts.apache.org/en/option.html#xAxis.axisLabel.formatter + formatter: { + year: '{yearStyle|{yyyy}}' + }, + rich: { + yearStyle: { + fontWeight: theme.typography.fontWeightMedium + } + } + }, axisTick: { show: false },