mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-11 00:08:30 +01:00
fix: display tick values for chart Y axis (#8412)
This PR adds back in ticks for the Y axis of the chart. The ticks were removed when updating the no content chart and this was an oversight.
This commit is contained in:
parent
4130b9b143
commit
42d5eeb7e5
@ -7,6 +7,7 @@ import {
|
|||||||
formatDateYMD,
|
formatDateYMD,
|
||||||
formatDateYMDHM,
|
formatDateYMDHM,
|
||||||
} from '../../utils/formatDate';
|
} from '../../utils/formatDate';
|
||||||
|
import { formatTickValue } from 'component/common/Chart/formatTickValue';
|
||||||
|
|
||||||
const formatVariantEntry = (
|
const formatVariantEntry = (
|
||||||
variant: [string, number],
|
variant: [string, number],
|
||||||
@ -168,7 +169,15 @@ export const createBarChartOptions = (
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
y: scales ? scales.y : {},
|
y: {
|
||||||
|
...(scales?.y ?? {}),
|
||||||
|
ticks: {
|
||||||
|
...(scales?.y?.ticks ?? {}),
|
||||||
|
color: theme.palette.text.secondary,
|
||||||
|
callback: formatTickValue,
|
||||||
|
display: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
elements,
|
elements,
|
||||||
interaction,
|
interaction,
|
||||||
|
Loading…
Reference in New Issue
Block a user