Spaces:
Running
Running
Update static/canvas.js
Browse files- static/canvas.js +4 -4
static/canvas.js
CHANGED
@@ -335,10 +335,10 @@ function createNode(x, y, label, type, inputs = [], outputs = [], id, source = '
|
|
335 |
// const textareaX = (nodePos.x + stage.x()) / scale + canvasRect.left;
|
336 |
// const textareaY = (nodePos.y + height + 10 + stage.y()) / scale + canvasRect.top;
|
337 |
const textareaY = nodePos.y;
|
338 |
-
codeTextarea.style.right = `${textareaX}px`;
|
339 |
-
codeTextarea.style.top = `${textareaY}px`;
|
340 |
-
|
341 |
-
|
342 |
codeTextarea.style.width = `${300 / scale}px`;
|
343 |
codeTextarea.style.height = `${100 / scale}px`;
|
344 |
codeTextarea.style.fontFamily = 'monospace';
|
|
|
335 |
// const textareaX = (nodePos.x + stage.x()) / scale + canvasRect.left;
|
336 |
// const textareaY = (nodePos.y + height + 10 + stage.y()) / scale + canvasRect.top;
|
337 |
const textareaY = nodePos.y;
|
338 |
+
//codeTextarea.style.right = `${textareaX}px`;
|
339 |
+
//codeTextarea.style.top = `${textareaY}px`;
|
340 |
+
codeTextarea.style.right = '-20px' || `${textareaX}px`;
|
341 |
+
codeTextarea.style.top = '20px' || `${textareaY}px`;
|
342 |
codeTextarea.style.width = `${300 / scale}px`;
|
343 |
codeTextarea.style.height = `${100 / scale}px`;
|
344 |
codeTextarea.style.fontFamily = 'monospace';
|