UNPKG

kepler.gl

Version:

kepler.gl is a webgl based application to visualize large scale location data in the browser

206 lines (197 loc) 32.1 kB
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); Object.defineProperty(exports, "__esModule", { value: true }); exports["default"] = void 0; exports.provideInitialState = provideInitialState; var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof")); var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray")); var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty")); var _actions = require("@kepler.gl/actions"); var _reduxActions = require("redux-actions"); var _core = require("./core"); 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) { (0, _defineProperty2["default"])(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; } // SPDX-License-Identifier: MIT // Copyright contributors to the kepler.gl project // Extend this type with additional actions to enforce strict typings // INITIAL_STATE var initialCoreState = {}; function provideInitialState(initialState, extraReducers) { var coreReducer = (0, _core.coreReducerFactory)(initialState, extraReducers); var handleRegisterEntry = function handleRegisterEntry(state, _ref) { var _ref$payload = _ref.payload, id = _ref$payload.id, mint = _ref$payload.mint, mapboxApiAccessToken = _ref$payload.mapboxApiAccessToken, mapboxApiUrl = _ref$payload.mapboxApiUrl, mapStylesReplaceDefault = _ref$payload.mapStylesReplaceDefault, initialUiState = _ref$payload.initialUiState; // by default, always create a mint state even if the same id already exist // if state.id exist and mint=false, keep the existing state var previousState = state[id] && mint === false ? state[id] : undefined; return _objectSpread(_objectSpread({}, state), {}, (0, _defineProperty2["default"])({}, id, coreReducer(previousState, (0, _actions.keplerGlInit)({ mapboxApiAccessToken: mapboxApiAccessToken, mapboxApiUrl: mapboxApiUrl, mapStylesReplaceDefault: mapStylesReplaceDefault, initialUiState: initialUiState })))); }; var handleDeleteEntry = function handleDeleteEntry(state, _ref2) { var id = _ref2.payload.id; return Object.keys(state).reduce(function (accu, curr) { return _objectSpread(_objectSpread({}, accu), curr === id ? {} : (0, _defineProperty2["default"])({}, curr, state[curr])); }, {}); }; var handleRenameEntry = function handleRenameEntry(state, _ref4) { var _ref4$payload = _ref4.payload, oldId = _ref4$payload.oldId, newId = _ref4$payload.newId; return Object.keys(state).reduce(function (accu, curr) { return _objectSpread(_objectSpread({}, accu), (0, _defineProperty2["default"])({}, curr === oldId ? newId : curr, state[curr])); }, {}); }; return function () { var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : initialCoreState; var action = arguments.length > 1 ? arguments[1] : undefined; // update child states Object.keys(state).forEach(function (id) { var updateItemState = coreReducer(state[id], (0, _actions._actionFor)(id, action)); state = (0, _actions._updateProperty)(state, id, updateItemState); }); // perform additional state reducing (e.g. switch action.type etc...) var handlers = (0, _defineProperty2["default"])((0, _defineProperty2["default"])((0, _defineProperty2["default"])({}, _actions.ActionTypes.REGISTER_ENTRY, handleRegisterEntry), _actions.ActionTypes.DELETE_ENTRY, handleDeleteEntry), _actions.ActionTypes.RENAME_ENTRY, handleRenameEntry); return (0, _reduxActions.handleActions)(handlers, initialCoreState)(state, action); }; } var _keplerGlReducer = provideInitialState(initialCoreState); function mergeInitialState() { var saved = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; var provided = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; var extraInitialStateKeys = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : []; var keys = ['mapState', 'mapStyle', 'visState', 'uiState'].concat((0, _toConsumableArray2["default"])(extraInitialStateKeys)); // shallow merge each reducer var newState = keys.reduce(function (accu, key) { return _objectSpread(_objectSpread({}, accu), saved[key] && provided[key] ? (0, _defineProperty2["default"])({}, key, _objectSpread(_objectSpread({}, saved[key]), provided[key])) : (0, _defineProperty2["default"])({}, key, saved[key] || provided[key] || {})); }, {}); return newState; } function decorate(target) { var savedInitialState = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; var targetInitialState = savedInitialState; /** * Returns a kepler.gl reducer that will also pass each action through additional reducers spiecified. * The parameter should be either a reducer map or a reducer function. * The state passed into the additional action handler is the instance state. * It will include all the subreducers `visState`, `uiState`, `mapState` and `mapStyle`. * `.plugin` is only meant to be called once when mounting the keplerGlReducer to the store. * **Note** This is an advanced option to give you more freedom to modify the internal state of the kepler.gl instance. * You should only use this to adding additional actions instead of replacing default actions. * * @mixin keplerGlReducer.plugin * @memberof keplerGlReducer * @param {Object|Function} customReducer - A reducer map or a reducer * @param {Object} options - options to be applied to custom reducer logic * @param {Object} options.override - objects that describe which action to override, e.g. {[ActionTypes.LAYER_TYPE_CHANGE]: true} * @public * @example * const myKeplerGlReducer = keplerGlReducer * .plugin({ * // 1. as reducer map * HIDE_AND_SHOW_SIDE_PANEL: (state, action) => ({ * ...state, * uiState: { * ...state.uiState, * readOnly: !state.uiState.readOnly * } * }) * }) * .plugin(handleActions({ * // 2. as reducer * 'HIDE_MAP_CONTROLS': (state, action) => ({ * ...state, * uiState: { * ...state.uiState, * mapControls: hiddenMapControl * } * }) * }, {})); */ target.plugin = function plugin(customReducer, options) { var _this = this; if ((0, _typeof2["default"])(customReducer) === 'object') { // if only provided a reducerMap, wrap it in a reducer customReducer = (0, _reduxActions.handleActions)(customReducer, {}); } // use 'function' keyword to enable 'this' return decorate(function () { var _options$override; var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; var action = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; var nextState = state; if (action.type && !(options !== null && options !== void 0 && (_options$override = options.override) !== null && _options$override !== void 0 && _options$override[action.type])) { nextState = _this(state, action); } // for each entry in the staten Object.keys(nextState).forEach(function (id) { // update child states nextState = (0, _actions._updateProperty)(nextState, id, customReducer(nextState[id], (0, _actions._actionFor)(id, action))); }); return nextState; }); }; /** * Return a reducer that initiated with custom initial state. * The parameter should be an object mapping from `subreducer` name to custom subreducer state, * which will be shallow **merged** with default initial state. * * Default subreducer state: * - [`visState`](./vis-state.md#INITIAL_VIS_STATE) * - [`mapState`](./map-state.md#INITIAL_MAP_STATE) * - [`mapStyle`](./map-style.md#INITIAL_MAP_STYLE) * - [`uiState`](./ui-state.md#INITIAL_UI_STATE) * @mixin keplerGlReducer.initialState * @memberof keplerGlReducer * @param {Object} iniSt - custom state to be merged with default initial state * @param {Object} extraReducers - optional custom reducers in addition to the default `visState`, `mapState`, `mapStyle`, and `uiState` * @public * @example * const myKeplerGlReducer = keplerGlReducer * .initialState({ * uiState: {readOnly: true} * }); */ target.initialState = function initialState(iniSt) { var extraReducers = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; // passing through extraInitialStateKeys and extraReducers allows external customization by adding additional subreducers and state beyond the default `visState`, `mapState`, `mapStyle`, and `uiState` var extraInitialStateKeys = Object.keys(extraReducers); var merged = mergeInitialState(targetInitialState, iniSt, extraInitialStateKeys); var targetReducer = provideInitialState(merged, extraReducers); return decorate(targetReducer, merged); }; return target; } /** * Kepler.gl reducer to be mounted to your store. You can mount `keplerGlReducer` at property `keplerGl`, if you choose * to mount it at another address e.g. `foo` you will need to specify it when you mount `KeplerGl` component in your app with `getState: state => state.foo` * @public * @example * import keplerGlReducer from 'kepler.gl/reducers'; * import {createStore, combineReducers, applyMiddleware, compose} from 'redux'; * import {taskMiddleware} from 'react-palm/tasks'; * * const initialState = {}; * const reducers = combineReducers({ * // <-- mount kepler.gl reducer in your app * keplerGl: keplerGlReducer, * * // Your other reducers here * app: appReducer * }); * * // using createStore * export default createStore(reducer, initialState, applyMiddleware(taskMiddleware)); */ var keplerGlReducer = decorate(_keplerGlReducer); var _default = exports["default"] = keplerGlReducer; //# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJuYW1lcyI6WyJfYWN0aW9ucyIsInJlcXVpcmUiLCJfcmVkdXhBY3Rpb25zIiwiX2NvcmUiLCJvd25LZXlzIiwiZSIsInIiLCJ0IiwiT2JqZWN0Iiwia2V5cyIsImdldE93blByb3BlcnR5U3ltYm9scyIsIm8iLCJmaWx0ZXIiLCJnZXRPd25Qcm9wZXJ0eURlc2NyaXB0b3IiLCJlbnVtZXJhYmxlIiwicHVzaCIsImFwcGx5IiwiX29iamVjdFNwcmVhZCIsImFyZ3VtZW50cyIsImxlbmd0aCIsImZvckVhY2giLCJfZGVmaW5lUHJvcGVydHkyIiwiZ2V0T3duUHJvcGVydHlEZXNjcmlwdG9ycyIsImRlZmluZVByb3BlcnRpZXMiLCJkZWZpbmVQcm9wZXJ0eSIsImluaXRpYWxDb3JlU3RhdGUiLCJwcm92aWRlSW5pdGlhbFN0YXRlIiwiaW5pdGlhbFN0YXRlIiwiZXh0cmFSZWR1Y2VycyIsImNvcmVSZWR1Y2VyIiwiY29yZVJlZHVjZXJGYWN0b3J5IiwiaGFuZGxlUmVnaXN0ZXJFbnRyeSIsInN0YXRlIiwiX3JlZiIsIl9yZWYkcGF5bG9hZCIsInBheWxvYWQiLCJpZCIsIm1pbnQiLCJtYXBib3hBcGlBY2Nlc3NUb2tlbiIsIm1hcGJveEFwaVVybCIsIm1hcFN0eWxlc1JlcGxhY2VEZWZhdWx0IiwiaW5pdGlhbFVpU3RhdGUiLCJwcmV2aW91c1N0YXRlIiwidW5kZWZpbmVkIiwia2VwbGVyR2xJbml0IiwiaGFuZGxlRGVsZXRlRW50cnkiLCJfcmVmMiIsInJlZHVjZSIsImFjY3UiLCJjdXJyIiwiaGFuZGxlUmVuYW1lRW50cnkiLCJfcmVmNCIsIl9yZWY0JHBheWxvYWQiLCJvbGRJZCIsIm5ld0lkIiwiYWN0aW9uIiwidXBk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