@opengeoweb/store 9.25.3 → 9.27.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/store",
3
- "version": "9.25.3",
3
+ "version": "9.27.0",
4
4
  "description": "GeoWeb Store library for the opengeoweb project",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -2,6 +2,7 @@ export * from './mapStore';
2
2
  export * from './ui';
3
3
  export * from './generic';
4
4
  export { genericListener } from './generic/listener';
5
+ export { mapListener } from './mapStore/map/listener';
5
6
  export * from './router';
6
7
  export * from './drawingtool';
7
8
  export * from './types';
@@ -11,4 +12,3 @@ export * as storeUtils from './utils';
11
12
  export * from './utils';
12
13
  export { uiModuleConfig } from './ui/config';
13
14
  export * from './testUtils/Providers';
14
- export { rootSaga as mapSaga } from './mapStore/map/sagas';
@@ -91,6 +91,6 @@ export declare const mapStoreActions: {
91
91
  export * from './service';
92
92
  export * from './map';
93
93
  export * from './layers';
94
- export type { WebMapStateModuleState, MapPreset } from './types';
94
+ export type { WebMapStateModuleState, MapPreset, MapPresetInitialProps, } from './types';
95
95
  export * as storeTestSettings from './storeTestSettings';
96
96
  export * from './config';
@@ -15,7 +15,7 @@ export declare enum LayerActionOrigin {
15
15
  ReactMapViewParseLayer = "ReactMapViewParseLayer",
16
16
  updateLayerInformationListener = "updateLayerInformationListener",
17
17
  toggleAutoUpdateListener = "toggleAutoUpdateListener",
18
- unregisterMapSaga = "unregisterMapSaga"
18
+ unregisterMapListener = "unregisterMapListener"
19
19
  }
20
20
  export interface FeatureLayer {
21
21
  geojson?: FeatureCollection;
@@ -13,6 +13,8 @@ export declare const mapUtils: {
13
13
  getTimeStepFromDataInterval: (timeInterval: import("dist/libs/webmap/src").TimeInterval) => number;
14
14
  getSpeedFactor: (speedDelay: number) => import("dist/libs/timeslider/src").SpeedFactorType;
15
15
  getAnimationDuration: (animationEndTime: string | undefined, animationStartTime: string | undefined) => number;
16
+ generateAnimationList: (unixAnimationStart: number, unixAnimationEnd: number, timeValues: string | undefined) => mapTypes.WebMapAnimationList;
17
+ parseTimeDimToISO8601Interval: (timeInterval: string | undefined) => mapTypes.ISO8601Interval[];
16
18
  };
17
19
  export { mapTypes };
18
20
  export { mapActions, reducer as webmapReducer } from './reducer';
@@ -1,3 +1,4 @@
1
1
  import { AnyAction, ThunkDispatch } from '@reduxjs/toolkit';
2
2
  import { WebMapStateModuleState } from '../types';
3
+ export declare const isAnimationEndTimeValid: (animationEndTime: string) => boolean;
3
4
  export declare const mapListener: import("@reduxjs/toolkit").ListenerMiddlewareInstance<WebMapStateModuleState, ThunkDispatch<WebMapStateModuleState, unknown, AnyAction>, unknown>;
@@ -710,7 +710,7 @@ export declare const getDockedLayerManagerSize: ((state: any, mapId: any) => imp
710
710
  * @param {string} mapId mapId: string - Id of the map
711
711
  * @returns {animationList} returnType: WebMapAnimationList, list of timesteps to animate for this map.
712
712
  */
713
- export declare const getAnimationList: ((state: any, mapId: any) => WebMapAnimationList) & import("reselect").OutputSelectorFields<(args_0: WebMap | undefined, args_1: string | undefined, args_2: string | undefined, args_3: number) => WebMapAnimationList, {
713
+ export declare const getAnimationList: ((state: any, mapId: any) => WebMapAnimationList) & import("reselect").OutputSelectorFields<(args_0: Record<string, ReduxLayer> | null, args_1: WebMap | undefined, args_2: string | undefined, args_3: string | undefined, args_4: number) => WebMapAnimationList, {
714
714
  clearCache: () => void;
715
715
  }> & {
716
716
  clearCache: () => void;
@@ -723,7 +723,7 @@ export declare const getAnimationList: ((state: any, mapId: any) => WebMapAnimat
723
723
  export declare const getAnimationRange: ((state: any, mapId: any) => {
724
724
  animationStartTime: string | undefined;
725
725
  animationEndTime: string | undefined;
726
- }) & import("reselect").OutputSelectorFields<(args_0: CoreAppStore, args_1: string | undefined, args_2: string | undefined, args_3: string | undefined, args_4: boolean, args_5: Dimension | undefined) => {
726
+ }) & import("reselect").OutputSelectorFields<(args_0: Record<string, ReduxLayer> | null, args_1: string | undefined, args_2: string | undefined, args_3: string | undefined, args_4: boolean) => {
727
727
  animationStartTime: string | undefined;
728
728
  animationEndTime: string | undefined;
729
729
  }, {
@@ -226,3 +226,8 @@ export interface SetDockedLayerManagerSize {
226
226
  mapId: string;
227
227
  dockedLayerManagerSize: DockedLayerManagerSize;
228
228
  }
229
+ export interface ISO8601Interval {
230
+ startTime: string;
231
+ endTime: string;
232
+ duration: string;
233
+ }
@@ -1,7 +1,7 @@
1
1
  import { TimeInterval } from '@opengeoweb/webmap';
2
2
  import { SpeedFactorType } from '@opengeoweb/timeslider';
3
3
  import { Bbox, Dimension } from './types';
4
- import type { WebMapState, WebMap } from '../types';
4
+ import type { WebMapState, WebMap, ISO8601Interval, WebMapAnimationList } from '../types';
5
5
  import type { Layer } from '../layers/types';
6
6
  export declare const dateFormat = "yyyy-MM-dd'T'HH:mm:ss'Z'";
7
7
  export interface CreateMapProps {
@@ -70,3 +70,16 @@ export declare function moveArrayElements<T>(array: T[], oldIndex: number, newIn
70
70
  export declare const getTimeStepFromDataInterval: (timeInterval: TimeInterval) => number;
71
71
  export declare const getSpeedFactor: (speedDelay: number) => SpeedFactorType;
72
72
  export declare const getAnimationDuration: (animationEndTime: string | undefined, animationStartTime: string | undefined) => number;
73
+ /**
74
+ * @param animationStart
75
+ * @param animationEnd
76
+ * @param iso8601Intervals
77
+ * @returns WebMapAnimationList with time points
78
+ */
79
+ export declare const generateAnimationList: (unixAnimationStart: number, unixAnimationEnd: number, timeValues: string | undefined) => WebMapAnimationList;
80
+ /**
81
+ * Parses the time dimension values string to an array of ISO8601 intervals
82
+ * @param timeInterval
83
+ * @returns An array of ISO8601 intervals
84
+ */
85
+ export declare const parseTimeDimToISO8601Interval: (timeInterval: string | undefined) => ISO8601Interval[];
@@ -0,0 +1,5 @@
1
+ import { AnyAction, ListenerEffectAPI, ThunkDispatch } from '@reduxjs/toolkit';
2
+ import { FetchInitialServicesPayload, SetLayersForServicePayload, WebMapStateModuleState } from '../types';
3
+ export declare const serviceListener: import("@reduxjs/toolkit").ListenerMiddlewareInstance<WebMapStateModuleState, ThunkDispatch<WebMapStateModuleState, unknown, AnyAction>, unknown>;
4
+ export declare const fetchService: (service: SetLayersForServicePayload, listenerApi: ListenerEffectAPI<WebMapStateModuleState, ThunkDispatch<WebMapStateModuleState, unknown, AnyAction>, unknown>) => Promise<void>;
5
+ export declare const fetchInitialServices: (payload: FetchInitialServicesPayload, listenerApi: ListenerEffectAPI<WebMapStateModuleState, ThunkDispatch<WebMapStateModuleState, unknown, AnyAction>, unknown>) => Promise<void>;
@@ -8,4 +8,4 @@ export declare const serviceActions: import("@reduxjs/toolkit").CaseReducerActio
8
8
  mapStoreRemoveService: (draft: Draft<ServiceState>, action: PayloadAction<MapStoreRemoveServicePayload>) => void;
9
9
  fetchInitialServices: (draft: Draft<ServiceState>, action: PayloadAction<FetchInitialServicesPayload>) => void;
10
10
  }, "serviceReducer">;
11
- export type ServiceActions = ReturnType<typeof serviceActions.mapStoreRemoveService> | ReturnType<typeof serviceActions.serviceSetLayers> | ReturnType<typeof layerActions.onUpdateLayerInformation>;
11
+ export type ServiceActions = ReturnType<typeof serviceActions.mapStoreRemoveService> | ReturnType<typeof serviceActions.serviceSetLayers> | ReturnType<typeof serviceActions.fetchInitialServices> | ReturnType<typeof layerActions.onUpdateLayerInformation>;
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { Store } from '@reduxjs/toolkit';
3
- export declare const createStore: () => Store;
3
+ export declare const createCustomStore: () => Store;
4
4
  /**
5
5
  * A Provider component which provides the GeoWeb theme and store for the core.
6
6
  * Note: Should only be used with core components, as the provided store is only for core.
@@ -1,12 +0,0 @@
1
- import { SagaIterator } from 'redux-saga';
2
- import { mapActions } from '.';
3
- import { Layer } from '../layers/types';
4
- export declare const getAnimationEndTime: (animationEndTime: string) => string;
5
- export declare const isAnimationEndTimeValid: (animationEndTime: string) => boolean;
6
- export declare function updateAnimation(mapId: string, maxValue: string): SagaIterator;
7
- export declare function handleBaseLayersSaga(mapId: string, baseLayers: Layer[]): SagaIterator;
8
- export declare function setMapPresetSaga({ payload, }: ReturnType<typeof mapActions.setMapPreset>): SagaIterator;
9
- export declare function unregisterMapSaga({ payload, }: ReturnType<typeof mapActions.unregisterMap>): Generator;
10
- export declare function setStepBackwardOrForwardSaga({ payload, }: ReturnType<typeof mapActions.setStepBackwardOrForward>): Generator;
11
- export declare function rootSaga(): SagaIterator;
12
- export default rootSaga;
@@ -1,7 +0,0 @@
1
- import { SagaIterator } from 'redux-saga';
2
- import { serviceActions } from './reducer';
3
- import { SetLayersForServicePayload } from './types';
4
- export declare function fetchServiceSaga(service: SetLayersForServicePayload): SagaIterator;
5
- export declare function fetchInitialServicesSaga({ payload, }: ReturnType<typeof serviceActions.fetchInitialServices>): SagaIterator;
6
- export declare function rootSaga(): SagaIterator;
7
- export default rootSaga;
@@ -1 +0,0 @@
1
- export {};