diff --git a/frontend/src/container/GridGraphComponent/index.tsx b/frontend/src/container/GridGraphComponent/index.tsx index 7c1572fae1..3ca7f4f544 100644 --- a/frontend/src/container/GridGraphComponent/index.tsx +++ b/frontend/src/container/GridGraphComponent/index.tsx @@ -1,6 +1,7 @@ import { Typography } from 'antd'; import { ChartData } from 'chart.js'; import Graph, { graphOnClickHandler } from 'components/Graph'; +import { getYAxisFormattedValue } from 'components/Graph/yAxisConfig'; import ValueGraph from 'components/ValueGraph'; import { GRAPH_TYPES } from 'container/NewDashboard/ComponentsSlider'; import history from 'lib/history'; @@ -57,7 +58,11 @@ function GridGraphComponent({ {title} - + ); diff --git a/frontend/src/container/NewWidget/RightContainer/YAxisUnitSelector.tsx b/frontend/src/container/NewWidget/RightContainer/YAxisUnitSelector.tsx index d8202d6fdb..1af32aff45 100644 --- a/frontend/src/container/NewWidget/RightContainer/YAxisUnitSelector.tsx +++ b/frontend/src/container/NewWidget/RightContainer/YAxisUnitSelector.tsx @@ -9,7 +9,7 @@ const findCategoryById = (searchValue) => const findCategoryByName = (searchValue) => find(flattenedCategories, (option) => option.name == searchValue); -function YAxisUnitSelector({ defaultValue, onSelect }): JSX.Element { +function YAxisUnitSelector({ defaultValue, onSelect, fieldLabel }): JSX.Element { const onSelectHandler = (selectedValue: string): void => { onSelect(findCategoryByName(selectedValue)?.id); }; @@ -19,7 +19,7 @@ function YAxisUnitSelector({ defaultValue, onSelect }): JSX.Element { return (
- Y Axis Unit + {fieldLabel}
- + ); }