UNPKG

@selenite/graph-editor

Version:

A graph editor for visual programming, based on rete and svelte.

27 lines (26 loc) 804 B
import { APINode } from '../../APINode'; /** * This node displays the value of the input. */ export class AcousticSEMNode extends APINode { // height = 150; width = 180; constructor({ factory }) { super({ label: 'Create AcousticSEM', factory, url: '/makutu/solver/create-acoustic-sem', height: 180 }); this.oldAddOutData({ name: 'solver', displayName: 'Solver', socketLabel: 'Solver', type: 'pythonObject' }); this.pythonComponent.addImportStatement('from utilities.solvers import AcousticSolver'); this.pythonComponent.addCode('$(solver) = AcousticSolver()'); this.pythonComponent.addVariable('solver'); // Display value } }