Skip to content

Commit f0b6b6a

Browse files
committed
update for jupyterlab 1.0.0
1 parent 6a9516d commit f0b6b6a

File tree

4 files changed

+23
-19
lines changed

4 files changed

+23
-19
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ lib/
33
node_modules/
44
*.egg-info/
55
.ipynb_checkpoints
6+
tsconfig.tsbuildinfo

package.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,23 +26,23 @@
2626
},
2727
"scripts": {
2828
"build": "node scripts/copyfiles.js && tsc",
29-
"clean": "rimraf lib",
29+
"clean": "rimraf lib && rimraf tsconfig.tsbuildinfo",
3030
"watch": "tsc -w",
3131
"prepublish": "npm run clean && npm run build"
3232
},
3333
"dependencies": {
34-
"@jupyterlab/application": "^0.19.1",
35-
"@jupyterlab/apputils": "^0.19.1",
36-
"@jupyterlab/coreutils": "^2.0.2",
37-
"@jupyterlab/docregistry": "^0.19.1",
38-
"@jupyterlab/filebrowser": "^0.19.1",
39-
"@jupyterlab/launcher": "^0.19.1",
40-
"@jupyterlab/mainmenu": "^0.8.1"
34+
"@jupyterlab/application": "^1.0.0",
35+
"@jupyterlab/apputils": "^1.0.0",
36+
"@jupyterlab/coreutils": "^3.0.0",
37+
"@jupyterlab/docregistry": "^1.0.0",
38+
"@jupyterlab/filebrowser": "^1.0.0",
39+
"@jupyterlab/launcher": "^1.0.0",
40+
"@jupyterlab/mainmenu": "^1.0.0"
4141
},
4242
"devDependencies": {
4343
"rimraf": "^2.6.1",
44-
"typescript": "~3.1.1",
45-
"fs-extra": "^0.30.0",
44+
"typescript": "~3.5.2",
45+
"fs-extra": "^8.1.0",
4646
"@phosphor/messaging": "^1.1.0"
4747
},
4848
"jupyterlab": {

src/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@
1313
// limitations under the License.
1414

1515
import {
16-
ILayoutRestorer, JupyterLab, JupyterLabPlugin
16+
ILayoutRestorer, JupyterLab, JupyterFrontEndPlugin
1717
} from '@jupyterlab/application';
1818

1919
import {
20-
ICommandPalette, InstanceTracker, IInstanceTracker
20+
ICommandPalette, WidgetTracker, IWidgetTracker
2121
} from '@jupyterlab/apputils';
2222

2323
import {
@@ -45,15 +45,15 @@ import {
4545
*/
4646
const FACTORY = 'Drawio';
4747

48-
interface IDrawioTracker extends IInstanceTracker<DrawioWidget> {}
48+
interface IDrawioTracker extends IWidgetTracker<DrawioWidget> {}
4949

5050
export
5151
const IDrawioTracker = new Token<IDrawioTracker>('drawio/tracki');
5252

5353
/**
5454
* The editor tracker extension.
5555
*/
56-
const plugin: JupyterLabPlugin<IDrawioTracker> = {
56+
const plugin: JupyterFrontEndPlugin<IDrawioTracker> = {
5757
activate,
5858
id: '@jupyterlab/drawio-extension:plugin',
5959
requires: [IFileBrowserFactory, ILayoutRestorer, IMainMenu, ICommandPalette],
@@ -74,7 +74,7 @@ function activate(app: JupyterLab,
7474
const namespace = 'drawio';
7575
const factory = new DrawioFactory({ name: FACTORY, fileTypes: ['dio'], defaultFor: ['dio'] });
7676
const { commands } = app;
77-
const tracker = new InstanceTracker<DrawioWidget>({ namespace });
77+
const tracker = new WidgetTracker<DrawioWidget>({ namespace });
7878

7979
/**
8080
* Whether there is an active DrawIO editor.

tsconfig.json

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,15 @@
55
"noEmitOnError": true,
66
"noUnusedLocals": true,
77
"allowJs": true,
8-
"module": "commonjs",
8+
"module": "esnext",
9+
"esModuleInterop": true,
10+
"incremental": true,
11+
"jsx": "react",
912
"moduleResolution": "node",
10-
"target": "ES2015",
13+
"target": "es2017",
1114
"outDir": "./lib",
12-
"lib": ["ES2015", "ES2015.Promise", "DOM", "ES2015.Collection"],
13-
"types": []
15+
"types": [],
16+
"rootDir": "./src"
1417
},
1518
"include": ["src/*"]
1619
}

0 commit comments

Comments
 (0)