diff --git a/jsapp/js/components/reports/chartColorsPicker.component.tsx b/jsapp/js/components/reports/chartColorsPicker.component.tsx index 315a536414..a111a768b4 100644 --- a/jsapp/js/components/reports/chartColorsPicker.component.tsx +++ b/jsapp/js/components/reports/chartColorsPicker.component.tsx @@ -1,7 +1,7 @@ import React from 'react'; import bem from 'js/bem'; -import {REPORT_COLOR_SETS} from './reportsConstants'; -import type {ReportStyle, ReportColorSet} from './reportsConstants'; +import {CHART_COLOR_SETS} from './reportsConstants'; +import type {ReportStyle, ChartColorSet} from './reportsConstants'; interface ChartColorsPickerProps { onChange: (params: {default: boolean}, value: {report_colors: string[]}) => void; @@ -10,9 +10,9 @@ interface ChartColorsPickerProps { export default function ChartColorsPicker(props: ChartColorsPickerProps) { function defaultReportColorsChange(value: number) { - let newColors = REPORT_COLOR_SETS[0].colors; - if (REPORT_COLOR_SETS[value]?.colors) { - newColors = REPORT_COLOR_SETS[value].colors; + let newColors = CHART_COLOR_SETS[0].colors; + if (CHART_COLOR_SETS[value]?.colors) { + newColors = CHART_COLOR_SETS[value].colors; } props.onChange({default: true}, {report_colors: newColors}); @@ -20,7 +20,7 @@ export default function ChartColorsPicker(props: ChartColorsPickerProps) { // Not sure why this is called "is default", and not simply "is active". This // needs some more investigation. - function isDefaultValue(set: ReportColorSet, index: number) { + function isDefaultValue(set: ChartColorSet, index: number) { if (props.defaultStyle.report_colors === undefined && index === 0) { return true; } @@ -33,7 +33,7 @@ export default function ChartColorsPicker(props: ChartColorsPickerProps) { return ( - {REPORT_COLOR_SETS.map((set, index) => ( + {CHART_COLOR_SETS.map((set, index) => (