@@ -5,20 +5,20 @@ import {
55} from "@jupyterlab/application" ;
66import { ILauncher } from "@jupyterlab/launcher" ;
77import { PageConfig } from "@jupyterlab/coreutils" ;
8- import { IRunningSessionManagers , IRunningSessions } from ' @jupyterlab/running' ;
8+ import { IRunningSessionManagers , IRunningSessions } from " @jupyterlab/running" ;
99import { IFrame , MainAreaWidget , WidgetTracker } from "@jupyterlab/apputils" ;
10- import { LabIcon } from ' @jupyterlab/ui-components' ;
11- import { ServerProxyManager } from ' ./manager' ;
12- import { IModel as IServerProxyModel } from ' ./serverproxy' ;
13- import serverProxyAppSvgstr from ' ../style/icons/proxy.svg' ;
10+ import { LabIcon } from " @jupyterlab/ui-components" ;
11+ import { ServerProxyManager } from " ./manager" ;
12+ import { IModel as IServerProxyModel } from " ./serverproxy" ;
13+ import serverProxyAppSvgstr from " ../style/icons/proxy.svg" ;
1414
1515export const ServerProxyAppIcon = new LabIcon ( {
16- name : ' server-proxy:proxyAppIcon' ,
17- svgstr : serverProxyAppSvgstr
16+ name : " server-proxy:proxyAppIcon" ,
17+ svgstr : serverProxyAppSvgstr ,
1818} ) ;
1919
2020namespace CommandIDs {
21- export const open = ' running-server-proxy:open' ;
21+ export const open = " running-server-proxy:open" ;
2222}
2323
2424function newServerProxyWidget (
@@ -52,21 +52,22 @@ function newServerProxyWidget(
5252 * User can shut down the applications as well to restart them in future
5353 *
5454 */
55- function addRunningSessionManager (
55+ function addRunningSessionManager (
5656 managers : IRunningSessionManagers ,
5757 app : JupyterFrontEnd ,
58- manager : ServerProxyManager
58+ manager : ServerProxyManager ,
5959) : void {
6060 managers . add ( {
61- name : ' Server Proxy Apps' ,
61+ name : " Server Proxy Apps" ,
6262 running : ( ) =>
6363 Array . from ( manager . running ( ) ) . map (
64- model => new RunningServerProxyApp ( model )
64+ ( model ) => new RunningServerProxyApp ( model ) ,
6565 ) ,
6666 shutdownAll : ( ) => manager . shutdownAll ( ) ,
6767 refreshRunning : ( ) => manager . refreshRunning ( ) ,
6868 runningChanged : manager . runningChanged ,
69- shutdownAllConfirmationText : 'Are you sure you want to close all server proxy applications?'
69+ shutdownAllConfirmationText :
70+ "Are you sure you want to close all server proxy applications?" ,
7071 } ) ;
7172
7273 class RunningServerProxyApp implements IRunningSessions . IRunningItem {
@@ -103,7 +104,7 @@ async function activate(
103104 app : JupyterFrontEnd ,
104105 launcher : ILauncher ,
105106 restorer : ILayoutRestorer ,
106- sessions : IRunningSessionManagers | null
107+ sessions : IRunningSessionManagers | null ,
107108) : Promise < void > {
108109 // Fetch configured server processes from {base_url}/server-proxy/servers-info
109110 const response = await fetch (
@@ -175,12 +176,12 @@ async function activate(
175176 } ) ;
176177
177178 commands . addCommand ( CommandIDs . open , {
178- execute : args => {
179- const model = args [ 'sp' ] as IServerProxyModel ;
179+ execute : ( args ) => {
180+ const model = args [ "sp" ] as IServerProxyModel ;
180181 const url = PageConfig . getBaseUrl ( ) + model . url ;
181- window . open ( url , ' _blank' ) ;
182+ window . open ( url , " _blank" ) ;
182183 return ;
183- }
184+ } ,
184185 } ) ;
185186
186187 for ( let server_process of data . server_processes ) {
@@ -222,7 +223,7 @@ const extension: JupyterFrontEndPlugin<void> = {
222223 autoStart : true ,
223224 requires : [ ILauncher , ILayoutRestorer ] ,
224225 optional : [ IRunningSessionManagers ] ,
225- activate : activate
226+ activate : activate ,
226227} ;
227228
228229export default extension ;
0 commit comments