@jupytergis/base 0.10.1 → 0.12.0
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/commands/BaseCommandIDs.d.ts +2 -0
- package/lib/commands/BaseCommandIDs.js +3 -0
- package/lib/commands/index.js +66 -0
- package/lib/constants.js +4 -0
- package/lib/dialogs/symbology/hooks/useGetBandInfo.d.ts +0 -6
- package/lib/dialogs/symbology/hooks/useGetBandInfo.js +2 -2
- package/lib/dialogs/symbology/tiff_layer/types/MultibandColor.js +4 -4
- package/lib/dialogs/symbology/vector_layer/types/Categorized.js +1 -5
- package/lib/formbuilder/formselectors.js +5 -1
- package/lib/formbuilder/objectform/StoryEditorForm.d.ts +9 -0
- package/lib/formbuilder/objectform/StoryEditorForm.js +16 -0
- package/lib/formbuilder/objectform/components/StorySegmentReset.d.ts +8 -0
- package/lib/formbuilder/objectform/components/StorySegmentReset.js +24 -0
- package/lib/formbuilder/objectform/layer/index.d.ts +1 -0
- package/lib/formbuilder/objectform/layer/index.js +1 -0
- package/lib/formbuilder/objectform/layer/storySegmentLayerForm.d.ts +5 -0
- package/lib/formbuilder/objectform/layer/storySegmentLayerForm.js +32 -0
- package/lib/mainview/mainView.d.ts +18 -0
- package/lib/mainview/mainView.js +293 -14
- package/lib/panelview/components/layers.d.ts +2 -1
- package/lib/panelview/components/layers.js +31 -23
- package/lib/panelview/{components/filter-panel → filter-panel}/Filter.js +1 -1
- package/lib/panelview/leftpanel.js +89 -7
- package/lib/panelview/rightpanel.d.ts +2 -0
- package/lib/panelview/rightpanel.js +41 -4
- package/lib/panelview/story-maps/PreviewModeSwitch.d.ts +7 -0
- package/lib/panelview/story-maps/PreviewModeSwitch.js +13 -0
- package/lib/panelview/story-maps/StoryEditorPanel.d.ts +9 -0
- package/lib/panelview/story-maps/StoryEditorPanel.js +34 -0
- package/lib/panelview/story-maps/StoryNavBar.d.ts +10 -0
- package/lib/panelview/story-maps/StoryNavBar.js +11 -0
- package/lib/panelview/story-maps/StoryViewerPanel.d.ts +13 -0
- package/lib/panelview/story-maps/StoryViewerPanel.js +179 -0
- package/lib/panelview/story-maps/components/StoryContentSection.d.ts +6 -0
- package/lib/panelview/story-maps/components/StoryContentSection.js +10 -0
- package/lib/panelview/story-maps/components/StoryImageSection.d.ts +15 -0
- package/lib/panelview/story-maps/components/StoryImageSection.js +13 -0
- package/lib/panelview/story-maps/components/StorySubtitleSection.d.ts +11 -0
- package/lib/panelview/story-maps/components/StorySubtitleSection.js +9 -0
- package/lib/panelview/story-maps/components/StoryTitleSection.d.ts +12 -0
- package/lib/panelview/story-maps/components/StoryTitleSection.js +8 -0
- package/lib/shared/components/Calendar.d.ts +1 -1
- package/lib/shared/components/Combobox.d.ts +21 -0
- package/lib/shared/components/Combobox.js +32 -0
- package/lib/shared/components/Command.d.ts +18 -0
- package/lib/shared/components/Command.js +60 -0
- package/lib/shared/components/Dialog.d.ts +15 -0
- package/lib/shared/components/Dialog.js +62 -0
- package/lib/shared/components/Input.d.ts +3 -0
- package/lib/shared/components/Input.js +18 -0
- package/lib/shared/components/Pagination.js +3 -2
- package/lib/shared/components/RadioGroup.d.ts +5 -0
- package/lib/shared/components/RadioGroup.js +26 -0
- package/lib/shared/components/Select.d.ts +19 -0
- package/lib/shared/components/Select.js +28 -0
- package/lib/shared/components/SingleDatePicker.d.ts +11 -0
- package/lib/shared/components/SingleDatePicker.js +16 -0
- package/lib/shared/components/Switch.d.ts +4 -0
- package/lib/shared/components/Switch.js +20 -0
- package/lib/stacBrowser/components/StacPanel.d.ts +9 -1
- package/lib/stacBrowser/components/StacPanel.js +53 -9
- package/lib/stacBrowser/components/filter-extension/QueryableComboBox.d.ts +9 -0
- package/lib/stacBrowser/components/filter-extension/QueryableComboBox.js +179 -0
- package/lib/stacBrowser/components/filter-extension/QueryableRow.d.ts +16 -0
- package/lib/stacBrowser/components/filter-extension/QueryableRow.js +16 -0
- package/lib/stacBrowser/components/filter-extension/StacFilterExtensionPanel.d.ts +7 -0
- package/lib/stacBrowser/components/filter-extension/StacFilterExtensionPanel.js +49 -0
- package/lib/stacBrowser/components/filter-extension/StacQueryableFilters.d.ts +11 -0
- package/lib/stacBrowser/components/filter-extension/StacQueryableFilters.js +19 -0
- package/lib/stacBrowser/components/{StacFilterSection.d.ts → geodes/StacFilterSection.d.ts} +1 -1
- package/lib/stacBrowser/components/{StacFilterSection.js → geodes/StacFilterSection.js} +3 -3
- package/lib/stacBrowser/components/geodes/StacGeodesFilterPanel.d.ts +7 -0
- package/lib/stacBrowser/components/geodes/StacGeodesFilterPanel.js +69 -0
- package/lib/stacBrowser/components/shared/StacPanelResults.d.ts +3 -0
- package/lib/stacBrowser/components/shared/StacPanelResults.js +68 -0
- package/lib/stacBrowser/components/shared/StacSpatialExtent.d.ts +8 -0
- package/lib/stacBrowser/components/shared/StacSpatialExtent.js +10 -0
- package/lib/stacBrowser/components/shared/StacTemporalExtent.d.ts +9 -0
- package/lib/stacBrowser/components/shared/StacTemporalExtent.js +9 -0
- package/lib/stacBrowser/context/StacResultsContext.d.ts +33 -0
- package/lib/stacBrowser/context/StacResultsContext.js +269 -0
- package/lib/stacBrowser/hooks/useGeodesSearch.d.ts +24 -0
- package/lib/stacBrowser/hooks/useGeodesSearch.js +178 -0
- package/lib/stacBrowser/hooks/useStacFilterExtension.d.ts +30 -0
- package/lib/stacBrowser/hooks/useStacFilterExtension.js +262 -0
- package/lib/stacBrowser/hooks/useStacSearch.d.ts +5 -16
- package/lib/stacBrowser/hooks/useStacSearch.js +30 -184
- package/lib/stacBrowser/types/types.d.ts +86 -3
- package/lib/toolbar/widget.d.ts +15 -0
- package/lib/toolbar/widget.js +70 -0
- package/lib/tools.d.ts +0 -7
- package/lib/tools.js +56 -15
- package/package.json +8 -3
- package/style/base.css +42 -3
- package/style/leftPanel.css +18 -0
- package/style/shared/button.css +6 -5
- package/style/shared/calendar.css +7 -1
- package/style/shared/combobox.css +75 -0
- package/style/shared/command.css +178 -0
- package/style/shared/dialog.css +177 -0
- package/style/shared/input.css +59 -0
- package/style/shared/pagination.css +1 -1
- package/style/shared/popover.css +1 -0
- package/style/shared/radioGroup.css +55 -0
- package/style/shared/switch.css +63 -0
- package/style/shared/tabs.css +4 -3
- package/style/shared/toggle.css +1 -1
- package/style/stacBrowser.css +169 -16
- package/style/statusBar.css +1 -0
- package/style/storyPanel.css +185 -0
- package/style/tabPanel.css +1 -88
- package/lib/stacBrowser/components/StacPanelFilters.d.ts +0 -14
- package/lib/stacBrowser/components/StacPanelFilters.js +0 -81
- package/lib/stacBrowser/components/StacPanelResults.d.ts +0 -13
- package/lib/stacBrowser/components/StacPanelResults.js +0 -48
- /package/lib/panelview/{components/filter-panel → filter-panel}/Filter.d.ts +0 -0
- /package/lib/panelview/{components/filter-panel → filter-panel}/FilterRow.d.ts +0 -0
- /package/lib/panelview/{components/filter-panel → filter-panel}/FilterRow.js +0 -0
- /package/lib/panelview/{components/identify-panel → identify-panel}/IdentifyPanel.d.ts +0 -0
- /package/lib/panelview/{components/identify-panel → identify-panel}/IdentifyPanel.js +0 -0
package/lib/toolbar/widget.d.ts
CHANGED
|
@@ -12,7 +12,22 @@ export declare class Separator extends Widget {
|
|
|
12
12
|
}
|
|
13
13
|
export declare class ToolbarWidget extends ReactiveToolbar {
|
|
14
14
|
private _model;
|
|
15
|
+
private _newSubMenu;
|
|
16
|
+
private _hasSetSpectaVisibility;
|
|
15
17
|
constructor(options: ToolbarWidget.IOptions);
|
|
18
|
+
/**
|
|
19
|
+
* Updates the story segment menu item based on settings
|
|
20
|
+
*/
|
|
21
|
+
private _updateStorySegmentMenuItem;
|
|
22
|
+
/**
|
|
23
|
+
* Handles settings changes
|
|
24
|
+
*/
|
|
25
|
+
private _onSettingsChanged;
|
|
26
|
+
/**
|
|
27
|
+
* Handles story changes to update Specta mode visibility
|
|
28
|
+
*/
|
|
29
|
+
private _onSpectaModeChanged;
|
|
30
|
+
dispose(): void;
|
|
16
31
|
}
|
|
17
32
|
export declare namespace ToolbarWidget {
|
|
18
33
|
interface IOptions extends Toolbar.IOptions {
|
package/lib/toolbar/widget.js
CHANGED
|
@@ -39,8 +39,32 @@ function createUserIconRenderer(model) {
|
|
|
39
39
|
export class ToolbarWidget extends ReactiveToolbar {
|
|
40
40
|
constructor(options) {
|
|
41
41
|
super();
|
|
42
|
+
this._newSubMenu = null;
|
|
43
|
+
this._hasSetSpectaVisibility = false;
|
|
44
|
+
/**
|
|
45
|
+
* Handles settings changes
|
|
46
|
+
*/
|
|
47
|
+
this._onSettingsChanged = (sender, key) => {
|
|
48
|
+
if (key === 'storyMapsDisabled') {
|
|
49
|
+
this._updateStorySegmentMenuItem();
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
/**
|
|
53
|
+
* Handles story changes to update Specta mode visibility
|
|
54
|
+
*/
|
|
55
|
+
this._onSpectaModeChanged = (args) => {
|
|
56
|
+
if (!this._hasSetSpectaVisibility) {
|
|
57
|
+
this.setHidden(this._model.isSpectaMode());
|
|
58
|
+
this._hasSetSpectaVisibility = true;
|
|
59
|
+
}
|
|
60
|
+
};
|
|
42
61
|
this._model = options.model;
|
|
43
62
|
this.addClass('jGIS-toolbar-widget');
|
|
63
|
+
// Listen for settings changes
|
|
64
|
+
this._model.settingsChanged.connect(this._onSettingsChanged, this);
|
|
65
|
+
// Listen for options change because it's the dependable signal
|
|
66
|
+
// Update Specta mode visibility
|
|
67
|
+
this._model.sharedModel.optionsChanged.connect(this._onSpectaModeChanged, this);
|
|
44
68
|
if (options.commands) {
|
|
45
69
|
const openLayersBrowserButton = new CommandToolbarButton({
|
|
46
70
|
id: CommandIDs.openLayerBrowser,
|
|
@@ -51,6 +75,7 @@ export class ToolbarWidget extends ReactiveToolbar {
|
|
|
51
75
|
openLayersBrowserButton.node.dataset.testid = 'open-layers-browser';
|
|
52
76
|
const NewSubMenu = new MenuSvg({ commands: options.commands });
|
|
53
77
|
NewSubMenu.title.label = 'Add Layer';
|
|
78
|
+
this._newSubMenu = NewSubMenu;
|
|
54
79
|
NewSubMenu.addItem({
|
|
55
80
|
type: 'submenu',
|
|
56
81
|
submenu: rasterSubMenu(options.commands),
|
|
@@ -59,6 +84,7 @@ export class ToolbarWidget extends ReactiveToolbar {
|
|
|
59
84
|
type: 'submenu',
|
|
60
85
|
submenu: vectorSubMenu(options.commands),
|
|
61
86
|
});
|
|
87
|
+
this._updateStorySegmentMenuItem();
|
|
62
88
|
const NewEntryButton = new ToolbarButton({
|
|
63
89
|
icon: addIcon,
|
|
64
90
|
noFocusOnClick: false,
|
|
@@ -102,6 +128,13 @@ export class ToolbarWidget extends ReactiveToolbar {
|
|
|
102
128
|
});
|
|
103
129
|
this.addItem('addMarker', addMarkerButton);
|
|
104
130
|
addMarkerButton.node.dataset.testid = 'add-marker-controller-button';
|
|
131
|
+
const storyModePresentationToggleButton = new CommandToolbarButton({
|
|
132
|
+
id: CommandIDs.toggleStoryPresentationMode,
|
|
133
|
+
label: '',
|
|
134
|
+
commands: options.commands,
|
|
135
|
+
});
|
|
136
|
+
this.addItem('toggleStoryPresentationMode', storyModePresentationToggleButton);
|
|
137
|
+
identifyButton.node.dataset.testid = 'toggleStoryPresentationMode-button';
|
|
105
138
|
this.addItem('separator2', new Separator());
|
|
106
139
|
const toggleConsoleButton = new CommandToolbarButton({
|
|
107
140
|
id: CommandIDs.toggleConsole,
|
|
@@ -117,4 +150,41 @@ export class ToolbarWidget extends ReactiveToolbar {
|
|
|
117
150
|
this.addItem('users', ReactWidget.create(React.createElement(UsersItem, { model: this._model, iconRenderer: iconRenderer })));
|
|
118
151
|
}
|
|
119
152
|
}
|
|
153
|
+
/**
|
|
154
|
+
* Updates the story segment menu item based on settings
|
|
155
|
+
*/
|
|
156
|
+
_updateStorySegmentMenuItem() {
|
|
157
|
+
if (!this._newSubMenu) {
|
|
158
|
+
return;
|
|
159
|
+
}
|
|
160
|
+
const shouldShow = !this._model.jgisSettings.storyMapsDisabled;
|
|
161
|
+
// Find if the item already exists by checking menu items
|
|
162
|
+
let itemIndex = null;
|
|
163
|
+
for (let i = 0; i < this._newSubMenu.items.length; i++) {
|
|
164
|
+
const item = this._newSubMenu.items[i];
|
|
165
|
+
if (item.type === 'command' &&
|
|
166
|
+
item.command === CommandIDs.addStorySegment) {
|
|
167
|
+
itemIndex = i;
|
|
168
|
+
break;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
const isCurrentlyAdded = itemIndex !== null;
|
|
172
|
+
if (shouldShow && !isCurrentlyAdded) {
|
|
173
|
+
this._newSubMenu.addItem({
|
|
174
|
+
command: CommandIDs.addStorySegment,
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
else if (!shouldShow && isCurrentlyAdded) {
|
|
178
|
+
if (itemIndex !== null) {
|
|
179
|
+
this._newSubMenu.removeItemAt(itemIndex);
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
dispose() {
|
|
184
|
+
if (this._model) {
|
|
185
|
+
this._model.settingsChanged.disconnect(this._onSettingsChanged, this);
|
|
186
|
+
this._model.sharedModel.storyMapsChanged.disconnect(this._onSpectaModeChanged, this);
|
|
187
|
+
}
|
|
188
|
+
super.dispose();
|
|
189
|
+
}
|
|
120
190
|
}
|
package/lib/tools.d.ts
CHANGED
|
@@ -109,13 +109,6 @@ export declare const MIME_TYPES: {
|
|
|
109
109
|
* @returns A string representing the MIME type.
|
|
110
110
|
*/
|
|
111
111
|
export declare const getMimeType: (filename: string) => string;
|
|
112
|
-
/**
|
|
113
|
-
* Helper to convert a string (base64) to ArrayBuffer.
|
|
114
|
-
*
|
|
115
|
-
* @param content - File content as a base64 string.
|
|
116
|
-
* @returns An ArrayBuffer.
|
|
117
|
-
*/
|
|
118
|
-
export declare const stringToArrayBuffer: (content: string) => Promise<ArrayBuffer>;
|
|
119
112
|
export declare const getFeatureAttributes: <T>(featureProperties: Record<string, Set<any>>, predicate?: (key: string, value: any) => boolean) => Record<string, Set<T>>;
|
|
120
113
|
/**
|
|
121
114
|
* Get attributes of the feature which are numeric.
|
package/lib/tools.js
CHANGED
|
@@ -131,7 +131,7 @@ export function createDefaultLayerRegistry(layerBrowserRegistry) {
|
|
|
131
131
|
}
|
|
132
132
|
// TODO: These need better names
|
|
133
133
|
/**
|
|
134
|
-
* Parse tile information from providers to be
|
|
134
|
+
* Parse tile information from providers to be usable in the layer registry
|
|
135
135
|
*
|
|
136
136
|
* @param entry - The name of the entry, which may also serve as the default provider name if none is specified.
|
|
137
137
|
* @param xyzprovider - An object containing the XYZ provider's details, including name, URL, zoom levels, attribution, and possibly other properties relevant to the provider.
|
|
@@ -449,17 +449,40 @@ export const loadFile = async (fileInfo) => {
|
|
|
449
449
|
}
|
|
450
450
|
switch (type) {
|
|
451
451
|
case 'GeoJSONSource': {
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
452
|
+
switch (file.format) {
|
|
453
|
+
case 'base64': {
|
|
454
|
+
return JSON.parse(atob(file.content));
|
|
455
|
+
}
|
|
456
|
+
case 'text': {
|
|
457
|
+
return JSON.parse(file.content);
|
|
458
|
+
}
|
|
459
|
+
case 'json': {
|
|
460
|
+
return file.content;
|
|
461
|
+
}
|
|
462
|
+
}
|
|
463
|
+
break;
|
|
455
464
|
}
|
|
456
465
|
case 'ShapefileSource': {
|
|
457
|
-
|
|
458
|
-
|
|
466
|
+
let buffer;
|
|
467
|
+
switch (file.format) {
|
|
468
|
+
case 'base64': {
|
|
469
|
+
buffer = await base64ToArrayBuffer(file.content);
|
|
470
|
+
break;
|
|
471
|
+
}
|
|
472
|
+
case 'text': {
|
|
473
|
+
buffer = await stringToArrayBuffer(file.content);
|
|
474
|
+
break;
|
|
475
|
+
}
|
|
476
|
+
case 'json':
|
|
477
|
+
default: {
|
|
478
|
+
throw new Error(`Invalid Shapefile format: ${file.format}.`);
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
const geojson = await shp(buffer);
|
|
459
482
|
return geojson;
|
|
460
483
|
}
|
|
461
484
|
case 'ImageSource': {
|
|
462
|
-
if (
|
|
485
|
+
if (file.format === 'base64') {
|
|
463
486
|
const mimeType = getMimeType(filepath);
|
|
464
487
|
if (!mimeType.startsWith('image/')) {
|
|
465
488
|
throw new Error(`Invalid image file. MIME type: ${mimeType}`);
|
|
@@ -488,14 +511,23 @@ export const loadFile = async (fileInfo) => {
|
|
|
488
511
|
}
|
|
489
512
|
}
|
|
490
513
|
case 'GeoParquetSource': {
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
514
|
+
let buffer;
|
|
515
|
+
switch (file.format) {
|
|
516
|
+
case 'base64': {
|
|
517
|
+
buffer = await base64ToArrayBuffer(file.content);
|
|
518
|
+
break;
|
|
519
|
+
}
|
|
520
|
+
case 'text': {
|
|
521
|
+
buffer = await stringToArrayBuffer(file.content);
|
|
522
|
+
break;
|
|
523
|
+
}
|
|
524
|
+
case 'json':
|
|
525
|
+
default: {
|
|
526
|
+
throw new Error(`Invalid Geoparquet format: ${file.format}.`);
|
|
527
|
+
}
|
|
498
528
|
}
|
|
529
|
+
const { toGeoJson } = await import('geoparquet');
|
|
530
|
+
return await toGeoJson({ file: buffer, compressors });
|
|
499
531
|
}
|
|
500
532
|
default: {
|
|
501
533
|
throw new Error(`Unsupported source type: ${type}`);
|
|
@@ -697,10 +729,19 @@ export const getMimeType = (filename) => {
|
|
|
697
729
|
* @param content - File content as a base64 string.
|
|
698
730
|
* @returns An ArrayBuffer.
|
|
699
731
|
*/
|
|
700
|
-
|
|
732
|
+
const base64ToArrayBuffer = async (content) => {
|
|
701
733
|
const base64Response = await fetch(`data:application/octet-stream;base64,${content}`);
|
|
702
734
|
return await base64Response.arrayBuffer();
|
|
703
735
|
};
|
|
736
|
+
/**
|
|
737
|
+
* Helper to convert a raw string to ArrayBuffer.
|
|
738
|
+
*
|
|
739
|
+
* @param content - Raw string content.
|
|
740
|
+
* @returns An ArrayBuffer.
|
|
741
|
+
*/
|
|
742
|
+
const stringToArrayBuffer = async (content) => {
|
|
743
|
+
return new TextEncoder().encode(content).buffer;
|
|
744
|
+
};
|
|
704
745
|
export const getFeatureAttributes = (featureProperties, predicate = (key, value) => true) => {
|
|
705
746
|
const filteredRecord = {};
|
|
706
747
|
for (const [key, set] of Object.entries(featureProperties)) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jupytergis/base",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.0",
|
|
4
4
|
"description": "A JupyterLab extension for 3D modelling.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jupyter",
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
"@fortawesome/fontawesome-svg-core": "^6.5.2",
|
|
42
42
|
"@fortawesome/free-solid-svg-icons": "^6.5.2",
|
|
43
43
|
"@fortawesome/react-fontawesome": ">=0.2.6 <3.0.0",
|
|
44
|
-
"@jupyter/collaboration": "^
|
|
44
|
+
"@jupyter/collaboration": "^4",
|
|
45
45
|
"@jupyter/react-components": "^0.16.6",
|
|
46
46
|
"@jupyter/ydoc": "^2.0.0 || ^3.0.0",
|
|
47
|
-
"@jupytergis/schema": "^0.
|
|
47
|
+
"@jupytergis/schema": "^0.12.0",
|
|
48
48
|
"@jupyterlab/application": "^4.3.0",
|
|
49
49
|
"@jupyterlab/apputils": "^4.3.0",
|
|
50
50
|
"@jupyterlab/completer": "^4.3.0",
|
|
@@ -65,9 +65,12 @@
|
|
|
65
65
|
"@mapbox/vector-tile": "^2.0.3",
|
|
66
66
|
"@naisutech/react-tree": "^3.0.1",
|
|
67
67
|
"@radix-ui/react-checkbox": "^1.3.2",
|
|
68
|
+
"@radix-ui/react-dialog": "^1.1.15",
|
|
68
69
|
"@radix-ui/react-dropdown-menu": "^2.1.15",
|
|
69
70
|
"@radix-ui/react-popover": "^1.1.14",
|
|
71
|
+
"@radix-ui/react-radio-group": "^1.3.8",
|
|
70
72
|
"@radix-ui/react-slot": "^1.2.3",
|
|
73
|
+
"@radix-ui/react-switch": "^1.2.6",
|
|
71
74
|
"@radix-ui/react-tabs": "^1.1.12",
|
|
72
75
|
"@radix-ui/react-toggle-group": "^1.1.10",
|
|
73
76
|
"@rjsf/core": "^4.2.0",
|
|
@@ -75,6 +78,7 @@
|
|
|
75
78
|
"ajv": "^8.14.0",
|
|
76
79
|
"class-variance-authority": "^0.7.1",
|
|
77
80
|
"clsx": "^2.1.1",
|
|
81
|
+
"cmdk": "^1.1.1",
|
|
78
82
|
"colormap": "^2.3.2",
|
|
79
83
|
"d3-color": "^3.1.0",
|
|
80
84
|
"date-fns": "^4.1.0",
|
|
@@ -93,6 +97,7 @@
|
|
|
93
97
|
"proj4-list": "1.0.4",
|
|
94
98
|
"react": "^18.0.1",
|
|
95
99
|
"react-day-picker": "^9.7.0",
|
|
100
|
+
"react-markdown": "^10.1.0",
|
|
96
101
|
"shpjs": "^6.1.0",
|
|
97
102
|
"styled-components": "^5.3.6",
|
|
98
103
|
"three": "^0.135.0",
|
package/style/base.css
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
| Distributed under the terms of the Modified BSD License.
|
|
4
4
|
|---------------------------------------------------------------------------- */
|
|
5
5
|
|
|
6
|
+
@import url('ol/ol.css');
|
|
6
7
|
@import url('./dialog.css');
|
|
7
8
|
@import url('./layerBrowser.css');
|
|
8
9
|
@import url('./leftPanel.css');
|
|
@@ -11,7 +12,8 @@
|
|
|
11
12
|
@import url('./statusBar.css');
|
|
12
13
|
@import url('./temporalSlider.css');
|
|
13
14
|
@import url('./tabPanel.css');
|
|
14
|
-
@import url('
|
|
15
|
+
@import url('./stacBrowser.css');
|
|
16
|
+
@import url('./storyPanel.css');
|
|
15
17
|
@import url('./shared/button.css');
|
|
16
18
|
@import url('./shared/toggle.css');
|
|
17
19
|
@import url('./shared/tabs.css');
|
|
@@ -20,6 +22,13 @@
|
|
|
20
22
|
@import url('./shared/dropdownMenu.css');
|
|
21
23
|
@import url('./shared/badge.css');
|
|
22
24
|
@import url('./shared/checkbox.css');
|
|
25
|
+
@import url('./shared/radioGroup.css');
|
|
26
|
+
@import url('./shared/dialog.css');
|
|
27
|
+
@import url('./shared/switch.css');
|
|
28
|
+
@import url('./shared/popover.css');
|
|
29
|
+
@import url('./shared/command.css');
|
|
30
|
+
@import url('./shared/combobox.css');
|
|
31
|
+
@import url('./shared/input.css');
|
|
23
32
|
|
|
24
33
|
.errors {
|
|
25
34
|
color: var(--jp-warn-color0);
|
|
@@ -88,7 +97,6 @@ button.jp-mod-styled.jp-mod-reject {
|
|
|
88
97
|
|
|
89
98
|
.jgis-right-panel-container {
|
|
90
99
|
width: 330px;
|
|
91
|
-
top: 30px;
|
|
92
100
|
right: 0px;
|
|
93
101
|
position: absolute;
|
|
94
102
|
margin: 5px;
|
|
@@ -98,12 +106,43 @@ button.jp-mod-styled.jp-mod-reject {
|
|
|
98
106
|
.jgis-left-panel-container {
|
|
99
107
|
position: absolute;
|
|
100
108
|
width: 250px;
|
|
101
|
-
top: 30px;
|
|
102
109
|
left: 0px;
|
|
103
110
|
margin: 5px;
|
|
104
111
|
z-index: 40;
|
|
105
112
|
}
|
|
106
113
|
|
|
114
|
+
.jgis-icon-adjust {
|
|
115
|
+
padding-top: 5px;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.jgis-controls-toolbar {
|
|
119
|
+
width: 100%;
|
|
120
|
+
display: flex;
|
|
121
|
+
justify-content: flex-start;
|
|
122
|
+
align-items: flex-end;
|
|
123
|
+
gap: 0.5rem;
|
|
124
|
+
position: absolute;
|
|
125
|
+
bottom: 0.125rem;
|
|
126
|
+
z-index: 1000;
|
|
127
|
+
padding: 0 0.125rem;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.jgis-controls-toolbar .ol-control,
|
|
131
|
+
.jgis-controls-toolbar .ol-scale-line,
|
|
132
|
+
.jgis-controls-toolbar .ol-full-screen {
|
|
133
|
+
position: relative;
|
|
134
|
+
top: unset;
|
|
135
|
+
bottom: unset;
|
|
136
|
+
left: unset;
|
|
137
|
+
right: unset;
|
|
138
|
+
margin: 0;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.jgis-controls-toolbar .ol-zoom {
|
|
142
|
+
position: fixed;
|
|
143
|
+
right: 0.125rem;
|
|
144
|
+
}
|
|
145
|
+
|
|
107
146
|
@media (max-width: 768px) {
|
|
108
147
|
.jgis-panels-wrapper {
|
|
109
148
|
position: fixed;
|
package/style/leftPanel.css
CHANGED
|
@@ -138,6 +138,24 @@
|
|
|
138
138
|
.jp-gis-sourceText {
|
|
139
139
|
padding: 3px 0;
|
|
140
140
|
cursor: pointer;
|
|
141
|
+
flex-grow: 1;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.jp-gis-layerSlideNumber {
|
|
145
|
+
box-sizing: border-box;
|
|
146
|
+
display: inline-flex;
|
|
147
|
+
align-items: center;
|
|
148
|
+
justify-content: center;
|
|
149
|
+
min-width: 18px;
|
|
150
|
+
height: 18px;
|
|
151
|
+
padding: 0 6px;
|
|
152
|
+
margin-right: 4px;
|
|
153
|
+
background-color: var(--jp-brand-color1);
|
|
154
|
+
color: var(--jp-ui-inverse-font-color1);
|
|
155
|
+
border-radius: 9999px;
|
|
156
|
+
font-size: var(--jp-ui-font-size0);
|
|
157
|
+
font-weight: 600;
|
|
158
|
+
line-height: 1;
|
|
141
159
|
}
|
|
142
160
|
|
|
143
161
|
li .lm-Menu-itemLabel {
|
package/style/shared/button.css
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
.jgis-button {
|
|
2
|
+
box-sizing: border-box;
|
|
2
3
|
display: inline-flex;
|
|
3
4
|
align-items: center;
|
|
4
5
|
justify-content: center;
|
|
5
6
|
white-space: nowrap;
|
|
6
|
-
border-radius: 0.375rem;
|
|
7
|
+
border-radius: var(--jp-border-radius, 0.375rem);
|
|
7
8
|
font-size: 0.875rem;
|
|
8
9
|
font-weight: 600;
|
|
9
10
|
outline: none;
|
|
10
11
|
background-color: var(--jp-layout-color0);
|
|
11
12
|
color: var(--jp-ui-font-color0);
|
|
12
13
|
border: 0.0375rem solid
|
|
13
|
-
color-mix(in srgb, var(--jp-
|
|
14
|
+
color-mix(in srgb, var(--jp-border-color1), transparent 20%);
|
|
14
15
|
transition: background-color 0.2s ease;
|
|
15
|
-
height: 2.
|
|
16
|
+
height: 2.25rem;
|
|
16
17
|
padding-left: 1rem;
|
|
17
18
|
padding-right: 1rem;
|
|
18
19
|
padding-top: 0.5rem;
|
|
@@ -146,14 +147,14 @@
|
|
|
146
147
|
/* sizing */
|
|
147
148
|
.jgis-button[data-size='sm'] {
|
|
148
149
|
height: 2.25rem;
|
|
149
|
-
border-radius: 0.375rem;
|
|
150
|
+
border-radius: var(--jp-border-radius, 0.375rem);
|
|
150
151
|
padding-left: 0.75rem;
|
|
151
152
|
padding-right: 0.75rem;
|
|
152
153
|
}
|
|
153
154
|
|
|
154
155
|
.jgis-button[data-size='lg'] {
|
|
155
156
|
height: 2.75rem;
|
|
156
|
-
border-radius: 0.375rem;
|
|
157
|
+
border-radius: var(--jp-border-radius, 0.375rem);
|
|
157
158
|
padding-left: 2rem;
|
|
158
159
|
padding-right: 2rem;
|
|
159
160
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
.jgis-calendar-container {
|
|
2
2
|
padding: 0.75rem;
|
|
3
3
|
background-color: var(--jp-layout-color2);
|
|
4
|
-
border: 1px solid var(--jp-
|
|
4
|
+
border: 1px solid var(--jp-border-color0);
|
|
5
5
|
border-radius: var(--jp-border-radius);
|
|
6
6
|
}
|
|
7
7
|
|
|
@@ -272,3 +272,9 @@
|
|
|
272
272
|
height: 2.5rem;
|
|
273
273
|
align-items: center;
|
|
274
274
|
}
|
|
275
|
+
|
|
276
|
+
/* Unset width and border when popover contains calendar */
|
|
277
|
+
.jgis-popover-content:has(> .jgis-calendar-container) {
|
|
278
|
+
width: unset;
|
|
279
|
+
border: unset;
|
|
280
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/* Shared base styles for Select and Combobox buttons */
|
|
2
|
+
/* More specific selector to override button base styles */
|
|
3
|
+
.jgis-button.jgis-combobox-button,
|
|
4
|
+
.jgis-button.jgis-select-button {
|
|
5
|
+
display: flex;
|
|
6
|
+
justify-content: space-between;
|
|
7
|
+
align-items: center;
|
|
8
|
+
white-space: preserve-breaks;
|
|
9
|
+
padding: 1rem 0.5rem;
|
|
10
|
+
box-sizing: border-box;
|
|
11
|
+
border-radius: var(--jp-border-radius, 0.375rem);
|
|
12
|
+
border: 1px solid var(--jp-border-color0);
|
|
13
|
+
background-color: var(--jp-layout-color0);
|
|
14
|
+
color: var(--jp-ui-font-color0);
|
|
15
|
+
font-size: 0.875rem;
|
|
16
|
+
/* min-height: 1.125rem; */
|
|
17
|
+
height: 1.5rem;
|
|
18
|
+
max-width: none;
|
|
19
|
+
gap: 0;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.jgis-combobox-button-text,
|
|
23
|
+
.jgis-select-button-text {
|
|
24
|
+
flex: 1;
|
|
25
|
+
min-width: 0;
|
|
26
|
+
overflow-wrap: break-word;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.jgis-combobox-icon,
|
|
30
|
+
.jgis-select-icon {
|
|
31
|
+
margin-left: 0.5rem;
|
|
32
|
+
margin-top: 0.125rem;
|
|
33
|
+
height: 1rem;
|
|
34
|
+
width: 1rem;
|
|
35
|
+
flex-shrink: 0;
|
|
36
|
+
opacity: 0.5;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/* Shared Popover styles */
|
|
40
|
+
.jgis-combobox-popover,
|
|
41
|
+
.jgis-select-popover {
|
|
42
|
+
width: 200px;
|
|
43
|
+
padding: 0;
|
|
44
|
+
border-radius: var(--jp-border-radius, 0.375rem);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/* Check icon for Combobox (multi-select) */
|
|
48
|
+
.jgis-combobox-check-icon {
|
|
49
|
+
margin-right: 0.5rem;
|
|
50
|
+
height: 1rem;
|
|
51
|
+
width: 1rem;
|
|
52
|
+
flex-shrink: 0;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/* Modifier classes - use higher specificity to override base */
|
|
56
|
+
.jgis-button.jgis-combobox-button--full-width,
|
|
57
|
+
.jgis-button.jgis-select-button--full-width {
|
|
58
|
+
width: 100%;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.jgis-button.jgis-combobox-button--max-width-200,
|
|
62
|
+
.jgis-button.jgis-select-button--max-width-200 {
|
|
63
|
+
max-width: 200px;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.jgis-button.jgis-combobox-button--no-radius,
|
|
67
|
+
.jgis-button.jgis-select-button--no-radius {
|
|
68
|
+
border-radius: 0;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.jgis-button.jgis-combobox-button--queryable-input,
|
|
72
|
+
.jgis-button.jgis-select-button--queryable-input {
|
|
73
|
+
padding: 0.25rem 1rem;
|
|
74
|
+
border-radius: 0;
|
|
75
|
+
}
|