@jupyter/collaboration-extension 1.0.0-alpha.1 → 1.0.0-alpha.2
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/filebrowser.js +5 -3
- package/package.json +7 -3
package/lib/filebrowser.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ILabShell, IRouter, JupyterFrontEnd } from '@jupyterlab/application';
|
|
2
2
|
import { IDefaultFileBrowser, IFileBrowserFactory } from '@jupyterlab/filebrowser';
|
|
3
|
+
import { ITranslator } from '@jupyterlab/translation';
|
|
3
4
|
import { YDrive } from '@jupyter/docprovider';
|
|
4
5
|
/**
|
|
5
6
|
* The command IDs used by the file browser plugin.
|
|
@@ -14,12 +15,13 @@ var CommandIDs;
|
|
|
14
15
|
export const defaultFileBrowser = {
|
|
15
16
|
id: '@jupyter/collaboration-extension:defaultFileBrowser',
|
|
16
17
|
provides: IDefaultFileBrowser,
|
|
17
|
-
requires: [IFileBrowserFactory],
|
|
18
|
+
requires: [IFileBrowserFactory, ITranslator],
|
|
18
19
|
optional: [IRouter, JupyterFrontEnd.ITreeResolver, ILabShell],
|
|
19
|
-
activate: async (app, fileBrowserFactory, router, tree, labShell) => {
|
|
20
|
+
activate: async (app, fileBrowserFactory, translator, router, tree, labShell) => {
|
|
20
21
|
console.debug('@jupyter/collaboration-extension:defaultFileBrowser: activated');
|
|
21
22
|
const { commands } = app;
|
|
22
|
-
const
|
|
23
|
+
const trans = translator.load('jupyter_collaboration');
|
|
24
|
+
const drive = new YDrive(app.serviceManager.user, trans);
|
|
23
25
|
app.serviceManager.contents.addDrive(drive);
|
|
24
26
|
// Manually restore and load the default file browser.
|
|
25
27
|
const defaultBrowser = fileBrowserFactory.createFileBrowser('filebrowser', {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jupyter/collaboration-extension",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.2",
|
|
4
4
|
"description": "JupyterLab - Real-Time Collaboration Extension",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jupyter",
|
|
@@ -52,8 +52,8 @@
|
|
|
52
52
|
"watch:labextension": "jupyter labextension watch ."
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@jupyter/collaboration": "^1.0.0-alpha.
|
|
56
|
-
"@jupyter/docprovider": "^1.0.0-alpha.
|
|
55
|
+
"@jupyter/collaboration": "^1.0.0-alpha.2",
|
|
56
|
+
"@jupyter/docprovider": "^1.0.0-alpha.2",
|
|
57
57
|
"@jupyterlab/application": "^4.0.0-alpha.19",
|
|
58
58
|
"@jupyterlab/apputils": "^4.0.0-alpha.19",
|
|
59
59
|
"@jupyterlab/coreutils": "^6.0.0-alpha.19",
|
|
@@ -99,6 +99,10 @@
|
|
|
99
99
|
"@jupyter/docprovider": {
|
|
100
100
|
"bundled": true,
|
|
101
101
|
"singleton": true
|
|
102
|
+
},
|
|
103
|
+
"@jupyter/ydoc": {
|
|
104
|
+
"bundled": false,
|
|
105
|
+
"singleton": true
|
|
102
106
|
}
|
|
103
107
|
}
|
|
104
108
|
}
|