@jupytergis/jupytergis-core 0.10.0 → 0.11.1
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
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { ICollaborativeDrive } from '@jupyter/collaborative-drive';
|
|
2
1
|
import { JupyterGISDocumentWidget } from '@jupytergis/base';
|
|
3
2
|
import { JupyterGISModel, IJupyterGISTracker, IJGISExternalCommandRegistry, IJGISFormSchemaRegistry, IAnnotationModel } from '@jupytergis/schema';
|
|
4
3
|
import { IEditorMimeTypeService } from '@jupyterlab/codeeditor';
|
|
5
4
|
import { ConsolePanel, IConsoleTracker } from '@jupyterlab/console';
|
|
6
5
|
import { ABCWidgetFactory, DocumentRegistry } from '@jupyterlab/docregistry';
|
|
7
6
|
import { IRenderMimeRegistry } from '@jupyterlab/rendermime';
|
|
8
|
-
import { ServiceManager } from '@jupyterlab/services';
|
|
7
|
+
import { Contents, ServiceManager } from '@jupyterlab/services';
|
|
9
8
|
import { IStateDB } from '@jupyterlab/statedb';
|
|
10
9
|
import { CommandRegistry } from '@lumino/commands';
|
|
11
10
|
interface IOptions extends DocumentRegistry.IWidgetFactoryOptions {
|
|
@@ -18,7 +17,7 @@ interface IOptions extends DocumentRegistry.IWidgetFactoryOptions {
|
|
|
18
17
|
rendermime?: IRenderMimeRegistry;
|
|
19
18
|
consoleTracker?: IConsoleTracker;
|
|
20
19
|
backendCheck?: () => boolean;
|
|
21
|
-
drive?:
|
|
20
|
+
drive?: Contents.IDrive | null;
|
|
22
21
|
formSchemaRegistry: IJGISFormSchemaRegistry;
|
|
23
22
|
state: IStateDB;
|
|
24
23
|
annotationModel: IAnnotationModel;
|
package/lib/factory.js
CHANGED
|
@@ -15,7 +15,7 @@ export class JupyterGISDocumentWidgetFactory extends ABCWidgetFactory {
|
|
|
15
15
|
constructor(options) {
|
|
16
16
|
var _a;
|
|
17
17
|
const { backendCheck, externalCommandRegistry } = options, rest = __rest(options, ["backendCheck", "externalCommandRegistry"]);
|
|
18
|
-
super(rest);
|
|
18
|
+
super(Object.assign(Object.assign({}, rest), { contentProviderId: 'rtc' }));
|
|
19
19
|
this.options = options;
|
|
20
20
|
this._backendCheck = backendCheck;
|
|
21
21
|
this._commands = options.commands;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ICollaborativeContentProvider } from '@jupyter/collaborative-drive';
|
|
2
2
|
import { CommandIDs, logoIcon, logoMiniIcon } from '@jupytergis/base';
|
|
3
3
|
import { IAnnotationToken, IJGISExternalCommandRegistryToken, IJupyterGISDocTracker, JupyterGISDoc, SCHEMA_VERSION, ProcessingMerge, IJGISFormSchemaRegistryToken, } from '@jupytergis/schema';
|
|
4
4
|
import { ICommandPalette, IThemeManager, } from '@jupyterlab/apputils';
|
|
@@ -18,7 +18,7 @@ const CONTENT_TYPE = 'jgis';
|
|
|
18
18
|
const PALETTE_CATEGORY = 'JupyterGIS';
|
|
19
19
|
const MODEL_NAME = 'jupytergis-jgismodel';
|
|
20
20
|
const SETTINGS_ID = '@jupytergis/jupytergis-core:jupytergis-settings';
|
|
21
|
-
const activate = async (app, tracker, themeManager, browserFactory, externalCommandRegistry, contentFactory, editorServices, rendermime, consoleTracker, annotationModel, settingRegistry, formSchemaRegistry, state, launcher, palette,
|
|
21
|
+
const activate = async (app, tracker, themeManager, browserFactory, externalCommandRegistry, contentFactory, editorServices, rendermime, consoleTracker, annotationModel, settingRegistry, formSchemaRegistry, state, launcher, palette, collaborativeContentProvider) => {
|
|
22
22
|
formSchemaRegistry && state;
|
|
23
23
|
if (PageConfig.getOption('jgis_expose_maps')) {
|
|
24
24
|
window.jupytergisMaps = {};
|
|
@@ -76,8 +76,8 @@ const activate = async (app, tracker, themeManager, browserFactory, externalComm
|
|
|
76
76
|
const jGISSharedModelFactory = () => {
|
|
77
77
|
return new JupyterGISDoc();
|
|
78
78
|
};
|
|
79
|
-
if (
|
|
80
|
-
|
|
79
|
+
if (collaborativeContentProvider) {
|
|
80
|
+
collaborativeContentProvider.sharedModelFactory.registerDocumentFactory(CONTENT_TYPE, jGISSharedModelFactory);
|
|
81
81
|
}
|
|
82
82
|
widgetFactory.widgetCreated.connect((sender, widget) => {
|
|
83
83
|
widget.title.icon = logoIcon;
|
|
@@ -196,7 +196,7 @@ const jGISPlugin = {
|
|
|
196
196
|
IJGISFormSchemaRegistryToken,
|
|
197
197
|
IStateDB,
|
|
198
198
|
],
|
|
199
|
-
optional: [ILauncher, ICommandPalette,
|
|
199
|
+
optional: [ILauncher, ICommandPalette, ICollaborativeContentProvider],
|
|
200
200
|
autoStart: true,
|
|
201
201
|
activate,
|
|
202
202
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jupytergis/jupytergis-core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.1",
|
|
4
4
|
"description": "JupyterGIS core extension",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jupyter",
|
|
@@ -53,9 +53,9 @@
|
|
|
53
53
|
"watch:labextension": "jupyter labextension watch ."
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@jupyter/collaborative-drive": "^
|
|
57
|
-
"@jupytergis/base": "^0.
|
|
58
|
-
"@jupytergis/schema": "^0.
|
|
56
|
+
"@jupyter/collaborative-drive": "^4.1.2",
|
|
57
|
+
"@jupytergis/base": "^0.11.1",
|
|
58
|
+
"@jupytergis/schema": "^0.11.1",
|
|
59
59
|
"@jupyterlab/application": "^4.3.0",
|
|
60
60
|
"@jupyterlab/apputils": "^4.3.0",
|
|
61
61
|
"@jupyterlab/docregistry": "^4.3.0",
|