File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed
packages/application-extension/src Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change 7
7
ITreePathUpdater ,
8
8
JupyterFrontEnd ,
9
9
JupyterFrontEndPlugin ,
10
+ JupyterLab ,
10
11
} from '@jupyterlab/application' ;
11
12
12
13
import {
@@ -159,6 +160,21 @@ const dirty: JupyterFrontEndPlugin<void> = {
159
160
} ,
160
161
} ;
161
162
163
+ /**
164
+ * The application info.
165
+ */
166
+ const info : JupyterFrontEndPlugin < JupyterLab . IInfo > = {
167
+ id : '@jupyter-notebook/application-extension:info' ,
168
+ autoStart : true ,
169
+ provides : JupyterLab . IInfo ,
170
+ activate : ( app : JupyterFrontEnd ) : JupyterLab . IInfo => {
171
+ if ( ! ( app instanceof NotebookApp ) ) {
172
+ throw new Error ( `${ info . id } must be activated in Jupyter Notebook.` ) ;
173
+ }
174
+ return app . info ;
175
+ } ,
176
+ } ;
177
+
162
178
/**
163
179
* The logo plugin.
164
180
*/
@@ -1148,6 +1164,7 @@ const zen: JupyterFrontEndPlugin<void> = {
1148
1164
*/
1149
1165
const plugins : JupyterFrontEndPlugin < any > [ ] = [
1150
1166
dirty ,
1167
+ info ,
1151
1168
logo ,
1152
1169
menus ,
1153
1170
menuSpacer ,
You can’t perform that action at this time.
0 commit comments