@kepler.gl/reducers 3.1.0-alpha.1 → 3.1.0-alpha.3

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.
Files changed (49) hide show
  1. package/dist/combined-updaters.d.ts +79 -0
  2. package/dist/combined-updaters.js +358 -0
  3. package/dist/composer-helpers.d.ts +24 -0
  4. package/dist/composer-helpers.js +101 -0
  5. package/dist/composers.d.ts +18 -0
  6. package/dist/composers.js +23 -0
  7. package/dist/core.d.ts +64 -0
  8. package/dist/core.js +105 -0
  9. package/dist/data-utils.d.ts +12 -0
  10. package/dist/data-utils.js +57 -0
  11. package/dist/export-utils.d.ts +21 -0
  12. package/dist/export-utils.js +91 -0
  13. package/dist/index.d.ts +35 -0
  14. package/dist/index.js +342 -0
  15. package/dist/interaction-utils.d.ts +29 -0
  16. package/dist/interaction-utils.js +105 -0
  17. package/dist/layer-utils.d.ts +96 -0
  18. package/dist/layer-utils.js +310 -0
  19. package/dist/map-state-updaters.d.ts +93 -0
  20. package/dist/map-state-updaters.js +432 -0
  21. package/dist/map-state.d.ts +75 -0
  22. package/dist/map-state.js +35 -0
  23. package/dist/map-style-updaters.d.ts +179 -0
  24. package/dist/map-style-updaters.js +656 -0
  25. package/dist/map-style.d.ts +4 -0
  26. package/dist/map-style.js +34 -0
  27. package/dist/merger-handler.d.ts +10 -0
  28. package/dist/merger-handler.js +105 -0
  29. package/dist/middleware.d.ts +8 -0
  30. package/dist/middleware.js +27 -0
  31. package/dist/provider-state-updaters.d.ts +35 -0
  32. package/dist/provider-state-updaters.js +348 -0
  33. package/dist/provider-state.d.ts +4 -0
  34. package/dist/provider-state.js +35 -0
  35. package/dist/root.d.ts +24 -0
  36. package/dist/root.js +206 -0
  37. package/dist/ui-state-updaters.d.ts +362 -0
  38. package/dist/ui-state-updaters.js +762 -0
  39. package/dist/ui-state.d.ts +3 -0
  40. package/dist/ui-state.js +37 -0
  41. package/dist/vis-state-merger.d.ts +143 -0
  42. package/dist/vis-state-merger.js +812 -0
  43. package/dist/vis-state-selectors.d.ts +10 -0
  44. package/dist/vis-state-selectors.js +30 -0
  45. package/dist/vis-state-updaters.d.ts +546 -0
  46. package/dist/vis-state-updaters.js +3338 -0
  47. package/dist/vis-state.d.ts +155 -0
  48. package/dist/vis-state.js +36 -0
  49. package/package.json +23 -17
@@ -0,0 +1,10 @@
1
+ export declare const getFileFormatNames: ((state: any) => any[]) & import("reselect").OutputSelectorFields<(args_0: any) => any[], {
2
+ clearCache: () => void;
3
+ }> & {
4
+ clearCache: () => void;
5
+ };
6
+ export declare const getFileExtensions: ((state: any) => any[]) & import("reselect").OutputSelectorFields<(args_0: any) => any[], {
7
+ clearCache: () => void;
8
+ }> & {
9
+ clearCache: () => void;
10
+ };
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.getFileFormatNames = exports.getFileExtensions = void 0;
8
+ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
9
+ var _reselect = require("reselect");
10
+ // SPDX-License-Identifier: MIT
11
+ // Copyright contributors to the kepler.gl project
12
+
13
+ // NOTE: default formats must match file-handler-test.js
14
+ var DEFAULT_FILE_EXTENSIONS = ['csv', 'json', 'geojson', 'arrow', 'parquet'];
15
+ var DEFAULT_FILE_FORMATS = ['CSV', 'Json', 'GeoJSON', 'Arrow', 'Parquet'];
16
+ var getFileFormatNames = exports.getFileFormatNames = (0, _reselect.createSelector)(function (state) {
17
+ return state.loaders;
18
+ }, function (loaders) {
19
+ return [].concat(DEFAULT_FILE_FORMATS, (0, _toConsumableArray2["default"])(loaders.map(function (loader) {
20
+ return loader.name;
21
+ })));
22
+ });
23
+ var getFileExtensions = exports.getFileExtensions = (0, _reselect.createSelector)(function (state) {
24
+ return state.loaders;
25
+ }, function (loaders) {
26
+ return [].concat(DEFAULT_FILE_EXTENSIONS, (0, _toConsumableArray2["default"])(loaders.flatMap(function (loader) {
27
+ return loader.extensions;
28
+ })));
29
+ });
30
+ //# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJuYW1lcyI6WyJfcmVzZWxlY3QiLCJyZXF1aXJlIiwiREVGQVVMVF9GSUxFX0VYVEVOU0lPTlMiLCJERUZBVUxUX0ZJTEVfRk9STUFUUyIsImdldEZpbGVGb3JtYXROYW1lcyIsImV4cG9ydHMiLCJjcmVhdGVTZWxlY3RvciIsInN0YXRlIiwibG9hZGVycyIsImNvbmNhdCIsIl90b0NvbnN1bWFibGVBcnJheTIiLCJtYXAiLCJsb2FkZXIiLCJuYW1lIiwiZ2V0RmlsZUV4dGVuc2lvbnMiLCJmbGF0TWFwIiwiZXh0ZW5zaW9ucyJdLCJzb3VyY2VzIjpbIi4uL3NyYy92aXMtc3RhdGUtc2VsZWN0b3JzLnRzIl0sInNvdXJjZXNDb250ZW50IjpbIi8vIFNQRFgtTGljZW5zZS1JZGVudGlmaWVyOiBNSVRcbi8vIENvcHlyaWdodCBjb250cmlidXRvcnMgdG8gdGhlIGtlcGxlci5nbCBwcm9qZWN0XG5cbmltcG9ydCB7Y3JlYXRlU2VsZWN0b3J9IGZyb20gJ3Jlc2VsZWN0JztcblxuLy8gTk9URTogZGVmYXVsdCBmb3JtYXRzIG11c3QgbWF0Y2ggZmlsZS1oYW5kbGVyLXRlc3QuanNcbmNvbnN0IERFRkFVTFRfRklMRV9FWFRFTlNJT05TID0gWydjc3YnLCAnanNvbicsICdnZW9qc29uJywgJ2Fycm93JywgJ3BhcnF1ZXQnXTtcbmNvbnN0IERFRkFVTFRfRklMRV9GT1JNQVRTID0gWydDU1YnLCAnSnNvbicsICdHZW9KU09OJywgJ0Fycm93JywgJ1BhcnF1ZXQnXTtcblxuZXhwb3J0IGNvbnN0IGdldEZpbGVGb3JtYXROYW1lcyA9IGNyZWF0ZVNlbGVjdG9yKFxuICBzdGF0ZSA9PiBzdGF0ZS5sb2FkZXJzLFxuICBsb2FkZXJzID0+IFsuLi5ERUZBVUxUX0ZJTEVfRk9STUFUUywgLi4ubG9hZGVycy5tYXAobG9hZGVyID0+IGxvYWRlci5uYW1lKV1cbik7XG5cbmV4cG9ydCBjb25zdCBnZXRGaWxlRXh0ZW5zaW9ucyA9IGNyZWF0ZVNlbGVjdG9yKFxuICBzdGF0ZSA9PiBzdGF0ZS5sb2FkZXJzLFxuICBsb2FkZXJzID0+IFsuLi5ERUZBVUxUX0ZJTEVfRVhURU5TSU9OUywgLi4ubG9hZGVycy5mbGF0TWFwKGxvYWRlciA9PiBsb2FkZXIuZXh0ZW5zaW9ucyldXG4pO1xuIl0sIm1hcHBpbmdzIjoiOzs7Ozs7OztBQUdBLElBQUFBLFNBQUEsR0FBQUMsT0FBQTtBQUhBO0FBQ0E7O0FBSUE7QUFDQSxJQUFNQyx1QkFBdUIsR0FBRyxDQUFDLEtBQUssRUFBRSxNQUFNLEVBQUUsU0FBUyxFQUFFLE9BQU8sRUFBRSxTQUFTLENBQUM7QUFDOUUsSUFBTUMsb0JBQW9CLEdBQUcsQ0FBQyxLQUFLLEVBQUUsTUFBTSxFQUFFLFNBQVMsRUFBRSxPQUFPLEVBQUUsU0FBUyxDQUFDO0FBRXBFLElBQU1DLGtCQUFrQixHQUFBQyxPQUFBLENBQUFELGtCQUFBLEdBQUcsSUFBQUUsd0JBQWMsRUFDOUMsVUFBQUMsS0FBSztFQUFBLE9BQUlBLEtBQUssQ0FBQ0MsT0FBTztBQUFBLEdBQ3RCLFVBQUFBLE9BQU87RUFBQSxVQUFBQyxNQUFBLENBQVFOLG9CQUFvQixNQUFBTyxtQkFBQSxhQUFLRixPQUFPLENBQUNHLEdBQUcsQ0FBQyxVQUFBQyxNQUFNO0lBQUEsT0FBSUEsTUFBTSxDQUFDQyxJQUFJO0VBQUEsRUFBQztBQUFBLENBQzVFLENBQUM7QUFFTSxJQUFNQyxpQkFBaUIsR0FBQVQsT0FBQSxDQUFBUyxpQkFBQSxHQUFHLElBQUFSLHdCQUFjLEVBQzdDLFVBQUFDLEtBQUs7RUFBQSxPQUFJQSxLQUFLLENBQUNDLE9BQU87QUFBQSxHQUN0QixVQUFBQSxPQUFPO0VBQUEsVUFBQUMsTUFBQSxDQUFRUCx1QkFBdUIsTUFBQVEsbUJBQUEsYUFBS0YsT0FBTyxDQUFDTyxPQUFPLENBQUMsVUFBQUgsTUFBTTtJQUFBLE9BQUlBLE1BQU0sQ0FBQ0ksVUFBVTtFQUFBLEVBQUM7QUFBQSxDQUN6RixDQUFDIiwiaWdub3JlTGlzdCI6W119
@@ -0,0 +1,546 @@
1
+ import { ActionTypes, CreateNewDatasetSuccessPayload, MapStateActions, ReceiveMapConfigPayload, VisStateActions } from '@kepler.gl/actions';
2
+ import { Layer } from '@kepler.gl/layers';
3
+ import { Merger, PostMergerPayload, VisState } from '@kepler.gl/schemas';
4
+ import { Filter, InteractionConfig, AnimationConfig, Editor } from '@kepler.gl/types';
5
+ import { Loader } from '@loaders.gl/loader-utils';
6
+ import { Datasets } from '@kepler.gl/table';
7
+ import { PayloadAction } from '@reduxjs/toolkit';
8
+ export declare const defaultInteractionConfig: InteractionConfig;
9
+ export declare const DEFAULT_ANIMATION_CONFIG: AnimationConfig;
10
+ export declare const DEFAULT_EDITOR: Editor;
11
+ /**
12
+ * Default initial `visState`
13
+ * @memberof visStateUpdaters
14
+ * @constant
15
+ * @public
16
+ */
17
+ export declare const INITIAL_VIS_STATE: VisState;
18
+ declare type UpdateStateWithLayerAndDataType = {
19
+ layers: Layer[];
20
+ layerData: any[];
21
+ };
22
+ /**
23
+ * Update state with updated layer and layerData
24
+ *
25
+ */
26
+ export declare function updateStateWithLayerAndData<S extends UpdateStateWithLayerAndDataType>(state: S, { layerData, layer, idx }: {
27
+ layerData?: any;
28
+ layer: Layer;
29
+ idx: number;
30
+ }): S;
31
+ export declare function updateStateOnLayerVisibilityChange<S extends VisState>(state: S, layer: Layer): S;
32
+ /**
33
+ * Apply layer config
34
+ * @memberof visStateUpdaters
35
+ * @returns nextState
36
+ */
37
+ export declare function applyLayerConfigUpdater(state: VisState, action: VisStateActions.ApplyLayerConfigUpdaterAction): VisState;
38
+ /**
39
+ * Update layer base config: dataId, label, column, isVisible
40
+ * @memberof visStateUpdaters
41
+ * @returns nextState
42
+ */
43
+ export declare function layerConfigChangeUpdater(state: VisState, action: VisStateActions.LayerConfigChangeUpdaterAction): VisState;
44
+ export declare function layerAnimationChangeUpdater<S extends VisState>(state: S, action: any): S;
45
+ /**
46
+ * Updates isValid flag of a layer.
47
+ * Updates isVisible based on the value of isValid.
48
+ * Triggers update of data for the layer in order to get errors again during next update iteration.
49
+ * @memberof visStateUpdaters
50
+ * @returns nextState
51
+ */
52
+ export declare function layerSetIsValidUpdater(state: VisState, action: VisStateActions.LayerSetIsValidUpdaterAction): VisState;
53
+ /**
54
+ * Update layer base config: dataId, label, column, isVisible
55
+ * @memberof visStateUpdaters
56
+ * @returns nextState
57
+ */
58
+ export declare function layerTextLabelChangeUpdater(state: VisState, action: VisStateActions.LayerTextLabelChangeUpdaterAction): VisState;
59
+ /**
60
+ * Update layer config dataId
61
+ * @memberof visStateUpdaters
62
+ * @returns nextState
63
+ */
64
+ export declare function layerDataIdChangeUpdater(state: VisState, action: {
65
+ oldLayer: Layer;
66
+ newConfig: {
67
+ dataId: string;
68
+ };
69
+ }): VisState;
70
+ export declare function setInitialLayerConfig(layer: any, datasets: any, layerClasses: any): Layer;
71
+ /**
72
+ * Update layer type. Previews layer config will be copied if applicable.
73
+ * @memberof visStateUpdaters
74
+ * @public
75
+ */
76
+ export declare function layerTypeChangeUpdater(state: VisState, action: VisStateActions.LayerTypeChangeUpdaterAction): VisState;
77
+ /**
78
+ * Update layer visual channel
79
+ * @memberof visStateUpdaters
80
+ * @returns {Object} nextState
81
+ * @public
82
+ */
83
+ export declare function layerVisualChannelChangeUpdater(state: VisState, action: VisStateActions.LayerVisualChannelConfigChangeUpdaterAction): VisState;
84
+ /**
85
+ * Update layer `visConfig`
86
+ * @memberof visStateUpdaters
87
+ * @public
88
+ */
89
+ export declare function layerVisConfigChangeUpdater(state: VisState, action: VisStateActions.LayerVisConfigChangeUpdaterAction): VisState;
90
+ /**
91
+ * Reset animation config current time to a specified value
92
+ * @memberof visStateUpdaters
93
+ * @public
94
+ *
95
+ */
96
+ export declare const setLayerAnimationTimeUpdater: <S extends VisState>(state: S, { value }: VisStateActions.SetLayerAnimationTimeUpdaterAction) => S;
97
+ /**
98
+ * Update filter property
99
+ * @memberof visStateUpdaters
100
+ * @public
101
+ */
102
+ export declare function setFilterAnimationTimeUpdater(state: VisState, action: VisStateActions.SetFilterAnimationTimeUpdaterAction): VisState;
103
+ /**
104
+ * Update filter animation window
105
+ * @memberof visStateUpdaters
106
+ * @public
107
+ */
108
+ export declare function setFilterAnimationWindowUpdater<S extends VisState>(state: S, { id, animationWindow }: VisStateActions.SetFilterAnimationWindowUpdaterAction): S;
109
+ /**
110
+ * Update filter property
111
+ * @memberof visStateUpdaters
112
+ * @public
113
+ */
114
+ export declare function setFilterUpdater<S extends VisState>(state: S, action: VisStateActions.SetFilterUpdaterAction): S;
115
+ /**
116
+ * Set the property of a filter plot
117
+ * @memberof visStateUpdaters
118
+ * @public
119
+ */
120
+ export declare const setFilterPlotUpdater: (state: VisState, { idx, newProp, valueIndex }: VisStateActions.SetFilterPlotUpdaterAction) => VisState;
121
+ /**
122
+ * Add a new filter
123
+ * @memberof visStateUpdaters
124
+ * @public
125
+ */
126
+ export declare const addFilterUpdater: (state: VisState, action: VisStateActions.AddFilterUpdaterAction) => VisState;
127
+ /**
128
+ * Create or update a filter
129
+ * @memberof visStateUpdaters
130
+ * @public
131
+ */
132
+ export declare const createOrUpdateFilterUpdater: (state: VisState, action: VisStateActions.CreateOrUpdateFilterUpdaterAction) => VisState;
133
+ /**
134
+ * Set layer color palette ui state
135
+ * @memberof visStateUpdaters
136
+ */
137
+ export declare const layerColorUIChangeUpdater: (state: VisState, { oldLayer, prop, newConfig }: VisStateActions.LayerColorUIChangeUpdaterAction) => VisState;
138
+ /**
139
+ * Start and end filter animation
140
+ * @memberof visStateUpdaters
141
+ * @public
142
+ */
143
+ export declare const toggleFilterAnimationUpdater: (state: VisState, action: VisStateActions.ToggleFilterAnimationUpdaterAction) => VisState;
144
+ /**
145
+ * @memberof visStateUpdaters
146
+ * @public
147
+ */
148
+ export declare const toggleLayerAnimationUpdater: (state: VisState, action: VisStateActions.ToggleLayerAnimationUpdaterAction) => VisState;
149
+ /**
150
+ * Hide and show layer animation control
151
+ * @memberof visStateUpdaters
152
+ * @public
153
+ */
154
+ export declare const toggleLayerAnimationControlUpdater: (state: VisState) => VisState;
155
+ /**
156
+ * Change filter animation speed
157
+ * @memberof visStateUpdaters
158
+ * @public
159
+ */
160
+ export declare const updateFilterAnimationSpeedUpdater: (state: VisState, action: VisStateActions.UpdateFilterAnimationSpeedUpdaterAction) => VisState;
161
+ /**
162
+ * Update animation speed with the vertical speed slider
163
+ * @memberof visStateUpdaters
164
+ * @public
165
+ *
166
+ */
167
+ export declare const updateLayerAnimationSpeedUpdater: (state: VisState, { speed }: VisStateActions.UpdateLayerAnimationSpeedUpdaterAction) => VisState;
168
+ /**
169
+ * Show larger time filter at bottom for time playback (apply to time filter only)
170
+ * @memberof visStateUpdaters
171
+ * @public
172
+ */
173
+ export declare const setFilterViewUpdater: (state: VisState, action: VisStateActions.SetFilterViewUpdaterAction) => {
174
+ filters: Filter[];
175
+ mapInfo: import("@kepler.gl/types").MapInfo;
176
+ layers: Layer[];
177
+ layerData: any[];
178
+ layerToBeMerged: any[];
179
+ layerOrder: string[];
180
+ effects: import("@kepler.gl/types").Effect[];
181
+ effectOrder: string[];
182
+ filterToBeMerged: any[];
183
+ datasets: Datasets;
184
+ editingDataset: string | undefined;
185
+ interactionConfig: InteractionConfig;
186
+ interactionToBeMerged: any;
187
+ layerBlending: string;
188
+ overlayBlending?: string | undefined;
189
+ hoverInfo: any;
190
+ clicked: any;
191
+ mousePos: any;
192
+ maxDefaultTooltips: number;
193
+ layerClasses: LayerClassesType;
194
+ animationConfig: AnimationConfig;
195
+ editor: Editor;
196
+ splitMaps: import("@kepler.gl/types").SplitMap[];
197
+ splitMapsToBeMerged: import("@kepler.gl/types").SplitMap[];
198
+ fileLoading: false | import("@kepler.gl/types").FileLoading;
199
+ fileLoadingProgress: import("@kepler.gl/types").FileLoadingProgress;
200
+ loaders: Loader<any, any, import("@loaders.gl/loader-utils").LoaderOptions>[];
201
+ loadOptions: object;
202
+ initialState?: Partial<VisState> | undefined;
203
+ mergers: import("@kepler.gl/schemas").VisStateMergers<any>;
204
+ schema: import("@kepler.gl/schemas").KeplerGLSchemaClass;
205
+ preserveLayerOrder?: string[] | undefined;
206
+ preserveFilterOrder?: string[] | undefined;
207
+ preserveDatasetOrder?: string[] | undefined;
208
+ isMergingDatasets: {
209
+ [datasetId: string]: boolean;
210
+ };
211
+ };
212
+ /**
213
+ * Toggles filter feature visibility
214
+ * @memberof visStateUpdaters
215
+ */
216
+ export declare const toggleFilterFeatureUpdater: (state: VisState, action: VisStateActions.ToggleFilterFeatureUpdaterAction) => VisState;
217
+ /**
218
+ * Remove a filter
219
+ * @memberof visStateUpdaters
220
+ * @public
221
+ */
222
+ export declare const removeFilterUpdater: (state: VisState, action: VisStateActions.RemoveFilterUpdaterAction) => VisState;
223
+ /**
224
+ * Add a new layer
225
+ * @memberof visStateUpdaters
226
+ * @public
227
+ */
228
+ export declare const addLayerUpdater: (state: VisState, action: VisStateActions.AddLayerUpdaterAction) => VisState;
229
+ /**
230
+ * remove layer
231
+ * @memberof visStateUpdaters
232
+ * @public
233
+ */
234
+ export declare function removeLayerUpdater<T extends VisState>(state: T, { id }: VisStateActions.RemoveLayerUpdaterAction): T;
235
+ /**
236
+ * Reorder layer
237
+ * @memberof visStateUpdaters
238
+ * @public
239
+ */
240
+ export declare const reorderLayerUpdater: (state: VisState, { order }: VisStateActions.ReorderLayerUpdaterAction) => VisState;
241
+ /**
242
+ * duplicate layer
243
+ * @memberof visStateUpdaters
244
+ * @public
245
+ */
246
+ export declare const duplicateLayerUpdater: (state: VisState, { id }: VisStateActions.DuplicateLayerUpdaterAction) => VisState;
247
+ /**
248
+ * Add a new effect
249
+ * @memberof visStateUpdaters
250
+ * @public
251
+ */
252
+ export declare const addEffectUpdater: (state: VisState, action: VisStateActions.AddEffectUpdaterAction) => VisState;
253
+ /**
254
+ * remove effect
255
+ * @memberof visStateUpdaters
256
+ * @public
257
+ */
258
+ export declare const removeEffectUpdater: (state: VisState, { id }: VisStateActions.RemoveEffectUpdaterAction) => VisState;
259
+ /**
260
+ * Reorder effect
261
+ * @memberof visStateUpdaters
262
+ * @public
263
+ */
264
+ export declare const reorderEffectUpdater: (state: VisState, { order }: VisStateActions.ReorderEffectUpdaterAction) => VisState;
265
+ /**
266
+ * Update effect
267
+ * @memberof visStateUpdaters
268
+ * @public
269
+ */
270
+ export declare const updateEffectUpdater: (state: VisState, { id, props }: VisStateActions.UpdateEffectUpdaterAction) => VisState;
271
+ /**
272
+ * Remove a dataset and all layers, filters, tooltip configs that based on it
273
+ * @memberof visStateUpdaters
274
+ * @public
275
+ */
276
+ export declare function removeDatasetUpdater<T extends VisState>(state: T, action: VisStateActions.RemoveDatasetUpdaterAction): T;
277
+ /**
278
+ * update layer blending mode
279
+ * @memberof visStateUpdaters
280
+ * @public
281
+ */
282
+ export declare const updateLayerBlendingUpdater: (state: VisState, action: VisStateActions.UpdateLayerBlendingUpdaterAction) => VisState;
283
+ /**
284
+ * update overlay blending mode
285
+ * @memberof visStateUpdaters
286
+ * @public
287
+ */
288
+ export declare const updateOverlayBlendingUpdater: (state: VisState, action: VisStateActions.UpdateOverlayBlendingUpdaterAction) => VisState;
289
+ /**
290
+ * Display dataset table in a modal
291
+ * @memberof visStateUpdaters
292
+ * @public
293
+ */
294
+ export declare const showDatasetTableUpdater: (state: VisState, action: VisStateActions.ShowDatasetTableUpdaterAction) => VisState;
295
+ /**
296
+ * Add custom color for datasets and layers
297
+ * @memberof visStateUpdaters
298
+ * @public
299
+ */
300
+ export declare const updateTableColorUpdater: (state: VisState, action: VisStateActions.UpdateDatasetColorUpdater) => VisState;
301
+ /**
302
+ * reset visState to initial State
303
+ * @memberof visStateUpdaters
304
+ * @public
305
+ */
306
+ export declare const resetMapConfigUpdater: (state: VisState) => VisState;
307
+ /**
308
+ * Propagate `visState` reducer with a new configuration. Current config will be override.
309
+ * @memberof visStateUpdaters
310
+ * @public
311
+ */
312
+ export declare const receiveMapConfigUpdater: (state: VisState, { payload: { config, options } }: {
313
+ type?: typeof ActionTypes.RECEIVE_MAP_CONFIG;
314
+ payload: ReceiveMapConfigPayload;
315
+ }) => VisState;
316
+ /**
317
+ * Trigger layer hover event with hovered object
318
+ * @memberof visStateUpdaters
319
+ * @public
320
+ */
321
+ export declare const layerHoverUpdater: (state: VisState, action: VisStateActions.OnLayerHoverUpdaterAction) => VisState;
322
+ /**
323
+ * Update `interactionConfig`
324
+ * @memberof visStateUpdaters
325
+ * @public
326
+ */
327
+ export declare function interactionConfigChangeUpdater(state: VisState, action: VisStateActions.InteractionConfigChangeUpdaterAction): VisState;
328
+ /**
329
+ * Trigger layer click event with clicked object
330
+ * @memberof visStateUpdaters
331
+ * @public
332
+ */
333
+ export declare const layerClickUpdater: (state: VisState, action: VisStateActions.OnLayerClickUpdaterAction) => VisState;
334
+ /**
335
+ * Trigger map click event, unselect clicked object
336
+ * @memberof visStateUpdaters
337
+ * @public
338
+ */
339
+ export declare const mapClickUpdater: (state: VisState, action: VisStateActions.OnMapClickUpdaterAction) => VisState;
340
+ /**
341
+ * Trigger map move event
342
+ * @memberof visStateUpdaters
343
+ * @public
344
+ */
345
+ export declare const mouseMoveUpdater: (state: VisState, { evt }: VisStateActions.OnMouseMoveUpdaterAction) => VisState;
346
+ /**
347
+ * Toggle visibility of a layer for a split map
348
+ * @memberof visStateUpdaters
349
+ * @public
350
+ */
351
+ export declare const toggleSplitMapUpdater: (state: VisState, action: MapStateActions.ToggleSplitMapUpdaterAction) => VisState;
352
+ /**
353
+ * Toggle visibility of a layer in a split map
354
+ * @memberof visStateUpdaters
355
+ * @public
356
+ */
357
+ export declare const toggleLayerForMapUpdater: (state: VisState, { mapIndex, layerId }: VisStateActions.ToggleLayerForMapUpdaterAction) => VisState;
358
+ /**
359
+ * Add new dataset to `visState`, with option to load a map config along with the datasets
360
+ * @memberof visStateUpdaters
361
+ * @public
362
+ */
363
+ export declare const updateVisDataUpdater: (state: VisState, action: VisStateActions.UpdateVisDataUpdaterAction) => VisState;
364
+ export declare const createNewDatasetSuccessUpdater: (state: VisState, action: PayloadAction<CreateNewDatasetSuccessPayload>) => VisState;
365
+ /**
366
+ * Add new dataset to `visState`, with option to load a map config along with the datasets
367
+ */
368
+ export declare function applyMergersUpdater(state: VisState, action: {
369
+ mergers: Merger<any>[];
370
+ postMergerPayload: PostMergerPayload;
371
+ }): VisState;
372
+ /**
373
+ * Rename an existing dataset in `visState`
374
+ * @memberof visStateUpdaters
375
+ * @public
376
+ */
377
+ export declare function renameDatasetUpdater(state: VisState, action: VisStateActions.RenameDatasetUpdaterAction): VisState;
378
+ /**
379
+ * Update Dataset props (label, color, meta). Do not use to update data or any related properties
380
+ * @memberof visStateUpdaters
381
+ * @public
382
+ */
383
+ export declare function updateDatasetPropsUpdater(state: VisState, action: VisStateActions.UpdateDatasetPropsUpdaterAction): VisState;
384
+ /**
385
+ * When a user clicks on the specific map closing icon
386
+ * the application will close the selected map
387
+ * and will merge the remaining one with the global state
388
+ * TODO: i think in the future this action should be called merge map layers with global settings
389
+ * @param {Object} state `visState`
390
+ * @param {Object} action action
391
+ * @returns {Object} nextState
392
+ */
393
+ export declare function closeSpecificMapAtIndex<S extends VisState>(state: S, action: MapStateActions.ToggleSplitMapUpdaterAction): S;
394
+ /**
395
+ * Trigger file loading dispatch `addDataToMap` if succeed, or `loadFilesErr` if failed
396
+ * @memberof visStateUpdaters
397
+ * @public
398
+ */
399
+ export declare const loadFilesUpdater: (state: VisState, action: VisStateActions.LoadFilesUpdaterAction) => VisState;
400
+ /**
401
+ * Sucessfully loaded one file, move on to the next one
402
+ * @memberof visStateUpdaters
403
+ * @public
404
+ */
405
+ export declare function loadFileStepSuccessUpdater(state: VisState, action: VisStateActions.LoadFileStepSuccessAction): VisState;
406
+ /**
407
+ *
408
+ * @memberof visStateUpdaters
409
+ * @public
410
+ */
411
+ export declare function loadNextFileUpdater(state: VisState): VisState;
412
+ export declare function makeLoadFileTask(file: any, fileCache: any, loaders?: Loader[], loadOptions?: {}): any;
413
+ /**
414
+ *
415
+ * @memberof visStateUpdaters
416
+ * @public
417
+ */
418
+ export declare function processFileContentUpdater(state: VisState, action: VisStateActions.ProcessFileContentUpdaterAction): VisState;
419
+ export declare function parseProgress(prevProgress: {} | undefined, progress: any): {
420
+ percent?: undefined;
421
+ } | {
422
+ percent: any;
423
+ };
424
+ /**
425
+ * gets called with payload = AsyncGenerator<???>
426
+ * @memberof visStateUpdaters
427
+ * @public
428
+ */
429
+ export declare const nextFileBatchUpdater: (state: VisState, { payload: { gen, fileName, progress, accumulated, onFinish } }: VisStateActions.NextFileBatchUpdaterAction) => VisState;
430
+ /**
431
+ * Trigger loading file error
432
+ * @memberof visStateUpdaters
433
+ * @public
434
+ */
435
+ export declare const loadFilesErrUpdater: (state: VisState, { error, fileName }: VisStateActions.LoadFilesErrUpdaterAction) => VisState;
436
+ /**
437
+ * When select dataset for export, apply cpu filter to selected dataset
438
+ * @memberof visStateUpdaters
439
+ * @public
440
+ */
441
+ export declare const applyCPUFilterUpdater: (state: VisState, { dataId }: VisStateActions.ApplyCPUFilterUpdaterAction) => VisState;
442
+ /**
443
+ * User input to update the info of the map
444
+ * @memberof visStateUpdaters
445
+ * @public
446
+ */
447
+ export declare const setMapInfoUpdater: (state: VisState, action: VisStateActions.SetMapInfoUpdaterAction) => VisState;
448
+ /**
449
+ * Helper function to update All layer domain and layer data of state
450
+ */
451
+ export declare function addDefaultLayers(state: VisState, datasets: Datasets): {
452
+ state: VisState;
453
+ newLayers: Layer[];
454
+ };
455
+ /**
456
+ * helper function to find default tooltips
457
+ * @param {Object} state
458
+ * @param {Object} dataset
459
+ * @returns {Object} nextState
460
+ */
461
+ export declare function addDefaultTooltips(state: any, dataset: any): any;
462
+ export declare function initialFileLoadingProgress(file: any, index: any): {
463
+ [x: number]: {
464
+ percent: number;
465
+ message: string;
466
+ fileName: any;
467
+ error: null;
468
+ };
469
+ };
470
+ export declare function updateFileLoadingProgressUpdater(state: any, { fileName, progress }: {
471
+ fileName: any;
472
+ progress: any;
473
+ }): any;
474
+ /**
475
+ * Helper function to update layer domains for an array of datasets
476
+ */
477
+ export declare function updateAllLayerDomainData<S extends VisState>(state: S, dataId: string | string[], updatedFilter?: Filter): S;
478
+ export declare function updateAnimationDomain<S extends VisState>(state: S): S;
479
+ /**
480
+ * Update the status of the editor
481
+ * @memberof visStateUpdaters
482
+ */
483
+ export declare const setEditorModeUpdater: (state: VisState, { mode }: VisStateActions.SetEditorModeUpdaterAction) => VisState;
484
+ /**
485
+ * Update editor features
486
+ * @memberof visStateUpdaters
487
+ */
488
+ export declare function setFeaturesUpdater(state: VisState, { features }: VisStateActions.SetFeaturesUpdaterAction): VisState;
489
+ /**
490
+ * Set the current selected feature
491
+ * @memberof uiStateUpdaters
492
+ */
493
+ export declare const setSelectedFeatureUpdater: (state: VisState, { feature, selectionContext }: VisStateActions.SetSelectedFeatureUpdaterAction) => VisState;
494
+ /**
495
+ * Delete existing feature from filters
496
+ * @memberof visStateUpdaters
497
+ */
498
+ export declare function deleteFeatureUpdater(state: VisState, { feature }: VisStateActions.DeleteFeatureUpdaterAction): VisState;
499
+ /**
500
+ * Toggle feature as layer filter
501
+ * @memberof visStateUpdaters
502
+ */
503
+ export declare function setPolygonFilterLayerUpdater(state: VisState, payload: VisStateActions.SetPolygonFilterLayerUpdaterAction): VisState;
504
+ /**
505
+ * @memberof visStateUpdaters
506
+ * @public
507
+ */
508
+ export declare function sortTableColumnUpdater(state: VisState, { dataId, column, mode }: VisStateActions.SortTableColumnUpdaterAction): VisState;
509
+ /**
510
+ * @memberof visStateUpdaters
511
+ * @public
512
+ */
513
+ export declare function pinTableColumnUpdater(state: VisState, { dataId, column }: VisStateActions.PinTableColumnUpdaterAction): VisState;
514
+ /**
515
+ * Copy column content as strings
516
+ * @memberof visStateUpdaters
517
+ * @public
518
+ */
519
+ export declare function copyTableColumnUpdater(state: VisState, { dataId, column }: VisStateActions.CopyTableColumnUpdaterAction): VisState;
520
+ /**
521
+ * Set display format from columns from user selection
522
+ * @memberof visStateUpdaters
523
+ * @public
524
+ */
525
+ export declare function setColumnDisplayFormatUpdater(state: VisState, { dataId, formats }: VisStateActions.SetColumnDisplayFormatUpdaterAction): VisState;
526
+ /**
527
+ * Update editor
528
+ */
529
+ export declare function toggleEditorVisibilityUpdater(state: VisState, action: VisStateActions.ToggleEditorVisibilityUpdaterAction): VisState;
530
+ export declare function setFilterAnimationTimeConfigUpdater(state: VisState, { idx, config }: VisStateActions.SetFilterAnimationTimeConfigAction): VisState;
531
+ /**
532
+ * Update editor
533
+ */
534
+ export declare function setLayerAnimationTimeConfigUpdater(state: VisState, { config }: VisStateActions.SetLayerAnimationTimeConfigAction): VisState;
535
+ /**
536
+ * Update editor
537
+ */
538
+ export declare function layerFilteredItemsChangeUpdater<S extends VisState>(state: S, action: VisStateActions.LayerFilteredItemsChangeAction): S;
539
+ export declare function syncTimeFilterWithLayerTimelineUpdater<S extends VisState>(state: S, action: VisStateActions.SyncTimeFilterWithLayerTimelineAction): S;
540
+ export declare function setTimeFilterTimelineModeUpdater<S extends VisState>(state: S, action: VisStateActions.setTimeFilterSyncTimelineModeAction): S;
541
+ export declare function prepareStateForDatasetReplace<T extends VisState>(state: T, dataId: string, dataIdToUse: string): T;
542
+ export declare function replaceDatasetDepsInState<T extends VisState>(state: T, { dataId, dataIdToUse }: {
543
+ dataId: string;
544
+ dataIdToUse: string;
545
+ }): T;
546
+ export {};