1- import { SimplifiedOutputArea , OutputAreaModel } from '@jupyterlab/outputarea' ;
21import { IRenderMimeRegistry } from '@jupyterlab/rendermime' ;
32import { ISessionContext } from '@jupyterlab/apputils' ;
43
@@ -19,7 +18,7 @@ export class BlocklyLayout extends PanelLayout {
1918 private _manager : BlocklyManager ;
2019 private _workspace : Blockly . WorkspaceSvg ;
2120 private _sessionContext : ISessionContext ;
22- private _outputArea : SimplifiedOutputArea ;
21+ private _outputArea : Widget ;
2322
2423 /**
2524 * Construct a `BlocklyLayout`.
@@ -35,11 +34,9 @@ export class BlocklyLayout extends PanelLayout {
3534 this . _sessionContext = sessionContext ;
3635
3736 // Creating the container for the Blockly editor
37+ // and the output area to render the execution replies.
3838 this . _host = document . createElement ( 'div' ) ;
39- this . _outputArea = new SimplifiedOutputArea ( {
40- model : new OutputAreaModel ( { trusted : true } ) ,
41- rendermime
42- } ) ;
39+ this . _outputArea = new Widget ( ) ;
4340 }
4441
4542 get workspace ( ) : PartialJSONValue {
@@ -89,12 +86,7 @@ export class BlocklyLayout extends PanelLayout {
8986
9087 run ( ) : void {
9188 const code = this . _manager . generator . workspaceToCode ( this . _workspace ) ;
92- SimplifiedOutputArea . execute ( code , this . _outputArea , this . _sessionContext )
93- . then ( resp => {
94- this . addWidget ( this . _outputArea ) ;
95- this . _resizeWorkspace ( ) ;
96- } )
97- . catch ( e => console . error ( e ) ) ;
89+ // Execute the code using the kernel
9890 }
9991
10092 /**
0 commit comments