Skip to content

Commit

Permalink
fix: enable user set value manually model setting from input
Browse files Browse the repository at this point in the history
  • Loading branch information
urmauur committed Jan 15, 2024
1 parent 74f1e8e commit 901f49f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions web/containers/SliderRightPanel/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,18 +114,18 @@ const SliderRightPanel: React.FC<Props> = ({
min={min}
max={max}
value={String(value)}
onChange={(e) => {
onBlur={(e) => {
if (Number(e.target.value) > Number(max)) {
onValueChanged([Number(max)])
setShowTooltip({ max: true, min: false })
} else if (Number(e.target.value) < Number(min)) {
onValueChanged([Number(min)])
setShowTooltip({ max: false, min: true })
} else {
onValueChanged([Number(e.target.value)])
setShowTooltip({ max: false, min: false })
}
}}
onChange={(e) => {
onValueChanged([Number(e.target.value)])
}}
/>
</TooltipTrigger>
<TooltipPortal>
Expand Down

0 comments on commit 901f49f

Please sign in to comment.