File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import { Box , styled , useTheme } from '@mui/material'
22
33import { getColor } from '../svg'
4- import { ColorMode , EFPData , EFPState } from '../types'
4+ import { ColorMode , EFPData } from '../types'
55
66interface ILegendProps {
77 data : EFPData
@@ -18,6 +18,11 @@ export default styled(function Legend({
1818 ...rest
1919} : ILegendProps ) {
2020 const theme = useTheme ( )
21+ // TODO: legend uses data.control (cross-group average) and data.min/max as a
22+ // global approximation. This can diverge from per-group colours when groups
23+ // have different controls. A per-group legend is out of scope for this fix.
24+ // I.e. The colours may not line up in this commit/PR due to group colours being different
25+ // than the global legend
2126 const control = data . control ?? 1
2227 const values = Array ( GRADIENT_STEPS )
2328 . fill ( 0 )
You can’t perform that action at this time.
0 commit comments