mirror of
https://github.com/Unleash/unleash.git
synced 2025-07-31 13:47:02 +02:00
feat: now pressing enter will submit the new rollout percentage (#9995)
This commit is contained in:
parent
a0e4f08507
commit
ba80c925e7
@ -139,6 +139,13 @@ const RolloutSlider = ({
|
||||
}
|
||||
};
|
||||
|
||||
const handleKeyDown = (e: React.KeyboardEvent<HTMLInputElement>) => {
|
||||
if (e.key === 'Enter') {
|
||||
e.preventDefault();
|
||||
handleInputBlur();
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<SliderWrapper>
|
||||
<StyledBox>
|
||||
@ -213,6 +220,7 @@ const RolloutSlider = ({
|
||||
value={inputValue}
|
||||
onChange={handleInputChange}
|
||||
onBlur={handleInputBlur}
|
||||
onKeyDown={handleKeyDown}
|
||||
disabled={disabled}
|
||||
inputProps={{
|
||||
min: 0,
|
||||
|
Loading…
Reference in New Issue
Block a user