Change value in table fields
* Input table fields need to be able to be empty * Slider table fields should default to 0 if value isn't provided
This commit is contained in:
parent
84e7fc5ffc
commit
d0c1f07422
2 changed files with 3 additions and 2 deletions
|
|
@ -43,8 +43,9 @@ const InputTableField = (props: Props) => {
|
||||||
>
|
>
|
||||||
<Input
|
<Input
|
||||||
className="Bound"
|
className="Bound"
|
||||||
|
placeholder={props.placeholder}
|
||||||
type="number"
|
type="number"
|
||||||
value={`${value}`}
|
value={value ? `${value}` : ''}
|
||||||
step={1}
|
step={1}
|
||||||
onChange={onInputChange}
|
onChange={onInputChange}
|
||||||
/>
|
/>
|
||||||
|
|
|
||||||
|
|
@ -58,7 +58,7 @@ const SliderTableField = (props: Props) => {
|
||||||
min={props.min}
|
min={props.min}
|
||||||
max={props.max}
|
max={props.max}
|
||||||
step={props.step}
|
step={props.step}
|
||||||
value={[value]}
|
value={[value ? value : 0]}
|
||||||
onValueChange={handleValueChange}
|
onValueChange={handleValueChange}
|
||||||
onValueCommit={handleValueCommit}
|
onValueCommit={handleValueCommit}
|
||||||
/>
|
/>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue