mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
OptionsUI: SliderValueEditor does not get auto focused on slider change (#59209)
This commit is contained in:
parent
220295d26f
commit
45d3125919
@ -87,7 +87,11 @@
|
|||||||
"ignoreNonDOM": true
|
"ignoreNonDOM": true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"jsx-a11y/no-static-element-interactions": "off"
|
"jsx-a11y/no-static-element-interactions": "off",
|
||||||
|
"jsx-a11y/label-has-associated-control": [ "error", {
|
||||||
|
"controlComponents": ["NumberInput"],
|
||||||
|
"depth": 2
|
||||||
|
}]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
@ -96,7 +96,7 @@ export const SliderValueEditor: React.FC<FieldConfigEditorProps<number, SliderFi
|
|||||||
<div className={cx(styles.container, styles.slider)}>
|
<div className={cx(styles.container, styles.slider)}>
|
||||||
{/** Slider tooltip's parent component is body and therefore we need Global component to do css overrides for it. */}
|
{/** Slider tooltip's parent component is body and therefore we need Global component to do css overrides for it. */}
|
||||||
<Global styles={styles.slider} />
|
<Global styles={styles.slider} />
|
||||||
<div className={cx(styles.sliderInput, ...sliderInputClassNames)}>
|
<label className={cx(styles.sliderInput, ...sliderInputClassNames)}>
|
||||||
<Slider
|
<Slider
|
||||||
min={min}
|
min={min}
|
||||||
max={max}
|
max={max}
|
||||||
@ -113,7 +113,7 @@ export const SliderValueEditor: React.FC<FieldConfigEditorProps<number, SliderFi
|
|||||||
<span className={stylesSlider.numberInputWrapper} ref={inputRef}>
|
<span className={stylesSlider.numberInputWrapper} ref={inputRef}>
|
||||||
<NumberInput value={sliderValue} onChange={onSliderInputChange} max={max} min={min} step={step} />
|
<NumberInput value={sliderValue} onChange={onSliderInputChange} max={max} min={min} step={step} />
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user