@@ -7,6 +7,7 @@ import { ICommandPalette, IThemeManager } from '@jupyterlab/apputils';
7
7
import { IDocumentManager } from '@jupyterlab/docmanager' ;
8
8
import { INotebookTracker , NotebookPanel } from '@jupyterlab/notebook' ;
9
9
import { ITranslator } from '@jupyterlab/translation' ;
10
+ import { IStateDB } from '@jupyterlab/statedb' ;
10
11
import {
11
12
NotebookEventType ,
12
13
onNotebookChange ,
@@ -24,10 +25,12 @@ const activate = (
24
25
notebookTracker : INotebookTracker ,
25
26
commandPalette : ICommandPalette ,
26
27
themeManager : IThemeManager ,
27
- translator : ITranslator
28
+ translator : ITranslator ,
29
+ state : IStateDB
28
30
) : void => {
29
31
const trans = translator . load ( 'jupyterlab' ) ;
30
32
const style = '@amzn/awsgluenotebooks-extensions/style/index.css' ;
33
+ const PLUGIN_ID = '@aws/amazon-codeguru-extension' ;
31
34
32
35
themeManager . register ( {
33
36
name : 'Glue Studio UI Light' ,
@@ -37,6 +40,10 @@ const activate = (
37
40
unload : ( ) => Promise . resolve ( undefined )
38
41
} ) ;
39
42
43
+ state . save ( `${ PLUGIN_ID } :plugin` , {
44
+ isFirstTime : false
45
+ } ) ;
46
+
40
47
// TODO: The script name should be coming from iFrame communication; so we need to populate that here.
41
48
const temporaryScriptName = '/Untitled.ipynb' ;
42
49
labShell . mode = 'single-document' ;
@@ -49,10 +56,10 @@ const activate = (
49
56
const body = document . querySelector ( 'body' ) ;
50
57
51
58
// Ensuring extension loads in an iframe within the AWS console context; otherwise do early return
52
- if ( window . location === window . parent . location ) {
53
- body . innerHTML = '' ;
54
- return ;
55
- }
59
+ // if (window.location === window.parent.location) {
60
+ // body.innerHTML = '';
61
+ // return;
62
+ // }
56
63
57
64
body ?. setAttribute ( 'id' , 'glue-base' ) ;
58
65
body ?. classList . add ( 'aws-fake-loader' ) ;
0 commit comments