@jupytergis/base 0.15.0 → 0.16.0-alpha.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 +5 -0
- package/lib/commands/BaseCommandIDs.js +5 -0
- package/lib/commands/index.js +218 -47
- package/lib/commands/operationCommands.js +2 -2
- package/lib/constants.js +5 -1
- package/lib/{panelview/annotationPanel.js → features/annotations/AnnotationsPanel.js} +1 -1
- package/lib/{annotations → features/annotations}/index.d.ts +1 -0
- package/lib/{annotations → features/annotations}/index.js +1 -0
- package/lib/{console → features/console}/consoleview.js +1 -1
- package/lib/{panelview/filter-panel → features/filter}/Filter.js +4 -4
- package/lib/{panelview/filter-panel → features/filter}/FilterRow.d.ts +3 -2
- package/lib/{panelview/filter-panel → features/filter}/FilterRow.js +2 -1
- package/lib/{panelview/identify-panel → features/identify}/IdentifyPanel.d.ts +2 -0
- package/lib/features/identify/IdentifyPanel.js +102 -0
- package/lib/features/identify/components/FeatureCard.d.ts +17 -0
- package/lib/features/identify/components/FeatureCard.js +26 -0
- package/lib/features/identify/components/FeatureCardHeader.d.ts +11 -0
- package/lib/features/identify/components/FeatureCardHeader.js +30 -0
- package/lib/features/identify/components/FeatureFloater.d.ts +7 -0
- package/lib/features/identify/components/FeatureFloater.js +19 -0
- package/lib/features/identify/components/FeaturePropertyList.d.ts +11 -0
- package/lib/features/identify/components/FeaturePropertyList.js +18 -0
- package/lib/features/identify/components/FeatureRow.d.ts +13 -0
- package/lib/features/identify/components/FeatureRow.js +25 -0
- package/lib/features/identify/components/PropertyEditors.d.ts +44 -0
- package/lib/features/identify/components/PropertyEditors.js +56 -0
- package/lib/features/identify/hooks/useIdentifyPropertyEditor.d.ts +11 -0
- package/lib/features/identify/hooks/useIdentifyPropertyEditor.js +132 -0
- package/lib/features/identify/types/editorTypes.d.ts +21 -0
- package/lib/features/identify/utils/getFeatureIdentifier.d.ts +5 -0
- package/lib/features/identify/utils/getFeatureIdentifier.js +14 -0
- package/lib/features/identify/utils/highlightLayer.d.ts +11 -0
- package/lib/features/identify/utils/highlightLayer.js +57 -0
- package/lib/features/identify/utils/highlightStyle.d.ts +7 -0
- package/lib/features/identify/utils/highlightStyle.js +40 -0
- package/lib/{dialogs/layerBrowserDialog.js → features/layer-browser/index.js} +2 -2
- package/lib/features/layers/forms/layer/geoTiffLayerForm.d.ts +3 -0
- package/lib/{formbuilder/objectform/layer/webGlLayerForm.js → features/layers/forms/layer/geoTiffLayerForm.js} +5 -5
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/heatmapLayerForm.js +4 -4
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/hillshadeLayerForm.js +4 -4
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/index.d.ts +1 -1
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/index.js +1 -1
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/layerform.d.ts +1 -1
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/layerform.js +4 -4
- package/lib/features/layers/forms/layer/storySegmentLayerForm.js +150 -0
- package/lib/{formbuilder/objectform → features/layers/forms}/layer/vectorlayerform.js +4 -4
- package/lib/{formbuilder/objectform → features/layers/forms}/source/geojsonsource.js +5 -5
- package/lib/features/layers/forms/source/geopackagesource.d.ts +3 -0
- package/lib/features/layers/forms/source/geopackagesource.js +93 -0
- package/lib/{formbuilder/objectform → features/layers/forms}/source/geotiffsource.js +5 -5
- package/lib/{formbuilder/objectform → features/layers/forms}/source/index.d.ts +1 -0
- package/lib/{formbuilder/objectform → features/layers/forms}/source/index.js +1 -0
- package/lib/{formbuilder/objectform → features/layers/forms}/source/pathbasedsource.js +5 -5
- package/lib/{formbuilder/objectform → features/layers/forms}/source/sourceform.d.ts +1 -1
- package/lib/{formbuilder/objectform → features/layers/forms}/source/sourceform.js +4 -4
- package/lib/{formbuilder/objectform → features/layers/forms}/source/tilesourceform.js +4 -4
- package/lib/{formbuilder/objectform → features/layers/forms}/source/wmsTileSource.d.ts +1 -1
- package/lib/{formbuilder/objectform → features/layers/forms}/source/wmsTileSource.js +6 -6
- package/lib/{dialogs → features/layers}/layerCreationFormDialog.d.ts +1 -1
- package/lib/{dialogs → features/layers}/layerCreationFormDialog.js +1 -1
- package/lib/features/layers/symbology/Grammar.d.ts +11 -0
- package/lib/features/layers/symbology/Grammar.js +235 -0
- package/lib/{dialogs/symbology/vector_layer/types → features/layers/symbology}/Heatmap.d.ts +1 -1
- package/lib/{dialogs/symbology/vector_layer/types → features/layers/symbology}/Heatmap.js +30 -10
- package/lib/{dialogs → features/layers}/symbology/classificationModes.d.ts +6 -6
- package/lib/{dialogs → features/layers}/symbology/classificationModes.js +48 -44
- package/lib/{dialogs → features/layers}/symbology/colorRampUtils.d.ts +1 -0
- package/lib/{dialogs → features/layers}/symbology/colorRampUtils.js +12 -1
- package/lib/features/layers/symbology/components/MappingRow.d.ts +40 -0
- package/lib/features/layers/symbology/components/MappingRow.js +516 -0
- package/lib/features/layers/symbology/components/NumericInput.d.ts +20 -0
- package/lib/features/layers/symbology/components/NumericInput.js +44 -0
- package/lib/features/layers/symbology/components/ScaleEditor.d.ts +33 -0
- package/lib/features/layers/symbology/components/ScaleEditor.js +221 -0
- package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ColorRampControls.d.ts +1 -1
- package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ColorRampControls.js +3 -2
- package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ColorRampSelector.d.ts +2 -1
- package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ColorRampSelector.js +6 -1
- package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ModeSelectRow.d.ts +1 -1
- package/lib/{dialogs → features/layers}/symbology/components/color_ramp/RgbaColorPicker.js +39 -9
- package/lib/{dialogs → features/layers}/symbology/components/color_stops/StopRow.d.ts +1 -1
- package/lib/{dialogs → features/layers}/symbology/components/color_stops/StopRow.js +1 -1
- package/lib/features/layers/symbology/grammarToOLLayer.d.ts +27 -0
- package/lib/features/layers/symbology/grammarToOLLayer.js +145 -0
- package/lib/features/layers/symbology/grammarToOLStyle.d.ts +32 -0
- package/lib/features/layers/symbology/grammarToOLStyle.js +467 -0
- package/lib/{dialogs → features/layers}/symbology/hooks/useGetBandInfo.d.ts +1 -1
- package/lib/{dialogs → features/layers}/symbology/hooks/useGetBandInfo.js +1 -1
- package/lib/{dialogs → features/layers}/symbology/hooks/useGetProperties.js +1 -1
- package/lib/{dialogs → features/layers}/symbology/hooks/useGetSymbology.js +4 -2
- package/lib/features/layers/symbology/styleBuilder.d.ts +21 -0
- package/lib/features/layers/symbology/styleBuilder.js +145 -0
- package/lib/{dialogs → features/layers}/symbology/symbologyDialog.d.ts +1 -1
- package/lib/{dialogs → features/layers}/symbology/symbologyDialog.js +12 -12
- package/lib/{dialogs → features/layers}/symbology/symbologyUtils.d.ts +18 -10
- package/lib/{dialogs → features/layers}/symbology/symbologyUtils.js +0 -84
- package/lib/{panelview/objectproperties.d.ts → features/objectproperties/index.d.ts} +1 -1
- package/lib/{panelview/objectproperties.js → features/objectproperties/index.js} +5 -10
- package/lib/{dialogs → features/processing}/ProcessingFormDialog.d.ts +1 -1
- package/lib/{dialogs → features/processing}/ProcessingFormDialog.js +28 -14
- package/lib/features/processing/forms/MapExtentToggle.d.ts +13 -0
- package/lib/features/processing/forms/MapExtentToggle.js +20 -0
- package/lib/features/processing/forms/clipRasterByExtentForm.d.ts +10 -0
- package/lib/features/processing/forms/clipRasterByExtentForm.js +99 -0
- package/lib/{formbuilder/objectform/process → features/processing/forms}/dissolveProcessForm.js +5 -5
- package/lib/{formbuilder/objectform → features/processing/forms}/processingForm.d.ts +1 -1
- package/lib/{formbuilder/objectform → features/processing/forms}/processingForm.js +6 -6
- package/lib/features/processing/forms/rasterizeForm.d.ts +10 -0
- package/lib/features/processing/forms/rasterizeForm.js +75 -0
- package/lib/features/processing/forms/useMapExtent.d.ts +22 -0
- package/lib/features/processing/forms/useMapExtent.js +57 -0
- package/lib/{processing → features/processing}/index.d.ts +19 -2
- package/lib/features/processing/index.js +1246 -0
- package/lib/{processing → features/processing}/processingCommands.d.ts +1 -1
- package/lib/features/processing/processingCommands.js +168 -0
- package/lib/features/processing/serverProcessing.d.ts +51 -0
- package/lib/features/processing/serverProcessing.js +99 -0
- package/lib/{stacBrowser → features/stac-browser}/components/StacPanel.js +2 -2
- package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/QueryableComboBox.js +5 -5
- package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/QueryableRow.js +1 -1
- package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/StacFilterExtensionPanel.js +2 -2
- package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/StacQueryableFilters.js +1 -1
- package/lib/{stacBrowser → features/stac-browser}/components/geodes/StacFilterSection.js +3 -3
- package/lib/{stacBrowser → features/stac-browser}/components/shared/StacPanelResults.js +3 -3
- package/lib/{stacBrowser → features/stac-browser}/components/shared/StacSpatialExtent.js +1 -1
- package/lib/{stacBrowser → features/stac-browser}/components/shared/StacTemporalExtent.js +1 -1
- package/lib/{stacBrowser → features/stac-browser}/context/StacResultsContext.js +2 -2
- package/lib/{stacBrowser → features/stac-browser}/hooks/useGeodesSearch.js +2 -2
- package/lib/{stacBrowser → features/stac-browser}/hooks/useStacFilterExtension.js +3 -3
- package/lib/{stacBrowser → features/stac-browser}/hooks/useStacSearch.js +1 -1
- package/lib/features/stac-browser/types/types.js +1 -0
- package/lib/{panelview/story-maps → features/story}/SpectaPanel.d.ts +4 -1
- package/lib/{panelview/story-maps → features/story}/SpectaPanel.js +3 -4
- package/lib/{panelview/story-maps → features/story}/StoryEditorPanel.js +1 -1
- package/lib/{panelview/story-maps → features/story}/StoryViewerPanel.d.ts +12 -11
- package/lib/features/story/StoryViewerPanel.js +64 -0
- package/lib/features/story/__tests__/fixtures/listStoryTestItems.d.ts +9 -0
- package/lib/features/story/__tests__/fixtures/listStoryTestItems.js +21 -0
- package/lib/features/story/components/ListStoryMapOverlayPanel.d.ts +10 -0
- package/lib/features/story/components/ListStoryMapOverlayPanel.js +11 -0
- package/lib/features/story/components/ListStoryMarkdownMeasurePane.d.ts +11 -0
- package/lib/features/story/components/ListStoryMarkdownMeasurePane.js +55 -0
- package/lib/features/story/components/ListStoryOverlayMarkdown.d.ts +15 -0
- package/lib/features/story/components/ListStoryOverlayMarkdown.js +93 -0
- package/lib/features/story/components/ListStoryStageOverlay.d.ts +12 -0
- package/lib/features/story/components/ListStoryStageOverlay.js +132 -0
- package/lib/features/story/components/ListStoryVirtualScrollTrack.d.ts +6 -0
- package/lib/features/story/components/ListStoryVirtualScrollTrack.js +7 -0
- package/lib/{panelview/story-maps → features/story}/components/SpectaDesktopView.d.ts +4 -2
- package/lib/features/story/components/SpectaDesktopView.js +67 -0
- package/lib/{panelview/story-maps → features/story}/components/SpectaMobileView.d.ts +2 -4
- package/lib/{panelview/story-maps → features/story}/components/SpectaMobileView.js +3 -3
- package/lib/features/story/components/SpectaSingleModeContent.d.ts +18 -0
- package/lib/features/story/components/SpectaSingleModeContent.js +8 -0
- package/lib/features/story/context/ListStoryScrollTrackContext.d.ts +15 -0
- package/lib/features/story/context/ListStoryScrollTrackContext.js +142 -0
- package/lib/features/story/hooks/useCurrentSegmentIndex.d.ts +3 -0
- package/lib/features/story/hooks/useCurrentSegmentIndex.js +17 -0
- package/lib/features/story/hooks/useListStoryScroll.d.ts +15 -0
- package/lib/features/story/hooks/useListStoryScroll.js +107 -0
- package/lib/features/story/hooks/useQueuedMarkdownHeightMeasure.d.ts +19 -0
- package/lib/features/story/hooks/useQueuedMarkdownHeightMeasure.js +56 -0
- package/lib/features/story/hooks/useStoryImagePreload.d.ts +1 -0
- package/lib/features/story/hooks/useStoryImagePreload.js +24 -0
- package/lib/{panelview/story-maps → features/story}/hooks/useStoryMap.d.ts +2 -7
- package/lib/{panelview/story-maps → features/story}/hooks/useStoryMap.js +20 -44
- package/lib/features/story/hooks/useStoryScrollState.d.ts +21 -0
- package/lib/features/story/hooks/useStoryScrollState.js +39 -0
- package/lib/features/story/hooks/useStorySegmentSync.d.ts +8 -0
- package/lib/features/story/hooks/useStorySegmentSync.js +51 -0
- package/lib/features/story/types/types.d.ts +38 -0
- package/lib/features/story/types/types.js +1 -0
- package/lib/features/story/utils/computeListStoryScrollState.d.ts +12 -0
- package/lib/features/story/utils/computeListStoryScrollState.js +70 -0
- package/lib/features/story/utils/listStoryMeasureQueue.d.ts +11 -0
- package/lib/features/story/utils/listStoryMeasureQueue.js +14 -0
- package/lib/features/story/utils/listStoryScrollTrack.d.ts +17 -0
- package/lib/features/story/utils/listStoryScrollTrack.js +72 -0
- package/lib/features/story/utils/spectaPresentation.d.ts +9 -0
- package/lib/features/story/utils/spectaPresentation.js +37 -0
- package/lib/features/story/utils/storySegmentViewItems.d.ts +5 -0
- package/lib/features/story/utils/storySegmentViewItems.js +30 -0
- package/lib/index.d.ts +11 -9
- package/lib/index.js +11 -9
- package/lib/keybindings.json +5 -0
- package/lib/mainview/OpenEOTileLayer.d.ts +49 -0
- package/lib/mainview/OpenEOTileLayer.js +179 -0
- package/lib/mainview/TemporalSlider.js +11 -9
- package/lib/mainview/geoJsonFeaturePatch.d.ts +9 -0
- package/lib/mainview/geoJsonFeaturePatch.js +43 -0
- package/lib/mainview/mainView.d.ts +90 -7
- package/lib/mainview/mainView.js +1196 -586
- package/lib/mainview/mainviewwidget.d.ts +5 -1
- package/lib/mainview/mainviewwidget.js +4 -2
- package/lib/shared/components/Button.d.ts +1 -1
- package/lib/shared/components/DropdownMenu.d.ts +1 -0
- package/lib/shared/components/DropdownMenu.js +3 -2
- package/lib/shared/components/NativeSelect.d.ts +8 -0
- package/lib/shared/components/NativeSelect.js +29 -0
- package/lib/shared/components/Tabs.d.ts +3 -3
- package/lib/shared/components/Tabs.js +5 -5
- package/lib/{formbuilder → shared/formbuilder}/creationform.js +71 -4
- package/lib/{formbuilder → shared/formbuilder}/editform.js +1 -1
- package/lib/{formbuilder → shared/formbuilder}/formselectors.d.ts +2 -2
- package/lib/{formbuilder → shared/formbuilder}/formselectors.js +10 -4
- package/lib/shared/formbuilder/index.d.ts +4 -0
- package/lib/shared/formbuilder/index.js +4 -0
- package/lib/{formbuilder → shared/formbuilder}/objectform/SchemaForm.d.ts +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/StoryEditorForm.d.ts +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/StoryEditorForm.js +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/components/LayerSelect.js +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/components/SegmentFormSymbology.js +4 -4
- package/lib/{formbuilder → shared/formbuilder}/objectform/components/SourcePropertiesField.js +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/components/StorySegmentReset.js +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/components/WmsTileSourceUrlInput.js +4 -4
- package/lib/{formbuilder → shared/formbuilder}/objectform/fileselectorwidget.js +8 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/schemaUtils.d.ts +3 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/schemaUtils.js +11 -0
- package/lib/{formbuilder → shared/formbuilder}/objectform/useSchemaFormState.d.ts +1 -1
- package/lib/{formbuilder → shared/formbuilder}/objectform/useSchemaFormState.js +1 -1
- package/lib/{icons.d.ts → shared/icons.d.ts} +2 -0
- package/lib/{icons.js → shared/icons.js} +28 -18
- package/lib/tools.d.ts +2 -0
- package/lib/tools.js +138 -4
- package/lib/types.d.ts +6 -1
- package/lib/types.js +6 -1
- package/lib/{menus.js → workspace/menus.js} +10 -2
- package/lib/workspace/panels/components/TabbedPanel.d.ts +17 -0
- package/lib/workspace/panels/components/TabbedPanel.js +19 -0
- package/lib/{panelview → workspace/panels}/components/layers.js +63 -18
- package/lib/workspace/panels/components/legendItem.js +680 -0
- package/lib/workspace/panels/hooks/useLayerTree.d.ts +19 -0
- package/lib/workspace/panels/hooks/useLayerTree.js +103 -0
- package/lib/workspace/panels/hooks/useRightPanelOptions.d.ts +27 -0
- package/lib/workspace/panels/hooks/useRightPanelOptions.js +72 -0
- package/lib/workspace/panels/hooks/useUIState.d.ts +2 -0
- package/lib/workspace/panels/hooks/useUIState.js +25 -0
- package/lib/{panelview → workspace/panels}/index.d.ts +1 -1
- package/lib/{panelview → workspace/panels}/index.js +1 -1
- package/lib/{panelview → workspace/panels}/leftpanel.d.ts +1 -1
- package/lib/workspace/panels/leftpanel.js +70 -0
- package/lib/{panelview/rightpanel.d.ts → workspace/panels/mergedpanel.d.ts} +6 -5
- package/lib/workspace/panels/mergedpanel.js +166 -0
- package/lib/workspace/panels/rightpanel.d.ts +25 -0
- package/lib/{panelview → workspace/panels}/rightpanel.js +53 -63
- package/lib/{statusbar → workspace/statusbar}/StatusBar.js +5 -4
- package/lib/{toolbar → workspace/toolbar}/widget.d.ts +2 -0
- package/lib/{toolbar → workspace/toolbar}/widget.js +33 -5
- package/lib/{widget.d.ts → workspace/widget.d.ts} +7 -5
- package/lib/{widget.js → workspace/widget.js} +16 -7
- package/package.json +16 -4
- package/style/base.css +109 -1
- package/style/icons/geopackage.svg +95 -0
- package/style/icons/pencil_solid.svg +7 -0
- package/style/identify.css +95 -0
- package/style/layerBrowser.css +28 -0
- package/style/leftPanel.css +25 -0
- package/style/shared/button.css +12 -0
- package/style/shared/dropdownMenu.css +9 -0
- package/style/shared/nativeSelect.css +75 -0
- package/style/shared/tabs.css +1 -1
- package/style/spectaProgressBar.css +0 -1
- package/style/storyPanel.css +140 -9
- package/style/storySpectaArticleOverlay.css +129 -0
- package/style/symbologyDialog.css +285 -27
- package/lib/dialogs/symbology/tiff_layer/TiffRendering.d.ts +0 -4
- package/lib/dialogs/symbology/tiff_layer/TiffRendering.js +0 -42
- package/lib/dialogs/symbology/tiff_layer/components/BandRow.d.ts +0 -23
- package/lib/dialogs/symbology/tiff_layer/components/BandRow.js +0 -59
- package/lib/dialogs/symbology/tiff_layer/types/MultibandColor.d.ts +0 -4
- package/lib/dialogs/symbology/tiff_layer/types/MultibandColor.js +0 -92
- package/lib/dialogs/symbology/tiff_layer/types/SingleBandPseudoColor.d.ts +0 -5
- package/lib/dialogs/symbology/tiff_layer/types/SingleBandPseudoColor.js +0 -313
- package/lib/dialogs/symbology/vector_layer/VectorRendering.d.ts +0 -4
- package/lib/dialogs/symbology/vector_layer/VectorRendering.js +0 -112
- package/lib/dialogs/symbology/vector_layer/components/ValueSelect.d.ts +0 -8
- package/lib/dialogs/symbology/vector_layer/components/ValueSelect.js +0 -9
- package/lib/dialogs/symbology/vector_layer/types/Canonical.d.ts +0 -4
- package/lib/dialogs/symbology/vector_layer/types/Canonical.js +0 -130
- package/lib/dialogs/symbology/vector_layer/types/Categorized.d.ts +0 -4
- package/lib/dialogs/symbology/vector_layer/types/Categorized.js +0 -243
- package/lib/dialogs/symbology/vector_layer/types/Graduated.d.ts +0 -4
- package/lib/dialogs/symbology/vector_layer/types/Graduated.js +0 -362
- package/lib/dialogs/symbology/vector_layer/types/SimpleSymbol.d.ts +0 -4
- package/lib/dialogs/symbology/vector_layer/types/SimpleSymbol.js +0 -120
- package/lib/formbuilder/index.d.ts +0 -4
- package/lib/formbuilder/index.js +0 -4
- package/lib/formbuilder/objectform/layer/storySegmentLayerForm.js +0 -95
- package/lib/formbuilder/objectform/layer/webGlLayerForm.d.ts +0 -3
- package/lib/formbuilder/objectform/process/index.d.ts +0 -1
- package/lib/formbuilder/objectform/process/index.js +0 -1
- package/lib/panelview/components/legendItem.js +0 -210
- package/lib/panelview/identify-panel/IdentifyPanel.js +0 -102
- package/lib/panelview/leftpanel.js +0 -139
- package/lib/panelview/story-maps/StoryViewerPanel.js +0 -116
- package/lib/panelview/story-maps/components/SpectaDesktopView.js +0 -49
- package/lib/processing/index.js +0 -200
- package/lib/processing/processingCommands.js +0 -67
- /package/lib/{panelview/annotationPanel.d.ts → features/annotations/AnnotationsPanel.d.ts} +0 -0
- /package/lib/{annotations → features/annotations}/components/Annotation.d.ts +0 -0
- /package/lib/{annotations → features/annotations}/components/Annotation.js +0 -0
- /package/lib/{annotations → features/annotations}/components/AnnotationFloater.d.ts +0 -0
- /package/lib/{annotations → features/annotations}/components/AnnotationFloater.js +0 -0
- /package/lib/{annotations → features/annotations}/components/Message.d.ts +0 -0
- /package/lib/{annotations → features/annotations}/components/Message.js +0 -0
- /package/lib/{annotations → features/annotations}/model.d.ts +0 -0
- /package/lib/{annotations → features/annotations}/model.js +0 -0
- /package/lib/{console → features/console}/consoleview.d.ts +0 -0
- /package/lib/{console → features/console}/index.d.ts +0 -0
- /package/lib/{console → features/console}/index.js +0 -0
- /package/lib/{panelview/filter-panel → features/filter}/Filter.d.ts +0 -0
- /package/lib/{stacBrowser/types/types.js → features/identify/types/editorTypes.js} +0 -0
- /package/lib/{dialogs/layerBrowserDialog.d.ts → features/layer-browser/index.d.ts} +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/layer/heatmapLayerForm.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/layer/hillshadeLayerForm.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/layer/storySegmentLayerForm.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/layer/vectorlayerform.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/source/geojsonsource.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/source/geotiffsource.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/source/pathbasedsource.d.ts +0 -0
- /package/lib/{formbuilder/objectform → features/layers/forms}/source/tilesourceform.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ColorRampSelectorEntry.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ColorRampSelectorEntry.js +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_ramp/ModeSelectRow.js +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_ramp/RgbaColorPicker.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_ramp/cmocean.json +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_stops/StopContainer.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/components/color_stops/StopContainer.js +0 -0
- /package/lib/{dialogs → features/layers}/symbology/hooks/useEffectiveSymbologyParams.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/hooks/useEffectiveSymbologyParams.js +0 -0
- /package/lib/{dialogs → features/layers}/symbology/hooks/useGetProperties.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/hooks/useGetSymbology.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/hooks/useOkSignal.d.ts +0 -0
- /package/lib/{dialogs → features/layers}/symbology/hooks/useOkSignal.js +0 -0
- /package/lib/{formbuilder/objectform/process → features/processing/forms}/dissolveProcessForm.d.ts +0 -0
- /package/lib/{processing → features/processing}/processingFormToParam.d.ts +0 -0
- /package/lib/{processing → features/processing}/processingFormToParam.js +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/StacPanel.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/QueryableComboBox.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/QueryableRow.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/StacFilterExtensionPanel.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/StacQueryableFilters.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/geodes/StacFilterSection.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/geodes/StacGeodesFilterPanel.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/geodes/StacGeodesFilterPanel.js +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/shared/StacPanelResults.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/shared/StacSpatialExtent.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/components/shared/StacTemporalExtent.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/constants.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/constants.js +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/context/StacResultsContext.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/hooks/useGeodesSearch.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/hooks/useStacFilterExtension.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/hooks/useStacSearch.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/index.d.ts +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/index.js +0 -0
- /package/lib/{stacBrowser → features/stac-browser}/types/types.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/StoryEditorPanel.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/PreviewModeSwitch.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/PreviewModeSwitch.js +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryContentSection.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryContentSection.js +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryImageSection.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryImageSection.js +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryNavBar.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryNavBar.js +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StorySubtitleSection.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StorySubtitleSection.js +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryTitleSection.d.ts +0 -0
- /package/lib/{panelview/story-maps → features/story}/components/StoryTitleSection.js +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/creationform.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/editform.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/SchemaForm.js +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/LayerSelect.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/OpacitySlider.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/OpacitySlider.js +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/SegmentFormSymbology.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/SourcePropertiesField.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/StorySegmentReset.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/components/WmsTileSourceUrlInput.d.ts +0 -0
- /package/lib/{formbuilder → shared/formbuilder}/objectform/fileselectorwidget.d.ts +0 -0
- /package/lib/{store.d.ts → shared/store.d.ts} +0 -0
- /package/lib/{store.js → shared/store.js} +0 -0
- /package/lib/{menus.d.ts → workspace/menus.d.ts} +0 -0
- /package/lib/{panelview → workspace/panels}/components/layers.d.ts +0 -0
- /package/lib/{panelview → workspace/panels}/components/legendItem.d.ts +0 -0
- /package/lib/{panelview → workspace/panels}/header.d.ts +0 -0
- /package/lib/{panelview → workspace/panels}/header.js +0 -0
- /package/lib/{statusbar → workspace/statusbar}/SpectaPresentationProgressBar.d.ts +0 -0
- /package/lib/{statusbar → workspace/statusbar}/SpectaPresentationProgressBar.js +0 -0
- /package/lib/{statusbar → workspace/statusbar}/StatusBar.d.ts +0 -0
- /package/lib/{toolbar → workspace/toolbar}/index.d.ts +0 -0
- /package/lib/{toolbar → workspace/toolbar}/index.js +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IDict, IJGISFormSchemaRegistry } from '@jupytergis/schema';
|
|
2
2
|
import { JupyterFrontEnd } from '@jupyterlab/application';
|
|
3
3
|
import { CommandRegistry } from '@lumino/commands';
|
|
4
|
-
import { JupyterGISTracker } from '
|
|
4
|
+
import { JupyterGISTracker } from '../../types';
|
|
5
5
|
export declare function replaceInSql(sql: string, keyToVal: IDict<string>, layerName: string): string;
|
|
6
6
|
export declare function addProcessingCommands(app: JupyterFrontEnd, commands: CommandRegistry, tracker: JupyterGISTracker, trans: any, formSchemaRegistry: IJGISFormSchemaRegistry, processingSchemas: Record<string, any>): void;
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
import { ProcessingMerge, ProcessingLogicType, } from '@jupytergis/schema';
|
|
2
|
+
import { selectedLayerIsOfType, processLayer, rasterizeLayer, clipRasterByExtent, clipRasterByVector, clipVectorByMaskLayer, } from './index';
|
|
3
|
+
export function replaceInSql(sql, keyToVal, layerName) {
|
|
4
|
+
const replaceTemplateString = (args) => args.template.replace(RegExp(`{${args.variableName}}`, 'g'), args.value);
|
|
5
|
+
let out = replaceTemplateString({
|
|
6
|
+
variableName: 'layerName',
|
|
7
|
+
template: sql,
|
|
8
|
+
value: layerName,
|
|
9
|
+
});
|
|
10
|
+
for (const [key, value] of Object.entries(keyToVal)) {
|
|
11
|
+
out = replaceTemplateString({
|
|
12
|
+
variableName: key,
|
|
13
|
+
template: out,
|
|
14
|
+
value: value,
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
return out;
|
|
18
|
+
}
|
|
19
|
+
export function addProcessingCommands(app, commands, tracker, trans, formSchemaRegistry, processingSchemas) {
|
|
20
|
+
for (const processingElement of ProcessingMerge) {
|
|
21
|
+
const schemaKey = Object.keys(processingSchemas).find(k => k.toLowerCase() === processingElement.description.toLowerCase() ||
|
|
22
|
+
k.toLowerCase() === processingElement.name.toLowerCase());
|
|
23
|
+
if (!schemaKey) {
|
|
24
|
+
continue;
|
|
25
|
+
}
|
|
26
|
+
if (processingElement.type === ProcessingLogicType.vector) {
|
|
27
|
+
commands.addCommand(`jupytergis:${processingElement.name}`, {
|
|
28
|
+
label: trans.__(processingElement.label),
|
|
29
|
+
describedBy: {
|
|
30
|
+
args: {
|
|
31
|
+
type: 'object',
|
|
32
|
+
properties: {
|
|
33
|
+
filePath: {
|
|
34
|
+
type: 'string',
|
|
35
|
+
description: 'Path to the .jGIS file',
|
|
36
|
+
},
|
|
37
|
+
layerId: {
|
|
38
|
+
type: 'string',
|
|
39
|
+
description: 'Layer ID to process',
|
|
40
|
+
},
|
|
41
|
+
params: processingSchemas[schemaKey],
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
isEnabled: () => selectedLayerIsOfType(['VectorLayer'], tracker),
|
|
46
|
+
execute: async (args) => {
|
|
47
|
+
await processLayer(tracker, formSchemaRegistry, processingElement.description, {
|
|
48
|
+
sqlQueryFn: (layerName, keyToVal) => replaceInSql(processingElement.operations.sql, keyToVal, layerName),
|
|
49
|
+
gdalFunction: processingElement.operations.gdalFunction,
|
|
50
|
+
options: (sqlQuery) => [
|
|
51
|
+
'-f',
|
|
52
|
+
'GeoJSON',
|
|
53
|
+
'-dialect',
|
|
54
|
+
'SQLITE',
|
|
55
|
+
'-sql',
|
|
56
|
+
sqlQuery,
|
|
57
|
+
'{outputName}',
|
|
58
|
+
],
|
|
59
|
+
}, app, args === null || args === void 0 ? void 0 : args.filePath, args === null || args === void 0 ? void 0 : args.processingInputs);
|
|
60
|
+
},
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
else if (processingElement.type === ProcessingLogicType.raster) {
|
|
64
|
+
commands.addCommand(`jupytergis:${processingElement.name}`, {
|
|
65
|
+
label: trans.__(processingElement.label),
|
|
66
|
+
describedBy: {
|
|
67
|
+
args: {
|
|
68
|
+
type: 'object',
|
|
69
|
+
properties: {
|
|
70
|
+
filePath: {
|
|
71
|
+
type: 'string',
|
|
72
|
+
description: 'Path to the .jGIS file',
|
|
73
|
+
},
|
|
74
|
+
layerId: {
|
|
75
|
+
type: 'string',
|
|
76
|
+
description: 'Layer ID to process',
|
|
77
|
+
},
|
|
78
|
+
params: processingSchemas[schemaKey],
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
isEnabled: () => selectedLayerIsOfType(['VectorLayer'], tracker),
|
|
83
|
+
execute: async (args) => {
|
|
84
|
+
await rasterizeLayer(tracker, formSchemaRegistry, processingElement.description, processingElement.operations.gdalFunction, app, args === null || args === void 0 ? void 0 : args.filePath, args === null || args === void 0 ? void 0 : args.processingInputs);
|
|
85
|
+
},
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
else if (processingElement.type === ProcessingLogicType.rasterClip) {
|
|
89
|
+
commands.addCommand(`jupytergis:${processingElement.name}`, {
|
|
90
|
+
label: trans.__(processingElement.label),
|
|
91
|
+
describedBy: {
|
|
92
|
+
args: {
|
|
93
|
+
type: 'object',
|
|
94
|
+
properties: {
|
|
95
|
+
filePath: {
|
|
96
|
+
type: 'string',
|
|
97
|
+
description: 'Path to the .jGIS file',
|
|
98
|
+
},
|
|
99
|
+
layerId: {
|
|
100
|
+
type: 'string',
|
|
101
|
+
description: 'Layer ID to process',
|
|
102
|
+
},
|
|
103
|
+
params: processingSchemas[schemaKey],
|
|
104
|
+
},
|
|
105
|
+
},
|
|
106
|
+
},
|
|
107
|
+
isEnabled: () => selectedLayerIsOfType(['GeoTiffLayer'], tracker),
|
|
108
|
+
execute: async (args) => {
|
|
109
|
+
await clipRasterByExtent(tracker, formSchemaRegistry, app, args === null || args === void 0 ? void 0 : args.filePath, args === null || args === void 0 ? void 0 : args.processingInputs);
|
|
110
|
+
},
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
else if (processingElement.type === ProcessingLogicType.rasterClipVector) {
|
|
114
|
+
commands.addCommand(`jupytergis:${processingElement.name}`, {
|
|
115
|
+
label: trans.__(processingElement.label),
|
|
116
|
+
describedBy: {
|
|
117
|
+
args: {
|
|
118
|
+
type: 'object',
|
|
119
|
+
properties: {
|
|
120
|
+
filePath: {
|
|
121
|
+
type: 'string',
|
|
122
|
+
description: 'Path to the .jGIS file',
|
|
123
|
+
},
|
|
124
|
+
layerId: {
|
|
125
|
+
type: 'string',
|
|
126
|
+
description: 'Layer ID to process',
|
|
127
|
+
},
|
|
128
|
+
params: processingSchemas[schemaKey],
|
|
129
|
+
},
|
|
130
|
+
},
|
|
131
|
+
},
|
|
132
|
+
isEnabled: () => selectedLayerIsOfType(['GeoTiffLayer'], tracker),
|
|
133
|
+
execute: async (args) => {
|
|
134
|
+
await clipRasterByVector(tracker, formSchemaRegistry, app, args === null || args === void 0 ? void 0 : args.filePath, args === null || args === void 0 ? void 0 : args.processingInputs);
|
|
135
|
+
},
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
else if (processingElement.type === ProcessingLogicType.clip) {
|
|
139
|
+
commands.addCommand(`jupytergis:${processingElement.name}`, {
|
|
140
|
+
label: trans.__(processingElement.label),
|
|
141
|
+
describedBy: {
|
|
142
|
+
args: {
|
|
143
|
+
type: 'object',
|
|
144
|
+
properties: {
|
|
145
|
+
filePath: {
|
|
146
|
+
type: 'string',
|
|
147
|
+
description: 'Path to the .jGIS file',
|
|
148
|
+
},
|
|
149
|
+
layerId: {
|
|
150
|
+
type: 'string',
|
|
151
|
+
description: 'Layer ID to process',
|
|
152
|
+
},
|
|
153
|
+
params: processingSchemas[schemaKey],
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
},
|
|
157
|
+
isEnabled: () => selectedLayerIsOfType(['VectorLayer'], tracker),
|
|
158
|
+
execute: async (args) => {
|
|
159
|
+
await clipVectorByMaskLayer(tracker, formSchemaRegistry, app, args === null || args === void 0 ? void 0 : args.filePath, args === null || args === void 0 ? void 0 : args.processingInputs);
|
|
160
|
+
},
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
else {
|
|
164
|
+
console.error('Unsupported process type');
|
|
165
|
+
return;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
export declare function isServerProcessingEnabled(): boolean;
|
|
2
|
+
export declare function getServerProcessingToggle(): boolean;
|
|
3
|
+
export declare function setServerProcessingEnabled(enabled: boolean): void;
|
|
4
|
+
/**
|
|
5
|
+
* Check if the server-side GDAL endpoint is available.
|
|
6
|
+
* Caches the result after the first successful check.
|
|
7
|
+
*/
|
|
8
|
+
export declare function checkServerAvailability(): Promise<boolean>;
|
|
9
|
+
/**
|
|
10
|
+
* Reset the cached availability (e.g. after environment change).
|
|
11
|
+
*/
|
|
12
|
+
export declare function resetServerAvailabilityCache(): void;
|
|
13
|
+
export interface IServerProcessingRequest {
|
|
14
|
+
operation: string;
|
|
15
|
+
options: string[];
|
|
16
|
+
geojson: string;
|
|
17
|
+
outputName: string;
|
|
18
|
+
}
|
|
19
|
+
export interface IServerProcessingUrlRequest {
|
|
20
|
+
operation: string;
|
|
21
|
+
options: string[];
|
|
22
|
+
url: string;
|
|
23
|
+
outputName: string;
|
|
24
|
+
}
|
|
25
|
+
export interface IServerProcessingUrlWithCutlineRequest {
|
|
26
|
+
operation: string;
|
|
27
|
+
options: string[];
|
|
28
|
+
url: string;
|
|
29
|
+
cutlineGeojson: string;
|
|
30
|
+
outputName: string;
|
|
31
|
+
}
|
|
32
|
+
export interface IServerProcessingResponse {
|
|
33
|
+
result: string;
|
|
34
|
+
format: 'text' | 'base64';
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Send a processing request to the server-side GDAL handler.
|
|
38
|
+
*/
|
|
39
|
+
export declare function runServerProcessing(request: IServerProcessingRequest): Promise<IServerProcessingResponse>;
|
|
40
|
+
/**
|
|
41
|
+
* Send a URL-based processing request — the server uses /vsicurl/ so GDAL
|
|
42
|
+
* issues HTTP range requests instead of downloading the full file.
|
|
43
|
+
* Ideal for Cloud-Optimized GeoTIFFs (COGs).
|
|
44
|
+
*/
|
|
45
|
+
export declare function runServerProcessingUrl(request: IServerProcessingUrlRequest): Promise<IServerProcessingResponse>;
|
|
46
|
+
/**
|
|
47
|
+
* Run a GDAL operation that needs both a remote raster URL and a vector
|
|
48
|
+
* cutline (e.g. `gdalwarp -cutline`). The server writes the cutline GeoJSON
|
|
49
|
+
* to a temp file and substitutes `{cutlinePath}` in the options list.
|
|
50
|
+
*/
|
|
51
|
+
export declare function runServerProcessingUrlWithCutline(request: IServerProcessingUrlWithCutlineRequest): Promise<IServerProcessingResponse>;
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { ServerConnection } from '@jupyterlab/services';
|
|
2
|
+
const PROCESSING_ENDPOINT = '/jupytergis_core/processing';
|
|
3
|
+
/**
|
|
4
|
+
* Module-level state for server-side processing toggle.
|
|
5
|
+
*/
|
|
6
|
+
let _serverProcessingEnabled = false;
|
|
7
|
+
let _serverAvailable = null;
|
|
8
|
+
export function isServerProcessingEnabled() {
|
|
9
|
+
return _serverProcessingEnabled && _serverAvailable === true;
|
|
10
|
+
}
|
|
11
|
+
export function getServerProcessingToggle() {
|
|
12
|
+
return _serverProcessingEnabled;
|
|
13
|
+
}
|
|
14
|
+
export function setServerProcessingEnabled(enabled) {
|
|
15
|
+
_serverProcessingEnabled = enabled;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Check if the server-side GDAL endpoint is available.
|
|
19
|
+
* Caches the result after the first successful check.
|
|
20
|
+
*/
|
|
21
|
+
export async function checkServerAvailability() {
|
|
22
|
+
if (_serverAvailable !== null) {
|
|
23
|
+
return _serverAvailable;
|
|
24
|
+
}
|
|
25
|
+
try {
|
|
26
|
+
const settings = ServerConnection.makeSettings();
|
|
27
|
+
const url = `${settings.baseUrl}${PROCESSING_ENDPOINT.slice(1)}`;
|
|
28
|
+
const response = await ServerConnection.makeRequest(url, {}, settings);
|
|
29
|
+
if (response.ok) {
|
|
30
|
+
const data = await response.json();
|
|
31
|
+
_serverAvailable = data.available === true;
|
|
32
|
+
}
|
|
33
|
+
else {
|
|
34
|
+
_serverAvailable = false;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
catch (_a) {
|
|
38
|
+
_serverAvailable = false;
|
|
39
|
+
}
|
|
40
|
+
return _serverAvailable;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Reset the cached availability (e.g. after environment change).
|
|
44
|
+
*/
|
|
45
|
+
export function resetServerAvailabilityCache() {
|
|
46
|
+
_serverAvailable = null;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Send a processing request to the server-side GDAL handler.
|
|
50
|
+
*/
|
|
51
|
+
export async function runServerProcessing(request) {
|
|
52
|
+
const settings = ServerConnection.makeSettings();
|
|
53
|
+
const url = `${settings.baseUrl}${PROCESSING_ENDPOINT.slice(1)}`;
|
|
54
|
+
const response = await ServerConnection.makeRequest(url, {
|
|
55
|
+
method: 'POST',
|
|
56
|
+
body: JSON.stringify(request),
|
|
57
|
+
}, settings);
|
|
58
|
+
if (!response.ok) {
|
|
59
|
+
const error = await response.json();
|
|
60
|
+
throw new Error(error.error || `Server processing failed: ${response.status}`);
|
|
61
|
+
}
|
|
62
|
+
return await response.json();
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* Send a URL-based processing request — the server uses /vsicurl/ so GDAL
|
|
66
|
+
* issues HTTP range requests instead of downloading the full file.
|
|
67
|
+
* Ideal for Cloud-Optimized GeoTIFFs (COGs).
|
|
68
|
+
*/
|
|
69
|
+
export async function runServerProcessingUrl(request) {
|
|
70
|
+
const settings = ServerConnection.makeSettings();
|
|
71
|
+
const endpoint = `${settings.baseUrl}${PROCESSING_ENDPOINT.slice(1)}`;
|
|
72
|
+
const response = await ServerConnection.makeRequest(endpoint, {
|
|
73
|
+
method: 'POST',
|
|
74
|
+
body: JSON.stringify(request),
|
|
75
|
+
}, settings);
|
|
76
|
+
if (!response.ok) {
|
|
77
|
+
const error = await response.json();
|
|
78
|
+
throw new Error(error.error || `Server processing failed: ${response.status}`);
|
|
79
|
+
}
|
|
80
|
+
return await response.json();
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Run a GDAL operation that needs both a remote raster URL and a vector
|
|
84
|
+
* cutline (e.g. `gdalwarp -cutline`). The server writes the cutline GeoJSON
|
|
85
|
+
* to a temp file and substitutes `{cutlinePath}` in the options list.
|
|
86
|
+
*/
|
|
87
|
+
export async function runServerProcessingUrlWithCutline(request) {
|
|
88
|
+
const settings = ServerConnection.makeSettings();
|
|
89
|
+
const endpoint = `${settings.baseUrl}${PROCESSING_ENDPOINT.slice(1)}`;
|
|
90
|
+
const response = await ServerConnection.makeRequest(endpoint, {
|
|
91
|
+
method: 'POST',
|
|
92
|
+
body: JSON.stringify(request),
|
|
93
|
+
}, settings);
|
|
94
|
+
if (!response.ok) {
|
|
95
|
+
const error = await response.json();
|
|
96
|
+
throw new Error(error.error || `Server processing failed: ${response.status}`);
|
|
97
|
+
}
|
|
98
|
+
return await response.json();
|
|
99
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Select } from "../../shared/components/Select";
|
|
3
|
-
import { Tabs, TabsContent, TabsList, TabsTrigger, } from "../../shared/components/Tabs";
|
|
4
2
|
import StacFilterExtensionPanel from "./filter-extension/StacFilterExtensionPanel";
|
|
5
3
|
import StacGeodesFilterPanel from "./geodes/StacGeodesFilterPanel";
|
|
6
4
|
import StacPanelResults from "./shared/StacPanelResults";
|
|
7
5
|
import { StacResultsProvider, useStacResultsContext, } from "../context/StacResultsContext";
|
|
6
|
+
import { Select } from "../../../shared/components/Select";
|
|
7
|
+
import { Tabs, TabsContent, TabsList, TabsTrigger, } from "../../../shared/components/Tabs";
|
|
8
8
|
const GEODES_URL = 'https://geodes-portal.cnes.fr/api/stac/';
|
|
9
9
|
const COPERNICUS_URL = 'https://stac.dataspace.copernicus.eu/v1/';
|
|
10
10
|
const WORLDPOP_URL = 'https://api.stac.worldpop.org/';
|
package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/QueryableComboBox.js
RENAMED
|
@@ -10,12 +10,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
10
10
|
return t;
|
|
11
11
|
};
|
|
12
12
|
import React, { useCallback, useEffect, useMemo, useRef, useState, } from 'react';
|
|
13
|
-
import { Combobox } from "../../../shared/components/Combobox";
|
|
14
|
-
import { Input } from "../../../shared/components/Input";
|
|
15
|
-
import { Select } from "../../../shared/components/Select";
|
|
16
13
|
import QueryableRow from "./QueryableRow";
|
|
17
|
-
import {
|
|
18
|
-
import
|
|
14
|
+
import { Combobox } from "../../../../shared/components/Combobox";
|
|
15
|
+
import { Input } from "../../../../shared/components/Input";
|
|
16
|
+
import { Select } from "../../../../shared/components/Select";
|
|
17
|
+
import { debounce } from "../../../../tools";
|
|
18
|
+
import SingleDatePicker from '../../../../shared/components/SingleDatePicker';
|
|
19
19
|
export function QueryableComboBox({ queryables, selectedQueryables, updateSelectedQueryables, }) {
|
|
20
20
|
const [draftValues, setDraftValues] = useState({});
|
|
21
21
|
const selectedQueryablesRef = useRef(selectedQueryables);
|
package/lib/{stacBrowser → features/stac-browser}/components/filter-extension/QueryableRow.js
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Select } from "
|
|
2
|
+
import { Select } from "../../../../shared/components/Select";
|
|
3
3
|
function QueryableRow({ qKey, qVal, operators, currentFilter, inputComponent, onOperatorChange, }) {
|
|
4
4
|
const currentOperator = operators.find(op => op.value === currentFilter.operator);
|
|
5
5
|
const buttonText = (currentOperator === null || currentOperator === void 0 ? void 0 : currentOperator.label) || 'Select operator...';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
|
-
import { Input } from "../../../shared/components/Input";
|
|
3
|
-
import { Select } from "../../../shared/components/Select";
|
|
4
2
|
import StacQueryableFilters from "./StacQueryableFilters";
|
|
5
3
|
import StacSpatialExtent from "../shared/StacSpatialExtent";
|
|
6
4
|
import StacTemporalExtent from "../shared/StacTemporalExtent";
|
|
7
5
|
import { useStacResultsContext } from "../../context/StacResultsContext";
|
|
8
6
|
import { useStacFilterExtension } from "../../hooks/useStacFilterExtension";
|
|
7
|
+
import { Input } from "../../../../shared/components/Input";
|
|
8
|
+
import { Select } from "../../../../shared/components/Select";
|
|
9
9
|
function StacFilterExtensionPanel({ model }) {
|
|
10
10
|
var _a;
|
|
11
11
|
const { selectedUrl } = useStacResultsContext();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { RadioGroup, RadioGroupItem } from "../../../shared/components/RadioGroup";
|
|
3
2
|
import { QueryableComboBox } from "./QueryableComboBox";
|
|
3
|
+
import { RadioGroup, RadioGroupItem } from "../../../../shared/components/RadioGroup";
|
|
4
4
|
const StacQueryableFilters = ({ queryableFields, selectedQueryables, updateSelectedQueryables, filterOperator, setFilterOperator, }) => {
|
|
5
5
|
return (React.createElement("div", { className: "jgis-stac-queryable-filters" },
|
|
6
6
|
React.createElement(RadioGroup, { className: "jgis-stac-queryable-filters-radio-group", value: filterOperator, onValueChange: (value) => {
|
|
@@ -2,9 +2,9 @@ import { faXmark } from '@fortawesome/free-solid-svg-icons';
|
|
|
2
2
|
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
|
3
3
|
import { ChevronRight } from 'lucide-react';
|
|
4
4
|
import React, { useMemo } from 'react';
|
|
5
|
-
import Badge from "
|
|
6
|
-
import { Button } from "
|
|
7
|
-
import { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, } from "
|
|
5
|
+
import Badge from "../../../../shared/components/Badge";
|
|
6
|
+
import { Button } from "../../../../shared/components/Button";
|
|
7
|
+
import { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, } from "../../../../shared/components/DropdownMenu";
|
|
8
8
|
const StacFilterSection = ({ section, data, selectedCollections, selectedData, handleCheckedChange, }) => {
|
|
9
9
|
const items = useMemo(() => {
|
|
10
10
|
if (section === 'Collection') {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Button } from "../../../shared/components/Button";
|
|
3
|
-
import { Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, } from "../../../shared/components/Pagination";
|
|
4
|
-
import { LoadingIcon } from "../../../shared/components/loading";
|
|
5
2
|
import { useStacResultsContext } from "../../context/StacResultsContext";
|
|
3
|
+
import { Button } from "../../../../shared/components/Button";
|
|
4
|
+
import { Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, } from "../../../../shared/components/Pagination";
|
|
5
|
+
import { LoadingIcon } from "../../../../shared/components/loading";
|
|
6
6
|
function getPageItems(currentPage, totalPages) {
|
|
7
7
|
if (totalPages <= 5) {
|
|
8
8
|
return Array.from({ length: totalPages }, (_, i) => i + 1);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import Checkbox from "
|
|
2
|
+
import Checkbox from "../../../../shared/components/Checkbox";
|
|
3
3
|
const StacSpatialExtent = ({ checked, onCheckedChange, label, }) => {
|
|
4
4
|
return (React.createElement(React.Fragment, null,
|
|
5
5
|
React.createElement("label", { className: "jgis-stac-filter-extension-label" }, "Spatial Extent"),
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import SingleDatePicker from '
|
|
2
|
+
import SingleDatePicker from '../../../../shared/components/SingleDatePicker';
|
|
3
3
|
function StacTemporalExtent({ startTime, endTime, setStartTime, setEndTime, }) {
|
|
4
4
|
return (React.createElement("div", { className: "jgis-stac-filter-extension-section" },
|
|
5
5
|
React.createElement("label", { className: "jgis-stac-filter-extension-label" }, "Temporal Extent"),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { UUID } from '@lumino/coreutils';
|
|
2
2
|
import React, { createContext, useContext, useState, useCallback, useRef, useEffect, } from 'react';
|
|
3
|
-
import { GlobalStateDbManager } from "
|
|
4
|
-
import { fetchWithProxies } from "
|
|
3
|
+
import { GlobalStateDbManager } from "../../../shared/store";
|
|
4
|
+
import { fetchWithProxies } from "../../../tools";
|
|
5
5
|
const StacResultsContext = createContext(undefined);
|
|
6
6
|
const STAC_SELECTED_URL_STATE_KEY = 'jupytergis:stac-selected-url';
|
|
7
7
|
export function StacResultsProvider({ children, model, }) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { startOfYesterday } from 'date-fns';
|
|
2
2
|
import { useCallback, useEffect, useState } from 'react';
|
|
3
|
-
import useIsFirstRender from "../../shared/hooks/useIsFirstRender";
|
|
4
3
|
import { products } from "../constants";
|
|
5
4
|
import { useStacResultsContext } from "../context/StacResultsContext";
|
|
6
5
|
import { useStacSearch } from "./useStacSearch";
|
|
7
|
-
import
|
|
6
|
+
import useIsFirstRender from "../../../shared/hooks/useIsFirstRender";
|
|
7
|
+
import { GlobalStateDbManager } from "../../../shared/store";
|
|
8
8
|
const GEODES_STAC_FILTERS_KEY = 'jupytergis:geodes-stac-filters';
|
|
9
9
|
/**
|
|
10
10
|
* Custom hook for managing GEODES-specific STAC search functionality
|
|
@@ -11,11 +11,11 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
11
11
|
};
|
|
12
12
|
import { endOfToday, startOfToday } from 'date-fns';
|
|
13
13
|
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
14
|
-
import useIsFirstRender from "../../shared/hooks/useIsFirstRender";
|
|
15
14
|
import { useStacResultsContext } from "../context/StacResultsContext";
|
|
16
15
|
import { useStacSearch } from "./useStacSearch";
|
|
17
|
-
import
|
|
18
|
-
import {
|
|
16
|
+
import useIsFirstRender from "../../../shared/hooks/useIsFirstRender";
|
|
17
|
+
import { GlobalStateDbManager } from "../../../shared/store";
|
|
18
|
+
import { fetchWithProxies } from "../../../tools";
|
|
19
19
|
const STAC_FILTER_EXTENSION_STATE_KEY = 'jupytergis:stac-filter-extension-state';
|
|
20
20
|
const STAC_COLLECTIONS_CACHE_STATE_KEY = 'jupytergis:stac-collections-cache';
|
|
21
21
|
const STAC_QUERYABLES_CACHE_STATE_KEY = 'jupytergis:stac-queryables-cache';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useEffect, useState } from 'react';
|
|
2
|
-
import { GlobalStateDbManager } from "
|
|
2
|
+
import { GlobalStateDbManager } from "../../../shared/store";
|
|
3
3
|
const STAC_SEARCH_STATE_KEY = 'jupytergis:stac-search-state';
|
|
4
4
|
/**
|
|
5
5
|
* Base hook for managing STAC search - handles temporal/spatial filters
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IJGISLayer, IJupyterGISModel } from '@jupytergis/schema';
|
|
2
2
|
import React, { RefObject } from 'react';
|
|
3
3
|
import type { IStoryViewerPanelHandle } from './StoryViewerPanel';
|
|
4
|
+
import type { IListStorySegmentTransition } from './types/types';
|
|
4
5
|
interface ISpectaPanelProps {
|
|
5
6
|
model: IJupyterGISModel;
|
|
6
7
|
isSpecta: boolean;
|
|
@@ -10,6 +11,8 @@ interface ISpectaPanelProps {
|
|
|
10
11
|
storyViewerPanelRef: RefObject<IStoryViewerPanelHandle>;
|
|
11
12
|
addLayer?: (id: string, layer: IJGISLayer, index: number) => Promise<void>;
|
|
12
13
|
removeLayer?: (id: string) => void;
|
|
14
|
+
/** List stories: segment handoff state for the map stage overlay. */
|
|
15
|
+
onSegmentTransitionChange?: (payload: IListStorySegmentTransition | null) => void;
|
|
13
16
|
}
|
|
14
|
-
export declare function SpectaPanel({ model, isSpecta, isMobile, onSegmentTransitionEnd, containerRef, storyViewerPanelRef, addLayer, removeLayer, }: ISpectaPanelProps): React.JSX.Element;
|
|
17
|
+
export declare function SpectaPanel({ model, isSpecta, isMobile, onSegmentTransitionEnd, containerRef, storyViewerPanelRef, addLayer, removeLayer, onSegmentTransitionChange, }: ISpectaPanelProps): React.JSX.Element;
|
|
15
18
|
export {};
|
|
@@ -2,7 +2,7 @@ import React, { useEffect, useRef } from 'react';
|
|
|
2
2
|
import { SpectaDesktopView } from './components/SpectaDesktopView';
|
|
3
3
|
import { SpectaMobileView } from './components/SpectaMobileView';
|
|
4
4
|
import { useStoryMap } from './hooks/useStoryMap';
|
|
5
|
-
export function SpectaPanel({ model, isSpecta, isMobile, onSegmentTransitionEnd, containerRef, storyViewerPanelRef, addLayer, removeLayer, }) {
|
|
5
|
+
export function SpectaPanel({ model, isSpecta, isMobile, onSegmentTransitionEnd, containerRef, storyViewerPanelRef, addLayer, removeLayer, onSegmentTransitionChange, }) {
|
|
6
6
|
const overrideLayerEntriesRef = useRef([]);
|
|
7
7
|
const segmentContainerRef = useRef(null);
|
|
8
8
|
const { storyData, currentIndex, setIndex, handlePrev, handleNext, hasPrev, hasNext, activeSlide, layerName, showGradient, } = useStoryMap({
|
|
@@ -10,7 +10,6 @@ export function SpectaPanel({ model, isSpecta, isMobile, onSegmentTransitionEnd,
|
|
|
10
10
|
overrideLayerEntriesRef,
|
|
11
11
|
removeLayer,
|
|
12
12
|
addLayer,
|
|
13
|
-
panelRef: isMobile ? undefined : containerRef,
|
|
14
13
|
isSpecta,
|
|
15
14
|
});
|
|
16
15
|
// Notify when segment transition animation ends
|
|
@@ -29,7 +28,7 @@ export function SpectaPanel({ model, isSpecta, isMobile, onSegmentTransitionEnd,
|
|
|
29
28
|
return () => el.removeEventListener('animationend', handleAnimationEnd);
|
|
30
29
|
}, [currentIndex, onSegmentTransitionEnd]);
|
|
31
30
|
if (isMobile) {
|
|
32
|
-
return (React.createElement(SpectaMobileView, {
|
|
31
|
+
return (React.createElement(SpectaMobileView, { segmentContainerRef: segmentContainerRef, storyData: storyData, currentIndex: currentIndex, activeSlide: activeSlide, layerName: layerName, handlePrev: handlePrev, handleNext: handleNext, hasPrev: hasPrev, hasNext: hasNext }));
|
|
33
32
|
}
|
|
34
|
-
return (React.createElement(SpectaDesktopView, { model: model, isSpecta: isSpecta, containerRef: containerRef, storyViewerPanelRef: storyViewerPanelRef, segmentContainerRef: segmentContainerRef, storyData: storyData, currentIndex: currentIndex, activeSlide: activeSlide, layerName: layerName, handlePrev: handlePrev, handleNext: handleNext, hasPrev: hasPrev, hasNext: hasNext, showGradient: showGradient, setIndex: setIndex }));
|
|
33
|
+
return (React.createElement(SpectaDesktopView, { model: model, isSpecta: isSpecta, containerRef: containerRef, storyViewerPanelRef: storyViewerPanelRef, segmentContainerRef: segmentContainerRef, storyData: storyData, currentIndex: currentIndex, activeSlide: activeSlide, layerName: layerName, handlePrev: handlePrev, handleNext: handleNext, hasPrev: hasPrev, hasNext: hasNext, showGradient: showGradient, setIndex: setIndex, onSegmentTransitionChange: onSegmentTransitionChange }));
|
|
35
34
|
}
|
|
@@ -3,8 +3,8 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
|
|
3
3
|
import jgisSchema from '@jupytergis/schema/lib/schema/project/jgis.json';
|
|
4
4
|
import React, { useMemo } from 'react';
|
|
5
5
|
import { CommandIDs } from "../../constants";
|
|
6
|
-
import { StoryEditorPropertiesForm } from "../../formbuilder/objectform/StoryEditorForm";
|
|
7
6
|
import { Button } from "../../shared/components/Button";
|
|
7
|
+
import { StoryEditorPropertiesForm } from "../../shared/formbuilder/objectform/StoryEditorForm";
|
|
8
8
|
import { deepCopy } from "../../tools";
|
|
9
9
|
const storyMapSchema = deepCopy(jgisSchema.definitions.jGISStoryMap);
|
|
10
10
|
const AddStorySegmentButton = ({ model, commands }) => (React.createElement("div", { style: { display: 'flex', justifyContent: 'center' } },
|
|
@@ -1,8 +1,13 @@
|
|
|
1
|
-
import { IJGISStoryMap,
|
|
1
|
+
import { IJGISStoryMap, IStorySegmentLayer } from '@jupytergis/schema';
|
|
2
2
|
import React, { RefObject } from 'react';
|
|
3
|
+
export interface IStoryViewerPanelSegmentNav {
|
|
4
|
+
handlePrev: () => void;
|
|
5
|
+
handleNext: () => void;
|
|
6
|
+
hasPrev: boolean;
|
|
7
|
+
hasNext: boolean;
|
|
8
|
+
}
|
|
3
9
|
/** Props: story state and callbacks come from useStoryMap in parent (SpectaPanel or SpectaMobileView). */
|
|
4
10
|
interface IStoryViewerPanelProps {
|
|
5
|
-
model: IJupyterGISModel;
|
|
6
11
|
isSpecta: boolean;
|
|
7
12
|
isMobile?: boolean;
|
|
8
13
|
/** Ref for the segment container (SpectaPanel uses it for animationend). */
|
|
@@ -11,11 +16,10 @@ interface IStoryViewerPanelProps {
|
|
|
11
16
|
currentIndex: number;
|
|
12
17
|
activeSlide: IStorySegmentLayer['parameters'] | undefined;
|
|
13
18
|
layerName: string;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
setIndex: (index: number) => void;
|
|
19
|
+
/** Omit for list-story overlay; required when segment nav is shown. */
|
|
20
|
+
segmentNav?: IStoryViewerPanelSegmentNav;
|
|
21
|
+
/** Disable fade animation for list stories. */
|
|
22
|
+
disableSegmentAnimation?: boolean;
|
|
19
23
|
}
|
|
20
24
|
export interface IStoryViewerPanelHandle {
|
|
21
25
|
handlePrev: () => void;
|
|
@@ -40,8 +44,5 @@ export type StoryNavPlacement = 'below-title' | 'over-image' | 'subtitle-specta'
|
|
|
40
44
|
* Story viewer (presentational). Receives story state and callbacks from parent.
|
|
41
45
|
* Desktop scroll/sentinel/imperative handle live in SpectaDesktopView.
|
|
42
46
|
*/
|
|
43
|
-
declare function StoryViewerPanel({
|
|
44
|
-
declare namespace StoryViewerPanel {
|
|
45
|
-
var displayName: string;
|
|
46
|
-
}
|
|
47
|
+
declare function StoryViewerPanel({ isSpecta, isMobile, segmentContainerRef, storyData, currentIndex, activeSlide, layerName, segmentNav, disableSegmentAnimation, }: IStoryViewerPanelProps): React.JSX.Element;
|
|
47
48
|
export default StoryViewerPanel;
|