qwc2 2025.3.31
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/LICENSE +28 -0
- package/README.md +68 -0
- package/actions/display.js +7 -0
- package/actions/editing.js +7 -0
- package/actions/layerinfo.js +7 -0
- package/actions/layers.js +8 -0
- package/actions/localConfig.js +7 -0
- package/actions/locale.js +10 -0
- package/actions/locate.js +8 -0
- package/actions/logging.js +7 -0
- package/actions/map.js +15 -0
- package/actions/measurement.js +8 -0
- package/actions/processNotifications.js +7 -0
- package/actions/redlining.js +7 -0
- package/actions/redliningPick.js +7 -0
- package/actions/serviceinfo.js +7 -0
- package/actions/task.js +9 -0
- package/actions/theme.js +24 -0
- package/actions/windows.js +10 -0
- package/components/AppMenu.js +8 -0
- package/components/AttributeForm.js +34 -0
- package/components/AutoEditForm.js +8 -0
- package/components/CoordinateDisplayer.js +7 -0
- package/components/EditComboField.js +10 -0
- package/components/EditUploadField.js +8 -0
- package/components/FullscreenSwitcher.js +8 -0
- package/components/Icon.js +7 -0
- package/components/IdentifyViewer.js +16 -0
- package/components/ImportLayer.js +25 -0
- package/components/LayerInfoWindow.js +7 -0
- package/components/LinkFeatureForm.js +10 -0
- package/components/MapSelection.js +13 -0
- package/components/NumericInputWindow.js +7 -0
- package/components/PickFeature.js +7 -0
- package/components/PluginsContainer.js +8 -0
- package/components/PrintSelection.js +54 -0
- package/components/QtDesignerForm.js +30 -0
- package/components/ResizeableWindow.js +12 -0
- package/components/SearchBox.js +26 -0
- package/components/ServiceInfoWindow.js +7 -0
- package/components/SideBar.js +9 -0
- package/components/StandardApp.js +35 -0
- package/components/Swipeable.js +1 -0
- package/components/TaskBar.js +7 -0
- package/components/ThemeLayersListWindow.js +9 -0
- package/components/ThemeList.js +12 -0
- package/components/Toolbar.js +7 -0
- package/components/WindowManager.js +7 -0
- package/components/map/OlLayer.js +12 -0
- package/components/map/OlLocate.css +56 -0
- package/components/map/OlLocate.js +17 -0
- package/components/map/OlMap.js +11 -0
- package/components/map/layers/BingLayer.js +8 -0
- package/components/map/layers/GoogleLayer.js +27 -0
- package/components/map/layers/GraticuleLayer.js +8 -0
- package/components/map/layers/ImageLayer.js +8 -0
- package/components/map/layers/MVTLayer.js +7 -0
- package/components/map/layers/OSMLayer.js +8 -0
- package/components/map/layers/OverlayLayer.js +10 -0
- package/components/map/layers/VectorLayer.js +14 -0
- package/components/map/layers/WFSLayer.js +11 -0
- package/components/map/layers/WMSLayer.js +11 -0
- package/components/map/layers/WMTSLayer.js +9 -0
- package/components/map/layers/XYZLayer.js +7 -0
- package/components/map/layers/index.js +8 -0
- package/components/map3d/BottomBar3D.js +7 -0
- package/components/map3d/Compare3D.js +12 -0
- package/components/map3d/Draw3D.js +10 -0
- package/components/map3d/ExportObjects3D.js +17 -0
- package/components/map3d/HeightProfile3D.js +8 -0
- package/components/map3d/HideObjects3D.js +12 -0
- package/components/map3d/Identify3D.js +13 -0
- package/components/map3d/LayerTree3D.js +8 -0
- package/components/map3d/Map3D.js +29 -0
- package/components/map3d/Map3DLight.js +10 -0
- package/components/map3d/MapControls3D.js +20 -0
- package/components/map3d/MapExport3D.js +11 -0
- package/components/map3d/Measure3D.js +23 -0
- package/components/map3d/OverviewMap3D.js +9 -0
- package/components/map3d/SearchField3D.js +16 -0
- package/components/map3d/TopBar3D.js +7 -0
- package/components/map3d/View3DSwitcher.js +7 -0
- package/components/map3d/drawtool/CreateTool3D.js +9 -0
- package/components/map3d/drawtool/EditTool3D.js +9 -0
- package/components/map3d/drawtool/NumericInput3D.js +7 -0
- package/components/map3d/img/viewcone.svg +124 -0
- package/components/map3d/layers/VectorLayer3D.js +7 -0
- package/components/map3d/layers/WFSLayer3D.js +8 -0
- package/components/map3d/layers/WMSLayer3D.js +7 -0
- package/components/map3d/layers/WMTSLayer3D.js +9 -0
- package/components/map3d/layers/index.js +8 -0
- package/components/map3d/models/arrow.glb +0 -0
- package/components/map3d/models/pin.glb +0 -0
- package/components/map3d/slices/map3d.js +1 -0
- package/components/map3d/style/BottomBar3D.css +67 -0
- package/components/map3d/style/Compare3D.css +57 -0
- package/components/map3d/style/Draw3D.css +7 -0
- package/components/map3d/style/HideObjects3D.css +29 -0
- package/components/map3d/style/LayerTree3D.css +126 -0
- package/components/map3d/style/Map3D.css +42 -0
- package/components/map3d/style/Map3DLight.css +72 -0
- package/components/map3d/style/MapControls3D.css +56 -0
- package/components/map3d/style/MapExport3D.css +25 -0
- package/components/map3d/style/OverviewMap3D.css +37 -0
- package/components/map3d/style/SearchField3D.css +7 -0
- package/components/map3d/style/View3DSwitcher.css +27 -0
- package/components/map3d/utils/Tiles3DStyle.js +1 -0
- package/components/share/ShareLink.js +7 -0
- package/components/share/ShareQRCode.js +8 -0
- package/components/share/ShareSocials.js +9 -0
- package/components/share/style/ShareLink.css +13 -0
- package/components/share/style/ShareSocials.css +9 -0
- package/components/style/App.css +229 -0
- package/components/style/AppMenu.css +162 -0
- package/components/style/AttributeForm.css +57 -0
- package/components/style/AutoEditForm.css +64 -0
- package/components/style/DefaultColorScheme.css +60 -0
- package/components/style/EditUploadField.css +103 -0
- package/components/style/FullscreenSwitcher.css +25 -0
- package/components/style/Icon.css +26 -0
- package/components/style/IdentifyViewer.css +249 -0
- package/components/style/ImportLayer.css +28 -0
- package/components/style/LayerInfoWindow.css +46 -0
- package/components/style/LinkFeatureForm.css +48 -0
- package/components/style/NumericInputWindow.css +11 -0
- package/components/style/PickFeature.css +25 -0
- package/components/style/PluginsContainer.css +4 -0
- package/components/style/QtDesignerForm.css +225 -0
- package/components/style/ResizeableWindow.css +178 -0
- package/components/style/SearchBox.css +159 -0
- package/components/style/ServiceInfoWindow.css +34 -0
- package/components/style/SideBar.css +100 -0
- package/components/style/TaskBar.css +35 -0
- package/components/style/ThemeLayersListWindow.css +47 -0
- package/components/style/ThemeList.css +200 -0
- package/components/style/Toolbar.css +20 -0
- package/components/style/WindowManager.css +50 -0
- package/components/timeline/FixedTimeline.js +10 -0
- package/components/timeline/InfiniteTimeline.js +13 -0
- package/components/timeline/TimelineFeaturesSlider.js +10 -0
- package/components/timeline/style/FixedTimeline.css +76 -0
- package/components/timeline/style/InfiniteTimeline.css +94 -0
- package/components/timeline/style/TimelineFeaturesSlider.css +131 -0
- package/components/widgets/AccordeonWidget.js +7 -0
- package/components/widgets/ButtonBar.js +7 -0
- package/components/widgets/ColorButton.js +8 -0
- package/components/widgets/ComboBox.js +7 -0
- package/components/widgets/CopyButton.js +7 -0
- package/components/widgets/DateTimeInput.js +8 -0
- package/components/widgets/EditableSelect.js +8 -0
- package/components/widgets/FileSelector.js +9 -0
- package/components/widgets/Input.js +7 -0
- package/components/widgets/InputContainer.js +7 -0
- package/components/widgets/LayerCatalogWidget.js +3 -0
- package/components/widgets/MenuButton.js +1 -0
- package/components/widgets/ModalDialog.js +7 -0
- package/components/widgets/NavBar.js +7 -0
- package/components/widgets/NumberInput.js +9 -0
- package/components/widgets/PopupMenu.js +1 -0
- package/components/widgets/Primitives.js +7 -0
- package/components/widgets/ReCaptchaWidget.js +1 -0
- package/components/widgets/SearchWidget.js +7 -0
- package/components/widgets/Spinner.js +6 -0
- package/components/widgets/SuggestionInput.js +7 -0
- package/components/widgets/TextInput.js +7 -0
- package/components/widgets/ToggleSwitch.js +7 -0
- package/components/widgets/VectorLayerPicker.js +8 -0
- package/components/widgets/style/AccordeonWidget.css +22 -0
- package/components/widgets/style/ButtonBar.css +88 -0
- package/components/widgets/style/ColorButton.css +88 -0
- package/components/widgets/style/ComboBox.css +83 -0
- package/components/widgets/style/CopyButton.css +21 -0
- package/components/widgets/style/EditableSelect.css +47 -0
- package/components/widgets/style/FileSelector.css +14 -0
- package/components/widgets/style/InputContainer.css +34 -0
- package/components/widgets/style/LayerCatalogWidget.css +59 -0
- package/components/widgets/style/MenuButton.css +122 -0
- package/components/widgets/style/ModalDialog.css +50 -0
- package/components/widgets/style/NavBar.css +12 -0
- package/components/widgets/style/NumberInput.css +76 -0
- package/components/widgets/style/SearchWidget.css +43 -0
- package/components/widgets/style/Spinner.css +32 -0
- package/components/widgets/style/SuggestionInput.css +8 -0
- package/components/widgets/style/TextInput.css +94 -0
- package/components/widgets/style/ToggleSwitch.css +61 -0
- package/components/widgets/style/VectorLayerPicker.css +3 -0
- package/icons/2d.svg +70 -0
- package/icons/3d.svg +70 -0
- package/icons/3d2d.svg +92 -0
- package/icons/after.svg +76 -0
- package/icons/arrow-down.svg +60 -0
- package/icons/arrow-up.svg +60 -0
- package/icons/before.svg +76 -0
- package/icons/bglayer.svg +71 -0
- package/icons/bookmark.svg +170 -0
- package/icons/box.svg +63 -0
- package/icons/buffer.svg +67 -0
- package/icons/camera.svg +118 -0
- package/icons/catalog.svg +62 -0
- package/icons/checked.svg +80 -0
- package/icons/chevron-down.svg +60 -0
- package/icons/chevron-left.svg +59 -0
- package/icons/chevron-right.svg +60 -0
- package/icons/chevron-up.svg +60 -0
- package/icons/circle.svg +70 -0
- package/icons/clear.svg +62 -0
- package/icons/clock.svg +71 -0
- package/icons/cog.svg +60 -0
- package/icons/collapse.svg +73 -0
- package/icons/compare.svg +72 -0
- package/icons/cone.svg +58 -0
- package/icons/confirm.svg +62 -0
- package/icons/copy.svg +60 -0
- package/icons/cuboid.svg +58 -0
- package/icons/cyclomedia.svg +47 -0
- package/icons/cylinder.svg +58 -0
- package/icons/dataimport.svg +116 -0
- package/icons/detach.svg +79 -0
- package/icons/dock.svg +82 -0
- package/icons/dock_bottom.svg +82 -0
- package/icons/dock_left.svg +84 -0
- package/icons/dock_right.svg +84 -0
- package/icons/dock_top.svg +84 -0
- package/icons/draw.svg +78 -0
- package/icons/editdraw.svg +84 -0
- package/icons/edited.svg +78 -0
- package/icons/editing.svg +118 -0
- package/icons/ellipse.svg +72 -0
- package/icons/embed.svg +88 -0
- package/icons/expand.svg +73 -0
- package/icons/export.svg +126 -0
- package/icons/eye.svg +127 -0
- package/icons/featureform.svg +115 -0
- package/icons/fill.svg +62 -0
- package/icons/filter.svg +69 -0
- package/icons/folder-open.svg +60 -0
- package/icons/freehand.svg +82 -0
- package/icons/group.svg +76 -0
- package/icons/home.svg +60 -0
- package/icons/identify_radius.svg +71 -0
- package/icons/identify_region.svg +71 -0
- package/icons/import.svg +62 -0
- package/icons/info-sign.svg +60 -0
- package/icons/info.svg +80 -0
- package/icons/layers.svg +71 -0
- package/icons/light.svg +77 -0
- package/icons/line.svg +61 -0
- package/icons/line_buffer.svg +65 -0
- package/icons/link.svg +75 -0
- package/icons/list-alt.svg +111 -0
- package/icons/lock.svg +54 -0
- package/icons/login.svg +56 -0
- package/icons/logout.svg +56 -0
- package/icons/map3d.svg +51 -0
- package/icons/maximize.svg +84 -0
- package/icons/measure.svg +82 -0
- package/icons/measure_line.svg +87 -0
- package/icons/measure_polygon.svg +88 -0
- package/icons/menu-hamburger.svg +60 -0
- package/icons/minimize.svg +76 -0
- package/icons/minus-sign.svg +60 -0
- package/icons/minus.svg +61 -0
- package/icons/nav-end.svg +74 -0
- package/icons/nav-left.svg +74 -0
- package/icons/nav-right.svg +74 -0
- package/icons/nav-start.svg +73 -0
- package/icons/new.svg +84 -0
- package/icons/nodetool.svg +68 -0
- package/icons/numericinput.svg +86 -0
- package/icons/ok.svg +60 -0
- package/icons/open.svg +79 -0
- package/icons/open_link.svg +74 -0
- package/icons/paint.svg +75 -0
- package/icons/pen.svg +41 -0
- package/icons/person.svg +44 -0
- package/icons/pick.svg +67 -0
- package/icons/pick_point.svg +74 -0
- package/icons/pick_region.svg +71 -0
- package/icons/plus.svg +60 -0
- package/icons/point.svg +67 -0
- package/icons/point_buffer.svg +74 -0
- package/icons/polygon.svg +61 -0
- package/icons/print.svg +60 -0
- package/icons/pyramid.svg +58 -0
- package/icons/radio_checked.svg +78 -0
- package/icons/radio_tristate.svg +75 -0
- package/icons/radio_unchecked.svg +72 -0
- package/icons/rasterexport.svg +124 -0
- package/icons/rect.svg +63 -0
- package/icons/refresh.svg +44 -0
- package/icons/remove.svg +60 -0
- package/icons/report.svg +84 -0
- package/icons/routing-bicycle.svg +40 -0
- package/icons/routing-bus.svg +40 -0
- package/icons/routing-cablecar.svg +40 -0
- package/icons/routing-car.svg +40 -0
- package/icons/routing-ship.svg +40 -0
- package/icons/routing-train.svg +40 -0
- package/icons/routing-tram.svg +40 -0
- package/icons/routing-truck.svg +40 -0
- package/icons/routing-walking.svg +40 -0
- package/icons/routing.svg +68 -0
- package/icons/save.svg +190 -0
- package/icons/scale.svg +62 -0
- package/icons/screenshot.svg +60 -0
- package/icons/search.svg +60 -0
- package/icons/selectbox.svg +79 -0
- package/icons/share.svg +64 -0
- package/icons/snap_edge.svg +79 -0
- package/icons/snap_vertex.svg +79 -0
- package/icons/sphere.svg +58 -0
- package/icons/square.svg +68 -0
- package/icons/sync.svg +72 -0
- package/icons/text.svg +68 -0
- package/icons/themes.svg +81 -0
- package/icons/tilt-down.svg +67 -0
- package/icons/tilt-left.svg +48 -0
- package/icons/tilt-right.svg +48 -0
- package/icons/tilt-up.svg +67 -0
- package/icons/today.svg +45 -0
- package/icons/tools.svg +77 -0
- package/icons/transformtool.svg +74 -0
- package/icons/transparency.svg +132 -0
- package/icons/trash.svg +60 -0
- package/icons/tree_minus.svg +81 -0
- package/icons/tree_plus.svg +81 -0
- package/icons/triangle-down.svg +59 -0
- package/icons/triangle-left.svg +60 -0
- package/icons/triangle-right.svg +60 -0
- package/icons/triangle-up.svg +59 -0
- package/icons/tristate.svg +79 -0
- package/icons/unchecked.svg +74 -0
- package/icons/undock.svg +82 -0
- package/icons/undock_bottom.svg +82 -0
- package/icons/undock_left.svg +82 -0
- package/icons/undock_right.svg +84 -0
- package/icons/undock_top.svg +84 -0
- package/icons/unmaximize.svg +84 -0
- package/icons/unminimize.svg +76 -0
- package/icons/up-down-arrow.svg +66 -0
- package/icons/warning.svg +72 -0
- package/icons/wedge.svg +58 -0
- package/icons/zoom.svg +60 -0
- package/icons/zoomin.svg +71 -0
- package/icons/zoomout.svg +80 -0
- package/libs/openlayers.js +11 -0
- package/package.json +135 -0
- package/plugins/API.js +114 -0
- package/plugins/AttributeTable.js +25 -0
- package/plugins/Authentication.js +13 -0
- package/plugins/BackgroundSwitcher.js +10 -0
- package/plugins/Bookmark.js +13 -0
- package/plugins/BottomBar.js +10 -0
- package/plugins/CookiePopup.js +9 -0
- package/plugins/Cyclomedia.js +11 -0
- package/plugins/Editing.js +21 -0
- package/plugins/FeatureForm.js +21 -0
- package/plugins/FeatureSearch.js +11 -0
- package/plugins/GeometryDigitizer.js +43 -0
- package/plugins/HeightProfile.js +26 -0
- package/plugins/Help.js +11 -0
- package/plugins/HomeButton.js +9 -0
- package/plugins/Identify.js +18 -0
- package/plugins/LayerCatalog.js +45 -0
- package/plugins/LayerTree.js +15 -0
- package/plugins/LocateButton.js +10 -0
- package/plugins/Map.js +22 -0
- package/plugins/MapCompare.js +11 -0
- package/plugins/MapCopyright.js +11 -0
- package/plugins/MapExport.js +23 -0
- package/plugins/MapFilter.js +20 -0
- package/plugins/MapInfoTooltip.js +32 -0
- package/plugins/MapLegend.js +14 -0
- package/plugins/MapTip.js +15 -0
- package/plugins/Measure.js +10 -0
- package/plugins/NewsPopup.js +12 -0
- package/plugins/Panoramax.js +10 -0
- package/plugins/Portal.js +10 -0
- package/plugins/Print.js +22 -0
- package/plugins/ProcessNotifications.js +11 -0
- package/plugins/Redlining.js +12 -0
- package/plugins/Reports.js +15 -0
- package/plugins/Routing.js +23 -0
- package/plugins/ScratchDrawing.js +15 -0
- package/plugins/Settings.js +12 -0
- package/plugins/Share.js +11 -0
- package/plugins/StartupMarker.js +12 -0
- package/plugins/TaskButton.js +9 -0
- package/plugins/ThemeSwitcher.js +10 -0
- package/plugins/TimeManager.js +21 -0
- package/plugins/TopBar.js +13 -0
- package/plugins/ValueTool.js +11 -0
- package/plugins/View3D.js +34 -0
- package/plugins/ZoomButtons.js +11 -0
- package/plugins/map/EditingSupport.js +13 -0
- package/plugins/map/LocateSupport.js +14 -0
- package/plugins/map/MeasurementSupport.js +15 -0
- package/plugins/map/OverviewSupport.js +14 -0
- package/plugins/map/RedliningPickSupport.js +12 -0
- package/plugins/map/RedliningSupport.js +28 -0
- package/plugins/map/ScaleBarSupport.js +10 -0
- package/plugins/map/SnapInteraction.js +1 -0
- package/plugins/map/SnapSupport.js +7 -0
- package/plugins/map/SnappingSupport.js +23 -0
- package/plugins/map/style/OverviewSupport.css +42 -0
- package/plugins/map/style/ScaleBarSupport.css +18 -0
- package/plugins/map/style/SnappingSupport.css +33 -0
- package/plugins/redlining/RedliningBufferSupport.js +8 -0
- package/plugins/style/AttributeTable.css +220 -0
- package/plugins/style/Authentication.css +16 -0
- package/plugins/style/BackgroundSwitcher.css +99 -0
- package/plugins/style/Bookmark.css +62 -0
- package/plugins/style/BottomBar.css +53 -0
- package/plugins/style/Buttons.css +68 -0
- package/plugins/style/CookiePopup.css +24 -0
- package/plugins/style/Cyclomedia.css +66 -0
- package/plugins/style/Editing.css +40 -0
- package/plugins/style/FeatureForm.css +21 -0
- package/plugins/style/FeatureSearch.css +71 -0
- package/plugins/style/GeometryDigitizer.css +28 -0
- package/plugins/style/HeightProfile.css +26 -0
- package/plugins/style/Identify.css +4 -0
- package/plugins/style/LayerCatalog.css +8 -0
- package/plugins/style/LayerTree.css +316 -0
- package/plugins/style/Map.css +43 -0
- package/plugins/style/MapCompare.css +27 -0
- package/plugins/style/MapCopyright.css +17 -0
- package/plugins/style/MapExport.css +55 -0
- package/plugins/style/MapFilter.css +101 -0
- package/plugins/style/MapInfoTooltip.css +78 -0
- package/plugins/style/MapLegend.css +36 -0
- package/plugins/style/MapTip.css +22 -0
- package/plugins/style/Measure.css +23 -0
- package/plugins/style/NewsPopup.css +87 -0
- package/plugins/style/Panoramax.css +15 -0
- package/plugins/style/Portal.css +115 -0
- package/plugins/style/Print.css +116 -0
- package/plugins/style/ProcessNotifications.css +55 -0
- package/plugins/style/Redlining.css +101 -0
- package/plugins/style/Reports.css +11 -0
- package/plugins/style/Routing.css +243 -0
- package/plugins/style/ScratchDrawing.css +8 -0
- package/plugins/style/Settings.css +11 -0
- package/plugins/style/Share.css +59 -0
- package/plugins/style/ThemeSwitcher.css +7 -0
- package/plugins/style/TimeManager.css +91 -0
- package/plugins/style/TopBar.css +50 -0
- package/plugins/style/ValueTool.css +60 -0
- package/reducers/display.js +7 -0
- package/reducers/editing.js +8 -0
- package/reducers/index.js +7 -0
- package/reducers/layerinfo.js +7 -0
- package/reducers/layers.js +14 -0
- package/reducers/localConfig.js +8 -0
- package/reducers/locale.js +8 -0
- package/reducers/locate.js +8 -0
- package/reducers/map.js +11 -0
- package/reducers/measurement.js +8 -0
- package/reducers/processNotifications.js +7 -0
- package/reducers/redlining.js +7 -0
- package/reducers/redliningPick.js +7 -0
- package/reducers/serviceinfo.js +7 -0
- package/reducers/task.js +7 -0
- package/reducers/theme.js +7 -0
- package/reducers/windows.js +7 -0
- package/scripts/dist.sh +16 -0
- package/scripts/gen-plugin-docs.js +9 -0
- package/scripts/makeIconkit.js +7 -0
- package/scripts/package-commands.bat +8 -0
- package/scripts/package-commands.sh +22 -0
- package/scripts/themesConfig.js +48 -0
- package/scripts/themesConfig.py +659 -0
- package/scripts/translateui.sh +51 -0
- package/scripts/updateTranslations.js +17 -0
- package/scripts/wmts_config_generator.py +169 -0
- package/selectors/searchproviders.js +12 -0
- package/static/translations/bg-BG.json +709 -0
- package/static/translations/ca-ES.json +709 -0
- package/static/translations/cs-CZ.json +709 -0
- package/static/translations/de-CH.json +709 -0
- package/static/translations/de-DE.json +709 -0
- package/static/translations/en-US.json +709 -0
- package/static/translations/es-ES.json +709 -0
- package/static/translations/fi-FI.json +709 -0
- package/static/translations/fr-FR.json +709 -0
- package/static/translations/hu-HU.json +709 -0
- package/static/translations/it-IT.json +709 -0
- package/static/translations/ja-JP.json +709 -0
- package/static/translations/nl-NL.json +709 -0
- package/static/translations/no-NO.json +709 -0
- package/static/translations/pl-PL.json +709 -0
- package/static/translations/pt-BR.json +709 -0
- package/static/translations/pt-PT.json +709 -0
- package/static/translations/ro-RO.json +709 -0
- package/static/translations/ru-RU.json +709 -0
- package/static/translations/sv-SE.json +709 -0
- package/static/translations/tr-TR.json +709 -0
- package/static/translations/tsconfig.json +606 -0
- package/stores/StandardStore.js +8 -0
- package/utils/ConfigUtils.js +9 -0
- package/utils/CoordinatesUtils.js +29 -0
- package/utils/DxfUtils.js +10 -0
- package/utils/EditingInterface.js +67 -0
- package/utils/EditingUtils.js +11 -0
- package/utils/FeatureStyles.js +10 -0
- package/utils/IdentifyUtils.js +12 -0
- package/utils/ImageEditor.js +15 -0
- package/utils/LayerUtils.js +57 -0
- package/utils/LocaleUtils.js +9 -0
- package/utils/MapUtils.js +66 -0
- package/utils/MeasureUtils.js +9 -0
- package/utils/MiscUtils.js +15 -0
- package/utils/PermaLinkUtils.js +11 -0
- package/utils/ResourceRegistry.js +7 -0
- package/utils/RoutingInterface.js +12 -0
- package/utils/SearchProviders.js +19 -0
- package/utils/ServiceLayerUtils.js +20 -0
- package/utils/Signal.js +2 -0
- package/utils/ThemeUtils.js +12 -0
- package/utils/VectorLayerUtils.js +20 -0
- package/utils/expr_grammar/README.md +3 -0
- package/utils/expr_grammar/grammar.js +3 -0
- package/utils/expr_grammar/grammar.ne +118 -0
- package/utils/expr_grammar/test.js +13 -0
- package/utils/img/README.markers +1 -0
- package/utils/img/arrowhead.svg +4 -0
- package/utils/img/marker-icon.png +0 -0
- package/utils/img/measurehead.svg +4 -0
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
|
|
3
|
+
if [ $# -lt 2 ]; then
|
|
4
|
+
echo "Usage: $0 form.ui lang1 [lang2 ...]"
|
|
5
|
+
exit 1
|
|
6
|
+
fi
|
|
7
|
+
|
|
8
|
+
UIC=""
|
|
9
|
+
LUPDATE=""
|
|
10
|
+
if command -v uic && command -v lupdate; then
|
|
11
|
+
UIC="uic"
|
|
12
|
+
LUPDATE="lupdate"
|
|
13
|
+
elif command -v uic-qt5 && command -v lupdate-qt5; then
|
|
14
|
+
UIC="uic-qt5"
|
|
15
|
+
LUPDATE="lupdate-qt5"
|
|
16
|
+
elif command -v uic-qt6 && command -v lupdate-qt6; then
|
|
17
|
+
UIC="uic-qt6"
|
|
18
|
+
LUPDATE="lupdate-qt6"
|
|
19
|
+
else
|
|
20
|
+
echo "Could not find uic and/or lupdate in PATH"
|
|
21
|
+
exit 1
|
|
22
|
+
fi
|
|
23
|
+
|
|
24
|
+
cd $(dirname $1)
|
|
25
|
+
ui=$(basename $1)
|
|
26
|
+
|
|
27
|
+
if [ ! -f "$ui" ]; then
|
|
28
|
+
echo "$1 does not exist"
|
|
29
|
+
exit 1
|
|
30
|
+
fi
|
|
31
|
+
|
|
32
|
+
shift
|
|
33
|
+
|
|
34
|
+
tsfiles () {
|
|
35
|
+
for i in $@
|
|
36
|
+
do
|
|
37
|
+
echo -n "${ui/.ui/_$i.ts} "
|
|
38
|
+
done
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
$UIC $ui > ui_${ui/.ui/.h}
|
|
42
|
+
|
|
43
|
+
cat > ${ui/.ui/.pro} <<EOF
|
|
44
|
+
SOURCES += ui_${ui/.ui/.h}
|
|
45
|
+
TRANSLATIONS += $(tsfiles $@)
|
|
46
|
+
EOF
|
|
47
|
+
|
|
48
|
+
$LUPDATE ${ui/.ui/.pro}
|
|
49
|
+
|
|
50
|
+
rm ui_${ui/.ui/.h}
|
|
51
|
+
rm ${ui/.ui/.pro}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* Copyright 2017-2024 Sourcepole AG
|
|
4
|
+
* All rights reserved.
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the BSD-style license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/var _packageJson$dependen;function _toConsumableArray(r){return _arrayWithoutHoles(r)||_iterableToArray(r)||_unsupportedIterableToArray(r)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _iterableToArray(r){if("undefined"!=typeof Symbol&&null!=r[Symbol.iterator]||null!=r["@@iterator"])return Array.from(r)}function _arrayWithoutHoles(r){if(Array.isArray(r))return _arrayLikeToArray(r)}function _createForOfIteratorHelper(r,e){var t="undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=_unsupportedIterableToArray(r))||e&&r&&"number"==typeof r.length){t&&(r=t);var _n=0,F=function F(){};return{s:F,n:function n(){return _n>=r.length?{done:!0}:{done:!1,value:r[_n++]}},e:function e(r){throw r},f:F}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function s(){t=t.call(r)},n:function n(){var r=t.next();return a=r.done,r},e:function e(r){u=!0,o=r},f:function f(){try{a||null==t["return"]||t["return"]()}finally{if(u)throw o}}}}function _unsupportedIterableToArray(r,a){if(r){if("string"==typeof r)return _arrayLikeToArray(r,a);var t={}.toString.call(r).slice(8,-1);return"Object"===t&&r.constructor&&(t=r.constructor.name),"Map"===t||"Set"===t?Array.from(r):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?_arrayLikeToArray(r,a):void 0}}function _arrayLikeToArray(r,a){(null==a||a>r.length)&&(a=r.length);for(var e=0,n=Array(a);e<a;e++)n[e]=r[e];return n}function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},_typeof(o)}var fs=require("fs");var merge=require("deepmerge");var objectPath=require("object-path");var readJSON=function readJSON(path){try{return JSON.parse(fs.readFileSync(process.cwd()+path,"utf8"))}catch(e){return{}}};var _cleanMessages=function cleanMessages(data,ref){for(var _i=0,_Object$keys=Object.keys(data);_i<_Object$keys.length;_i++){var property=_Object$keys[_i];var omit=ref&&!(property in ref);if(_typeof(data[property])==="object"){if(omit){delete data[property]}else{_cleanMessages(data[property],ref?ref[property]:undefined)}}else if(data[property]===""||omit){delete data[property]}}return data};var createSkel=function createSkel(strings){var skel={locale:"",messages:{}};var _iterator=_createForOfIteratorHelper(strings),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var string=_step.value;var path=string.split(".");var cur=skel.messages;for(var i=0;i<path.length-1;++i){cur[path[i]]=cur[path[i]]||{};cur=cur[path[i]]}cur[path[path.length-1]]=""}}catch(err){_iterator.e(err)}finally{_iterator.f()}return skel};var _listDir=function listDir(dir,pattern){var results=[];var list=fs.readdirSync(dir);list.forEach(function(file){if(file==="node_modules"){return}var path=dir+"/"+file;var stat=fs.statSync(path);if(stat&&stat.isDirectory()){/* Recurse into a subdirectory */results=results.concat(_listDir(path,pattern))}else if(pattern.exec(file)){/* Is a file */results.push(path)}});return results};var updateTsConfig=function updateTsConfig(topdir,tsconfig){var collectedMsgIds=arguments.length>2&&arguments[2]!==undefined?arguments[2]:null;var files=_listDir(topdir,/^.*\.jsx?$/);var trRegEx=/LocaleUtils\.tr(?:msg)?\((['"])([A-Za-z0-9._]+)\1/g;var msgIds=new Set;var _iterator2=_createForOfIteratorHelper(files),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var file=_step2.value;var data=fs.readFileSync(file).toString();var _iterator3=_createForOfIteratorHelper(data.matchAll(trRegEx)),_step3;try{for(_iterator3.s();!(_step3=_iterator3.n()).done;){var match=_step3.value;if((!collectedMsgIds||!collectedMsgIds.has(match[2]))&&!match[2].endsWith(".")){msgIds.add(match[2])}}}catch(err){_iterator3.e(err)}finally{_iterator3.f()}}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}var msgIdList=Array.from(msgIds);msgIdList.sort();var json=readJSON(tsconfig);json.strings=msgIdList;fs.writeFileSync(process.cwd()+"/"+tsconfig,JSON.stringify(json,null,2)+"\n");return msgIds};// Determine workspaces / dependencies
|
|
9
|
+
var packageJson=readJSON("/package.json");var workspaces=packageJson.workspaces||[];var qwcDeps=Object.keys((_packageJson$dependen=packageJson.dependencies)!==null&&_packageJson$dependen!==void 0?_packageJson$dependen:{qwc2:"0"}).filter(function(dep){return dep.startsWith("qwc")});// Generate workspace translations
|
|
10
|
+
var collectedMsgIds=new Set;var _iterator4=_createForOfIteratorHelper(workspaces),_step4;try{for(_iterator4.s();!(_step4=_iterator4.n()).done;){var workspace=_step4.value;/* eslint-disable-next-line */console.log("Generating translations for "+workspace);var newMsgIds=updateTsConfig(process.cwd()+"/"+workspace,"/"+workspace+"/static/translations/tsconfig.json");collectedMsgIds=new Set([].concat(_toConsumableArray(collectedMsgIds),_toConsumableArray(newMsgIds)));var _config=readJSON("/"+workspace+"/static/translations/tsconfig.json");var _strings=[].concat(_toConsumableArray(_config.strings||[]),_toConsumableArray(_config.extra_strings||[]));var _skel=createSkel(_strings);var _iterator6=_createForOfIteratorHelper(_config.languages||[]),_step6;try{for(_iterator6.s();!(_step6=_iterator6.n()).done;){var lang=_step6.value;var langskel=merge(_skel,{locale:lang});// Merge translations
|
|
11
|
+
var data=merge(langskel,_cleanMessages(readJSON("/"+workspace+"/static/translations/"+lang+".json"),langskel));// Write updated translations file
|
|
12
|
+
try{fs.writeFileSync(process.cwd()+"/"+workspace+"/static/translations/"+lang+".json",JSON.stringify(data,null,2)+"\n");/* eslint-disable-next-line */console.log("Wrote "+workspace+"/static/translations/"+lang+".json")}catch(e){/* eslint-disable-next-line */console.error("Failed to write "+workspace+"/static/translations/"+lang+".json: "+e)}}}catch(err){_iterator6.e(err)}finally{_iterator6.f()}}// Generate application translations
|
|
13
|
+
}catch(err){_iterator4.e(err)}finally{_iterator4.f()}updateTsConfig(fs.existsSync(process.cwd()+"/js")?process.cwd()+"/js":process.cwd(),"/static/translations/tsconfig.json",collectedMsgIds);var config=readJSON("/static/translations/tsconfig.json");var strings=[].concat(_toConsumableArray(config.strings||[]),_toConsumableArray(config.extra_strings||[]));var skel=createSkel(strings);var _iterator5=_createForOfIteratorHelper(config.languages||[]),_step5;try{for(_iterator5.s();!(_step5=_iterator5.n()).done;){var _lang=_step5.value;var _langskel=merge(skel,{locale:_lang});var origData=readJSON("/static/translations/"+_lang+".json");var _data=merge(_langskel,_cleanMessages(readJSON("/static/translations/"+_lang+".json"),_langskel));// Merge translations from workspaces
|
|
14
|
+
var _iterator7=_createForOfIteratorHelper(workspaces),_step7;try{for(_iterator7.s();!(_step7=_iterator7.n()).done;){var _workspace=_step7.value;_data=merge(_data,readJSON("/"+_workspace+"/static/translations/"+_lang+".json"))}// Merge translations from dependencies
|
|
15
|
+
}catch(err){_iterator7.e(err)}finally{_iterator7.f()}var _iterator8=_createForOfIteratorHelper(qwcDeps),_step8;try{for(_iterator8.s();!(_step8=_iterator8.n()).done;){var qwcDep=_step8.value;_data=merge(_data,readJSON("/node_modules/"+qwcDep+"/static/translations/"+_lang+".json"))}// Revert to original values for strings specified in overrides
|
|
16
|
+
}catch(err){_iterator8.e(err)}finally{_iterator8.f()}var _iterator9=_createForOfIteratorHelper(config.overrides||[]),_step9;try{for(_iterator9.s();!(_step9=_iterator9.n()).done;){var path=_step9.value;var value=objectPath.get(origData.messages,path);if(value!==undefined){objectPath.set(_data.messages,path,value)}}// Write output
|
|
17
|
+
}catch(err){_iterator9.e(err)}finally{_iterator9.f()}try{fs.writeFileSync(process.cwd()+"/static/translations/"+_lang+".json",JSON.stringify(_data,null,2)+"\n");/* eslint-disable-next-line */console.log("Wrote static/translations/"+_lang+".json")}catch(e){/* eslint-disable-next-line */console.error("Failed to write static/translations/"+_lang+".json: "+e)}}}catch(err){_iterator5.e(err)}finally{_iterator5.f()}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
#!/usr/bin/python3
|
|
2
|
+
|
|
3
|
+
# Automatically generates a QWC2 WMTS background layer configuration, to be added to themesConfig.json
|
|
4
|
+
#
|
|
5
|
+
# Usage: wmts_config_generator.py <WMTS Capabilities URL> <LayerName> <Projection> [<format>]
|
|
6
|
+
#
|
|
7
|
+
# Example: wmts_config_generator.py https://www.wmts.nrw.de/geobasis/wmts_nw_dop/1.0.0/WMTSCapabilities.xml nw_dop EPSG:25832
|
|
8
|
+
|
|
9
|
+
import json
|
|
10
|
+
import re
|
|
11
|
+
import sys
|
|
12
|
+
import urllib.request
|
|
13
|
+
from xml.dom.minidom import parseString
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def getFirstElementByTagName(parent, name):
|
|
17
|
+
try:
|
|
18
|
+
return parent.getElementsByTagName(name)[0]
|
|
19
|
+
except:
|
|
20
|
+
return None
|
|
21
|
+
|
|
22
|
+
def getFirstElementValueByTagName(parent, name):
|
|
23
|
+
try:
|
|
24
|
+
return parent.getElementsByTagName(name)[0].firstChild.nodeValue
|
|
25
|
+
except:
|
|
26
|
+
return ""
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
if len(sys.argv) < 4:
|
|
30
|
+
print("Usage: %s WMTS_Capabilities_URL LayerName Projection [style=default]" % sys.argv[0], file=sys.stderr)
|
|
31
|
+
sys.exit(1)
|
|
32
|
+
|
|
33
|
+
capabilitiesUrl = sys.argv[1]
|
|
34
|
+
layerName = sys.argv[2]
|
|
35
|
+
crs = sys.argv[3]
|
|
36
|
+
styleIdentifier = sys.argv[4] if len(sys.argv) > 4 else ""
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
try:
|
|
40
|
+
response = urllib.request.urlopen(capabilitiesUrl)
|
|
41
|
+
except:
|
|
42
|
+
print("Failed to download capabilities", file=sys.stderr)
|
|
43
|
+
sys.exit(1)
|
|
44
|
+
|
|
45
|
+
try:
|
|
46
|
+
capabilities = parseString(response.read())
|
|
47
|
+
except:
|
|
48
|
+
print("Failed to parse capabilities", file=sys.stderr)
|
|
49
|
+
sys.exit(1)
|
|
50
|
+
|
|
51
|
+
contents = getFirstElementByTagName(capabilities, "Contents")
|
|
52
|
+
|
|
53
|
+
# Search for layer
|
|
54
|
+
targetLayer = None
|
|
55
|
+
for layer in contents.getElementsByTagName("Layer"):
|
|
56
|
+
identifier = getFirstElementValueByTagName(layer, "ows:Identifier")
|
|
57
|
+
if identifier == layerName:
|
|
58
|
+
targetLayer = layer
|
|
59
|
+
break
|
|
60
|
+
|
|
61
|
+
if not targetLayer:
|
|
62
|
+
print("Could not find layer %s in capabilities" % layerName, file=sys.stderr)
|
|
63
|
+
sys.exit(1)
|
|
64
|
+
|
|
65
|
+
# Get supported tile matrix
|
|
66
|
+
layerTileMatrixSet = []
|
|
67
|
+
for tileMatrixSetLink in targetLayer.getElementsByTagName("TileMatrixSetLink"):
|
|
68
|
+
layerTileMatrixSet.append(getFirstElementValueByTagName(tileMatrixSetLink, "TileMatrixSet"))
|
|
69
|
+
|
|
70
|
+
# Get best tile matrix
|
|
71
|
+
tileMatrix = None
|
|
72
|
+
tileMatrixName = ""
|
|
73
|
+
for child in contents.childNodes:
|
|
74
|
+
if child.nodeName == "TileMatrixSet":
|
|
75
|
+
tileMatrixSet = child
|
|
76
|
+
tileMatrixName = getFirstElementValueByTagName(tileMatrixSet, "ows:Identifier")
|
|
77
|
+
supportedCrs = getFirstElementValueByTagName(tileMatrixSet, "ows:SupportedCRS")
|
|
78
|
+
crsMatch = re.search(r'(EPSG).*:(\d+)', supportedCrs)
|
|
79
|
+
if crsMatch and crs == "EPSG:" + crsMatch.group(2) and tileMatrixName in layerTileMatrixSet:
|
|
80
|
+
tileMatrix = tileMatrixSet.getElementsByTagName("TileMatrix")
|
|
81
|
+
break
|
|
82
|
+
|
|
83
|
+
if not tileMatrix:
|
|
84
|
+
print("Could not find compatible tile matrix", file=sys.stderr)
|
|
85
|
+
sys.exit(1)
|
|
86
|
+
|
|
87
|
+
# Boundingbox
|
|
88
|
+
wgsBboxEl = getFirstElementByTagName(layer, "ows:WGS84BoundingBox")
|
|
89
|
+
tmsBboxEl = getFirstElementByTagName(tileMatrixSet, "ows:BoundingBox")
|
|
90
|
+
if wgsBboxEl is not None:
|
|
91
|
+
bboxLower = list(map(float, getFirstElementValueByTagName(wgsBboxEl, "ows:LowerCorner").split(" ")))
|
|
92
|
+
bboxUpper = list(map(float, getFirstElementValueByTagName(wgsBboxEl, "ows:UpperCorner").split(" ")))
|
|
93
|
+
bbox = {
|
|
94
|
+
"crs": "EPSG:4326",
|
|
95
|
+
"bounds": [bboxLower[0], bboxLower[1], bboxUpper[0], bboxUpper[1]]
|
|
96
|
+
}
|
|
97
|
+
elif tmsBboxEl is not None:
|
|
98
|
+
bboxLower = list(map(float, getFirstElementValueByTagName(tmsBboxEl, "ows:LowerCorner").split(" ")))
|
|
99
|
+
bboxUpper = list(map(float, getFirstElementValueByTagName(tmsBboxEl, "ows:UpperCorner").split(" ")))
|
|
100
|
+
crsMatch = re.search(r'(EPSG).*:(\d+)', tmsBboxEl.getAttribute("crs"))
|
|
101
|
+
bbox = {
|
|
102
|
+
"crs": ("EPSG:" + crsMatch.group(2)) if crsMatch else crs,
|
|
103
|
+
"bounds": [bboxLower[0], bboxLower[1], bboxUpper[0], bboxUpper[1]]
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
# Compute origin and resolutions
|
|
108
|
+
origin = list(map(float, filter(bool, getFirstElementValueByTagName(tileMatrix[0], "TopLeftCorner").split(" "))))
|
|
109
|
+
tileSize = [
|
|
110
|
+
int(getFirstElementValueByTagName(tileMatrix[0], "TileWidth")),
|
|
111
|
+
int(getFirstElementValueByTagName(tileMatrix[0], "TileHeight"))
|
|
112
|
+
]
|
|
113
|
+
resolutions = []
|
|
114
|
+
for entry in tileMatrix:
|
|
115
|
+
scaleDenominator = getFirstElementValueByTagName(entry, "ScaleDenominator")
|
|
116
|
+
# 0.00028: assumed pixel width in meters, as per WMTS standard
|
|
117
|
+
resolutions.append(float(scaleDenominator) * 0.00028)
|
|
118
|
+
|
|
119
|
+
# Determine style
|
|
120
|
+
if not styleIdentifier:
|
|
121
|
+
for style in targetLayer.getElementsByTagName("Style"):
|
|
122
|
+
if style.getAttribute("isDefault") == "true":
|
|
123
|
+
styleIdentifier = getFirstElementValueByTagName(style, "ows:Identifier")
|
|
124
|
+
break
|
|
125
|
+
|
|
126
|
+
# Resource URL
|
|
127
|
+
tileUrl = None
|
|
128
|
+
for resourceURL in targetLayer.getElementsByTagName("ResourceURL"):
|
|
129
|
+
if resourceURL.getAttribute("resourceType") == "tile":
|
|
130
|
+
tileUrl = resourceURL.getAttribute("template")
|
|
131
|
+
|
|
132
|
+
# Dimensions
|
|
133
|
+
for dimension in targetLayer.getElementsByTagName("Dimension"):
|
|
134
|
+
dimensionIdentifier = getFirstElementValueByTagName(dimension, "ows:Identifier")
|
|
135
|
+
dimensionValue = getFirstElementValueByTagName(dimension, "Default")
|
|
136
|
+
tileUrl = tileUrl.replace("{%s}" % dimensionIdentifier, dimensionValue)
|
|
137
|
+
|
|
138
|
+
# Format
|
|
139
|
+
format = getFirstElementValueByTagName(targetLayer, "Format")
|
|
140
|
+
|
|
141
|
+
# RequestEncoding
|
|
142
|
+
requestEncoding = ""
|
|
143
|
+
operationsMetadata = getFirstElementByTagName(capabilities, "ows:OperationsMetadata")
|
|
144
|
+
if operationsMetadata is not None:
|
|
145
|
+
for operation in operationsMetadata.getElementsByTagName("ows:Operation"):
|
|
146
|
+
if operation.getAttribute("name") == "GetCapabilities":
|
|
147
|
+
constraint = getFirstElementByTagName(operation, "ows:Constraint")
|
|
148
|
+
if constraint.getAttribute("name") == "GetEncoding":
|
|
149
|
+
requestEncoding = getFirstElementValueByTagName(constraint, "ows:Value")
|
|
150
|
+
|
|
151
|
+
result = {
|
|
152
|
+
"type": "wmts",
|
|
153
|
+
"url": tileUrl,
|
|
154
|
+
"name": layerName,
|
|
155
|
+
"format": format,
|
|
156
|
+
"requestEncoding": requestEncoding,
|
|
157
|
+
"tileMatrixPrefix": "",
|
|
158
|
+
"tileMatrixSet": tileMatrixName,
|
|
159
|
+
"originX": origin[0],
|
|
160
|
+
"originY": origin[1],
|
|
161
|
+
"projection": crs,
|
|
162
|
+
"tileSize": tileSize,
|
|
163
|
+
"style": styleIdentifier,
|
|
164
|
+
"bbox": bbox,
|
|
165
|
+
"resolutions": resolutions,
|
|
166
|
+
"thumbnail": layerName + ".jpg",
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
print(json.dumps(result, indent=2))
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
function _typeof(o){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},_typeof(o)}function _createForOfIteratorHelper(r,e){var t="undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=_unsupportedIterableToArray(r))||e&&r&&"number"==typeof r.length){t&&(r=t);var _n=0,F=function F(){};return{s:F,n:function n(){return _n>=r.length?{done:!0}:{done:!1,value:r[_n++]}},e:function e(r){throw r},f:F}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function s(){t=t.call(r)},n:function n(){var r=t.next();return a=r.done,r},e:function e(r){u=!0,o=r},f:function f(){try{a||null==t["return"]||t["return"]()}finally{if(u)throw o}}}}function ownKeys(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),t.push.apply(t,o)}return t}function _objectSpread(e){for(var r=1;r<arguments.length;r++){var t=null!=arguments[r]?arguments[r]:{};r%2?ownKeys(Object(t),!0).forEach(function(r){_defineProperty(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ownKeys(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function _defineProperty(e,r,t){return(r=_toPropertyKey(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==_typeof(i)?i:i+""}function _toPrimitive(t,r){if("object"!=_typeof(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(t)}function _toConsumableArray(r){return _arrayWithoutHoles(r)||_iterableToArray(r)||_unsupportedIterableToArray(r)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _unsupportedIterableToArray(r,a){if(r){if("string"==typeof r)return _arrayLikeToArray(r,a);var t={}.toString.call(r).slice(8,-1);return"Object"===t&&r.constructor&&(t=r.constructor.name),"Map"===t||"Set"===t?Array.from(r):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?_arrayLikeToArray(r,a):void 0}}function _iterableToArray(r){if("undefined"!=typeof Symbol&&null!=r[Symbol.iterator]||null!=r["@@iterator"])return Array.from(r)}function _arrayWithoutHoles(r){if(Array.isArray(r))return _arrayLikeToArray(r)}function _arrayLikeToArray(r,a){(null==a||a>r.length)&&(a=r.length);for(var e=0,n=Array(a);e<a;e++)n[e]=r[e];return n}/**
|
|
2
|
+
* Copyright 2020-2024 Sourcepole AG
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
* This source code is licensed under the BSD-style license found in the
|
|
6
|
+
* LICENSE file in the root directory of this source tree.
|
|
7
|
+
*/import{createSelector}from"reselect";import{LayerRole}from"../actions/layers";import ConfigUtils from"../utils/ConfigUtils";import LayerUtils from"../utils/LayerUtils";import LocaleUtils from"../utils/LocaleUtils";import MapUtils from"../utils/MapUtils";import SearchProviders from"../utils/SearchProviders";import ThemeUtils from"../utils/ThemeUtils";import VectorLayerUtils from"../utils/VectorLayerUtils";// Uniformize the response of getResultGeometry
|
|
8
|
+
function getResultGeometry(provider,item,callback){provider.getResultGeometry(item,function(response){var features=[];if(response!==null&&response!==void 0&&response.geometry){var highlightFeature=response.geometry.coordinates?{type:"Feature",geometry:response.geometry}:VectorLayerUtils.wktToGeoJSON(response.geometry,response.crs,response.crs);if(highlightFeature){features.push(highlightFeature)}}else if(response!==null&&response!==void 0&&response.feature){if(response.feature.features){features.push.apply(features,_toConsumableArray(response.feature.features))}else{features.push(response.feature)}}if(features.length===0){callback(null)}else{callback(_objectSpread(_objectSpread({feature:{type:"FeatureCollection",features:features},crs:response.crs,hidemarker:response.hidemarker},response.bbox&&{bbox:response.bbox}),response.center&&{center:response.center}))}})}export default createSelector([function(state){return state.theme.current},function(state){return state.theme},function(state){return state.layers.flat},function(state){return state.map.scales},function(state){return state.map.zoom}],function(theme,themes,layers,scales,zoom){// Collect active layers/search terms
|
|
9
|
+
var searchTerms=[];var activeLayers=[];var mapScale=MapUtils.computeForZoom(scales,zoom);var _iterator=_createForOfIteratorHelper(LayerUtils.explodeLayers(layers)),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var entry=_step.value;if(entry.layer.role===LayerRole.THEME&&entry.sublayer.visibility===true&&LayerUtils.layerScaleInRange(entry.sublayer,mapScale)){searchTerms=searchTerms.concat(entry.sublayer.searchterms||[]);activeLayers.push(entry.sublayer.name)}}}catch(err){_iterator.e(err)}finally{_iterator.f()}var searchProviders=_objectSpread(_objectSpread({},SearchProviders),window.QWC2SearchProviders||{});var availableProviders={};var themeLayerNames=layers.map(function(layer){return layer.role===LayerRole.THEME?layer.params.LAYERS:""}).join(",").split(",").filter(function(entry){return entry});var providerKeys=new Set;var _iterator2=_createForOfIteratorHelper((theme===null||theme===void 0?void 0:theme.searchProviders)||[]),_step2;try{var _loop=function _loop(){var _entry;var entry=_step2.value;if(typeof entry==="string"){entry={provider:entry}}// Omit qgis provider with field configuration, this is only supported through the FeatureSearch plugin
|
|
10
|
+
if(entry.provider==="qgis"&&(_entry=entry)!==null&&_entry!==void 0&&(_entry=_entry.params)!==null&&_entry!==void 0&&_entry.fields){return 0;// continue
|
|
11
|
+
}var provider=searchProviders[entry.provider];if(provider){var _entry$key,_entry$label,_entry$labelmsgid;if(provider.requiresLayer&&!themeLayerNames.includes(provider.requiresLayer)){return 0;// continue
|
|
12
|
+
}var key=(_entry$key=entry.key)!==null&&_entry$key!==void 0?_entry$key:entry.provider;if(providerKeys.has(key)){var i=0;for(i=0;providerKeys.has(key+"_"+i);++i);key=key+"_"+i}providerKeys.add(key);availableProviders[key]=_objectSpread(_objectSpread({},provider),{},{label:(_entry$label=entry.label)!==null&&_entry$label!==void 0?_entry$label:provider.label,labelmsgid:(_entry$labelmsgid=entry.labelmsgid)!==null&&_entry$labelmsgid!==void 0?_entry$labelmsgid:provider.labelmsgid,getResultGeometry:provider.getResultGeometry?function(item,callback){return getResultGeometry(provider,item,callback)}:null,cfgParams:entry.params||{},params:{searchTerms:searchTerms,activeLayers:activeLayers,theme:theme}})}},_ret;for(_iterator2.s();!(_step2=_iterator2.n()).done;){_ret=_loop();if(_ret===0)continue}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}if(ConfigUtils.getConfigProp("searchThemes",theme)){availableProviders.themes={labelmsgid:LocaleUtils.trmsg("search.themes"),onSearch:function onSearch(text,options,callback){callback({results:ThemeUtils.searchThemes(themes.themes,text)})}}}if(ConfigUtils.getConfigProp("searchThemeLayers",theme)){availableProviders.themelayers={labelmsgid:LocaleUtils.trmsg("search.themelayers"),onSearch:function onSearch(text,options,callback){callback({results:ThemeUtils.searchThemeLayers(themes.themes,text)})}}}return availableProviders});
|