@carto/ps-react-maps 0.0.1-alpha.0 → 0.0.1-alpha.2
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/dist/index.cjs +9 -9
- package/dist/index.js +229 -215
- package/dist/types/index.d.ts +6 -0
- package/dist/types/map.const.d.ts +15 -0
- package/dist/types/map.context.d.ts +5 -0
- package/dist/types/map.hook.d.ts +2 -0
- package/dist/types/map.provider.d.ts +2 -0
- package/dist/types/map.reducer.d.ts +13 -0
- package/dist/types/map.types.d.ts +50 -0
- package/dist/types/tmp.utils.d.ts +1 -0
- package/package.json +7 -7
package/dist/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("react"),mr=require("react-redux");var
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("react"),mr=require("react-redux");var De=(a=>(a.Roadmap="roadmap",a.Satellite="satellite",a.Terrain="terrain",a))(De||{}),Ae=(a=>(a.DarkMatter="dark-matter",a.Positron="positron",a.Voyager="voyager",a))(Ae||{});const yr={positron:"https://basemaps.cartocdn.com/gl/positron-gl-style/style.json",voyager:"https://basemaps.cartocdn.com/gl/voyager-gl-style/style.json","dark-matter":"https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json"},q=()=>{throw new Error("You forgot to wrap your component in <MapProvider>.")},L={state:{maps:{}},actions:{setViewState:q,setBasemap:q,setResize:q,setZoom:q}},ne=h.createContext(L.state),ae=h.createContext(L.actions);var $=(a=>(a.SetViewState="SetViewState",a.SetBasemap="SetBasemap",a.SetResize="SetResize",a.SetZoom="SetZoom",a))($||{});function Fe(a,{type:b,payload:_}){return{SetViewState:()=>{const{id:u,viewState:m}=_,p={...a.maps};return p[u]={...a.maps[u],viewState:m},{...a,maps:p}},SetResize:()=>{const{id:u,width:m,height:p}=_,S={...a.maps};return S[u]={...a.maps[u],viewState:{...a.maps[u].viewState,width:m,height:p}},{...a,maps:S}},SetBasemap:()=>{const{id:u,basemap:m}=_,p={...a.maps};return p[u]={...a.maps[u],basemap:m},{...a,maps:p}},SetZoom:()=>{const{id:u,zoom:m}=_,p={...a.maps};return p[u]={...a.maps[u],viewState:{...a.maps[u].viewState,zoom:m}},{...a,maps:p}}}[b]?.()??a}function br(){return h.useContext(ne)}function gr(){return h.useContext(ae)}var te={exports:{}},V={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var xe;function Rr(){if(xe)return
|
|
9
|
+
*/var xe;function Rr(){if(xe)return V;xe=1;var a=h,b=Symbol.for("react.element"),_=Symbol.for("react.fragment"),C=Object.prototype.hasOwnProperty,u=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,m={key:!0,ref:!0,__self:!0,__source:!0};function p(S,y,O){var g,l={},f=null,x=null;O!==void 0&&(f=""+O),y.key!==void 0&&(f=""+y.key),y.ref!==void 0&&(x=y.ref);for(g in y)C.call(y,g)&&!m.hasOwnProperty(g)&&(l[g]=y[g]);if(S&&S.defaultProps)for(g in y=S.defaultProps,y)l[g]===void 0&&(l[g]=y[g]);return{$$typeof:b,type:S,key:f,ref:x,props:l,_owner:u.current}}return V.Fragment=_,V.jsx=p,V.jsxs=p,V}var W={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,14 +14,14 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
19
|
-
`),
|
|
20
|
-
`),d=o.length-1,v=
|
|
21
|
-
`+o[d].replace(" at new "," at ");return e.displayName&&
|
|
17
|
+
*/var je;function Er(){return je||(je=1,process.env.NODE_ENV!=="production"&&function(){var a=h,b=Symbol.for("react.element"),_=Symbol.for("react.portal"),C=Symbol.for("react.fragment"),u=Symbol.for("react.strict_mode"),m=Symbol.for("react.profiler"),p=Symbol.for("react.provider"),S=Symbol.for("react.context"),y=Symbol.for("react.forward_ref"),O=Symbol.for("react.suspense"),g=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),x=Symbol.for("react.offscreen"),F=Symbol.iterator,J="@@iterator";function Ie(e){if(e===null||typeof e!="object")return null;var r=F&&e[F]||e[J];return typeof r=="function"?r:null}var k=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function R(e){{for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];Me("error",e,t)}}function Me(e,r,t){{var n=k.ReactDebugCurrentFrame,s=n.getStackAddendum();s!==""&&(r+="%s",t=t.concat([s]));var c=t.map(function(i){return String(i)});c.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,c)}}var Ve=!1,We=!1,$e=!1,Le=!1,Ye=!1,oe;oe=Symbol.for("react.module.reference");function Ne(e){return!!(typeof e=="string"||typeof e=="function"||e===C||e===m||Ye||e===u||e===O||e===g||Le||e===x||Ve||We||$e||typeof e=="object"&&e!==null&&(e.$$typeof===f||e.$$typeof===l||e.$$typeof===p||e.$$typeof===S||e.$$typeof===y||e.$$typeof===oe||e.getModuleId!==void 0))}function Ue(e,r,t){var n=e.displayName;if(n)return n;var s=r.displayName||r.name||"";return s!==""?t+"("+s+")":t}function ie(e){return e.displayName||"Context"}function w(e){if(e==null)return null;if(typeof e.tag=="number"&&R("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case C:return"Fragment";case _:return"Portal";case m:return"Profiler";case u:return"StrictMode";case O:return"Suspense";case g:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case S:var r=e;return ie(r)+".Consumer";case p:var t=e;return ie(t._context)+".Provider";case y:return Ue(e,e.render,"ForwardRef");case l:var n=e.displayName||null;return n!==null?n:w(e.type)||"Memo";case f:{var s=e,c=s._payload,i=s._init;try{return w(i(c))}catch{return null}}}return null}var j=Object.assign,I=0,se,ue,ce,le,fe,de,ve;function pe(){}pe.__reactDisabledLog=!0;function Be(){{if(I===0){se=console.log,ue=console.info,ce=console.warn,le=console.error,fe=console.group,de=console.groupCollapsed,ve=console.groupEnd;var e={configurable:!0,enumerable:!0,value:pe,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}I++}}function ze(){{if(I--,I===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:j({},e,{value:se}),info:j({},e,{value:ue}),warn:j({},e,{value:ce}),error:j({},e,{value:le}),group:j({},e,{value:fe}),groupCollapsed:j({},e,{value:de}),groupEnd:j({},e,{value:ve})})}I<0&&R("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Z=k.ReactCurrentDispatcher,G;function Y(e,r,t){{if(G===void 0)try{throw Error()}catch(s){var n=s.stack.trim().match(/\n( *(at )?)/);G=n&&n[1]||""}return`
|
|
18
|
+
`+G+e}}var K=!1,N;{var qe=typeof WeakMap=="function"?WeakMap:Map;N=new qe}function me(e,r){if(!e||K)return"";{var t=N.get(e);if(t!==void 0)return t}var n;K=!0;var s=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var c;c=Z.current,Z.current=null,Be();try{if(r){var i=function(){throw Error()};if(Object.defineProperty(i.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(i,[])}catch(P){n=P}Reflect.construct(e,[],i)}else{try{i.call()}catch(P){n=P}e.call(i.prototype)}}else{try{throw Error()}catch(P){n=P}e()}}catch(P){if(P&&n&&typeof P.stack=="string"){for(var o=P.stack.split(`
|
|
19
|
+
`),E=n.stack.split(`
|
|
20
|
+
`),d=o.length-1,v=E.length-1;d>=1&&v>=0&&o[d]!==E[v];)v--;for(;d>=1&&v>=0;d--,v--)if(o[d]!==E[v]){if(d!==1||v!==1)do if(d--,v--,v<0||o[d]!==E[v]){var T=`
|
|
21
|
+
`+o[d].replace(" at new "," at ");return e.displayName&&T.includes("<anonymous>")&&(T=T.replace("<anonymous>",e.displayName)),typeof e=="function"&&N.set(e,T),T}while(d>=1&&v>=0);break}}}finally{K=!1,Z.current=c,ze(),Error.prepareStackTrace=s}var A=e?e.displayName||e.name:"",Oe=A?Y(A):"";return typeof e=="function"&&N.set(e,Oe),Oe}function Je(e,r,t){return me(e,!1)}function Ze(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function U(e,r,t){if(e==null)return"";if(typeof e=="function")return me(e,Ze(e));if(typeof e=="string")return Y(e);switch(e){case O:return Y("Suspense");case g:return Y("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case y:return Je(e.render);case l:return U(e.type,r,t);case f:{var n=e,s=n._payload,c=n._init;try{return U(c(s),r,t)}catch{}}}return""}var B=Object.prototype.hasOwnProperty,ye={},be=k.ReactDebugCurrentFrame;function z(e){if(e){var r=e._owner,t=U(e.type,e._source,r?r.type:null);be.setExtraStackFrame(t)}else be.setExtraStackFrame(null)}function Ge(e,r,t,n,s){{var c=Function.call.bind(B);for(var i in e)if(c(e,i)){var o=void 0;try{if(typeof e[i]!="function"){var E=Error((n||"React class")+": "+t+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw E.name="Invariant Violation",E}o=e[i](r,i,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(d){o=d}o&&!(o instanceof Error)&&(z(s),R("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",n||"React class",t,i,typeof o),z(null)),o instanceof Error&&!(o.message in ye)&&(ye[o.message]=!0,z(s),R("Failed %s type: %s",t,o.message),z(null))}}}var Ke=Array.isArray;function H(e){return Ke(e)}function He(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,t=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return t}}function Xe(e){try{return ge(e),!1}catch{return!0}}function ge(e){return""+e}function Re(e){if(Xe(e))return R("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",He(e)),ge(e)}var M=k.ReactCurrentOwner,Qe={key:!0,ref:!0,__self:!0,__source:!0},Ee,he,X;X={};function er(e){if(B.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function rr(e){if(B.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function tr(e,r){if(typeof e.ref=="string"&&M.current&&r&&M.current.stateNode!==r){var t=w(M.current.type);X[t]||(R('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',w(M.current.type),e.ref),X[t]=!0)}}function nr(e,r){{var t=function(){Ee||(Ee=!0,R("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"key",{get:t,configurable:!0})}}function ar(e,r){{var t=function(){he||(he=!0,R("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"ref",{get:t,configurable:!0})}}var or=function(e,r,t,n,s,c,i){var o={$$typeof:b,type:e,key:r,ref:t,props:i,_owner:c};return o._store={},Object.defineProperty(o._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(o,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(o,"_source",{configurable:!1,enumerable:!1,writable:!1,value:s}),Object.freeze&&(Object.freeze(o.props),Object.freeze(o)),o};function ir(e,r,t,n,s){{var c,i={},o=null,E=null;t!==void 0&&(Re(t),o=""+t),rr(r)&&(Re(r.key),o=""+r.key),er(r)&&(E=r.ref,tr(r,s));for(c in r)B.call(r,c)&&!Qe.hasOwnProperty(c)&&(i[c]=r[c]);if(e&&e.defaultProps){var d=e.defaultProps;for(c in d)i[c]===void 0&&(i[c]=d[c])}if(o||E){var v=typeof e=="function"?e.displayName||e.name||"Unknown":e;o&&nr(i,v),E&&ar(i,v)}return or(e,o,E,s,n,M.current,i)}}var Q=k.ReactCurrentOwner,_e=k.ReactDebugCurrentFrame;function D(e){if(e){var r=e._owner,t=U(e.type,e._source,r?r.type:null);_e.setExtraStackFrame(t)}else _e.setExtraStackFrame(null)}var ee;ee=!1;function re(e){return typeof e=="object"&&e!==null&&e.$$typeof===b}function Se(){{if(Q.current){var e=w(Q.current.type);if(e)return`
|
|
22
22
|
|
|
23
23
|
Check the render method of \``+e+"`."}return""}}function sr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),t=e.lineNumber;return`
|
|
24
24
|
|
|
25
|
-
Check your code at `+r+":"+t+"."}return""}}var
|
|
25
|
+
Check your code at `+r+":"+t+"."}return""}}var Te={};function ur(e){{var r=Se();if(!r){var t=typeof e=="string"?e:e.displayName||e.name;t&&(r=`
|
|
26
26
|
|
|
27
|
-
Check the top-level render call using <`+t+">.")}return r}}function
|
|
27
|
+
Check the top-level render call using <`+t+">.")}return r}}function Ce(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var t=ur(r);if(Te[t])return;Te[t]=!0;var n="";e&&e._owner&&e._owner!==Q.current&&(n=" It was passed a child from "+w(e._owner.type)+"."),D(e),R('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',t,n),D(null)}}function we(e,r){{if(typeof e!="object")return;if(H(e))for(var t=0;t<e.length;t++){var n=e[t];re(n)&&Ce(n,r)}else if(re(e))e._store&&(e._store.validated=!0);else if(e){var s=Ie(e);if(typeof s=="function"&&s!==e.entries)for(var c=s.call(e),i;!(i=c.next()).done;)re(i.value)&&Ce(i.value,r)}}}function cr(e){{var r=e.type;if(r==null||typeof r=="string")return;var t;if(typeof r=="function")t=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===y||r.$$typeof===l))t=r.propTypes;else return;if(t){var n=w(r);Ge(t,e.props,"prop",n,e)}else if(r.PropTypes!==void 0&&!ee){ee=!0;var s=w(r);R("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",s||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&R("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function lr(e){{for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if(n!=="children"&&n!=="key"){D(e),R("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),D(null);break}}e.ref!==null&&(D(e),R("Invalid attribute `ref` supplied to `React.Fragment`."),D(null))}}function Pe(e,r,t,n,s,c){{var i=Ne(e);if(!i){var o="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(o+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var E=sr(s);E?o+=E:o+=Se();var d;e===null?d="null":H(e)?d="array":e!==void 0&&e.$$typeof===b?(d="<"+(w(e.type)||"Unknown")+" />",o=" Did you accidentally export a JSX literal instead of a component?"):d=typeof e,R("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",d,o)}var v=ir(e,r,t,s,c);if(v==null)return v;if(i){var T=r.children;if(T!==void 0)if(n)if(H(T)){for(var A=0;A<T.length;A++)we(T[A],e);Object.freeze&&Object.freeze(T)}else R("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else we(T,e)}return e===C?lr(v):cr(v),v}}function fr(e,r,t){return Pe(e,r,t,!0)}function dr(e,r,t){return Pe(e,r,t,!1)}var vr=dr,pr=fr;W.Fragment=C,W.jsx=vr,W.jsxs=pr}()),W}process.env.NODE_ENV==="production"?te.exports=Rr():te.exports=Er();var ke=te.exports;const hr=(a,b)=>(...u)=>{clearTimeout(0),setTimeout(()=>a(...u),b)},_r=["transitionDuration","transitionEasing","transitionInterpolator","transitionInterruption"],Sr=(a,b)=>{a({type:"carto/setViewState",payload:b}),a({type:"carto/setViewPort"})},Tr=hr(Sr,500);function Cr({children:a,maps:b}){const _=mr.useDispatch(),[C,u]=h.useReducer(Fe,{...L.state,maps:b.reduce((l,f)=>(l[f.id]=f,l),L.state.maps)}),m=h.useCallback((l,f)=>{if(b[0].id===l){const F={...f};for(const J of _r)delete F[J];Tr(_,F)}},[_,b]),p=h.useCallback((l,f)=>{u({type:$.SetViewState,payload:{id:l,viewState:f}}),m(l,f)},[u,m]),S=h.useCallback((l,{height:f,width:x})=>{u({type:$.SetResize,payload:{id:l,height:f,width:x}}),m(l,{height:f,width:x})},[u,m]),y=h.useCallback((l,f)=>{u({type:$.SetBasemap,payload:{id:l,basemap:f}})},[u]),O=h.useCallback((l,f)=>{u({type:$.SetZoom,payload:{id:l,zoom:f}})},[u]),g=h.useRef({setViewState:p,setBasemap:y,setResize:S,setZoom:O});return ke.jsx(ae.Provider,{value:g.current,children:ke.jsx(ne.Provider,{value:C,children:a})})}exports.CartoBasemapURL=yr;exports.CartoBasemapsNames=Ae;exports.GMapsBasemap=De;exports.INITIAL_STATE=L;exports.MapActionsContext=ae;exports.MapContext=ne;exports.MapProvider=Cr;exports.reducer=Fe;exports.useMap=br;exports.useMapActions=gr;
|
package/dist/index.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import
|
|
1
|
+
import je, { createContext as ke, useContext as De, useReducer as mr, useCallback as V, useRef as yr } from "react";
|
|
2
2
|
import { useDispatch as gr } from "react-redux";
|
|
3
3
|
var Rr = /* @__PURE__ */ ((a) => (a.Roadmap = "roadmap", a.Satellite = "satellite", a.Terrain = "terrain", a))(Rr || {}), br = /* @__PURE__ */ ((a) => (a.DarkMatter = "dark-matter", a.Positron = "positron", a.Voyager = "voyager", a))(br || {});
|
|
4
|
-
const
|
|
4
|
+
const xr = {
|
|
5
5
|
positron: "https://basemaps.cartocdn.com/gl/positron-gl-style/style.json",
|
|
6
6
|
voyager: "https://basemaps.cartocdn.com/gl/voyager-gl-style/style.json",
|
|
7
7
|
"dark-matter": "https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json"
|
|
8
|
-
},
|
|
8
|
+
}, B = () => {
|
|
9
9
|
throw new Error("You forgot to wrap your component in <MapProvider>.");
|
|
10
|
-
},
|
|
10
|
+
}, q = {
|
|
11
11
|
state: {
|
|
12
12
|
maps: {}
|
|
13
13
|
// sync: false,
|
|
14
14
|
},
|
|
15
15
|
actions: {
|
|
16
16
|
// toggleSync: stub,
|
|
17
|
-
setViewState:
|
|
18
|
-
setBasemap:
|
|
19
|
-
setResize:
|
|
20
|
-
setZoom:
|
|
17
|
+
setViewState: B,
|
|
18
|
+
setBasemap: B,
|
|
19
|
+
setResize: B,
|
|
20
|
+
setZoom: B
|
|
21
21
|
}
|
|
22
|
-
},
|
|
23
|
-
|
|
24
|
-
),
|
|
25
|
-
|
|
22
|
+
}, Fe = ke(
|
|
23
|
+
q.state
|
|
24
|
+
), Ae = ke(
|
|
25
|
+
q.actions
|
|
26
26
|
);
|
|
27
|
-
var
|
|
28
|
-
function hr(a, { type:
|
|
27
|
+
var Y = /* @__PURE__ */ ((a) => (a.SetViewState = "SetViewState", a.SetBasemap = "SetBasemap", a.SetResize = "SetResize", a.SetZoom = "SetZoom", a))(Y || {});
|
|
28
|
+
function hr(a, { type: g, payload: E }) {
|
|
29
29
|
return {
|
|
30
30
|
SetViewState: () => {
|
|
31
|
-
const { id: u, viewState: m } =
|
|
31
|
+
const { id: u, viewState: m } = E, p = { ...a.maps };
|
|
32
32
|
return p[u] = {
|
|
33
33
|
...a.maps[u],
|
|
34
34
|
viewState: m
|
|
@@ -38,8 +38,8 @@ function hr(a, { type: _, payload: S }) {
|
|
|
38
38
|
};
|
|
39
39
|
},
|
|
40
40
|
SetResize: () => {
|
|
41
|
-
const { id: u, width: m, height: p } =
|
|
42
|
-
return
|
|
41
|
+
const { id: u, width: m, height: p } = E, _ = { ...a.maps };
|
|
42
|
+
return _[u] = {
|
|
43
43
|
...a.maps[u],
|
|
44
44
|
viewState: {
|
|
45
45
|
...a.maps[u].viewState,
|
|
@@ -48,11 +48,11 @@ function hr(a, { type: _, payload: S }) {
|
|
|
48
48
|
}
|
|
49
49
|
}, {
|
|
50
50
|
...a,
|
|
51
|
-
maps:
|
|
51
|
+
maps: _
|
|
52
52
|
};
|
|
53
53
|
},
|
|
54
54
|
SetBasemap: () => {
|
|
55
|
-
const { id: u, basemap: m } =
|
|
55
|
+
const { id: u, basemap: m } = E, p = { ...a.maps };
|
|
56
56
|
return p[u] = {
|
|
57
57
|
...a.maps[u],
|
|
58
58
|
basemap: m
|
|
@@ -62,7 +62,7 @@ function hr(a, { type: _, payload: S }) {
|
|
|
62
62
|
};
|
|
63
63
|
},
|
|
64
64
|
SetZoom: () => {
|
|
65
|
-
const { id: u, zoom: m } =
|
|
65
|
+
const { id: u, zoom: m } = E, p = { ...a.maps };
|
|
66
66
|
return p[u] = {
|
|
67
67
|
...a.maps[u],
|
|
68
68
|
viewState: {
|
|
@@ -74,15 +74,15 @@ function hr(a, { type: _, payload: S }) {
|
|
|
74
74
|
maps: p
|
|
75
75
|
};
|
|
76
76
|
}
|
|
77
|
-
}[
|
|
77
|
+
}[g]?.() ?? a;
|
|
78
78
|
}
|
|
79
|
-
function
|
|
80
|
-
return
|
|
79
|
+
function jr() {
|
|
80
|
+
return De(Fe);
|
|
81
81
|
}
|
|
82
|
-
function
|
|
83
|
-
return
|
|
82
|
+
function kr() {
|
|
83
|
+
return De(Ae);
|
|
84
84
|
}
|
|
85
|
-
var
|
|
85
|
+
var te = { exports: {} }, W = {};
|
|
86
86
|
/**
|
|
87
87
|
* @license React
|
|
88
88
|
* react-jsx-runtime.production.min.js
|
|
@@ -92,23 +92,23 @@ var ee = { exports: {} }, V = {};
|
|
|
92
92
|
* This source code is licensed under the MIT license found in the
|
|
93
93
|
* LICENSE file in the root directory of this source tree.
|
|
94
94
|
*/
|
|
95
|
-
var
|
|
95
|
+
var Pe;
|
|
96
96
|
function Er() {
|
|
97
|
-
if (
|
|
98
|
-
return
|
|
99
|
-
|
|
100
|
-
var a =
|
|
101
|
-
function p(
|
|
102
|
-
var
|
|
97
|
+
if (Pe)
|
|
98
|
+
return W;
|
|
99
|
+
Pe = 1;
|
|
100
|
+
var a = je, g = Symbol.for("react.element"), E = Symbol.for("react.fragment"), T = Object.prototype.hasOwnProperty, u = a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, m = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
101
|
+
function p(_, y, P) {
|
|
102
|
+
var R, l = {}, f = null, O = null;
|
|
103
103
|
P !== void 0 && (f = "" + P), y.key !== void 0 && (f = "" + y.key), y.ref !== void 0 && (O = y.ref);
|
|
104
|
-
for (
|
|
105
|
-
|
|
106
|
-
if (
|
|
107
|
-
for (
|
|
108
|
-
l[
|
|
109
|
-
return { $$typeof:
|
|
104
|
+
for (R in y)
|
|
105
|
+
T.call(y, R) && !m.hasOwnProperty(R) && (l[R] = y[R]);
|
|
106
|
+
if (_ && _.defaultProps)
|
|
107
|
+
for (R in y = _.defaultProps, y)
|
|
108
|
+
l[R] === void 0 && (l[R] = y[R]);
|
|
109
|
+
return { $$typeof: g, type: _, key: f, ref: O, props: l, _owner: u.current };
|
|
110
110
|
}
|
|
111
|
-
return
|
|
111
|
+
return W.Fragment = E, W.jsx = p, W.jsxs = p, W;
|
|
112
112
|
}
|
|
113
113
|
var $ = {};
|
|
114
114
|
/**
|
|
@@ -120,18 +120,18 @@ var $ = {};
|
|
|
120
120
|
* This source code is licensed under the MIT license found in the
|
|
121
121
|
* LICENSE file in the root directory of this source tree.
|
|
122
122
|
*/
|
|
123
|
-
var
|
|
123
|
+
var Oe;
|
|
124
124
|
function _r() {
|
|
125
|
-
return
|
|
126
|
-
var a =
|
|
125
|
+
return Oe || (Oe = 1, process.env.NODE_ENV !== "production" && function() {
|
|
126
|
+
var a = je, g = Symbol.for("react.element"), E = Symbol.for("react.portal"), T = Symbol.for("react.fragment"), u = Symbol.for("react.strict_mode"), m = Symbol.for("react.profiler"), p = Symbol.for("react.provider"), _ = Symbol.for("react.context"), y = Symbol.for("react.forward_ref"), P = Symbol.for("react.suspense"), R = Symbol.for("react.suspense_list"), l = Symbol.for("react.memo"), f = Symbol.for("react.lazy"), O = Symbol.for("react.offscreen"), F = Symbol.iterator, J = "@@iterator";
|
|
127
127
|
function Ie(e) {
|
|
128
128
|
if (e === null || typeof e != "object")
|
|
129
129
|
return null;
|
|
130
|
-
var r =
|
|
130
|
+
var r = F && e[F] || e[J];
|
|
131
131
|
return typeof r == "function" ? r : null;
|
|
132
132
|
}
|
|
133
133
|
var j = a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
134
|
-
function
|
|
134
|
+
function b(e) {
|
|
135
135
|
{
|
|
136
136
|
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), n = 1; n < r; n++)
|
|
137
137
|
t[n - 1] = arguments[n];
|
|
@@ -148,14 +148,14 @@ function _r() {
|
|
|
148
148
|
c.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, c);
|
|
149
149
|
}
|
|
150
150
|
}
|
|
151
|
-
var
|
|
152
|
-
|
|
151
|
+
var We = !1, $e = !1, Ye = !1, Me = !1, Le = !1, ne;
|
|
152
|
+
ne = Symbol.for("react.module.reference");
|
|
153
153
|
function Ne(e) {
|
|
154
|
-
return !!(typeof e == "string" || typeof e == "function" || e ===
|
|
154
|
+
return !!(typeof e == "string" || typeof e == "function" || e === T || e === m || Le || e === u || e === P || e === R || Me || e === O || We || $e || Ye || typeof e == "object" && e !== null && (e.$$typeof === f || e.$$typeof === l || e.$$typeof === p || e.$$typeof === _ || e.$$typeof === y || // This needs to include all possible module reference object
|
|
155
155
|
// types supported by any Flight configuration anywhere since
|
|
156
156
|
// we don't know which Flight build this will end up being used
|
|
157
157
|
// with.
|
|
158
|
-
e.$$typeof ===
|
|
158
|
+
e.$$typeof === ne || e.getModuleId !== void 0));
|
|
159
159
|
}
|
|
160
160
|
function Ue(e, r, t) {
|
|
161
161
|
var n = e.displayName;
|
|
@@ -164,20 +164,20 @@ function _r() {
|
|
|
164
164
|
var s = r.displayName || r.name || "";
|
|
165
165
|
return s !== "" ? t + "(" + s + ")" : t;
|
|
166
166
|
}
|
|
167
|
-
function
|
|
167
|
+
function ae(e) {
|
|
168
168
|
return e.displayName || "Context";
|
|
169
169
|
}
|
|
170
|
-
function
|
|
170
|
+
function w(e) {
|
|
171
171
|
if (e == null)
|
|
172
172
|
return null;
|
|
173
|
-
if (typeof e.tag == "number" &&
|
|
173
|
+
if (typeof e.tag == "number" && b("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
|
|
174
174
|
return e.displayName || e.name || null;
|
|
175
175
|
if (typeof e == "string")
|
|
176
176
|
return e;
|
|
177
177
|
switch (e) {
|
|
178
|
-
case
|
|
178
|
+
case T:
|
|
179
179
|
return "Fragment";
|
|
180
|
-
case
|
|
180
|
+
case E:
|
|
181
181
|
return "Portal";
|
|
182
182
|
case m:
|
|
183
183
|
return "Profiler";
|
|
@@ -185,26 +185,26 @@ function _r() {
|
|
|
185
185
|
return "StrictMode";
|
|
186
186
|
case P:
|
|
187
187
|
return "Suspense";
|
|
188
|
-
case
|
|
188
|
+
case R:
|
|
189
189
|
return "SuspenseList";
|
|
190
190
|
}
|
|
191
191
|
if (typeof e == "object")
|
|
192
192
|
switch (e.$$typeof) {
|
|
193
|
-
case
|
|
193
|
+
case _:
|
|
194
194
|
var r = e;
|
|
195
|
-
return
|
|
195
|
+
return ae(r) + ".Consumer";
|
|
196
196
|
case p:
|
|
197
197
|
var t = e;
|
|
198
|
-
return
|
|
198
|
+
return ae(t._context) + ".Provider";
|
|
199
199
|
case y:
|
|
200
200
|
return Ue(e, e.render, "ForwardRef");
|
|
201
201
|
case l:
|
|
202
202
|
var n = e.displayName || null;
|
|
203
|
-
return n !== null ? n :
|
|
203
|
+
return n !== null ? n : w(e.type) || "Memo";
|
|
204
204
|
case f: {
|
|
205
205
|
var s = e, c = s._payload, i = s._init;
|
|
206
206
|
try {
|
|
207
|
-
return
|
|
207
|
+
return w(i(c));
|
|
208
208
|
} catch {
|
|
209
209
|
return null;
|
|
210
210
|
}
|
|
@@ -212,18 +212,18 @@ function _r() {
|
|
|
212
212
|
}
|
|
213
213
|
return null;
|
|
214
214
|
}
|
|
215
|
-
var x = Object.assign,
|
|
216
|
-
function
|
|
215
|
+
var x = Object.assign, A = 0, oe, ie, se, ue, ce, le, fe;
|
|
216
|
+
function de() {
|
|
217
217
|
}
|
|
218
|
-
|
|
218
|
+
de.__reactDisabledLog = !0;
|
|
219
219
|
function ze() {
|
|
220
220
|
{
|
|
221
|
-
if (
|
|
222
|
-
|
|
221
|
+
if (A === 0) {
|
|
222
|
+
oe = console.log, ie = console.info, se = console.warn, ue = console.error, ce = console.group, le = console.groupCollapsed, fe = console.groupEnd;
|
|
223
223
|
var e = {
|
|
224
224
|
configurable: !0,
|
|
225
225
|
enumerable: !0,
|
|
226
|
-
value:
|
|
226
|
+
value: de,
|
|
227
227
|
writable: !0
|
|
228
228
|
};
|
|
229
229
|
Object.defineProperties(console, {
|
|
@@ -236,12 +236,12 @@ function _r() {
|
|
|
236
236
|
groupEnd: e
|
|
237
237
|
});
|
|
238
238
|
}
|
|
239
|
-
|
|
239
|
+
A++;
|
|
240
240
|
}
|
|
241
241
|
}
|
|
242
242
|
function Be() {
|
|
243
243
|
{
|
|
244
|
-
if (
|
|
244
|
+
if (A--, A === 0) {
|
|
245
245
|
var e = {
|
|
246
246
|
configurable: !0,
|
|
247
247
|
enumerable: !0,
|
|
@@ -249,64 +249,64 @@ function _r() {
|
|
|
249
249
|
};
|
|
250
250
|
Object.defineProperties(console, {
|
|
251
251
|
log: x({}, e, {
|
|
252
|
-
value:
|
|
252
|
+
value: oe
|
|
253
253
|
}),
|
|
254
254
|
info: x({}, e, {
|
|
255
|
-
value:
|
|
255
|
+
value: ie
|
|
256
256
|
}),
|
|
257
257
|
warn: x({}, e, {
|
|
258
|
-
value:
|
|
258
|
+
value: se
|
|
259
259
|
}),
|
|
260
260
|
error: x({}, e, {
|
|
261
|
-
value:
|
|
261
|
+
value: ue
|
|
262
262
|
}),
|
|
263
263
|
group: x({}, e, {
|
|
264
|
-
value:
|
|
264
|
+
value: ce
|
|
265
265
|
}),
|
|
266
266
|
groupCollapsed: x({}, e, {
|
|
267
|
-
value:
|
|
267
|
+
value: le
|
|
268
268
|
}),
|
|
269
269
|
groupEnd: x({}, e, {
|
|
270
|
-
value:
|
|
270
|
+
value: fe
|
|
271
271
|
})
|
|
272
272
|
});
|
|
273
273
|
}
|
|
274
|
-
|
|
274
|
+
A < 0 && b("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
275
275
|
}
|
|
276
276
|
}
|
|
277
|
-
var
|
|
278
|
-
function
|
|
277
|
+
var Z = j.ReactCurrentDispatcher, K;
|
|
278
|
+
function M(e, r, t) {
|
|
279
279
|
{
|
|
280
|
-
if (
|
|
280
|
+
if (K === void 0)
|
|
281
281
|
try {
|
|
282
282
|
throw Error();
|
|
283
283
|
} catch (s) {
|
|
284
284
|
var n = s.stack.trim().match(/\n( *(at )?)/);
|
|
285
|
-
|
|
285
|
+
K = n && n[1] || "";
|
|
286
286
|
}
|
|
287
287
|
return `
|
|
288
|
-
` +
|
|
288
|
+
` + K + e;
|
|
289
289
|
}
|
|
290
290
|
}
|
|
291
|
-
var
|
|
291
|
+
var G = !1, L;
|
|
292
292
|
{
|
|
293
293
|
var qe = typeof WeakMap == "function" ? WeakMap : Map;
|
|
294
|
-
|
|
294
|
+
L = new qe();
|
|
295
295
|
}
|
|
296
|
-
function
|
|
297
|
-
if (!e ||
|
|
296
|
+
function ve(e, r) {
|
|
297
|
+
if (!e || G)
|
|
298
298
|
return "";
|
|
299
299
|
{
|
|
300
|
-
var t =
|
|
300
|
+
var t = L.get(e);
|
|
301
301
|
if (t !== void 0)
|
|
302
302
|
return t;
|
|
303
303
|
}
|
|
304
304
|
var n;
|
|
305
|
-
|
|
305
|
+
G = !0;
|
|
306
306
|
var s = Error.prepareStackTrace;
|
|
307
307
|
Error.prepareStackTrace = void 0;
|
|
308
308
|
var c;
|
|
309
|
-
c =
|
|
309
|
+
c = Z.current, Z.current = null, ze();
|
|
310
310
|
try {
|
|
311
311
|
if (r) {
|
|
312
312
|
var i = function() {
|
|
@@ -342,94 +342,94 @@ function _r() {
|
|
|
342
342
|
} catch (C) {
|
|
343
343
|
if (C && n && typeof C.stack == "string") {
|
|
344
344
|
for (var o = C.stack.split(`
|
|
345
|
-
`),
|
|
346
|
-
`), d = o.length - 1, v =
|
|
345
|
+
`), h = n.stack.split(`
|
|
346
|
+
`), d = o.length - 1, v = h.length - 1; d >= 1 && v >= 0 && o[d] !== h[v]; )
|
|
347
347
|
v--;
|
|
348
348
|
for (; d >= 1 && v >= 0; d--, v--)
|
|
349
|
-
if (o[d] !==
|
|
349
|
+
if (o[d] !== h[v]) {
|
|
350
350
|
if (d !== 1 || v !== 1)
|
|
351
351
|
do
|
|
352
|
-
if (d--, v--, v < 0 || o[d] !==
|
|
353
|
-
var
|
|
352
|
+
if (d--, v--, v < 0 || o[d] !== h[v]) {
|
|
353
|
+
var S = `
|
|
354
354
|
` + o[d].replace(" at new ", " at ");
|
|
355
|
-
return e.displayName &&
|
|
355
|
+
return e.displayName && S.includes("<anonymous>") && (S = S.replace("<anonymous>", e.displayName)), typeof e == "function" && L.set(e, S), S;
|
|
356
356
|
}
|
|
357
357
|
while (d >= 1 && v >= 0);
|
|
358
358
|
break;
|
|
359
359
|
}
|
|
360
360
|
}
|
|
361
361
|
} finally {
|
|
362
|
-
|
|
362
|
+
G = !1, Z.current = c, Be(), Error.prepareStackTrace = s;
|
|
363
363
|
}
|
|
364
|
-
var D = e ? e.displayName || e.name : "",
|
|
365
|
-
return typeof e == "function" &&
|
|
364
|
+
var D = e ? e.displayName || e.name : "", Ce = D ? M(D) : "";
|
|
365
|
+
return typeof e == "function" && L.set(e, Ce), Ce;
|
|
366
366
|
}
|
|
367
367
|
function Je(e, r, t) {
|
|
368
|
-
return
|
|
368
|
+
return ve(e, !1);
|
|
369
369
|
}
|
|
370
370
|
function Ze(e) {
|
|
371
371
|
var r = e.prototype;
|
|
372
372
|
return !!(r && r.isReactComponent);
|
|
373
373
|
}
|
|
374
|
-
function
|
|
374
|
+
function N(e, r, t) {
|
|
375
375
|
if (e == null)
|
|
376
376
|
return "";
|
|
377
377
|
if (typeof e == "function")
|
|
378
|
-
return
|
|
378
|
+
return ve(e, Ze(e));
|
|
379
379
|
if (typeof e == "string")
|
|
380
|
-
return
|
|
380
|
+
return M(e);
|
|
381
381
|
switch (e) {
|
|
382
382
|
case P:
|
|
383
|
-
return
|
|
384
|
-
case
|
|
385
|
-
return
|
|
383
|
+
return M("Suspense");
|
|
384
|
+
case R:
|
|
385
|
+
return M("SuspenseList");
|
|
386
386
|
}
|
|
387
387
|
if (typeof e == "object")
|
|
388
388
|
switch (e.$$typeof) {
|
|
389
389
|
case y:
|
|
390
390
|
return Je(e.render);
|
|
391
391
|
case l:
|
|
392
|
-
return
|
|
392
|
+
return N(e.type, r, t);
|
|
393
393
|
case f: {
|
|
394
394
|
var n = e, s = n._payload, c = n._init;
|
|
395
395
|
try {
|
|
396
|
-
return
|
|
396
|
+
return N(c(s), r, t);
|
|
397
397
|
} catch {
|
|
398
398
|
}
|
|
399
399
|
}
|
|
400
400
|
}
|
|
401
401
|
return "";
|
|
402
402
|
}
|
|
403
|
-
var
|
|
404
|
-
function
|
|
403
|
+
var U = Object.prototype.hasOwnProperty, pe = {}, me = j.ReactDebugCurrentFrame;
|
|
404
|
+
function z(e) {
|
|
405
405
|
if (e) {
|
|
406
|
-
var r = e._owner, t =
|
|
407
|
-
|
|
406
|
+
var r = e._owner, t = N(e.type, e._source, r ? r.type : null);
|
|
407
|
+
me.setExtraStackFrame(t);
|
|
408
408
|
} else
|
|
409
|
-
|
|
409
|
+
me.setExtraStackFrame(null);
|
|
410
410
|
}
|
|
411
|
-
function
|
|
411
|
+
function Ke(e, r, t, n, s) {
|
|
412
412
|
{
|
|
413
|
-
var c = Function.call.bind(
|
|
413
|
+
var c = Function.call.bind(U);
|
|
414
414
|
for (var i in e)
|
|
415
415
|
if (c(e, i)) {
|
|
416
416
|
var o = void 0;
|
|
417
417
|
try {
|
|
418
418
|
if (typeof e[i] != "function") {
|
|
419
|
-
var
|
|
420
|
-
throw
|
|
419
|
+
var h = Error((n || "React class") + ": " + t + " type `" + i + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[i] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
420
|
+
throw h.name = "Invariant Violation", h;
|
|
421
421
|
}
|
|
422
422
|
o = e[i](r, i, n, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
423
423
|
} catch (d) {
|
|
424
424
|
o = d;
|
|
425
425
|
}
|
|
426
|
-
o && !(o instanceof Error) && (
|
|
426
|
+
o && !(o instanceof Error) && (z(s), b("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", n || "React class", t, i, typeof o), z(null)), o instanceof Error && !(o.message in pe) && (pe[o.message] = !0, z(s), b("Failed %s type: %s", t, o.message), z(null));
|
|
427
427
|
}
|
|
428
428
|
}
|
|
429
429
|
}
|
|
430
|
-
var
|
|
431
|
-
function
|
|
432
|
-
return
|
|
430
|
+
var Ge = Array.isArray;
|
|
431
|
+
function H(e) {
|
|
432
|
+
return Ge(e);
|
|
433
433
|
}
|
|
434
434
|
function He(e) {
|
|
435
435
|
{
|
|
@@ -439,27 +439,27 @@ function _r() {
|
|
|
439
439
|
}
|
|
440
440
|
function Xe(e) {
|
|
441
441
|
try {
|
|
442
|
-
return
|
|
442
|
+
return ye(e), !1;
|
|
443
443
|
} catch {
|
|
444
444
|
return !0;
|
|
445
445
|
}
|
|
446
446
|
}
|
|
447
|
-
function
|
|
447
|
+
function ye(e) {
|
|
448
448
|
return "" + e;
|
|
449
449
|
}
|
|
450
|
-
function
|
|
450
|
+
function ge(e) {
|
|
451
451
|
if (Xe(e))
|
|
452
|
-
return
|
|
452
|
+
return b("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", He(e)), ye(e);
|
|
453
453
|
}
|
|
454
|
-
var
|
|
454
|
+
var I = j.ReactCurrentOwner, Qe = {
|
|
455
455
|
key: !0,
|
|
456
456
|
ref: !0,
|
|
457
457
|
__self: !0,
|
|
458
458
|
__source: !0
|
|
459
|
-
},
|
|
460
|
-
|
|
459
|
+
}, Re, be, X;
|
|
460
|
+
X = {};
|
|
461
461
|
function er(e) {
|
|
462
|
-
if (
|
|
462
|
+
if (U.call(e, "ref")) {
|
|
463
463
|
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
464
464
|
if (r && r.isReactWarning)
|
|
465
465
|
return !1;
|
|
@@ -467,7 +467,7 @@ function _r() {
|
|
|
467
467
|
return e.ref !== void 0;
|
|
468
468
|
}
|
|
469
469
|
function rr(e) {
|
|
470
|
-
if (
|
|
470
|
+
if (U.call(e, "key")) {
|
|
471
471
|
var r = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
472
472
|
if (r && r.isReactWarning)
|
|
473
473
|
return !1;
|
|
@@ -475,15 +475,15 @@ function _r() {
|
|
|
475
475
|
return e.key !== void 0;
|
|
476
476
|
}
|
|
477
477
|
function tr(e, r) {
|
|
478
|
-
if (typeof e.ref == "string" &&
|
|
479
|
-
var t =
|
|
480
|
-
|
|
478
|
+
if (typeof e.ref == "string" && I.current && r && I.current.stateNode !== r) {
|
|
479
|
+
var t = w(I.current.type);
|
|
480
|
+
X[t] || (b('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', w(I.current.type), e.ref), X[t] = !0);
|
|
481
481
|
}
|
|
482
482
|
}
|
|
483
483
|
function nr(e, r) {
|
|
484
484
|
{
|
|
485
485
|
var t = function() {
|
|
486
|
-
|
|
486
|
+
Re || (Re = !0, b("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
|
|
487
487
|
};
|
|
488
488
|
t.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
489
489
|
get: t,
|
|
@@ -494,7 +494,7 @@ function _r() {
|
|
|
494
494
|
function ar(e, r) {
|
|
495
495
|
{
|
|
496
496
|
var t = function() {
|
|
497
|
-
|
|
497
|
+
be || (be = !0, b("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
|
|
498
498
|
};
|
|
499
499
|
t.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
500
500
|
get: t,
|
|
@@ -505,7 +505,7 @@ function _r() {
|
|
|
505
505
|
var or = function(e, r, t, n, s, c, i) {
|
|
506
506
|
var o = {
|
|
507
507
|
// This tag allows us to uniquely identify this as a React Element
|
|
508
|
-
$$typeof:
|
|
508
|
+
$$typeof: g,
|
|
509
509
|
// Built-in properties that belong on the element
|
|
510
510
|
type: e,
|
|
511
511
|
key: r,
|
|
@@ -533,39 +533,39 @@ function _r() {
|
|
|
533
533
|
};
|
|
534
534
|
function ir(e, r, t, n, s) {
|
|
535
535
|
{
|
|
536
|
-
var c, i = {}, o = null,
|
|
537
|
-
t !== void 0 && (
|
|
536
|
+
var c, i = {}, o = null, h = null;
|
|
537
|
+
t !== void 0 && (ge(t), o = "" + t), rr(r) && (ge(r.key), o = "" + r.key), er(r) && (h = r.ref, tr(r, s));
|
|
538
538
|
for (c in r)
|
|
539
|
-
|
|
539
|
+
U.call(r, c) && !Qe.hasOwnProperty(c) && (i[c] = r[c]);
|
|
540
540
|
if (e && e.defaultProps) {
|
|
541
541
|
var d = e.defaultProps;
|
|
542
542
|
for (c in d)
|
|
543
543
|
i[c] === void 0 && (i[c] = d[c]);
|
|
544
544
|
}
|
|
545
|
-
if (o ||
|
|
545
|
+
if (o || h) {
|
|
546
546
|
var v = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
547
|
-
o && nr(i, v),
|
|
547
|
+
o && nr(i, v), h && ar(i, v);
|
|
548
548
|
}
|
|
549
|
-
return or(e, o,
|
|
549
|
+
return or(e, o, h, s, n, I.current, i);
|
|
550
550
|
}
|
|
551
551
|
}
|
|
552
|
-
var
|
|
552
|
+
var Q = j.ReactCurrentOwner, he = j.ReactDebugCurrentFrame;
|
|
553
553
|
function k(e) {
|
|
554
554
|
if (e) {
|
|
555
|
-
var r = e._owner, t =
|
|
556
|
-
|
|
555
|
+
var r = e._owner, t = N(e.type, e._source, r ? r.type : null);
|
|
556
|
+
he.setExtraStackFrame(t);
|
|
557
557
|
} else
|
|
558
|
-
|
|
558
|
+
he.setExtraStackFrame(null);
|
|
559
559
|
}
|
|
560
|
-
var
|
|
561
|
-
|
|
562
|
-
function
|
|
563
|
-
return typeof e == "object" && e !== null && e.$$typeof ===
|
|
560
|
+
var ee;
|
|
561
|
+
ee = !1;
|
|
562
|
+
function re(e) {
|
|
563
|
+
return typeof e == "object" && e !== null && e.$$typeof === g;
|
|
564
564
|
}
|
|
565
|
-
function
|
|
565
|
+
function Ee() {
|
|
566
566
|
{
|
|
567
|
-
if (
|
|
568
|
-
var e =
|
|
567
|
+
if (Q.current) {
|
|
568
|
+
var e = w(Q.current.type);
|
|
569
569
|
if (e)
|
|
570
570
|
return `
|
|
571
571
|
|
|
@@ -585,10 +585,10 @@ Check your code at ` + r + ":" + t + ".";
|
|
|
585
585
|
return "";
|
|
586
586
|
}
|
|
587
587
|
}
|
|
588
|
-
var
|
|
588
|
+
var _e = {};
|
|
589
589
|
function ur(e) {
|
|
590
590
|
{
|
|
591
|
-
var r =
|
|
591
|
+
var r = Ee();
|
|
592
592
|
if (!r) {
|
|
593
593
|
var t = typeof e == "string" ? e : e.displayName || e.name;
|
|
594
594
|
t && (r = `
|
|
@@ -598,35 +598,35 @@ Check the top-level render call using <` + t + ">.");
|
|
|
598
598
|
return r;
|
|
599
599
|
}
|
|
600
600
|
}
|
|
601
|
-
function
|
|
601
|
+
function Se(e, r) {
|
|
602
602
|
{
|
|
603
603
|
if (!e._store || e._store.validated || e.key != null)
|
|
604
604
|
return;
|
|
605
605
|
e._store.validated = !0;
|
|
606
606
|
var t = ur(r);
|
|
607
|
-
if (
|
|
607
|
+
if (_e[t])
|
|
608
608
|
return;
|
|
609
|
-
|
|
609
|
+
_e[t] = !0;
|
|
610
610
|
var n = "";
|
|
611
|
-
e && e._owner && e._owner !==
|
|
611
|
+
e && e._owner && e._owner !== Q.current && (n = " It was passed a child from " + w(e._owner.type) + "."), k(e), b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, n), k(null);
|
|
612
612
|
}
|
|
613
613
|
}
|
|
614
|
-
function
|
|
614
|
+
function Te(e, r) {
|
|
615
615
|
{
|
|
616
616
|
if (typeof e != "object")
|
|
617
617
|
return;
|
|
618
|
-
if (
|
|
618
|
+
if (H(e))
|
|
619
619
|
for (var t = 0; t < e.length; t++) {
|
|
620
620
|
var n = e[t];
|
|
621
|
-
|
|
621
|
+
re(n) && Se(n, r);
|
|
622
622
|
}
|
|
623
|
-
else if (
|
|
623
|
+
else if (re(e))
|
|
624
624
|
e._store && (e._store.validated = !0);
|
|
625
625
|
else if (e) {
|
|
626
626
|
var s = Ie(e);
|
|
627
627
|
if (typeof s == "function" && s !== e.entries)
|
|
628
628
|
for (var c = s.call(e), i; !(i = c.next()).done; )
|
|
629
|
-
|
|
629
|
+
re(i.value) && Se(i.value, r);
|
|
630
630
|
}
|
|
631
631
|
}
|
|
632
632
|
}
|
|
@@ -645,14 +645,14 @@ Check the top-level render call using <` + t + ">.");
|
|
|
645
645
|
else
|
|
646
646
|
return;
|
|
647
647
|
if (t) {
|
|
648
|
-
var n =
|
|
649
|
-
|
|
650
|
-
} else if (r.PropTypes !== void 0 && !
|
|
651
|
-
|
|
652
|
-
var s =
|
|
653
|
-
|
|
648
|
+
var n = w(r);
|
|
649
|
+
Ke(t, e.props, "prop", n, e);
|
|
650
|
+
} else if (r.PropTypes !== void 0 && !ee) {
|
|
651
|
+
ee = !0;
|
|
652
|
+
var s = w(r);
|
|
653
|
+
b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", s || "Unknown");
|
|
654
654
|
}
|
|
655
|
-
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved &&
|
|
655
|
+
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && b("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
656
656
|
}
|
|
657
657
|
}
|
|
658
658
|
function lr(e) {
|
|
@@ -660,11 +660,11 @@ Check the top-level render call using <` + t + ">.");
|
|
|
660
660
|
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
|
|
661
661
|
var n = r[t];
|
|
662
662
|
if (n !== "children" && n !== "key") {
|
|
663
|
-
k(e),
|
|
663
|
+
k(e), b("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", n), k(null);
|
|
664
664
|
break;
|
|
665
665
|
}
|
|
666
666
|
}
|
|
667
|
-
e.ref !== null && (k(e),
|
|
667
|
+
e.ref !== null && (k(e), b("Invalid attribute `ref` supplied to `React.Fragment`."), k(null));
|
|
668
668
|
}
|
|
669
669
|
}
|
|
670
670
|
function we(e, r, t, n, s, c) {
|
|
@@ -673,28 +673,28 @@ Check the top-level render call using <` + t + ">.");
|
|
|
673
673
|
if (!i) {
|
|
674
674
|
var o = "";
|
|
675
675
|
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (o += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
676
|
-
var
|
|
677
|
-
|
|
676
|
+
var h = sr(s);
|
|
677
|
+
h ? o += h : o += Ee();
|
|
678
678
|
var d;
|
|
679
|
-
e === null ? d = "null" :
|
|
679
|
+
e === null ? d = "null" : H(e) ? d = "array" : e !== void 0 && e.$$typeof === g ? (d = "<" + (w(e.type) || "Unknown") + " />", o = " Did you accidentally export a JSX literal instead of a component?") : d = typeof e, b("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", d, o);
|
|
680
680
|
}
|
|
681
681
|
var v = ir(e, r, t, s, c);
|
|
682
682
|
if (v == null)
|
|
683
683
|
return v;
|
|
684
684
|
if (i) {
|
|
685
|
-
var
|
|
686
|
-
if (
|
|
685
|
+
var S = r.children;
|
|
686
|
+
if (S !== void 0)
|
|
687
687
|
if (n)
|
|
688
|
-
if (
|
|
689
|
-
for (var D = 0; D <
|
|
690
|
-
|
|
691
|
-
Object.freeze && Object.freeze(
|
|
688
|
+
if (H(S)) {
|
|
689
|
+
for (var D = 0; D < S.length; D++)
|
|
690
|
+
Te(S[D], e);
|
|
691
|
+
Object.freeze && Object.freeze(S);
|
|
692
692
|
} else
|
|
693
|
-
|
|
693
|
+
b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
694
694
|
else
|
|
695
|
-
|
|
695
|
+
Te(S, e);
|
|
696
696
|
}
|
|
697
|
-
return e ===
|
|
697
|
+
return e === T ? lr(v) : cr(v), v;
|
|
698
698
|
}
|
|
699
699
|
}
|
|
700
700
|
function fr(e, r, t) {
|
|
@@ -704,28 +704,42 @@ Check the top-level render call using <` + t + ">.");
|
|
|
704
704
|
return we(e, r, t, !1);
|
|
705
705
|
}
|
|
706
706
|
var vr = dr, pr = fr;
|
|
707
|
-
$.Fragment =
|
|
707
|
+
$.Fragment = T, $.jsx = vr, $.jsxs = pr;
|
|
708
708
|
}()), $;
|
|
709
709
|
}
|
|
710
|
-
process.env.NODE_ENV === "production" ?
|
|
711
|
-
var
|
|
712
|
-
const Sr = (a) => ({
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
710
|
+
process.env.NODE_ENV === "production" ? te.exports = Er() : te.exports = _r();
|
|
711
|
+
var xe = te.exports;
|
|
712
|
+
const Sr = (a, g) => (...u) => {
|
|
713
|
+
clearTimeout(0), setTimeout(() => a(...u), g);
|
|
714
|
+
}, Tr = [
|
|
715
|
+
"transitionDuration",
|
|
716
|
+
"transitionEasing",
|
|
717
|
+
"transitionInterpolator",
|
|
718
|
+
"transitionInterruption"
|
|
719
|
+
], wr = (a, g) => {
|
|
720
|
+
a({
|
|
721
|
+
type: "carto/setViewState",
|
|
722
|
+
payload: g
|
|
723
|
+
}), a({ type: "carto/setViewPort" });
|
|
724
|
+
}, Cr = Sr(wr, 500);
|
|
725
|
+
function Dr({ children: a, maps: g }) {
|
|
726
|
+
const E = gr(), [T, u] = mr(hr, {
|
|
727
|
+
...q.state,
|
|
728
|
+
maps: g.reduce((l, f) => (l[f.id] = f, l), q.state.maps)
|
|
729
|
+
}), m = V(
|
|
721
730
|
(l, f) => {
|
|
722
|
-
|
|
731
|
+
if (g[0].id === l) {
|
|
732
|
+
const F = { ...f };
|
|
733
|
+
for (const J of Tr)
|
|
734
|
+
delete F[J];
|
|
735
|
+
Cr(E, F);
|
|
736
|
+
}
|
|
723
737
|
},
|
|
724
|
-
[
|
|
725
|
-
), p =
|
|
738
|
+
[E, g]
|
|
739
|
+
), p = V(
|
|
726
740
|
(l, f) => {
|
|
727
741
|
u({
|
|
728
|
-
type:
|
|
742
|
+
type: Y.SetViewState,
|
|
729
743
|
payload: {
|
|
730
744
|
id: l,
|
|
731
745
|
viewState: f
|
|
@@ -733,10 +747,10 @@ function xr({ children: a, maps: _ }) {
|
|
|
733
747
|
}), m(l, f);
|
|
734
748
|
},
|
|
735
749
|
[u, m]
|
|
736
|
-
),
|
|
750
|
+
), _ = V(
|
|
737
751
|
(l, { height: f, width: O }) => {
|
|
738
752
|
u({
|
|
739
|
-
type:
|
|
753
|
+
type: Y.SetResize,
|
|
740
754
|
payload: {
|
|
741
755
|
id: l,
|
|
742
756
|
height: f,
|
|
@@ -745,10 +759,10 @@ function xr({ children: a, maps: _ }) {
|
|
|
745
759
|
}), m(l, { height: f, width: O });
|
|
746
760
|
},
|
|
747
761
|
[u, m]
|
|
748
|
-
), y =
|
|
762
|
+
), y = V(
|
|
749
763
|
(l, f) => {
|
|
750
764
|
u({
|
|
751
|
-
type:
|
|
765
|
+
type: Y.SetBasemap,
|
|
752
766
|
payload: {
|
|
753
767
|
id: l,
|
|
754
768
|
basemap: f
|
|
@@ -756,10 +770,10 @@ function xr({ children: a, maps: _ }) {
|
|
|
756
770
|
});
|
|
757
771
|
},
|
|
758
772
|
[u]
|
|
759
|
-
), P =
|
|
773
|
+
), P = V(
|
|
760
774
|
(l, f) => {
|
|
761
775
|
u({
|
|
762
|
-
type:
|
|
776
|
+
type: Y.SetZoom,
|
|
763
777
|
payload: {
|
|
764
778
|
id: l,
|
|
765
779
|
zoom: f
|
|
@@ -767,23 +781,23 @@ function xr({ children: a, maps: _ }) {
|
|
|
767
781
|
});
|
|
768
782
|
},
|
|
769
783
|
[u]
|
|
770
|
-
),
|
|
784
|
+
), R = yr({
|
|
771
785
|
setViewState: p,
|
|
772
786
|
setBasemap: y,
|
|
773
|
-
setResize:
|
|
787
|
+
setResize: _,
|
|
774
788
|
setZoom: P
|
|
775
789
|
});
|
|
776
|
-
return /* @__PURE__ */
|
|
790
|
+
return /* @__PURE__ */ xe.jsx(Ae.Provider, { value: R.current, children: /* @__PURE__ */ xe.jsx(Fe.Provider, { value: T, children: a }) });
|
|
777
791
|
}
|
|
778
792
|
export {
|
|
779
|
-
|
|
793
|
+
xr as CartoBasemapURL,
|
|
780
794
|
br as CartoBasemapsNames,
|
|
781
795
|
Rr as GMapsBasemap,
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
796
|
+
q as INITIAL_STATE,
|
|
797
|
+
Ae as MapActionsContext,
|
|
798
|
+
Fe as MapContext,
|
|
799
|
+
Dr as MapProvider,
|
|
786
800
|
hr as reducer,
|
|
787
|
-
|
|
788
|
-
|
|
801
|
+
jr as useMap,
|
|
802
|
+
kr as useMapActions
|
|
789
803
|
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export * from './map.const';
|
|
2
|
+
export * from './map.types';
|
|
3
|
+
export { INITIAL_STATE, MapContext, MapActionsContext } from './map.context';
|
|
4
|
+
export { reducer } from './map.reducer';
|
|
5
|
+
export { useMap, useMapActions } from './map.hook';
|
|
6
|
+
export { MapProvider } from './map.provider';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare enum GMapsBasemap {
|
|
2
|
+
Roadmap = "roadmap",
|
|
3
|
+
Satellite = "satellite",
|
|
4
|
+
Terrain = "terrain"
|
|
5
|
+
}
|
|
6
|
+
export declare enum CartoBasemapsNames {
|
|
7
|
+
DarkMatter = "dark-matter",
|
|
8
|
+
Positron = "positron",
|
|
9
|
+
Voyager = "voyager"
|
|
10
|
+
}
|
|
11
|
+
export declare const CartoBasemapURL: {
|
|
12
|
+
positron: string;
|
|
13
|
+
voyager: string;
|
|
14
|
+
"dark-matter": string;
|
|
15
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { MapContextInterface } from './map.types';
|
|
3
|
+
export declare const INITIAL_STATE: MapContextInterface;
|
|
4
|
+
export declare const MapContext: import("react").Context<import("./map.types").MapState>;
|
|
5
|
+
export declare const MapActionsContext: import("react").Context<import("./map.types").MapActionsState>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { MapsProps, MapState } from './map.types';
|
|
2
|
+
export declare enum Actions {
|
|
3
|
+
SetViewState = "SetViewState",
|
|
4
|
+
SetBasemap = "SetBasemap",
|
|
5
|
+
SetResize = "SetResize",
|
|
6
|
+
SetZoom = "SetZoom"
|
|
7
|
+
}
|
|
8
|
+
type Action = {
|
|
9
|
+
type: Actions;
|
|
10
|
+
payload: MapsProps;
|
|
11
|
+
};
|
|
12
|
+
export declare function reducer(state: MapState, { type, payload }: Action): MapState;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/// <reference types="google.maps" />
|
|
2
|
+
import { type MapViewState } from '@deck.gl/core/typed';
|
|
3
|
+
import { type GoogleMapsOverlay, type GoogleMapsOverlayProps } from '@deck.gl/google-maps/typed';
|
|
4
|
+
import { type DeckGLProps, type DeckGLRef } from '@deck.gl/react/typed';
|
|
5
|
+
import type { StyleSpecification } from 'maplibre-gl';
|
|
6
|
+
import type { Properties } from 'csstype';
|
|
7
|
+
import type { MutableRefObject, ReactNode, RefObject } from 'react';
|
|
8
|
+
import { type MapRef } from 'react-map-gl';
|
|
9
|
+
import { CartoBasemapsNames, GMapsBasemap } from './map.const';
|
|
10
|
+
export type MapProviderProps = {
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
maps: MapsProps[];
|
|
13
|
+
};
|
|
14
|
+
export type MapState = {
|
|
15
|
+
maps: Record<MapsProps['id'], MapsProps>;
|
|
16
|
+
};
|
|
17
|
+
export type MapResize = {
|
|
18
|
+
width: number | string;
|
|
19
|
+
height: number | string;
|
|
20
|
+
};
|
|
21
|
+
export type MapActionsState = {
|
|
22
|
+
setViewState: (id: MapsProps['id'], viewState: MapViewState) => void;
|
|
23
|
+
setResize: (id: MapsProps['id'], props: MapResize) => void;
|
|
24
|
+
setBasemap: (id: MapsProps['id'], basemap: Basemap) => void;
|
|
25
|
+
setZoom: (id: MapsProps['id'], zoom: number) => void;
|
|
26
|
+
};
|
|
27
|
+
export type MapContextInterface = {
|
|
28
|
+
state: MapState;
|
|
29
|
+
actions: MapActionsState;
|
|
30
|
+
};
|
|
31
|
+
export type Basemap = (typeof GMapsBasemap)[keyof typeof GMapsBasemap] | (typeof CartoBasemapsNames)[keyof typeof CartoBasemapsNames] | string | StyleSpecification;
|
|
32
|
+
export type CommonProps = {
|
|
33
|
+
id: string;
|
|
34
|
+
basemap?: Basemap;
|
|
35
|
+
instanceRef?: RefObject<InstanceMapRef>;
|
|
36
|
+
overlayRef?: MutableRefObject<OverlayMapRef>;
|
|
37
|
+
} & DeckGLProps;
|
|
38
|
+
export type MapsProps = DeckGLMapsProps & GoogleMapsProps;
|
|
39
|
+
export type InstanceMapRef = GoogleMapsOverlay | DeckGLRef | null;
|
|
40
|
+
export type OverlayMapRef = google.maps.Map | MapRef | null;
|
|
41
|
+
export type DeckGLMapsProps = CommonProps;
|
|
42
|
+
export type GoogleMapsProps = {
|
|
43
|
+
apiKey?: string;
|
|
44
|
+
height?: string | undefined;
|
|
45
|
+
language?: string;
|
|
46
|
+
mapOptions?: Record<string, number | string>;
|
|
47
|
+
style?: Properties;
|
|
48
|
+
version?: string;
|
|
49
|
+
width?: string | undefined;
|
|
50
|
+
} & CommonProps & GoogleMapsOverlayProps;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const debounce: <F extends (...args: Parameters<F>) => void>(func: F, waitFor: number) => (...args: Parameters<F>) => ReturnType<F>;
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@carto/ps-react-maps",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
3
|
+
"version": "0.0.1-alpha.2",
|
|
4
4
|
"description": "CARTO's Professional Service React Maps library",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist"
|
|
7
7
|
],
|
|
8
8
|
"type": "module",
|
|
9
9
|
"types": "./dist/types/index.d.ts",
|
|
10
|
-
"main": "./dist/
|
|
11
|
-
"module": "./dist/
|
|
10
|
+
"main": "./dist/index.cjs",
|
|
11
|
+
"module": "./dist/index.js",
|
|
12
12
|
"exports": {
|
|
13
13
|
".": {
|
|
14
14
|
"types": "./dist/types/index.d.ts",
|
|
@@ -17,7 +17,8 @@
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
"scripts": {
|
|
20
|
-
"
|
|
20
|
+
"prebuild": "npm exec rimraf dist",
|
|
21
|
+
"build": "tsc && vite build",
|
|
21
22
|
"lint": "eslint './**/*.{ts,tsx}' --ignore-path ../../.gitignore",
|
|
22
23
|
"format": "prettier --write . --ignore-path ../../.gitignore",
|
|
23
24
|
"test:watch": "vitest",
|
|
@@ -25,7 +26,6 @@
|
|
|
25
26
|
"test:coverage": "vitest run --coverage"
|
|
26
27
|
},
|
|
27
28
|
"dependencies": {
|
|
28
|
-
"react-map-gl": "7.1.6",
|
|
29
29
|
"react-redux": "8.1.3"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
@@ -38,13 +38,13 @@
|
|
|
38
38
|
"@testing-library/user-event": "14.5.1",
|
|
39
39
|
"@types/google.maps": "3.54.4",
|
|
40
40
|
"@vitejs/plugin-react-swc": "3.4.0",
|
|
41
|
-
"maplibre-gl": "3.5.1"
|
|
41
|
+
"maplibre-gl": "3.5.1",
|
|
42
|
+
"react-map-gl": "7.1.6"
|
|
42
43
|
},
|
|
43
44
|
"peerDependencies": {
|
|
44
45
|
"@carto/react-redux": "1.x || 2.x",
|
|
45
46
|
"react": "17.x || 18.x",
|
|
46
47
|
"react-dom": "17.x || 18.x",
|
|
47
|
-
"react-map-gl": "7.x",
|
|
48
48
|
"react-redux": "8.x"
|
|
49
49
|
}
|
|
50
50
|
}
|