diff options
Diffstat (limited to 'src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx')
-rw-r--r-- | src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx b/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx index cd55453ea..85c20760e 100644 --- a/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx +++ b/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx @@ -41,15 +41,13 @@ export default class InputField extends React.Component<IInputProps, IState> { } } - epsilon: number = 0; - componentDidMount() { - this.epsilon = 0.01; - } + epsilon: number = 0.01; componentDidUpdate(prevProps: Readonly<IInputProps>, prevState: Readonly<IState>, snapshot?: any): void { if (prevProps.value != this.props.value) { if (this.props.mode == "Freeform") { if (Math.abs(this.state.tempValue - Number(this.props.value)) > 1) { + console.log('update temp value') this.setState({tempValue: Number(this.props.value)}) } } |