@jupytergis/jupytergis-lab 0.4.2 → 0.4.3

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.
Files changed (2) hide show
  1. package/lib/index.js +32 -1
  2. package/package.json +3 -3
package/lib/index.js CHANGED
@@ -29,7 +29,6 @@ const plugin = {
29
29
  const stateDbManager = GlobalStateDbManager.getInstance();
30
30
  stateDbManager.initialize(state);
31
31
  addCommands(app, tracker, translator, formSchemaRegistry, layerBrowserRegistry, state, completionProviderManager);
32
- app.shell.addClass('data-jgis-keybinding');
33
32
  // SOURCES context menu
34
33
  const newSourceSubMenu = new Menu({ commands: app.commands });
35
34
  newSourceSubMenu.title.label = translator
@@ -104,6 +103,38 @@ const plugin = {
104
103
  selector: '.jp-gis-layerItem',
105
104
  rank: 2
106
105
  });
106
+ // Create the Download submenu
107
+ const downloadSubmenu = new Menu({ commands: app.commands });
108
+ downloadSubmenu.title.label = translator.load('jupyterlab').__('Download');
109
+ downloadSubmenu.id = 'jp-gis-contextmenu-download';
110
+ downloadSubmenu.addItem({
111
+ command: CommandIDs.downloadGeoJSON
112
+ });
113
+ // Add the Download submenu to the context menu
114
+ app.contextMenu.addItem({
115
+ type: 'submenu',
116
+ selector: '.jp-gis-layerItem',
117
+ rank: 2,
118
+ submenu: downloadSubmenu
119
+ });
120
+ // Create the Processing submenu
121
+ const processingSubmenu = new Menu({ commands: app.commands });
122
+ processingSubmenu.title.label = translator
123
+ .load('jupyterlab')
124
+ .__('Processing');
125
+ processingSubmenu.id = 'jp-gis-contextmenu-processing';
126
+ processingSubmenu.addItem({
127
+ command: CommandIDs.buffer
128
+ });
129
+ processingSubmenu.addItem({
130
+ command: CommandIDs.dissolve
131
+ });
132
+ app.contextMenu.addItem({
133
+ type: 'submenu',
134
+ selector: '.jp-gis-layerItem',
135
+ rank: 2,
136
+ submenu: processingSubmenu
137
+ });
107
138
  const moveLayerSubmenu = new Menu({ commands: app.commands });
108
139
  moveLayerSubmenu.title.label = translator
109
140
  .load('jupyterlab')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jupytergis/jupytergis-lab",
3
- "version": "0.4.2",
3
+ "version": "0.4.3",
4
4
  "description": "JupyterGIS Lab extension.",
5
5
  "keywords": [
6
6
  "jupyter",
@@ -53,8 +53,8 @@
53
53
  },
54
54
  "dependencies": {
55
55
  "@jupyter/collaborative-drive": "^3.0.0",
56
- "@jupytergis/base": "^0.4.2",
57
- "@jupytergis/schema": "^0.4.2",
56
+ "@jupytergis/base": "^0.4.3",
57
+ "@jupytergis/schema": "^0.4.3",
58
58
  "@jupyterlab/application": "^4.3.0",
59
59
  "@jupyterlab/apputils": "^4.3.0",
60
60
  "@jupyterlab/completer": "^4.3.0",