@opengeoweb/webmap-react 9.4.1 → 9.6.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/package.json CHANGED
@@ -1,12 +1,29 @@
1
1
  {
2
2
  "name": "@opengeoweb/webmap-react",
3
- "version": "9.4.1",
3
+ "version": "9.6.0",
4
4
  "description": "GeoWeb react wrapper for webmap",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "git@gitlab.com:opengeoweb/opengeoweb.git"
9
9
  },
10
+ "dependencies": {
11
+ "@opengeoweb/webmap": "*",
12
+ "axios": "1.5.0",
13
+ "@opengeoweb/theme": "*",
14
+ "@mui/material": "5.12.0",
15
+ "@opengeoweb/shared": "*",
16
+ "lodash": "^4.17.21",
17
+ "proj4": "^2.9.2",
18
+ "@turf/turf": "^6.5.0",
19
+ "immer": "^9.0.21",
20
+ "react-resize-detector": "^9.1.0",
21
+ "throttle-debounce": "^5.0.0",
22
+ "date-fns": "^3.3.0"
23
+ },
24
+ "peerDependencies": {
25
+ "react": "18"
26
+ },
10
27
  "module": "./index.esm.js",
11
28
  "type": "module",
12
29
  "main": "./index.esm.js"
@@ -4,6 +4,7 @@ export declare const simpleSmallLineStringGeoJSON: GeoJSON.FeatureCollection;
4
4
  export declare const simpleFlightRoutePointsGeoJSON: GeoJSON.FeatureCollection;
5
5
  export declare const simpleLineStringGeoJSON: GeoJSON.FeatureCollection;
6
6
  export declare const simpleBoxGeoJSON: GeoJSON.FeatureCollection;
7
+ export declare const simpleBoxGeoJSONWrongOrder: GeoJSON.FeatureCollection;
7
8
  export declare const simpleFlightRouteLineStringGeoJSON: GeoJSON.FeatureCollection;
8
9
  export declare const simpleMultiPolygon: GeoJSON.FeatureCollection;
9
10
  export declare const intersectionFeatureNL: GeoJSON.Feature;
@@ -2,6 +2,7 @@
2
2
  import * as React from 'react';
3
3
  import { WMJSMap, WMLayer, WMBBOX } from '@opengeoweb/webmap';
4
4
  import { ReactMapViewProps } from './types';
5
+ import type { MapViewLayerProps } from '../MapView';
5
6
  export declare const ORIGIN_REACTMAPVIEW_ONMAPCHANGEDIMENSION = "ORIGIN_REACTMAPVIEW_ONMAPCHANGEDIMENSION";
6
7
  export declare const ORIGIN_REACTMAPVIEW_ONUPDATELAYERINFO = "ORIGIN_REACTMAPVIEW_ONUPDATELAYERINFO";
7
8
  interface ReactMapViewState {
@@ -13,9 +14,7 @@ interface AdagucObjectProp {
13
14
  oldbbox: WMBBOX;
14
15
  currentWidth: number;
15
16
  currentHeight: number;
16
- currentMapProps: {
17
- children?: React.ReactNode;
18
- };
17
+ currentChildren: MapViewLayerProps[];
19
18
  }
20
19
  export declare class ReactMapView extends React.Component<ReactMapViewProps, ReactMapViewState> {
21
20
  adaguc: AdagucObjectProp;
@@ -48,7 +47,6 @@ export declare class ReactMapView extends React.Component<ReactMapViewProps, Rea
48
47
  onUpdateBBoxListener(newBbox: WMBBOX): void;
49
48
  onStartRefetchTimer: () => void;
50
49
  clearRefetchTimer: () => void;
51
- parseWMJSLayer: (wmLayer: WMLayer, forceReload: boolean, child?: React.ReactElement) => void;
52
50
  updateWMJSMapProps(prevProps: ReactMapViewProps, props: ReactMapViewProps): void;
53
51
  drawDebounced(): void;
54
52
  mountWMJSMap(): WMJSMap | null;
@@ -1,4 +1,4 @@
1
1
  import { WMLayer, WMJSDimension } from '@opengeoweb/webmap';
2
2
  import { UpdateLayerInfoPayload } from './types';
3
3
  export declare const getCurrentDimensionValue: (name: string, dimensions?: WMJSDimension[]) => string;
4
- export declare const setLayerInfo: (wmLayer: WMLayer, mapId: string, onUpdateLayerInformation?: ((payload: UpdateLayerInfoPayload) => void) | undefined) => void;
4
+ export declare const getLayerUpdateInfo: (wmLayer: WMLayer, mapId: string) => UpdateLayerInfoPayload;
@@ -55,6 +55,10 @@ export interface SetBboxPayload {
55
55
  srs?: string;
56
56
  origin?: string;
57
57
  }
58
+ export interface SetStepBackWardOrForward {
59
+ mapId: string;
60
+ isForwardStep: boolean;
61
+ }
58
62
  export interface SetLayerDimensionsPayload {
59
63
  layerId: string;
60
64
  origin: string;
@@ -1,5 +1,8 @@
1
- import { Dimension, LayerFoundation, WMLayer } from '@opengeoweb/webmap';
1
+ import { Dimension, LayerFoundation, WMJSMap, WMLayer } from '@opengeoweb/webmap';
2
+ import React from 'react';
2
3
  import { FeatureLayer } from '../MapDraw';
4
+ import type { MapViewLayerProps, MapViewProps } from '../MapView';
5
+ import { ReactMapViewProps, UpdateLayerInfoPayload } from './types';
3
6
  /**
4
7
  * Returns filtered list of props with geoJson
5
8
  * @param children React.ReactNode, layers with geoJson
@@ -15,8 +18,10 @@ export declare const isAMapLayer: (layer: LayerFoundation) => boolean;
15
18
  * @param layer The LayerFoundation object, or the props from the ReactWMJSLayer
16
19
  */
17
20
  export declare const isAGeoJSONLayer: (layer: LayerFoundation) => boolean;
18
- export declare const getWMJSLayerFromReactLayer: (mapId: string, wmLayers: WMLayer[], reactWebMapJSLayer: React.ReactElement, wmLayerIndex: number) => {
19
- layer: WMLayer;
20
- layerArrayMutated: boolean;
21
- };
22
21
  export declare function getIsInsideAcceptanceTime(acceptanceTimeInMinutes: number | undefined, mapDimensions: Dimension[] | undefined, layerDimensions: Dimension[] | undefined): boolean;
22
+ export declare const makeLayerPropListFromChildren: (children: React.ReactNode, mapId: string) => MapViewLayerProps[];
23
+ export declare const parseWMJSLayer: (wmLayer: WMLayer, forceReload: boolean) => Promise<WMLayer>;
24
+ export declare const setWMLayerPropsBasedOnChildProps: (child: MapViewLayerProps, wmLayer: WMLayer, mapViewProps: ReactMapViewProps) => boolean;
25
+ export declare const addWMLayerPropsBasedOnChildProps: (child: MapViewLayerProps, mapId: string, props: MapViewProps, onUpdateLayerInformation?: ((payload: UpdateLayerInfoPayload) => void) | undefined) => void;
26
+ export declare const removeWMLayerFromMap: (wmLayer: WMLayer, mapId: string, onUpdateLayerInformation?: ((payload: UpdateLayerInfoPayload) => void) | undefined) => void;
27
+ export declare const orderLayers: (wmjsMap: WMJSMap, _reactMapViewLayers: MapViewLayerProps[]) => boolean;