aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/ScriptingBox.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2024-03-10 09:50:46 -0400
committerbobzel <zzzman@gmail.com>2024-03-10 09:50:46 -0400
commit4caca5b32f74beed00bfbdaa181cb69fc001b7ca (patch)
tree5601b1bdaa8499af44d2ca50dd845ea0a65128b4 /src/client/views/nodes/ScriptingBox.tsx
parent3735fd5e8c0f5315d73a28ef59dcff4bc6158c88 (diff)
parenta9eb266296d1b71f1016c867f39e20299c011eea (diff)
Merge branch 'master' into zach-starter
Diffstat (limited to 'src/client/views/nodes/ScriptingBox.tsx')
-rw-r--r--src/client/views/nodes/ScriptingBox.tsx32
1 files changed, 15 insertions, 17 deletions
diff --git a/src/client/views/nodes/ScriptingBox.tsx b/src/client/views/nodes/ScriptingBox.tsx
index 89650889d..d9d0dbe3e 100644
--- a/src/client/views/nodes/ScriptingBox.tsx
+++ b/src/client/views/nodes/ScriptingBox.tsx
@@ -130,7 +130,7 @@ export class ScriptingBox extends ViewBoxAnnotatableComponent<FieldViewProps>()
}
})
);
- observer.observe(document.getElementsByClassName('scriptingBox')[0]);
+ observer.observe(document.getElementsByClassName('scriptingBox-outerDiv')[0]);
}
@action
@@ -811,22 +811,20 @@ export class ScriptingBox extends ViewBoxAnnotatableComponent<FieldViewProps>()
render() {
TraceMobx();
return (
- <div className={`scriptingBox`} onContextMenu={this.specificContextMenu} onPointerUp={!this._function ? this.suggestionPos : undefined}>
- <div className="scriptingBox-outerDiv" onWheel={e => this._props.isSelected() && e.stopPropagation()}>
- {this._paramSuggestion ? (
- <div className="boxed" ref={this._suggestionRef} style={{ left: this._suggestionBoxX + 20, top: this._suggestionBoxY - 15, display: 'inline' }}>
- {' '}
- {this._scriptSuggestedParams}{' '}
- </div>
- ) : null}
- {!this._applied && !this._function ? this.renderScriptingInputs : null}
- {this._applied && !this._function ? this.renderParamsInputs() : null}
- {!this._applied && this._function ? this.renderFunctionInputs() : null}
-
- {!this._applied && !this._function ? this.renderScriptingTools() : null}
- {this._applied && !this._function ? this.renderTools('Run', () => this.onRun()) : null}
- {!this._applied && this._function ? this.renderTools('Create Function', () => this.onCreate()) : null}
- </div>
+ <div className="scriptingBox-outerDiv" onContextMenu={this.specificContextMenu} onPointerUp={!this._function ? this.suggestionPos : undefined} onWheel={e => this._props.isSelected() && e.stopPropagation()}>
+ {this._paramSuggestion ? (
+ <div className="boxed" ref={this._suggestionRef} style={{ left: this._suggestionBoxX + 20, top: this._suggestionBoxY - 15, display: 'inline' }}>
+ {' '}
+ {this._scriptSuggestedParams}{' '}
+ </div>
+ ) : null}
+ {!this._applied && !this._function ? this.renderScriptingInputs : null}
+ {this._applied && !this._function ? this.renderParamsInputs() : null}
+ {!this._applied && this._function ? this.renderFunctionInputs() : null}
+
+ {!this._applied && !this._function ? this.renderScriptingTools() : null}
+ {this._applied && !this._function ? this.renderTools('Run', () => this.onRun()) : null}
+ {!this._applied && this._function ? this.renderTools('Create Function', () => this.onCreate()) : null}
</div>
);
}