diff --git a/src/legacy/core_plugins/kbn_vislib_vis_types/public/components/options/gauge/ranges_panel.tsx b/src/legacy/core_plugins/kbn_vislib_vis_types/public/components/options/gauge/ranges_panel.tsx index e1dad7442f0aa..d22d1b8ee4b64 100644 --- a/src/legacy/core_plugins/kbn_vislib_vis_types/public/components/options/gauge/ranges_panel.tsx +++ b/src/legacy/core_plugins/kbn_vislib_vis_types/public/components/options/gauge/ranges_panel.tsx @@ -36,7 +36,7 @@ function RangesPanel({ uiState, vis, }: GaugeOptionsInternalProps) { - const [isCustomColors, setIsCustomColors] = useState(false); + const [isCustomColors, setIsCustomColors] = useState(() => !!uiState.get('vis.colors')); useEffect(() => { uiState.on('colorChanged', () => {