mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Fix light theme issues with named colors disabled
This commit is contained in:
parent
f01441f4a7
commit
e75b0a3c70
@ -37,13 +37,13 @@ export class ColorPickerPopover<T extends CustomPickersDescriptor> extends React
|
||||
};
|
||||
|
||||
handleChange = (color: any) => {
|
||||
const { onColorChange, onChange, enableNamedColors } = this.props;
|
||||
const { onColorChange, onChange, enableNamedColors, theme } = this.props;
|
||||
const changeHandler = onColorChange || onChange;
|
||||
|
||||
if (enableNamedColors) {
|
||||
return changeHandler(color);
|
||||
}
|
||||
changeHandler(getColorFromHexRgbOrName(color));
|
||||
changeHandler(getColorFromHexRgbOrName(color, theme));
|
||||
};
|
||||
|
||||
handleTabChange = (tab: PickerType | keyof T, updatePopperPosition?: () => void) => {
|
||||
|
Loading…
Reference in New Issue
Block a user