From c93e1dc281c831ab08cf0ce29420df845323b0be Mon Sep 17 00:00:00 2001
From: brynnchernosky <56202540+brynnchernosky@users.noreply.github.com>
Date: Mon, 1 May 2023 20:05:49 -0400
Subject: debugging

---
 .../views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx    | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

(limited to 'src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx')

diff --git a/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx b/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx
index 1125e6020..cd55453ea 100644
--- a/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx
+++ b/src/client/views/nodes/PhysicsBox/PhysicsSimulationInputField.tsx
@@ -23,7 +23,7 @@ export interface IInputProps {
 }
 
 interface IState {
-  tempValue: number,
+  tempValue: string | number | (string|number)[],
   tempRadianValue: number,
   width: string;
   margin: string;
@@ -71,7 +71,9 @@ export default class InputField extends React.Component<IInputProps, IState> {
     } else if (value < this.props.lowerBound) {
       value = this.props.lowerBound;
     }
-    this.props.dataDoc[this.props.prop] = value
+    if (this.props.prop != "") {
+      this.props.dataDoc[this.props.prop] = value
+    }
     this.setState({tempValue: event.target.value == "" ? event.target.value : value})
     this.setState({tempRadianValue: (value * Math.PI) / 180})
     if (this.props.effect) {
@@ -85,8 +87,9 @@ export default class InputField extends React.Component<IInputProps, IState> {
       value = 2 * Math.PI;
     } else if (value < 0) {
       value = 0;
+    }if (this.props.prop != "") {
+      this.props.dataDoc[this.props.prop] = (value * 180) / Math.PI
     }
-    this.props.dataDoc[this.props.prop] = (value * 180) / Math.PI
     this.setState({tempValue: (value * 180) / Math.PI})
     this.setState({tempRadianValue: value})
     if (this.props.effect) {
@@ -95,6 +98,7 @@ export default class InputField extends React.Component<IInputProps, IState> {
   };
 
   render () { 
+    return (
     <div
       style={{
         display: "flex",
@@ -174,5 +178,6 @@ export default class InputField extends React.Component<IInputProps, IState> {
         />
       )}
     </div>
+    )
   }
 };
-- 
cgit v1.2.3-70-g09d2

