@opengeoweb/webmap-react 9.14.0 → 9.16.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,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengeoweb/webmap-react",
3
- "version": "9.14.0",
3
+ "version": "9.16.0",
4
4
  "description": "GeoWeb react wrapper for webmap",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -18,7 +18,9 @@
18
18
  "@turf/turf": "^6.5.0",
19
19
  "immer": "^10.0.3",
20
20
  "react-resize-detector": "^9.1.0",
21
- "throttle-debounce": "^5.0.0"
21
+ "throttle-debounce": "^5.0.0",
22
+ "i18next": "^23.7.11",
23
+ "react-i18next": "^13.5.0"
22
24
  },
23
25
  "peerDependencies": {
24
26
  "react": "18"
package/src/index.d.ts CHANGED
@@ -1 +1,3 @@
1
+ import webmapReactTranslations from '../locales/webmap-react.json';
1
2
  export * from './lib';
3
+ export { webmapReactTranslations };
@@ -1,5 +1,6 @@
1
1
  import { Feature } from '@turf/turf';
2
2
  import { FeatureCollection, GeoJsonProperties, Point } from 'geojson';
3
+ import { Bbox } from '@opengeoweb/webmap';
3
4
  import { DrawMode, SelectionType } from './types';
4
5
  /**
5
6
  * Adds properties to the first geojson feature based on the given property object.
@@ -59,3 +60,4 @@ export declare const isGeoJSONFeatureCreatedByTool: (existingJSON: GeoJSON.Featu
59
60
  export declare const rewindGeometry: (geoJSON: FeatureCollection) => FeatureCollection;
60
61
  export declare const addGeoJSONProperties: (geoJSON: GeoJSON.Feature | GeoJSON.FeatureCollection, newProperties: GeoJsonProperties) => GeoJSON.Feature | GeoJSON.FeatureCollection;
61
62
  export declare const addSelectionTypeToGeoJSON: (geoJSON: GeoJSON.Feature | GeoJSON.FeatureCollection, selectionType: SelectionType) => GeoJSON.Feature | GeoJSON.FeatureCollection;
63
+ export declare const getFeatureExtent: (geoJSON: GeoJSON.Feature | GeoJSON.FeatureCollection) => Bbox;
@@ -0,0 +1,10 @@
1
+ import * as React from 'react';
2
+ declare const _default: {
3
+ title: string;
4
+ component: React.FC<import("./MapView").MapViewProps>;
5
+ };
6
+ export default _default;
7
+ export declare const HoldShiftToZoom: {
8
+ (): React.ReactElement;
9
+ storyName: string;
10
+ };
@@ -0,0 +1,22 @@
1
+ import * as React from 'react';
2
+ declare const _default: {
3
+ title: string;
4
+ component: React.FC<import("./MapView").MapViewProps>;
5
+ };
6
+ export default _default;
7
+ export interface MapDropDownItem {
8
+ name: string;
9
+ title: string;
10
+ }
11
+ export interface MapDropDownProps {
12
+ value: string;
13
+ change: (updatedValue: string) => void;
14
+ options: MapDropDownItem[];
15
+ top?: number;
16
+ left?: number;
17
+ }
18
+ export declare const MapDropDown: ({ value, change, options, top, left, }: MapDropDownProps) => React.ReactElement<MapDropDownProps>;
19
+ export declare const MapViewTiledBaseLayers: {
20
+ (): React.ReactElement;
21
+ storyName: string;
22
+ };
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ import { ThemeProviderProps } from '@opengeoweb/theme';
3
+ export declare const WebmapReactThemeProvider: React.FC<ThemeProviderProps>;
4
+ interface WebmapReactTranslationWrapperProps {
5
+ children?: React.ReactNode;
6
+ }
7
+ export declare const WebmapReactI18nProvider: React.FC<WebmapReactTranslationWrapperProps>;
8
+ export {};
@@ -0,0 +1 @@
1
+ export * from './Providers';
@@ -5,6 +5,7 @@ import { ReactMapViewProps } from './types';
5
5
  import type { MapViewLayerProps } from '../MapView';
6
6
  export declare const ORIGIN_REACTMAPVIEW_ONMAPCHANGEDIMENSION = "ORIGIN_REACTMAPVIEW_ONMAPCHANGEDIMENSION";
7
7
  export declare const ORIGIN_REACTMAPVIEW_ONUPDATELAYERINFO = "ORIGIN_REACTMAPVIEW_ONUPDATELAYERINFO";
8
+ export declare const MINUTE_TO_MILLISECOND = 60000;
8
9
  interface ReactMapViewState {
9
10
  adagucInitialised: boolean;
10
11
  }
@@ -22,9 +22,10 @@ export interface ReactMapViewProps {
22
22
  onClick?: () => void;
23
23
  displayMapPin?: boolean;
24
24
  mapPinLocation?: MapLocation;
25
- shouldAutoFetch?: boolean;
25
+ shouldAutoFetch?: number | boolean;
26
26
  showLayerInfo?: boolean;
27
27
  disableMapPin?: boolean;
28
+ holdShiftToScroll?: boolean;
28
29
  onWMJSMount?: (mapId: string) => void;
29
30
  onWMJSUnMount?: (mapId: string) => void;
30
31
  onMapChangeDimension?: (payload: SetMapDimensionPayload) => void;
@@ -2,6 +2,8 @@ export * from './Legend';
2
2
  export * from './MapDraw';
3
3
  export * from './MapDrawTool';
4
4
  export * from './ReactMapView';
5
+ export * from './ReactMapView/utils';
6
+ export * from './ReactMapView/ReactMapViewParseLayer';
5
7
  export * from './MapView';
6
8
  export * from './MapTime';
7
9
  export * from './MapControls';
@@ -1,2 +1,3 @@
1
1
  export * from './components';
2
2
  export * from './layers';
3
+ export { WEBMAP_REACT_NAMESPACE } from './utils/i18n';
@@ -0,0 +1,2 @@
1
+ export declare const WEBMAP_REACT_NAMESPACE = "webmapreact";
2
+ export declare const initWebmapReactTestI18n: () => void;