@jupyterlab/debugger 4.0.0-alpha.14 → 4.0.0-alpha.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/factory.d.ts +1 -1
- package/lib/factory.js +8 -8
- package/lib/factory.js.map +1 -1
- package/lib/handlers/editor.d.ts +1 -1
- package/lib/tokens.d.ts +1 -1
- package/package.json +18 -18
package/lib/factory.d.ts
CHANGED
package/lib/factory.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
// Copyright (c) Jupyter Development Team.
|
|
2
2
|
// Distributed under the terms of the Modified BSD License.
|
|
3
3
|
import { CodeEditor, CodeEditorWrapper } from '@jupyterlab/codeeditor';
|
|
4
|
-
import { createStandaloneCell } from '@jupyterlab/shared-models';
|
|
5
4
|
/**
|
|
6
5
|
* A widget factory for read only editors.
|
|
7
6
|
*/
|
|
@@ -23,14 +22,12 @@ export class ReadOnlyEditorFactory {
|
|
|
23
22
|
const { content, mimeType, path } = source;
|
|
24
23
|
const factory = this._services.factoryService.newInlineEditor;
|
|
25
24
|
const mimeTypeService = this._services.mimeTypeService;
|
|
25
|
+
const model = new CodeEditor.Model({
|
|
26
|
+
mimeType: mimeType || mimeTypeService.getMimeTypeByFilePath(path)
|
|
27
|
+
});
|
|
28
|
+
model.sharedModel.source = content;
|
|
26
29
|
const editor = new CodeEditorWrapper({
|
|
27
|
-
model
|
|
28
|
-
sharedModel: createStandaloneCell({
|
|
29
|
-
cell_type: 'code',
|
|
30
|
-
source: content
|
|
31
|
-
}),
|
|
32
|
-
mimeType: mimeType || mimeTypeService.getMimeTypeByFilePath(path)
|
|
33
|
-
}),
|
|
30
|
+
model,
|
|
34
31
|
factory,
|
|
35
32
|
config: {
|
|
36
33
|
readOnly: true,
|
|
@@ -38,6 +35,9 @@ export class ReadOnlyEditorFactory {
|
|
|
38
35
|
}
|
|
39
36
|
});
|
|
40
37
|
editor.node.setAttribute('data-jp-debugger', 'true');
|
|
38
|
+
editor.disposed.connect(() => {
|
|
39
|
+
model.dispose();
|
|
40
|
+
});
|
|
41
41
|
return editor;
|
|
42
42
|
}
|
|
43
43
|
}
|
package/lib/factory.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../src/factory.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,2DAA2D;AAE3D,OAAO,EACL,UAAU,EACV,iBAAiB,EAElB,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../src/factory.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,2DAA2D;AAE3D,OAAO,EACL,UAAU,EACV,iBAAiB,EAElB,MAAM,wBAAwB,CAAC;AAGhC;;GAEG;AACH,MAAM,OAAO,qBAAqB;IAChC;;;;OAIG;IACH,YAAY,OAAuC;QACjD,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,cAAc,CAAC;IAC1C,CAAC;IAED;;;;OAIG;IACH,eAAe,CAAC,MAAwB;QACtC,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,MAAM,CAAC;QAC3C,MAAM,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,eAAe,CAAC;QAC9D,MAAM,eAAe,GAAG,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC;QACvD,MAAM,KAAK,GAAG,IAAI,UAAU,CAAC,KAAK,CAAC;YACjC,QAAQ,EAAE,QAAQ,IAAI,eAAe,CAAC,qBAAqB,CAAC,IAAI,CAAC;SAClE,CAAC,CAAC;QACH,KAAK,CAAC,WAAW,CAAC,MAAM,GAAG,OAAO,CAAC;QACnC,MAAM,MAAM,GAAG,IAAI,iBAAiB,CAAC;YACnC,KAAK;YACL,OAAO;YACP,MAAM,EAAE;gBACN,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,IAAI;aAClB;SACF,CAAC,CAAC;QACH,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAC;QAErD,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,EAAE;YAC3B,KAAK,CAAC,OAAO,EAAE,CAAC;QAClB,CAAC,CAAC,CAAC;QAEH,OAAO,MAAM,CAAC;IAChB,CAAC;CAGF"}
|
package/lib/handlers/editor.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CodeEditor } from '@jupyterlab/codeeditor';
|
|
2
2
|
import { IDisposable } from '@lumino/disposable';
|
|
3
|
-
import { ISharedText } from '@
|
|
3
|
+
import { ISharedText } from '@jupyter-notebook/ydoc';
|
|
4
4
|
import { StateEffectType } from '@codemirror/state';
|
|
5
5
|
import { IDebugger } from '../tokens';
|
|
6
6
|
/**
|
package/lib/tokens.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CodeEditor, CodeEditorWrapper } from '@jupyterlab/codeeditor';
|
|
2
2
|
import { KernelMessage, Session } from '@jupyterlab/services';
|
|
3
|
-
import { ISharedText } from '@
|
|
3
|
+
import { ISharedText } from '@jupyter-notebook/ydoc';
|
|
4
4
|
import { ReadonlyJSONObject, Token } from '@lumino/coreutils';
|
|
5
5
|
import { IDisposable, IObservableDisposable } from '@lumino/disposable';
|
|
6
6
|
import { ISignal, Signal } from '@lumino/signaling';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jupyterlab/debugger",
|
|
3
|
-
"version": "4.0.0-alpha.
|
|
3
|
+
"version": "4.0.0-alpha.16",
|
|
4
4
|
"description": "JupyterLab - Debugger Extension",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jupyter",
|
|
@@ -50,22 +50,22 @@
|
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@codemirror/state": "^6.0.0",
|
|
52
52
|
"@codemirror/view": "^6.0.0",
|
|
53
|
-
"@
|
|
54
|
-
"@jupyterlab/
|
|
55
|
-
"@jupyterlab/
|
|
56
|
-
"@jupyterlab/
|
|
57
|
-
"@jupyterlab/
|
|
58
|
-
"@jupyterlab/
|
|
59
|
-
"@jupyterlab/
|
|
60
|
-
"@jupyterlab/
|
|
61
|
-
"@jupyterlab/
|
|
62
|
-
"@jupyterlab/
|
|
63
|
-
"@jupyterlab/
|
|
64
|
-
"@jupyterlab/
|
|
65
|
-
"@jupyterlab/
|
|
66
|
-
"@jupyterlab/
|
|
67
|
-
"@jupyterlab/translation": "^4.0.0-alpha.
|
|
68
|
-
"@jupyterlab/ui-components": "^4.0.0-alpha.
|
|
53
|
+
"@jupyter-notebook/ydoc": "~0.2.0",
|
|
54
|
+
"@jupyterlab/application": "^4.0.0-alpha.16",
|
|
55
|
+
"@jupyterlab/apputils": "^4.0.0-alpha.16",
|
|
56
|
+
"@jupyterlab/cells": "^4.0.0-alpha.16",
|
|
57
|
+
"@jupyterlab/codeeditor": "^4.0.0-alpha.16",
|
|
58
|
+
"@jupyterlab/codemirror": "^4.0.0-alpha.16",
|
|
59
|
+
"@jupyterlab/console": "^4.0.0-alpha.16",
|
|
60
|
+
"@jupyterlab/coreutils": "^6.0.0-alpha.16",
|
|
61
|
+
"@jupyterlab/docregistry": "^4.0.0-alpha.16",
|
|
62
|
+
"@jupyterlab/fileeditor": "^4.0.0-alpha.16",
|
|
63
|
+
"@jupyterlab/notebook": "^4.0.0-alpha.16",
|
|
64
|
+
"@jupyterlab/observables": "^5.0.0-alpha.16",
|
|
65
|
+
"@jupyterlab/rendermime": "^4.0.0-alpha.16",
|
|
66
|
+
"@jupyterlab/services": "^7.0.0-alpha.16",
|
|
67
|
+
"@jupyterlab/translation": "^4.0.0-alpha.16",
|
|
68
|
+
"@jupyterlab/ui-components": "^4.0.0-alpha.31",
|
|
69
69
|
"@lumino/algorithm": "^2.0.0-alpha.6",
|
|
70
70
|
"@lumino/commands": "^2.0.0-alpha.6",
|
|
71
71
|
"@lumino/coreutils": "^2.0.0-alpha.6",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"devDependencies": {
|
|
82
82
|
"@babel/core": "^7.10.2",
|
|
83
83
|
"@babel/preset-env": "^7.10.2",
|
|
84
|
-
"@jupyterlab/testutils": "^4.0.0-alpha.
|
|
84
|
+
"@jupyterlab/testutils": "^4.0.0-alpha.16",
|
|
85
85
|
"@types/jest": "^26.0.10",
|
|
86
86
|
"@types/react-dom": "^17.0.0",
|
|
87
87
|
"@types/text-encoding": "^0.0.35",
|