@road-labs/map-sdk 0.0.17 → 0.0.18
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/contexts/Map.d.ts +2 -0
- package/dist/index.css +1 -1
- package/dist/index.js +22 -22
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1543 -1544
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("react"),ut=require("react-dom");function po(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ct={exports:{}},st={};/**
|
|
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 Qn;function ho(){if(Qn)return st;Qn=1;var e=
|
|
9
|
+
*/var Qn;function ho(){if(Qn)return st;Qn=1;var e=v,n=Symbol.for("react.element"),i=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,t={key:!0,ref:!0,__self:!0,__source:!0};function s(c,l,u){var f,p={},h=null,x=null;u!==void 0&&(h=""+u),l.key!==void 0&&(h=""+l.key),l.ref!==void 0&&(x=l.ref);for(f in l)r.call(l,f)&&!t.hasOwnProperty(f)&&(p[f]=l[f]);if(c&&c.defaultProps)for(f in l=c.defaultProps,l)p[f]===void 0&&(p[f]=l[f]);return{$$typeof:n,type:c,key:h,ref:x,props:p,_owner:o.current}}return st.Fragment=i,st.jsx=s,st.jsxs=s,st}var at={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,47 +14,47 @@
|
|
|
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 er;function mo(){return er||(er=1,process.env.NODE_ENV!=="production"&&(function(){var e=
|
|
18
|
-
|
|
19
|
-
`),be=
|
|
20
|
-
`),
|
|
21
|
-
`+
|
|
17
|
+
*/var er;function mo(){return er||(er=1,process.env.NODE_ENV!=="production"&&(function(){var e=v,n=Symbol.for("react.element"),i=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),t=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),c=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),x=Symbol.for("react.offscreen"),w=Symbol.iterator,N="@@iterator";function E(d){if(d===null||typeof d!="object")return null;var I=w&&d[w]||d[N];return typeof I=="function"?I:null}var k=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function C(d){{for(var I=arguments.length,M=new Array(I>1?I-1:0),X=1;X<I;X++)M[X-1]=arguments[X];y("error",d,M)}}function y(d,I,M){{var X=k.ReactDebugCurrentFrame,ce=X.getStackAddendum();ce!==""&&(I+="%s",M=M.concat([ce]));var he=M.map(function(se){return String(se)});he.unshift("Warning: "+I),Function.prototype.apply.call(console[d],console,he)}}var T=!1,m=!1,R=!1,J=!1,F=!1,Q;Q=Symbol.for("react.module.reference");function B(d){return!!(typeof d=="string"||typeof d=="function"||d===r||d===t||F||d===o||d===u||d===f||J||d===x||T||m||R||typeof d=="object"&&d!==null&&(d.$$typeof===h||d.$$typeof===p||d.$$typeof===s||d.$$typeof===c||d.$$typeof===l||d.$$typeof===Q||d.getModuleId!==void 0))}function W(d,I,M){var X=d.displayName;if(X)return X;var ce=I.displayName||I.name||"";return ce!==""?M+"("+ce+")":M}function te(d){return d.displayName||"Context"}function P(d){if(d==null)return null;if(typeof d.tag=="number"&&C("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof d=="function")return d.displayName||d.name||null;if(typeof d=="string")return d;switch(d){case r:return"Fragment";case i:return"Portal";case t:return"Profiler";case o:return"StrictMode";case u:return"Suspense";case f:return"SuspenseList"}if(typeof d=="object")switch(d.$$typeof){case c:var I=d;return te(I)+".Consumer";case s:var M=d;return te(M._context)+".Provider";case l:return W(d,d.render,"ForwardRef");case p:var X=d.displayName||null;return X!==null?X:P(d.type)||"Memo";case h:{var ce=d,he=ce._payload,se=ce._init;try{return P(se(he))}catch{return null}}}return null}var D=Object.assign,re=0,ne,_e,G,A,g,b,H;function Y(){}Y.__reactDisabledLog=!0;function V(){{if(re===0){ne=console.log,_e=console.info,G=console.warn,A=console.error,g=console.group,b=console.groupCollapsed,H=console.groupEnd;var d={configurable:!0,enumerable:!0,value:Y,writable:!0};Object.defineProperties(console,{info:d,log:d,warn:d,error:d,group:d,groupCollapsed:d,groupEnd:d})}re++}}function Z(){{if(re--,re===0){var d={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:D({},d,{value:ne}),info:D({},d,{value:_e}),warn:D({},d,{value:G}),error:D({},d,{value:A}),group:D({},d,{value:g}),groupCollapsed:D({},d,{value:b}),groupEnd:D({},d,{value:H})})}re<0&&C("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var j=k.ReactCurrentDispatcher,$;function z(d,I,M){{if($===void 0)try{throw Error()}catch(ce){var X=ce.stack.trim().match(/\n( *(at )?)/);$=X&&X[1]||""}return`
|
|
18
|
+
`+$+d}}var ee=!1,q;{var ae=typeof WeakMap=="function"?WeakMap:Map;q=new ae}function O(d,I){if(!d||ee)return"";{var M=q.get(d);if(M!==void 0)return M}var X;ee=!0;var ce=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var he;he=j.current,j.current=null,V();try{if(I){var se=function(){throw Error()};if(Object.defineProperty(se.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(se,[])}catch(Ne){X=Ne}Reflect.construct(d,[],se)}else{try{se.call()}catch(Ne){X=Ne}d.call(se.prototype)}}else{try{throw Error()}catch(Ne){X=Ne}d()}}catch(Ne){if(Ne&&X&&typeof Ne.stack=="string"){for(var oe=Ne.stack.split(`
|
|
19
|
+
`),be=X.stack.split(`
|
|
20
|
+
`),ve=oe.length-1,Ce=be.length-1;ve>=1&&Ce>=0&&oe[ve]!==be[Ce];)Ce--;for(;ve>=1&&Ce>=0;ve--,Ce--)if(oe[ve]!==be[Ce]){if(ve!==1||Ce!==1)do if(ve--,Ce--,Ce<0||oe[ve]!==be[Ce]){var Re=`
|
|
21
|
+
`+oe[ve].replace(" at new "," at ");return d.displayName&&Re.includes("<anonymous>")&&(Re=Re.replace("<anonymous>",d.displayName)),typeof d=="function"&&q.set(d,Re),Re}while(ve>=1&&Ce>=0);break}}}finally{ee=!1,j.current=he,Z(),Error.prepareStackTrace=ce}var Qe=d?d.displayName||d.name:"",Ye=Qe?z(Qe):"";return typeof d=="function"&&q.set(d,Ye),Ye}function me(d,I,M){return O(d,!1)}function L(d){var I=d.prototype;return!!(I&&I.isReactComponent)}function xe(d,I,M){if(d==null)return"";if(typeof d=="function")return O(d,L(d));if(typeof d=="string")return z(d);switch(d){case u:return z("Suspense");case f:return z("SuspenseList")}if(typeof d=="object")switch(d.$$typeof){case l:return me(d.render);case p:return xe(d.type,I,M);case h:{var X=d,ce=X._payload,he=X._init;try{return xe(he(ce),I,M)}catch{}}}return""}var ge=Object.prototype.hasOwnProperty,we={},Ue=k.ReactDebugCurrentFrame;function Pe(d){if(d){var I=d._owner,M=xe(d.type,d._source,I?I.type:null);Ue.setExtraStackFrame(M)}else Ue.setExtraStackFrame(null)}function qt(d,I,M,X,ce){{var he=Function.call.bind(ge);for(var se in d)if(he(d,se)){var oe=void 0;try{if(typeof d[se]!="function"){var be=Error((X||"React class")+": "+M+" type `"+se+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof d[se]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw be.name="Invariant Violation",be}oe=d[se](I,se,X,M,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(ve){oe=ve}oe&&!(oe instanceof Error)&&(Pe(ce),C("%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).",X||"React class",M,se,typeof oe),Pe(null)),oe instanceof Error&&!(oe.message in we)&&(we[oe.message]=!0,Pe(ce),C("Failed %s type: %s",M,oe.message),Pe(null))}}}var Je=Array.isArray;function Ve(d){return Je(d)}function Zt(d){{var I=typeof Symbol=="function"&&Symbol.toStringTag,M=I&&d[Symbol.toStringTag]||d.constructor.name||"Object";return M}}function Wi(d){try{return Fn(d),!1}catch{return!0}}function Fn(d){return""+d}function Bn(d){if(Wi(d))return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Zt(d)),Fn(d)}var zn=k.ReactCurrentOwner,Gi={key:!0,ref:!0,__self:!0,__source:!0},Un,Yn;function qi(d){if(ge.call(d,"ref")){var I=Object.getOwnPropertyDescriptor(d,"ref").get;if(I&&I.isReactWarning)return!1}return d.ref!==void 0}function Zi(d){if(ge.call(d,"key")){var I=Object.getOwnPropertyDescriptor(d,"key").get;if(I&&I.isReactWarning)return!1}return d.key!==void 0}function Ji(d,I){typeof d.ref=="string"&&zn.current}function Xi(d,I){{var M=function(){Un||(Un=!0,C("%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)",I))};M.isReactWarning=!0,Object.defineProperty(d,"key",{get:M,configurable:!0})}}function Qi(d,I){{var M=function(){Yn||(Yn=!0,C("%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)",I))};M.isReactWarning=!0,Object.defineProperty(d,"ref",{get:M,configurable:!0})}}var eo=function(d,I,M,X,ce,he,se){var oe={$$typeof:n,type:d,key:I,ref:M,props:se,_owner:he};return oe._store={},Object.defineProperty(oe._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(oe,"_self",{configurable:!1,enumerable:!1,writable:!1,value:X}),Object.defineProperty(oe,"_source",{configurable:!1,enumerable:!1,writable:!1,value:ce}),Object.freeze&&(Object.freeze(oe.props),Object.freeze(oe)),oe};function to(d,I,M,X,ce){{var he,se={},oe=null,be=null;M!==void 0&&(Bn(M),oe=""+M),Zi(I)&&(Bn(I.key),oe=""+I.key),qi(I)&&(be=I.ref,Ji(I,ce));for(he in I)ge.call(I,he)&&!Gi.hasOwnProperty(he)&&(se[he]=I[he]);if(d&&d.defaultProps){var ve=d.defaultProps;for(he in ve)se[he]===void 0&&(se[he]=ve[he])}if(oe||be){var Ce=typeof d=="function"?d.displayName||d.name||"Unknown":d;oe&&Xi(se,Ce),be&&Qi(se,Ce)}return eo(d,oe,be,ce,X,zn.current,se)}}var Jt=k.ReactCurrentOwner,Kn=k.ReactDebugCurrentFrame;function Xe(d){if(d){var I=d._owner,M=xe(d.type,d._source,I?I.type:null);Kn.setExtraStackFrame(M)}else Kn.setExtraStackFrame(null)}var Xt;Xt=!1;function Qt(d){return typeof d=="object"&&d!==null&&d.$$typeof===n}function Wn(){{if(Jt.current){var d=P(Jt.current.type);if(d)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+d+"`."}return""}}function no(d){return""}var Gn={};function ro(d){{var
|
|
23
|
+
Check the render method of \``+d+"`."}return""}}function no(d){return""}var Gn={};function ro(d){{var I=Wn();if(!I){var M=typeof d=="string"?d:d.displayName||d.name;M&&(I=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+
|
|
25
|
+
Check the top-level render call using <`+M+">.")}return I}}function qn(d,I){{if(!d._store||d._store.validated||d.key!=null)return;d._store.validated=!0;var M=ro(I);if(Gn[M])return;Gn[M]=!0;var X="";d&&d._owner&&d._owner!==Jt.current&&(X=" It was passed a child from "+P(d._owner.type)+"."),Xe(d),C('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',M,X),Xe(null)}}function Zn(d,I){{if(typeof d!="object")return;if(Ve(d))for(var M=0;M<d.length;M++){var X=d[M];Qt(X)&&qn(X,I)}else if(Qt(d))d._store&&(d._store.validated=!0);else if(d){var ce=E(d);if(typeof ce=="function"&&ce!==d.entries)for(var he=ce.call(d),se;!(se=he.next()).done;)Qt(se.value)&&qn(se.value,I)}}}function io(d){{var I=d.type;if(I==null||typeof I=="string")return;var M;if(typeof I=="function")M=I.propTypes;else if(typeof I=="object"&&(I.$$typeof===l||I.$$typeof===p))M=I.propTypes;else return;if(M){var X=P(I);qt(M,d.props,"prop",X,d)}else if(I.PropTypes!==void 0&&!Xt){Xt=!0;var ce=P(I);C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",ce||"Unknown")}typeof I.getDefaultProps=="function"&&!I.getDefaultProps.isReactClassApproved&&C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function oo(d){{for(var I=Object.keys(d.props),M=0;M<I.length;M++){var X=I[M];if(X!=="children"&&X!=="key"){Xe(d),C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",X),Xe(null);break}}d.ref!==null&&(Xe(d),C("Invalid attribute `ref` supplied to `React.Fragment`."),Xe(null))}}var Jn={};function Xn(d,I,M,X,ce,he){{var se=B(d);if(!se){var oe="";(d===void 0||typeof d=="object"&&d!==null&&Object.keys(d).length===0)&&(oe+=" 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 be=no();be?oe+=be:oe+=Wn();var ve;d===null?ve="null":Ve(d)?ve="array":d!==void 0&&d.$$typeof===n?(ve="<"+(P(d.type)||"Unknown")+" />",oe=" Did you accidentally export a JSX literal instead of a component?"):ve=typeof d,C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",ve,oe)}var Ce=to(d,I,M,ce,he);if(Ce==null)return Ce;if(se){var Re=I.children;if(Re!==void 0)if(X)if(Ve(Re)){for(var Qe=0;Qe<Re.length;Qe++)Zn(Re[Qe],d);Object.freeze&&Object.freeze(Re)}else C("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 Zn(Re,d)}if(ge.call(I,"key")){var Ye=P(d),Ne=Object.keys(I).filter(function(fo){return fo!=="key"}),en=Ne.length>0?"{key: someKey, "+Ne.join(": ..., ")+": ...}":"{key: someKey}";if(!Jn[Ye+en]){var uo=Ne.length>0?"{"+Ne.join(": ..., ")+": ...}":"{}";C(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,en,Ye,uo,Ye),Jn[Ye+en]=!0}}return d===r?oo(Ce):io(Ce),Ce}}function so(d,b,A){return Xn(d,b,A,!0)}function ao(d,b,A){return Xn(d,b,A,!1)}var co=ao,lo=so;at.Fragment=r,at.jsx=co,at.jsxs=lo})()),at}var tr;function go(){return tr||(tr=1,process.env.NODE_ENV==="production"?Ct.exports=ho():Ct.exports=mo()),Ct.exports}var a=go();const vo="app-module_container",_o="app-module_loader",nr={container:vo,loader:_o};function Co(e){const[n,i]=g.useState(!1),r=g.useMemo(()=>new IntersectionObserver(([o])=>{o.isIntersecting&&(i(!0),r.disconnect())}),[e]);return g.useEffect(()=>{if(e.current)return r.observe(e.current),()=>r.disconnect()},[e.current]),n}function Eo(e){const n=e;return["nl","nl-be","nl-nl"].includes(n)?"nl":["en","en-us","en-eg","en-au","en-gb","en-ca","en-nz","en-ie","en-za","en-jm","en-bz","en-tt"].includes(n)?"en":["de","de-ch","de-at","de-lu","de-li","de-de"].includes(n)?"de":["fr","fr-be","fr-ca","fr-fr","fr-lu","fr-ch"].includes(n)?"fr":["it","it-ch","it-it"].includes(n)?"it":["es","es-ar","es-bo","es-cl","es-co","es-cr","es-do","es-ec","es-sv","es-gt","es-hn","es-mx","es-ni","es-pa","es-py","es-pe","es-pr","es-es","es-uy","es-ve"].includes(n)?"es":"en"}const yo={"search.placeholder":"Enter a location...","cdrPrice.flatFee":"additional fee {{total}} / session","tariffPriceComponent.dynamicTariffHeader":"Dynamic Tariff - {{date}}","tariffPriceComponent.flat":"{{total}} / session","tariffPriceComponent.time":"{{total}} / hour","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / hour idle fee","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. wait time before idle fee","tariffPriceComponent.noTariff":"No tariff available","tariffPriceComponent.baseTariff":"Base Tariff","tariffPriceComponent.active":"Active now","filters.header":"Filters","filters.dcChargers":"Fast Chargers","filters.efluxChargers":"E-Flux Chargers","filters.noAdditionalFee":"Without additional fee per session","filters.available":"Available","filters.charging":"Charging","filters.notAvailable":"Not Available","filters.chargingPower":"Charging Power [kW]","filters.connectorType":"Connector Type","filters.apply":"Apply Filters","filters.clearAll":"Clear All Filters","filters.onlyShow":"Only Show","filters.statusHeading":"Status","evse.statusAvailable":"Available","evse.statusCharging":"Charging","evse.statusUnavailable":"Unavailable","evse.statusRemoved":"Removed","evse.statusPlanned":"Planned","evse.statusReserved":"Reserved","evse.statusInoperative":"Inoperative","evse.statusOutOfOrder":"Out of Order","evse.statusError":"Error","evse.statusUnknown":"Unknown","locationType.onStreet":"On Street","locationType.parkingGarage":"Parking Garage","locationType.undergroundGarage":"Underground Garage","locationType.parkingLot":"Parking Lot","locationType.other":"Other","locationType.unknown":"Unknown","tariffPriceComponent.viewTariff":"View Tariff notes","tariffNote.subHeader":"Tariff notes","tariffNote.eFluxScheduledTariffNote":"A scheduled tariff overrides base tariff prices for specific time period.","tariffNote.dynamicScheduledTariffNote":"Dynamic price is adjusted automatically based on energy market price (1 hour interval).","tariffNote.scheduledTariffNote":"A scheduled tariff overrides base tariff prices for specific time period.","tariffNote.baseTariffNote":"Tariffs shown here have been sent to E-Flux by roaming partner. Accuracy may vary depending on provider.","evse.pricing":"Pricing","dynamicTariffs.subHeader":"Hourly Prices","location.viewAllHourlyPrices":"View All Hourly Prices","backButton.backTo":"Back To"},To={"search.placeholder":"Voer een locatie in...","cdrPrice.flatFee":"Extra vergoeding {{total}} / sessie","tariffPriceComponent.dynamicTariffHeader":"Dynamisch Tarief - {{date}}","tariffPriceComponent.flat":"{{total}} / sessie","tariffPriceComponent.time":"{{total}} / uur","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / uur blokkeertarief","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. wachttijd voor blokkeertarief","tariffPriceComponent.noTariff":"Geen beschikbaar tarief","tariffPriceComponent.baseTariff":"Basistarief","tariffPriceComponent.active":"Nu actief","filters.header":"Filters","filters.dcChargers":"DC-laders","filters.efluxChargers":"E-Flux-laders","filters.noAdditionalFee":"Zonder extra kosten per sessie","filters.available":"Beschikbaar","filters.charging":"Laden","filters.notAvailable":"Niet beschikbaar","filters.chargingPower":"Laadvermogen [kW]","filters.connectorType":"Aansluitingstype","filters.apply":"Filters toepassen","filters.clearAll":"Alle filters wissen","filters.onlyShow":"Alleen tonen","filters.statusHeading":"Status","evse.statusAvailable":"Beschikbaar","evse.statusCharging":"Laden","evse.statusUnavailable":"Niet beschikbaar","evse.statusError":"Fout","evse.statusRemoved":"Verwijderd","evse.statusPlanned":"Gepland","evse.statusReserved":"Gereserveerd","evse.statusInoperative":"Inoperative","evse.statusOutOfOrder":"Uit van orde","evse.statusUnknown":"Onbekend","locationType.onStreet":"Op straat","locationType.parkingGarage":"Parkeergarage","locationType.undergroundGarage":"Ondergrondse garage","locationType.parkingLot":"Parkeerterrein","locationType.other":"Anders","locationType.unknown":"Onbekend","tariffPriceComponent.viewTariff":"Tariefnotitie bekijken","tariffNote.subHeader":"Tariefnotities","tariffNote.eFluxScheduledTariffNote":"Een gepland tarief overschrijft de basis tariefprijzen voor een specifieke periode.","tariffNote.dynamicScheduledTariffNote":"De dynamische prijs wordt automatisch aangepast op basis van de energiemarktprijs (interval van 1 uur).","tariffNote.scheduledTariffNote":"Een gepland tarief overschrijft de basis tariefprijzen voor een specifieke periode.","tariffNote.baseTariffNote":"De hier getoonde tarieven zijn door de roamingpartner aan E-Flux verstrekt. De nauwkeurigheid kan variëren afhankelijk van de aanbieder.","evse.pricing":"Tarieven","dynamicTariffs.subHeader":"Uurtarieven","location.viewAllHourlyPrices":"Bekijk Alle Uurprijzen","backButton.backTo":"Terug Naar"},xo={"search.placeholder":"Geben Sie einen Ort ein...","cdrPrice.flatFee":"Zusätzliche Gebühr {{total}} / Sitzung","tariffPriceComponent.dynamicTariffHeader":"Dynamischer Tarif - {{date}}","tariffPriceComponent.flat":"{{total}} / Sitzung","tariffPriceComponent.time":"{{total}} / Stunde","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / Stunde Blockiergebühr","tariffPriceComponent.parkingTimeWait":"{{minutes}} Min. Wartezeit vor der Blockiergebühr","tariffPriceComponent.noTariff":"Kein Tarif verfügbar","tariffPriceComponent.baseTariff":"Grundtarif","tariffPriceComponent.active":"Aktuell aktiv","filters.header":"Filter","filters.dcChargers":"Gleichstrom-Ladegeräte","filters.efluxChargers":"E-Flux-Ladegeräte","filters.noAdditionalFee":"Ohne zusätzliche Gebühr pro Sitzung","filters.available":"Verfügbar","filters.charging":"Lädt","filters.notAvailable":"Nicht verfügbar","filters.chargingPower":"Ladeleistung [kW]","filters.connectorType":"Steckertyp","filters.apply":"Filter anwenden","filters.clearAll":"Alle Filter löschen","filters.onlyShow":"Nur anzeigen","filters.statusHeading":"Status","evse.statusAvailable":"Verfügbar","evse.statusCharging":"Lädt","evse.statusUnavailable":"Nicht verfügbar","evse.statusRemoved":"Entfernt","evse.statusPlanned":"Geplant","evse.statusReserved":"Reserviert","evse.statusInoperative":"Inoperative","evse.statusOutOfOrder":"Ausgeschaltet","evse.statusError":"Fehler","evse.statusUnknown":"Unbekannt","evse.pricing":"Preisbildung","locationType.onStreet":"Straße","locationType.parkingGarage":"Parkhaus","locationType.undergroundGarage":"Tiefgarage","locationType.parkingLot":"Parkplatz","locationType.other":"Andere","locationType.unknown":"Unbekannt","tariffPriceComponent.viewTariff":"Tarif anzeigen","tariffNote.subHeader":"Tarifhinweise","tariffNote.eFluxScheduledTariffNote":"Ein geplanter Tarif überschreibt die Basistarifpreise für einen bestimmten Zeitraum.","tariffNote.dynamicScheduledTariffNote":"Der dynamische Preis wird automatisch basierend auf dem Energiepreis auf dem Markt angepasst (im Intervall von 1 Stunde).","tariffNote.scheduledTariffNote":"Ein geplanter Tarif überschreibt die Basistarifpreise für einen bestimmten Zeitraum.","tariffNote.baseTariffNote":"Die hier angezeigten Tarife wurden von einem Roaming-Partner an E-Flux gesendet. Die Genauigkeit kann je nach Anbieter variieren.","dynamicTariffs.subHeader":"Stundentarife","location.viewAllHourlyPrices":"Alle Stundenpreise anzeigen","backButton.backTo":"Zurück zu"},bo={"search.placeholder":"Entrez un lieu...","cdrPrice.flatFee":"Frais supplémentaires {{total}} / session","tariffPriceComponent.dynamicTariffHeader":"Tarif Dynamique - {{date}}","tariffPriceComponent.flat":"{{total}} / session","tariffPriceComponent.time":"{{total}} / heure","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / frais d'occupation par heure","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. avant frais d'occupation","tariffPriceComponent.noTariff":"Aucun tarif disponible","tariffPriceComponent.baseTariff":"Tarif de base","tariffPriceComponent.active":"Actuellement actif","filters.header":"Filtres","filters.dcChargers":"Chargeurs à courant continu","filters.efluxChargers":"Chargeurs E-Flux","filters.noAdditionalFee":"Sans frais supplémentaires par séance","filters.available":"Disponible","filters.charging":"En charge","filters.notAvailable":"Indisponible","filters.chargingPower":"Puissance de charge [kW]","filters.connectorType":"Type de connecteur","filters.apply":"Appliquer les filtres","filters.clearAll":"Effacer tous les filtres","filters.onlyShow":"Afficher uniquement","filters.statusHeading":"Statut","evse.statusAvailable":"Disponible","evse.statusCharging":"En charge","evse.statusUnavailable":"Indisponible","evse.statusRemoved":"Supprimé","evse.statusPlanned":"Planifié","evse.statusReserved":"Réservé","evse.statusInoperative":"Hors service","evse.statusOutOfOrder":"En panne","evse.statusError":"Erreur","evse.statusUnknown":"Inconnu","evse.pricing":"Tarification","locationType.onStreet":"Dans la rue","locationType.parkingGarage":"Parking couvert","locationType.undergroundGarage":"Parking souterrain","locationType.parkingLot":"Parking","locationType.other":"Autre","locationType.unknown":"Inconnu","tariffPriceComponent.viewTariff":"Voir le tarif","tariffNote.subHeader":"Notes tarifaires","tariffNote.eFluxScheduledTariffNote":"Un tarif programmé remplace les prix de base du tarif pour une période spécifique.","tariffNote.dynamicScheduledTariffNote":"Le prix dynamique est ajusté automatiquement en fonction du prix du marché de l'énergie (intervalle d'une heure).","tariffNote.scheduledTariffNote":"Un tarif programmé remplace les prix de base du tarif pour une période spécifique.","tariffNote.baseTariffNote":"Les tarifs affichés ici ont été transmis à E-Flux par le partenaire d'itinérance. La précision peut varier en fonction du fournisseur.","dynamicTariffs.subHeader":"Tarifs horaires","location.viewAllHourlyPrices":"Voir tous les tarifs horaires","backButton.backTo":"Retour à"},Io={"search.placeholder":"Inserisci una posizione...","cdrPrice.flatFee":"Costo aggiuntivo {{total}} / sessione","tariffPriceComponent.dynamicTariffHeader":"Tariffa dinamica - {{date}}","tariffPriceComponent.flat":"{{total}} / sessione","tariffPriceComponent.time":"{{total}} / ora","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / ora tariffa di inattività","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. tempo di attesa prima della tariffa di inattività","tariffPriceComponent.noTariff":"Nessuna tariffa disponibile","tariffPriceComponent.baseTariff":"Tariffa base","tariffPriceComponent.active":"Attivo ora","filters.header":"Filtri","filters.dcChargers":"Caricabatterie DC","filters.efluxChargers":"Caricabatterie E-Flux","filters.noAdditionalFee":"Senza costi aggiuntivi per sessione","filters.available":"Disponibile","filters.charging":"In carica","filters.notAvailable":"Non disponibile","filters.chargingPower":"Potenza di ricarica [kW]","filters.connectorType":"Tipo di connettore","filters.apply":"Applica filtri","filters.clearAll":"Cancella tutti i filtri","filters.onlyShow":"Mostra solo","filters.statusHeading":"Stato","evse.statusAvailable":"Disponibile","evse.statusCharging":"In carica","evse.statusUnavailable":"Non disponibile","evse.statusRemoved":"Rimossa","evse.statusPlanned":"Pianificata","evse.statusReserved":"Réservé","evse.statusInoperative":"Inoperativo","evse.statusOutOfOrder":"Fuori servizio","evse.statusError":"Errore","evse.statusUnknown":"Sconosciuto","locationType.onStreet":"In strada","locationType.parkingGarage":"Garage per il parcheggio","locationType.undergroundGarage":"Garage sotterraneo","locationType.parkingLot":"Parcheggio","locationType.other":"Altro","locationType.unknown":"Sconosciuto","tariffPriceComponent.viewTariff":"Visualizza note tariffarie","tariffNote.subHeader":"Note tariffarie","tariffNote.eFluxScheduledTariffNote":"Una tariffa programmata sostituisce i prezzi della tariffa base per un periodo di tempo specifico.","tariffNote.dynamicScheduledTariffNote":"Il prezzo dinamico si regola automaticamente in base al prezzo del mercato dell'energia (intervallo di 1 ora).","tariffNote.scheduledTariffNote":"Una tariffa programmata sostituisce i prezzi della tariffa base per un periodo di tempo specifico.","tariffNote.baseTariffNote":"Le tariffe mostrate qui sono state inviate a E-Flux dal partner di roaming. L'accuratezza può variare a seconda del fornitore.","evse.pricing":"Prezzi","dynamicTariffs.subHeader":"Prezzi orari","location.viewAllHourlyPrices":"Visualizza tutti i prezzi orari","backButton.backTo":"Torna a"},wo={"search.placeholder":"Ingrese una ubicación...","cdrPrice.flatFee":"Tarifa adicional {{total}} / sesión","tariffPriceComponent.dynamicTariffHeader":"Tarifa Dinámica - {{date}}","tariffPriceComponent.flat":"{{total}} / sesión","tariffPriceComponent.time":"{{total}} / hora","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / hora tarifa de inactividad","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. tiempo de espera antes de la tarifa de inactividad","tariffPriceComponent.noTariff":"Tarifa no disponible","tariffPriceComponent.baseTariff":"Tarifa Base","tariffPriceComponent.active":"Activo ahora","filters.header":"Filtros","filters.dcChargers":"Cargadores DC","filters.efluxChargers":"Cargadores E-Flux","filters.noAdditionalFee":"Sin tarifa adicional por sesión","filters.available":"Disponible","filters.charging":"Cargando","filters.notAvailable":"No Disponible","filters.chargingPower":"Potencia de Carga [kW]","filters.connectorType":"Tipo de Conector","filters.apply":"Aplicar Filtros","filters.clearAll":"Limpiar Todos los Filtros","filters.onlyShow":"Mostrar Solo","evse.statusRemoved":"Eliminado","evse.statusPlanned":"Planificado","evse.statusReserved":"Reservado","evse.statusInoperative":"Fuera de servicio","evse.statusOutOfOrder":"Averiado","filters.statusHeading":"Estado","evse.statusAvailable":"Disponible","evse.statusCharging":"Cargando","evse.statusUnavailable":"No Disponible","evse.statusError":"Error","evse.statusUnknown":"Desconocido","locationType.onStreet":"En la calle","locationType.parkingGarage":"Garaje para Estacionar","locationType.undergroundGarage":"Garaje Subterráneo","locationType.parkingLot":"Estacionamiento","locationType.other":"Otro","locationType.unknown":"Desconocido","tariffPriceComponent.viewTariff":"Ver notas de tarifas","tariffNote.subHeader":"Notas de Tarifas","tariffNote.eFluxScheduledTariffNote":"Una tarifa programada anula los precios de la tarifa base para un período de tiempo específico.","tariffNote.dynamicScheduledTariffNote":"El precio dinámico se ajusta automáticamente según el precio del mercado de la energía (intervalo de 1 hora).","tariffNote.scheduledTariffNote":"Una tarifa programada anula los precios de la tarifa base para un período de tiempo específico.","tariffNote.baseTariffNote":"Las tarifas mostradas aquí han sido enviadas a E-Flux por el socio de roaming. La precisión puede variar según el proveedor.","evse.pricing":"Precios","dynamicTariffs.subHeader":"Precios por Hora","location.viewAllHourlyPrices":"Ver Todos los Precios por Hora","backButton.backTo":"Volver a"},No={en:yo,nl:To,de:xo,fr:bo,it:Io,es:wo};async function Ut(e,n){try{const i=await fetch(e,{method:"GET",headers:{"Content-Type":"application/json",...n.version&&{version:n.version},...n.authorization&&n.version==="v2"&&{Authorization:`Bearer ${n.authorization}`}},...n});switch(i.status){case 200:return i.json();case 400:throw new Error("Bad request");case 404:throw new Error("Not Found");case 500:throw new Error("Server Error");case 503:throw new Error("Timeout!");default:throw new Error(`Unexpected status: ${i.status}`)}}catch(i){if(i instanceof DOMException)return null;throw i}}async function Oo(e,n,i,r,{precision:o,bbox:t,...s}){return Ut(`${e}/1/map/search`,{method:"POST",version:n,authorization:i,body:JSON.stringify({gridPrecision:o,bbox:t,...r?.length>0&&{locationIds:r},...s,...s?.operatorOnly?{operator:[s.operatorOnly]}:{}})})}async function So(e,n,i,{origin:r,ids:o}){return Ut(`${e}/1/map/tariff`,{method:"POST",version:n,authorization:i,body:JSON.stringify({connection_id:r.connectionId,country_code:r.countryCode,party_id:r.partyId,tariff_ids:o})})}async function Do(e,n,i,{ids:r,status:o}){return Ut(`${e}/1/map/locations`,{method:"POST",version:n,authorization:i,body:JSON.stringify({ids:r,...n==="v2"?{status:o}:{}})})}async function Po(e,n,i){return(await Ut(`${e}/1/map/config`,{version:n,authorization:i}))?.data}const Cn=g.createContext({isReady:!1,setPlace:()=>{},t:e=>`Translate ${e}`,language:"en"}),Ro=({children:e,...n})=>{const[i,r]=g.useState(n.options),[o,t]=g.useState({preferredOperators:n.options.preferredOperators,showOperatorOnly:n.options.showOperatorOnly,showNoAdditionalFeeFilter:n.options.showNoAdditionalFeeFilter,showPublishingModeFilter:n.options.showPublishingModeFilter}),[s,c]=g.useState(),[l,u]=g.useState(),[f,p]=g.useState(n.options.position),[h,x]=g.useState({}),[w,O]=g.useState([n.options.locationId].filter(Boolean)),[E,M]=g.useState([]),[_,y]=g.useState({type:"success"}),T=window.location.search.includes("debug=true");T&&console.log("map-context options",n.options);const m=g.useMemo(()=>Eo(n.options.language||"en"),[n.options.language]),R=g.useMemo(()=>(ne,V)=>No[m][ne].replace(/\{\{(\w+)\}\}/g,($,C)=>V[C]),[m]),J=n.options?.apiRoot||"https://api.road.io";let L=n.options.version,X=n.options.authorization;const W=window.location.search.split("map_key=")[1];W&&(X=W,L="v2");const q=Oo.bind(null,J,L,X,n.options.limitToLocationIds||[]),te=Do.bind(null,J,L,X),P=So.bind(null,J,L,X);async function D({ids:ne,status:V}){y({type:"loading"});try{const{data:$}=await te({ids:ne,...L==="v2"?{status:V}:{}});return M($.filter(C=>C?.evses?.length)),y({type:"success"}),$}catch($){y({type:"error",error:$})}}g.useEffect(()=>{n.options.locationId&&D({ids:[n.options.locationId],status:h.status}).then(ne=>{if(ne?.length){const V=ne[0];V.geoLocation?.coordinates&&p({lng:V.geoLocation?.coordinates[0],lat:V.geoLocation?.coordinates[1]})}})},[n.options.locationId]),g.useEffect(()=>{Po(J,L,X).then(ne=>{T&&console.log("retrieved remote config",ne),t({...ne,...o}),r({googleApiKey:ne.googleMapsApiKey,...i,...ne}),!i.locationId&&!i?.position?.lat&&ne.ipLatitude?(T&&console.debug("setting position from ip latitude and longitude"),p({lat:ne.ipLatitude,lng:ne.ipLongitude})):i.locationId||(T&&console.debug("setting position from options position"),p(i?.position?.lat?i.position:{lat:52.3676,lng:4.9041}))}).catch(ne=>c(ne))},[]),g.useEffect(()=>{w?.length&&D({ids:w,status:h.status})},[w]),g.useEffect(()=>{const{theming:ne,shadowRoot:V}=n.options;if(V){const $=V.querySelectorAll("#road-map-styles")[0]||document.createElement("style");$.setAttribute("type","text/css"),$.setAttribute("id","road-map-styles"),$.innerHTML=`
|
|
30
|
+
<%s key={someKey} {...props} />`,en,Ye,uo,Ye),Jn[Ye+en]=!0}}return d===r?oo(Ce):io(Ce),Ce}}function so(d,I,M){return Xn(d,I,M,!0)}function ao(d,I,M){return Xn(d,I,M,!1)}var co=ao,lo=so;at.Fragment=r,at.jsx=co,at.jsxs=lo})()),at}var tr;function go(){return tr||(tr=1,process.env.NODE_ENV==="production"?Ct.exports=ho():Ct.exports=mo()),Ct.exports}var a=go();const vo="app-module_container",_o="app-module_loader",nr={container:vo,loader:_o};function Co(e){const[n,i]=v.useState(!1),r=v.useMemo(()=>new IntersectionObserver(([o])=>{o.isIntersecting&&(i(!0),r.disconnect())}),[e]);return v.useEffect(()=>{if(e.current)return r.observe(e.current),()=>r.disconnect()},[e.current]),n}function Eo(e){const n=e;return["nl","nl-be","nl-nl"].includes(n)?"nl":["en","en-us","en-eg","en-au","en-gb","en-ca","en-nz","en-ie","en-za","en-jm","en-bz","en-tt"].includes(n)?"en":["de","de-ch","de-at","de-lu","de-li","de-de"].includes(n)?"de":["fr","fr-be","fr-ca","fr-fr","fr-lu","fr-ch"].includes(n)?"fr":["it","it-ch","it-it"].includes(n)?"it":["es","es-ar","es-bo","es-cl","es-co","es-cr","es-do","es-ec","es-sv","es-gt","es-hn","es-mx","es-ni","es-pa","es-py","es-pe","es-pr","es-es","es-uy","es-ve"].includes(n)?"es":"en"}const yo={"search.placeholder":"Enter a location...","cdrPrice.flatFee":"additional fee {{total}} / session","tariffPriceComponent.dynamicTariffHeader":"Dynamic Tariff - {{date}}","tariffPriceComponent.flat":"{{total}} / session","tariffPriceComponent.time":"{{total}} / hour","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / hour idle fee","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. wait time before idle fee","tariffPriceComponent.noTariff":"No tariff available","tariffPriceComponent.baseTariff":"Base Tariff","tariffPriceComponent.active":"Active now","filters.header":"Filters","filters.dcChargers":"Fast Chargers","filters.efluxChargers":"E-Flux Chargers","filters.noAdditionalFee":"Without additional fee per session","filters.available":"Available","filters.charging":"Charging","filters.notAvailable":"Not Available","filters.chargingPower":"Charging Power [kW]","filters.connectorType":"Connector Type","filters.apply":"Apply Filters","filters.clearAll":"Clear All Filters","filters.onlyShow":"Only Show","filters.statusHeading":"Status","evse.statusAvailable":"Available","evse.statusCharging":"Charging","evse.statusUnavailable":"Unavailable","evse.statusRemoved":"Removed","evse.statusPlanned":"Planned","evse.statusReserved":"Reserved","evse.statusInoperative":"Inoperative","evse.statusOutOfOrder":"Out of Order","evse.statusError":"Error","evse.statusUnknown":"Unknown","locationType.onStreet":"On Street","locationType.parkingGarage":"Parking Garage","locationType.undergroundGarage":"Underground Garage","locationType.parkingLot":"Parking Lot","locationType.other":"Other","locationType.unknown":"Unknown","tariffPriceComponent.viewTariff":"View Tariff notes","tariffNote.subHeader":"Tariff notes","tariffNote.eFluxScheduledTariffNote":"A scheduled tariff overrides base tariff prices for specific time period.","tariffNote.dynamicScheduledTariffNote":"Dynamic price is adjusted automatically based on energy market price (1 hour interval).","tariffNote.scheduledTariffNote":"A scheduled tariff overrides base tariff prices for specific time period.","tariffNote.baseTariffNote":"Tariffs shown here have been sent to E-Flux by roaming partner. Accuracy may vary depending on provider.","evse.pricing":"Pricing","dynamicTariffs.subHeader":"Hourly Prices","location.viewAllHourlyPrices":"View All Hourly Prices","backButton.backTo":"Back To"},To={"search.placeholder":"Voer een locatie in...","cdrPrice.flatFee":"Extra vergoeding {{total}} / sessie","tariffPriceComponent.dynamicTariffHeader":"Dynamisch Tarief - {{date}}","tariffPriceComponent.flat":"{{total}} / sessie","tariffPriceComponent.time":"{{total}} / uur","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / uur blokkeertarief","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. wachttijd voor blokkeertarief","tariffPriceComponent.noTariff":"Geen beschikbaar tarief","tariffPriceComponent.baseTariff":"Basistarief","tariffPriceComponent.active":"Nu actief","filters.header":"Filters","filters.dcChargers":"DC-laders","filters.efluxChargers":"E-Flux-laders","filters.noAdditionalFee":"Zonder extra kosten per sessie","filters.available":"Beschikbaar","filters.charging":"Laden","filters.notAvailable":"Niet beschikbaar","filters.chargingPower":"Laadvermogen [kW]","filters.connectorType":"Aansluitingstype","filters.apply":"Filters toepassen","filters.clearAll":"Alle filters wissen","filters.onlyShow":"Alleen tonen","filters.statusHeading":"Status","evse.statusAvailable":"Beschikbaar","evse.statusCharging":"Laden","evse.statusUnavailable":"Niet beschikbaar","evse.statusError":"Fout","evse.statusRemoved":"Verwijderd","evse.statusPlanned":"Gepland","evse.statusReserved":"Gereserveerd","evse.statusInoperative":"Inoperative","evse.statusOutOfOrder":"Uit van orde","evse.statusUnknown":"Onbekend","locationType.onStreet":"Op straat","locationType.parkingGarage":"Parkeergarage","locationType.undergroundGarage":"Ondergrondse garage","locationType.parkingLot":"Parkeerterrein","locationType.other":"Anders","locationType.unknown":"Onbekend","tariffPriceComponent.viewTariff":"Tariefnotitie bekijken","tariffNote.subHeader":"Tariefnotities","tariffNote.eFluxScheduledTariffNote":"Een gepland tarief overschrijft de basis tariefprijzen voor een specifieke periode.","tariffNote.dynamicScheduledTariffNote":"De dynamische prijs wordt automatisch aangepast op basis van de energiemarktprijs (interval van 1 uur).","tariffNote.scheduledTariffNote":"Een gepland tarief overschrijft de basis tariefprijzen voor een specifieke periode.","tariffNote.baseTariffNote":"De hier getoonde tarieven zijn door de roamingpartner aan E-Flux verstrekt. De nauwkeurigheid kan variëren afhankelijk van de aanbieder.","evse.pricing":"Tarieven","dynamicTariffs.subHeader":"Uurtarieven","location.viewAllHourlyPrices":"Bekijk Alle Uurprijzen","backButton.backTo":"Terug Naar"},xo={"search.placeholder":"Geben Sie einen Ort ein...","cdrPrice.flatFee":"Zusätzliche Gebühr {{total}} / Sitzung","tariffPriceComponent.dynamicTariffHeader":"Dynamischer Tarif - {{date}}","tariffPriceComponent.flat":"{{total}} / Sitzung","tariffPriceComponent.time":"{{total}} / Stunde","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / Stunde Blockiergebühr","tariffPriceComponent.parkingTimeWait":"{{minutes}} Min. Wartezeit vor der Blockiergebühr","tariffPriceComponent.noTariff":"Kein Tarif verfügbar","tariffPriceComponent.baseTariff":"Grundtarif","tariffPriceComponent.active":"Aktuell aktiv","filters.header":"Filter","filters.dcChargers":"Gleichstrom-Ladegeräte","filters.efluxChargers":"E-Flux-Ladegeräte","filters.noAdditionalFee":"Ohne zusätzliche Gebühr pro Sitzung","filters.available":"Verfügbar","filters.charging":"Lädt","filters.notAvailable":"Nicht verfügbar","filters.chargingPower":"Ladeleistung [kW]","filters.connectorType":"Steckertyp","filters.apply":"Filter anwenden","filters.clearAll":"Alle Filter löschen","filters.onlyShow":"Nur anzeigen","filters.statusHeading":"Status","evse.statusAvailable":"Verfügbar","evse.statusCharging":"Lädt","evse.statusUnavailable":"Nicht verfügbar","evse.statusRemoved":"Entfernt","evse.statusPlanned":"Geplant","evse.statusReserved":"Reserviert","evse.statusInoperative":"Inoperative","evse.statusOutOfOrder":"Ausgeschaltet","evse.statusError":"Fehler","evse.statusUnknown":"Unbekannt","evse.pricing":"Preisbildung","locationType.onStreet":"Straße","locationType.parkingGarage":"Parkhaus","locationType.undergroundGarage":"Tiefgarage","locationType.parkingLot":"Parkplatz","locationType.other":"Andere","locationType.unknown":"Unbekannt","tariffPriceComponent.viewTariff":"Tarif anzeigen","tariffNote.subHeader":"Tarifhinweise","tariffNote.eFluxScheduledTariffNote":"Ein geplanter Tarif überschreibt die Basistarifpreise für einen bestimmten Zeitraum.","tariffNote.dynamicScheduledTariffNote":"Der dynamische Preis wird automatisch basierend auf dem Energiepreis auf dem Markt angepasst (im Intervall von 1 Stunde).","tariffNote.scheduledTariffNote":"Ein geplanter Tarif überschreibt die Basistarifpreise für einen bestimmten Zeitraum.","tariffNote.baseTariffNote":"Die hier angezeigten Tarife wurden von einem Roaming-Partner an E-Flux gesendet. Die Genauigkeit kann je nach Anbieter variieren.","dynamicTariffs.subHeader":"Stundentarife","location.viewAllHourlyPrices":"Alle Stundenpreise anzeigen","backButton.backTo":"Zurück zu"},bo={"search.placeholder":"Entrez un lieu...","cdrPrice.flatFee":"Frais supplémentaires {{total}} / session","tariffPriceComponent.dynamicTariffHeader":"Tarif Dynamique - {{date}}","tariffPriceComponent.flat":"{{total}} / session","tariffPriceComponent.time":"{{total}} / heure","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / frais d'occupation par heure","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. avant frais d'occupation","tariffPriceComponent.noTariff":"Aucun tarif disponible","tariffPriceComponent.baseTariff":"Tarif de base","tariffPriceComponent.active":"Actuellement actif","filters.header":"Filtres","filters.dcChargers":"Chargeurs à courant continu","filters.efluxChargers":"Chargeurs E-Flux","filters.noAdditionalFee":"Sans frais supplémentaires par séance","filters.available":"Disponible","filters.charging":"En charge","filters.notAvailable":"Indisponible","filters.chargingPower":"Puissance de charge [kW]","filters.connectorType":"Type de connecteur","filters.apply":"Appliquer les filtres","filters.clearAll":"Effacer tous les filtres","filters.onlyShow":"Afficher uniquement","filters.statusHeading":"Statut","evse.statusAvailable":"Disponible","evse.statusCharging":"En charge","evse.statusUnavailable":"Indisponible","evse.statusRemoved":"Supprimé","evse.statusPlanned":"Planifié","evse.statusReserved":"Réservé","evse.statusInoperative":"Hors service","evse.statusOutOfOrder":"En panne","evse.statusError":"Erreur","evse.statusUnknown":"Inconnu","evse.pricing":"Tarification","locationType.onStreet":"Dans la rue","locationType.parkingGarage":"Parking couvert","locationType.undergroundGarage":"Parking souterrain","locationType.parkingLot":"Parking","locationType.other":"Autre","locationType.unknown":"Inconnu","tariffPriceComponent.viewTariff":"Voir le tarif","tariffNote.subHeader":"Notes tarifaires","tariffNote.eFluxScheduledTariffNote":"Un tarif programmé remplace les prix de base du tarif pour une période spécifique.","tariffNote.dynamicScheduledTariffNote":"Le prix dynamique est ajusté automatiquement en fonction du prix du marché de l'énergie (intervalle d'une heure).","tariffNote.scheduledTariffNote":"Un tarif programmé remplace les prix de base du tarif pour une période spécifique.","tariffNote.baseTariffNote":"Les tarifs affichés ici ont été transmis à E-Flux par le partenaire d'itinérance. La précision peut varier en fonction du fournisseur.","dynamicTariffs.subHeader":"Tarifs horaires","location.viewAllHourlyPrices":"Voir tous les tarifs horaires","backButton.backTo":"Retour à"},Io={"search.placeholder":"Inserisci una posizione...","cdrPrice.flatFee":"Costo aggiuntivo {{total}} / sessione","tariffPriceComponent.dynamicTariffHeader":"Tariffa dinamica - {{date}}","tariffPriceComponent.flat":"{{total}} / sessione","tariffPriceComponent.time":"{{total}} / ora","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / ora tariffa di inattività","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. tempo di attesa prima della tariffa di inattività","tariffPriceComponent.noTariff":"Nessuna tariffa disponibile","tariffPriceComponent.baseTariff":"Tariffa base","tariffPriceComponent.active":"Attivo ora","filters.header":"Filtri","filters.dcChargers":"Caricabatterie DC","filters.efluxChargers":"Caricabatterie E-Flux","filters.noAdditionalFee":"Senza costi aggiuntivi per sessione","filters.available":"Disponibile","filters.charging":"In carica","filters.notAvailable":"Non disponibile","filters.chargingPower":"Potenza di ricarica [kW]","filters.connectorType":"Tipo di connettore","filters.apply":"Applica filtri","filters.clearAll":"Cancella tutti i filtri","filters.onlyShow":"Mostra solo","filters.statusHeading":"Stato","evse.statusAvailable":"Disponibile","evse.statusCharging":"In carica","evse.statusUnavailable":"Non disponibile","evse.statusRemoved":"Rimossa","evse.statusPlanned":"Pianificata","evse.statusReserved":"Réservé","evse.statusInoperative":"Inoperativo","evse.statusOutOfOrder":"Fuori servizio","evse.statusError":"Errore","evse.statusUnknown":"Sconosciuto","locationType.onStreet":"In strada","locationType.parkingGarage":"Garage per il parcheggio","locationType.undergroundGarage":"Garage sotterraneo","locationType.parkingLot":"Parcheggio","locationType.other":"Altro","locationType.unknown":"Sconosciuto","tariffPriceComponent.viewTariff":"Visualizza note tariffarie","tariffNote.subHeader":"Note tariffarie","tariffNote.eFluxScheduledTariffNote":"Una tariffa programmata sostituisce i prezzi della tariffa base per un periodo di tempo specifico.","tariffNote.dynamicScheduledTariffNote":"Il prezzo dinamico si regola automaticamente in base al prezzo del mercato dell'energia (intervallo di 1 ora).","tariffNote.scheduledTariffNote":"Una tariffa programmata sostituisce i prezzi della tariffa base per un periodo di tempo specifico.","tariffNote.baseTariffNote":"Le tariffe mostrate qui sono state inviate a E-Flux dal partner di roaming. L'accuratezza può variare a seconda del fornitore.","evse.pricing":"Prezzi","dynamicTariffs.subHeader":"Prezzi orari","location.viewAllHourlyPrices":"Visualizza tutti i prezzi orari","backButton.backTo":"Torna a"},wo={"search.placeholder":"Ingrese una ubicación...","cdrPrice.flatFee":"Tarifa adicional {{total}} / sesión","tariffPriceComponent.dynamicTariffHeader":"Tarifa Dinámica - {{date}}","tariffPriceComponent.flat":"{{total}} / sesión","tariffPriceComponent.time":"{{total}} / hora","tariffPriceComponent.energy":"{{total}} / kWh","tariffPriceComponent.parkingTime":"{{total}} / hora tarifa de inactividad","tariffPriceComponent.parkingTimeWait":"{{minutes}} min. tiempo de espera antes de la tarifa de inactividad","tariffPriceComponent.noTariff":"Tarifa no disponible","tariffPriceComponent.baseTariff":"Tarifa Base","tariffPriceComponent.active":"Activo ahora","filters.header":"Filtros","filters.dcChargers":"Cargadores DC","filters.efluxChargers":"Cargadores E-Flux","filters.noAdditionalFee":"Sin tarifa adicional por sesión","filters.available":"Disponible","filters.charging":"Cargando","filters.notAvailable":"No Disponible","filters.chargingPower":"Potencia de Carga [kW]","filters.connectorType":"Tipo de Conector","filters.apply":"Aplicar Filtros","filters.clearAll":"Limpiar Todos los Filtros","filters.onlyShow":"Mostrar Solo","evse.statusRemoved":"Eliminado","evse.statusPlanned":"Planificado","evse.statusReserved":"Reservado","evse.statusInoperative":"Fuera de servicio","evse.statusOutOfOrder":"Averiado","filters.statusHeading":"Estado","evse.statusAvailable":"Disponible","evse.statusCharging":"Cargando","evse.statusUnavailable":"No Disponible","evse.statusError":"Error","evse.statusUnknown":"Desconocido","locationType.onStreet":"En la calle","locationType.parkingGarage":"Garaje para Estacionar","locationType.undergroundGarage":"Garaje Subterráneo","locationType.parkingLot":"Estacionamiento","locationType.other":"Otro","locationType.unknown":"Desconocido","tariffPriceComponent.viewTariff":"Ver notas de tarifas","tariffNote.subHeader":"Notas de Tarifas","tariffNote.eFluxScheduledTariffNote":"Una tarifa programada anula los precios de la tarifa base para un período de tiempo específico.","tariffNote.dynamicScheduledTariffNote":"El precio dinámico se ajusta automáticamente según el precio del mercado de la energía (intervalo de 1 hora).","tariffNote.scheduledTariffNote":"Una tarifa programada anula los precios de la tarifa base para un período de tiempo específico.","tariffNote.baseTariffNote":"Las tarifas mostradas aquí han sido enviadas a E-Flux por el socio de roaming. La precisión puede variar según el proveedor.","evse.pricing":"Precios","dynamicTariffs.subHeader":"Precios por Hora","location.viewAllHourlyPrices":"Ver Todos los Precios por Hora","backButton.backTo":"Volver a"},No={en:yo,nl:To,de:xo,fr:bo,it:Io,es:wo};async function Ut(e,n){try{const i=await fetch(e,{method:"GET",headers:{"Content-Type":"application/json",...n.version&&{version:n.version},...n.authorization&&n.version==="v2"&&{Authorization:`Bearer ${n.authorization}`}},...n});switch(i.status){case 200:return i.json();case 400:throw new Error("Bad request");case 404:throw new Error("Not Found");case 500:throw new Error("Server Error");case 503:throw new Error("Timeout!");default:throw new Error(`Unexpected status: ${i.status}`)}}catch(i){if(i instanceof DOMException)return null;throw i}}async function Oo(e,n,i,r,{precision:o,bbox:t,...s}){return Ut(`${e}/1/map/search`,{method:"POST",version:n,authorization:i,body:JSON.stringify({gridPrecision:o,bbox:t,...r?.length>0&&{locationIds:r},...s,...s?.operatorOnly?{operator:[s.operatorOnly]}:{}})})}async function So(e,n,i,{origin:r,ids:o}){return Ut(`${e}/1/map/tariff`,{method:"POST",version:n,authorization:i,body:JSON.stringify({connection_id:r.connectionId,country_code:r.countryCode,party_id:r.partyId,tariff_ids:o})})}async function Do(e,n,i,{ids:r,status:o}){return Ut(`${e}/1/map/locations`,{method:"POST",version:n,authorization:i,body:JSON.stringify({ids:r,...n==="v2"?{status:o}:{}})})}async function Po(e,n,i){return(await Ut(`${e}/1/map/config`,{version:n,authorization:i}))?.data}const Cn=v.createContext({isReady:!1,setPlace:()=>{},t:e=>`Translate ${e}`,language:"en"}),Ro=({children:e,...n})=>{const[i,r]=v.useState(n.options),[o,t]=v.useState({preferredOperators:n.options.preferredOperators,showOperatorOnly:n.options.showOperatorOnly,showNoAdditionalFeeFilter:n.options.showNoAdditionalFeeFilter,showPublishingModeFilter:n.options.showPublishingModeFilter}),[s,c]=v.useState(),[l,u]=v.useState(),[f,p]=v.useState(n.options.position),[h,x]=v.useState({}),[w,N]=v.useState([n.options.locationId].filter(Boolean)),[E,k]=v.useState([]),[C,y]=v.useState({type:"success"}),[T,m]=v.useState(!1),R=window.location.search.includes("debug=true");R&&console.log("map-context options",n.options);const J=v.useMemo(()=>Eo(n.options.language||"en"),[n.options.language]),F=v.useMemo(()=>(A,g)=>No[J][A].replace(/\{\{(\w+)\}\}/g,(b,H)=>g[H]),[J]),Q=n.options?.apiRoot||"https://api.road.io";let B=n.options.version,W=n.options.authorization;const te=window.location.search.split("map_key=")[1];te&&(W=te,B="v2");const P=Oo.bind(null,Q,B,W,n.options.limitToLocationIds||[]),D=Do.bind(null,Q,B,W),re=So.bind(null,Q,B,W);async function ne({ids:A,status:g}){y({type:"loading"});try{const{data:b}=await D({ids:A,...B==="v2"?{status:g}:{}});return k(b.filter(H=>H?.evses?.length)),y({type:"success"}),b}catch(b){y({type:"error",error:b})}}v.useEffect(()=>{n.options.locationId&&ne({ids:[n.options.locationId],status:h.status}).then(A=>{if(A?.length){const g=A[0];g.geoLocation?.coordinates&&p({lng:g.geoLocation?.coordinates[0],lat:g.geoLocation?.coordinates[1]})}})},[n.options.locationId]),v.useEffect(()=>{Po(Q,B,W).then(A=>{R&&console.log("retrieved remote config",A),t({...A,...o}),r({googleApiKey:A.googleMapsApiKey,...i,...A}),!i.locationId&&!i?.position?.lat&&A.ipLatitude?(R&&console.debug("setting position from ip latitude and longitude"),p({lat:A.ipLatitude,lng:A.ipLongitude})):i.locationId||(R&&console.debug("setting position from options position"),p(i?.position?.lat?i.position:{lat:52.3676,lng:4.9041}))}).catch(A=>c(A))},[]),v.useEffect(()=>{w?.length&&ne({ids:w,status:h.status})},[w]),v.useEffect(()=>{const{theming:A,shadowRoot:g}=n.options;if(g){const b=g.querySelectorAll("#road-map-styles")[0]||document.createElement("style");b.setAttribute("type","text/css"),b.setAttribute("id","road-map-styles"),b.innerHTML=`
|
|
31
31
|
:host {
|
|
32
|
-
--roadmap-brand-color: ${
|
|
33
|
-
--roadmap-background-color: ${
|
|
34
|
-
--roadmap-text-color: ${
|
|
35
|
-
--roadmap-border-color: ${
|
|
36
|
-
--roadmap-font-family: ${
|
|
32
|
+
--roadmap-brand-color: ${A?.brandColor||"#6102d3"};
|
|
33
|
+
--roadmap-background-color: ${A?.backgroundColor||"#ffffff"};
|
|
34
|
+
--roadmap-text-color: ${A?.textColor||"#2a2a2a"};
|
|
35
|
+
--roadmap-border-color: ${A?.borderColor||"#dddddd"};
|
|
36
|
+
--roadmap-font-family: ${A?.fontFamily||"Inter"};
|
|
37
37
|
}
|
|
38
|
-
`,V.appendChild($)}},[n.options.theming]);const re=!!(f&&i?.googleApiKey),ie=g.useMemo(()=>({options:i,setPlace:u,place:l,t:R,language:m,fetchGeohashes:q,locations:E,locationsStatus:_,filterConfiguration:o,setFilters:x,setLocationsIds:O,locationIds:w,filters:h,fetchTariffs:P,fetchLocations:te,isReady:re,position:f}),[f,m,E,_,P,n.options,l,u,x,h,o,w,O,R,q,te,re]);return a.jsx(Cn.Provider,{value:ie,children:e})};function Oe(){const e=g.useContext(Cn);if(e===void 0)throw new Error("useMapContext must be used within a MapProvider");return e}function Ao(e){const{isReady:n}=g.useContext(Cn),i=g.useRef(null),o=Co(i)&&n;return a.jsxs("div",{ref:i,className:nr.container,style:{height:`${e.height}px`},children:[!o&&a.jsx("div",{className:nr.loader,children:"Loading..."}),o&&e.children]})}const Mo="Map-module_container",ko={container:Mo};function jo(e,n,i,r){function o(t){return t instanceof i?t:new i(function(s){s(t)})}return new(i||(i=Promise))(function(t,s){function c(f){try{u(r.next(f))}catch(p){s(p)}}function l(f){try{u(r.throw(f))}catch(p){s(p)}}function u(f){f.done?t(f.value):o(f.value).then(c,l)}u((r=r.apply(e,[])).next())})}function Lo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Vo=function e(n,i){if(n===i)return!0;if(n&&i&&typeof n=="object"&&typeof i=="object"){if(n.constructor!==i.constructor)return!1;var r,o,t;if(Array.isArray(n)){if(r=n.length,r!=i.length)return!1;for(o=r;o--!==0;)if(!e(n[o],i[o]))return!1;return!0}if(n.constructor===RegExp)return n.source===i.source&&n.flags===i.flags;if(n.valueOf!==Object.prototype.valueOf)return n.valueOf()===i.valueOf();if(n.toString!==Object.prototype.toString)return n.toString()===i.toString();if(t=Object.keys(n),r=t.length,r!==Object.keys(i).length)return!1;for(o=r;o--!==0;)if(!Object.prototype.hasOwnProperty.call(i,t[o]))return!1;for(o=r;o--!==0;){var s=t[o];if(!e(n[s],i[s]))return!1}return!0}return n!==n&&i!==i},Ho=Lo(Vo);const rr="__googleMapsScriptId";var rt;(function(e){e[e.INITIALIZED=0]="INITIALIZED",e[e.LOADING=1]="LOADING",e[e.SUCCESS=2]="SUCCESS",e[e.FAILURE=3]="FAILURE"})(rt||(rt={}));class Ge{constructor({apiKey:n,authReferrerPolicy:i,channel:r,client:o,id:t=rr,language:s,libraries:c=[],mapIds:l,nonce:u,region:f,retries:p=3,url:h="https://maps.googleapis.com/maps/api/js",version:x}){if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=n,this.authReferrerPolicy=i,this.channel=r,this.client=o,this.id=t||rr,this.language=s,this.libraries=c,this.mapIds=l,this.nonce=u,this.region=f,this.retries=p,this.url=h,this.version=x,Ge.instance){if(!Ho(this.options,Ge.instance.options))throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(Ge.instance.options)}`);return Ge.instance}Ge.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?rt.FAILURE:this.done?rt.SUCCESS:this.loading?rt.LOADING:rt.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){let n=this.url;return n+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(n+=`&key=${this.apiKey}`),this.channel&&(n+=`&channel=${this.channel}`),this.client&&(n+=`&client=${this.client}`),this.libraries.length>0&&(n+=`&libraries=${this.libraries.join(",")}`),this.language&&(n+=`&language=${this.language}`),this.region&&(n+=`®ion=${this.region}`),this.version&&(n+=`&v=${this.version}`),this.mapIds&&(n+=`&map_ids=${this.mapIds.join(",")}`),this.authReferrerPolicy&&(n+=`&auth_referrer_policy=${this.authReferrerPolicy}`),n}deleteScript(){const n=document.getElementById(this.id);n&&n.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise((n,i)=>{this.loadCallback(r=>{r?i(r.error):n(window.google)})})}importLibrary(n){return this.execute(),google.maps.importLibrary(n)}loadCallback(n){this.callbacks.push(n),this.execute()}setScript(){var n,i;if(document.getElementById(this.id)){this.callback();return}const r={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};Object.keys(r).forEach(t=>!r[t]&&delete r[t]),!((i=(n=window?.google)===null||n===void 0?void 0:n.maps)===null||i===void 0)&&i.importLibrary||(t=>{let s,c,l,u="The Google Maps JavaScript API",f="google",p="importLibrary",h="__ib__",x=document,w=window;w=w[f]||(w[f]={});const O=w.maps||(w.maps={}),E=new Set,M=new URLSearchParams,_=()=>s||(s=new Promise((y,T)=>jo(this,void 0,void 0,function*(){var m;yield c=x.createElement("script"),c.id=this.id,M.set("libraries",[...E]+"");for(l in t)M.set(l.replace(/[A-Z]/g,R=>"_"+R[0].toLowerCase()),t[l]);M.set("callback",f+".maps."+h),c.src=this.url+"?"+M,O[h]=y,c.onerror=()=>s=T(Error(u+" could not load.")),c.nonce=this.nonce||((m=x.querySelector("script[nonce]"))===null||m===void 0?void 0:m.nonce)||"",x.head.append(c)})));O[p]?console.warn(u+" only loads once. Ignoring:",t):O[p]=(y,...T)=>E.add(y)&&_().then(()=>O[p](y,...T))})(r);const o=this.libraries.map(t=>this.importLibrary(t));o.length||o.push(this.importLibrary("core")),Promise.all(o).then(()=>this.callback(),t=>{const s=new ErrorEvent("error",{error:t});this.loadErrorCallback(s)})}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(n){if(this.errors.push(n),this.errors.length<=this.retries){const i=this.errors.length*Math.pow(2,this.errors.length);console.error(`Failed to load Google Maps script, retrying in ${i} ms.`),setTimeout(()=>{this.deleteScript(),this.setScript()},i)}else this.onerrorEvent=n,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach(n=>{n(this.onerrorEvent)}),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version){console.warn("Google Maps already loaded outside @googlemaps/js-api-loader.This may result in undesirable behavior as options and script parameters may not match."),this.callback();return}this.loading||(this.loading=!0,this.setScript())}}}let tn;function Fr(e,n){if(tn)return tn;const i=new Ge({apiKey:e,version:"weekly",language:n});return tn=i,i}const nn="0123456789bcdefghjkmnpqrstuvwxyz";class ye{static encode(n,i,r){if(typeof r>"u"){for(let h=1;h<=12;h++){const x=ye.encode(n,i,h),w=ye.decode(x);if(w.lat==n&&w.lon==i)return x}r=12}if(n=Number(n),i=Number(i),r=Number(r),isNaN(n)||isNaN(i)||isNaN(r))throw new Error("Invalid geohash");let o=0,t=0,s=!0,c="",l=-90,u=90,f=-180,p=180;for(;c.length<r;){if(s){const h=(f+p)/2;i>=h?(o=o*2+1,f=h):(o=o*2,p=h)}else{const h=(l+u)/2;n>=h?(o=o*2+1,l=h):(o=o*2,u=h)}s=!s,++t==5&&(c+=nn.charAt(o),t=0,o=0)}return c}static decode(n){const i=ye.bounds(n),r=i.sw.lat,o=i.sw.lon,t=i.ne.lat,s=i.ne.lon;let c=(r+t)/2,l=(o+s)/2;return c=c.toFixed(Math.floor(2-Math.log(t-r)/Math.LN10)),l=l.toFixed(Math.floor(2-Math.log(s-o)/Math.LN10)),{lat:Number(c),lon:Number(l)}}static bounds(n){if(n.length==0)throw new Error("Invalid geohash");n=n.toLowerCase();let i=!0,r=-90,o=90,t=-180,s=180;for(let l=0;l<n.length;l++){const u=n.charAt(l),f=nn.indexOf(u);if(f==-1)throw new Error("Invalid geohash");for(let p=4;p>=0;p--){const h=f>>p&1;if(i){const x=(t+s)/2;h==1?t=x:s=x}else{const x=(r+o)/2;h==1?r=x:o=x}i=!i}}return{sw:{lat:r,lon:t},ne:{lat:o,lon:s}}}static adjacent(n,i){if(n=n.toLowerCase(),i=i.toLowerCase(),n.length==0)throw new Error("Invalid geohash");if("nsew".indexOf(i)==-1)throw new Error("Invalid direction");const r={n:["p0r21436x8zb9dcf5h7kjnmqesgutwvy","bc01fg45238967deuvhjyznpkmstqrwx"],s:["14365h7k9dcfesgujnmqp0r2twvyx8zb","238967debc01fg45kmstqrwxuvhjyznp"],e:["bc01fg45238967deuvhjyznpkmstqrwx","p0r21436x8zb9dcf5h7kjnmqesgutwvy"],w:["238967debc01fg45kmstqrwxuvhjyznp","14365h7k9dcfesgujnmqp0r2twvyx8zb"]},o={n:["prxz","bcfguvyz"],s:["028b","0145hjnp"],e:["bcfguvyz","prxz"],w:["0145hjnp","028b"]},t=n.slice(-1);let s=n.slice(0,-1);const c=n.length%2;return o[i][c].indexOf(t)!=-1&&s!=""&&(s=ye.adjacent(s,i)),s+nn.charAt(r[i][c].indexOf(t))}static neighbours(n){return{n:ye.adjacent(n,"n"),ne:ye.adjacent(ye.adjacent(n,"n"),"e"),e:ye.adjacent(n,"e"),se:ye.adjacent(ye.adjacent(n,"s"),"e"),s:ye.adjacent(n,"s"),sw:ye.adjacent(ye.adjacent(n,"s"),"w"),w:ye.adjacent(n,"w"),nw:ye.adjacent(ye.adjacent(n,"n"),"w")}}}function $o(e,n,i){class r extends google.maps.OverlayView{constructor(t,s,c){super(),this.container=t,this.pane=s,this.position=c}onAdd(){this.getPanes()?.[this.pane]?.appendChild(this.container)}draw(){const s=this.getProjection().fromLatLngToDivPixel(this.position);s!==null&&(this.container.style.transform=`translate(${s.x}px, ${s.y}px)`)}onRemove(){this.container.parentNode!==null&&this.container.parentNode.removeChild(this.container)}}return new r(e,n,i)}function Fo({position:e,pane:n="floatPane",map:i,zIndex:r,children:o}){const t=g.useMemo(()=>{const c=document.createElement("div");return c.style.position="absolute",c},[]),s=g.useMemo(()=>$o(t,n,{lat:e.lat,lng:e.lon}),[t,n,e]);return g.useEffect(()=>(s?.setMap(i),()=>{s?.setMap(null)}),[i,s]),g.useEffect(()=>{t.style.zIndex=`${r}`},[r,t]),ut.createPortal(o,t)}function Fe(e){switch(e){case"AVAILABLE":return"#33AC19";case"CHARGING":return"#005CEE";default:return"#EB001B"}}const Bo="CustomMarker-module_container",zo={container:Bo},Uo=new Intl.NumberFormat(void 0,{maximumSignificantDigits:3}),Yo=e=>Uo.format(e),Ko=({data:e,map:n,onClick:i,highlight:r})=>{const o=g.useCallback(()=>{i(e)},[i,e]),t=g.useMemo(()=>e.statuses.find(s=>s.name==="AVAILABLE")?{background:Fe("AVAILABLE")}:e.statuses.find(s=>s.name==="CHARGING")?{background:Fe("CHARGING")}:{background:Fe("UNAVAILABLE")},[e]);return a.jsx(Fo,{position:e.centroid,map:n,zIndex:r?99:0,children:a.jsx("button",{className:zo.container,onClick:o,style:t,onTouchEndCapture:o,children:e.count>1?Yo(e.count):""})})},Wo=[1,1,2,2,2,3,3,3,4,4,4,5,6,6,6,7,8,8,8,8,8,9,9,9,9,9];function rn(e){return Wo[e]}function ir(e,n){const i=e.getSouthWest().toJSON(),r=e.getNorthEast().toJSON(),o=ye.encode(i.lat,i.lng,n),t=ye.bounds(o),s=Math.abs(t.sw.lat-t.ne.lat),c=Math.abs(t.sw.lon-t.ne.lon);let l=t.sw.lat;for(;l<=r.lat;)l=l+s;let u=t.sw.lon;for(;u<=r.lng;)u=u+c;return{nwLat:l,nwLng:t.sw.lon,seLat:t.sw.lat,seLng:u}}function Go(e,n){return e.nwLat===n.nwLat&&e.nwLng===n.nwLng&&e.seLat===n.seLat&&e.seLng===n.seLng}function qo({map:e,filters:n,fetchGeohashes:i,onMarkerClicked:r}){const[o,t]=g.useState([]),[s,c]=g.useState({zoom:rn(e.getZoom()),normalizedBounds:ir(e.getBounds(),rn(e.getZoom()))});g.useEffect(()=>{let f=s.zoom,p;e.addListener("idle",()=>{const h=rn(e.getZoom()),x={...s,zoom:h},w=ir(e.getBounds(),f);p&&Go(p,w)||(p=w,c({...x,normalizedBounds:w}))})},[]);function l(f){const p=o.filter(h=>f.find(x=>x.key===h.key));t([...p,...f.filter(h=>!p.find(x=>x.key===h.key))])}g.useEffect(()=>{if(!s.normalizedBounds)return;let f=!1;return i({precision:s.zoom,bbox:s.normalizedBounds,...n}).then(({data:p})=>{f||l(p)}).catch(p=>{}),()=>{f=!0}},[s,n]);const u=g.useCallback(f=>{const p=f.ids;p.length==100&&e.setZoom(e.getZoom()+2),e.panTo({lat:f.centroid.lat,lng:f.centroid.lon}),p.length!==100&&r(p)},[e,r]);return a.jsx(a.Fragment,{children:o.filter(Boolean).map((f,p)=>a.jsx(Ko,{map:e,data:f,onClick:u},f.key))})}function Zo(){const{place:e,options:n,fetchGeohashes:i,setLocationsIds:r,language:o,filters:t,position:s}=Oe(),c=n.googleApiKey,[l,u]=g.useState(),f=g.useRef(null),p=Fr(c,o);return g.useEffect(()=>{l&&e?.geometry?.viewport&&l.fitBounds(e.geometry.viewport),l&&e?.geometry?.location&&l.setCenter(e.geometry.location)},[l,e]),g.useEffect(()=>{p.importLibrary("maps").then(({Map:h})=>{const x=new h(f.current,{mapId:"ced50d4165f3a695",center:s,zoom:12,zoomControl:!0,mapTypeControl:!1,scaleControl:!1,streetViewControl:!1,rotateControl:!1,fullscreenControl:!1,controlSize:32,clickableIcons:!1,gestureHandling:n.gestureHandling||"auto"});return x.addListener("idle",()=>{u(x)}),()=>{console.log("unmounting")}})},[c]),a.jsx("div",{className:ko.container,ref:f,children:l&&l.getBounds()&&a.jsx(qo,{filters:t,onMarkerClicked:h=>{r([...h])},map:l,fetchGeohashes:i})})}function oe(){return oe=Object.assign?Object.assign.bind():function(e){for(var n=1;n<arguments.length;n++){var i=arguments[n];for(var r in i)({}).hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},oe.apply(null,arguments)}function ke(e,n){if(e==null)return{};var i={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(n.indexOf(r)!==-1)continue;i[r]=e[r]}return i}function pn(e,n){return pn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,r){return i.__proto__=r,i},pn(e,n)}function Yt(e,n){e.prototype=Object.create(n.prototype),e.prototype.constructor=e,pn(e,n)}var Et={exports:{}},yt={exports:{}},ue={};/** @license React v16.13.1
|
|
38
|
+
`,g.appendChild(b)}},[n.options.theming]);const _e=!!(f&&i?.googleApiKey),G=v.useMemo(()=>({options:i,setPlace:u,place:l,t:F,language:J,fetchGeohashes:P,locations:E,locationsStatus:C,filterConfiguration:o,setFilters:x,setLocationsIds:N,locationIds:w,filters:h,fetchTariffs:re,fetchLocations:D,isReady:_e,position:f,isSearching:T,setIsSearching:m}),[f,J,E,C,re,n.options,l,u,x,h,o,w,N,F,P,D,_e,T]);return a.jsx(Cn.Provider,{value:G,children:e})};function Ie(){const e=v.useContext(Cn);if(e===void 0)throw new Error("useMapContext must be used within a MapProvider");return e}function Ao(e){const{isReady:n}=v.useContext(Cn),i=v.useRef(null),o=Co(i)&&n;return a.jsxs("div",{ref:i,className:nr.container,style:{height:`${e.height}px`},children:[!o&&a.jsx("div",{className:nr.loader,children:"Loading..."}),o&&e.children]})}const Mo="Map-module_container",ko={container:Mo};function jo(e,n,i,r){function o(t){return t instanceof i?t:new i(function(s){s(t)})}return new(i||(i=Promise))(function(t,s){function c(f){try{u(r.next(f))}catch(p){s(p)}}function l(f){try{u(r.throw(f))}catch(p){s(p)}}function u(f){f.done?t(f.value):o(f.value).then(c,l)}u((r=r.apply(e,[])).next())})}function Lo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Vo=function e(n,i){if(n===i)return!0;if(n&&i&&typeof n=="object"&&typeof i=="object"){if(n.constructor!==i.constructor)return!1;var r,o,t;if(Array.isArray(n)){if(r=n.length,r!=i.length)return!1;for(o=r;o--!==0;)if(!e(n[o],i[o]))return!1;return!0}if(n.constructor===RegExp)return n.source===i.source&&n.flags===i.flags;if(n.valueOf!==Object.prototype.valueOf)return n.valueOf()===i.valueOf();if(n.toString!==Object.prototype.toString)return n.toString()===i.toString();if(t=Object.keys(n),r=t.length,r!==Object.keys(i).length)return!1;for(o=r;o--!==0;)if(!Object.prototype.hasOwnProperty.call(i,t[o]))return!1;for(o=r;o--!==0;){var s=t[o];if(!e(n[s],i[s]))return!1}return!0}return n!==n&&i!==i},Ho=Lo(Vo);const rr="__googleMapsScriptId";var rt;(function(e){e[e.INITIALIZED=0]="INITIALIZED",e[e.LOADING=1]="LOADING",e[e.SUCCESS=2]="SUCCESS",e[e.FAILURE=3]="FAILURE"})(rt||(rt={}));class qe{constructor({apiKey:n,authReferrerPolicy:i,channel:r,client:o,id:t=rr,language:s,libraries:c=[],mapIds:l,nonce:u,region:f,retries:p=3,url:h="https://maps.googleapis.com/maps/api/js",version:x}){if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=n,this.authReferrerPolicy=i,this.channel=r,this.client=o,this.id=t||rr,this.language=s,this.libraries=c,this.mapIds=l,this.nonce=u,this.region=f,this.retries=p,this.url=h,this.version=x,qe.instance){if(!Ho(this.options,qe.instance.options))throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(qe.instance.options)}`);return qe.instance}qe.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?rt.FAILURE:this.done?rt.SUCCESS:this.loading?rt.LOADING:rt.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){let n=this.url;return n+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(n+=`&key=${this.apiKey}`),this.channel&&(n+=`&channel=${this.channel}`),this.client&&(n+=`&client=${this.client}`),this.libraries.length>0&&(n+=`&libraries=${this.libraries.join(",")}`),this.language&&(n+=`&language=${this.language}`),this.region&&(n+=`®ion=${this.region}`),this.version&&(n+=`&v=${this.version}`),this.mapIds&&(n+=`&map_ids=${this.mapIds.join(",")}`),this.authReferrerPolicy&&(n+=`&auth_referrer_policy=${this.authReferrerPolicy}`),n}deleteScript(){const n=document.getElementById(this.id);n&&n.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise((n,i)=>{this.loadCallback(r=>{r?i(r.error):n(window.google)})})}importLibrary(n){return this.execute(),google.maps.importLibrary(n)}loadCallback(n){this.callbacks.push(n),this.execute()}setScript(){var n,i;if(document.getElementById(this.id)){this.callback();return}const r={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};Object.keys(r).forEach(t=>!r[t]&&delete r[t]),!((i=(n=window?.google)===null||n===void 0?void 0:n.maps)===null||i===void 0)&&i.importLibrary||(t=>{let s,c,l,u="The Google Maps JavaScript API",f="google",p="importLibrary",h="__ib__",x=document,w=window;w=w[f]||(w[f]={});const N=w.maps||(w.maps={}),E=new Set,k=new URLSearchParams,C=()=>s||(s=new Promise((y,T)=>jo(this,void 0,void 0,function*(){var m;yield c=x.createElement("script"),c.id=this.id,k.set("libraries",[...E]+"");for(l in t)k.set(l.replace(/[A-Z]/g,R=>"_"+R[0].toLowerCase()),t[l]);k.set("callback",f+".maps."+h),c.src=this.url+"?"+k,N[h]=y,c.onerror=()=>s=T(Error(u+" could not load.")),c.nonce=this.nonce||((m=x.querySelector("script[nonce]"))===null||m===void 0?void 0:m.nonce)||"",x.head.append(c)})));N[p]?console.warn(u+" only loads once. Ignoring:",t):N[p]=(y,...T)=>E.add(y)&&C().then(()=>N[p](y,...T))})(r);const o=this.libraries.map(t=>this.importLibrary(t));o.length||o.push(this.importLibrary("core")),Promise.all(o).then(()=>this.callback(),t=>{const s=new ErrorEvent("error",{error:t});this.loadErrorCallback(s)})}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(n){if(this.errors.push(n),this.errors.length<=this.retries){const i=this.errors.length*Math.pow(2,this.errors.length);console.error(`Failed to load Google Maps script, retrying in ${i} ms.`),setTimeout(()=>{this.deleteScript(),this.setScript()},i)}else this.onerrorEvent=n,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach(n=>{n(this.onerrorEvent)}),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version){console.warn("Google Maps already loaded outside @googlemaps/js-api-loader.This may result in undesirable behavior as options and script parameters may not match."),this.callback();return}this.loading||(this.loading=!0,this.setScript())}}}let tn;function Fr(e,n){if(tn)return tn;const i=new qe({apiKey:e,version:"weekly",language:n});return tn=i,i}const nn="0123456789bcdefghjkmnpqrstuvwxyz";class ye{static encode(n,i,r){if(typeof r>"u"){for(let h=1;h<=12;h++){const x=ye.encode(n,i,h),w=ye.decode(x);if(w.lat==n&&w.lon==i)return x}r=12}if(n=Number(n),i=Number(i),r=Number(r),isNaN(n)||isNaN(i)||isNaN(r))throw new Error("Invalid geohash");let o=0,t=0,s=!0,c="",l=-90,u=90,f=-180,p=180;for(;c.length<r;){if(s){const h=(f+p)/2;i>=h?(o=o*2+1,f=h):(o=o*2,p=h)}else{const h=(l+u)/2;n>=h?(o=o*2+1,l=h):(o=o*2,u=h)}s=!s,++t==5&&(c+=nn.charAt(o),t=0,o=0)}return c}static decode(n){const i=ye.bounds(n),r=i.sw.lat,o=i.sw.lon,t=i.ne.lat,s=i.ne.lon;let c=(r+t)/2,l=(o+s)/2;return c=c.toFixed(Math.floor(2-Math.log(t-r)/Math.LN10)),l=l.toFixed(Math.floor(2-Math.log(s-o)/Math.LN10)),{lat:Number(c),lon:Number(l)}}static bounds(n){if(n.length==0)throw new Error("Invalid geohash");n=n.toLowerCase();let i=!0,r=-90,o=90,t=-180,s=180;for(let l=0;l<n.length;l++){const u=n.charAt(l),f=nn.indexOf(u);if(f==-1)throw new Error("Invalid geohash");for(let p=4;p>=0;p--){const h=f>>p&1;if(i){const x=(t+s)/2;h==1?t=x:s=x}else{const x=(r+o)/2;h==1?r=x:o=x}i=!i}}return{sw:{lat:r,lon:t},ne:{lat:o,lon:s}}}static adjacent(n,i){if(n=n.toLowerCase(),i=i.toLowerCase(),n.length==0)throw new Error("Invalid geohash");if("nsew".indexOf(i)==-1)throw new Error("Invalid direction");const r={n:["p0r21436x8zb9dcf5h7kjnmqesgutwvy","bc01fg45238967deuvhjyznpkmstqrwx"],s:["14365h7k9dcfesgujnmqp0r2twvyx8zb","238967debc01fg45kmstqrwxuvhjyznp"],e:["bc01fg45238967deuvhjyznpkmstqrwx","p0r21436x8zb9dcf5h7kjnmqesgutwvy"],w:["238967debc01fg45kmstqrwxuvhjyznp","14365h7k9dcfesgujnmqp0r2twvyx8zb"]},o={n:["prxz","bcfguvyz"],s:["028b","0145hjnp"],e:["bcfguvyz","prxz"],w:["0145hjnp","028b"]},t=n.slice(-1);let s=n.slice(0,-1);const c=n.length%2;return o[i][c].indexOf(t)!=-1&&s!=""&&(s=ye.adjacent(s,i)),s+nn.charAt(r[i][c].indexOf(t))}static neighbours(n){return{n:ye.adjacent(n,"n"),ne:ye.adjacent(ye.adjacent(n,"n"),"e"),e:ye.adjacent(n,"e"),se:ye.adjacent(ye.adjacent(n,"s"),"e"),s:ye.adjacent(n,"s"),sw:ye.adjacent(ye.adjacent(n,"s"),"w"),w:ye.adjacent(n,"w"),nw:ye.adjacent(ye.adjacent(n,"n"),"w")}}}function $o(e,n,i){class r extends google.maps.OverlayView{constructor(t,s,c){super(),this.container=t,this.pane=s,this.position=c}onAdd(){this.getPanes()?.[this.pane]?.appendChild(this.container)}draw(){const s=this.getProjection().fromLatLngToDivPixel(this.position);s!==null&&(this.container.style.transform=`translate(${s.x}px, ${s.y}px)`)}onRemove(){this.container.parentNode!==null&&this.container.parentNode.removeChild(this.container)}}return new r(e,n,i)}function Fo({position:e,pane:n="floatPane",map:i,zIndex:r,children:o}){const t=v.useMemo(()=>{const c=document.createElement("div");return c.style.position="absolute",c},[]),s=v.useMemo(()=>$o(t,n,{lat:e.lat,lng:e.lon}),[t,n,e]);return v.useEffect(()=>(s?.setMap(i),()=>{s?.setMap(null)}),[i,s]),v.useEffect(()=>{t.style.zIndex=`${r}`},[r,t]),ut.createPortal(o,t)}function Fe(e){switch(e){case"AVAILABLE":return"#33AC19";case"CHARGING":return"#005CEE";default:return"#EB001B"}}const Bo="CustomMarker-module_container",zo={container:Bo},Uo=new Intl.NumberFormat(void 0,{maximumSignificantDigits:3}),Yo=e=>Uo.format(e),Ko=({data:e,map:n,onClick:i,highlight:r})=>{const o=v.useCallback(()=>{i(e)},[i,e]),t=v.useMemo(()=>e.statuses.find(s=>s.name==="AVAILABLE")?{background:Fe("AVAILABLE")}:e.statuses.find(s=>s.name==="CHARGING")?{background:Fe("CHARGING")}:{background:Fe("UNAVAILABLE")},[e]);return a.jsx(Fo,{position:e.centroid,map:n,zIndex:r?99:0,children:a.jsx("button",{className:zo.container,onClick:o,style:t,onTouchEndCapture:o,children:e.count>1?Yo(e.count):""})})},Wo=[1,1,2,2,2,3,3,3,4,4,4,5,6,6,6,7,8,8,8,8,8,9,9,9,9,9];function rn(e){return Wo[e]}function ir(e,n){const i=e.getSouthWest().toJSON(),r=e.getNorthEast().toJSON(),o=ye.encode(i.lat,i.lng,n),t=ye.bounds(o),s=Math.abs(t.sw.lat-t.ne.lat),c=Math.abs(t.sw.lon-t.ne.lon);let l=t.sw.lat;for(;l<=r.lat;)l=l+s;let u=t.sw.lon;for(;u<=r.lng;)u=u+c;return{nwLat:l,nwLng:t.sw.lon,seLat:t.sw.lat,seLng:u}}function Go(e,n){return e.nwLat===n.nwLat&&e.nwLng===n.nwLng&&e.seLat===n.seLat&&e.seLng===n.seLng}function qo({map:e,filters:n,fetchGeohashes:i,onMarkerClicked:r}){const{setIsSearching:o}=Ie(),[t,s]=v.useState([]),[c,l]=v.useState({zoom:rn(e.getZoom()),normalizedBounds:ir(e.getBounds(),rn(e.getZoom()))});v.useEffect(()=>{let p=c.zoom,h;e.addListener("idle",()=>{const x=rn(e.getZoom()),w={...c,zoom:x},N=ir(e.getBounds(),p);h&&Go(h,N)||(h=N,l({...w,normalizedBounds:N}))})},[]);function u(p){const h=t.filter(x=>p.find(w=>w.key===x.key));s([...h,...p.filter(x=>!h.find(w=>w.key===x.key))])}v.useEffect(()=>{if(!c.normalizedBounds)return;let p=!1;return o(!0),i({precision:c.zoom,bbox:c.normalizedBounds,...n}).then(({data:h})=>{p||(u(h),o(!1))}).catch(h=>{o(!1)}),()=>{p=!0,o(!1)}},[c,n]);const f=v.useCallback(p=>{const h=p.ids;h.length==100&&e.setZoom(e.getZoom()+2),e.panTo({lat:p.centroid.lat,lng:p.centroid.lon}),h.length!==100&&r(h)},[e,r]);return a.jsx(a.Fragment,{children:t.filter(Boolean).map((p,h)=>a.jsx(Ko,{map:e,data:p,onClick:f},p.key))})}function Zo(){const{place:e,options:n,fetchGeohashes:i,setLocationsIds:r,language:o,filters:t,position:s}=Ie(),c=n.googleApiKey,[l,u]=v.useState(),f=v.useRef(null),p=Fr(c,o);return v.useEffect(()=>{l&&e?.geometry?.viewport&&l.fitBounds(e.geometry.viewport),l&&e?.geometry?.location&&l.setCenter(e.geometry.location)},[l,e]),v.useEffect(()=>{p.importLibrary("maps").then(({Map:h})=>{const x=new h(f.current,{mapId:"ced50d4165f3a695",center:s,zoom:12,zoomControl:!0,mapTypeControl:!1,scaleControl:!1,streetViewControl:!1,rotateControl:!1,fullscreenControl:!1,controlSize:32,clickableIcons:!1,gestureHandling:n.gestureHandling||"auto"});return x.addListener("idle",()=>{u(x)}),()=>{console.log("unmounting")}})},[c]),a.jsx("div",{className:ko.container,ref:f,children:l&&l.getBounds()&&a.jsx(qo,{filters:t,onMarkerClicked:h=>{r([...h])},map:l,fetchGeohashes:i})})}function ie(){return ie=Object.assign?Object.assign.bind():function(e){for(var n=1;n<arguments.length;n++){var i=arguments[n];for(var r in i)({}).hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},ie.apply(null,arguments)}function ke(e,n){if(e==null)return{};var i={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(n.indexOf(r)!==-1)continue;i[r]=e[r]}return i}function pn(e,n){return pn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,r){return i.__proto__=r,i},pn(e,n)}function Yt(e,n){e.prototype=Object.create(n.prototype),e.prototype.constructor=e,pn(e,n)}var Et={exports:{}},yt={exports:{}},le={};/** @license React v16.13.1
|
|
39
39
|
* react-is.production.min.js
|
|
40
40
|
*
|
|
41
41
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
42
42
|
*
|
|
43
43
|
* This source code is licensed under the MIT license found in the
|
|
44
44
|
* LICENSE file in the root directory of this source tree.
|
|
45
|
-
*/var or;function Jo(){if(or)return
|
|
45
|
+
*/var or;function Jo(){if(or)return le;or=1;var e=typeof Symbol=="function"&&Symbol.for,n=e?Symbol.for("react.element"):60103,i=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,t=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,c=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,w=e?Symbol.for("react.lazy"):60116,N=e?Symbol.for("react.block"):60121,E=e?Symbol.for("react.fundamental"):60117,k=e?Symbol.for("react.responder"):60118,C=e?Symbol.for("react.scope"):60119;function y(m){if(typeof m=="object"&&m!==null){var R=m.$$typeof;switch(R){case n:switch(m=m.type,m){case l:case u:case r:case t:case o:case p:return m;default:switch(m=m&&m.$$typeof,m){case c:case f:case w:case x:case s:return m;default:return R}}case i:return R}}}function T(m){return y(m)===u}return le.AsyncMode=l,le.ConcurrentMode=u,le.ContextConsumer=c,le.ContextProvider=s,le.Element=n,le.ForwardRef=f,le.Fragment=r,le.Lazy=w,le.Memo=x,le.Portal=i,le.Profiler=t,le.StrictMode=o,le.Suspense=p,le.isAsyncMode=function(m){return T(m)||y(m)===l},le.isConcurrentMode=T,le.isContextConsumer=function(m){return y(m)===c},le.isContextProvider=function(m){return y(m)===s},le.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===n},le.isForwardRef=function(m){return y(m)===f},le.isFragment=function(m){return y(m)===r},le.isLazy=function(m){return y(m)===w},le.isMemo=function(m){return y(m)===x},le.isPortal=function(m){return y(m)===i},le.isProfiler=function(m){return y(m)===t},le.isStrictMode=function(m){return y(m)===o},le.isSuspense=function(m){return y(m)===p},le.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===r||m===u||m===t||m===o||m===p||m===h||typeof m=="object"&&m!==null&&(m.$$typeof===w||m.$$typeof===x||m.$$typeof===s||m.$$typeof===c||m.$$typeof===f||m.$$typeof===E||m.$$typeof===k||m.$$typeof===C||m.$$typeof===N)},le.typeOf=y,le}var ue={};/** @license React v16.13.1
|
|
46
46
|
* react-is.development.js
|
|
47
47
|
*
|
|
48
48
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
49
49
|
*
|
|
50
50
|
* This source code is licensed under the MIT license found in the
|
|
51
51
|
* LICENSE file in the root directory of this source tree.
|
|
52
|
-
*/var sr;function Xo(){return sr||(sr=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,n=e?Symbol.for("react.element"):60103,i=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,t=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,c=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,w=e?Symbol.for("react.lazy"):60116,
|
|
52
|
+
*/var sr;function Xo(){return sr||(sr=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,n=e?Symbol.for("react.element"):60103,i=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,t=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,c=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,x=e?Symbol.for("react.memo"):60115,w=e?Symbol.for("react.lazy"):60116,N=e?Symbol.for("react.block"):60121,E=e?Symbol.for("react.fundamental"):60117,k=e?Symbol.for("react.responder"):60118,C=e?Symbol.for("react.scope"):60119;function y(O){return typeof O=="string"||typeof O=="function"||O===r||O===u||O===t||O===o||O===p||O===h||typeof O=="object"&&O!==null&&(O.$$typeof===w||O.$$typeof===x||O.$$typeof===s||O.$$typeof===c||O.$$typeof===f||O.$$typeof===E||O.$$typeof===k||O.$$typeof===C||O.$$typeof===N)}function T(O){if(typeof O=="object"&&O!==null){var me=O.$$typeof;switch(me){case n:var L=O.type;switch(L){case l:case u:case r:case t:case o:case p:return L;default:var xe=L&&L.$$typeof;switch(xe){case c:case f:case w:case x:case s:return xe;default:return me}}case i:return me}}}var m=l,R=u,J=c,F=s,Q=n,B=f,W=r,te=w,P=x,D=i,re=t,ne=o,_e=p,G=!1;function A(O){return G||(G=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),g(O)||T(O)===l}function g(O){return T(O)===u}function b(O){return T(O)===c}function H(O){return T(O)===s}function Y(O){return typeof O=="object"&&O!==null&&O.$$typeof===n}function V(O){return T(O)===f}function Z(O){return T(O)===r}function j(O){return T(O)===w}function $(O){return T(O)===x}function z(O){return T(O)===i}function ee(O){return T(O)===t}function q(O){return T(O)===o}function ae(O){return T(O)===p}ue.AsyncMode=m,ue.ConcurrentMode=R,ue.ContextConsumer=J,ue.ContextProvider=F,ue.Element=Q,ue.ForwardRef=B,ue.Fragment=W,ue.Lazy=te,ue.Memo=P,ue.Portal=D,ue.Profiler=re,ue.StrictMode=ne,ue.Suspense=_e,ue.isAsyncMode=A,ue.isConcurrentMode=g,ue.isContextConsumer=b,ue.isContextProvider=H,ue.isElement=Y,ue.isForwardRef=V,ue.isFragment=Z,ue.isLazy=j,ue.isMemo=$,ue.isPortal=z,ue.isProfiler=ee,ue.isStrictMode=q,ue.isSuspense=ae,ue.isValidElementType=y,ue.typeOf=T})()),ue}var ar;function Br(){return ar||(ar=1,process.env.NODE_ENV==="production"?yt.exports=Jo():yt.exports=Xo()),yt.exports}/*
|
|
53
53
|
object-assign
|
|
54
54
|
(c) Sindre Sorhus
|
|
55
55
|
@license MIT
|
|
56
|
-
*/var on,cr;function Qo(){if(cr)return on;cr=1;var e=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function r(t){if(t==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}function o(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de",Object.getOwnPropertyNames(t)[0]==="5")return!1;for(var s={},c=0;c<10;c++)s["_"+String.fromCharCode(c)]=c;var l=Object.getOwnPropertyNames(s).map(function(f){return s[f]});if(l.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(f){u[f]=f}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return on=o()?Object.assign:function(t,s){for(var c,l=r(t),u,f=1;f<arguments.length;f++){c=Object(arguments[f]);for(var p in c)n.call(c,p)&&(l[p]=c[p]);if(e){u=e(c);for(var h=0;h<u.length;h++)i.call(c,u[h])&&(l[u[h]]=c[u[h]])}}return l},on}var sn,lr;function En(){if(lr)return sn;lr=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return sn=e,sn}var an,ur;function zr(){return ur||(ur=1,an=Function.call.bind(Object.prototype.hasOwnProperty)),an}var cn,dr;function es(){if(dr)return cn;dr=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var n=En(),i={},r=zr();e=function(t){var s="Warning: "+t;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function o(t,s,c,l,u){if(process.env.NODE_ENV!=="production"){for(var f in t)if(r(t,f)){var p;try{if(typeof t[f]!="function"){var h=Error((l||"React class")+": "+c+" type `"+f+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof t[f]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}p=t[f](s,f,l,c,null,n)}catch(w){p=w}if(p&&!(p instanceof Error)&&e((l||"React class")+": type specification of "+c+" `"+f+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof p+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),p instanceof Error&&!(p.message in i)){i[p.message]=!0;var x=u?u():"";e("Failed "+c+" type: "+p.message+(x??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(i={})},cn=o,cn}var ln,fr;function ts(){if(fr)return ln;fr=1;var e=Br(),n=Qo(),i=En(),r=zr(),o=es(),t=function(){};process.env.NODE_ENV!=="production"&&(t=function(c){var l="Warning: "+c;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return ln=function(c,l){var u=typeof Symbol=="function"&&Symbol.iterator,f="@@iterator";function p(
|
|
57
|
-
Valid keys: `+JSON.stringify(Object.keys(C),null," "));var N=ce(F,G,H,Z,k+"."+G,i);if(N)return N}return null}return E(I)}function D(C){switch(typeof C){case"number":case"string":case"undefined":return!0;case"boolean":return!C;case"object":if(Array.isArray(C))return C.every(D);if(C===null||c(C))return!0;var I=p(C);if(I){var U=I.call(C),Y;if(I!==C.entries){for(;!(Y=U.next()).done;)if(!D(Y.value))return!1}else for(;!(Y=U.next()).done;){var H=Y.value;if(H&&!D(H[1]))return!1}}else return!1;return!0;default:return!1}}function re(C,I){return C==="symbol"?!0:I?I["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&I instanceof Symbol:!1}function ie(C){var I=typeof C;return Array.isArray(C)?"array":C instanceof RegExp?"object":re(I,C)?"symbol":I}function ne(C){if(typeof C>"u"||C===null)return""+C;var I=ie(C);if(I==="object"){if(C instanceof Date)return"date";if(C instanceof RegExp)return"regexp"}return I}function V(C){var I=ne(C);switch(I){case"array":case"object":return"an "+I;case"boolean":case"date":case"regexp":return"a "+I;default:return I}}function $(C){return!C.constructor||!C.constructor.name?h:C.constructor.name}return x.checkPropTypes=o,x.resetWarningCache=o.resetWarningCache,x.PropTypes=x,x},ln}var un,pr;function ns(){if(pr)return un;pr=1;var e=En();function n(){}function i(){}return i.resetWarningCache=n,un=function(){function r(s,c,l,u,f,p){if(p!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}r.isRequired=r;function o(){return r}var t={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:i,resetWarningCache:n};return t.PropTypes=t,t},un}var hr;function rs(){if(hr)return Et.exports;if(hr=1,process.env.NODE_ENV!=="production"){var e=Br(),n=!0;Et.exports=ts()(e.isElement,n)}else Et.exports=ns()();return Et.exports}var is=rs();const v=po(is);function os(e,n){return e.classList?!!n&&e.classList.contains(n):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+n+" ")!==-1}function ss(e,n){e.classList?e.classList.add(n):os(e,n)||(typeof e.className=="string"?e.className=e.className+" "+n:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+n))}function mr(e,n){return e.replace(new RegExp("(^|\\s)"+n+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function as(e,n){e.classList?e.classList.remove(n):typeof e.className=="string"?e.className=mr(e.className,n):e.setAttribute("class",mr(e.className&&e.className.baseVal||"",n))}const gr={disabled:!1};var cs=process.env.NODE_ENV!=="production"?v.oneOfType([v.number,v.shape({enter:v.number,exit:v.number,appear:v.number}).isRequired]):null,ls=process.env.NODE_ENV!=="production"?v.oneOfType([v.string,v.shape({enter:v.string,exit:v.string,active:v.string}),v.shape({enter:v.string,enterDone:v.string,enterActive:v.string,exit:v.string,exitDone:v.string,exitActive:v.string})]):null;const yn=g.createContext(null);var Ur=function(n){return n.scrollTop},dt="unmounted",Ke="exited",Me="entering",je="entered",gt="exiting",Le=(function(e){Yt(n,e);function n(r,o){var t;t=e.call(this,r,o)||this;var s=o,c=s&&!s.isMounting?r.enter:r.appear,l;return t.appearStatus=null,r.in?c?(l=Ke,t.appearStatus=Me):l=je:r.unmountOnExit||r.mountOnEnter?l=dt:l=Ke,t.state={status:l},t.nextCallback=null,t}n.getDerivedStateFromProps=function(o,t){var s=o.in;return s&&t.status===dt?{status:Ke}:null};var i=n.prototype;return i.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},i.componentDidUpdate=function(o){var t=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==Me&&s!==je&&(t=Me):(s===Me||s===je)&&(t=gt)}this.updateStatus(!1,t)},i.componentWillUnmount=function(){this.cancelNextCallback()},i.getTimeouts=function(){var o=this.props.timeout,t,s,c;return t=s=c=o,o!=null&&typeof o!="number"&&(t=o.exit,s=o.enter,c=o.appear!==void 0?o.appear:s),{exit:t,enter:s,appear:c}},i.updateStatus=function(o,t){if(o===void 0&&(o=!1),t!==null)if(this.cancelNextCallback(),t===Me){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:ut.findDOMNode(this);s&&Ur(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Ke&&this.setState({status:dt})},i.performEnter=function(o){var t=this,s=this.props.enter,c=this.context?this.context.isMounting:o,l=this.props.nodeRef?[c]:[ut.findDOMNode(this),c],u=l[0],f=l[1],p=this.getTimeouts(),h=c?p.appear:p.enter;if(!o&&!s||gr.disabled){this.safeSetState({status:je},function(){t.props.onEntered(u)});return}this.props.onEnter(u,f),this.safeSetState({status:Me},function(){t.props.onEntering(u,f),t.onTransitionEnd(h,function(){t.safeSetState({status:je},function(){t.props.onEntered(u,f)})})})},i.performExit=function(){var o=this,t=this.props.exit,s=this.getTimeouts(),c=this.props.nodeRef?void 0:ut.findDOMNode(this);if(!t||gr.disabled){this.safeSetState({status:Ke},function(){o.props.onExited(c)});return}this.props.onExit(c),this.safeSetState({status:gt},function(){o.props.onExiting(c),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:Ke},function(){o.props.onExited(c)})})})},i.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},i.safeSetState=function(o,t){t=this.setNextCallback(t),this.setState(o,t)},i.setNextCallback=function(o){var t=this,s=!0;return this.nextCallback=function(c){s&&(s=!1,t.nextCallback=null,o(c))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},i.onTransitionEnd=function(o,t){this.setNextCallback(t);var s=this.props.nodeRef?this.props.nodeRef.current:ut.findDOMNode(this),c=o==null&&!this.props.addEndListener;if(!s||c){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],u=l[0],f=l[1];this.props.addEndListener(u,f)}o!=null&&setTimeout(this.nextCallback,o)},i.render=function(){var o=this.state.status;if(o===dt)return null;var t=this.props,s=t.children;t.in,t.mountOnEnter,t.unmountOnExit,t.appear,t.enter,t.exit,t.timeout,t.addEndListener,t.onEnter,t.onEntering,t.onEntered,t.onExit,t.onExiting,t.onExited,t.nodeRef;var c=ke(t,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(yn.Provider,{value:null},typeof s=="function"?s(o,c):g.cloneElement(g.Children.only(s),c))},n})(g.Component);Le.contextType=yn;Le.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:v.shape({current:typeof Element>"u"?v.any:function(e,n,i,r,o,t){var s=e[n];return v.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(e,n,i,r,o,t)}}),children:v.oneOfType([v.func.isRequired,v.element.isRequired]).isRequired,in:v.bool,mountOnEnter:v.bool,unmountOnExit:v.bool,appear:v.bool,enter:v.bool,exit:v.bool,timeout:function(n){var i=cs;n.addEndListener||(i=i.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),t=1;t<r;t++)o[t-1]=arguments[t];return i.apply(void 0,[n].concat(o))},addEndListener:v.func,onEnter:v.func,onEntering:v.func,onEntered:v.func,onExit:v.func,onExiting:v.func,onExited:v.func}:{};function Qe(){}Le.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:Qe,onEntering:Qe,onEntered:Qe,onExit:Qe,onExiting:Qe,onExited:Qe};Le.UNMOUNTED=dt;Le.EXITED=Ke;Le.ENTERING=Me;Le.ENTERED=je;Le.EXITING=gt;var us=function(n,i){return n&&i&&i.split(" ").forEach(function(r){return ss(n,r)})},dn=function(n,i){return n&&i&&i.split(" ").forEach(function(r){return as(n,r)})},Tn=(function(e){Yt(n,e);function n(){for(var r,o=arguments.length,t=new Array(o),s=0;s<o;s++)t[s]=arguments[s];return r=e.call.apply(e,[this].concat(t))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(c,l){var u=r.resolveArguments(c,l),f=u[0],p=u[1];r.removeClasses(f,"exit"),r.addClass(f,p?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(c,l)},r.onEntering=function(c,l){var u=r.resolveArguments(c,l),f=u[0],p=u[1],h=p?"appear":"enter";r.addClass(f,h,"active"),r.props.onEntering&&r.props.onEntering(c,l)},r.onEntered=function(c,l){var u=r.resolveArguments(c,l),f=u[0],p=u[1],h=p?"appear":"enter";r.removeClasses(f,h),r.addClass(f,h,"done"),r.props.onEntered&&r.props.onEntered(c,l)},r.onExit=function(c){var l=r.resolveArguments(c),u=l[0];r.removeClasses(u,"appear"),r.removeClasses(u,"enter"),r.addClass(u,"exit","base"),r.props.onExit&&r.props.onExit(c)},r.onExiting=function(c){var l=r.resolveArguments(c),u=l[0];r.addClass(u,"exit","active"),r.props.onExiting&&r.props.onExiting(c)},r.onExited=function(c){var l=r.resolveArguments(c),u=l[0];r.removeClasses(u,"exit"),r.addClass(u,"exit","done"),r.props.onExited&&r.props.onExited(c)},r.resolveArguments=function(c,l){return r.props.nodeRef?[r.props.nodeRef.current,c]:[c,l]},r.getClassNames=function(c){var l=r.props.classNames,u=typeof l=="string",f=u&&l?l+"-":"",p=u?""+f+c:l[c],h=u?p+"-active":l[c+"Active"],x=u?p+"-done":l[c+"Done"];return{baseClassName:p,activeClassName:h,doneClassName:x}},r}var i=n.prototype;return i.addClass=function(o,t,s){var c=this.getClassNames(t)[s+"ClassName"],l=this.getClassNames("enter"),u=l.doneClassName;t==="appear"&&s==="done"&&u&&(c+=" "+u),s==="active"&&o&&Ur(o),c&&(this.appliedClasses[t][s]=c,us(o,c))},i.removeClasses=function(o,t){var s=this.appliedClasses[t],c=s.base,l=s.active,u=s.done;this.appliedClasses[t]={},c&&dn(o,c),l&&dn(o,l),u&&dn(o,u)},i.render=function(){var o=this.props;o.classNames;var t=ke(o,["classNames"]);return g.createElement(Le,oe({},t,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},n})(g.Component);Tn.defaultProps={classNames:""};Tn.propTypes=process.env.NODE_ENV!=="production"?oe({},Le.propTypes,{classNames:ls,onEnter:v.func,onEntering:v.func,onEntered:v.func,onExit:v.func,onExiting:v.func,onExited:v.func}):{};var Tt,xt;function ds(e,n){return!(e===n||g.isValidElement(e)&&g.isValidElement(n)&&e.key!=null&&e.key===n.key)}var ze={out:"out-in",in:"in-out"},Lt=function(n,i,r){return function(){var o;n.props[i]&&(o=n.props)[i].apply(o,arguments),r()}},fs=(Tt={},Tt[ze.out]=function(e){var n=e.current,i=e.changeState;return g.cloneElement(n,{in:!1,onExited:Lt(n,"onExited",function(){i(Me,null)})})},Tt[ze.in]=function(e){var n=e.current,i=e.changeState,r=e.children;return[n,g.cloneElement(r,{in:!0,onEntered:Lt(r,"onEntered",function(){i(Me)})})]},Tt),ps=(xt={},xt[ze.out]=function(e){var n=e.children,i=e.changeState;return g.cloneElement(n,{in:!0,onEntered:Lt(n,"onEntered",function(){i(je,g.cloneElement(n,{in:!0}))})})},xt[ze.in]=function(e){var n=e.current,i=e.children,r=e.changeState;return[g.cloneElement(n,{in:!1,onExited:Lt(n,"onExited",function(){r(je,g.cloneElement(i,{in:!0}))})}),g.cloneElement(i,{in:!0})]},xt),xn=(function(e){Yt(n,e);function n(){for(var r,o=arguments.length,t=new Array(o),s=0;s<o;s++)t[s]=arguments[s];return r=e.call.apply(e,[this].concat(t))||this,r.state={status:je,current:null},r.appeared=!1,r.changeState=function(c,l){l===void 0&&(l=r.state.current),r.setState({status:c,current:l})},r}var i=n.prototype;return i.componentDidMount=function(){this.appeared=!0},n.getDerivedStateFromProps=function(o,t){return o.children==null?{current:null}:t.status===Me&&o.mode===ze.in?{status:Me}:t.current&&ds(t.current,o.children)?{status:gt}:{current:g.cloneElement(o.children,{in:!0})}},i.render=function(){var o=this.props,t=o.children,s=o.mode,c=this.state,l=c.status,u=c.current,f={children:t,current:u,changeState:this.changeState,status:l},p;switch(l){case Me:p=ps[s](f);break;case gt:p=fs[s](f);break;case je:p=u}return g.createElement(yn.Provider,{value:{isMounting:!this.appeared}},p)},n})(g.Component);xn.propTypes=process.env.NODE_ENV!=="production"?{mode:v.oneOf([ze.in,ze.out]),children:v.oneOfType([v.element.isRequired])}:{};xn.defaultProps={mode:ze.out};const hs="stack-module_stack",ms="stack-module_slideEnter",gs="stack-module_slideEnterActive",vs="stack-module_slideExit",_s="stack-module_slideExitActive",He={stack:hs,slideEnter:ms,slideEnterActive:gs,slideExit:vs,slideExitActive:_s};function Cs({name:e,children:n}){return a.jsx("div",{className:He.stack,children:n})}const Yr=g.createContext({setView:()=>{},current:{name:"none"}});function _t(){return g.useContext(Yr)}function $e({name:e,currentView:n,onViewChange:i,children:r}){const o={none:{name:"none",ref:g.createRef(),view:null}};g.Children.forEach(r,p=>{if(!g.isValidElement(p))return;const{name:h}=p.props;if(!h)throw new Error("name is required for Stack.View");o[h]={name:h,ref:g.createRef(),view:p}});const[t,s]=g.useState(o[n].ref);g.useEffect(()=>{s(o[n].ref)},[n]);const{view:c}=o[n],[l,u]=g.useState({}),f=g.useMemo(()=>({current:{name:n,args:l},setView:(p,h)=>{u(h),i(p,h)}}),[n,i,l,u]);return a.jsx(Yr.Provider,{value:f,children:a.jsx(xn,{mode:"out-in",children:a.jsx(Tn,{classNames:{enter:He.slideEnter,enterActive:He.slideEnterActive,enterDone:He.slideEnterDone,exit:He.slideExit,exitActive:He.slideExitActive,exitDone:He.slideExitDone},mountOnEnter:!0,unmountOnExit:!0,timeout:300,nodeRef:t,addEndListener:p=>{t.current.addEventListener("transitionend",p,!1)},children:a.jsx("div",{className:He.stack,ref:t,children:c})},n)})})}$e.View=Cs;const Es="router-module_container",ys="router-module_controlsContainer",Ts="router-module_filterButton",xs="router-module_filterCounter",bs="router-module_stackContainer",et={container:Es,controlsContainer:ys,filterButton:Ts,filterCounter:xs,stackContainer:bs},Is="SearchInput-module_container",ws="SearchInput-module_searchInput",vr={container:Is,searchInput:ws};function Ns({onFocus:e}){const{options:n,setPlace:i,t:r,language:o}=Oe(),t=n.googleApiKey,s=g.useRef(null),c=Fr(t,o);return g.useEffect(()=>{s.current&&c.importLibrary("places").then(l=>{const u=new l.Autocomplete(s.current,{fields:["geometry"]});u.addListener("place_changed",()=>{const f=u.getPlace();i(f)})})},[s]),a.jsx("div",{className:vr.container,children:a.jsx("input",{onFocus:e,ref:s,className:vr.searchInput,type:"text",placeholder:r("search.placeholder")})})}const Os="filters-module_headerContainer",Ss="filters-module_container",Ds="filters-module_header",Ps="filters-module_heading",Rs="filters-module_actionLinkClearAll",As="filters-module_optionsGroup",Ms="filters-module_rowLabel",ks="filters-module_label",js="filters-module_dot",Ls="filters-module_connectorIcon",K={headerContainer:Os,container:Ss,header:Ds,heading:Ps,actionLinkClearAll:Rs,optionsGroup:As,rowLabel:Ms,label:ks,dot:js,connectorIcon:Ls},Vs="Checkbox-module_container",Hs="Checkbox-module_box",_r={container:Vs,box:Hs};function Se({id:e,name:n,checked:i,onChange:r,type:o="checkbox"}){const[t,s]=g.useState(i||!1),c=g.useCallback(l=>{s(l.target.checked),r(l.target.checked)},[r]);return g.useEffect(()=>{s(i)},[i]),a.jsxs("div",{className:_r.container,children:[a.jsx("input",{name:n,id:e,type:o,value:t,checked:t,onChange:c}),a.jsx("span",{className:_r.box,children:a.jsx("svg",{className:"checkmark",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor",strokeWidth:"4",strokeLinecap:"round",strokeLinejoin:"round",children:a.jsx("polyline",{points:"20 6 9 17 4 12"})})})]})}const $s="Range-module_container",Fs="Range-module_input",Bs="Range-module_ticksContainer",zs="Range-module_tick",bt={container:$s,input:Fs,ticksContainer:Bs,tick:zs};function Us({ticks:e,value:n,onChange:i}){const r=g.useRef(null),o=e.findIndex(s=>s.value===n),t=o/(e.length-1)*100;return a.jsxs("div",{className:bt.container,children:[a.jsx("input",{value:o,onChange:s=>{i(e[s.target.value].value)},ref:r,className:bt.input,type:"range",list:"tickmarks",step:"1",min:"0",max:"8",style:{"--roadmap-range-bgize":`${t}%`}}),a.jsx("div",{className:bt.ticksContainer,children:e.map((s,c)=>a.jsx("div",{onClick:l=>{i(e[c].value)},className:bt.tick,children:s.label},s.label))})]})}var It={exports:{}},fe={};/**
|
|
56
|
+
*/var on,cr;function Qo(){if(cr)return on;cr=1;var e=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function r(t){if(t==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}function o(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de",Object.getOwnPropertyNames(t)[0]==="5")return!1;for(var s={},c=0;c<10;c++)s["_"+String.fromCharCode(c)]=c;var l=Object.getOwnPropertyNames(s).map(function(f){return s[f]});if(l.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(f){u[f]=f}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return on=o()?Object.assign:function(t,s){for(var c,l=r(t),u,f=1;f<arguments.length;f++){c=Object(arguments[f]);for(var p in c)n.call(c,p)&&(l[p]=c[p]);if(e){u=e(c);for(var h=0;h<u.length;h++)i.call(c,u[h])&&(l[u[h]]=c[u[h]])}}return l},on}var sn,lr;function En(){if(lr)return sn;lr=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return sn=e,sn}var an,ur;function zr(){return ur||(ur=1,an=Function.call.bind(Object.prototype.hasOwnProperty)),an}var cn,dr;function es(){if(dr)return cn;dr=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var n=En(),i={},r=zr();e=function(t){var s="Warning: "+t;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function o(t,s,c,l,u){if(process.env.NODE_ENV!=="production"){for(var f in t)if(r(t,f)){var p;try{if(typeof t[f]!="function"){var h=Error((l||"React class")+": "+c+" type `"+f+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof t[f]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}p=t[f](s,f,l,c,null,n)}catch(w){p=w}if(p&&!(p instanceof Error)&&e((l||"React class")+": type specification of "+c+" `"+f+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof p+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),p instanceof Error&&!(p.message in i)){i[p.message]=!0;var x=u?u():"";e("Failed "+c+" type: "+p.message+(x??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(i={})},cn=o,cn}var ln,fr;function ts(){if(fr)return ln;fr=1;var e=Br(),n=Qo(),i=En(),r=zr(),o=es(),t=function(){};process.env.NODE_ENV!=="production"&&(t=function(c){var l="Warning: "+c;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return ln=function(c,l){var u=typeof Symbol=="function"&&Symbol.iterator,f="@@iterator";function p(g){var b=g&&(u&&g[u]||g[f]);if(typeof b=="function")return b}var h="<<anonymous>>",x={array:k("array"),bigint:k("bigint"),bool:k("boolean"),func:k("function"),number:k("number"),object:k("object"),string:k("string"),symbol:k("symbol"),any:C(),arrayOf:y,element:T(),elementType:m(),instanceOf:R,node:B(),objectOf:F,oneOf:J,oneOfType:Q,shape:te,exact:P};function w(g,b){return g===b?g!==0||1/g===1/b:g!==g&&b!==b}function N(g,b){this.message=g,this.data=b&&typeof b=="object"?b:{},this.stack=""}N.prototype=Error.prototype;function E(g){if(process.env.NODE_ENV!=="production")var b={},H=0;function Y(Z,j,$,z,ee,q,ae){if(z=z||h,q=q||$,ae!==i){if(l){var O=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw O.name="Invariant Violation",O}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var me=z+":"+$;!b[me]&&H<3&&(t("You are manually calling a React.PropTypes validation function for the `"+q+"` prop on `"+z+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),b[me]=!0,H++)}}return j[$]==null?Z?j[$]===null?new N("The "+ee+" `"+q+"` is marked as required "+("in `"+z+"`, but its value is `null`.")):new N("The "+ee+" `"+q+"` is marked as required in "+("`"+z+"`, but its value is `undefined`.")):null:g(j,$,z,ee,q)}var V=Y.bind(null,!1);return V.isRequired=Y.bind(null,!0),V}function k(g){function b(H,Y,V,Z,j,$){var z=H[Y],ee=ne(z);if(ee!==g){var q=_e(z);return new N("Invalid "+Z+" `"+j+"` of type "+("`"+q+"` supplied to `"+V+"`, expected ")+("`"+g+"`."),{expectedType:g})}return null}return E(b)}function C(){return E(s)}function y(g){function b(H,Y,V,Z,j){if(typeof g!="function")return new N("Property `"+j+"` of component `"+V+"` has invalid PropType notation inside arrayOf.");var $=H[Y];if(!Array.isArray($)){var z=ne($);return new N("Invalid "+Z+" `"+j+"` of type "+("`"+z+"` supplied to `"+V+"`, expected an array."))}for(var ee=0;ee<$.length;ee++){var q=g($,ee,V,Z,j+"["+ee+"]",i);if(q instanceof Error)return q}return null}return E(b)}function T(){function g(b,H,Y,V,Z){var j=b[H];if(!c(j)){var $=ne(j);return new N("Invalid "+V+" `"+Z+"` of type "+("`"+$+"` supplied to `"+Y+"`, expected a single ReactElement."))}return null}return E(g)}function m(){function g(b,H,Y,V,Z){var j=b[H];if(!e.isValidElementType(j)){var $=ne(j);return new N("Invalid "+V+" `"+Z+"` of type "+("`"+$+"` supplied to `"+Y+"`, expected a single ReactElement type."))}return null}return E(g)}function R(g){function b(H,Y,V,Z,j){if(!(H[Y]instanceof g)){var $=g.name||h,z=A(H[Y]);return new N("Invalid "+Z+" `"+j+"` of type "+("`"+z+"` supplied to `"+V+"`, expected ")+("instance of `"+$+"`."))}return null}return E(b)}function J(g){if(!Array.isArray(g))return process.env.NODE_ENV!=="production"&&(arguments.length>1?t("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):t("Invalid argument supplied to oneOf, expected an array.")),s;function b(H,Y,V,Z,j){for(var $=H[Y],z=0;z<g.length;z++)if(w($,g[z]))return null;var ee=JSON.stringify(g,function(ae,O){var me=_e(O);return me==="symbol"?String(O):O});return new N("Invalid "+Z+" `"+j+"` of value `"+String($)+"` "+("supplied to `"+V+"`, expected one of "+ee+"."))}return E(b)}function F(g){function b(H,Y,V,Z,j){if(typeof g!="function")return new N("Property `"+j+"` of component `"+V+"` has invalid PropType notation inside objectOf.");var $=H[Y],z=ne($);if(z!=="object")return new N("Invalid "+Z+" `"+j+"` of type "+("`"+z+"` supplied to `"+V+"`, expected an object."));for(var ee in $)if(r($,ee)){var q=g($,ee,V,Z,j+"."+ee,i);if(q instanceof Error)return q}return null}return E(b)}function Q(g){if(!Array.isArray(g))return process.env.NODE_ENV!=="production"&&t("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var b=0;b<g.length;b++){var H=g[b];if(typeof H!="function")return t("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+G(H)+" at index "+b+"."),s}function Y(V,Z,j,$,z){for(var ee=[],q=0;q<g.length;q++){var ae=g[q],O=ae(V,Z,j,$,z,i);if(O==null)return null;O.data&&r(O.data,"expectedType")&&ee.push(O.data.expectedType)}var me=ee.length>0?", expected one of type ["+ee.join(", ")+"]":"";return new N("Invalid "+$+" `"+z+"` supplied to "+("`"+j+"`"+me+"."))}return E(Y)}function B(){function g(b,H,Y,V,Z){return D(b[H])?null:new N("Invalid "+V+" `"+Z+"` supplied to "+("`"+Y+"`, expected a ReactNode."))}return E(g)}function W(g,b,H,Y,V){return new N((g||"React class")+": "+b+" type `"+H+"."+Y+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+V+"`.")}function te(g){function b(H,Y,V,Z,j){var $=H[Y],z=ne($);if(z!=="object")return new N("Invalid "+Z+" `"+j+"` of type `"+z+"` "+("supplied to `"+V+"`, expected `object`."));for(var ee in g){var q=g[ee];if(typeof q!="function")return W(V,Z,j,ee,_e(q));var ae=q($,ee,V,Z,j+"."+ee,i);if(ae)return ae}return null}return E(b)}function P(g){function b(H,Y,V,Z,j){var $=H[Y],z=ne($);if(z!=="object")return new N("Invalid "+Z+" `"+j+"` of type `"+z+"` "+("supplied to `"+V+"`, expected `object`."));var ee=n({},H[Y],g);for(var q in ee){var ae=g[q];if(r(g,q)&&typeof ae!="function")return W(V,Z,j,q,_e(ae));if(!ae)return new N("Invalid "+Z+" `"+j+"` key `"+q+"` supplied to `"+V+"`.\nBad object: "+JSON.stringify(H[Y],null," ")+`
|
|
57
|
+
Valid keys: `+JSON.stringify(Object.keys(g),null," "));var O=ae($,q,V,Z,j+"."+q,i);if(O)return O}return null}return E(b)}function D(g){switch(typeof g){case"number":case"string":case"undefined":return!0;case"boolean":return!g;case"object":if(Array.isArray(g))return g.every(D);if(g===null||c(g))return!0;var b=p(g);if(b){var H=b.call(g),Y;if(b!==g.entries){for(;!(Y=H.next()).done;)if(!D(Y.value))return!1}else for(;!(Y=H.next()).done;){var V=Y.value;if(V&&!D(V[1]))return!1}}else return!1;return!0;default:return!1}}function re(g,b){return g==="symbol"?!0:b?b["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&b instanceof Symbol:!1}function ne(g){var b=typeof g;return Array.isArray(g)?"array":g instanceof RegExp?"object":re(b,g)?"symbol":b}function _e(g){if(typeof g>"u"||g===null)return""+g;var b=ne(g);if(b==="object"){if(g instanceof Date)return"date";if(g instanceof RegExp)return"regexp"}return b}function G(g){var b=_e(g);switch(b){case"array":case"object":return"an "+b;case"boolean":case"date":case"regexp":return"a "+b;default:return b}}function A(g){return!g.constructor||!g.constructor.name?h:g.constructor.name}return x.checkPropTypes=o,x.resetWarningCache=o.resetWarningCache,x.PropTypes=x,x},ln}var un,pr;function ns(){if(pr)return un;pr=1;var e=En();function n(){}function i(){}return i.resetWarningCache=n,un=function(){function r(s,c,l,u,f,p){if(p!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}r.isRequired=r;function o(){return r}var t={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:i,resetWarningCache:n};return t.PropTypes=t,t},un}var hr;function rs(){if(hr)return Et.exports;if(hr=1,process.env.NODE_ENV!=="production"){var e=Br(),n=!0;Et.exports=ts()(e.isElement,n)}else Et.exports=ns()();return Et.exports}var is=rs();const _=po(is);function os(e,n){return e.classList?!!n&&e.classList.contains(n):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+n+" ")!==-1}function ss(e,n){e.classList?e.classList.add(n):os(e,n)||(typeof e.className=="string"?e.className=e.className+" "+n:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+n))}function mr(e,n){return e.replace(new RegExp("(^|\\s)"+n+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function as(e,n){e.classList?e.classList.remove(n):typeof e.className=="string"?e.className=mr(e.className,n):e.setAttribute("class",mr(e.className&&e.className.baseVal||"",n))}const gr={disabled:!1};var cs=process.env.NODE_ENV!=="production"?_.oneOfType([_.number,_.shape({enter:_.number,exit:_.number,appear:_.number}).isRequired]):null,ls=process.env.NODE_ENV!=="production"?_.oneOfType([_.string,_.shape({enter:_.string,exit:_.string,active:_.string}),_.shape({enter:_.string,enterDone:_.string,enterActive:_.string,exit:_.string,exitDone:_.string,exitActive:_.string})]):null;const yn=v.createContext(null);var Ur=function(n){return n.scrollTop},dt="unmounted",We="exited",Me="entering",je="entered",gt="exiting",Le=(function(e){Yt(n,e);function n(r,o){var t;t=e.call(this,r,o)||this;var s=o,c=s&&!s.isMounting?r.enter:r.appear,l;return t.appearStatus=null,r.in?c?(l=We,t.appearStatus=Me):l=je:r.unmountOnExit||r.mountOnEnter?l=dt:l=We,t.state={status:l},t.nextCallback=null,t}n.getDerivedStateFromProps=function(o,t){var s=o.in;return s&&t.status===dt?{status:We}:null};var i=n.prototype;return i.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},i.componentDidUpdate=function(o){var t=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==Me&&s!==je&&(t=Me):(s===Me||s===je)&&(t=gt)}this.updateStatus(!1,t)},i.componentWillUnmount=function(){this.cancelNextCallback()},i.getTimeouts=function(){var o=this.props.timeout,t,s,c;return t=s=c=o,o!=null&&typeof o!="number"&&(t=o.exit,s=o.enter,c=o.appear!==void 0?o.appear:s),{exit:t,enter:s,appear:c}},i.updateStatus=function(o,t){if(o===void 0&&(o=!1),t!==null)if(this.cancelNextCallback(),t===Me){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:ut.findDOMNode(this);s&&Ur(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===We&&this.setState({status:dt})},i.performEnter=function(o){var t=this,s=this.props.enter,c=this.context?this.context.isMounting:o,l=this.props.nodeRef?[c]:[ut.findDOMNode(this),c],u=l[0],f=l[1],p=this.getTimeouts(),h=c?p.appear:p.enter;if(!o&&!s||gr.disabled){this.safeSetState({status:je},function(){t.props.onEntered(u)});return}this.props.onEnter(u,f),this.safeSetState({status:Me},function(){t.props.onEntering(u,f),t.onTransitionEnd(h,function(){t.safeSetState({status:je},function(){t.props.onEntered(u,f)})})})},i.performExit=function(){var o=this,t=this.props.exit,s=this.getTimeouts(),c=this.props.nodeRef?void 0:ut.findDOMNode(this);if(!t||gr.disabled){this.safeSetState({status:We},function(){o.props.onExited(c)});return}this.props.onExit(c),this.safeSetState({status:gt},function(){o.props.onExiting(c),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:We},function(){o.props.onExited(c)})})})},i.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},i.safeSetState=function(o,t){t=this.setNextCallback(t),this.setState(o,t)},i.setNextCallback=function(o){var t=this,s=!0;return this.nextCallback=function(c){s&&(s=!1,t.nextCallback=null,o(c))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},i.onTransitionEnd=function(o,t){this.setNextCallback(t);var s=this.props.nodeRef?this.props.nodeRef.current:ut.findDOMNode(this),c=o==null&&!this.props.addEndListener;if(!s||c){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],u=l[0],f=l[1];this.props.addEndListener(u,f)}o!=null&&setTimeout(this.nextCallback,o)},i.render=function(){var o=this.state.status;if(o===dt)return null;var t=this.props,s=t.children;t.in,t.mountOnEnter,t.unmountOnExit,t.appear,t.enter,t.exit,t.timeout,t.addEndListener,t.onEnter,t.onEntering,t.onEntered,t.onExit,t.onExiting,t.onExited,t.nodeRef;var c=ke(t,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return v.createElement(yn.Provider,{value:null},typeof s=="function"?s(o,c):v.cloneElement(v.Children.only(s),c))},n})(v.Component);Le.contextType=yn;Le.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:_.shape({current:typeof Element>"u"?_.any:function(e,n,i,r,o,t){var s=e[n];return _.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(e,n,i,r,o,t)}}),children:_.oneOfType([_.func.isRequired,_.element.isRequired]).isRequired,in:_.bool,mountOnEnter:_.bool,unmountOnExit:_.bool,appear:_.bool,enter:_.bool,exit:_.bool,timeout:function(n){var i=cs;n.addEndListener||(i=i.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),t=1;t<r;t++)o[t-1]=arguments[t];return i.apply(void 0,[n].concat(o))},addEndListener:_.func,onEnter:_.func,onEntering:_.func,onEntered:_.func,onExit:_.func,onExiting:_.func,onExited:_.func}:{};function et(){}Le.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:et,onEntering:et,onEntered:et,onExit:et,onExiting:et,onExited:et};Le.UNMOUNTED=dt;Le.EXITED=We;Le.ENTERING=Me;Le.ENTERED=je;Le.EXITING=gt;var us=function(n,i){return n&&i&&i.split(" ").forEach(function(r){return ss(n,r)})},dn=function(n,i){return n&&i&&i.split(" ").forEach(function(r){return as(n,r)})},Tn=(function(e){Yt(n,e);function n(){for(var r,o=arguments.length,t=new Array(o),s=0;s<o;s++)t[s]=arguments[s];return r=e.call.apply(e,[this].concat(t))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(c,l){var u=r.resolveArguments(c,l),f=u[0],p=u[1];r.removeClasses(f,"exit"),r.addClass(f,p?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(c,l)},r.onEntering=function(c,l){var u=r.resolveArguments(c,l),f=u[0],p=u[1],h=p?"appear":"enter";r.addClass(f,h,"active"),r.props.onEntering&&r.props.onEntering(c,l)},r.onEntered=function(c,l){var u=r.resolveArguments(c,l),f=u[0],p=u[1],h=p?"appear":"enter";r.removeClasses(f,h),r.addClass(f,h,"done"),r.props.onEntered&&r.props.onEntered(c,l)},r.onExit=function(c){var l=r.resolveArguments(c),u=l[0];r.removeClasses(u,"appear"),r.removeClasses(u,"enter"),r.addClass(u,"exit","base"),r.props.onExit&&r.props.onExit(c)},r.onExiting=function(c){var l=r.resolveArguments(c),u=l[0];r.addClass(u,"exit","active"),r.props.onExiting&&r.props.onExiting(c)},r.onExited=function(c){var l=r.resolveArguments(c),u=l[0];r.removeClasses(u,"exit"),r.addClass(u,"exit","done"),r.props.onExited&&r.props.onExited(c)},r.resolveArguments=function(c,l){return r.props.nodeRef?[r.props.nodeRef.current,c]:[c,l]},r.getClassNames=function(c){var l=r.props.classNames,u=typeof l=="string",f=u&&l?l+"-":"",p=u?""+f+c:l[c],h=u?p+"-active":l[c+"Active"],x=u?p+"-done":l[c+"Done"];return{baseClassName:p,activeClassName:h,doneClassName:x}},r}var i=n.prototype;return i.addClass=function(o,t,s){var c=this.getClassNames(t)[s+"ClassName"],l=this.getClassNames("enter"),u=l.doneClassName;t==="appear"&&s==="done"&&u&&(c+=" "+u),s==="active"&&o&&Ur(o),c&&(this.appliedClasses[t][s]=c,us(o,c))},i.removeClasses=function(o,t){var s=this.appliedClasses[t],c=s.base,l=s.active,u=s.done;this.appliedClasses[t]={},c&&dn(o,c),l&&dn(o,l),u&&dn(o,u)},i.render=function(){var o=this.props;o.classNames;var t=ke(o,["classNames"]);return v.createElement(Le,ie({},t,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},n})(v.Component);Tn.defaultProps={classNames:""};Tn.propTypes=process.env.NODE_ENV!=="production"?ie({},Le.propTypes,{classNames:ls,onEnter:_.func,onEntering:_.func,onEntered:_.func,onExit:_.func,onExiting:_.func,onExited:_.func}):{};var Tt,xt;function ds(e,n){return!(e===n||v.isValidElement(e)&&v.isValidElement(n)&&e.key!=null&&e.key===n.key)}var ze={out:"out-in",in:"in-out"},Lt=function(n,i,r){return function(){var o;n.props[i]&&(o=n.props)[i].apply(o,arguments),r()}},fs=(Tt={},Tt[ze.out]=function(e){var n=e.current,i=e.changeState;return v.cloneElement(n,{in:!1,onExited:Lt(n,"onExited",function(){i(Me,null)})})},Tt[ze.in]=function(e){var n=e.current,i=e.changeState,r=e.children;return[n,v.cloneElement(r,{in:!0,onEntered:Lt(r,"onEntered",function(){i(Me)})})]},Tt),ps=(xt={},xt[ze.out]=function(e){var n=e.children,i=e.changeState;return v.cloneElement(n,{in:!0,onEntered:Lt(n,"onEntered",function(){i(je,v.cloneElement(n,{in:!0}))})})},xt[ze.in]=function(e){var n=e.current,i=e.children,r=e.changeState;return[v.cloneElement(n,{in:!1,onExited:Lt(n,"onExited",function(){r(je,v.cloneElement(i,{in:!0}))})}),v.cloneElement(i,{in:!0})]},xt),xn=(function(e){Yt(n,e);function n(){for(var r,o=arguments.length,t=new Array(o),s=0;s<o;s++)t[s]=arguments[s];return r=e.call.apply(e,[this].concat(t))||this,r.state={status:je,current:null},r.appeared=!1,r.changeState=function(c,l){l===void 0&&(l=r.state.current),r.setState({status:c,current:l})},r}var i=n.prototype;return i.componentDidMount=function(){this.appeared=!0},n.getDerivedStateFromProps=function(o,t){return o.children==null?{current:null}:t.status===Me&&o.mode===ze.in?{status:Me}:t.current&&ds(t.current,o.children)?{status:gt}:{current:v.cloneElement(o.children,{in:!0})}},i.render=function(){var o=this.props,t=o.children,s=o.mode,c=this.state,l=c.status,u=c.current,f={children:t,current:u,changeState:this.changeState,status:l},p;switch(l){case Me:p=ps[s](f);break;case gt:p=fs[s](f);break;case je:p=u}return v.createElement(yn.Provider,{value:{isMounting:!this.appeared}},p)},n})(v.Component);xn.propTypes=process.env.NODE_ENV!=="production"?{mode:_.oneOf([ze.in,ze.out]),children:_.oneOfType([_.element.isRequired])}:{};xn.defaultProps={mode:ze.out};const hs="stack-module_stack",ms="stack-module_slideEnter",gs="stack-module_slideEnterActive",vs="stack-module_slideExit",_s="stack-module_slideExitActive",He={stack:hs,slideEnter:ms,slideEnterActive:gs,slideExit:vs,slideExitActive:_s};function Cs({name:e,children:n}){return a.jsx("div",{className:He.stack,children:n})}const Yr=v.createContext({setView:()=>{},current:{name:"none"}});function _t(){return v.useContext(Yr)}function $e({name:e,currentView:n,onViewChange:i,children:r}){const o={none:{name:"none",ref:v.createRef(),view:null}};v.Children.forEach(r,p=>{if(!v.isValidElement(p))return;const{name:h}=p.props;if(!h)throw new Error("name is required for Stack.View");o[h]={name:h,ref:v.createRef(),view:p}});const[t,s]=v.useState(o[n].ref);v.useEffect(()=>{s(o[n].ref)},[n]);const{view:c}=o[n],[l,u]=v.useState({}),f=v.useMemo(()=>({current:{name:n,args:l},setView:(p,h)=>{u(h),i(p,h)}}),[n,i,l,u]);return a.jsx(Yr.Provider,{value:f,children:a.jsx(xn,{mode:"out-in",children:a.jsx(Tn,{classNames:{enter:He.slideEnter,enterActive:He.slideEnterActive,enterDone:He.slideEnterDone,exit:He.slideExit,exitActive:He.slideExitActive,exitDone:He.slideExitDone},mountOnEnter:!0,unmountOnExit:!0,timeout:300,nodeRef:t,addEndListener:p=>{t.current.addEventListener("transitionend",p,!1)},children:a.jsx("div",{className:He.stack,ref:t,children:c})},n)})})}$e.View=Cs;const Es="router-module_container",ys="router-module_controlsContainer",Ts="router-module_filterButton",xs="router-module_filterCounter",bs="router-module_spinner",Is="router-module_stackContainer",Ke={container:Es,controlsContainer:ys,filterButton:Ts,filterCounter:xs,spinner:bs,stackContainer:Is},ws="SearchInput-module_container",Ns="SearchInput-module_searchInput",vr={container:ws,searchInput:Ns};function Os({onFocus:e}){const{options:n,setPlace:i,t:r,language:o}=Ie(),t=n.googleApiKey,s=v.useRef(null),c=Fr(t,o);return v.useEffect(()=>{s.current&&c.importLibrary("places").then(l=>{const u=new l.Autocomplete(s.current,{fields:["geometry"]});u.addListener("place_changed",()=>{const f=u.getPlace();i(f)})})},[s]),a.jsx("div",{className:vr.container,children:a.jsx("input",{onFocus:e,ref:s,className:vr.searchInput,type:"text",placeholder:r("search.placeholder")})})}const Ss="filters-module_headerContainer",Ds="filters-module_container",Ps="filters-module_header",Rs="filters-module_heading",As="filters-module_actionLinkClearAll",Ms="filters-module_optionsGroup",ks="filters-module_rowLabel",js="filters-module_label",Ls="filters-module_dot",Vs="filters-module_connectorIcon",K={headerContainer:Ss,container:Ds,header:Ps,heading:Rs,actionLinkClearAll:As,optionsGroup:Ms,rowLabel:ks,label:js,dot:Ls,connectorIcon:Vs},Hs="Checkbox-module_container",$s="Checkbox-module_box",_r={container:Hs,box:$s};function Se({id:e,name:n,checked:i,onChange:r,type:o="checkbox"}){const[t,s]=v.useState(i||!1),c=v.useCallback(l=>{s(l.target.checked),r(l.target.checked)},[r]);return v.useEffect(()=>{s(i)},[i]),a.jsxs("div",{className:_r.container,children:[a.jsx("input",{name:n,id:e,type:o,value:t,checked:t,onChange:c}),a.jsx("span",{className:_r.box,children:a.jsx("svg",{className:"checkmark",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor",strokeWidth:"4",strokeLinecap:"round",strokeLinejoin:"round",children:a.jsx("polyline",{points:"20 6 9 17 4 12"})})})]})}const Fs="Range-module_container",Bs="Range-module_input",zs="Range-module_ticksContainer",Us="Range-module_tick",bt={container:Fs,input:Bs,ticksContainer:zs,tick:Us};function Ys({ticks:e,value:n,onChange:i}){const r=v.useRef(null),o=e.findIndex(s=>s.value===n),t=o/(e.length-1)*100;return a.jsxs("div",{className:bt.container,children:[a.jsx("input",{value:o,onChange:s=>{i(e[s.target.value].value)},ref:r,className:bt.input,type:"range",list:"tickmarks",step:"1",min:"0",max:"8",style:{"--roadmap-range-bgize":`${t}%`}}),a.jsx("div",{className:bt.ticksContainer,children:e.map((s,c)=>a.jsx("div",{onClick:l=>{i(e[c].value)},className:bt.tick,children:s.label},s.label))})]})}var It={exports:{}},de={};/**
|
|
58
58
|
* @license React
|
|
59
59
|
* react-is.production.min.js
|
|
60
60
|
*
|
|
@@ -62,7 +62,7 @@ Valid keys: `+JSON.stringify(Object.keys(C),null," "));var N=ce(F,G,H,Z,k+"."+G
|
|
|
62
62
|
*
|
|
63
63
|
* This source code is licensed under the MIT license found in the
|
|
64
64
|
* LICENSE file in the root directory of this source tree.
|
|
65
|
-
*/var Cr;function
|
|
65
|
+
*/var Cr;function Ks(){if(Cr)return de;Cr=1;var e=Symbol.for("react.element"),n=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),t=Symbol.for("react.provider"),s=Symbol.for("react.context"),c=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),x=Symbol.for("react.offscreen"),w;w=Symbol.for("react.module.reference");function N(E){if(typeof E=="object"&&E!==null){var k=E.$$typeof;switch(k){case e:switch(E=E.type,E){case i:case o:case r:case u:case f:return E;default:switch(E=E&&E.$$typeof,E){case c:case s:case l:case h:case p:case t:return E;default:return k}}case n:return k}}}return de.ContextConsumer=s,de.ContextProvider=t,de.Element=e,de.ForwardRef=l,de.Fragment=i,de.Lazy=h,de.Memo=p,de.Portal=n,de.Profiler=o,de.StrictMode=r,de.Suspense=u,de.SuspenseList=f,de.isAsyncMode=function(){return!1},de.isConcurrentMode=function(){return!1},de.isContextConsumer=function(E){return N(E)===s},de.isContextProvider=function(E){return N(E)===t},de.isElement=function(E){return typeof E=="object"&&E!==null&&E.$$typeof===e},de.isForwardRef=function(E){return N(E)===l},de.isFragment=function(E){return N(E)===i},de.isLazy=function(E){return N(E)===h},de.isMemo=function(E){return N(E)===p},de.isPortal=function(E){return N(E)===n},de.isProfiler=function(E){return N(E)===o},de.isStrictMode=function(E){return N(E)===r},de.isSuspense=function(E){return N(E)===u},de.isSuspenseList=function(E){return N(E)===f},de.isValidElementType=function(E){return typeof E=="string"||typeof E=="function"||E===i||E===o||E===r||E===u||E===f||E===x||typeof E=="object"&&E!==null&&(E.$$typeof===h||E.$$typeof===p||E.$$typeof===t||E.$$typeof===s||E.$$typeof===l||E.$$typeof===w||E.getModuleId!==void 0)},de.typeOf=N,de}var fe={};/**
|
|
66
66
|
* @license React
|
|
67
67
|
* react-is.development.js
|
|
68
68
|
*
|
|
@@ -70,5 +70,5 @@ Valid keys: `+JSON.stringify(Object.keys(C),null," "));var N=ce(F,G,H,Z,k+"."+G
|
|
|
70
70
|
*
|
|
71
71
|
* This source code is licensed under the MIT license found in the
|
|
72
72
|
* LICENSE file in the root directory of this source tree.
|
|
73
|
-
*/var Er;function Ks(){return Er||(Er=1,process.env.NODE_ENV!=="production"&&(function(){var e=Symbol.for("react.element"),n=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),t=Symbol.for("react.provider"),s=Symbol.for("react.context"),c=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),x=Symbol.for("react.offscreen"),w=!1,O=!1,E=!1,M=!1,_=!1,y;y=Symbol.for("react.module.reference");function T(j){return!!(typeof j=="string"||typeof j=="function"||j===i||j===o||_||j===r||j===u||j===f||M||j===x||w||O||E||typeof j=="object"&&j!==null&&(j.$$typeof===h||j.$$typeof===p||j.$$typeof===t||j.$$typeof===s||j.$$typeof===l||j.$$typeof===y||j.getModuleId!==void 0))}function m(j){if(typeof j=="object"&&j!==null){var xe=j.$$typeof;switch(xe){case e:var ve=j.type;switch(ve){case i:case o:case r:case u:case f:return ve;default:var Ie=ve&&ve.$$typeof;switch(Ie){case c:case s:case l:case h:case p:case t:return Ie;default:return xe}}case n:return xe}}}var R=s,J=t,L=e,X=l,W=i,q=h,te=p,P=n,D=o,re=r,ie=u,ne=f,V=!1,$=!1;function C(j){return V||(V=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function I(j){return $||($=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function U(j){return m(j)===s}function Y(j){return m(j)===t}function H(j){return typeof j=="object"&&j!==null&&j.$$typeof===e}function Z(j){return m(j)===l}function k(j){return m(j)===i}function F(j){return m(j)===h}function B(j){return m(j)===p}function ee(j){return m(j)===n}function G(j){return m(j)===o}function ce(j){return m(j)===r}function N(j){return m(j)===u}function ge(j){return m(j)===f}pe.ContextConsumer=R,pe.ContextProvider=J,pe.Element=L,pe.ForwardRef=X,pe.Fragment=W,pe.Lazy=q,pe.Memo=te,pe.Portal=P,pe.Profiler=D,pe.StrictMode=re,pe.Suspense=ie,pe.SuspenseList=ne,pe.isAsyncMode=C,pe.isConcurrentMode=I,pe.isContextConsumer=U,pe.isContextProvider=Y,pe.isElement=H,pe.isForwardRef=Z,pe.isFragment=k,pe.isLazy=F,pe.isMemo=B,pe.isPortal=ee,pe.isProfiler=G,pe.isStrictMode=ce,pe.isSuspense=N,pe.isSuspenseList=ge,pe.isValidElementType=T,pe.typeOf=m})()),pe}var yr;function Ws(){return yr||(yr=1,process.env.NODE_ENV==="production"?It.exports=Ys():It.exports=Ks()),It.exports}var Tr=Ws();const xr=e=>typeof e=="object"&&e!=null&&e.nodeType===1,br=(e,n)=>(!n||e!=="hidden")&&e!=="visible"&&e!=="clip",wt=(e,n)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){const i=getComputedStyle(e,null);return br(i.overflowY,n)||br(i.overflowX,n)||(r=>{const o=(t=>{if(!t.ownerDocument||!t.ownerDocument.defaultView)return null;try{return t.ownerDocument.defaultView.frameElement}catch{return null}})(r);return!!o&&(o.clientHeight<r.scrollHeight||o.clientWidth<r.scrollWidth)})(e)}return!1},Nt=(e,n,i,r,o,t,s,c)=>t<e&&s>n||t>e&&s<n?0:t<=e&&c<=i||s>=n&&c>=i?t-e-r:s>n&&c<i||t<e&&c>i?s-n+o:0,Gs=e=>{const n=e.parentElement;return n??(e.getRootNode().host||null)},qs=(e,n)=>{var i,r,o,t;if(typeof document>"u")return[];const{inline:s,boundary:c,skipOverflowHiddenElements:l}=n,u=typeof c=="function"?c:P=>P!==c;if(!xr(e))throw new TypeError("Invalid target");const f=document.scrollingElement||document.documentElement,p=[];let h=e;for(;xr(h)&&u(h);){if(h=Gs(h),h===f){p.push(h);break}h!=null&&h===document.body&&wt(h)&&!wt(document.documentElement)||h!=null&&wt(h,l)&&p.push(h)}const x=(r=(i=window.visualViewport)==null?void 0:i.width)!=null?r:innerWidth,w=(t=(o=window.visualViewport)==null?void 0:o.height)!=null?t:innerHeight,{scrollX:O,scrollY:E}=window,{height:M,width:_,top:y,right:T,bottom:m,left:R}=e.getBoundingClientRect(),{top:J,right:L,left:X}=(P=>{const D=window.getComputedStyle(P);return{top:parseFloat(D.scrollMarginTop)||0,right:parseFloat(D.scrollMarginRight)||0,bottom:parseFloat(D.scrollMarginBottom)||0,left:parseFloat(D.scrollMarginLeft)||0}})(e);let W=y-J,q=s==="center"?R+_/2-X+L:s==="end"?T+L:R-X;const te=[];for(let P=0;P<p.length;P++){const D=p[P],{height:re,width:ie,top:ne,right:V,bottom:$,left:C}=D.getBoundingClientRect();if(y>=0&&R>=0&&m<=w&&T<=x&&(D===f&&!wt(D)||y>=ne&&m<=$&&R>=C&&T<=V))return te;const I=getComputedStyle(D),U=parseInt(I.borderLeftWidth,10),Y=parseInt(I.borderTopWidth,10),H=parseInt(I.borderRightWidth,10),Z=parseInt(I.borderBottomWidth,10);let k=0,F=0;const B="offsetWidth"in D?D.offsetWidth-D.clientWidth-U-H:0,ee="offsetHeight"in D?D.offsetHeight-D.clientHeight-Y-Z:0,G="offsetWidth"in D?D.offsetWidth===0?0:ie/D.offsetWidth:0,ce="offsetHeight"in D?D.offsetHeight===0?0:re/D.offsetHeight:0;if(f===D)k=Nt(E,E+w,w,Y,Z,E+W,E+W+M,M),F=s==="start"?q:s==="center"?q-x/2:s==="end"?q-x:Nt(O,O+x,x,U,H,O+q,O+q+_,_),k=Math.max(0,k+E),F=Math.max(0,F+O);else{k=Nt(ne,$,re,Y,Z+ee,W,W+M,M),F=s==="start"?q-C-U:s==="center"?q-(C+ie/2)+B/2:s==="end"?q-V+H+B:Nt(C,V,ie,U,H+B,q,q+_,_);const{scrollLeft:N,scrollTop:ge}=D;k=ce===0?0:Math.max(0,Math.min(ge+k/ce,D.scrollHeight-re/ce+ee)),F=G===0?0:Math.max(0,Math.min(N+F/G,D.scrollWidth-ie/G+B)),W+=ge-k,q+=N-F}te.push({el:D,top:k,left:F})}return te};var it=function(){return it=Object.assign||function(n){for(var i,r=1,o=arguments.length;r<o;r++){i=arguments[r];for(var t in i)Object.prototype.hasOwnProperty.call(i,t)&&(n[t]=i[t])}return n},it.apply(this,arguments)};var Zs=0;function Ir(e){return typeof e=="function"?e:De}function De(){}function Kr(e,n){if(e){var i=qs(e,{boundary:n});i.forEach(function(r){var o=r.el,t=r.top,s=r.left;o.scrollTop=t,o.scrollLeft=s})}}function wr(e,n,i){var r=e===n||n instanceof i.Node&&e.contains&&e.contains(n);return r}function Kt(e,n){var i;function r(){i&&clearTimeout(i)}function o(){for(var t=arguments.length,s=new Array(t),c=0;c<t;c++)s[c]=arguments[c];r(),i=setTimeout(function(){i=null,e.apply(void 0,s)},n)}return o.cancel=r,o}function Te(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return function(r){for(var o=arguments.length,t=new Array(o>1?o-1:0),s=1;s<o;s++)t[s-1]=arguments[s];return n.some(function(c){return c&&c.apply(void 0,[r].concat(t)),r.preventDownshiftDefault||r.hasOwnProperty("nativeEvent")&&r.nativeEvent.preventDownshiftDefault})}}function ft(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return function(r){n.forEach(function(o){typeof o=="function"?o(r):o&&(o.current=r)})}}function Wr(){return String(Zs++)}function Js(e){var n=e.isOpen,i=e.resultCount,r=e.previousResultCount;return n?i?i!==r?i+" result"+(i===1?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":""}function Nr(e,n){return e=Array.isArray(e)?e[0]:e,!e&&n?n:e}function Gr(e){return typeof e.type=="string"}function qr(e){return e.props}function Xs(e,n){console.error('The property "'+n+'" is required in "'+e+'"')}var Qs=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Ot(e){e===void 0&&(e={});var n={};return Qs.forEach(function(i){e.hasOwnProperty(i)&&(n[i]=e[i])}),n}function Vt(e,n){return!e||!n?e:Object.keys(e).reduce(function(i,r){return i[r]=hn(n,r)?n[r]:e[r],i},{})}function hn(e,n){return e[n]!==void 0}function mn(e){var n=e.key,i=e.keyCode;return i>=37&&i<=40&&n.indexOf("Arrow")!==0?"Arrow"+n:n}function ea(e){return Object.prototype.toString.call(e)==="[object Object]"}function qe(e,n,i,r,o){o===void 0&&(o=!1);var t=i.length;if(t===0)return-1;var s=t-1;(typeof e!="number"||e<0||e>s)&&(e=n>0?-1:s+1);var c=e+n;c<0?c=o?s:0:c>s&&(c=o?0:s);var l=ot(c,n<0,i,r,o);return l===-1?e>=t?-1:e:l}function ot(e,n,i,r,o){o===void 0&&(o=!1);var t=i.length;if(n){for(var s=e;s>=0;s--)if(!r(i[s],s))return s}else for(var c=e;c<t;c++)if(!r(i[c],c))return c;return o?ot(n?t-1:0,n,i,r):-1}function Ht(e,n,i,r){return r===void 0&&(r=!0),i&&n.some(function(o){return o&&(wr(o,e,i)||r&&wr(o,i.document.activeElement,i))})}var bn=De;process.env.NODE_ENV!=="production"&&(bn=function(n,i,r){var o="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(n).forEach(function(t){i[t]!==void 0&&r[t]===void 0?console.error('downshift: A component has changed the controlled prop "'+t+'" to be uncontrolled. '+o):i[t]===void 0&&r[t]!==void 0&&console.error('downshift: A component has changed the uncontrolled prop "'+t+'" to be controlled. '+o)})});var ta=Kt(function(e){Zr(e).textContent=""},500);function Zr(e){var n=e.getElementById("a11y-status-message");return n||(n=e.createElement("div"),n.setAttribute("id","a11y-status-message"),n.setAttribute("role","status"),n.setAttribute("aria-live","polite"),n.setAttribute("aria-relevant","additions text"),Object.assign(n.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(n),n)}function Jr(e,n){if(!(!e||!n)){var i=Zr(n);i.textContent=e,ta(n)}}function na(e){var n=e?.getElementById("a11y-status-message");n&&n.remove()}var Xr=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,Qr=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,ei=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Rt=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,At=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,ti=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,ni=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,ri=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,ii=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,oi=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,si=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,ai=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,ci=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,gn=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,li=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,ui=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,di=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16,ra=Object.freeze({__proto__:null,blurButton:li,blurInput:si,changeInput:ai,clickButton:gn,clickItem:oi,controlledPropUpdatedSelectedItem:ui,itemMouseEnter:ei,keyDownArrowDown:At,keyDownArrowUp:Rt,keyDownEnd:ii,keyDownEnter:ni,keyDownEscape:ti,keyDownHome:ri,keyDownSpaceButton:ci,mouseUp:Qr,touchEnd:di,unknown:Xr}),ia=["refKey","ref"],oa=["onClick","onPress","onKeyDown","onKeyUp","onBlur"],sa=["onKeyDown","onBlur","onChange","onInput","onChangeText"],aa=["refKey","ref"],ca=["onMouseMove","onMouseDown","onClick","onPress","index","item"],la=(function(){var e=(function(n){function i(o){var t;t=n.call(this,o)||this,t.id=t.props.id||"downshift-"+Wr(),t.menuId=t.props.menuId||t.id+"-menu",t.labelId=t.props.labelId||t.id+"-label",t.inputId=t.props.inputId||t.id+"-input",t.getItemId=t.props.getItemId||function(_){return t.id+"-item-"+_},t.items=[],t.itemCount=null,t.previousResultCount=0,t.timeoutIds=[],t.internalSetTimeout=function(_,y){var T=setTimeout(function(){t.timeoutIds=t.timeoutIds.filter(function(m){return m!==T}),_()},y);t.timeoutIds.push(T)},t.setItemCount=function(_){t.itemCount=_},t.unsetItemCount=function(){t.itemCount=null},t.isItemDisabled=function(_,y){var T=t.getItemNodeFromIndex(y);return T&&T.hasAttribute("disabled")},t.setHighlightedIndex=function(_,y){_===void 0&&(_=t.props.defaultHighlightedIndex),y===void 0&&(y={}),y=Ot(y),t.internalSetState(oe({highlightedIndex:_},y))},t.clearSelection=function(_){t.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:t.props.defaultHighlightedIndex,isOpen:t.props.defaultIsOpen},_)},t.selectItem=function(_,y,T){y=Ot(y),t.internalSetState(oe({isOpen:t.props.defaultIsOpen,highlightedIndex:t.props.defaultHighlightedIndex,selectedItem:_,inputValue:t.props.itemToString(_)},y),T)},t.selectItemAtIndex=function(_,y,T){var m=t.items[_];m!=null&&t.selectItem(m,y,T)},t.selectHighlightedItem=function(_,y){return t.selectItemAtIndex(t.getState().highlightedIndex,_,y)},t.internalSetState=function(_,y){var T,m,R={},J=typeof _=="function";return!J&&_.hasOwnProperty("inputValue")&&t.props.onInputValueChange(_.inputValue,oe({},t.getStateAndHelpers(),_)),t.setState(function(L){var X;L=t.getState(L);var W=J?_(L):_;W=t.props.stateReducer(L,W),T=W.hasOwnProperty("selectedItem");var q={};return T&&W.selectedItem!==L.selectedItem&&(m=W.selectedItem),(X=W).type||(X.type=Xr),Object.keys(W).forEach(function(te){L[te]!==W[te]&&(R[te]=W[te]),te!=="type"&&(W[te],hn(t.props,te)||(q[te]=W[te]))}),J&&W.hasOwnProperty("inputValue")&&t.props.onInputValueChange(W.inputValue,oe({},t.getStateAndHelpers(),W)),q},function(){Ir(y)();var L=Object.keys(R).length>1;L&&t.props.onStateChange(R,t.getStateAndHelpers()),T&&t.props.onSelect(_.selectedItem,t.getStateAndHelpers()),m!==void 0&&t.props.onChange(m,t.getStateAndHelpers()),t.props.onUserAction(R,t.getStateAndHelpers())})},t.rootRef=function(_){return t._rootNode=_},t.getRootProps=function(_,y){var T,m=_===void 0?{}:_,R=m.refKey,J=R===void 0?"ref":R,L=m.ref,X=ke(m,ia),W=y===void 0?{}:y,q=W.suppressRefError,te=q===void 0?!1:q;t.getRootProps.called=!0,t.getRootProps.refKey=J,t.getRootProps.suppressRefError=te;var P=t.getState(),D=P.isOpen;return oe((T={},T[J]=ft(L,t.rootRef),T.role="combobox",T["aria-expanded"]=D,T["aria-haspopup"]="listbox",T["aria-owns"]=D?t.menuId:void 0,T["aria-labelledby"]=t.labelId,T),X)},t.keyDownHandlers={ArrowDown:function(y){var T=this;if(y.preventDefault(),this.getState().isOpen){var m=y.shiftKey?5:1;this.moveHighlightedIndex(m,{type:At})}else this.internalSetState({isOpen:!0,type:At},function(){var R=T.getItemCount();if(R>0){var J=T.getState(),L=J.highlightedIndex,X=qe(L,1,{length:R},T.isItemDisabled,!0);T.setHighlightedIndex(X,{type:At})}})},ArrowUp:function(y){var T=this;if(y.preventDefault(),this.getState().isOpen){var m=y.shiftKey?-5:-1;this.moveHighlightedIndex(m,{type:Rt})}else this.internalSetState({isOpen:!0,type:Rt},function(){var R=T.getItemCount();if(R>0){var J=T.getState(),L=J.highlightedIndex,X=qe(L,-1,{length:R},T.isItemDisabled,!0);T.setHighlightedIndex(X,{type:Rt})}})},Enter:function(y){if(y.which!==229){var T=this.getState(),m=T.isOpen,R=T.highlightedIndex;if(m&&R!=null){y.preventDefault();var J=this.items[R],L=this.getItemNodeFromIndex(R);if(J==null||L&&L.hasAttribute("disabled"))return;this.selectHighlightedItem({type:ni})}}},Escape:function(y){y.preventDefault(),this.reset(oe({type:ti},!this.state.isOpen&&{selectedItem:null,inputValue:""}))}},t.buttonKeyDownHandlers=oe({},t.keyDownHandlers,{" ":function(y){y.preventDefault(),this.toggleMenu({type:ci})}}),t.inputKeyDownHandlers=oe({},t.keyDownHandlers,{Home:function(y){var T=this.getState(),m=T.isOpen;if(m){y.preventDefault();var R=this.getItemCount();if(!(R<=0||!m)){var J=ot(0,!1,{length:R},this.isItemDisabled);this.setHighlightedIndex(J,{type:ri})}}},End:function(y){var T=this.getState(),m=T.isOpen;if(m){y.preventDefault();var R=this.getItemCount();if(!(R<=0||!m)){var J=ot(R-1,!0,{length:R},this.isItemDisabled);this.setHighlightedIndex(J,{type:ii})}}}}),t.getToggleButtonProps=function(_){var y=_===void 0?{}:_,T=y.onClick;y.onPress;var m=y.onKeyDown,R=y.onKeyUp,J=y.onBlur,L=ke(y,oa),X=t.getState(),W=X.isOpen,q={onClick:Te(T,t.buttonHandleClick),onKeyDown:Te(m,t.buttonHandleKeyDown),onKeyUp:Te(R,t.buttonHandleKeyUp),onBlur:Te(J,t.buttonHandleBlur)},te=L.disabled?{}:q;return oe({type:"button",role:"button","aria-label":W?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},te,L)},t.buttonHandleKeyUp=function(_){_.preventDefault()},t.buttonHandleKeyDown=function(_){var y=mn(_);t.buttonKeyDownHandlers[y]&&t.buttonKeyDownHandlers[y].call(t,_)},t.buttonHandleClick=function(_){if(_.preventDefault(),t.props.environment){var y=t.props.environment.document,T=y.body,m=y.activeElement;T&&T===m&&_.target.focus()}process.env.NODE_ENV==="test"?t.toggleMenu({type:gn}):t.internalSetTimeout(function(){return t.toggleMenu({type:gn})})},t.buttonHandleBlur=function(_){var y=_.target;t.internalSetTimeout(function(){if(!(t.isMouseDown||!t.props.environment)){var T=t.props.environment.document.activeElement;(T==null||T.id!==t.inputId)&&T!==y&&t.reset({type:li})}})},t.getLabelProps=function(_){return oe({htmlFor:t.inputId,id:t.labelId},_)},t.getInputProps=function(_){var y=_===void 0?{}:_,T=y.onKeyDown,m=y.onBlur,R=y.onChange,J=y.onInput;y.onChangeText;var L=ke(y,sa),X,W={};X="onChange";var q=t.getState(),te=q.inputValue,P=q.isOpen,D=q.highlightedIndex;if(!L.disabled){var re;W=(re={},re[X]=Te(R,J,t.inputHandleChange),re.onKeyDown=Te(T,t.inputHandleKeyDown),re.onBlur=Te(m,t.inputHandleBlur),re)}return oe({"aria-autocomplete":"list","aria-activedescendant":P&&typeof D=="number"&&D>=0?t.getItemId(D):void 0,"aria-controls":P?t.menuId:void 0,"aria-labelledby":L&&L["aria-label"]?void 0:t.labelId,autoComplete:"off",value:te,id:t.inputId},W,L)},t.inputHandleKeyDown=function(_){var y=mn(_);y&&t.inputKeyDownHandlers[y]&&t.inputKeyDownHandlers[y].call(t,_)},t.inputHandleChange=function(_){t.internalSetState({type:ai,isOpen:!0,inputValue:_.target.value,highlightedIndex:t.props.defaultHighlightedIndex})},t.inputHandleBlur=function(){t.internalSetTimeout(function(){var _;if(!(t.isMouseDown||!t.props.environment)){var y=t.props.environment.document.activeElement,T=(y==null||(_=y.dataset)==null?void 0:_.toggle)&&t._rootNode&&t._rootNode.contains(y);T||t.reset({type:si})}})},t.menuRef=function(_){t._menuNode=_},t.getMenuProps=function(_,y){var T,m=_===void 0?{}:_,R=m.refKey,J=R===void 0?"ref":R,L=m.ref,X=ke(m,aa),W=y===void 0?{}:y,q=W.suppressRefError,te=q===void 0?!1:q;return t.getMenuProps.called=!0,t.getMenuProps.refKey=J,t.getMenuProps.suppressRefError=te,oe((T={},T[J]=ft(L,t.menuRef),T.role="listbox",T["aria-labelledby"]=X&&X["aria-label"]?void 0:t.labelId,T.id=t.menuId,T),X)},t.getItemProps=function(_){var y,T=_===void 0?{}:_,m=T.onMouseMove,R=T.onMouseDown,J=T.onClick;T.onPress;var L=T.index,X=T.item,W=X===void 0?process.env.NODE_ENV==="production"?void 0:Xs("getItemProps","item"):X,q=ke(T,ca);L===void 0?(t.items.push(W),L=t.items.indexOf(W)):t.items[L]=W;var te="onClick",P=J,D=(y={onMouseMove:Te(m,function(){L!==t.getState().highlightedIndex&&(t.setHighlightedIndex(L,{type:ei}),t.avoidScrolling=!0,t.internalSetTimeout(function(){return t.avoidScrolling=!1},250))}),onMouseDown:Te(R,function(ie){ie.preventDefault()})},y[te]=Te(P,function(){t.selectItemAtIndex(L,{type:oi})}),y),re=q.disabled?{onMouseDown:D.onMouseDown}:D;return oe({id:t.getItemId(L),role:"option","aria-selected":t.getState().highlightedIndex===L},re,q)},t.clearItems=function(){t.items=[]},t.reset=function(_,y){_===void 0&&(_={}),_=Ot(_),t.internalSetState(function(T){var m=T.selectedItem;return oe({isOpen:t.props.defaultIsOpen,highlightedIndex:t.props.defaultHighlightedIndex,inputValue:t.props.itemToString(m)},_)},y)},t.toggleMenu=function(_,y){_===void 0&&(_={}),_=Ot(_),t.internalSetState(function(T){var m=T.isOpen;return oe({isOpen:!m},m&&{highlightedIndex:t.props.defaultHighlightedIndex},_)},function(){var T=t.getState(),m=T.isOpen,R=T.highlightedIndex;m&&t.getItemCount()>0&&typeof R=="number"&&t.setHighlightedIndex(R,_),Ir(y)()})},t.openMenu=function(_){t.internalSetState({isOpen:!0},_)},t.closeMenu=function(_){t.internalSetState({isOpen:!1},_)},t.updateStatus=Kt(function(){var _;if((_=t.props)!=null&&(_=_.environment)!=null&&_.document){var y=t.getState(),T=t.items[y.highlightedIndex],m=t.getItemCount(),R=t.props.getA11yStatusMessage(oe({itemToString:t.props.itemToString,previousResultCount:t.previousResultCount,resultCount:m,highlightedItem:T},y));t.previousResultCount=m,Jr(R,t.props.environment.document)}},200);var s=t.props,c=s.defaultHighlightedIndex,l=s.initialHighlightedIndex,u=l===void 0?c:l,f=s.defaultIsOpen,p=s.initialIsOpen,h=p===void 0?f:p,x=s.initialInputValue,w=x===void 0?"":x,O=s.initialSelectedItem,E=O===void 0?null:O,M=t.getState({highlightedIndex:u,isOpen:h,inputValue:w,selectedItem:E});return M.selectedItem!=null&&t.props.initialInputValue===void 0&&(M.inputValue=t.props.itemToString(M.selectedItem)),t.state=M,t}Yt(i,n);var r=i.prototype;return r.internalClearTimeouts=function(){this.timeoutIds.forEach(function(t){clearTimeout(t)}),this.timeoutIds=[]},r.getState=function(t){return t===void 0&&(t=this.state),Vt(t,this.props)},r.getItemCount=function(){var t=this.items.length;return this.itemCount!=null?t=this.itemCount:this.props.itemCount!==void 0&&(t=this.props.itemCount),t},r.getItemNodeFromIndex=function(t){return this.props.environment?this.props.environment.document.getElementById(this.getItemId(t)):null},r.scrollHighlightedItemIntoView=function(){{var t=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(t,this._menuNode)}},r.moveHighlightedIndex=function(t,s){var c=this.getItemCount(),l=this.getState(),u=l.highlightedIndex;if(c>0){var f=qe(u,t,{length:c},this.isItemDisabled,!0);this.setHighlightedIndex(f,s)}},r.getStateAndHelpers=function(){var t=this.getState(),s=t.highlightedIndex,c=t.inputValue,l=t.selectedItem,u=t.isOpen,f=this.props.itemToString,p=this.id,h=this.getRootProps,x=this.getToggleButtonProps,w=this.getLabelProps,O=this.getMenuProps,E=this.getInputProps,M=this.getItemProps,_=this.openMenu,y=this.closeMenu,T=this.toggleMenu,m=this.selectItem,R=this.selectItemAtIndex,J=this.selectHighlightedItem,L=this.setHighlightedIndex,X=this.clearSelection,W=this.clearItems,q=this.reset,te=this.setItemCount,P=this.unsetItemCount,D=this.internalSetState;return{getRootProps:h,getToggleButtonProps:x,getLabelProps:w,getMenuProps:O,getInputProps:E,getItemProps:M,reset:q,openMenu:_,closeMenu:y,toggleMenu:T,selectItem:m,selectItemAtIndex:R,selectHighlightedItem:J,setHighlightedIndex:L,clearSelection:X,clearItems:W,setItemCount:te,unsetItemCount:P,setState:D,itemToString:f,id:p,highlightedIndex:s,inputValue:c,isOpen:u,selectedItem:l}},r.componentDidMount=function(){var t=this;if(process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&Or(this._menuNode,this.getMenuProps),!this.props.environment)this.cleanup=function(){t.internalClearTimeouts()};else{var s=function(){t.isMouseDown=!0},c=function(x){t.isMouseDown=!1;var w=Ht(x.target,[t._rootNode,t._menuNode],t.props.environment);!w&&t.getState().isOpen&&t.reset({type:Qr},function(){return t.props.onOuterClick(t.getStateAndHelpers())})},l=function(){t.isTouchMove=!1},u=function(){t.isTouchMove=!0},f=function(x){var w=Ht(x.target,[t._rootNode,t._menuNode],t.props.environment,!1);!t.isTouchMove&&!w&&t.getState().isOpen&&t.reset({type:di},function(){return t.props.onOuterClick(t.getStateAndHelpers())})},p=this.props.environment;p.addEventListener("mousedown",s),p.addEventListener("mouseup",c),p.addEventListener("touchstart",l),p.addEventListener("touchmove",u),p.addEventListener("touchend",f),this.cleanup=function(){t.internalClearTimeouts(),t.updateStatus.cancel(),p.removeEventListener("mousedown",s),p.removeEventListener("mouseup",c),p.removeEventListener("touchstart",l),p.removeEventListener("touchmove",u),p.removeEventListener("touchend",f)}}},r.shouldScroll=function(t,s){var c=this.props.highlightedIndex===void 0?this.getState():this.props,l=c.highlightedIndex,u=s.highlightedIndex===void 0?t:s,f=u.highlightedIndex,p=l&&this.getState().isOpen&&!t.isOpen,h=l!==f;return p||h},r.componentDidUpdate=function(t,s){process.env.NODE_ENV!=="production"&&(bn(this.state,t,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&Or(this._menuNode,this.getMenuProps)),hn(this.props,"selectedItem")&&this.props.selectedItemChanged(t.selectedItem,this.props.selectedItem)&&this.internalSetState({type:ui,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(s,t)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},r.componentWillUnmount=function(){this.cleanup()},r.render=function(){var t=Nr(this.props.children,De);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var s=Nr(t(this.getStateAndHelpers()));if(!s)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&ua(s,this.getRootProps),s;if(Gr(s))return g.cloneElement(s,this.getRootProps(qr(s)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")},i})(g.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:Js,itemToString:function(i){return i==null?"":(process.env.NODE_ENV!=="production"&&ea(i)&&!i.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",i),String(i))},onStateChange:De,onInputValueChange:De,onUserAction:De,onChange:De,onSelect:De,onOuterClick:De,selectedItemChanged:function(i,r){return i!==r},environment:typeof window>"u"?void 0:window,stateReducer:function(i,r){return r},suppressRefError:!1,scrollIntoView:Kr},e.stateChangeTypes=ra,e})();process.env.NODE_ENV!=="production"&&(la.propTypes={children:v.func,defaultHighlightedIndex:v.number,defaultIsOpen:v.bool,initialHighlightedIndex:v.number,initialSelectedItem:v.any,initialInputValue:v.string,initialIsOpen:v.bool,getA11yStatusMessage:v.func,itemToString:v.func,onChange:v.func,onSelect:v.func,onStateChange:v.func,onInputValueChange:v.func,onUserAction:v.func,onOuterClick:v.func,selectedItemChanged:v.func,stateReducer:v.func,itemCount:v.number,id:v.string,environment:v.shape({addEventListener:v.func.isRequired,removeEventListener:v.func.isRequired,document:v.shape({createElement:v.func.isRequired,getElementById:v.func.isRequired,activeElement:v.any.isRequired,body:v.any.isRequired}).isRequired,Node:v.func.isRequired}),suppressRefError:v.bool,scrollIntoView:v.func,selectedItem:v.any,isOpen:v.bool,inputValue:v.string,highlightedIndex:v.number,labelId:v.string,inputId:v.string,menuId:v.string,getItemId:v.func});function Or(e,n){var i=n.refKey;e||console.error('downshift: The ref prop "'+i+'" from getMenuProps was not applied correctly on your menu element.')}function ua(e,n){var i=n.refKey,r=i!=="ref",o=!Gr(e);o&&!r&&!Tr.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!o&&r&&console.error('downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "'+i+'"'),!Tr.isForwardRef(e)&&!qr(e)[i]&&console.error('downshift: You must apply the ref prop "'+i+'" from getRootProps onto your root element.')}var fi={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""};function da(e,n,i){var r=e.props,o=e.type,t={};Object.keys(n).forEach(function(s){fa(s,e,n,i),i[s]!==n[s]&&(t[s]=i[s])}),r.onStateChange&&Object.keys(t).length&&r.onStateChange(oe({type:o},t))}function fa(e,n,i,r){var o=n.props,t=n.type,s="on"+In(e)+"Change";o[s]&&r[e]!==void 0&&r[e]!==i[e]&&o[s](oe({type:t},r))}function pa(e,n){return n.changes}var Sr=Kt(function(e,n){Jr(e,n)},200),ha=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?g.useLayoutEffect:g.useEffect,ma="useId"in g?function(n){var i=n.id,r=n.labelId,o=n.menuId,t=n.getItemId,s=n.toggleButtonId,c=n.inputId,l="downshift-"+g.useId();i||(i=l);var u=g.useRef({labelId:r||i+"-label",menuId:o||i+"-menu",getItemId:t||function(f){return i+"-item-"+f},toggleButtonId:s||i+"-toggle-button",inputId:c||i+"-input"});return u.current}:function(n){var i=n.id,r=i===void 0?"downshift-"+Wr():i,o=n.labelId,t=n.menuId,s=n.getItemId,c=n.toggleButtonId,l=n.inputId,u=g.useRef({labelId:o||r+"-label",menuId:t||r+"-menu",getItemId:s||function(f){return r+"-item-"+f},toggleButtonId:c||r+"-toggle-button",inputId:l||r+"-input"});return u.current};function ga(e,n,i,r){var o,t;if(e===void 0){if(n===void 0)throw new Error(r);o=i[n],t=n}else t=n===void 0?i.indexOf(e):n,o=e;return[o,t]}function va(e){return/^\S{1}$/.test(e)}function In(e){return""+e.slice(0,1).toUpperCase()+e.slice(1)}function pi(e){var n=g.useRef(e);return n.current=e,n}function _a(e,n,i,r){var o=g.useRef(),t=g.useRef(),s=g.useCallback(function(x,w){t.current=w,x=Vt(x,w.props);var O=e(x,w),E=w.props.stateReducer(x,oe({},w,{changes:O}));return E},[e]),c=g.useReducer(s,n,i),l=c[0],u=c[1],f=pi(n),p=g.useCallback(function(x){return u(oe({props:f.current},x))},[f]),h=t.current;return g.useEffect(function(){var x=Vt(o.current,h?.props),w=h&&o.current&&!r(x,l);w&&da(h,x,l),o.current=l},[l,h,r]),[l,p]}function Ca(e,n,i,r){var o=_a(e,n,i,r),t=o[0],s=o[1];return[Vt(t,n),s]}var pt={itemToString:function(n){return n?String(n):""},itemToKey:function(n){return n},stateReducer:pa,scrollIntoView:Kr,environment:typeof window>"u"?void 0:window};function Be(e,n,i){i===void 0&&(i=fi);var r=e["default"+In(n)];return r!==void 0?r:i[n]}function ht(e,n,i){i===void 0&&(i=fi);var r=e[n];if(r!==void 0)return r;var o=e["initial"+In(n)];return o!==void 0?o:Be(e,n,i)}function Ea(e){var n=ht(e,"selectedItem"),i=ht(e,"isOpen"),r=Ia(e),o=ht(e,"inputValue");return{highlightedIndex:r<0&&n&&i?e.items.findIndex(function(t){return e.itemToKey(t)===e.itemToKey(n)}):r,isOpen:i,selectedItem:n,inputValue:o}}function $t(e,n,i){var r=e.items,o=e.initialHighlightedIndex,t=e.defaultHighlightedIndex,s=e.isItemDisabled,c=e.itemToKey,l=n.selectedItem,u=n.highlightedIndex;return r.length===0?-1:o!==void 0&&u===o&&!s(r[o],o)?o:t!==void 0&&!s(r[t],t)?t:l?r.findIndex(function(f){return c(l)===c(f)}):i<0&&!s(r[r.length-1],r.length-1)?r.length-1:i>0&&!s(r[0],0)?0:-1}function ya(e,n,i){var r=g.useRef({isMouseDown:!1,isTouchMove:!1,isTouchEnd:!1});return g.useEffect(function(){if(!e)return De;var o=i.map(function(f){return f.current});function t(){r.current.isTouchEnd=!1,r.current.isMouseDown=!0}function s(f){r.current.isMouseDown=!1,Ht(f.target,o,e)||n()}function c(){r.current.isTouchEnd=!1,r.current.isTouchMove=!1}function l(){r.current.isTouchMove=!0}function u(f){r.current.isTouchEnd=!0,!r.current.isTouchMove&&!Ht(f.target,o,e,!1)&&n()}return e.addEventListener("mousedown",t),e.addEventListener("mouseup",s),e.addEventListener("touchstart",c),e.addEventListener("touchmove",l),e.addEventListener("touchend",u),function(){e.removeEventListener("mousedown",t),e.removeEventListener("mouseup",s),e.removeEventListener("touchstart",c),e.removeEventListener("touchmove",l),e.removeEventListener("touchend",u)}},[i,e,n]),r.current}var hi=function(){return De};process.env.NODE_ENV!=="production"&&(hi=function(){for(var n=arguments.length,i=new Array(n),r=0;r<n;r++)i[r]=arguments[r];var o=g.useRef(i.reduce(function(s,c){return s[c]={},s},{}));g.useEffect(function(){Object.keys(o.current).forEach(function(s){var c=o.current[s];if(!Object.keys(c).length){console.error("downshift: You forgot to call the "+s+" getter function on your component / element.");return}var l=c.suppressRefError,u=c.refKey,f=c.elementRef;l||f!=null&&f.current||console.error('downshift: The ref prop "'+u+'" from '+s+" was not applied correctly on your element.")})},[]);var t=g.useCallback(function(s,c,l,u){o.current[s]={suppressRefError:c,refKey:l,elementRef:u}},[]);return t});function Ta(e,n,i,r){r===void 0&&(r={});var o=r.document,t=gi();g.useEffect(function(){if(!(!e||t||!o)){var s=e(n);Sr(s,o)}},i),g.useEffect(function(){return function(){Sr.cancel(),na(o)}},[o])}function xa(e){var n=e.highlightedIndex,i=e.isOpen,r=e.itemRefs,o=e.getItemNodeFromIndex,t=e.menuElement,s=e.scrollIntoView,c=g.useRef(!0);return ha(function(){n<0||!i||!Object.keys(r.current).length||(c.current===!1?c.current=!0:s(o(n),t))},[n]),c}var mi=De;process.env.NODE_ENV!=="production"&&(mi=function(n){var i=n.props,r=n.state,o=g.useRef(i),t=gi();g.useEffect(function(){t||(bn(r,o.current,i),o.current=i)},[r,i,t])});function Dr(e,n,i){var r,o=((r=e.items)==null?void 0:r.length)&&n>=0;return oe({isOpen:!1,highlightedIndex:-1},o&&oe({selectedItem:e.items[n],isOpen:Be(e,"isOpen"),highlightedIndex:Be(e,"highlightedIndex")},i))}function ba(e,n){return e.isOpen===n.isOpen&&e.inputValue===n.inputValue&&e.highlightedIndex===n.highlightedIndex&&e.selectedItem===n.selectedItem}function gi(){var e=g.useRef(!0);return g.useEffect(function(){return e.current=!1,function(){e.current=!0}},[]),e.current}function vi(e){var n=Be(e,"highlightedIndex");return n>-1&&e.isItemDisabled(e.items[n],n)?-1:n}function Ia(e){var n=ht(e,"highlightedIndex");return n>-1&&e.isItemDisabled(e.items[n],n)?-1:n}var Mt={environment:v.shape({addEventListener:v.func.isRequired,removeEventListener:v.func.isRequired,document:v.shape({createElement:v.func.isRequired,getElementById:v.func.isRequired,activeElement:v.any.isRequired,body:v.any.isRequired}).isRequired,Node:v.func.isRequired}),itemToString:v.func,itemToKey:v.func,stateReducer:v.func},_i=oe({},Mt,{getA11yStatusMessage:v.func,highlightedIndex:v.number,defaultHighlightedIndex:v.number,initialHighlightedIndex:v.number,isOpen:v.bool,defaultIsOpen:v.bool,initialIsOpen:v.bool,selectedItem:v.any,initialSelectedItem:v.any,defaultSelectedItem:v.any,id:v.string,labelId:v.string,menuId:v.string,getItemId:v.func,toggleButtonId:v.string,onSelectedItemChange:v.func,onHighlightedIndexChange:v.func,onStateChange:v.func,onIsOpenChange:v.func,scrollIntoView:v.func});function wa(e,n,i){var r=n.type,o=n.props,t;switch(r){case i.ItemMouseMove:t={highlightedIndex:n.disabled?-1:n.index};break;case i.MenuMouseLeave:t={highlightedIndex:-1};break;case i.ToggleButtonClick:case i.FunctionToggleMenu:t={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:$t(o,e,0)};break;case i.FunctionOpenMenu:t={isOpen:!0,highlightedIndex:$t(o,e,0)};break;case i.FunctionCloseMenu:t={isOpen:!1};break;case i.FunctionSetHighlightedIndex:t={highlightedIndex:o.isItemDisabled(o.items[n.highlightedIndex],n.highlightedIndex)?-1:n.highlightedIndex};break;case i.FunctionSetInputValue:t={inputValue:n.inputValue};break;case i.FunctionReset:t={highlightedIndex:vi(o),isOpen:Be(o,"isOpen"),selectedItem:Be(o,"selectedItem"),inputValue:Be(o,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return oe({},e,t)}function Na(e){for(var n=e.keysSoFar,i=e.highlightedIndex,r=e.items,o=e.itemToString,t=e.isItemDisabled,s=n.toLowerCase(),c=0;c<r.length;c++){var l=(c+i+(n.length<2?1:0))%r.length,u=r[l];if(u!==void 0&&o(u).toLowerCase().startsWith(s)&&!t(u,l))return l}return i}var Oa=it(it({},_i),{items:v.array.isRequired,isItemDisabled:v.func}),Sa=it(it({},pt),{isItemDisabled:function(){return!1}}),Ci=De;process.env.NODE_ENV!=="production"&&(Ci=function(e,n){v.checkPropTypes(Oa,e,"prop",n.name)});var kt=process.env.NODE_ENV!=="production"?"__togglebutton_click__":0,wn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_arrow_down__":1,Nn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_arrow_up__":2,Ft=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_character__":3,On=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_escape__":4,Sn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_home__":5,Dn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_end__":6,Pn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_enter__":7,Rn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_space_button__":8,An=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_page_up__":9,Mn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_page_down__":10,Bt=process.env.NODE_ENV!=="production"?"__togglebutton_blur__":11,Ei=process.env.NODE_ENV!=="production"?"__menu_mouse_leave__":12,yi=process.env.NODE_ENV!=="production"?"__item_mouse_move__":13,kn=process.env.NODE_ENV!=="production"?"__item_click__":14,Ti=process.env.NODE_ENV!=="production"?"__function_toggle_menu__":15,xi=process.env.NODE_ENV!=="production"?"__function_open_menu__":16,bi=process.env.NODE_ENV!=="production"?"__function_close_menu__":17,Ii=process.env.NODE_ENV!=="production"?"__function_set_highlighted_index__":18,jn=process.env.NODE_ENV!=="production"?"__function_select_item__":19,vn=process.env.NODE_ENV!=="production"?"__function_set_input_value__":20,wi=process.env.NODE_ENV!=="production"?"__function_reset__":21,Ni=Object.freeze({__proto__:null,FunctionCloseMenu:bi,FunctionOpenMenu:xi,FunctionReset:wi,FunctionSelectItem:jn,FunctionSetHighlightedIndex:Ii,FunctionSetInputValue:vn,FunctionToggleMenu:Ti,ItemClick:kn,ItemMouseMove:yi,MenuMouseLeave:Ei,ToggleButtonBlur:Bt,ToggleButtonClick:kt,ToggleButtonKeyDownArrowDown:wn,ToggleButtonKeyDownArrowUp:Nn,ToggleButtonKeyDownCharacter:Ft,ToggleButtonKeyDownEnd:Dn,ToggleButtonKeyDownEnter:Pn,ToggleButtonKeyDownEscape:On,ToggleButtonKeyDownHome:Sn,ToggleButtonKeyDownPageDown:Mn,ToggleButtonKeyDownPageUp:An,ToggleButtonKeyDownSpaceButton:Rn});function Da(e,n){var i,r=n.type,o=n.props,t=n.altKey,s;switch(r){case kn:s={isOpen:Be(o,"isOpen"),highlightedIndex:vi(o),selectedItem:o.items[n.index]};break;case Ft:{var c=n.key,l=""+e.inputValue+c,u=!e.isOpen&&e.selectedItem?o.items.findIndex(function(x){return o.itemToKey(x)===o.itemToKey(e.selectedItem)}):e.highlightedIndex,f=Na({keysSoFar:l,highlightedIndex:u,items:o.items,itemToString:o.itemToString,isItemDisabled:o.isItemDisabled});s={inputValue:l,highlightedIndex:f,isOpen:!0}}break;case wn:{var p=e.isOpen?qe(e.highlightedIndex,1,o.items,o.isItemDisabled):t&&e.selectedItem==null?-1:$t(o,e,1);s={highlightedIndex:p,isOpen:!0}}break;case Nn:if(e.isOpen&&t)s=Dr(o,e.highlightedIndex,!1);else{var h=e.isOpen?qe(e.highlightedIndex,-1,o.items,o.isItemDisabled):$t(o,e,-1);s={highlightedIndex:h,isOpen:!0}}break;case Pn:case Rn:s=Dr(o,e.highlightedIndex,!1);break;case Sn:s={highlightedIndex:ot(0,!1,o.items,o.isItemDisabled),isOpen:!0};break;case Dn:s={highlightedIndex:ot(o.items.length-1,!0,o.items,o.isItemDisabled),isOpen:!0};break;case An:s={highlightedIndex:qe(e.highlightedIndex,-10,o.items,o.isItemDisabled)};break;case Mn:s={highlightedIndex:qe(e.highlightedIndex,10,o.items,o.isItemDisabled)};break;case On:s={isOpen:!1,highlightedIndex:-1};break;case Bt:s=oe({isOpen:!1,highlightedIndex:-1},e.highlightedIndex>=0&&((i=o.items)==null?void 0:i.length)&&{selectedItem:o.items[e.highlightedIndex]});break;case jn:s={selectedItem:n.selectedItem};break;default:return wa(e,n,Ni)}return oe({},e,s)}var Pa=["onClick"],Ra=["onMouseLeave","refKey","ref"],Aa=["onBlur","onClick","onPress","onKeyDown","refKey","ref"],Ma=["item","index","onMouseMove","onClick","onMouseDown","onPress","refKey","disabled","ref"];Ln.stateChangeTypes=Ni;function Ln(e){e===void 0&&(e={}),Ci(e,Ln);var n=oe({},Sa,e),i=n.scrollIntoView,r=n.environment,o=n.getA11yStatusMessage,t=Ca(Da,n,Ea,ba),s=t[0],c=t[1],l=s.isOpen,u=s.highlightedIndex,f=s.selectedItem,p=s.inputValue,h=g.useRef(null),x=g.useRef(null),w=g.useRef({}),O=g.useRef(null),E=ma(n),M=pi({state:s,props:n}),_=g.useCallback(function(V){return w.current[E.getItemId(V)]},[E]);Ta(o,s,[l,u,f,p],r);var y=xa({menuElement:x.current,highlightedIndex:u,isOpen:l,itemRefs:w,scrollIntoView:i,getItemNodeFromIndex:_});g.useEffect(function(){return O.current=Kt(function(V){V({type:vn,inputValue:""})},500),function(){O.current.cancel()}},[]),g.useEffect(function(){p&&O.current(c)},[c,p]),mi({props:n,state:s}),g.useEffect(function(){var V=ht(n,"isOpen");V&&h.current&&h.current.focus()},[]);var T=ya(r,g.useCallback(function(){M.current.state.isOpen&&c({type:Bt})},[c,M]),g.useMemo(function(){return[x,h]},[x.current,h.current])),m=hi("getMenuProps","getToggleButtonProps");g.useEffect(function(){l||(w.current={})},[l]);var R=g.useMemo(function(){return{ArrowDown:function($){$.preventDefault(),c({type:wn,altKey:$.altKey})},ArrowUp:function($){$.preventDefault(),c({type:Nn,altKey:$.altKey})},Home:function($){$.preventDefault(),c({type:Sn})},End:function($){$.preventDefault(),c({type:Dn})},Escape:function(){M.current.state.isOpen&&c({type:On})},Enter:function($){$.preventDefault(),c({type:M.current.state.isOpen?Pn:kt})},PageUp:function($){M.current.state.isOpen&&($.preventDefault(),c({type:An}))},PageDown:function($){M.current.state.isOpen&&($.preventDefault(),c({type:Mn}))}," ":function($){$.preventDefault();var C=M.current.state;if(!C.isOpen){c({type:kt});return}C.inputValue?c({type:Ft,key:" "}):c({type:Rn})}}},[c,M]),J=g.useCallback(function(){c({type:Ti})},[c]),L=g.useCallback(function(){c({type:bi})},[c]),X=g.useCallback(function(){c({type:xi})},[c]),W=g.useCallback(function(V){c({type:Ii,highlightedIndex:V})},[c]),q=g.useCallback(function(V){c({type:jn,selectedItem:V})},[c]),te=g.useCallback(function(){c({type:wi})},[c]),P=g.useCallback(function(V){c({type:vn,inputValue:V})},[c]),D=g.useCallback(function(V){var $=V===void 0?{}:V,C=$.onClick,I=ke($,Pa),U=function(){var H;(H=h.current)==null||H.focus()};return oe({id:E.labelId,htmlFor:E.toggleButtonId,onClick:Te(C,U)},I)},[E]),re=g.useCallback(function(V,$){var C,I=V===void 0?{}:V,U=I.onMouseLeave,Y=I.refKey,H=Y===void 0?"ref":Y,Z=I.ref,k=ke(I,Ra),F=$===void 0?{}:$,B=F.suppressRefError,ee=B===void 0?!1:B,G=function(){c({type:Ei})};return m("getMenuProps",ee,H,x),oe((C={},C[H]=ft(Z,function(ce){x.current=ce}),C.id=E.menuId,C.role="listbox",C["aria-labelledby"]=k&&k["aria-label"]?void 0:""+E.labelId,C.onMouseLeave=Te(U,G),C),k)},[c,m,E]),ie=g.useCallback(function(V,$){var C,I=V===void 0?{}:V,U=I.onBlur,Y=I.onClick;I.onPress;var H=I.onKeyDown,Z=I.refKey,k=Z===void 0?"ref":Z,F=I.ref,B=ke(I,Aa),ee=$===void 0?{}:$,G=ee.suppressRefError,ce=G===void 0?!1:G,N=M.current.state,ge=function(){c({type:kt})},j=function(){N.isOpen&&!T.isMouseDown&&c({type:Bt})},xe=function(Ue){var Pe=mn(Ue);Pe&&R[Pe]?R[Pe](Ue):va(Pe)&&c({type:Ft,key:Pe})},ve=oe((C={},C[k]=ft(F,function(Ie){h.current=Ie}),C["aria-activedescendant"]=N.isOpen&&N.highlightedIndex>-1?E.getItemId(N.highlightedIndex):"",C["aria-controls"]=E.menuId,C["aria-expanded"]=M.current.state.isOpen,C["aria-haspopup"]="listbox",C["aria-labelledby"]=B&&B["aria-label"]?void 0:""+E.labelId,C.id=E.toggleButtonId,C.role="combobox",C.tabIndex=0,C.onBlur=Te(U,j),C),B);return B.disabled||(ve.onClick=Te(Y,ge),ve.onKeyDown=Te(H,xe)),m("getToggleButtonProps",ce,k,h),ve},[c,E,M,T,m,R]),ne=g.useCallback(function(V){var $,C=V===void 0?{}:V,I=C.item,U=C.index,Y=C.onMouseMove,H=C.onClick,Z=C.onMouseDown;C.onPress;var k=C.refKey,F=k===void 0?"ref":k,B=C.disabled,ee=C.ref,G=ke(C,Ma);B!==void 0&&console.warn('Passing "disabled" as an argument to getItemProps is not supported anymore. Please use the isItemDisabled prop from useSelect.');var ce=M.current,N=ce.state,ge=ce.props,j=ga(I,U,ge.items,"Pass either item or index to getItemProps!"),xe=j[0],ve=j[1],Ie=ge.isItemDisabled(xe,ve),Ue=function(){T.isTouchEnd||ve===N.highlightedIndex||(y.current=!1,c({type:yi,index:ve,disabled:Ie}))},Pe=function(){c({type:kn,index:ve})},qt=function(Zt){return Zt.preventDefault()},Ze=oe(($={},$[F]=ft(ee,function(Ve){Ve&&(w.current[E.getItemId(ve)]=Ve)}),$["aria-disabled"]=Ie,$["aria-selected"]=xe===N.selectedItem,$.id=E.getItemId(ve),$.role="option",$),G);return Ie||(Ze.onClick=Te(H,Pe)),Ze.onMouseMove=Te(Y,Ue),Ze.onMouseDown=Te(Z,qt),Ze},[M,E,T,y,c]);return{getToggleButtonProps:ie,getLabelProps:D,getMenuProps:re,getItemProps:ne,toggleMenu:J,openMenu:X,closeMenu:L,setHighlightedIndex:W,selectItem:q,reset:te,setInputValue:P,highlightedIndex:u,isOpen:l,selectedItem:f,inputValue:p}}process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;oe({},_i,{items:v.array.isRequired,isItemDisabled:v.func,inputValue:v.string,defaultInputValue:v.string,initialInputValue:v.string,inputId:v.string,onInputValueChange:v.func});process.env.NODE_ENV;oe({},pt,{isItemDisabled:function(){return!1}});Mt.stateReducer,Mt.itemToKey,Mt.environment,v.array,v.array,v.array,v.func,v.number,v.number,v.number,v.func,v.func,v.string,v.string;pt.itemToKey,pt.stateReducer,pt.environment;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;const ka="MultiSelect-module_multiSelect",ja="MultiSelect-module_control",La="MultiSelect-module_disabled",Va="MultiSelect-module_valueContainer",Ha="MultiSelect-module_input",$a="MultiSelect-module_multiValue",Fa="MultiSelect-module_multiValueLabel",Ba="MultiSelect-module_multiValueRemove",za="MultiSelect-module_dropdownIndicator",Ua="MultiSelect-module_menu",Ya="MultiSelect-module_menuOpen",Ka="MultiSelect-module_menuList",Wa="MultiSelect-module_groupHeading",Ga="MultiSelect-module_groupSeparator",qa="MultiSelect-module_option",Za="MultiSelect-module_optionLast",Ja="MultiSelect-module_optionSelected",Xa="MultiSelect-module_optionFocused",Qa="MultiSelect-module_optionDisabled",ec="MultiSelect-module_optionLabel",tc="MultiSelect-module_noOptions",he={multiSelect:ka,control:ja,disabled:La,valueContainer:Va,input:Ha,multiValue:$a,multiValueLabel:Fa,multiValueRemove:Ba,dropdownIndicator:za,menu:Ua,menuOpen:Ya,menuList:Ka,groupHeading:Wa,groupSeparator:Ga,option:qa,optionLast:Za,optionSelected:Ja,optionFocused:Xa,optionDisabled:Qa,optionLabel:ec,noOptions:tc},nc=({id:e,name:n,options:i,value:r=[],preferredValues:o=[],placeholder:t="Select...",disabled:s=!1,className:c,onChange:l})=>{const[u,f]=g.useState(!1),[p,h]=g.useState(""),x=g.useRef(null),w=g.useRef(null),O=g.useMemo(()=>new Set(o),[o]),E=g.useMemo(()=>{const P=i.filter(ie=>ie.label.toLowerCase().includes(p.toLowerCase())),D=P.filter(ie=>O.has(ie.value)),re=P.filter(ie=>!O.has(ie.value));return{preferred:D,others:re}},[i,p,O]),M=g.useMemo(()=>i.filter(P=>r.includes(P.value)),[i,r]),{isOpen:_,getToggleButtonProps:y,getMenuProps:T,getItemProps:m,highlightedIndex:R}=Ln({items:[...E.preferred,...E.others],selectedItem:null,onSelectedItemChange:({selectedItem:P})=>{if(P){const D=P.value,re=r.includes(D)?r.filter(ie=>ie!==D):[...r,D];l?.(re)}}});g.useEffect(()=>{f(_)},[_]),g.useEffect(()=>{const P=D=>{w.current&&!w.current.contains(D.target)&&(f(!1),h(""))};return u&&document.addEventListener("mousedown",P),()=>{document.removeEventListener("mousedown",P)}},[u]);const J=P=>{h(P.target.value)},L=P=>{P.key==="Escape"&&(f(!1),h(""),x.current?.blur())},X=P=>{P.stopPropagation(),P.preventDefault()},W=P=>{P.stopPropagation()},q=P=>{const D=r.filter(re=>re!==P);l?.(D)},te=()=>{s||f(!u)};return a.jsxs("div",{ref:w,className:`${he.multiSelect} ${c??""}`,children:[a.jsxs("div",{className:`${he.control} ${s?he.disabled:""}`,children:[a.jsxs("div",{className:he.valueContainer,children:[M.map(P=>a.jsxs("div",{className:he.multiValue,children:[a.jsx("span",{className:he.multiValueLabel,children:P.label}),a.jsx("button",{type:"button",className:he.multiValueRemove,onClick:()=>q(P.value),disabled:s,children:"×"})]},P.value)),a.jsx("input",{ref:x,id:e,name:n,className:he.input,value:p,onChange:J,onKeyDown:L,onFocus:()=>!s&&f(!0),placeholder:M.length===0?t:"",disabled:s,autoComplete:"off"})]}),a.jsx("button",{type:"button",className:he.dropdownIndicator,onClick:te,disabled:s,...y(),children:a.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:a.jsx("polyline",{points:"6,9 12,15 18,9"})})})]}),a.jsx("div",{className:`${he.menu} ${u?he.menuOpen:""}`,...T(),onClick:X,onMouseDown:W,children:a.jsxs("div",{className:he.menuList,children:[E.preferred.length>0&&a.jsxs(a.Fragment,{children:[a.jsx("div",{className:he.groupHeading,children:"Preferred"}),E.preferred.map((P,D)=>{const ie=D===E.preferred.length-1&&E.others.length===0;return a.jsx("div",{className:`${he.option} ${R===D?he.optionFocused:""} ${r.includes(P.value)?he.optionSelected:""} ${P.disabled?he.optionDisabled:""} ${ie?he.optionLast:""}`,onClick:X,...m({item:P,index:D,disabled:P.disabled}),children:a.jsx("span",{className:he.optionLabel,children:P.label})},P.value)})]}),E.others.length>0&&a.jsxs(a.Fragment,{children:[E.preferred.length>0&&a.jsxs(a.Fragment,{children:[a.jsx("div",{className:he.groupSeparator}),a.jsx("div",{className:he.groupHeading,children:"All"})]}),E.others.map((P,D)=>{const re=E.preferred.length+D,ie=D===E.others.length-1;return a.jsx("div",{className:`${he.option} ${R===re?he.optionFocused:""} ${r.includes(P.value)?he.optionSelected:""} ${P.disabled?he.optionDisabled:""} ${ie?he.optionLast:""}`,onClick:X,...m({item:P,index:re,disabled:P.disabled}),children:a.jsx("span",{className:he.optionLabel,children:P.label})},P.value)})]}),E.preferred.length===0&&E.others.length===0&&a.jsx("div",{className:he.noOptions,children:"No options found"})]})})]})},rc="SelectField-module_selectField",ic="SelectField-module_select",Pr={selectField:rc,select:ic},oc=({id:e,name:n,value:i,options:r=[],placeholder:o="Select an option",disabled:t=!1,className:s="",onChange:c,onBlur:l,onFocus:u})=>{const f=p=>{const h=p.target.value,x=r.find(w=>w.value.toString()===h);x&&c&&c(x.value)};return a.jsx("div",{className:`${Pr.selectField} ${s}`,children:a.jsxs("select",{id:e,name:n,value:i||"",disabled:t,onChange:f,onBlur:l,onFocus:u,className:Pr.select,children:[o&&a.jsx("option",{value:"",disabled:!0,children:o}),r.map((p,h)=>a.jsx("option",{value:p.value,disabled:p.disabled,children:p.label},`${h}`))]})})},Rr="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M353.286,163.919c16.464,0,29.815,13.351,29.815,29.822%20c0,16.467-13.351,29.819-29.815,29.819c-16.47,0-29.822-13.352-29.822-29.819C323.464,177.27,336.816,163.919,353.286,163.919%20L353.286,163.919z%20M245.838,163.919c16.47,0,29.822,13.351,29.822,29.822c0,16.467-13.352,29.819-29.822,29.819%20c-16.471,0-29.822-13.352-29.822-29.819C216.016,177.27,229.367,163.919,245.838,163.919L245.838,163.919z%20M354.093,338.178%20c22.575,0,40.874,18.299,40.874,40.87c0,22.571-18.299,40.87-40.874,40.87c-22.568,0-40.867-18.299-40.867-40.87%20C313.226,356.477,331.525,338.178,354.093,338.178L354.093,338.178z%20M245.024,338.178c22.575,0,40.874,18.299,40.874,40.87%20c0,22.571-18.299,40.87-40.874,40.87c-22.568,0-40.874-18.299-40.874-40.87C204.151,356.477,222.457,338.178,245.024,338.178%20L245.024,338.178z%20M406.906,244.769c22.575,0,40.874,18.299,40.874,40.87s-18.299,40.87-40.874,40.87%20c-22.568,0-40.867-18.299-40.867-40.87S384.338,244.769,406.906,244.769L406.906,244.769z%20M192.211,244.769%20c22.568,0,40.874,18.299,40.874,40.87s-18.306,40.87-40.874,40.87c-22.575,0-40.874-18.299-40.874-40.87%20S169.636,244.769,192.211,244.769L192.211,244.769z%20M299.559,244.769c22.575,0,40.874,18.299,40.874,40.87%20s-18.299,40.87-40.874,40.87c-22.569,0-40.868-18.299-40.868-40.87S276.99,244.769,299.559,244.769L299.559,244.769z%20M452.99,131.334H146.127c-32.625,37.291-50.332,84.551-50.332,134.107c0,112.541,91.226,203.765,203.764,203.765%20c112.544,0,203.764-91.223,203.764-203.765C503.323,215.889,485.608,168.622,452.99,131.334L452.99,131.334z%20M471.276,105.109%20l-4.672-4.998h-334.09l-4.672,4.998c-40.739,43.6-63.267,100.662-63.267,160.332c0,129.775,105.21,234.988,234.984,234.988%20c129.774,0,234.984-105.213,234.984-234.988C534.542,205.771,512.015,148.709,471.276,105.109L471.276,105.109z%20M480.204,60.027%20H118.914C61.952,110.158,26,183.596,26,265.441C26,416.523,148.48,539,299.559,539c151.085,0,273.558-122.477,273.558-273.559%20C573.117,183.596,537.165,110.158,480.204,60.027z'/%3e%3c/svg%3e",Ar="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M228.887,396.793c20.779,0,37.62,16.841,37.62,37.617%20c0,20.773-16.841,37.617-37.62,37.617c-20.773,0-37.613-16.844-37.613-37.617C191.274,413.634,208.115,396.793,228.887,396.793%20L228.887,396.793z%20M366.03,396.793c20.773,0,37.614,16.841,37.614,37.617c0,20.773-16.841,37.617-37.614,37.617%20c-20.779,0-37.62-16.844-37.62-37.617C328.41,413.634,345.251,396.793,366.03,396.793L366.03,396.793z%20M228.375,325.684%20c-29.03,0-55.41,11.868-74.52,30.976c-41.566,41.573-41.566,113.923,0,155.497c19.111,19.111,45.49,30.979,74.52,30.979h138.168%20c29.023,0,55.41-11.868,74.521-30.979c41.565-41.566,41.565-113.928,0-155.497c-18.336-18.336-43.379-30.003-71.019-30.916%20c63.723-27.868,105.151-90.836,105.151-160.733c0-42.14-13.276-74.632-37.316-108.359H161.794%20c-24.033,33.747-37.309,66.2-37.309,108.359c0,69.852,41.359,132.758,105.012,160.674H228.375L228.375,325.684z%20M366.543,357.791%20H228.375c-20.163,0-38.513,8.265-51.824,21.569c-29.023,29.027-29.023,81.069,0,110.096c13.311,13.308,31.654,21.569,51.824,21.569%20h138.168c20.17,0,38.513-8.261,51.824-21.569c29.023-29.027,29.023-81.069,0-110.096%20C405.056,366.057,386.706,357.791,366.543,357.791L366.543,357.791z%20M421.17,88.762c14.523,23.018,21.915,49.024,21.915,76.248%20c0,79.121-64.131,143.245-143.248,143.245S156.595,244.127,156.595,165.01c0-27.234,7.392-53.222,21.915-76.248H421.17%20L421.17,88.762z%20M331.075,225.95c11.726,0,21.236,9.511,21.236,21.236c0,11.733-9.511,21.24-21.236,21.24%20c-11.733,0-21.236-9.507-21.236-21.24C309.839,235.461,319.342,225.95,331.075,225.95L331.075,225.95z%20M268.605,225.95%20c11.726,0,21.243,9.511,21.243,21.236c0,11.733-9.518,21.24-21.243,21.24c-11.726,0-21.236-9.507-21.236-21.24%20C247.369,235.461,256.879,225.95,268.605,225.95L268.605,225.95z%20M236.882,163.754c11.726,0,21.243,9.508,21.243,21.236%20c0,11.729-9.518,21.24-21.243,21.24c-11.726,0-21.236-9.511-21.236-21.24C215.646,173.261,225.156,163.754,236.882,163.754%20L236.882,163.754z%20M299.837,163.754c11.732,0,21.243,9.508,21.243,21.236c0,11.729-9.511,21.24-21.243,21.24%20c-11.726,0-21.236-9.511-21.236-21.24C278.6,173.261,288.111,163.754,299.837,163.754L299.837,163.754z%20M362.798,163.754%20c11.726,0,21.236,9.508,21.236,21.236c0,11.729-9.511,21.24-21.236,21.24c-11.733,0-21.236-9.511-21.236-21.24%20C341.562,173.261,351.065,163.754,362.798,163.754L362.798,163.754z%20M332.079,116.228c6.86,0,12.417,5.561,12.417,12.417%20c0,6.86-5.558,12.425-12.417,12.425s-12.424-5.566-12.424-12.425C319.654,121.79,325.219,116.228,332.079,116.228L332.079,116.228z%20M267.601,116.228c6.86,0,12.425,5.561,12.425,12.417c0,6.86-5.565,12.425-12.425,12.425c-6.86,0-12.417-5.566-12.417-12.425%20C255.184,121.79,260.742,116.228,267.601,116.228L267.601,116.228z%20M177.153,7.87C129.219,7.87,90,47.086,90,95.02v408.83%20c0,47.934,39.219,87.15,87.153,87.15h246.024c47.934,0,87.147-39.216,87.147-87.15V95.02c0-47.934-39.213-87.15-87.147-87.15%20H177.153z'/%3e%3c/svg%3e",Mr="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M407.111,334.214c16.317,0,29.543,13.226,29.543,29.543%20c0,16.313-13.227,29.543-29.543,29.543c-16.31,0-29.536-13.229-29.536-29.543C377.576,347.44,390.802,334.214,407.111,334.214%20L407.111,334.214z%20M198.69,334.214c16.317,0,29.543,13.226,29.543,29.543c0,16.313-13.226,29.543-29.543,29.543%20s-29.543-13.229-29.543-29.543C169.147,347.44,182.373,334.214,198.69,334.214L198.69,334.214z%20M227.94,180.772%20c24.971,0,45.213,20.242,45.213,45.213c0,24.967-20.243,45.213-45.213,45.213s-45.213-20.245-45.213-45.213%20C182.727,201.014,202.969,180.772,227.94,180.772L227.94,180.772z%20M377.868,180.772c24.968,0,45.213,20.242,45.213,45.213%20c0,24.967-20.245,45.213-45.213,45.213c-24.974,0-45.213-20.245-45.213-45.213C332.655,201.014,352.894,180.772,377.868,180.772%20L377.868,180.772z%20M302.899,361.142c24.974,0,45.22,20.243,45.22,45.213s-20.245,45.213-45.22,45.213%20c-24.968,0-45.21-20.243-45.21-45.213S277.931,361.142,302.899,361.142L302.899,361.142z%20M302.899,100.142%20c-111.485,0-201.855,90.37-201.855,201.858c0,111.489,90.37,201.859,201.855,201.859c111.491,0,201.865-90.37,201.865-201.859%20C504.764,190.512,414.391,100.142,302.899,100.142L302.899,100.142z%20M302.899,69.21C174.338,69.21,70.113,173.44,70.113,302%20c0,128.561,104.226,232.79,232.787,232.79c128.56,0,232.793-104.229,232.793-232.79C535.692,173.44,431.459,69.21,302.899,69.21%20L302.899,69.21z%20M302.899,31C153.234,31,31.902,152.328,31.902,302c0,149.669,121.331,271,270.997,271%20c149.672,0,271.006-121.331,271.006-271C573.906,152.328,452.571,31,302.899,31z'/%3e%3c/svg%3e",kr="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M246.063,132.777c18.959,0,34.335,15.373,34.335,34.332%20c0,18.965-15.376,34.335-34.335,34.335c-18.961,0-34.332-15.37-34.332-34.335C211.731,148.15,227.102,132.777,246.063,132.777%20L246.063,132.777z%20M357.555,132.777c18.962,0,34.332,15.373,34.332,34.332c0,18.962-15.37,34.335-34.332,34.335%20c-18.961,0-34.331-15.373-34.331-34.335C323.224,148.15,338.594,132.777,357.555,132.777L357.555,132.777z%20M226.875,253.708%20c9.286,0,16.811,7.525,16.811,16.808c0,9.286-7.525,16.811-16.811,16.811c-9.283,0-16.808-7.525-16.808-16.811%20C210.066,261.234,217.592,253.708,226.875,253.708L226.875,253.708z%20M371.359,253.708c9.286,0,16.815,7.525,16.815,16.808%20c0,9.286-7.529,16.811-16.815,16.811c-9.279,0-16.808-7.525-16.808-16.811C354.552,261.234,362.08,253.708,371.359,253.708%20L371.359,253.708z%20M236.304,421.639c19.179,0,34.731,15.548,34.731,34.731c0,19.179-15.552,34.731-34.731,34.731%20c-19.179,0-34.731-15.552-34.731-34.731C201.573,437.187,217.126,421.639,236.304,421.639L236.304,421.639z%20M362.924,421.639%20c19.179,0,34.728,15.548,34.728,34.731c0,19.179-15.549,34.731-34.728,34.731c-19.186,0-34.735-15.552-34.735-34.731%20C328.189,437.187,343.738,421.639,362.924,421.639L362.924,421.639z%20M235.828,355.985c-26.801,0-51.159,10.958-68.804,28.6%20c-38.377,38.383-38.377,105.184,0,143.567c17.645,17.645,42.004,28.602,68.804,28.602h127.568c26.803,0,51.159-10.957,68.804-28.602%20c38.377-38.377,38.377-105.19,0-143.567c-16.91-16.91-39.994-27.679-65.481-28.542c57.148-25.011,97.033-82.036,97.033-148.405%20c0-88.133-70.984-161.938-161.945-161.938c-90.131,0-161.935,73.009-161.935,161.938c0,66.315,39.821,123.302,96.895,148.348%20H235.828L235.828,355.985z%20M159.969,344.666c-6.378,4.464-12.357,9.488-17.866,14.999c-52.137,52.134-52.137,141.271-0.003,193.407%20C167.008,577.982,200.589,592,235.828,592h127.568c35.24,0,68.823-14.018,93.729-38.927c52.137-52.134,52.137-141.276,0-193.41%20c-4.761-4.761-9.874-9.155-15.287-13.143c36.523-36.834,57.159-86.685,57.159-138.883c0-108.993-88.188-197.184-197.19-197.184%20c-108.977,0-197.181,88.207-197.181,197.184C104.627,258.933,124.557,307.996,159.969,344.666L159.969,344.666z%20M363.396,385.629%20H235.828c-18.617,0-35.559,7.631-47.846,19.914c-26.797,26.8-26.797,74.85,0,101.65c12.287,12.286,29.225,19.914,47.846,19.914%20h127.568c18.623,0,35.559-7.628,47.849-19.914c26.797-26.8,26.797-74.85,0-101.65C398.955,393.259,382.013,385.629,363.396,385.629%20L363.396,385.629z%20M301.808,75.381c-73.808,0-132.256,59.869-132.256,132.256c0,72.383,58.448,132.256,132.256,132.256%20c73.815,0,132.265-59.87,132.265-132.256C434.073,135.248,375.622,75.381,301.808,75.381L301.808,75.381z%20M301.808,271.807%20c13.689,0,24.784,11.098,24.784,24.781c0,13.686-11.094,24.78-24.784,24.78c-13.686,0-24.777-11.094-24.777-24.78%20C277.03,282.905,288.122,271.807,301.808,271.807z'/%3e%3c/svg%3e",St="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M460.592,75.695C501.794,116.897,525,172.38,525,230.692v136.191%20c0,58.315-23.206,113.795-64.408,154.997c-86.029,86.032-228.158,86.032-314.186,0C105.203,480.679,82,425.199,82,366.884V230.692%20c0-58.312,23.203-113.795,64.405-154.997C232.433-10.337,374.563-10.337,460.592,75.695L460.592,75.695z%20M434.493,101.794%20c-71.625-71.628-190.365-71.628-261.989,0c-33.068,33.068-53.597,78.696-53.597,128.898v136.191%20c0,50.205,20.529,95.834,53.597,128.898c71.624,71.628,190.364,71.628,261.989,0c33.067-33.064,53.596-78.693,53.596-128.898%20V230.692C488.089,180.49,467.56,134.862,434.493,101.794L434.493,101.794z%20M195.699,124.99%20c-27.134,27.137-43.982,64.557-43.982,105.702v136.191c0,41.146,16.848,78.568,43.982,105.702%20c58.806,58.814,156.791,58.814,215.598,0c27.138-27.134,43.982-64.557,43.982-105.702V230.692%20c0-41.146-16.845-78.566-43.982-105.702C352.491,66.18,254.506,66.18,195.699,124.99L195.699,124.99z%20M303.497,401.594%20c-17.304,0-31.334,14.029-31.334,31.337c0,17.304,14.03,31.333,31.334,31.333c17.307,0,31.337-14.029,31.337-31.333%20C334.834,415.623,320.804,401.594,303.497,401.594L303.497,401.594z%20M223.204,305.993c-17.308,0-31.338,14.03-31.338,31.334%20c0,17.308,14.03,31.337,31.338,31.337c17.307,0,31.337-14.029,31.337-31.337C254.541,320.023,240.511,305.993,223.204,305.993%20L223.204,305.993z%20M223.204,208.881c-17.308,0-31.338,14.026-31.338,31.334c0,17.307,14.03,31.337,31.338,31.337%20c17.307,0,31.337-14.03,31.337-31.337C254.541,222.907,240.511,208.881,223.204,208.881L223.204,208.881z%20M383.796,305.993%20c-17.308,0-31.338,14.03-31.338,31.334c0,17.308,14.03,31.337,31.338,31.337c17.307,0,31.333-14.029,31.333-31.337%20C415.129,320.023,401.103,305.993,383.796,305.993L383.796,305.993z%20M383.796,208.881c-17.308,0-31.338,14.026-31.338,31.334%20c0,17.307,14.03,31.337,31.338,31.337c17.307,0,31.333-14.03,31.333-31.337C415.129,222.907,401.103,208.881,383.796,208.881%20L383.796,208.881z%20M354.769,129.256c-12.585,0-22.786,10.201-22.786,22.786s10.2,22.786,22.786,22.786%20c12.585,0,22.786-10.201,22.786-22.786S367.354,129.256,354.769,129.256L354.769,129.256z%20M252.228,129.256%20c-12.585,0-22.786,10.201-22.786,22.786s10.2,22.786,22.786,22.786c12.585,0,22.786-10.201,22.786-22.786%20S264.813,129.256,252.228,129.256z'/%3e%3c/svg%3e",jr="data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M17%2012.8108C17%2013.1901%2016.898%2013.5661%2016.6687%2013.8682C15.2357%2015.7558%2012.784%2017%2010%2017C7.21614%2017%204.76431%2015.7557%203.33134%2013.8681C3.10199%2013.566%203%2013.1901%203%2012.8108V7.18924C3%206.80993%203.10199%206.43401%203.33134%206.13189C4.76431%204.24428%207.21614%203%2010%203C12.784%203%2015.2357%204.24423%2016.6687%206.13183C16.898%206.43395%2017%206.80986%2017%207.18918V12.8108ZM10%207C10.5522%207%2011%206.55231%2011%206C11%205.44769%2010.5522%205%2010%205C9.44775%205%209%205.44769%209%206C9%206.55231%209.44775%207%2010%207ZM6.5%2011.5C7.32837%2011.5%208%2010.8284%208%2010C8%209.17157%207.32837%208.5%206.5%208.5C5.67163%208.5%205%209.17157%205%2010C5%2010.8284%205.67163%2011.5%206.5%2011.5ZM11.5%2013.5C11.5%2014.3284%2010.8284%2015%2010%2015C9.17163%2015%208.5%2014.3284%208.5%2013.5C8.5%2012.6716%209.17163%2012%2010%2012C10.8284%2012%2011.5%2012.6716%2011.5%2013.5ZM13.5%2011.5C14.3284%2011.5%2015%2010.8284%2015%2010C15%209.17157%2014.3284%208.5%2013.5%208.5C12.6716%208.5%2012%209.17157%2012%2010C12%2010.8284%2012.6716%2011.5%2013.5%2011.5Z'%20fill='currentColor'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M10%201C13.8106%201%2017.1182%202.95715%2018.7732%205.82595C18.9298%206.09752%2019%206.40872%2019%206.72224V13.2778C19%2013.5913%2018.9298%2013.9025%2018.7732%2014.1741C17.1182%2017.0429%2013.8106%2019%2010%2019C6.18943%2019%202.88177%2017.0429%201.22682%2014.1741C1.07016%2013.9025%201%2013.5913%201%2013.2778V6.72224C1%206.40872%201.07016%206.09752%201.22682%205.82595C2.88177%202.95715%206.18943%201%2010%201ZM17.6711%205.64554C17.8973%205.95002%2018%206.32536%2018%206.70467V13.2953C18%2013.6746%2017.8973%2014.05%2017.6711%2014.3545C16.0408%2016.5488%2013.214%2018%2010%2018C6.78594%2018%203.95915%2016.5488%202.32887%2014.3544C2.10268%2014.0499%202%2013.6746%202%2013.2953V6.70472C2%206.32542%202.10268%205.95008%202.32887%205.64561C3.95915%203.45116%206.78594%202%2010%202C13.214%202%2016.0408%203.45116%2017.6711%205.64554Z'%20fill='currentColor'/%3e%3c/svg%3e",z="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M395.264,259.724c21.074,0,38.157,17.083,38.157,38.158%20c0,21.074-17.083,38.164-38.157,38.164c-21.075,0-38.165-17.09-38.165-38.164C357.099,276.806,374.189,259.724,395.264,259.724%20L395.264,259.724z%20M206.743,259.724c21.075,0,38.158,17.083,38.158,38.158c0,21.074-17.083,38.164-38.158,38.164%20c-21.074,0-38.164-17.09-38.164-38.164C168.579,276.806,185.669,259.724,206.743,259.724L206.743,259.724z%20M317.092,89.755v29.841%20h-32.183V89.755c-67.083,5.031-127.459,41.741-163.107,98.796v223.399c35.648,57.055,96.024,93.765,163.107,98.802v-29.841h32.183%20v29.841c67.084-5.038,127.459-41.747,163.114-98.802V188.551C444.551,131.496,384.176,94.787,317.092,89.755L317.092,89.755z%20M301,56.962c-85.858,0-165.124,45.192-209.061,118.921l-2.328,3.902v90.784H58.612v59.364h30.999v90.784l2.328,3.902%20C135.876,498.348,215.143,543.539,301,543.539c85.857,0,165.123-45.184,209.06-118.921l2.328-3.902v-90.784h31.006v-59.364h-31.006%20v-90.784l-2.328-3.902C466.124,102.147,386.857,56.962,301,56.962L301,56.962z%20M301,18.251c-155.741,0-282,126.253-282,282%20c0,155.741,126.26,282,282,282c155.747,0,282-126.26,282-282C583,144.504,456.747,18.251,301,18.251z'/%3e%3c/svg%3e",Ae="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M261.067,178.239c0,7.551,2.198,14.579,5.985,20.491l20.49-20.491%20l-20.49-20.491C263.265,163.659,261.067,170.694,261.067,178.239L261.067,178.239z%20M298.999,216.171%20c-7.545,0-14.58-2.198-20.488-5.981l20.488-20.491l20.491,20.491C313.581,213.972,306.55,216.171,298.999,216.171L298.999,216.171z%20M336.934,178.239c0-7.545-2.198-14.58-5.985-20.491l-20.491,20.491l20.491,20.491C334.736,192.818,336.934,185.79,336.934,178.239%20L336.934,178.239z%20M319.49,146.295l-20.491,20.484l-20.488-20.484c5.907-3.79,12.943-5.988,20.488-5.988%20C306.55,140.307,313.581,142.505,319.49,146.295L319.49,146.295z%20M298.999,124.101c29.864,0,54.141,24.281,54.141,54.138%20c0,29.864-24.277,54.145-54.141,54.145c-29.858,0-54.138-24.281-54.138-54.145C244.861,148.382,269.141,124.101,298.999,124.101%20L298.999,124.101z%20M261.067,417.863c0,7.551,2.198,14.579,5.985,20.491l20.49-20.491l-20.49-20.491%20C263.265,403.283,261.067,410.319,261.067,417.863L261.067,417.863z%20M298.999,455.795c-7.545,0-14.58-2.198-20.488-5.981%20l20.488-20.491l20.491,20.491C313.581,453.597,306.55,455.795,298.999,455.795L298.999,455.795z%20M336.934,417.863%20c0-7.545-2.198-14.58-5.985-20.491l-20.491,20.491l20.491,20.491C334.736,432.443,336.934,425.415,336.934,417.863L336.934,417.863z%20M319.49,385.92l-20.491,20.484l-20.488-20.484c5.907-3.79,12.943-5.988,20.488-5.988C306.55,379.931,313.581,382.13,319.49,385.92%20L319.49,385.92z%20M298.999,363.725c29.864,0,54.141,24.281,54.141,54.138c0,29.864-24.277,54.145-54.141,54.145%20c-29.858,0-54.138-24.281-54.138-54.145C244.861,388.007,269.141,363.725,298.999,363.725L298.999,363.725z%20M180.188,239.928%20c30.094,0,54.49,24.4,54.49,54.494c0,30.095-24.396,54.494-54.49,54.494c-30.095,0-54.494-24.399-54.494-54.494%20C125.694,264.327,150.093,239.928,180.188,239.928L180.188,239.928z%20M417.816,239.928c30.094,0,54.494,24.4,54.494,54.494%20c0,30.095-24.4,54.494-54.494,54.494c-30.095,0-54.494-24.399-54.494-54.494C363.323,264.327,387.722,239.928,417.816,239.928%20L417.816,239.928z%20M298.999,86.511c116.835,0,211.544,94.708,211.544,211.54c0,116.84-94.708,211.54-211.544,211.54%20c-116.836,0-211.54-94.708-211.54-211.54C87.458,181.219,182.163,86.511,298.999,86.511L298.999,86.511z%20M298.999,54.1%20c134.73,0,243.955,109.225,243.955,243.951c0,134.727-109.225,243.952-243.955,243.952c-134.727,0-243.952-109.225-243.952-243.952%20C55.047,163.324,164.271,54.1,298.999,54.1L298.999,54.1z%20M298.999,14.053C455.846,14.053,583,141.2,583,298.051%20c0,156.844-127.154,283.999-284.001,283.999C142.151,582.049,15,454.895,15,298.051C15,141.2,142.151,14.053,298.999,14.053z'/%3e%3c/svg%3e",tt="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M449.833,45.125C531.521,95.36,586,185.558,586,288.497%20c0,157.672-127.825,285.497-285.503,285.497C142.822,573.994,15,446.169,15,288.497C15,185.558,69.476,95.36,151.167,45.125H449.833%20L449.833,45.125z%20M193.639,256.195c-29.46,0-53.343,23.89-53.343,53.35c0,29.46,23.882,53.343,53.343,53.343%20c29.46,0,53.346-23.882,53.346-53.343C246.985,280.085,223.099,256.195,193.639,256.195L193.639,256.195z%20M407.365,256.195%20c-29.46,0-53.35,23.89-53.35,53.35c0,29.46,23.89,53.343,53.35,53.343c29.46,0,53.343-23.882,53.343-53.343%20C460.708,280.085,436.826,256.195,407.365,256.195L407.365,256.195z%20M442.248,88.407l-4.308-3.053H163.052l-4.304,3.053%20c-64.954,46.088-103.49,120.43-103.49,200.09c0,135.438,109.801,245.239,245.239,245.239c135.437,0,245.245-109.801,245.245-245.239%20C545.742,208.837,507.203,134.495,442.248,88.407L442.248,88.407z%20M427.607,117.937H173.391%20c-54.002,40.321-85.547,103.142-85.547,170.56c0,117.449,95.204,212.656,212.653,212.656c117.455,0,212.663-95.207,212.663-212.656%20C513.16,221.08,481.609,158.258,427.607,117.937L427.607,117.937z%20M300.497,215.65c-11.384,0-20.614,9.226-20.614,20.613%20c0,11.387,9.23,20.614,20.614,20.614c11.387,0,20.62-9.226,20.62-20.614C321.117,224.876,311.883,215.65,300.497,215.65%20L300.497,215.65z%20M300.497,146.275c-11.384,0-20.614,9.226-20.614,20.614c0,11.387,9.23,20.62,20.614,20.62%20c11.387,0,20.62-9.233,20.62-20.62C321.117,155.501,311.883,146.275,300.497,146.275L300.497,146.275z%20M381.735,146.275%20c-11.387,0-20.613,9.226-20.613,20.614c0,11.387,9.226,20.62,20.613,20.62c11.387,0,20.613-9.233,20.613-20.62%20C402.348,155.501,393.122,146.275,381.735,146.275L381.735,146.275z%20M219.265,146.275c-11.387,0-20.616,9.226-20.616,20.614%20c0,11.387,9.23,20.62,20.616,20.62c11.387,0,20.617-9.233,20.617-20.62C239.882,155.501,230.652,146.275,219.265,146.275%20L219.265,146.275z%20M300.497,400.094c-18.881,0-34.186,15.309-34.186,34.189c0,18.887,15.305,34.189,34.186,34.189%20c18.887,0,34.189-15.302,34.189-34.189C334.686,415.403,319.384,400.094,300.497,400.094L300.497,400.094z%20M381.735,417.199%20c-11.387,0-20.613,9.233-20.613,20.62c0,11.38,9.226,20.614,20.613,20.614c11.387,0,20.613-9.233,20.613-20.614%20C402.348,426.433,393.122,417.199,381.735,417.199L381.735,417.199z%20M219.265,417.199c-11.387,0-20.616,9.233-20.616,20.62%20c0,11.38,9.23,20.614,20.616,20.614c11.387,0,20.617-9.233,20.617-20.614C239.882,426.433,230.652,417.199,219.265,417.199z'/%3e%3c/svg%3e",We={IEC_62196_T1:Mr,IEC_62196_T1_COMBO:kr,IEC_62196_T2:Rr,IEC_62196_T2_COMBO:Ar,IEC_62196_T3:St,IEC_62196_T3A:jr,IEC_62196_T3B:St,IEC_62196_T3C:St,CHADEMO:Ae,CHAOJI:Ae,CATARC:tt,GBT_AC:tt,GBT_DC:tt,SCHUKO:z,DOMESTIC_A:z,DOMESTIC_B:z,DOMESTIC_C:z,DOMESTIC_D:z,DOMESTIC_E:z,DOMESTIC_F:z,DOMESTIC_G:z,DOMESTIC_H:z,DOMESTIC_I:z,DOMESTIC_J:z,DOMESTIC_K:z,DOMESTIC_L:z,DOMESTIC_M:z,DOMESTIC_N:z,DOMESTIC_O:z,IEC_60309_2_SINGLE_16:z,IEC_60309_2_THREE_16:z,IEC_60309_2_THREE_32:z,IEC_60309_2_THREE_64:z,NEMA_5_20:z,NEMA_6_30:z,NEMA_6_50:z,NEMA_10_30:z,NEMA_10_50:z,NEMA_14_30:z,NEMA_14_50:z,PANTOGRAPH_BOTTOM_UP:Ae,PANTOGRAPH_TOP_DOWN:Ae,TESLA_R:Ae,TESLA_S:Ae,CONNECTOR_STANDARD_TYPE_CHADEMO:Ae,CONNECTOR_STANDARD_TYPE_CHAOJI:Ae,CONNECTOR_STANDARD_TYPE_CATARC:tt,CONNECTOR_STANDARD_TYPE_SCHUKO:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_A:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_B:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_C:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_D:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_E:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_F:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_G:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_H:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_I:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_J:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_K:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_L:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_M:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_N:z,CONNECTOR_STANDARD_TYPE_DOMESTIC_O:z,CONNECTOR_STANDARD_TYPE_GBT_AC:tt,CONNECTOR_STANDARD_TYPE_GBT_DC:tt,CONNECTOR_STANDARD_TYPE_IEC_60309_2_SINGLE_16:z,CONNECTOR_STANDARD_TYPE_IEC_60309_2_THREE_16:z,CONNECTOR_STANDARD_TYPE_IEC_60309_2_THREE_32:z,CONNECTOR_STANDARD_TYPE_IEC_60309_2_THREE_64:z,CONNECTOR_STANDARD_TYPE_IEC_62196_T1:Mr,CONNECTOR_STANDARD_TYPE_IEC_62196_T1_COMBO:kr,CONNECTOR_STANDARD_TYPE_IEC_62196_T2:Rr,CONNECTOR_STANDARD_TYPE_IEC_62196_T2_COMBO:Ar,CONNECTOR_STANDARD_TYPE_IEC_62196_T3A:jr,CONNECTOR_STANDARD_TYPE_IEC_62196_T3C:St,CONNECTOR_STANDARD_TYPE_NEMA_5_20:z,CONNECTOR_STANDARD_TYPE_NEMA_6_30:z,CONNECTOR_STANDARD_TYPE_NEMA_6_50:z,CONNECTOR_STANDARD_TYPE_NEMA_10_30:z,CONNECTOR_STANDARD_TYPE_NEMA_10_50:z,CONNECTOR_STANDARD_TYPE_NEMA_14_30:z,CONNECTOR_STANDARD_TYPE_NEMA_14_50:z,CONNECTOR_STANDARD_TYPE_PANTOGRAPH_BOTTOM_UP:Ae,CONNECTOR_STANDARD_TYPE_PANTOGRAPH_TOP_DOWN:Ae,CONNECTOR_STANDARD_TYPE_TESLA_R:Ae,CONNECTOR_STANDARD_TYPE_TESLA_S:Ae},jt={minPower:7,operator:[],status:[],publishingMode:"",connectorTypes:[],noAdditionalCharges:!1,powerType:void 0,operatorOnly:""};function sc(e){return!!(e.minPower&&e.minPower!==jt.minPower||e?.status?.length||e?.connectorTypes?.length||e?.operator?.length||e?.powerType||e?.partyId||e?.noAdditionalCharges||e?.operatorOnly)}const ac=[{label:7,value:7},{label:11,value:11},{label:22,value:22},{label:43,value:43},{label:50,value:50},{label:100,value:100},{label:150,value:150},{label:200,value:200},{label:"250+",value:250}],fn=(e,n,i)=>{switch(e){case"remove":return n.filter(r=>!i.includes(r));case"add":return Array.from(new Set([...n,...i]))}};function cc(e){return g.useReducer((n,i)=>({...n,...i}),e)}function lc(){const{setFilters:e,t:n,filters:i,filterConfiguration:r,options:o}=Oe(),[t,s]=cc(jt),{setView:c}=_t(),l=o.version==="v2"&&r?.operators?.length>1;return g.useEffect(()=>{s(i)},[]),g.useEffect(()=>{e(t)},[t]),a.jsxs(a.Fragment,{children:[a.jsx("div",{className:K.headerContainer,children:a.jsx("div",{className:K.header,children:n("filters.header")})}),a.jsxs("div",{className:K.container,children:[a.jsx("button",{onClick:()=>{s(jt),e(jt)},className:K.actionLinkClearAll,children:n("filters.clearAll")}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.onlyShow")}),a.jsxs("label",{htmlFor:"dsChargers",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:n("filters.dcChargers")}),a.jsx(Se,{id:"dsChargers",checked:t.powerType==="dc",onChange:u=>{s({powerType:u?"dc":void 0})}})]}),o.version!=="v2"&&a.jsxs("label",{htmlFor:"efluxChargers",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:n("filters.efluxChargers")}),a.jsx(Se,{id:"efluxChargers",checked:t.partyId==="EFL",onChange:u=>{s({partyId:u?"EFL":void 0})}})]}),(o.version!=="v2"||r?.showNoAdditionalFeeFilter)&&a.jsxs("label",{htmlFor:"noAdditionalFee",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:n("filters.noAdditionalFee")}),a.jsx(Se,{id:"noAdditionalFee",checked:t.noAdditionalCharges,onChange:u=>{s({noAdditionalCharges:u?!0:void 0})}})]}),r.showOperatorOnly&&o.version==="v2"&&a.jsxs("label",{htmlFor:"operatorOnly",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:`Show '${r.showOperatorOnly}' only`}),a.jsx(Se,{id:"operatorOnly",checked:t.operatorOnly===r.showOperatorOnly,onChange:u=>{s({operatorOnly:u?r.showOperatorOnly:void 0})}})]})]}),l&&a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:"Operator"}),a.jsx(nc,{id:"operator",preferredValues:o.preferredOperators,value:t.operator,options:[...r?.operators?.map(u=>({value:u?.connectionId,label:u?.name,selected:t.operators?.includes(u?.connectionId)}))||[]],placeholder:"Select operator",onChange:u=>{s({operator:u})}})]}),r?.showPublishingModeFilter&&r?.publishingMode?.length>1&&a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:"Visibility"}),a.jsx(oc,{id:"publishingMode",value:t.publishingMode,placeholder:"Showing all available locations",options:[{value:"",label:"All locations"},{value:"PUBLISHING_MODE_PUBLIC",label:"Public locations"},{value:"PUBLISHING_MODE_PRIVATE",label:"Private locations"}],onChange:u=>{s({publishingMode:u})}})]}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.statusHeading")}),a.jsxs("label",{htmlFor:"statusAvailable",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("div",{className:K.dot,style:{background:"#33AC19"}}),n("filters.available")]}),a.jsx(Se,{id:"statusAvailable",name:"status",checked:t.status.includes("AVAILABLE"),onChange:u=>{s({status:fn(u?"add":"remove",t.status,["AVAILABLE"])})}})]}),a.jsxs("label",{htmlFor:"statusCharging",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("div",{className:K.dot,style:{background:"#005CEE"}}),n("filters.charging")]}),a.jsx(Se,{id:"statusCharging",checked:t.status.includes("CHARGING"),onChange:u=>{s({status:fn(u?"add":"remove",t.status,["CHARGING"])})}})]}),a.jsxs("label",{htmlFor:"statusError",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("div",{className:K.dot,style:{background:"#EB001B"}}),n("filters.notAvailable")]}),a.jsx(Se,{id:"statusError",name:"status",checked:t.status.includes("INOPERATIVE")&&t.status.includes("UNKNOWN"),onChange:u=>{s({status:fn(u?"add":"remove",t.status,["INOPERATIVE","UNKNOWN"])})}})]})]}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.chargingPower")}),a.jsx(Us,{value:t.minPower,onChange:u=>{s({minPower:u})},ticks:ac})]}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.connectorType")}),a.jsxs("label",{htmlFor:"type1",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:We.IEC_62196_T1,className:K.connectorIcon}),"Type 1 (Yazaki)"]}),a.jsx(Se,{id:"type1",checked:t.connectorTypes.includes("IEC_62196_T1"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T1"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T1")})}})]}),a.jsxs("label",{htmlFor:"type2",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:We.IEC_62196_T2,className:K.connectorIcon}),"Type 2 (Mennekes)"]}),a.jsx(Se,{id:"type2",checked:t.connectorTypes.includes("IEC_62196_T2"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T2"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T2")})}})]}),a.jsxs("label",{htmlFor:"type3",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:We.IEC_62196_T3,className:K.connectorIcon}),"Type 3 (Le Grand)"]}),a.jsx(Se,{id:"type3",checked:t.connectorTypes.includes("IEC_62196_T3A"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T3A"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T3A")})}})]}),a.jsxs("label",{htmlFor:"CHAdeMo",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:We.CHADEMO,className:K.connectorIcon}),"CHAdeMo"]}),a.jsx(Se,{id:"CHAdeMo",checked:t.connectorTypes.includes("CHADEMO"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"CHADEMO"]:t.connectorTypes.filter(f=>f!=="CHADEMO")})}})]}),a.jsxs("label",{htmlFor:"domestic",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:We.DOMESTIC_F,className:K.connectorIcon}),"Domestic"]}),a.jsx(Se,{id:"domestic",checked:t.connectorTypes.includes("DOMESTIC_F"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"DOMESTIC_F"]:t.connectorTypes.filter(f=>f!=="DOMESTIC_F")})}})]}),a.jsxs("label",{htmlFor:"combo",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:We.IEC_62196_T2_COMBO,className:K.connectorIcon}),"Combo"]}),a.jsx(Se,{id:"combo",checked:t.connectorTypes.includes("IEC_62196_T2_COMBO"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T2_COMBO"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T2_COMBO")})}})]})]})]})]})}const uc="locations-module_headerContainer",dc="locations-module_publishingMode",fc="locations-module_container",pc="locations-module_header",hc="locations-module_subheader",mc="locations-module_row",gc="locations-module_icon",vc="locations-module_statusIcon",_c="locations-module_text",Cc="locations-module_note",Ec="locations-module_divider",yc="locations-module_pagingation",Tc="locations-module_tariffNoteLink",S={headerContainer:uc,publishingMode:dc,container:fc,header:pc,subheader:hc,row:mc,icon:gc,statusIcon:vc,text:_c,note:Cc,divider:Ec,pagingation:yc,tariffNoteLink:Tc},xc="LocationPlaceholder-module_container",bc="LocationPlaceholder-module_header",Ic="LocationPlaceholder-module_divider",wc="LocationPlaceholder-module_iconLine",Nc="LocationPlaceholder-module_priceLine",Ne={container:xc,header:bc,divider:Ic,iconLine:wc,priceLine:Nc};function Oc(){return a.jsxs("div",{className:Ne.container,children:[a.jsx("div",{className:Ne.header}),a.jsx("div",{className:Ne.divider,style:{marginTop:"15px",marginBottom:"23px"}}),a.jsx("div",{className:Ne.iconLine,style:{width:"60%"}}),a.jsx("div",{className:Ne.iconLine,style:{width:"45%"}}),a.jsx("div",{className:Ne.iconLine,style:{width:"50%"}}),a.jsx("div",{className:Ne.divider}),a.jsx("div",{className:Ne.iconLine,style:{width:"50%"}}),a.jsx("div",{className:Ne.iconLine,style:{width:"62%"}}),a.jsx("div",{className:Ne.priceLine}),a.jsx("div",{className:Ne.divider}),a.jsx("div",{className:Ne.iconLine,style:{width:"50%"}}),a.jsx("div",{className:Ne.iconLine,style:{width:"57%"}}),a.jsx("div",{className:Ne.priceLine,style:{width:"30%"}})]})}function Oi(){return a.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512",fill:"currentColor",children:a.jsx("path",{d:"M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"})})}function Sc(){return a.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512",fill:"currentColor",children:a.jsx("path",{d:"M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"})})}function Vn(){return a.jsx("svg",{viewBox:"0 0 16 16",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:a.jsx("g",{children:a.jsx("path",{d:"M8 0.25C3.72009 0.25 0.25 3.72134 0.25 8C0.25 12.2812 3.72009 15.75 8 15.75C12.2799 15.75 15.75 12.2812 15.75 8C15.75 3.72134 12.2799 0.25 8 0.25ZM8 14.25C4.54588 14.25 1.75 11.4553 1.75 8C1.75 4.54703 4.546 1.75 8 1.75C11.4528 1.75 14.25 4.54597 14.25 8C14.25 11.4541 11.4553 14.25 8 14.25ZM8 3.6875C8.72487 3.6875 9.3125 4.27513 9.3125 5C9.3125 5.72487 8.72487 6.3125 8 6.3125C7.27513 6.3125 6.6875 5.72487 6.6875 5C6.6875 4.27513 7.27513 3.6875 8 3.6875ZM9.75 11.625C9.75 11.8321 9.58209 12 9.375 12H6.625C6.41791 12 6.25 11.8321 6.25 11.625V10.875C6.25 10.6679 6.41791 10.5 6.625 10.5H7V8.5H6.625C6.41791 8.5 6.25 8.33209 6.25 8.125V7.375C6.25 7.16791 6.41791 7 6.625 7H8.625C8.83209 7 9 7.16791 9 7.375V10.5H9.375C9.58209 10.5 9.75 10.6679 9.75 10.875V11.625Z"})})})}const Dc="SidebarContainer-module_container",Pc={container:Dc};function mt({children:e}){return a.jsx("div",{className:Pc.container,children:e})}const Rc="Debug-module_container",Ac="Debug-module_content",Mc="Debug-module_connectorHeader",kc="Debug-module_code",jc="Debug-module_evse",nt={container:Rc,content:Ac,connectorHeader:Mc,code:kc,evse:jc};function Lc({location:e}){return a.jsx("div",{className:nt.container,children:a.jsxs(mt,{children:[a.jsx("div",{children:a.jsxs("h3",{children:["Debug: ",e.name]})}),a.jsx("div",{style:{marginBottom:"5px"},children:a.jsx("button",{onClick:()=>{navigator.clipboard.writeText(JSON.stringify(e,null,2))},children:"Copy location"})}),a.jsx("div",{className:nt.content,children:e.evses.map(n=>a.jsxs("div",{className:nt.evse,children:[a.jsxs("div",{className:nt.connectorHeader,children:["Evse: ",n.evseId||n.evse_id]}),a.jsx("div",{children:n.connectors.map((i,r)=>a.jsxs("div",{children:[a.jsxs("div",{className:nt.connectorHeader,children:["Connector #",r]}),a.jsx("pre",{className:nt.code,children:JSON.stringify(i.tariff||Array.isArray(e.tariffs)?e.tariffs?.find(o=>i.tariff_ids.includes(o.id)):null,null,2)})]}))})]}))})]})})}const Si="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='18'%20height='16'%20viewBox='0%200%2018%2016'%20fill='none'%3e%3cg%20clip-path='url(%23clip0_480_2466)'%3e%3cpath%20d='M3.76781%207H5.0925L4.81812%208.71156C4.77812%208.85969%204.9075%209%205.07875%209C5.17188%209%205.26156%208.95719%205.31063%208.88313L7.40219%205.78062C7.50531%205.62469%207.37656%205.42875%207.17031%205.42875H5.88219L6.14094%204.295C6.18625%204.14625%206.05781%204.00031%205.88219%204.00031H4.36438C4.23%204.00031%204.11656%204.08719%204.09875%204.20375L3.50187%206.735C3.48094%206.87531%203.60594%207%203.76781%207ZM17.5%204H17V2.5C17%202.22375%2016.7763%202%2016.5%202C16.2237%202%2016%202.22375%2016%202.5V4H15V2.5C15%202.22375%2014.7762%202%2014.5%202C14.2238%202%2014%202.22375%2014%202.5V4H13.5C13.2238%204%2013%204.22375%2013%204.5V6C13%207.1175%2013.7381%208.05281%2014.75%208.37281V11.625C14.75%2012.1075%2014.3575%2012.5%2013.875%2012.5C13.3925%2012.5%2013%2012.1075%2013%2011.625V10.75C13%209.23344%2011.7666%208%2010.25%208H10V1.5C10%200.671562%209.32844%200%208.5%200H2.5C1.67156%200%201%200.671562%201%201.5V14.5H0.25C0.111875%2014.5%200%2014.6119%200%2014.75V15.75C0%2015.8881%200.111875%2016%200.25%2016H10.75C10.8881%2016%2011%2015.8881%2011%2015.75V14.75C11%2014.6119%2010.8881%2014.5%2010.75%2014.5H10V9.5H10.25C10.9394%209.5%2011.5%2010.0606%2011.5%2010.75V11.625C11.5%2012.9347%2012.5653%2014%2013.875%2014C15.1847%2014%2016.25%2012.9347%2016.25%2011.625V8.37281C17.2619%208.05281%2018%207.1175%2018%206V4.5C18%204.22375%2017.7763%204%2017.5%204ZM8.5%2014.5H2.5V1.5H8.5V14.5ZM16.5%206C16.5%206.55125%2016.0513%207%2015.5%207C14.9487%207%2014.5%206.55125%2014.5%206V5.5H16.5V6Z'%20fill='black'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_480_2466'%3e%3crect%20width='18'%20height='16'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Di="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='14'%20height='16'%20viewBox='0%200%2014%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_480_2468)'%3e%3cpath%20d='M4%204.625V3.375C4%203.16875%204.16875%203%204.375%203H5.625C5.83125%203%206%203.16875%206%203.375V4.625C6%204.83125%205.83125%205%205.625%205H4.375C4.16875%205%204%204.83125%204%204.625ZM8.375%205H9.625C9.83125%205%2010%204.83125%2010%204.625V3.375C10%203.16875%209.83125%203%209.625%203H8.375C8.16875%203%208%203.16875%208%203.375V4.625C8%204.83125%208.16875%205%208.375%205ZM4.375%208H5.625C5.83125%208%206%207.83125%206%207.625V6.375C6%206.16875%205.83125%206%205.625%206H4.375C4.16875%206%204%206.16875%204%206.375V7.625C4%207.83125%204.16875%208%204.375%208ZM8.375%208H9.625C9.83125%208%2010%207.83125%2010%207.625V6.375C10%206.16875%209.83125%206%209.625%206H8.375C8.16875%206%208%206.16875%208%206.375V7.625C8%207.83125%208.16875%208%208.375%208ZM6%2010.625V9.375C6%209.16875%205.83125%209%205.625%209H4.375C4.16875%209%204%209.16875%204%209.375V10.625C4%2010.8313%204.16875%2011%204.375%2011H5.625C5.83125%2011%206%2010.8313%206%2010.625ZM8.375%2011H9.625C9.83125%2011%2010%2010.8313%2010%2010.625V9.375C10%209.16875%209.83125%209%209.625%209H8.375C8.16875%209%208%209.16875%208%209.375V10.625C8%2010.8313%208.16875%2011%208.375%2011ZM14%2014.875V16H0V14.875C0%2014.6687%200.16875%2014.5%200.375%2014.5H0.984375V0.75C0.984375%200.334375%201.31875%200%201.73438%200H12.2656C12.6812%200%2013.0156%200.334375%2013.0156%200.75V14.5H13.625C13.8313%2014.5%2014%2014.6687%2014%2014.875ZM2.48438%2014.4688H6V12.375C6%2012.1687%206.16875%2012%206.375%2012H7.625C7.83125%2012%208%2012.1687%208%2012.375V14.4688H11.5156V1.53125L2.5%201.5L2.48438%2014.4688Z'%20fill='black'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_480_2468'%3e%3crect%20width='14'%20height='16'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Pi="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='20'%20height='16'%20viewBox='0%200%2020%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M17%206H16.5L13.1003%201.75063C12.913%201.51641%2012.6754%201.32734%2012.405%201.19741C12.1347%201.06747%2011.8387%201.00001%2011.5387%201H4.85406C4.03625%201%203.30094%201.49781%202.99719%202.25719L1.5%206V6.07062C0.63875%206.29375%200%207.06906%200%208V11.5C0%2011.7762%200.22375%2012%200.5%2012H2C2%2013.6569%203.34312%2015%205%2015C6.65688%2015%208%2013.6569%208%2012H12C12%2013.6569%2013.3431%2015%2015%2015C16.6569%2015%2018%2013.6569%2018%2012H19.5C19.7763%2012%2020%2011.7762%2020%2011.5V9C20%207.34312%2018.6569%206%2017%206ZM8.75%202.5H11.5387C11.6916%202.5%2011.8338%202.56844%2011.9291%202.6875L14.5791%206H8.75V2.5ZM4.38969%202.81437C4.46625%202.62344%204.64844%202.5%204.85406%202.5H7.25V6H3.11562L4.38969%202.81437ZM5%2013.5C4.17156%2013.5%203.5%2012.8284%203.5%2012C3.5%2011.1716%204.17156%2010.5%205%2010.5C5.82844%2010.5%206.5%2011.1716%206.5%2012C6.5%2012.8284%205.82844%2013.5%205%2013.5ZM15%2013.5C14.1716%2013.5%2013.5%2012.8284%2013.5%2012C13.5%2011.1716%2014.1716%2010.5%2015%2010.5C15.8284%2010.5%2016.5%2011.1716%2016.5%2012C16.5%2012.8284%2015.8284%2013.5%2015%2013.5ZM18.5%2010.5H17.5841C17.0644%209.60719%2016.1078%209%2015%209C13.8922%209%2012.9359%209.60719%2012.4159%2010.5H7.58406C7.06437%209.60719%206.10781%209%205%209C3.89219%209%202.93594%209.60719%202.41594%2010.5H1.5V8C1.5%207.72437%201.72438%207.5%202%207.5H17C17.8272%207.5%2018.5%208.17281%2018.5%209V10.5Z'%20fill='black'/%3e%3c/svg%3e",Wt="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='12'%20height='16'%20viewBox='0%200%2012%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_480_2435)'%3e%3cpath%20d='M11.8068%205.24687C11.5506%204.8%2011.0849%204.53125%2010.5693%204.53125H7.61932L8.51619%201.79688C8.63182%201.36563%208.54119%200.9125%208.26932%200.55625C7.99432%200.203125%207.57869%200%207.13182%200H3.05369C2.34118%200%201.73181%200.534375%201.65368%201.15937L0.0161813%207.79063C-0.0431938%208.22188%200.0849314%208.65625%200.369307%208.98438C0.653682%209.3125%201.06618%209.5%201.50056%209.5H4.56619L3.47556%2014.2406C3.37556%2014.6688%203.47244%2015.1125%203.74431%2015.4563C4.01619%2015.8031%204.42556%2016%204.86619%2016C5.37556%2016%205.85057%2015.725%206.07869%2015.325L11.8037%206.67812C12.0662%206.23125%2012.0662%205.69375%2011.8068%205.24687ZM5.00369%2014.2937L6.45057%208H1.48493L3.05369%201.5L7.04119%201.47187L5.54744%206.03125H10.4381L5.00369%2014.2937Z'%20fill='%232A2A2A'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_480_2435'%3e%3crect%20width='12'%20height='16'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Ri="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='18'%20height='12'%20viewBox='0%200%2018%2012'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M16.2857%200H0.857143C0.383839%200%200%200.383839%200%200.857143V11.1429C0%2011.6162%200.383839%2012%200.857143%2012H16.2857C16.759%2012%2017.1429%2011.6162%2017.1429%2011.1429V0.857143C17.1429%200.383839%2016.759%200%2016.2857%200ZM15.8571%2010.7143H1.28571V1.28571H15.8571V10.7143ZM7.92857%207.71429H10.0714C10.1898%207.71429%2010.2857%207.61839%2010.2857%207.5V6.64286C10.2857%206.52446%2010.1898%206.42857%2010.0714%206.42857H7.92857C7.81018%206.42857%207.71429%206.52446%207.71429%206.64286V7.5C7.71429%207.61839%207.81018%207.71429%207.92857%207.71429ZM14.3571%206.42857H12.2143C12.0959%206.42857%2012%206.52446%2012%206.64286V7.5C12%207.61839%2012.0959%207.71429%2012.2143%207.71429H14.3571C14.4755%207.71429%2014.5714%207.61839%2014.5714%207.5V6.64286C14.5714%206.52446%2014.4755%206.42857%2014.3571%206.42857ZM7.92857%205.57143H14.3571C14.4755%205.57143%2014.5714%205.47554%2014.5714%205.35714V4.5C14.5714%204.38161%2014.4755%204.28571%2014.3571%204.28571H7.92857C7.81018%204.28571%207.71429%204.38161%207.71429%204.5V5.35714C7.71429%205.47554%207.81018%205.57143%207.92857%205.57143ZM3.60857%206.04607L4.73866%206.3525C4.85089%206.38304%204.92857%206.47437%204.92857%206.57482C4.92857%206.70339%204.80804%206.80786%204.65911%206.80786H3.95357C3.84241%206.80786%203.73312%206.78%203.6383%206.72884C3.5558%206.68411%203.45509%206.69214%203.3908%206.76045L3.0675%207.10143C2.9842%207.18929%202.99786%207.33286%203.09777%207.40116C3.32009%207.5525%203.58152%207.63902%203.85714%207.65616V7.92857C3.85714%208.04696%203.95304%208.14286%204.07143%208.14286H4.5C4.61839%208.14286%204.71429%208.04696%204.71429%207.92857V7.65402C5.30839%207.62455%205.78571%207.15661%205.78571%206.57455C5.78571%206.08786%205.44768%205.65634%204.96286%205.52536L3.83277%205.21893C3.72054%205.18839%203.64286%205.09705%203.64286%204.99661C3.64286%204.86804%203.76339%204.76357%203.91232%204.76357H4.61786C4.72902%204.76357%204.8383%204.79143%204.93312%204.84259C5.01562%204.88705%205.11634%204.87929%205.18062%204.81098L5.50393%204.47C5.58723%204.38214%205.57357%204.23857%205.47366%204.17027C5.25134%204.01893%204.98991%203.93241%204.71429%203.91527V3.64286C4.71429%203.52446%204.61839%203.42857%204.5%203.42857H4.07143C3.95304%203.42857%203.85714%203.52446%203.85714%203.64286V3.91741C3.26304%203.94688%202.78571%204.41482%202.78571%204.99688C2.78571%205.48357%203.12375%205.91509%203.60857%206.04607Z'%20fill='%232A2A2A'/%3e%3c/svg%3e";function Ai(e){return We[e.standard||e.connectorStandardType]}function Mi(e,n){return new Intl.NumberFormat(e,{maximumFractionDigits:2}).format(n)}const Vc={CONNECTOR_POWER_TYPE_UNSPECIFIED:"Unspecified",CONNECTOR_POWER_TYPE_AC_1_PHASE:"AC x 1",CONNECTOR_POWER_TYPE_AC_2_PHASE:"AC x 2",CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT:"AC x 2 Split",CONNECTOR_POWER_TYPE_AC_3_PHASE:"AC x 3",CONNECTOR_POWER_TYPE_DC:"DC",CONNECTOR_POWER_TYPE_AC:"AC",AC_3_PHASE:"AC x 3",AC_1_PHASE:"AC x 1",DC:"DC"};function ki(e){return[Hc(e.standard||e.connectorStandardType),Vc[e.powerType||e.power_type||e.connectorPowerType],"Socket"].join(", ")}function Hc(e){return e=(e||"").replace("CONNECTOR_STANDARD_TYPE_",""),e==="IEC_62196_T1"?"Type 1":e==="IEC_62196_T1_COMBO"?"Type 1 Combo":e==="IEC_62196_T2"?"Type 2":e==="IEC_62196_T2_COMBO"?"Type 2 Combo":e==="IEC_62196_T3A"?"Type 3A":e==="IEC_62196_T3C"?"Type 3C":e==="CHADEMO"?"CHAdeMO":e==="DOMESTIC_F"?"Domestic F":e==="DOMESTIC_E"?"Domestic E":e==="DOMESTIC_B"?"Domestic B":e==="CATARC"?"Catarc":e}function ji(e,n){switch(n){case"AVAILABLE":return e("evse.statusAvailable");case"CHARGING":return e("evse.statusCharging");case"UNAVAILABLE":return e("evse.statusUnavailable");case"ERROR":return e("evse.statusError");case"UNKNOWN":return e("evse.statusUnknown");case"REMOVED":return e("evse.statusRemoved");case"PLANNED":return e("evse.statusPlanned");case"RESERVED":return e("evse.statusReserved");case"INOPERATIVE":return e("evse.statusInoperative");case"OUTOFORDER":return e("evse.statusOutOfOrder");default:return e("evse.statusUnknown")}}function Li(e,n){return n?.type==="ON_STREET"?e("locationType.onStreet"):n?.type==="PARKING_GARAGE"?e("locationType.parkingGarage"):n?.type==="UNDERGROUND_GARAGE"?e("locationType.undergroundGarage"):n?.type==="PARKING_LOT"?e("locationType.parkingLot"):e("locationType.other")}function Vi(e=[]){return e.some(n=>n.status==="AVAILABLE")?Fe("AVAILABLE"):e.some(n=>n.status==="CHARGING")?Fe("CHARGING"):Fe("UNKNOWN")}function Hi(e,n){let i;["en","fr"].some(s=>{let l=new Intl.DateTimeFormat(s,{minute:"numeric",timeZone:n,timeZoneName:"short"}).formatToParts(e).filter(u=>u.type=="timeZoneName"&&u.value);if(/^(GMT|UTC)/.test(l[0].value))return i=l[0].value.replace(/GMT|UTC/,"")||"+0",!0});let r=i[0]=="+"?"+":"-",[o,t]=i.substring(1).split(":");return r+o.padStart(2,"0")+":"+(t||"00")}function $i(e){let n=/^-/.test(e)?-1:1,[i,r]=e.match(/\d\d/g);return n*(i*60+Number(r))}function Lr(e,n){const i=s=>("0"+s).slice(-2),{year:r,month:o,day:t}=new Intl.DateTimeFormat("en",{timeZone:e}).formatToParts(n).reduce((s,c)=>(s[c.type]=c.value,c),Object.create(null));return`${r}-${i(o)}-${i(t)}`}function Fi(e,n=new Date){const i=Hi(n,e),r=$i(i),o=new Date(+n);return o.setUTCMinutes(o.getUTCMinutes()+r),o}function Bi(e,n=new Date){const i=Hi(n,e),r=$i(i),o=new Date(+n);o.setUTCHours(0,-r,0,0);const t=Lr(e,n),s=Lr(e,o);return s>t?o.setUTCDate(o.getUTCDate()-1):s<t&&o.setUTCDate(o.getUTCDate()+1),o}function $c(e,n=new Date){return new Date(Bi(e,n).valueOf()+86399999)}function Fc(e,n,i){const r=Fi(i,e);return r.getUTCDate()!==n&&r.setUTCDate(e.getUTCDate()+(7+n-e.getUTCDay()-1)%7+1),{start:Bi(i,r),end:$c(i,r)}}function vt(e,n){return Fi(n,e).getUTCDay()}function Vr(e){const[n,i]=e.split(":");return parseInt(n)*60+parseInt(i)}function Hn(e){if(!e?.restrictions?.startTime)return{elements:[e],priceComponents:e.priceComponents,startTime:0,endTime:1440,isFullDay:!0};const n=Vr(e.restrictions.startTime),i=Vr(e.restrictions.endTime);return{elements:[e],priceComponents:e.priceComponents,isFullDay:n===0&&i===1440,startTime:n,endTime:i}}function Bc(e,n,i){const r=(i.getHours()*60+i.getMinutes())%60;if(e.length<=1)return e.map(t=>(t.isActive=n&&t.startTime<=r&&t.endTime>=r,t));e=e.sort((t,s)=>t.startTime-s.startTime);let o=[e[0]];for(let t=1;t<e.length;t++){const s=e[t],c=o.findLast(u=>u.startTime<=s.startTime);if(!c)o=o.filter(u=>u.endTime>s.endTime),o.unshift(s);else{const u=c.endTime;c.endTime=s.startTime;const f=[s];u>s.endTime&&f.push({...c,startTime:s.endTime,endTime:u}),o.splice(o.indexOf(c)+1,0,...f)}let l=0;o=o.map((u,f)=>{const p=o[f-1];if(u.endTime>l)l=u.endTime;else return null;return p&&p.endTime!==u.startTime&&(u.startTime=p.endTime),u}).filter(Boolean)}return o.map(t=>(t.isActive=n&&t.startTime<=r&&t.endTime>=r,t.isFullDay=t.startTime===0&&t.endTime===1440,t))}function zi(e){return!e?.restrictions||!e?.restrictions?.start_date&&!e?.restrictions?.end_date&&!e?.restrictions?.start_time&&!e?.restrictions?.end_time&&!e?.restrictions?.day_of_week&&!e?.restrictions?.day_of_week}function Gt(e){return!e?.restrictions||!e?.restrictions?.startDate&&!e?.restrictions?.endDate&&!e?.restrictions?.startTime&&!e?.restrictions?.startTime&&!e?.restrictions?.dayOfWeek}function zc(e,n=6,i=new Date){const o=[...e].filter(t=>!zi(t)).map(t=>({...t,restrictions:{_startDate:new Date(`${t.restrictions.start_date}T${t.restrictions.start_time}`),...t.restrictions}})).sort((t,s)=>t.restrictions._startDate.valueOf()-s.restrictions._startDate.valueOf()).filter(t=>t.restrictions._startDate.valueOf()>new Date().valueOf()-108e5).slice(0,n).reduce((t,s)=>{const c=s.restrictions._startDate.getDate();return t[c]={date:new Date(s.restrictions.start_date),items:[...t[c]?.items||[],s]},t},[]);return Object.keys(o).map(t=>{const{date:s,items:c}=o[t],l=c.map(({restrictions:u,...f})=>{const{_startDate:p,...h}=u;return{...f,restrictions:{...h}}}).map(Hn).map(u=>{const f=vt(i)===vt(s),p=i.getHours()*60+i.getMinutes(),h=f&&u.startTime<=p&&u.endTime-1>=p;return{...u,isActive:h}});return{date:s,items:l}})}function Ui({elements:e,limit:n=6,now:i=new Date}){const o=[...e].filter(t=>!Gt(t)).map(t=>({...t,restrictions:{_startDate:new Date(`${t.restrictions.startDate}T${t.restrictions.startTime}`),...t.restrictions}})).sort((t,s)=>t.restrictions._startDate.valueOf()-s.restrictions._startDate.valueOf()).filter(t=>t.restrictions._startDate.valueOf()>new Date().valueOf()-108e5).slice(0,n).reduce((t,s)=>{const c=s.restrictions._startDate.getDate();return t[c]={date:new Date(s.restrictions.startDate),items:[...t[c]?.items||[],s]},t},[]);return Object.keys(o).map(t=>{const{date:s,items:c}=o[t],l=c.map(({restrictions:u,...f})=>{const{_startDate:p,...h}=u;return{...f,restrictions:{...h}}}).map(Hn).map(u=>{const f=vt(i)===vt(s),p=i.getHours()*60+i.getMinutes(),h=f&&u.startTime<=p&&u.endTime-1>=p;return{...u,isActive:h}});return{date:s,items:l}})}function Uc(e,n){const i=new Date;return[...e].reduce((r,o)=>{const{startDate:t,endDate:s,dayOfWeek:c=[]}=o.restrictions||{};if(!Object.keys(o.restrictions||{}).length)return r;const l=t?new Date(t):null;if(t&&l.valueOf()>Date.now())return r;const u=s?new Date(s):null;return s&&u.valueOf()<Date.now()||["SUNDAY","MONDAY","TUESDAY","WEDNESDAY","THURSDAY","FRIDAY","SATURDAY"].forEach((f,p)=>{const{start:h,end:x}=Fc(i,p,n);l&&l.valueOf()>h.valueOf()||u&&u.valueOf()<x.valueOf()||c.length&&!c.includes(f)||(r[f]=[...r[f],o])}),r},{MONDAY:[],TUESDAY:[],WEDNESDAY:[],THURSDAY:[],FRIDAY:[],SATURDAY:[],SUNDAY:[]})}function Hr(e,n){return Object.keys(e).reduce((i,r)=>(n.includes(r)||(i[r]=e[r]),i),{})}function Yc(e,n){const i=e.map(o=>Hr(o,["isActive"])),r=n.map(o=>Hr(o,["isActive"]));return JSON.stringify(i)===JSON.stringify(r)}function Kc(e){return e.reduce((n,i)=>{const r=n.find(o=>o.startTime===i.startTime&&o.endTime===i.endTime);return r?r.elements.push(...i.elements):n.push(i),n},[])}function Wc(e,n,i){const r=Uc(e.concat().filter(l=>!Gt(l)),n),{SUNDAY:o,...t}=r,[s,...c]=Object.keys({SUNDAY:r.SUNDAY,...t}).map((l,u)=>{const f=r[l],p=vt(i,n)===u;return{day:l,isActive:p,items:Bc(Kc(f.map(Hn)),p,i)}});return[...c,s].reduce((l,u,f,p)=>{const h=l[l.length-1],x=h?.items;if(!x||!Yc(x,u.items)){const{day:w,...O}=u;l.push({...O,days:[u.day]})}else h.days=[h.days[0],u.day],h.isActive=h.isActive||u.isActive;return l},[]).filter(l=>!!l.items.length)}function Gc(e){return!e||!e.elements?.some(o=>o?.price_components?.length>0)?"none":e.elements.filter(zi).length===e.elements.length?"base":zc(e.elements,6,new Date).length?"dynamic":"scheduled"}function qc(e){const{elements:n=[]}=e;return n?.some(t=>t?.priceComponents?.length>0)?n.filter(Gt).length===n.length?"base":Ui({elements:n,limit:6,now:new Date}).length?"dynamic":"scheduled":"none"}const ct={CONNECTOR_POWER_TYPE_AC_1_PHASE:"CONNECTOR_POWER_TYPE_AC_1_PHASE",CONNECTOR_POWER_TYPE_AC_2_PHASE:"CONNECTOR_POWER_TYPE_AC_2_PHASE",CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT:"CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT",CONNECTOR_POWER_TYPE_AC_3_PHASE:"CONNECTOR_POWER_TYPE_AC_3_PHASE",CONNECTOR_POWER_TYPE_DC:"CONNECTOR_POWER_TYPE_DC"};function Zc(e){switch(e.connectorPowerType){case ct.CONNECTOR_POWER_TYPE_AC_1_PHASE:case ct.CONNECTOR_POWER_TYPE_DC:return e.power.maxVoltage*e.power.maxAmperage/1e3;case ct.CONNECTOR_POWER_TYPE_AC_2_PHASE:case ct.CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT:return e.power.maxVoltage*e.power.maxAmperage*2/1e3;case ct.CONNECTOR_POWER_TYPE_AC_3_PHASE:return e.power.maxVoltage*e.power.maxAmperage*3/1e3;default:return 0}}const Jc="ConnectorTariff-module_container",Xc="ConnectorTariff-module_bold",Qc="ConnectorTariff-module_dynamicTariffItem",el="ConnectorTariff-module_dynamicTariffItemRange",tl="ConnectorTariff-module_tariffHeader",nl="ConnectorTariff-module_tariffLabel",rl="ConnectorTariff-module_tariffNote",il="ConnectorTariff-module_activeNowLabel",Ee={container:Jc,bold:Xc,dynamicTariffItem:Qc,dynamicTariffItemRange:el,tariffHeader:tl,tariffLabel:nl,tariffNote:rl,activeNowLabel:il},ol="Price-module_tariffItem",_n={tariffItem:ol};function sl(e,n){return new Intl.NumberFormat(void 0,{style:"currency",currency:n.currency||"EUR",maximumFractionDigits:2}).format(e)}function al(e){const n=e.vat?e.vat/100:0;return e.price+e.price*n}function cl({priceComponent:e,restrictions:n={},currency:i}){const{t:r}=Oe(),o={ENERGY:"tariffPriceComponent.energy",TIME:"tariffPriceComponent.time",FLAT:"tariffPriceComponent.flat",PARKING_TIME:"tariffPriceComponent.parkingTime"};return n?.minDuration===0&&n?.maxDuration&&e.type==="PARKING_TIME"?a.jsx("div",{className:_n.tariffItem,children:r("tariffPriceComponent.parkingTimeWait",{minutes:Math.floor(n.maxDuration/60)})}):o[e.type]?a.jsx("div",{className:_n.tariffItem,children:r(o[e.type],{total:sl(al(e),{currency:i})})}):null}const ll="PriceComponents-module_container",ul={container:ll},$r=["ENERGY","TIME","FLAT","PARKING_TIME"];function Dt({elements:e,currency:n}){const{t:i}=Oe(),r=e.reduce((t,s)=>(s.priceComponents.forEach(c=>{t[c.type]||(t[c.type]=[]),t[c.type].push({priceComponent:c,restrictions:s.restrictions})}),t),{}),o=Object.keys(r).map(t=>({type:t,elements:r[t]})).sort((t,s)=>{const c=$r.indexOf(t.type),l=$r.indexOf(s.type);return c===-1?1:l===-1?-1:c-l});return a.jsx("div",{className:ul.container,children:o.map(({type:t,elements:s},c)=>s.reverse().map((l,u)=>a.jsx(cl,{currency:n,priceComponent:l.priceComponent,restrictions:l.restrictions},`${t}-${c}-${u}`)))})}function dl(e,n){return new Intl.NumberFormat(void 0,{style:"currency",currency:n.currency||"EUR",maximumFractionDigits:2}).format(e)}function fl({vat:e,price:n}){const i=e?e/100:0;return n+n*i}function pl({cdrAdditionalCharge:e,currency:n}){const{t:i}=Oe(),r={FLAT_FEE:i("cdrPrice.flatFee",{total:dl(fl(e),{currency:n})})};return a.jsx("div",{className:_n.tariffItem,children:r[e.type]})}function Pt(e,n){const i=new Date(0),r=Math.floor(n/60),o=n%60;return i.setHours(r,o,0,0),i.toLocaleTimeString("nl",{hour:"2-digit",minute:"2-digit"})}const hl=Intl.DateTimeFormat().resolvedOptions().timeZone;function ml(e){const{format:n}=new Intl.DateTimeFormat(e,{weekday:"long"});return["SUNDAY","MONDAY","TUESDAY","WEDNESDAY","THURSDAY","FRIDAY","SATURDAY"].reduce((i,r,o)=>(i[r]=n(new Date(Date.UTC(2023,9,o+1))),i),{})}function lt({currency:e,cdrAdditionalCharges:n}){return n.map(i=>a.jsx(pl,{currency:e,cdrAdditionalCharge:i},i.id))}function $n({timezone:e=hl,tariff:n,compact:i=!0,cdrAdditionalCharges:r=[]}){const{t:o,language:t}=Oe(),s=ml(t);if(!n)return null;const c=n.elements||[],l=n.currency||"",u=c.some(w=>w.priceComponents&&w.priceComponents.length>0),f=Ui({elements:c,limit:i?6:40,now:new Date}),p=f.length?[]:Wc(c,e,new Date),h=c.filter(Gt);if(!u)return a.jsxs(a.Fragment,{children:[a.jsx("div",{className:Ee.tariffNote,children:o("tariffPriceComponent.noTariff")}),r.length>0&&a.jsx("div",{className:Ee.container,children:a.jsx(lt,{currency:l,cdrAdditionalCharges:r})})]});const x=!p.some(w=>w.isActive);return p.length?a.jsxs("div",{className:Ee.container,children:[h.length>0&&a.jsxs("div",{className:[Ee.tariffList,Ee.bold].join(" "),children:[a.jsxs("div",{className:Ee.tariffHeader,children:[o("tariffPriceComponent.baseTariff"),x&&a.jsx("span",{className:Ee.activeNowLabel,children:o("tariffPriceComponent.active")})]}),a.jsx(Dt,{elements:h,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r})]}),p.map(w=>a.jsxs("div",{className:Ee.tariffList,children:[a.jsxs("div",{className:Ee.tariffHeader,children:[w.days.map(O=>s[O]).join(" - "),w.isActive&&a.jsx("span",{className:Ee.activeNowLabel,children:o("tariffPriceComponent.active")})]}),w.items.map(O=>a.jsxs("div",{className:O.isActive&&Ee.bold,children:[!O.isFullDay&&a.jsxs("div",{className:Ee.tariffLabel,children:[Pt(t,O.startTime)," -"," ",Pt(t,O.endTime)]}),a.jsxs("div",{children:[a.jsx(Dt,{elements:O.elements,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r})]})]},O.startTime))]},w.days.join("-")))]}):a.jsxs("div",{className:Ee.container,children:[h.length>0&&a.jsxs("div",{className:Ee.tariffList,children:[a.jsx(Dt,{elements:h,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r})]}),f.length>0&&a.jsx(a.Fragment,{children:f.map((w,O)=>a.jsxs(a.Fragment,{children:[a.jsx("div",{className:Ee.tariffHeader,children:o("tariffPriceComponent.dynamicTariffHeader",{date:new Intl.DateTimeFormat(t,{weekday:"long",month:"short",day:"numeric"}).format(w.date)})}),a.jsx("div",{className:Ee.dynamicTariffList,children:w.items.map((E,M)=>a.jsxs("div",{className:[Ee.dynamicTariffItem,E.isActive&&Ee.bold].filter(Boolean).join(" "),children:[a.jsxs("div",{className:Ee.dynamicTariffItemRange,children:[Pt(t,E.startTime)," –"," ",Pt(t,E.endTime)]}),a.jsx(Dt,{elements:E.elements,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r}),E.isActive&&a.jsx("span",{className:Ee.activeNowLabel,children:o("tariffPriceComponent.active")})]},[E.startTime,E.endTime,M].join()))})]}))})]})}function zt(e,n,i){const r=[];return n?.customNote&&r.push(n?.customNote),i==="none"?r.length?r:[e("tariffNote.baseTariffNote")]:(i==="dynamic"&&r.push(e("tariffNote.dynamicScheduledTariffNote")),n?.infraProviderId==="NLEFL"||n?.party_id==="EFL"?(i==="scheduled"&&r.push(e("tariffNote.eFluxScheduledTariffNote")),r):(i==="scheduled"?r.push(e("tariffNote.baseTariffNote"),e("tariffNote.scheduledTariffNote")):r.push(e("tariffNote.baseTariffNote")),r))}const gl=({currentLocation:e,evses:n,setView:i,cdrAdditionalCharges:r})=>{const{options:o,t,language:s}=Oe(),c=n.filter(l=>l.status==="AVAILABLE");return a.jsxs("div",{className:S.container,children:[a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Si,alt:"station icon"}),a.jsxs("div",{className:S.text,children:[o.locationBaseUrl&&a.jsx("a",{href:`${o.locationBaseUrl}/${e.id}`,children:e.name||"-"}),!o.locationBaseUrl&&e.name]})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{className:S.icon,children:a.jsx("div",{style:{background:Vi(e.evses)},className:S.statusIcon})}),a.jsxs("div",{className:S.text,children:[c.length," / ",n.length," ",t("evse.statusAvailable")]})]}),e.subOperator?.name&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Di,alt:"building icon"}),a.jsx("div",{className:S.text,children:e.subOperator?.name})]}),e.parkingType!=="UNKNOWN"&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Pi,alt:"parking icon"}),a.jsx("div",{className:S.text,children:Li(t,e.parkingType)})]}),n.map(l=>a.jsxs("div",{children:[a.jsx("hr",{className:S.divider}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:l.evseId})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{style:{background:Fe(l.status)},className:S.statusIcon}),a.jsx("div",{className:S.text,children:[ji(t,l.status),l.maxPower&&`${Mi(s,Math.floor(l.maxPower))}kW`].filter(Boolean).join(", ")})]}),l.connectors.map((u,f)=>{const p=qc(u.tariff),h=zt(t,e,p);return a.jsxs("div",{children:[" ",a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ai(u),alt:"socket type"}),a.jsx("div",{className:S.text,children:ki(u)})]}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ri,alt:"pricing"}),a.jsx("div",{className:S.text,children:t("evse.pricing")})]}),a.jsx($n,{tariff:u.tariff,cdrAdditionalCharges:r}),p==="dynamic"&&a.jsx("div",{className:S.tariffNoteLink,onClick:()=>{i("dynamicTariff",{connector:u,evseId:l.evseId,notes:h,locationName:e.name})},children:t("location.viewAllHourlyPrices")}),h.length>0&&a.jsxs("div",{className:S.tariffNoteLink,onClick:()=>{i("tariffNote",{locationName:e.name,evseId:l.evseId,notes:zt(t,e,p)})},children:[a.jsx(Vn,{})," ",t("tariffPriceComponent.viewTariff")]})]},`connector-${f}`)})]},l.evseId))]})};function vl(e){return e?.currency?{currency:e.currency,id:e.id,country_code:e.country_code,party_id:e.party_id,elements:(e?.elements||[]).map(n=>({priceComponents:(n?.price_components||[]).map(i=>({type:(()=>{switch(i.type){case"FLAT":return"FLAT";case"TIME":return"TIME";case"ENERGY":return"ENERGY";case"PARKING_TIME":return"PARKING_TIME"}})(),price:i.price,vat:i.vat,stepSize:i.step_size})),...n?.restrictions?{restrictions:{startTime:n?.restrictions?.start_time,endTime:n?.restrictions?.end_time,startDate:n?.restrictions?.start_date,endDate:n?.restrictions?.end_date,dayOfWeek:n?.restrictions?.day_of_week}}:{}}))}:null}const _l=({tariff:e,additionalCharges:n})=>a.jsx($n,{tariff:vl(e),cdrAdditionalCharges:n}),Cl=({currentLocation:e,setView:n})=>{const{options:i,t:r,language:o}=Oe(),t=e?.evses?.filter(s=>s.status==="AVAILABLE")||[];return a.jsxs("div",{className:S.container,children:[i.context==="cpo"&&a.jsx("div",{className:S.publishingMode,children:e?.publish?"Public location":"Private location"}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Si,alt:"station icon"}),a.jsxs("div",{className:S.text,children:[i.locationBaseUrl&&a.jsx("a",{href:`${i.locationBaseUrl}/${e?.id}`,children:e?.name||"-"}),!i.locationBaseUrl&&e?.name]})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{className:S.icon,children:a.jsx("div",{style:{background:Vi(e.evses)},className:S.statusIcon})}),a.jsxs("div",{className:S.text,children:[t?.length," / ",e?.evses?.length," ",r("evse.statusAvailable")]})]}),e?.suboperator?.name&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Di,alt:"building icon"}),a.jsx("div",{className:S.text,children:e?.suboperator?.name})]}),e.parkingType!=="PARKING_TYPE_UNKNOWN"&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Pi,alt:"parking icon"}),a.jsx("div",{className:S.text,children:Li(r,e.parkingType)})]}),e?.evses?.map(s=>a.jsxs("div",{children:[a.jsx("hr",{className:S.divider}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:s.evse_id})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{style:{background:Fe(s.status)},className:S.statusIcon}),a.jsx("div",{className:S.text,children:[ji(r,s.status),s.connectors[0]?.power&&s.connectors[0]?.connectorPowerType?`${Mi(o,Math.floor(Zc(s.connectors[0])))}kW`:null].filter(Boolean).join(", ")})]}),s.connectors.map((c,l)=>{const u=e?.tariffs?.find(h=>h.id===c?.tariff_ids?.[0]),f=Gc(u),p=zt(r,e,f);return a.jsxs("div",{children:[" ",a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ai(c),alt:"socket type"}),a.jsx("div",{className:S.text,children:ki(c)})]}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ri,alt:"pricing"}),a.jsx("div",{className:S.text,children:r("evse.pricing")})]}),a.jsx(_l,{tariff:u,additionalCharges:e?.cdrAdditionalCharges||[]}),f==="dynamic"&&a.jsx("div",{className:S.tariffNoteLink,onClick:()=>{n("dynamicTariff",{connector:c,evseId:s.evse_id,notes:p,locationName:e.name})},children:r("location.viewAllHourlyPrices")}),i.context!=="cpo"&&p?.length>0&&a.jsxs("div",{className:S.tariffNoteLink,onClick:()=>{n("tariffNote",{locationName:e.name,evseId:s.evse_id,notes:zt(r,e,f)})},children:[a.jsx(Vn,{})," ",r("tariffPriceComponent.viewTariff")]})]},`connector-${l}`)})]},`${s.evse_id}-${s.uid}`))]})},El=()=>{const{setView:e}=_t(),{locations:n,locationsStatus:i,options:r}=Oe(),[o,t]=g.useState(0);g.useEffect(()=>{t(0)},[n]);const s=n[o];if(i.type==="loading"||!s)return a.jsx("div",{className:S.container,children:a.jsx(Oc,{})});const{evses:c=[],cdrAdditionalCharges:l}=s,u=o<n.length-1,f=o>0,p=window.location?.search?.includes("debug"),h=()=>{switch(r.version){case"v2":return[s?.address?.addressLine,s?.address?.city];default:return[s?.address,s?.city]}},x=r.version==="v2";return a.jsxs(a.Fragment,{children:[p&&s&&a.jsx(Lc,{location:s}),a.jsx("div",{className:S.headerContainer,children:a.jsxs("div",{className:S.header,children:[n.length>1&&a.jsxs("div",{className:S.pagingation,children:[a.jsxs("span",{children:[o+1," / ",n.length]}),a.jsx("button",{disabled:!f,onClick:()=>{t(Math.max(0,o-1))},children:a.jsx(Oi,{})}),a.jsx("button",{disabled:!u,onClick:()=>t(Math.min(n.length-1,o+1)),children:a.jsx(Sc,{})})]}),h().filter(Boolean).join(", ")]})}),!x&&a.jsx(gl,{setView:e,cdrAdditionalCharges:l,currentLocation:s,evses:c}),x&&a.jsx(Cl,{setView:e,currentLocation:s})]})},yl="BackButton-module_backButton",Tl={backButton:yl};function Yi({onClick:e=()=>{}}){const{t:n}=Oe();return a.jsxs("button",{onClick:e,className:Tl.backButton,children:[a.jsx(Oi,{}),n("backButton.backTo")]})}function xl(){const{t:e}=Oe(),{current:n,setView:i}=_t(),{notes:r=[],evseId:o,locationName:t}=n?.args||{};return a.jsxs(a.Fragment,{children:[a.jsx("div",{className:S.headerContainer,children:a.jsxs("div",{className:S.header,onClick:()=>i("locations"),style:{cursor:"pointer"},children:[a.jsx(Yi,{}),t?.text||t]})}),a.jsxs("div",{className:S.container,children:[a.jsx("div",{className:S.subheader,children:e("tariffNote.subHeader")}),o&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:o})]}),r.map(s=>a.jsx("p",{className:S.note,children:s},s))]})]})}function bl(){const{t:e}=Oe(),{current:n,setView:i}=_t(),{connector:r,locationName:o,evseId:t,notes:s}=n?.args||{};return r?.tariff?a.jsxs(a.Fragment,{children:[a.jsx("div",{className:S.headerContainer,children:a.jsxs("div",{className:S.header,onClick:()=>i("locations"),style:{cursor:"pointer"},children:[a.jsx(Yi,{}),o]})}),a.jsxs("div",{className:S.container,children:[a.jsx("div",{className:S.subheader,children:e("dynamicTariffs.subHeader")}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:t})]}),a.jsx($n,{tariff:r.tariff,compact:!1}),a.jsxs("div",{className:S.tariffNoteLink,onClick:()=>{i("tariffNote",{locationName:o,evseId:t,notes:s})},children:[a.jsx(Vn,{})," ",e("tariffPriceComponent.viewTariff")]})]})]}):null}const Il="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='10'%20height='11'%20viewBox='0%200%2010%2011'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M6.48751%205.99758L9.85376%202.63133C10.0484%202.43664%2010.0484%202.1207%209.85376%201.9257L9.07157%201.14351C8.87688%200.948826%208.56095%200.948826%208.36595%201.14351L5.00001%204.51008L1.63376%201.14383C1.43907%200.949138%201.12313%200.949138%200.928135%201.14383L0.14626%201.9257C-0.0484277%202.12039%20-0.0484277%202.43633%200.14626%202.63133L3.51251%205.99758L0.14626%209.36383C-0.0484277%209.55851%20-0.0484277%209.87445%200.14626%2010.0695L0.928447%2010.8516C1.12313%2011.0463%201.43907%2011.0463%201.63407%2010.8516L5.00001%207.48508L8.36626%2010.8513C8.56095%2011.046%208.87688%2011.046%209.07188%2010.8513L9.85407%2010.0691C10.0488%209.87445%2010.0488%209.55851%209.85407%209.36351L6.48751%205.99758Z'%20fill='black'/%3e%3c/svg%3e",wl="CloseButton-module_closeButton",Nl={closeButton:wl};function Ki({onClick:e}){return a.jsx("button",{onClick:e,className:Nl.closeButton,children:a.jsx("img",{src:Il})})}function Ol(){const[e,n]=g.useState("locations"),{setView:i}=_t();return a.jsxs($e,{name:"locations",currentView:e,onViewChange:n,children:[a.jsx($e.View,{name:"locations",children:a.jsxs(mt,{children:[a.jsx(Ki,{onClick:()=>i("none")}),a.jsx(El,{})]})}),a.jsx($e.View,{name:"tariffNote",children:a.jsx(mt,{children:a.jsx(xl,{})})}),a.jsx($e.View,{name:"dynamicTariff",children:a.jsx(mt,{children:a.jsx(bl,{})})})]})}const Sl="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='currentColor'%20xmlns='http://www.w3.org/2000/svg'%20%3e%3cpath%20d='M14.4985%200H1.50178C0.169343%200%20-0.502939%201.61659%200.441124%202.56066L5.5%207.62131V13C5.5%2013.4721%205.72228%2013.9167%206.1%2014.25L8.1%2015.7208C9.07728%2016.4038%2010.5%2015.7689%2010.5%2014.5208V7.62131L15.5592%202.56066C16.5013%201.6185%2015.8336%200%2014.4985%200ZM9%207V14.5L7%2013V7L1.5%201.5H14.5L9%207Z'%20fill='currentColor'%20/%3e%3c/svg%3e";function Dl(){const{locationIds:e,fetchLocations:n,filters:i}=Oe(),[r,o]=g.useState("none");return g.useEffect(()=>{e.length>0&&o("locations")},[e,o]),a.jsxs("div",{className:et.container,children:[a.jsxs("div",{className:et.controlsContainer,children:[a.jsx(Ns,{onFocus:()=>{o("none")}}),a.jsxs("div",{className:et.filterButton,onClick:()=>{o("filters")},children:[a.jsx("img",{className:et.filterIcon,src:Sl}),sc(i)&&a.jsx("span",{className:et.filterCounter})]})]}),a.jsx("div",{className:et.stackContainer,children:a.jsxs($e,{name:"router",currentView:r,onViewChange:t=>{o(t)},children:[a.jsx($e.View,{name:"locations",children:a.jsx(Ol,{})}),a.jsx($e.View,{name:"filters",children:a.jsxs(mt,{children:[a.jsx(Ki,{onClick:()=>o("none")}),a.jsx(lc,{})]})})]})})]})}function Pl(e){return a.jsx(Ro,{options:e,language:e.language,children:a.jsxs(Ao,{height:e?.height,children:[a.jsx(Dl,{}),a.jsx(Zo,{})]})})}exports.RoadMap=Pl;
|
|
73
|
+
*/var Er;function Ws(){return Er||(Er=1,process.env.NODE_ENV!=="production"&&(function(){var e=Symbol.for("react.element"),n=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),t=Symbol.for("react.provider"),s=Symbol.for("react.context"),c=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),x=Symbol.for("react.offscreen"),w=!1,N=!1,E=!1,k=!1,C=!1,y;y=Symbol.for("react.module.reference");function T(L){return!!(typeof L=="string"||typeof L=="function"||L===i||L===o||C||L===r||L===u||L===f||k||L===x||w||N||E||typeof L=="object"&&L!==null&&(L.$$typeof===h||L.$$typeof===p||L.$$typeof===t||L.$$typeof===s||L.$$typeof===l||L.$$typeof===y||L.getModuleId!==void 0))}function m(L){if(typeof L=="object"&&L!==null){var xe=L.$$typeof;switch(xe){case e:var ge=L.type;switch(ge){case i:case o:case r:case u:case f:return ge;default:var we=ge&&ge.$$typeof;switch(we){case c:case s:case l:case h:case p:case t:return we;default:return xe}}case n:return xe}}}var R=s,J=t,F=e,Q=l,B=i,W=h,te=p,P=n,D=o,re=r,ne=u,_e=f,G=!1,A=!1;function g(L){return G||(G=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function b(L){return A||(A=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function H(L){return m(L)===s}function Y(L){return m(L)===t}function V(L){return typeof L=="object"&&L!==null&&L.$$typeof===e}function Z(L){return m(L)===l}function j(L){return m(L)===i}function $(L){return m(L)===h}function z(L){return m(L)===p}function ee(L){return m(L)===n}function q(L){return m(L)===o}function ae(L){return m(L)===r}function O(L){return m(L)===u}function me(L){return m(L)===f}fe.ContextConsumer=R,fe.ContextProvider=J,fe.Element=F,fe.ForwardRef=Q,fe.Fragment=B,fe.Lazy=W,fe.Memo=te,fe.Portal=P,fe.Profiler=D,fe.StrictMode=re,fe.Suspense=ne,fe.SuspenseList=_e,fe.isAsyncMode=g,fe.isConcurrentMode=b,fe.isContextConsumer=H,fe.isContextProvider=Y,fe.isElement=V,fe.isForwardRef=Z,fe.isFragment=j,fe.isLazy=$,fe.isMemo=z,fe.isPortal=ee,fe.isProfiler=q,fe.isStrictMode=ae,fe.isSuspense=O,fe.isSuspenseList=me,fe.isValidElementType=T,fe.typeOf=m})()),fe}var yr;function Gs(){return yr||(yr=1,process.env.NODE_ENV==="production"?It.exports=Ks():It.exports=Ws()),It.exports}var Tr=Gs();const xr=e=>typeof e=="object"&&e!=null&&e.nodeType===1,br=(e,n)=>(!n||e!=="hidden")&&e!=="visible"&&e!=="clip",wt=(e,n)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){const i=getComputedStyle(e,null);return br(i.overflowY,n)||br(i.overflowX,n)||(r=>{const o=(t=>{if(!t.ownerDocument||!t.ownerDocument.defaultView)return null;try{return t.ownerDocument.defaultView.frameElement}catch{return null}})(r);return!!o&&(o.clientHeight<r.scrollHeight||o.clientWidth<r.scrollWidth)})(e)}return!1},Nt=(e,n,i,r,o,t,s,c)=>t<e&&s>n||t>e&&s<n?0:t<=e&&c<=i||s>=n&&c>=i?t-e-r:s>n&&c<i||t<e&&c>i?s-n+o:0,qs=e=>{const n=e.parentElement;return n??(e.getRootNode().host||null)},Zs=(e,n)=>{var i,r,o,t;if(typeof document>"u")return[];const{inline:s,boundary:c,skipOverflowHiddenElements:l}=n,u=typeof c=="function"?c:P=>P!==c;if(!xr(e))throw new TypeError("Invalid target");const f=document.scrollingElement||document.documentElement,p=[];let h=e;for(;xr(h)&&u(h);){if(h=qs(h),h===f){p.push(h);break}h!=null&&h===document.body&&wt(h)&&!wt(document.documentElement)||h!=null&&wt(h,l)&&p.push(h)}const x=(r=(i=window.visualViewport)==null?void 0:i.width)!=null?r:innerWidth,w=(t=(o=window.visualViewport)==null?void 0:o.height)!=null?t:innerHeight,{scrollX:N,scrollY:E}=window,{height:k,width:C,top:y,right:T,bottom:m,left:R}=e.getBoundingClientRect(),{top:J,right:F,left:Q}=(P=>{const D=window.getComputedStyle(P);return{top:parseFloat(D.scrollMarginTop)||0,right:parseFloat(D.scrollMarginRight)||0,bottom:parseFloat(D.scrollMarginBottom)||0,left:parseFloat(D.scrollMarginLeft)||0}})(e);let B=y-J,W=s==="center"?R+C/2-Q+F:s==="end"?T+F:R-Q;const te=[];for(let P=0;P<p.length;P++){const D=p[P],{height:re,width:ne,top:_e,right:G,bottom:A,left:g}=D.getBoundingClientRect();if(y>=0&&R>=0&&m<=w&&T<=x&&(D===f&&!wt(D)||y>=_e&&m<=A&&R>=g&&T<=G))return te;const b=getComputedStyle(D),H=parseInt(b.borderLeftWidth,10),Y=parseInt(b.borderTopWidth,10),V=parseInt(b.borderRightWidth,10),Z=parseInt(b.borderBottomWidth,10);let j=0,$=0;const z="offsetWidth"in D?D.offsetWidth-D.clientWidth-H-V:0,ee="offsetHeight"in D?D.offsetHeight-D.clientHeight-Y-Z:0,q="offsetWidth"in D?D.offsetWidth===0?0:ne/D.offsetWidth:0,ae="offsetHeight"in D?D.offsetHeight===0?0:re/D.offsetHeight:0;if(f===D)j=Nt(E,E+w,w,Y,Z,E+B,E+B+k,k),$=s==="start"?W:s==="center"?W-x/2:s==="end"?W-x:Nt(N,N+x,x,H,V,N+W,N+W+C,C),j=Math.max(0,j+E),$=Math.max(0,$+N);else{j=Nt(_e,A,re,Y,Z+ee,B,B+k,k),$=s==="start"?W-g-H:s==="center"?W-(g+ne/2)+z/2:s==="end"?W-G+V+z:Nt(g,G,ne,H,V+z,W,W+C,C);const{scrollLeft:O,scrollTop:me}=D;j=ae===0?0:Math.max(0,Math.min(me+j/ae,D.scrollHeight-re/ae+ee)),$=q===0?0:Math.max(0,Math.min(O+$/q,D.scrollWidth-ne/q+z)),B+=me-j,W+=O-$}te.push({el:D,top:j,left:$})}return te};var it=function(){return it=Object.assign||function(n){for(var i,r=1,o=arguments.length;r<o;r++){i=arguments[r];for(var t in i)Object.prototype.hasOwnProperty.call(i,t)&&(n[t]=i[t])}return n},it.apply(this,arguments)};var Js=0;function Ir(e){return typeof e=="function"?e:De}function De(){}function Kr(e,n){if(e){var i=Zs(e,{boundary:n});i.forEach(function(r){var o=r.el,t=r.top,s=r.left;o.scrollTop=t,o.scrollLeft=s})}}function wr(e,n,i){var r=e===n||n instanceof i.Node&&e.contains&&e.contains(n);return r}function Kt(e,n){var i;function r(){i&&clearTimeout(i)}function o(){for(var t=arguments.length,s=new Array(t),c=0;c<t;c++)s[c]=arguments[c];r(),i=setTimeout(function(){i=null,e.apply(void 0,s)},n)}return o.cancel=r,o}function Te(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return function(r){for(var o=arguments.length,t=new Array(o>1?o-1:0),s=1;s<o;s++)t[s-1]=arguments[s];return n.some(function(c){return c&&c.apply(void 0,[r].concat(t)),r.preventDownshiftDefault||r.hasOwnProperty("nativeEvent")&&r.nativeEvent.preventDownshiftDefault})}}function ft(){for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return function(r){n.forEach(function(o){typeof o=="function"?o(r):o&&(o.current=r)})}}function Wr(){return String(Js++)}function Xs(e){var n=e.isOpen,i=e.resultCount,r=e.previousResultCount;return n?i?i!==r?i+" result"+(i===1?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":""}function Nr(e,n){return e=Array.isArray(e)?e[0]:e,!e&&n?n:e}function Gr(e){return typeof e.type=="string"}function qr(e){return e.props}function Qs(e,n){console.error('The property "'+n+'" is required in "'+e+'"')}var ea=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Ot(e){e===void 0&&(e={});var n={};return ea.forEach(function(i){e.hasOwnProperty(i)&&(n[i]=e[i])}),n}function Vt(e,n){return!e||!n?e:Object.keys(e).reduce(function(i,r){return i[r]=hn(n,r)?n[r]:e[r],i},{})}function hn(e,n){return e[n]!==void 0}function mn(e){var n=e.key,i=e.keyCode;return i>=37&&i<=40&&n.indexOf("Arrow")!==0?"Arrow"+n:n}function ta(e){return Object.prototype.toString.call(e)==="[object Object]"}function Ze(e,n,i,r,o){o===void 0&&(o=!1);var t=i.length;if(t===0)return-1;var s=t-1;(typeof e!="number"||e<0||e>s)&&(e=n>0?-1:s+1);var c=e+n;c<0?c=o?s:0:c>s&&(c=o?0:s);var l=ot(c,n<0,i,r,o);return l===-1?e>=t?-1:e:l}function ot(e,n,i,r,o){o===void 0&&(o=!1);var t=i.length;if(n){for(var s=e;s>=0;s--)if(!r(i[s],s))return s}else for(var c=e;c<t;c++)if(!r(i[c],c))return c;return o?ot(n?t-1:0,n,i,r):-1}function Ht(e,n,i,r){return r===void 0&&(r=!0),i&&n.some(function(o){return o&&(wr(o,e,i)||r&&wr(o,i.document.activeElement,i))})}var bn=De;process.env.NODE_ENV!=="production"&&(bn=function(n,i,r){var o="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(n).forEach(function(t){i[t]!==void 0&&r[t]===void 0?console.error('downshift: A component has changed the controlled prop "'+t+'" to be uncontrolled. '+o):i[t]===void 0&&r[t]!==void 0&&console.error('downshift: A component has changed the uncontrolled prop "'+t+'" to be controlled. '+o)})});var na=Kt(function(e){Zr(e).textContent=""},500);function Zr(e){var n=e.getElementById("a11y-status-message");return n||(n=e.createElement("div"),n.setAttribute("id","a11y-status-message"),n.setAttribute("role","status"),n.setAttribute("aria-live","polite"),n.setAttribute("aria-relevant","additions text"),Object.assign(n.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(n),n)}function Jr(e,n){if(!(!e||!n)){var i=Zr(n);i.textContent=e,na(n)}}function ra(e){var n=e?.getElementById("a11y-status-message");n&&n.remove()}var Xr=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,Qr=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,ei=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Rt=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,At=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,ti=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,ni=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,ri=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,ii=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,oi=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,si=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,ai=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,ci=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,gn=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,li=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,ui=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,di=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16,ia=Object.freeze({__proto__:null,blurButton:li,blurInput:si,changeInput:ai,clickButton:gn,clickItem:oi,controlledPropUpdatedSelectedItem:ui,itemMouseEnter:ei,keyDownArrowDown:At,keyDownArrowUp:Rt,keyDownEnd:ii,keyDownEnter:ni,keyDownEscape:ti,keyDownHome:ri,keyDownSpaceButton:ci,mouseUp:Qr,touchEnd:di,unknown:Xr}),oa=["refKey","ref"],sa=["onClick","onPress","onKeyDown","onKeyUp","onBlur"],aa=["onKeyDown","onBlur","onChange","onInput","onChangeText"],ca=["refKey","ref"],la=["onMouseMove","onMouseDown","onClick","onPress","index","item"],ua=(function(){var e=(function(n){function i(o){var t;t=n.call(this,o)||this,t.id=t.props.id||"downshift-"+Wr(),t.menuId=t.props.menuId||t.id+"-menu",t.labelId=t.props.labelId||t.id+"-label",t.inputId=t.props.inputId||t.id+"-input",t.getItemId=t.props.getItemId||function(C){return t.id+"-item-"+C},t.items=[],t.itemCount=null,t.previousResultCount=0,t.timeoutIds=[],t.internalSetTimeout=function(C,y){var T=setTimeout(function(){t.timeoutIds=t.timeoutIds.filter(function(m){return m!==T}),C()},y);t.timeoutIds.push(T)},t.setItemCount=function(C){t.itemCount=C},t.unsetItemCount=function(){t.itemCount=null},t.isItemDisabled=function(C,y){var T=t.getItemNodeFromIndex(y);return T&&T.hasAttribute("disabled")},t.setHighlightedIndex=function(C,y){C===void 0&&(C=t.props.defaultHighlightedIndex),y===void 0&&(y={}),y=Ot(y),t.internalSetState(ie({highlightedIndex:C},y))},t.clearSelection=function(C){t.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:t.props.defaultHighlightedIndex,isOpen:t.props.defaultIsOpen},C)},t.selectItem=function(C,y,T){y=Ot(y),t.internalSetState(ie({isOpen:t.props.defaultIsOpen,highlightedIndex:t.props.defaultHighlightedIndex,selectedItem:C,inputValue:t.props.itemToString(C)},y),T)},t.selectItemAtIndex=function(C,y,T){var m=t.items[C];m!=null&&t.selectItem(m,y,T)},t.selectHighlightedItem=function(C,y){return t.selectItemAtIndex(t.getState().highlightedIndex,C,y)},t.internalSetState=function(C,y){var T,m,R={},J=typeof C=="function";return!J&&C.hasOwnProperty("inputValue")&&t.props.onInputValueChange(C.inputValue,ie({},t.getStateAndHelpers(),C)),t.setState(function(F){var Q;F=t.getState(F);var B=J?C(F):C;B=t.props.stateReducer(F,B),T=B.hasOwnProperty("selectedItem");var W={};return T&&B.selectedItem!==F.selectedItem&&(m=B.selectedItem),(Q=B).type||(Q.type=Xr),Object.keys(B).forEach(function(te){F[te]!==B[te]&&(R[te]=B[te]),te!=="type"&&(B[te],hn(t.props,te)||(W[te]=B[te]))}),J&&B.hasOwnProperty("inputValue")&&t.props.onInputValueChange(B.inputValue,ie({},t.getStateAndHelpers(),B)),W},function(){Ir(y)();var F=Object.keys(R).length>1;F&&t.props.onStateChange(R,t.getStateAndHelpers()),T&&t.props.onSelect(C.selectedItem,t.getStateAndHelpers()),m!==void 0&&t.props.onChange(m,t.getStateAndHelpers()),t.props.onUserAction(R,t.getStateAndHelpers())})},t.rootRef=function(C){return t._rootNode=C},t.getRootProps=function(C,y){var T,m=C===void 0?{}:C,R=m.refKey,J=R===void 0?"ref":R,F=m.ref,Q=ke(m,oa),B=y===void 0?{}:y,W=B.suppressRefError,te=W===void 0?!1:W;t.getRootProps.called=!0,t.getRootProps.refKey=J,t.getRootProps.suppressRefError=te;var P=t.getState(),D=P.isOpen;return ie((T={},T[J]=ft(F,t.rootRef),T.role="combobox",T["aria-expanded"]=D,T["aria-haspopup"]="listbox",T["aria-owns"]=D?t.menuId:void 0,T["aria-labelledby"]=t.labelId,T),Q)},t.keyDownHandlers={ArrowDown:function(y){var T=this;if(y.preventDefault(),this.getState().isOpen){var m=y.shiftKey?5:1;this.moveHighlightedIndex(m,{type:At})}else this.internalSetState({isOpen:!0,type:At},function(){var R=T.getItemCount();if(R>0){var J=T.getState(),F=J.highlightedIndex,Q=Ze(F,1,{length:R},T.isItemDisabled,!0);T.setHighlightedIndex(Q,{type:At})}})},ArrowUp:function(y){var T=this;if(y.preventDefault(),this.getState().isOpen){var m=y.shiftKey?-5:-1;this.moveHighlightedIndex(m,{type:Rt})}else this.internalSetState({isOpen:!0,type:Rt},function(){var R=T.getItemCount();if(R>0){var J=T.getState(),F=J.highlightedIndex,Q=Ze(F,-1,{length:R},T.isItemDisabled,!0);T.setHighlightedIndex(Q,{type:Rt})}})},Enter:function(y){if(y.which!==229){var T=this.getState(),m=T.isOpen,R=T.highlightedIndex;if(m&&R!=null){y.preventDefault();var J=this.items[R],F=this.getItemNodeFromIndex(R);if(J==null||F&&F.hasAttribute("disabled"))return;this.selectHighlightedItem({type:ni})}}},Escape:function(y){y.preventDefault(),this.reset(ie({type:ti},!this.state.isOpen&&{selectedItem:null,inputValue:""}))}},t.buttonKeyDownHandlers=ie({},t.keyDownHandlers,{" ":function(y){y.preventDefault(),this.toggleMenu({type:ci})}}),t.inputKeyDownHandlers=ie({},t.keyDownHandlers,{Home:function(y){var T=this.getState(),m=T.isOpen;if(m){y.preventDefault();var R=this.getItemCount();if(!(R<=0||!m)){var J=ot(0,!1,{length:R},this.isItemDisabled);this.setHighlightedIndex(J,{type:ri})}}},End:function(y){var T=this.getState(),m=T.isOpen;if(m){y.preventDefault();var R=this.getItemCount();if(!(R<=0||!m)){var J=ot(R-1,!0,{length:R},this.isItemDisabled);this.setHighlightedIndex(J,{type:ii})}}}}),t.getToggleButtonProps=function(C){var y=C===void 0?{}:C,T=y.onClick;y.onPress;var m=y.onKeyDown,R=y.onKeyUp,J=y.onBlur,F=ke(y,sa),Q=t.getState(),B=Q.isOpen,W={onClick:Te(T,t.buttonHandleClick),onKeyDown:Te(m,t.buttonHandleKeyDown),onKeyUp:Te(R,t.buttonHandleKeyUp),onBlur:Te(J,t.buttonHandleBlur)},te=F.disabled?{}:W;return ie({type:"button",role:"button","aria-label":B?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},te,F)},t.buttonHandleKeyUp=function(C){C.preventDefault()},t.buttonHandleKeyDown=function(C){var y=mn(C);t.buttonKeyDownHandlers[y]&&t.buttonKeyDownHandlers[y].call(t,C)},t.buttonHandleClick=function(C){if(C.preventDefault(),t.props.environment){var y=t.props.environment.document,T=y.body,m=y.activeElement;T&&T===m&&C.target.focus()}process.env.NODE_ENV==="test"?t.toggleMenu({type:gn}):t.internalSetTimeout(function(){return t.toggleMenu({type:gn})})},t.buttonHandleBlur=function(C){var y=C.target;t.internalSetTimeout(function(){if(!(t.isMouseDown||!t.props.environment)){var T=t.props.environment.document.activeElement;(T==null||T.id!==t.inputId)&&T!==y&&t.reset({type:li})}})},t.getLabelProps=function(C){return ie({htmlFor:t.inputId,id:t.labelId},C)},t.getInputProps=function(C){var y=C===void 0?{}:C,T=y.onKeyDown,m=y.onBlur,R=y.onChange,J=y.onInput;y.onChangeText;var F=ke(y,aa),Q,B={};Q="onChange";var W=t.getState(),te=W.inputValue,P=W.isOpen,D=W.highlightedIndex;if(!F.disabled){var re;B=(re={},re[Q]=Te(R,J,t.inputHandleChange),re.onKeyDown=Te(T,t.inputHandleKeyDown),re.onBlur=Te(m,t.inputHandleBlur),re)}return ie({"aria-autocomplete":"list","aria-activedescendant":P&&typeof D=="number"&&D>=0?t.getItemId(D):void 0,"aria-controls":P?t.menuId:void 0,"aria-labelledby":F&&F["aria-label"]?void 0:t.labelId,autoComplete:"off",value:te,id:t.inputId},B,F)},t.inputHandleKeyDown=function(C){var y=mn(C);y&&t.inputKeyDownHandlers[y]&&t.inputKeyDownHandlers[y].call(t,C)},t.inputHandleChange=function(C){t.internalSetState({type:ai,isOpen:!0,inputValue:C.target.value,highlightedIndex:t.props.defaultHighlightedIndex})},t.inputHandleBlur=function(){t.internalSetTimeout(function(){var C;if(!(t.isMouseDown||!t.props.environment)){var y=t.props.environment.document.activeElement,T=(y==null||(C=y.dataset)==null?void 0:C.toggle)&&t._rootNode&&t._rootNode.contains(y);T||t.reset({type:si})}})},t.menuRef=function(C){t._menuNode=C},t.getMenuProps=function(C,y){var T,m=C===void 0?{}:C,R=m.refKey,J=R===void 0?"ref":R,F=m.ref,Q=ke(m,ca),B=y===void 0?{}:y,W=B.suppressRefError,te=W===void 0?!1:W;return t.getMenuProps.called=!0,t.getMenuProps.refKey=J,t.getMenuProps.suppressRefError=te,ie((T={},T[J]=ft(F,t.menuRef),T.role="listbox",T["aria-labelledby"]=Q&&Q["aria-label"]?void 0:t.labelId,T.id=t.menuId,T),Q)},t.getItemProps=function(C){var y,T=C===void 0?{}:C,m=T.onMouseMove,R=T.onMouseDown,J=T.onClick;T.onPress;var F=T.index,Q=T.item,B=Q===void 0?process.env.NODE_ENV==="production"?void 0:Qs("getItemProps","item"):Q,W=ke(T,la);F===void 0?(t.items.push(B),F=t.items.indexOf(B)):t.items[F]=B;var te="onClick",P=J,D=(y={onMouseMove:Te(m,function(){F!==t.getState().highlightedIndex&&(t.setHighlightedIndex(F,{type:ei}),t.avoidScrolling=!0,t.internalSetTimeout(function(){return t.avoidScrolling=!1},250))}),onMouseDown:Te(R,function(ne){ne.preventDefault()})},y[te]=Te(P,function(){t.selectItemAtIndex(F,{type:oi})}),y),re=W.disabled?{onMouseDown:D.onMouseDown}:D;return ie({id:t.getItemId(F),role:"option","aria-selected":t.getState().highlightedIndex===F},re,W)},t.clearItems=function(){t.items=[]},t.reset=function(C,y){C===void 0&&(C={}),C=Ot(C),t.internalSetState(function(T){var m=T.selectedItem;return ie({isOpen:t.props.defaultIsOpen,highlightedIndex:t.props.defaultHighlightedIndex,inputValue:t.props.itemToString(m)},C)},y)},t.toggleMenu=function(C,y){C===void 0&&(C={}),C=Ot(C),t.internalSetState(function(T){var m=T.isOpen;return ie({isOpen:!m},m&&{highlightedIndex:t.props.defaultHighlightedIndex},C)},function(){var T=t.getState(),m=T.isOpen,R=T.highlightedIndex;m&&t.getItemCount()>0&&typeof R=="number"&&t.setHighlightedIndex(R,C),Ir(y)()})},t.openMenu=function(C){t.internalSetState({isOpen:!0},C)},t.closeMenu=function(C){t.internalSetState({isOpen:!1},C)},t.updateStatus=Kt(function(){var C;if((C=t.props)!=null&&(C=C.environment)!=null&&C.document){var y=t.getState(),T=t.items[y.highlightedIndex],m=t.getItemCount(),R=t.props.getA11yStatusMessage(ie({itemToString:t.props.itemToString,previousResultCount:t.previousResultCount,resultCount:m,highlightedItem:T},y));t.previousResultCount=m,Jr(R,t.props.environment.document)}},200);var s=t.props,c=s.defaultHighlightedIndex,l=s.initialHighlightedIndex,u=l===void 0?c:l,f=s.defaultIsOpen,p=s.initialIsOpen,h=p===void 0?f:p,x=s.initialInputValue,w=x===void 0?"":x,N=s.initialSelectedItem,E=N===void 0?null:N,k=t.getState({highlightedIndex:u,isOpen:h,inputValue:w,selectedItem:E});return k.selectedItem!=null&&t.props.initialInputValue===void 0&&(k.inputValue=t.props.itemToString(k.selectedItem)),t.state=k,t}Yt(i,n);var r=i.prototype;return r.internalClearTimeouts=function(){this.timeoutIds.forEach(function(t){clearTimeout(t)}),this.timeoutIds=[]},r.getState=function(t){return t===void 0&&(t=this.state),Vt(t,this.props)},r.getItemCount=function(){var t=this.items.length;return this.itemCount!=null?t=this.itemCount:this.props.itemCount!==void 0&&(t=this.props.itemCount),t},r.getItemNodeFromIndex=function(t){return this.props.environment?this.props.environment.document.getElementById(this.getItemId(t)):null},r.scrollHighlightedItemIntoView=function(){{var t=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(t,this._menuNode)}},r.moveHighlightedIndex=function(t,s){var c=this.getItemCount(),l=this.getState(),u=l.highlightedIndex;if(c>0){var f=Ze(u,t,{length:c},this.isItemDisabled,!0);this.setHighlightedIndex(f,s)}},r.getStateAndHelpers=function(){var t=this.getState(),s=t.highlightedIndex,c=t.inputValue,l=t.selectedItem,u=t.isOpen,f=this.props.itemToString,p=this.id,h=this.getRootProps,x=this.getToggleButtonProps,w=this.getLabelProps,N=this.getMenuProps,E=this.getInputProps,k=this.getItemProps,C=this.openMenu,y=this.closeMenu,T=this.toggleMenu,m=this.selectItem,R=this.selectItemAtIndex,J=this.selectHighlightedItem,F=this.setHighlightedIndex,Q=this.clearSelection,B=this.clearItems,W=this.reset,te=this.setItemCount,P=this.unsetItemCount,D=this.internalSetState;return{getRootProps:h,getToggleButtonProps:x,getLabelProps:w,getMenuProps:N,getInputProps:E,getItemProps:k,reset:W,openMenu:C,closeMenu:y,toggleMenu:T,selectItem:m,selectItemAtIndex:R,selectHighlightedItem:J,setHighlightedIndex:F,clearSelection:Q,clearItems:B,setItemCount:te,unsetItemCount:P,setState:D,itemToString:f,id:p,highlightedIndex:s,inputValue:c,isOpen:u,selectedItem:l}},r.componentDidMount=function(){var t=this;if(process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&Or(this._menuNode,this.getMenuProps),!this.props.environment)this.cleanup=function(){t.internalClearTimeouts()};else{var s=function(){t.isMouseDown=!0},c=function(x){t.isMouseDown=!1;var w=Ht(x.target,[t._rootNode,t._menuNode],t.props.environment);!w&&t.getState().isOpen&&t.reset({type:Qr},function(){return t.props.onOuterClick(t.getStateAndHelpers())})},l=function(){t.isTouchMove=!1},u=function(){t.isTouchMove=!0},f=function(x){var w=Ht(x.target,[t._rootNode,t._menuNode],t.props.environment,!1);!t.isTouchMove&&!w&&t.getState().isOpen&&t.reset({type:di},function(){return t.props.onOuterClick(t.getStateAndHelpers())})},p=this.props.environment;p.addEventListener("mousedown",s),p.addEventListener("mouseup",c),p.addEventListener("touchstart",l),p.addEventListener("touchmove",u),p.addEventListener("touchend",f),this.cleanup=function(){t.internalClearTimeouts(),t.updateStatus.cancel(),p.removeEventListener("mousedown",s),p.removeEventListener("mouseup",c),p.removeEventListener("touchstart",l),p.removeEventListener("touchmove",u),p.removeEventListener("touchend",f)}}},r.shouldScroll=function(t,s){var c=this.props.highlightedIndex===void 0?this.getState():this.props,l=c.highlightedIndex,u=s.highlightedIndex===void 0?t:s,f=u.highlightedIndex,p=l&&this.getState().isOpen&&!t.isOpen,h=l!==f;return p||h},r.componentDidUpdate=function(t,s){process.env.NODE_ENV!=="production"&&(bn(this.state,t,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&Or(this._menuNode,this.getMenuProps)),hn(this.props,"selectedItem")&&this.props.selectedItemChanged(t.selectedItem,this.props.selectedItem)&&this.internalSetState({type:ui,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(s,t)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},r.componentWillUnmount=function(){this.cleanup()},r.render=function(){var t=Nr(this.props.children,De);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var s=Nr(t(this.getStateAndHelpers()));if(!s)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&da(s,this.getRootProps),s;if(Gr(s))return v.cloneElement(s,this.getRootProps(qr(s)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")},i})(v.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:Xs,itemToString:function(i){return i==null?"":(process.env.NODE_ENV!=="production"&&ta(i)&&!i.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",i),String(i))},onStateChange:De,onInputValueChange:De,onUserAction:De,onChange:De,onSelect:De,onOuterClick:De,selectedItemChanged:function(i,r){return i!==r},environment:typeof window>"u"?void 0:window,stateReducer:function(i,r){return r},suppressRefError:!1,scrollIntoView:Kr},e.stateChangeTypes=ia,e})();process.env.NODE_ENV!=="production"&&(ua.propTypes={children:_.func,defaultHighlightedIndex:_.number,defaultIsOpen:_.bool,initialHighlightedIndex:_.number,initialSelectedItem:_.any,initialInputValue:_.string,initialIsOpen:_.bool,getA11yStatusMessage:_.func,itemToString:_.func,onChange:_.func,onSelect:_.func,onStateChange:_.func,onInputValueChange:_.func,onUserAction:_.func,onOuterClick:_.func,selectedItemChanged:_.func,stateReducer:_.func,itemCount:_.number,id:_.string,environment:_.shape({addEventListener:_.func.isRequired,removeEventListener:_.func.isRequired,document:_.shape({createElement:_.func.isRequired,getElementById:_.func.isRequired,activeElement:_.any.isRequired,body:_.any.isRequired}).isRequired,Node:_.func.isRequired}),suppressRefError:_.bool,scrollIntoView:_.func,selectedItem:_.any,isOpen:_.bool,inputValue:_.string,highlightedIndex:_.number,labelId:_.string,inputId:_.string,menuId:_.string,getItemId:_.func});function Or(e,n){var i=n.refKey;e||console.error('downshift: The ref prop "'+i+'" from getMenuProps was not applied correctly on your menu element.')}function da(e,n){var i=n.refKey,r=i!=="ref",o=!Gr(e);o&&!r&&!Tr.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!o&&r&&console.error('downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "'+i+'"'),!Tr.isForwardRef(e)&&!qr(e)[i]&&console.error('downshift: You must apply the ref prop "'+i+'" from getRootProps onto your root element.')}var fi={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""};function fa(e,n,i){var r=e.props,o=e.type,t={};Object.keys(n).forEach(function(s){pa(s,e,n,i),i[s]!==n[s]&&(t[s]=i[s])}),r.onStateChange&&Object.keys(t).length&&r.onStateChange(ie({type:o},t))}function pa(e,n,i,r){var o=n.props,t=n.type,s="on"+In(e)+"Change";o[s]&&r[e]!==void 0&&r[e]!==i[e]&&o[s](ie({type:t},r))}function ha(e,n){return n.changes}var Sr=Kt(function(e,n){Jr(e,n)},200),ma=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?v.useLayoutEffect:v.useEffect,ga="useId"in v?function(n){var i=n.id,r=n.labelId,o=n.menuId,t=n.getItemId,s=n.toggleButtonId,c=n.inputId,l="downshift-"+v.useId();i||(i=l);var u=v.useRef({labelId:r||i+"-label",menuId:o||i+"-menu",getItemId:t||function(f){return i+"-item-"+f},toggleButtonId:s||i+"-toggle-button",inputId:c||i+"-input"});return u.current}:function(n){var i=n.id,r=i===void 0?"downshift-"+Wr():i,o=n.labelId,t=n.menuId,s=n.getItemId,c=n.toggleButtonId,l=n.inputId,u=v.useRef({labelId:o||r+"-label",menuId:t||r+"-menu",getItemId:s||function(f){return r+"-item-"+f},toggleButtonId:c||r+"-toggle-button",inputId:l||r+"-input"});return u.current};function va(e,n,i,r){var o,t;if(e===void 0){if(n===void 0)throw new Error(r);o=i[n],t=n}else t=n===void 0?i.indexOf(e):n,o=e;return[o,t]}function _a(e){return/^\S{1}$/.test(e)}function In(e){return""+e.slice(0,1).toUpperCase()+e.slice(1)}function pi(e){var n=v.useRef(e);return n.current=e,n}function Ca(e,n,i,r){var o=v.useRef(),t=v.useRef(),s=v.useCallback(function(x,w){t.current=w,x=Vt(x,w.props);var N=e(x,w),E=w.props.stateReducer(x,ie({},w,{changes:N}));return E},[e]),c=v.useReducer(s,n,i),l=c[0],u=c[1],f=pi(n),p=v.useCallback(function(x){return u(ie({props:f.current},x))},[f]),h=t.current;return v.useEffect(function(){var x=Vt(o.current,h?.props),w=h&&o.current&&!r(x,l);w&&fa(h,x,l),o.current=l},[l,h,r]),[l,p]}function Ea(e,n,i,r){var o=Ca(e,n,i,r),t=o[0],s=o[1];return[Vt(t,n),s]}var pt={itemToString:function(n){return n?String(n):""},itemToKey:function(n){return n},stateReducer:ha,scrollIntoView:Kr,environment:typeof window>"u"?void 0:window};function Be(e,n,i){i===void 0&&(i=fi);var r=e["default"+In(n)];return r!==void 0?r:i[n]}function ht(e,n,i){i===void 0&&(i=fi);var r=e[n];if(r!==void 0)return r;var o=e["initial"+In(n)];return o!==void 0?o:Be(e,n,i)}function ya(e){var n=ht(e,"selectedItem"),i=ht(e,"isOpen"),r=wa(e),o=ht(e,"inputValue");return{highlightedIndex:r<0&&n&&i?e.items.findIndex(function(t){return e.itemToKey(t)===e.itemToKey(n)}):r,isOpen:i,selectedItem:n,inputValue:o}}function $t(e,n,i){var r=e.items,o=e.initialHighlightedIndex,t=e.defaultHighlightedIndex,s=e.isItemDisabled,c=e.itemToKey,l=n.selectedItem,u=n.highlightedIndex;return r.length===0?-1:o!==void 0&&u===o&&!s(r[o],o)?o:t!==void 0&&!s(r[t],t)?t:l?r.findIndex(function(f){return c(l)===c(f)}):i<0&&!s(r[r.length-1],r.length-1)?r.length-1:i>0&&!s(r[0],0)?0:-1}function Ta(e,n,i){var r=v.useRef({isMouseDown:!1,isTouchMove:!1,isTouchEnd:!1});return v.useEffect(function(){if(!e)return De;var o=i.map(function(f){return f.current});function t(){r.current.isTouchEnd=!1,r.current.isMouseDown=!0}function s(f){r.current.isMouseDown=!1,Ht(f.target,o,e)||n()}function c(){r.current.isTouchEnd=!1,r.current.isTouchMove=!1}function l(){r.current.isTouchMove=!0}function u(f){r.current.isTouchEnd=!0,!r.current.isTouchMove&&!Ht(f.target,o,e,!1)&&n()}return e.addEventListener("mousedown",t),e.addEventListener("mouseup",s),e.addEventListener("touchstart",c),e.addEventListener("touchmove",l),e.addEventListener("touchend",u),function(){e.removeEventListener("mousedown",t),e.removeEventListener("mouseup",s),e.removeEventListener("touchstart",c),e.removeEventListener("touchmove",l),e.removeEventListener("touchend",u)}},[i,e,n]),r.current}var hi=function(){return De};process.env.NODE_ENV!=="production"&&(hi=function(){for(var n=arguments.length,i=new Array(n),r=0;r<n;r++)i[r]=arguments[r];var o=v.useRef(i.reduce(function(s,c){return s[c]={},s},{}));v.useEffect(function(){Object.keys(o.current).forEach(function(s){var c=o.current[s];if(!Object.keys(c).length){console.error("downshift: You forgot to call the "+s+" getter function on your component / element.");return}var l=c.suppressRefError,u=c.refKey,f=c.elementRef;l||f!=null&&f.current||console.error('downshift: The ref prop "'+u+'" from '+s+" was not applied correctly on your element.")})},[]);var t=v.useCallback(function(s,c,l,u){o.current[s]={suppressRefError:c,refKey:l,elementRef:u}},[]);return t});function xa(e,n,i,r){r===void 0&&(r={});var o=r.document,t=gi();v.useEffect(function(){if(!(!e||t||!o)){var s=e(n);Sr(s,o)}},i),v.useEffect(function(){return function(){Sr.cancel(),ra(o)}},[o])}function ba(e){var n=e.highlightedIndex,i=e.isOpen,r=e.itemRefs,o=e.getItemNodeFromIndex,t=e.menuElement,s=e.scrollIntoView,c=v.useRef(!0);return ma(function(){n<0||!i||!Object.keys(r.current).length||(c.current===!1?c.current=!0:s(o(n),t))},[n]),c}var mi=De;process.env.NODE_ENV!=="production"&&(mi=function(n){var i=n.props,r=n.state,o=v.useRef(i),t=gi();v.useEffect(function(){t||(bn(r,o.current,i),o.current=i)},[r,i,t])});function Dr(e,n,i){var r,o=((r=e.items)==null?void 0:r.length)&&n>=0;return ie({isOpen:!1,highlightedIndex:-1},o&&ie({selectedItem:e.items[n],isOpen:Be(e,"isOpen"),highlightedIndex:Be(e,"highlightedIndex")},i))}function Ia(e,n){return e.isOpen===n.isOpen&&e.inputValue===n.inputValue&&e.highlightedIndex===n.highlightedIndex&&e.selectedItem===n.selectedItem}function gi(){var e=v.useRef(!0);return v.useEffect(function(){return e.current=!1,function(){e.current=!0}},[]),e.current}function vi(e){var n=Be(e,"highlightedIndex");return n>-1&&e.isItemDisabled(e.items[n],n)?-1:n}function wa(e){var n=ht(e,"highlightedIndex");return n>-1&&e.isItemDisabled(e.items[n],n)?-1:n}var Mt={environment:_.shape({addEventListener:_.func.isRequired,removeEventListener:_.func.isRequired,document:_.shape({createElement:_.func.isRequired,getElementById:_.func.isRequired,activeElement:_.any.isRequired,body:_.any.isRequired}).isRequired,Node:_.func.isRequired}),itemToString:_.func,itemToKey:_.func,stateReducer:_.func},_i=ie({},Mt,{getA11yStatusMessage:_.func,highlightedIndex:_.number,defaultHighlightedIndex:_.number,initialHighlightedIndex:_.number,isOpen:_.bool,defaultIsOpen:_.bool,initialIsOpen:_.bool,selectedItem:_.any,initialSelectedItem:_.any,defaultSelectedItem:_.any,id:_.string,labelId:_.string,menuId:_.string,getItemId:_.func,toggleButtonId:_.string,onSelectedItemChange:_.func,onHighlightedIndexChange:_.func,onStateChange:_.func,onIsOpenChange:_.func,scrollIntoView:_.func});function Na(e,n,i){var r=n.type,o=n.props,t;switch(r){case i.ItemMouseMove:t={highlightedIndex:n.disabled?-1:n.index};break;case i.MenuMouseLeave:t={highlightedIndex:-1};break;case i.ToggleButtonClick:case i.FunctionToggleMenu:t={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:$t(o,e,0)};break;case i.FunctionOpenMenu:t={isOpen:!0,highlightedIndex:$t(o,e,0)};break;case i.FunctionCloseMenu:t={isOpen:!1};break;case i.FunctionSetHighlightedIndex:t={highlightedIndex:o.isItemDisabled(o.items[n.highlightedIndex],n.highlightedIndex)?-1:n.highlightedIndex};break;case i.FunctionSetInputValue:t={inputValue:n.inputValue};break;case i.FunctionReset:t={highlightedIndex:vi(o),isOpen:Be(o,"isOpen"),selectedItem:Be(o,"selectedItem"),inputValue:Be(o,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return ie({},e,t)}function Oa(e){for(var n=e.keysSoFar,i=e.highlightedIndex,r=e.items,o=e.itemToString,t=e.isItemDisabled,s=n.toLowerCase(),c=0;c<r.length;c++){var l=(c+i+(n.length<2?1:0))%r.length,u=r[l];if(u!==void 0&&o(u).toLowerCase().startsWith(s)&&!t(u,l))return l}return i}var Sa=it(it({},_i),{items:_.array.isRequired,isItemDisabled:_.func}),Da=it(it({},pt),{isItemDisabled:function(){return!1}}),Ci=De;process.env.NODE_ENV!=="production"&&(Ci=function(e,n){_.checkPropTypes(Sa,e,"prop",n.name)});var kt=process.env.NODE_ENV!=="production"?"__togglebutton_click__":0,wn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_arrow_down__":1,Nn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_arrow_up__":2,Ft=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_character__":3,On=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_escape__":4,Sn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_home__":5,Dn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_end__":6,Pn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_enter__":7,Rn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_space_button__":8,An=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_page_up__":9,Mn=process.env.NODE_ENV!=="production"?"__togglebutton_keydown_page_down__":10,Bt=process.env.NODE_ENV!=="production"?"__togglebutton_blur__":11,Ei=process.env.NODE_ENV!=="production"?"__menu_mouse_leave__":12,yi=process.env.NODE_ENV!=="production"?"__item_mouse_move__":13,kn=process.env.NODE_ENV!=="production"?"__item_click__":14,Ti=process.env.NODE_ENV!=="production"?"__function_toggle_menu__":15,xi=process.env.NODE_ENV!=="production"?"__function_open_menu__":16,bi=process.env.NODE_ENV!=="production"?"__function_close_menu__":17,Ii=process.env.NODE_ENV!=="production"?"__function_set_highlighted_index__":18,jn=process.env.NODE_ENV!=="production"?"__function_select_item__":19,vn=process.env.NODE_ENV!=="production"?"__function_set_input_value__":20,wi=process.env.NODE_ENV!=="production"?"__function_reset__":21,Ni=Object.freeze({__proto__:null,FunctionCloseMenu:bi,FunctionOpenMenu:xi,FunctionReset:wi,FunctionSelectItem:jn,FunctionSetHighlightedIndex:Ii,FunctionSetInputValue:vn,FunctionToggleMenu:Ti,ItemClick:kn,ItemMouseMove:yi,MenuMouseLeave:Ei,ToggleButtonBlur:Bt,ToggleButtonClick:kt,ToggleButtonKeyDownArrowDown:wn,ToggleButtonKeyDownArrowUp:Nn,ToggleButtonKeyDownCharacter:Ft,ToggleButtonKeyDownEnd:Dn,ToggleButtonKeyDownEnter:Pn,ToggleButtonKeyDownEscape:On,ToggleButtonKeyDownHome:Sn,ToggleButtonKeyDownPageDown:Mn,ToggleButtonKeyDownPageUp:An,ToggleButtonKeyDownSpaceButton:Rn});function Pa(e,n){var i,r=n.type,o=n.props,t=n.altKey,s;switch(r){case kn:s={isOpen:Be(o,"isOpen"),highlightedIndex:vi(o),selectedItem:o.items[n.index]};break;case Ft:{var c=n.key,l=""+e.inputValue+c,u=!e.isOpen&&e.selectedItem?o.items.findIndex(function(x){return o.itemToKey(x)===o.itemToKey(e.selectedItem)}):e.highlightedIndex,f=Oa({keysSoFar:l,highlightedIndex:u,items:o.items,itemToString:o.itemToString,isItemDisabled:o.isItemDisabled});s={inputValue:l,highlightedIndex:f,isOpen:!0}}break;case wn:{var p=e.isOpen?Ze(e.highlightedIndex,1,o.items,o.isItemDisabled):t&&e.selectedItem==null?-1:$t(o,e,1);s={highlightedIndex:p,isOpen:!0}}break;case Nn:if(e.isOpen&&t)s=Dr(o,e.highlightedIndex,!1);else{var h=e.isOpen?Ze(e.highlightedIndex,-1,o.items,o.isItemDisabled):$t(o,e,-1);s={highlightedIndex:h,isOpen:!0}}break;case Pn:case Rn:s=Dr(o,e.highlightedIndex,!1);break;case Sn:s={highlightedIndex:ot(0,!1,o.items,o.isItemDisabled),isOpen:!0};break;case Dn:s={highlightedIndex:ot(o.items.length-1,!0,o.items,o.isItemDisabled),isOpen:!0};break;case An:s={highlightedIndex:Ze(e.highlightedIndex,-10,o.items,o.isItemDisabled)};break;case Mn:s={highlightedIndex:Ze(e.highlightedIndex,10,o.items,o.isItemDisabled)};break;case On:s={isOpen:!1,highlightedIndex:-1};break;case Bt:s=ie({isOpen:!1,highlightedIndex:-1},e.highlightedIndex>=0&&((i=o.items)==null?void 0:i.length)&&{selectedItem:o.items[e.highlightedIndex]});break;case jn:s={selectedItem:n.selectedItem};break;default:return Na(e,n,Ni)}return ie({},e,s)}var Ra=["onClick"],Aa=["onMouseLeave","refKey","ref"],Ma=["onBlur","onClick","onPress","onKeyDown","refKey","ref"],ka=["item","index","onMouseMove","onClick","onMouseDown","onPress","refKey","disabled","ref"];Ln.stateChangeTypes=Ni;function Ln(e){e===void 0&&(e={}),Ci(e,Ln);var n=ie({},Da,e),i=n.scrollIntoView,r=n.environment,o=n.getA11yStatusMessage,t=Ea(Pa,n,ya,Ia),s=t[0],c=t[1],l=s.isOpen,u=s.highlightedIndex,f=s.selectedItem,p=s.inputValue,h=v.useRef(null),x=v.useRef(null),w=v.useRef({}),N=v.useRef(null),E=ga(n),k=pi({state:s,props:n}),C=v.useCallback(function(G){return w.current[E.getItemId(G)]},[E]);xa(o,s,[l,u,f,p],r);var y=ba({menuElement:x.current,highlightedIndex:u,isOpen:l,itemRefs:w,scrollIntoView:i,getItemNodeFromIndex:C});v.useEffect(function(){return N.current=Kt(function(G){G({type:vn,inputValue:""})},500),function(){N.current.cancel()}},[]),v.useEffect(function(){p&&N.current(c)},[c,p]),mi({props:n,state:s}),v.useEffect(function(){var G=ht(n,"isOpen");G&&h.current&&h.current.focus()},[]);var T=Ta(r,v.useCallback(function(){k.current.state.isOpen&&c({type:Bt})},[c,k]),v.useMemo(function(){return[x,h]},[x.current,h.current])),m=hi("getMenuProps","getToggleButtonProps");v.useEffect(function(){l||(w.current={})},[l]);var R=v.useMemo(function(){return{ArrowDown:function(A){A.preventDefault(),c({type:wn,altKey:A.altKey})},ArrowUp:function(A){A.preventDefault(),c({type:Nn,altKey:A.altKey})},Home:function(A){A.preventDefault(),c({type:Sn})},End:function(A){A.preventDefault(),c({type:Dn})},Escape:function(){k.current.state.isOpen&&c({type:On})},Enter:function(A){A.preventDefault(),c({type:k.current.state.isOpen?Pn:kt})},PageUp:function(A){k.current.state.isOpen&&(A.preventDefault(),c({type:An}))},PageDown:function(A){k.current.state.isOpen&&(A.preventDefault(),c({type:Mn}))}," ":function(A){A.preventDefault();var g=k.current.state;if(!g.isOpen){c({type:kt});return}g.inputValue?c({type:Ft,key:" "}):c({type:Rn})}}},[c,k]),J=v.useCallback(function(){c({type:Ti})},[c]),F=v.useCallback(function(){c({type:bi})},[c]),Q=v.useCallback(function(){c({type:xi})},[c]),B=v.useCallback(function(G){c({type:Ii,highlightedIndex:G})},[c]),W=v.useCallback(function(G){c({type:jn,selectedItem:G})},[c]),te=v.useCallback(function(){c({type:wi})},[c]),P=v.useCallback(function(G){c({type:vn,inputValue:G})},[c]),D=v.useCallback(function(G){var A=G===void 0?{}:G,g=A.onClick,b=ke(A,Ra),H=function(){var V;(V=h.current)==null||V.focus()};return ie({id:E.labelId,htmlFor:E.toggleButtonId,onClick:Te(g,H)},b)},[E]),re=v.useCallback(function(G,A){var g,b=G===void 0?{}:G,H=b.onMouseLeave,Y=b.refKey,V=Y===void 0?"ref":Y,Z=b.ref,j=ke(b,Aa),$=A===void 0?{}:A,z=$.suppressRefError,ee=z===void 0?!1:z,q=function(){c({type:Ei})};return m("getMenuProps",ee,V,x),ie((g={},g[V]=ft(Z,function(ae){x.current=ae}),g.id=E.menuId,g.role="listbox",g["aria-labelledby"]=j&&j["aria-label"]?void 0:""+E.labelId,g.onMouseLeave=Te(H,q),g),j)},[c,m,E]),ne=v.useCallback(function(G,A){var g,b=G===void 0?{}:G,H=b.onBlur,Y=b.onClick;b.onPress;var V=b.onKeyDown,Z=b.refKey,j=Z===void 0?"ref":Z,$=b.ref,z=ke(b,Ma),ee=A===void 0?{}:A,q=ee.suppressRefError,ae=q===void 0?!1:q,O=k.current.state,me=function(){c({type:kt})},L=function(){O.isOpen&&!T.isMouseDown&&c({type:Bt})},xe=function(Ue){var Pe=mn(Ue);Pe&&R[Pe]?R[Pe](Ue):_a(Pe)&&c({type:Ft,key:Pe})},ge=ie((g={},g[j]=ft($,function(we){h.current=we}),g["aria-activedescendant"]=O.isOpen&&O.highlightedIndex>-1?E.getItemId(O.highlightedIndex):"",g["aria-controls"]=E.menuId,g["aria-expanded"]=k.current.state.isOpen,g["aria-haspopup"]="listbox",g["aria-labelledby"]=z&&z["aria-label"]?void 0:""+E.labelId,g.id=E.toggleButtonId,g.role="combobox",g.tabIndex=0,g.onBlur=Te(H,L),g),z);return z.disabled||(ge.onClick=Te(Y,me),ge.onKeyDown=Te(V,xe)),m("getToggleButtonProps",ae,j,h),ge},[c,E,k,T,m,R]),_e=v.useCallback(function(G){var A,g=G===void 0?{}:G,b=g.item,H=g.index,Y=g.onMouseMove,V=g.onClick,Z=g.onMouseDown;g.onPress;var j=g.refKey,$=j===void 0?"ref":j,z=g.disabled,ee=g.ref,q=ke(g,ka);z!==void 0&&console.warn('Passing "disabled" as an argument to getItemProps is not supported anymore. Please use the isItemDisabled prop from useSelect.');var ae=k.current,O=ae.state,me=ae.props,L=va(b,H,me.items,"Pass either item or index to getItemProps!"),xe=L[0],ge=L[1],we=me.isItemDisabled(xe,ge),Ue=function(){T.isTouchEnd||ge===O.highlightedIndex||(y.current=!1,c({type:yi,index:ge,disabled:we}))},Pe=function(){c({type:kn,index:ge})},qt=function(Zt){return Zt.preventDefault()},Je=ie((A={},A[$]=ft(ee,function(Ve){Ve&&(w.current[E.getItemId(ge)]=Ve)}),A["aria-disabled"]=we,A["aria-selected"]=xe===O.selectedItem,A.id=E.getItemId(ge),A.role="option",A),q);return we||(Je.onClick=Te(V,Pe)),Je.onMouseMove=Te(Y,Ue),Je.onMouseDown=Te(Z,qt),Je},[k,E,T,y,c]);return{getToggleButtonProps:ne,getLabelProps:D,getMenuProps:re,getItemProps:_e,toggleMenu:J,openMenu:Q,closeMenu:F,setHighlightedIndex:B,selectItem:W,reset:te,setInputValue:P,highlightedIndex:u,isOpen:l,selectedItem:f,inputValue:p}}process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;ie({},_i,{items:_.array.isRequired,isItemDisabled:_.func,inputValue:_.string,defaultInputValue:_.string,initialInputValue:_.string,inputId:_.string,onInputValueChange:_.func});process.env.NODE_ENV;ie({},pt,{isItemDisabled:function(){return!1}});Mt.stateReducer,Mt.itemToKey,Mt.environment,_.array,_.array,_.array,_.func,_.number,_.number,_.number,_.func,_.func,_.string,_.string;pt.itemToKey,pt.stateReducer,pt.environment;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;const ja="MultiSelect-module_multiSelect",La="MultiSelect-module_control",Va="MultiSelect-module_disabled",Ha="MultiSelect-module_valueContainer",$a="MultiSelect-module_input",Fa="MultiSelect-module_multiValue",Ba="MultiSelect-module_multiValueLabel",za="MultiSelect-module_multiValueRemove",Ua="MultiSelect-module_dropdownIndicator",Ya="MultiSelect-module_menu",Ka="MultiSelect-module_menuOpen",Wa="MultiSelect-module_menuList",Ga="MultiSelect-module_groupHeading",qa="MultiSelect-module_groupSeparator",Za="MultiSelect-module_option",Ja="MultiSelect-module_optionLast",Xa="MultiSelect-module_optionSelected",Qa="MultiSelect-module_optionFocused",ec="MultiSelect-module_optionDisabled",tc="MultiSelect-module_optionLabel",nc="MultiSelect-module_noOptions",pe={multiSelect:ja,control:La,disabled:Va,valueContainer:Ha,input:$a,multiValue:Fa,multiValueLabel:Ba,multiValueRemove:za,dropdownIndicator:Ua,menu:Ya,menuOpen:Ka,menuList:Wa,groupHeading:Ga,groupSeparator:qa,option:Za,optionLast:Ja,optionSelected:Xa,optionFocused:Qa,optionDisabled:ec,optionLabel:tc,noOptions:nc},rc=({id:e,name:n,options:i,value:r=[],preferredValues:o=[],placeholder:t="Select...",disabled:s=!1,className:c,onChange:l})=>{const[u,f]=v.useState(!1),[p,h]=v.useState(""),x=v.useRef(null),w=v.useRef(null),N=v.useMemo(()=>new Set(o),[o]),E=v.useMemo(()=>{const P=i.filter(ne=>ne.label.toLowerCase().includes(p.toLowerCase())),D=P.filter(ne=>N.has(ne.value)),re=P.filter(ne=>!N.has(ne.value));return{preferred:D,others:re}},[i,p,N]),k=v.useMemo(()=>i.filter(P=>r.includes(P.value)),[i,r]),{isOpen:C,getToggleButtonProps:y,getMenuProps:T,getItemProps:m,highlightedIndex:R}=Ln({items:[...E.preferred,...E.others],selectedItem:null,onSelectedItemChange:({selectedItem:P})=>{if(P){const D=P.value,re=r.includes(D)?r.filter(ne=>ne!==D):[...r,D];l?.(re)}}});v.useEffect(()=>{f(C)},[C]),v.useEffect(()=>{const P=D=>{w.current&&!w.current.contains(D.target)&&(f(!1),h(""))};return u&&document.addEventListener("mousedown",P),()=>{document.removeEventListener("mousedown",P)}},[u]);const J=P=>{h(P.target.value)},F=P=>{P.key==="Escape"&&(f(!1),h(""),x.current?.blur())},Q=P=>{P.stopPropagation(),P.preventDefault()},B=P=>{P.stopPropagation()},W=P=>{const D=r.filter(re=>re!==P);l?.(D)},te=()=>{s||f(!u)};return a.jsxs("div",{ref:w,className:`${pe.multiSelect} ${c??""}`,children:[a.jsxs("div",{className:`${pe.control} ${s?pe.disabled:""}`,children:[a.jsxs("div",{className:pe.valueContainer,children:[k.map(P=>a.jsxs("div",{className:pe.multiValue,children:[a.jsx("span",{className:pe.multiValueLabel,children:P.label}),a.jsx("button",{type:"button",className:pe.multiValueRemove,onClick:()=>W(P.value),disabled:s,children:"×"})]},P.value)),a.jsx("input",{ref:x,id:e,name:n,className:pe.input,value:p,onChange:J,onKeyDown:F,onFocus:()=>!s&&f(!0),placeholder:k.length===0?t:"",disabled:s,autoComplete:"off"})]}),a.jsx("button",{type:"button",className:pe.dropdownIndicator,onClick:te,disabled:s,...y(),children:a.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:a.jsx("polyline",{points:"6,9 12,15 18,9"})})})]}),a.jsx("div",{className:`${pe.menu} ${u?pe.menuOpen:""}`,...T(),onClick:Q,onMouseDown:B,children:a.jsxs("div",{className:pe.menuList,children:[E.preferred.length>0&&a.jsxs(a.Fragment,{children:[a.jsx("div",{className:pe.groupHeading,children:"Preferred"}),E.preferred.map((P,D)=>{const ne=D===E.preferred.length-1&&E.others.length===0;return a.jsx("div",{className:`${pe.option} ${R===D?pe.optionFocused:""} ${r.includes(P.value)?pe.optionSelected:""} ${P.disabled?pe.optionDisabled:""} ${ne?pe.optionLast:""}`,onClick:Q,...m({item:P,index:D,disabled:P.disabled}),children:a.jsx("span",{className:pe.optionLabel,children:P.label})},P.value)})]}),E.others.length>0&&a.jsxs(a.Fragment,{children:[E.preferred.length>0&&a.jsxs(a.Fragment,{children:[a.jsx("div",{className:pe.groupSeparator}),a.jsx("div",{className:pe.groupHeading,children:"All"})]}),E.others.map((P,D)=>{const re=E.preferred.length+D,ne=D===E.others.length-1;return a.jsx("div",{className:`${pe.option} ${R===re?pe.optionFocused:""} ${r.includes(P.value)?pe.optionSelected:""} ${P.disabled?pe.optionDisabled:""} ${ne?pe.optionLast:""}`,onClick:Q,...m({item:P,index:re,disabled:P.disabled}),children:a.jsx("span",{className:pe.optionLabel,children:P.label})},P.value)})]}),E.preferred.length===0&&E.others.length===0&&a.jsx("div",{className:pe.noOptions,children:"No options found"})]})})]})},ic="SelectField-module_selectField",oc="SelectField-module_select",Pr={selectField:ic,select:oc},sc=({id:e,name:n,value:i,options:r=[],placeholder:o="Select an option",disabled:t=!1,className:s="",onChange:c,onBlur:l,onFocus:u})=>{const f=p=>{const h=p.target.value,x=r.find(w=>w.value.toString()===h);x&&c&&c(x.value)};return a.jsx("div",{className:`${Pr.selectField} ${s}`,children:a.jsxs("select",{id:e,name:n,value:i||"",disabled:t,onChange:f,onBlur:l,onFocus:u,className:Pr.select,children:[o&&a.jsx("option",{value:"",disabled:!0,children:o}),r.map((p,h)=>a.jsx("option",{value:p.value,disabled:p.disabled,children:p.label},`${h}`))]})})},Rr="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M353.286,163.919c16.464,0,29.815,13.351,29.815,29.822%20c0,16.467-13.351,29.819-29.815,29.819c-16.47,0-29.822-13.352-29.822-29.819C323.464,177.27,336.816,163.919,353.286,163.919%20L353.286,163.919z%20M245.838,163.919c16.47,0,29.822,13.351,29.822,29.822c0,16.467-13.352,29.819-29.822,29.819%20c-16.471,0-29.822-13.352-29.822-29.819C216.016,177.27,229.367,163.919,245.838,163.919L245.838,163.919z%20M354.093,338.178%20c22.575,0,40.874,18.299,40.874,40.87c0,22.571-18.299,40.87-40.874,40.87c-22.568,0-40.867-18.299-40.867-40.87%20C313.226,356.477,331.525,338.178,354.093,338.178L354.093,338.178z%20M245.024,338.178c22.575,0,40.874,18.299,40.874,40.87%20c0,22.571-18.299,40.87-40.874,40.87c-22.568,0-40.874-18.299-40.874-40.87C204.151,356.477,222.457,338.178,245.024,338.178%20L245.024,338.178z%20M406.906,244.769c22.575,0,40.874,18.299,40.874,40.87s-18.299,40.87-40.874,40.87%20c-22.568,0-40.867-18.299-40.867-40.87S384.338,244.769,406.906,244.769L406.906,244.769z%20M192.211,244.769%20c22.568,0,40.874,18.299,40.874,40.87s-18.306,40.87-40.874,40.87c-22.575,0-40.874-18.299-40.874-40.87%20S169.636,244.769,192.211,244.769L192.211,244.769z%20M299.559,244.769c22.575,0,40.874,18.299,40.874,40.87%20s-18.299,40.87-40.874,40.87c-22.569,0-40.868-18.299-40.868-40.87S276.99,244.769,299.559,244.769L299.559,244.769z%20M452.99,131.334H146.127c-32.625,37.291-50.332,84.551-50.332,134.107c0,112.541,91.226,203.765,203.764,203.765%20c112.544,0,203.764-91.223,203.764-203.765C503.323,215.889,485.608,168.622,452.99,131.334L452.99,131.334z%20M471.276,105.109%20l-4.672-4.998h-334.09l-4.672,4.998c-40.739,43.6-63.267,100.662-63.267,160.332c0,129.775,105.21,234.988,234.984,234.988%20c129.774,0,234.984-105.213,234.984-234.988C534.542,205.771,512.015,148.709,471.276,105.109L471.276,105.109z%20M480.204,60.027%20H118.914C61.952,110.158,26,183.596,26,265.441C26,416.523,148.48,539,299.559,539c151.085,0,273.558-122.477,273.558-273.559%20C573.117,183.596,537.165,110.158,480.204,60.027z'/%3e%3c/svg%3e",Ar="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M228.887,396.793c20.779,0,37.62,16.841,37.62,37.617%20c0,20.773-16.841,37.617-37.62,37.617c-20.773,0-37.613-16.844-37.613-37.617C191.274,413.634,208.115,396.793,228.887,396.793%20L228.887,396.793z%20M366.03,396.793c20.773,0,37.614,16.841,37.614,37.617c0,20.773-16.841,37.617-37.614,37.617%20c-20.779,0-37.62-16.844-37.62-37.617C328.41,413.634,345.251,396.793,366.03,396.793L366.03,396.793z%20M228.375,325.684%20c-29.03,0-55.41,11.868-74.52,30.976c-41.566,41.573-41.566,113.923,0,155.497c19.111,19.111,45.49,30.979,74.52,30.979h138.168%20c29.023,0,55.41-11.868,74.521-30.979c41.565-41.566,41.565-113.928,0-155.497c-18.336-18.336-43.379-30.003-71.019-30.916%20c63.723-27.868,105.151-90.836,105.151-160.733c0-42.14-13.276-74.632-37.316-108.359H161.794%20c-24.033,33.747-37.309,66.2-37.309,108.359c0,69.852,41.359,132.758,105.012,160.674H228.375L228.375,325.684z%20M366.543,357.791%20H228.375c-20.163,0-38.513,8.265-51.824,21.569c-29.023,29.027-29.023,81.069,0,110.096c13.311,13.308,31.654,21.569,51.824,21.569%20h138.168c20.17,0,38.513-8.261,51.824-21.569c29.023-29.027,29.023-81.069,0-110.096%20C405.056,366.057,386.706,357.791,366.543,357.791L366.543,357.791z%20M421.17,88.762c14.523,23.018,21.915,49.024,21.915,76.248%20c0,79.121-64.131,143.245-143.248,143.245S156.595,244.127,156.595,165.01c0-27.234,7.392-53.222,21.915-76.248H421.17%20L421.17,88.762z%20M331.075,225.95c11.726,0,21.236,9.511,21.236,21.236c0,11.733-9.511,21.24-21.236,21.24%20c-11.733,0-21.236-9.507-21.236-21.24C309.839,235.461,319.342,225.95,331.075,225.95L331.075,225.95z%20M268.605,225.95%20c11.726,0,21.243,9.511,21.243,21.236c0,11.733-9.518,21.24-21.243,21.24c-11.726,0-21.236-9.507-21.236-21.24%20C247.369,235.461,256.879,225.95,268.605,225.95L268.605,225.95z%20M236.882,163.754c11.726,0,21.243,9.508,21.243,21.236%20c0,11.729-9.518,21.24-21.243,21.24c-11.726,0-21.236-9.511-21.236-21.24C215.646,173.261,225.156,163.754,236.882,163.754%20L236.882,163.754z%20M299.837,163.754c11.732,0,21.243,9.508,21.243,21.236c0,11.729-9.511,21.24-21.243,21.24%20c-11.726,0-21.236-9.511-21.236-21.24C278.6,173.261,288.111,163.754,299.837,163.754L299.837,163.754z%20M362.798,163.754%20c11.726,0,21.236,9.508,21.236,21.236c0,11.729-9.511,21.24-21.236,21.24c-11.733,0-21.236-9.511-21.236-21.24%20C341.562,173.261,351.065,163.754,362.798,163.754L362.798,163.754z%20M332.079,116.228c6.86,0,12.417,5.561,12.417,12.417%20c0,6.86-5.558,12.425-12.417,12.425s-12.424-5.566-12.424-12.425C319.654,121.79,325.219,116.228,332.079,116.228L332.079,116.228z%20M267.601,116.228c6.86,0,12.425,5.561,12.425,12.417c0,6.86-5.565,12.425-12.425,12.425c-6.86,0-12.417-5.566-12.417-12.425%20C255.184,121.79,260.742,116.228,267.601,116.228L267.601,116.228z%20M177.153,7.87C129.219,7.87,90,47.086,90,95.02v408.83%20c0,47.934,39.219,87.15,87.153,87.15h246.024c47.934,0,87.147-39.216,87.147-87.15V95.02c0-47.934-39.213-87.15-87.147-87.15%20H177.153z'/%3e%3c/svg%3e",Mr="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M407.111,334.214c16.317,0,29.543,13.226,29.543,29.543%20c0,16.313-13.227,29.543-29.543,29.543c-16.31,0-29.536-13.229-29.536-29.543C377.576,347.44,390.802,334.214,407.111,334.214%20L407.111,334.214z%20M198.69,334.214c16.317,0,29.543,13.226,29.543,29.543c0,16.313-13.226,29.543-29.543,29.543%20s-29.543-13.229-29.543-29.543C169.147,347.44,182.373,334.214,198.69,334.214L198.69,334.214z%20M227.94,180.772%20c24.971,0,45.213,20.242,45.213,45.213c0,24.967-20.243,45.213-45.213,45.213s-45.213-20.245-45.213-45.213%20C182.727,201.014,202.969,180.772,227.94,180.772L227.94,180.772z%20M377.868,180.772c24.968,0,45.213,20.242,45.213,45.213%20c0,24.967-20.245,45.213-45.213,45.213c-24.974,0-45.213-20.245-45.213-45.213C332.655,201.014,352.894,180.772,377.868,180.772%20L377.868,180.772z%20M302.899,361.142c24.974,0,45.22,20.243,45.22,45.213s-20.245,45.213-45.22,45.213%20c-24.968,0-45.21-20.243-45.21-45.213S277.931,361.142,302.899,361.142L302.899,361.142z%20M302.899,100.142%20c-111.485,0-201.855,90.37-201.855,201.858c0,111.489,90.37,201.859,201.855,201.859c111.491,0,201.865-90.37,201.865-201.859%20C504.764,190.512,414.391,100.142,302.899,100.142L302.899,100.142z%20M302.899,69.21C174.338,69.21,70.113,173.44,70.113,302%20c0,128.561,104.226,232.79,232.787,232.79c128.56,0,232.793-104.229,232.793-232.79C535.692,173.44,431.459,69.21,302.899,69.21%20L302.899,69.21z%20M302.899,31C153.234,31,31.902,152.328,31.902,302c0,149.669,121.331,271,270.997,271%20c149.672,0,271.006-121.331,271.006-271C573.906,152.328,452.571,31,302.899,31z'/%3e%3c/svg%3e",kr="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M246.063,132.777c18.959,0,34.335,15.373,34.335,34.332%20c0,18.965-15.376,34.335-34.335,34.335c-18.961,0-34.332-15.37-34.332-34.335C211.731,148.15,227.102,132.777,246.063,132.777%20L246.063,132.777z%20M357.555,132.777c18.962,0,34.332,15.373,34.332,34.332c0,18.962-15.37,34.335-34.332,34.335%20c-18.961,0-34.331-15.373-34.331-34.335C323.224,148.15,338.594,132.777,357.555,132.777L357.555,132.777z%20M226.875,253.708%20c9.286,0,16.811,7.525,16.811,16.808c0,9.286-7.525,16.811-16.811,16.811c-9.283,0-16.808-7.525-16.808-16.811%20C210.066,261.234,217.592,253.708,226.875,253.708L226.875,253.708z%20M371.359,253.708c9.286,0,16.815,7.525,16.815,16.808%20c0,9.286-7.529,16.811-16.815,16.811c-9.279,0-16.808-7.525-16.808-16.811C354.552,261.234,362.08,253.708,371.359,253.708%20L371.359,253.708z%20M236.304,421.639c19.179,0,34.731,15.548,34.731,34.731c0,19.179-15.552,34.731-34.731,34.731%20c-19.179,0-34.731-15.552-34.731-34.731C201.573,437.187,217.126,421.639,236.304,421.639L236.304,421.639z%20M362.924,421.639%20c19.179,0,34.728,15.548,34.728,34.731c0,19.179-15.549,34.731-34.728,34.731c-19.186,0-34.735-15.552-34.735-34.731%20C328.189,437.187,343.738,421.639,362.924,421.639L362.924,421.639z%20M235.828,355.985c-26.801,0-51.159,10.958-68.804,28.6%20c-38.377,38.383-38.377,105.184,0,143.567c17.645,17.645,42.004,28.602,68.804,28.602h127.568c26.803,0,51.159-10.957,68.804-28.602%20c38.377-38.377,38.377-105.19,0-143.567c-16.91-16.91-39.994-27.679-65.481-28.542c57.148-25.011,97.033-82.036,97.033-148.405%20c0-88.133-70.984-161.938-161.945-161.938c-90.131,0-161.935,73.009-161.935,161.938c0,66.315,39.821,123.302,96.895,148.348%20H235.828L235.828,355.985z%20M159.969,344.666c-6.378,4.464-12.357,9.488-17.866,14.999c-52.137,52.134-52.137,141.271-0.003,193.407%20C167.008,577.982,200.589,592,235.828,592h127.568c35.24,0,68.823-14.018,93.729-38.927c52.137-52.134,52.137-141.276,0-193.41%20c-4.761-4.761-9.874-9.155-15.287-13.143c36.523-36.834,57.159-86.685,57.159-138.883c0-108.993-88.188-197.184-197.19-197.184%20c-108.977,0-197.181,88.207-197.181,197.184C104.627,258.933,124.557,307.996,159.969,344.666L159.969,344.666z%20M363.396,385.629%20H235.828c-18.617,0-35.559,7.631-47.846,19.914c-26.797,26.8-26.797,74.85,0,101.65c12.287,12.286,29.225,19.914,47.846,19.914%20h127.568c18.623,0,35.559-7.628,47.849-19.914c26.797-26.8,26.797-74.85,0-101.65C398.955,393.259,382.013,385.629,363.396,385.629%20L363.396,385.629z%20M301.808,75.381c-73.808,0-132.256,59.869-132.256,132.256c0,72.383,58.448,132.256,132.256,132.256%20c73.815,0,132.265-59.87,132.265-132.256C434.073,135.248,375.622,75.381,301.808,75.381L301.808,75.381z%20M301.808,271.807%20c13.689,0,24.784,11.098,24.784,24.781c0,13.686-11.094,24.78-24.784,24.78c-13.686,0-24.777-11.094-24.777-24.78%20C277.03,282.905,288.122,271.807,301.808,271.807z'/%3e%3c/svg%3e",St="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M460.592,75.695C501.794,116.897,525,172.38,525,230.692v136.191%20c0,58.315-23.206,113.795-64.408,154.997c-86.029,86.032-228.158,86.032-314.186,0C105.203,480.679,82,425.199,82,366.884V230.692%20c0-58.312,23.203-113.795,64.405-154.997C232.433-10.337,374.563-10.337,460.592,75.695L460.592,75.695z%20M434.493,101.794%20c-71.625-71.628-190.365-71.628-261.989,0c-33.068,33.068-53.597,78.696-53.597,128.898v136.191%20c0,50.205,20.529,95.834,53.597,128.898c71.624,71.628,190.364,71.628,261.989,0c33.067-33.064,53.596-78.693,53.596-128.898%20V230.692C488.089,180.49,467.56,134.862,434.493,101.794L434.493,101.794z%20M195.699,124.99%20c-27.134,27.137-43.982,64.557-43.982,105.702v136.191c0,41.146,16.848,78.568,43.982,105.702%20c58.806,58.814,156.791,58.814,215.598,0c27.138-27.134,43.982-64.557,43.982-105.702V230.692%20c0-41.146-16.845-78.566-43.982-105.702C352.491,66.18,254.506,66.18,195.699,124.99L195.699,124.99z%20M303.497,401.594%20c-17.304,0-31.334,14.029-31.334,31.337c0,17.304,14.03,31.333,31.334,31.333c17.307,0,31.337-14.029,31.337-31.333%20C334.834,415.623,320.804,401.594,303.497,401.594L303.497,401.594z%20M223.204,305.993c-17.308,0-31.338,14.03-31.338,31.334%20c0,17.308,14.03,31.337,31.338,31.337c17.307,0,31.337-14.029,31.337-31.337C254.541,320.023,240.511,305.993,223.204,305.993%20L223.204,305.993z%20M223.204,208.881c-17.308,0-31.338,14.026-31.338,31.334c0,17.307,14.03,31.337,31.338,31.337%20c17.307,0,31.337-14.03,31.337-31.337C254.541,222.907,240.511,208.881,223.204,208.881L223.204,208.881z%20M383.796,305.993%20c-17.308,0-31.338,14.03-31.338,31.334c0,17.308,14.03,31.337,31.338,31.337c17.307,0,31.333-14.029,31.333-31.337%20C415.129,320.023,401.103,305.993,383.796,305.993L383.796,305.993z%20M383.796,208.881c-17.308,0-31.338,14.026-31.338,31.334%20c0,17.307,14.03,31.337,31.338,31.337c17.307,0,31.333-14.03,31.333-31.337C415.129,222.907,401.103,208.881,383.796,208.881%20L383.796,208.881z%20M354.769,129.256c-12.585,0-22.786,10.201-22.786,22.786s10.2,22.786,22.786,22.786%20c12.585,0,22.786-10.201,22.786-22.786S367.354,129.256,354.769,129.256L354.769,129.256z%20M252.228,129.256%20c-12.585,0-22.786,10.201-22.786,22.786s10.2,22.786,22.786,22.786c12.585,0,22.786-10.201,22.786-22.786%20S264.813,129.256,252.228,129.256z'/%3e%3c/svg%3e",jr="data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M17%2012.8108C17%2013.1901%2016.898%2013.5661%2016.6687%2013.8682C15.2357%2015.7558%2012.784%2017%2010%2017C7.21614%2017%204.76431%2015.7557%203.33134%2013.8681C3.10199%2013.566%203%2013.1901%203%2012.8108V7.18924C3%206.80993%203.10199%206.43401%203.33134%206.13189C4.76431%204.24428%207.21614%203%2010%203C12.784%203%2015.2357%204.24423%2016.6687%206.13183C16.898%206.43395%2017%206.80986%2017%207.18918V12.8108ZM10%207C10.5522%207%2011%206.55231%2011%206C11%205.44769%2010.5522%205%2010%205C9.44775%205%209%205.44769%209%206C9%206.55231%209.44775%207%2010%207ZM6.5%2011.5C7.32837%2011.5%208%2010.8284%208%2010C8%209.17157%207.32837%208.5%206.5%208.5C5.67163%208.5%205%209.17157%205%2010C5%2010.8284%205.67163%2011.5%206.5%2011.5ZM11.5%2013.5C11.5%2014.3284%2010.8284%2015%2010%2015C9.17163%2015%208.5%2014.3284%208.5%2013.5C8.5%2012.6716%209.17163%2012%2010%2012C10.8284%2012%2011.5%2012.6716%2011.5%2013.5ZM13.5%2011.5C14.3284%2011.5%2015%2010.8284%2015%2010C15%209.17157%2014.3284%208.5%2013.5%208.5C12.6716%208.5%2012%209.17157%2012%2010C12%2010.8284%2012.6716%2011.5%2013.5%2011.5Z'%20fill='currentColor'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M10%201C13.8106%201%2017.1182%202.95715%2018.7732%205.82595C18.9298%206.09752%2019%206.40872%2019%206.72224V13.2778C19%2013.5913%2018.9298%2013.9025%2018.7732%2014.1741C17.1182%2017.0429%2013.8106%2019%2010%2019C6.18943%2019%202.88177%2017.0429%201.22682%2014.1741C1.07016%2013.9025%201%2013.5913%201%2013.2778V6.72224C1%206.40872%201.07016%206.09752%201.22682%205.82595C2.88177%202.95715%206.18943%201%2010%201ZM17.6711%205.64554C17.8973%205.95002%2018%206.32536%2018%206.70467V13.2953C18%2013.6746%2017.8973%2014.05%2017.6711%2014.3545C16.0408%2016.5488%2013.214%2018%2010%2018C6.78594%2018%203.95915%2016.5488%202.32887%2014.3544C2.10268%2014.0499%202%2013.6746%202%2013.2953V6.70472C2%206.32542%202.10268%205.95008%202.32887%205.64561C3.95915%203.45116%206.78594%202%2010%202C13.214%202%2016.0408%203.45116%2017.6711%205.64554Z'%20fill='currentColor'/%3e%3c/svg%3e",U="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M395.264,259.724c21.074,0,38.157,17.083,38.157,38.158%20c0,21.074-17.083,38.164-38.157,38.164c-21.075,0-38.165-17.09-38.165-38.164C357.099,276.806,374.189,259.724,395.264,259.724%20L395.264,259.724z%20M206.743,259.724c21.075,0,38.158,17.083,38.158,38.158c0,21.074-17.083,38.164-38.158,38.164%20c-21.074,0-38.164-17.09-38.164-38.164C168.579,276.806,185.669,259.724,206.743,259.724L206.743,259.724z%20M317.092,89.755v29.841%20h-32.183V89.755c-67.083,5.031-127.459,41.741-163.107,98.796v223.399c35.648,57.055,96.024,93.765,163.107,98.802v-29.841h32.183%20v29.841c67.084-5.038,127.459-41.747,163.114-98.802V188.551C444.551,131.496,384.176,94.787,317.092,89.755L317.092,89.755z%20M301,56.962c-85.858,0-165.124,45.192-209.061,118.921l-2.328,3.902v90.784H58.612v59.364h30.999v90.784l2.328,3.902%20C135.876,498.348,215.143,543.539,301,543.539c85.857,0,165.123-45.184,209.06-118.921l2.328-3.902v-90.784h31.006v-59.364h-31.006%20v-90.784l-2.328-3.902C466.124,102.147,386.857,56.962,301,56.962L301,56.962z%20M301,18.251c-155.741,0-282,126.253-282,282%20c0,155.741,126.26,282,282,282c155.747,0,282-126.26,282-282C583,144.504,456.747,18.251,301,18.251z'/%3e%3c/svg%3e",Ae="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M261.067,178.239c0,7.551,2.198,14.579,5.985,20.491l20.49-20.491%20l-20.49-20.491C263.265,163.659,261.067,170.694,261.067,178.239L261.067,178.239z%20M298.999,216.171%20c-7.545,0-14.58-2.198-20.488-5.981l20.488-20.491l20.491,20.491C313.581,213.972,306.55,216.171,298.999,216.171L298.999,216.171z%20M336.934,178.239c0-7.545-2.198-14.58-5.985-20.491l-20.491,20.491l20.491,20.491C334.736,192.818,336.934,185.79,336.934,178.239%20L336.934,178.239z%20M319.49,146.295l-20.491,20.484l-20.488-20.484c5.907-3.79,12.943-5.988,20.488-5.988%20C306.55,140.307,313.581,142.505,319.49,146.295L319.49,146.295z%20M298.999,124.101c29.864,0,54.141,24.281,54.141,54.138%20c0,29.864-24.277,54.145-54.141,54.145c-29.858,0-54.138-24.281-54.138-54.145C244.861,148.382,269.141,124.101,298.999,124.101%20L298.999,124.101z%20M261.067,417.863c0,7.551,2.198,14.579,5.985,20.491l20.49-20.491l-20.49-20.491%20C263.265,403.283,261.067,410.319,261.067,417.863L261.067,417.863z%20M298.999,455.795c-7.545,0-14.58-2.198-20.488-5.981%20l20.488-20.491l20.491,20.491C313.581,453.597,306.55,455.795,298.999,455.795L298.999,455.795z%20M336.934,417.863%20c0-7.545-2.198-14.58-5.985-20.491l-20.491,20.491l20.491,20.491C334.736,432.443,336.934,425.415,336.934,417.863L336.934,417.863z%20M319.49,385.92l-20.491,20.484l-20.488-20.484c5.907-3.79,12.943-5.988,20.488-5.988C306.55,379.931,313.581,382.13,319.49,385.92%20L319.49,385.92z%20M298.999,363.725c29.864,0,54.141,24.281,54.141,54.138c0,29.864-24.277,54.145-54.141,54.145%20c-29.858,0-54.138-24.281-54.138-54.145C244.861,388.007,269.141,363.725,298.999,363.725L298.999,363.725z%20M180.188,239.928%20c30.094,0,54.49,24.4,54.49,54.494c0,30.095-24.396,54.494-54.49,54.494c-30.095,0-54.494-24.399-54.494-54.494%20C125.694,264.327,150.093,239.928,180.188,239.928L180.188,239.928z%20M417.816,239.928c30.094,0,54.494,24.4,54.494,54.494%20c0,30.095-24.4,54.494-54.494,54.494c-30.095,0-54.494-24.399-54.494-54.494C363.323,264.327,387.722,239.928,417.816,239.928%20L417.816,239.928z%20M298.999,86.511c116.835,0,211.544,94.708,211.544,211.54c0,116.84-94.708,211.54-211.544,211.54%20c-116.836,0-211.54-94.708-211.54-211.54C87.458,181.219,182.163,86.511,298.999,86.511L298.999,86.511z%20M298.999,54.1%20c134.73,0,243.955,109.225,243.955,243.951c0,134.727-109.225,243.952-243.955,243.952c-134.727,0-243.952-109.225-243.952-243.952%20C55.047,163.324,164.271,54.1,298.999,54.1L298.999,54.1z%20M298.999,14.053C455.846,14.053,583,141.2,583,298.051%20c0,156.844-127.154,283.999-284.001,283.999C142.151,582.049,15,454.895,15,298.051C15,141.2,142.151,14.053,298.999,14.053z'/%3e%3c/svg%3e",tt="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2022.0.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20id='Layer_1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20600%20600'%20enable-background='new%200%200%20600%20600'%20xml:space='preserve'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20fill='currentColor'%20d='M449.833,45.125C531.521,95.36,586,185.558,586,288.497%20c0,157.672-127.825,285.497-285.503,285.497C142.822,573.994,15,446.169,15,288.497C15,185.558,69.476,95.36,151.167,45.125H449.833%20L449.833,45.125z%20M193.639,256.195c-29.46,0-53.343,23.89-53.343,53.35c0,29.46,23.882,53.343,53.343,53.343%20c29.46,0,53.346-23.882,53.346-53.343C246.985,280.085,223.099,256.195,193.639,256.195L193.639,256.195z%20M407.365,256.195%20c-29.46,0-53.35,23.89-53.35,53.35c0,29.46,23.89,53.343,53.35,53.343c29.46,0,53.343-23.882,53.343-53.343%20C460.708,280.085,436.826,256.195,407.365,256.195L407.365,256.195z%20M442.248,88.407l-4.308-3.053H163.052l-4.304,3.053%20c-64.954,46.088-103.49,120.43-103.49,200.09c0,135.438,109.801,245.239,245.239,245.239c135.437,0,245.245-109.801,245.245-245.239%20C545.742,208.837,507.203,134.495,442.248,88.407L442.248,88.407z%20M427.607,117.937H173.391%20c-54.002,40.321-85.547,103.142-85.547,170.56c0,117.449,95.204,212.656,212.653,212.656c117.455,0,212.663-95.207,212.663-212.656%20C513.16,221.08,481.609,158.258,427.607,117.937L427.607,117.937z%20M300.497,215.65c-11.384,0-20.614,9.226-20.614,20.613%20c0,11.387,9.23,20.614,20.614,20.614c11.387,0,20.62-9.226,20.62-20.614C321.117,224.876,311.883,215.65,300.497,215.65%20L300.497,215.65z%20M300.497,146.275c-11.384,0-20.614,9.226-20.614,20.614c0,11.387,9.23,20.62,20.614,20.62%20c11.387,0,20.62-9.233,20.62-20.62C321.117,155.501,311.883,146.275,300.497,146.275L300.497,146.275z%20M381.735,146.275%20c-11.387,0-20.613,9.226-20.613,20.614c0,11.387,9.226,20.62,20.613,20.62c11.387,0,20.613-9.233,20.613-20.62%20C402.348,155.501,393.122,146.275,381.735,146.275L381.735,146.275z%20M219.265,146.275c-11.387,0-20.616,9.226-20.616,20.614%20c0,11.387,9.23,20.62,20.616,20.62c11.387,0,20.617-9.233,20.617-20.62C239.882,155.501,230.652,146.275,219.265,146.275%20L219.265,146.275z%20M300.497,400.094c-18.881,0-34.186,15.309-34.186,34.189c0,18.887,15.305,34.189,34.186,34.189%20c18.887,0,34.189-15.302,34.189-34.189C334.686,415.403,319.384,400.094,300.497,400.094L300.497,400.094z%20M381.735,417.199%20c-11.387,0-20.613,9.233-20.613,20.62c0,11.38,9.226,20.614,20.613,20.614c11.387,0,20.613-9.233,20.613-20.614%20C402.348,426.433,393.122,417.199,381.735,417.199L381.735,417.199z%20M219.265,417.199c-11.387,0-20.616,9.233-20.616,20.62%20c0,11.38,9.23,20.614,20.616,20.614c11.387,0,20.617-9.233,20.617-20.614C239.882,426.433,230.652,417.199,219.265,417.199z'/%3e%3c/svg%3e",Ge={IEC_62196_T1:Mr,IEC_62196_T1_COMBO:kr,IEC_62196_T2:Rr,IEC_62196_T2_COMBO:Ar,IEC_62196_T3:St,IEC_62196_T3A:jr,IEC_62196_T3B:St,IEC_62196_T3C:St,CHADEMO:Ae,CHAOJI:Ae,CATARC:tt,GBT_AC:tt,GBT_DC:tt,SCHUKO:U,DOMESTIC_A:U,DOMESTIC_B:U,DOMESTIC_C:U,DOMESTIC_D:U,DOMESTIC_E:U,DOMESTIC_F:U,DOMESTIC_G:U,DOMESTIC_H:U,DOMESTIC_I:U,DOMESTIC_J:U,DOMESTIC_K:U,DOMESTIC_L:U,DOMESTIC_M:U,DOMESTIC_N:U,DOMESTIC_O:U,IEC_60309_2_SINGLE_16:U,IEC_60309_2_THREE_16:U,IEC_60309_2_THREE_32:U,IEC_60309_2_THREE_64:U,NEMA_5_20:U,NEMA_6_30:U,NEMA_6_50:U,NEMA_10_30:U,NEMA_10_50:U,NEMA_14_30:U,NEMA_14_50:U,PANTOGRAPH_BOTTOM_UP:Ae,PANTOGRAPH_TOP_DOWN:Ae,TESLA_R:Ae,TESLA_S:Ae,CONNECTOR_STANDARD_TYPE_CHADEMO:Ae,CONNECTOR_STANDARD_TYPE_CHAOJI:Ae,CONNECTOR_STANDARD_TYPE_CATARC:tt,CONNECTOR_STANDARD_TYPE_SCHUKO:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_A:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_B:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_C:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_D:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_E:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_F:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_G:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_H:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_I:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_J:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_K:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_L:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_M:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_N:U,CONNECTOR_STANDARD_TYPE_DOMESTIC_O:U,CONNECTOR_STANDARD_TYPE_GBT_AC:tt,CONNECTOR_STANDARD_TYPE_GBT_DC:tt,CONNECTOR_STANDARD_TYPE_IEC_60309_2_SINGLE_16:U,CONNECTOR_STANDARD_TYPE_IEC_60309_2_THREE_16:U,CONNECTOR_STANDARD_TYPE_IEC_60309_2_THREE_32:U,CONNECTOR_STANDARD_TYPE_IEC_60309_2_THREE_64:U,CONNECTOR_STANDARD_TYPE_IEC_62196_T1:Mr,CONNECTOR_STANDARD_TYPE_IEC_62196_T1_COMBO:kr,CONNECTOR_STANDARD_TYPE_IEC_62196_T2:Rr,CONNECTOR_STANDARD_TYPE_IEC_62196_T2_COMBO:Ar,CONNECTOR_STANDARD_TYPE_IEC_62196_T3A:jr,CONNECTOR_STANDARD_TYPE_IEC_62196_T3C:St,CONNECTOR_STANDARD_TYPE_NEMA_5_20:U,CONNECTOR_STANDARD_TYPE_NEMA_6_30:U,CONNECTOR_STANDARD_TYPE_NEMA_6_50:U,CONNECTOR_STANDARD_TYPE_NEMA_10_30:U,CONNECTOR_STANDARD_TYPE_NEMA_10_50:U,CONNECTOR_STANDARD_TYPE_NEMA_14_30:U,CONNECTOR_STANDARD_TYPE_NEMA_14_50:U,CONNECTOR_STANDARD_TYPE_PANTOGRAPH_BOTTOM_UP:Ae,CONNECTOR_STANDARD_TYPE_PANTOGRAPH_TOP_DOWN:Ae,CONNECTOR_STANDARD_TYPE_TESLA_R:Ae,CONNECTOR_STANDARD_TYPE_TESLA_S:Ae},jt={minPower:7,operator:[],status:[],publishingMode:"",connectorTypes:[],noAdditionalCharges:!1,powerType:void 0,operatorOnly:""};function ac(e){return!!(e.minPower&&e.minPower!==jt.minPower||e?.status?.length||e?.connectorTypes?.length||e?.operator?.length||e?.powerType||e?.partyId||e?.noAdditionalCharges||e?.operatorOnly)}const cc=[{label:7,value:7},{label:11,value:11},{label:22,value:22},{label:43,value:43},{label:50,value:50},{label:100,value:100},{label:150,value:150},{label:200,value:200},{label:"250+",value:250}],fn=(e,n,i)=>{switch(e){case"remove":return n.filter(r=>!i.includes(r));case"add":return Array.from(new Set([...n,...i]))}};function lc(e){return v.useReducer((n,i)=>({...n,...i}),e)}function uc(){const{setFilters:e,t:n,filters:i,filterConfiguration:r,options:o}=Ie(),[t,s]=lc(jt),{setView:c}=_t(),l=o.version==="v2"&&r?.operators?.length>1;return v.useEffect(()=>{s(i)},[]),v.useEffect(()=>{e(t)},[t]),a.jsxs(a.Fragment,{children:[a.jsx("div",{className:K.headerContainer,children:a.jsx("div",{className:K.header,children:n("filters.header")})}),a.jsxs("div",{className:K.container,children:[a.jsx("button",{onClick:()=>{s(jt),e(jt)},className:K.actionLinkClearAll,children:n("filters.clearAll")}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.onlyShow")}),a.jsxs("label",{htmlFor:"dsChargers",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:n("filters.dcChargers")}),a.jsx(Se,{id:"dsChargers",checked:t.powerType==="dc",onChange:u=>{s({powerType:u?"dc":void 0})}})]}),o.version!=="v2"&&a.jsxs("label",{htmlFor:"efluxChargers",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:n("filters.efluxChargers")}),a.jsx(Se,{id:"efluxChargers",checked:t.partyId==="EFL",onChange:u=>{s({partyId:u?"EFL":void 0})}})]}),(o.version!=="v2"||r?.showNoAdditionalFeeFilter)&&a.jsxs("label",{htmlFor:"noAdditionalFee",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:n("filters.noAdditionalFee")}),a.jsx(Se,{id:"noAdditionalFee",checked:t.noAdditionalCharges,onChange:u=>{s({noAdditionalCharges:u?!0:void 0})}})]}),r.showOperatorOnly&&o.version==="v2"&&a.jsxs("label",{htmlFor:"operatorOnly",className:K.rowLabel,children:[a.jsx("div",{className:K.label,children:`Show '${r.showOperatorOnly}' only`}),a.jsx(Se,{id:"operatorOnly",checked:t.operatorOnly===r.showOperatorOnly,onChange:u=>{s({operatorOnly:u?r.showOperatorOnly:void 0})}})]})]}),l&&a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:"Operator"}),a.jsx(rc,{id:"operator",preferredValues:o.preferredOperators,value:t.operator,options:[...r?.operators?.map(u=>({value:u?.connectionId,label:u?.name,selected:t.operators?.includes(u?.connectionId)}))||[]],placeholder:"Select operator",onChange:u=>{s({operator:u})}})]}),r?.showPublishingModeFilter&&r?.publishingMode?.length>1&&a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:"Visibility"}),a.jsx(sc,{id:"publishingMode",value:t.publishingMode,options:[{value:"",label:"All locations"},{value:"PUBLISHING_MODE_PUBLIC",label:"Public locations"},{value:"PUBLISHING_MODE_PRIVATE",label:"Private locations"}],onChange:u=>{s({publishingMode:u})}})]}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.statusHeading")}),a.jsxs("label",{htmlFor:"statusAvailable",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("div",{className:K.dot,style:{background:"#33AC19"}}),n("filters.available")]}),a.jsx(Se,{id:"statusAvailable",name:"status",checked:t.status.includes("AVAILABLE"),onChange:u=>{s({status:fn(u?"add":"remove",t.status,["AVAILABLE"])})}})]}),a.jsxs("label",{htmlFor:"statusCharging",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("div",{className:K.dot,style:{background:"#005CEE"}}),n("filters.charging")]}),a.jsx(Se,{id:"statusCharging",checked:t.status.includes("CHARGING"),onChange:u=>{s({status:fn(u?"add":"remove",t.status,["CHARGING"])})}})]}),a.jsxs("label",{htmlFor:"statusError",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("div",{className:K.dot,style:{background:"#EB001B"}}),n("filters.notAvailable")]}),a.jsx(Se,{id:"statusError",name:"status",checked:t.status.includes("INOPERATIVE")&&t.status.includes("UNKNOWN"),onChange:u=>{s({status:fn(u?"add":"remove",t.status,["INOPERATIVE","UNKNOWN"])})}})]})]}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.chargingPower")}),a.jsx(Ys,{value:t.minPower,onChange:u=>{s({minPower:u})},ticks:cc})]}),a.jsxs("div",{className:K.optionsGroup,children:[a.jsx("div",{className:K.heading,children:n("filters.connectorType")}),a.jsxs("label",{htmlFor:"type1",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:Ge.IEC_62196_T1,className:K.connectorIcon}),"Type 1 (Yazaki)"]}),a.jsx(Se,{id:"type1",checked:t.connectorTypes.includes("IEC_62196_T1"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T1"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T1")})}})]}),a.jsxs("label",{htmlFor:"type2",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:Ge.IEC_62196_T2,className:K.connectorIcon}),"Type 2 (Mennekes)"]}),a.jsx(Se,{id:"type2",checked:t.connectorTypes.includes("IEC_62196_T2"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T2"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T2")})}})]}),a.jsxs("label",{htmlFor:"type3",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:Ge.IEC_62196_T3,className:K.connectorIcon}),"Type 3 (Le Grand)"]}),a.jsx(Se,{id:"type3",checked:t.connectorTypes.includes("IEC_62196_T3A"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T3A"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T3A")})}})]}),a.jsxs("label",{htmlFor:"CHAdeMo",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:Ge.CHADEMO,className:K.connectorIcon}),"CHAdeMo"]}),a.jsx(Se,{id:"CHAdeMo",checked:t.connectorTypes.includes("CHADEMO"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"CHADEMO"]:t.connectorTypes.filter(f=>f!=="CHADEMO")})}})]}),a.jsxs("label",{htmlFor:"domestic",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:Ge.DOMESTIC_F,className:K.connectorIcon}),"Domestic"]}),a.jsx(Se,{id:"domestic",checked:t.connectorTypes.includes("DOMESTIC_F"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"DOMESTIC_F"]:t.connectorTypes.filter(f=>f!=="DOMESTIC_F")})}})]}),a.jsxs("label",{htmlFor:"combo",className:K.rowLabel,children:[a.jsxs("div",{className:K.label,children:[a.jsx("img",{src:Ge.IEC_62196_T2_COMBO,className:K.connectorIcon}),"Combo"]}),a.jsx(Se,{id:"combo",checked:t.connectorTypes.includes("IEC_62196_T2_COMBO"),onChange:u=>{s({connectorTypes:u?[...t.connectorTypes,"IEC_62196_T2_COMBO"]:t.connectorTypes.filter(f=>f!=="IEC_62196_T2_COMBO")})}})]})]})]})]})}const dc="locations-module_headerContainer",fc="locations-module_publishingMode",pc="locations-module_container",hc="locations-module_header",mc="locations-module_subheader",gc="locations-module_row",vc="locations-module_icon",_c="locations-module_statusIcon",Cc="locations-module_text",Ec="locations-module_note",yc="locations-module_divider",Tc="locations-module_pagingation",xc="locations-module_tariffNoteLink",S={headerContainer:dc,publishingMode:fc,container:pc,header:hc,subheader:mc,row:gc,icon:vc,statusIcon:_c,text:Cc,note:Ec,divider:yc,pagingation:Tc,tariffNoteLink:xc},bc="LocationPlaceholder-module_container",Ic="LocationPlaceholder-module_header",wc="LocationPlaceholder-module_divider",Nc="LocationPlaceholder-module_iconLine",Oc="LocationPlaceholder-module_priceLine",Oe={container:bc,header:Ic,divider:wc,iconLine:Nc,priceLine:Oc};function Sc(){return a.jsxs("div",{className:Oe.container,children:[a.jsx("div",{className:Oe.header}),a.jsx("div",{className:Oe.divider,style:{marginTop:"15px",marginBottom:"23px"}}),a.jsx("div",{className:Oe.iconLine,style:{width:"60%"}}),a.jsx("div",{className:Oe.iconLine,style:{width:"45%"}}),a.jsx("div",{className:Oe.iconLine,style:{width:"50%"}}),a.jsx("div",{className:Oe.divider}),a.jsx("div",{className:Oe.iconLine,style:{width:"50%"}}),a.jsx("div",{className:Oe.iconLine,style:{width:"62%"}}),a.jsx("div",{className:Oe.priceLine}),a.jsx("div",{className:Oe.divider}),a.jsx("div",{className:Oe.iconLine,style:{width:"50%"}}),a.jsx("div",{className:Oe.iconLine,style:{width:"57%"}}),a.jsx("div",{className:Oe.priceLine,style:{width:"30%"}})]})}function Oi(){return a.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512",fill:"currentColor",children:a.jsx("path",{d:"M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"})})}function Dc(){return a.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512",fill:"currentColor",children:a.jsx("path",{d:"M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"})})}function Vn(){return a.jsx("svg",{viewBox:"0 0 16 16",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:a.jsx("g",{children:a.jsx("path",{d:"M8 0.25C3.72009 0.25 0.25 3.72134 0.25 8C0.25 12.2812 3.72009 15.75 8 15.75C12.2799 15.75 15.75 12.2812 15.75 8C15.75 3.72134 12.2799 0.25 8 0.25ZM8 14.25C4.54588 14.25 1.75 11.4553 1.75 8C1.75 4.54703 4.546 1.75 8 1.75C11.4528 1.75 14.25 4.54597 14.25 8C14.25 11.4541 11.4553 14.25 8 14.25ZM8 3.6875C8.72487 3.6875 9.3125 4.27513 9.3125 5C9.3125 5.72487 8.72487 6.3125 8 6.3125C7.27513 6.3125 6.6875 5.72487 6.6875 5C6.6875 4.27513 7.27513 3.6875 8 3.6875ZM9.75 11.625C9.75 11.8321 9.58209 12 9.375 12H6.625C6.41791 12 6.25 11.8321 6.25 11.625V10.875C6.25 10.6679 6.41791 10.5 6.625 10.5H7V8.5H6.625C6.41791 8.5 6.25 8.33209 6.25 8.125V7.375C6.25 7.16791 6.41791 7 6.625 7H8.625C8.83209 7 9 7.16791 9 7.375V10.5H9.375C9.58209 10.5 9.75 10.6679 9.75 10.875V11.625Z"})})})}const Pc="SidebarContainer-module_container",Rc={container:Pc};function mt({children:e}){return a.jsx("div",{className:Rc.container,children:e})}const Ac="Debug-module_container",Mc="Debug-module_content",kc="Debug-module_connectorHeader",jc="Debug-module_code",Lc="Debug-module_evse",nt={container:Ac,content:Mc,connectorHeader:kc,code:jc,evse:Lc};function Vc({location:e}){return a.jsx("div",{className:nt.container,children:a.jsxs(mt,{children:[a.jsx("div",{children:a.jsxs("h3",{children:["Debug: ",e.name]})}),a.jsx("div",{style:{marginBottom:"5px"},children:a.jsx("button",{onClick:()=>{navigator.clipboard.writeText(JSON.stringify(e,null,2))},children:"Copy location"})}),a.jsx("div",{className:nt.content,children:e.evses.map(n=>a.jsxs("div",{className:nt.evse,children:[a.jsxs("div",{className:nt.connectorHeader,children:["Evse: ",n.evseId||n.evse_id]}),a.jsx("div",{children:n.connectors.map((i,r)=>a.jsxs("div",{children:[a.jsxs("div",{className:nt.connectorHeader,children:["Connector #",r]}),a.jsx("pre",{className:nt.code,children:JSON.stringify(i.tariff||Array.isArray(e.tariffs)?e.tariffs?.find(o=>i.tariff_ids.includes(o.id)):null,null,2)})]}))})]}))})]})})}const Si="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='18'%20height='16'%20viewBox='0%200%2018%2016'%20fill='none'%3e%3cg%20clip-path='url(%23clip0_480_2466)'%3e%3cpath%20d='M3.76781%207H5.0925L4.81812%208.71156C4.77812%208.85969%204.9075%209%205.07875%209C5.17188%209%205.26156%208.95719%205.31063%208.88313L7.40219%205.78062C7.50531%205.62469%207.37656%205.42875%207.17031%205.42875H5.88219L6.14094%204.295C6.18625%204.14625%206.05781%204.00031%205.88219%204.00031H4.36438C4.23%204.00031%204.11656%204.08719%204.09875%204.20375L3.50187%206.735C3.48094%206.87531%203.60594%207%203.76781%207ZM17.5%204H17V2.5C17%202.22375%2016.7763%202%2016.5%202C16.2237%202%2016%202.22375%2016%202.5V4H15V2.5C15%202.22375%2014.7762%202%2014.5%202C14.2238%202%2014%202.22375%2014%202.5V4H13.5C13.2238%204%2013%204.22375%2013%204.5V6C13%207.1175%2013.7381%208.05281%2014.75%208.37281V11.625C14.75%2012.1075%2014.3575%2012.5%2013.875%2012.5C13.3925%2012.5%2013%2012.1075%2013%2011.625V10.75C13%209.23344%2011.7666%208%2010.25%208H10V1.5C10%200.671562%209.32844%200%208.5%200H2.5C1.67156%200%201%200.671562%201%201.5V14.5H0.25C0.111875%2014.5%200%2014.6119%200%2014.75V15.75C0%2015.8881%200.111875%2016%200.25%2016H10.75C10.8881%2016%2011%2015.8881%2011%2015.75V14.75C11%2014.6119%2010.8881%2014.5%2010.75%2014.5H10V9.5H10.25C10.9394%209.5%2011.5%2010.0606%2011.5%2010.75V11.625C11.5%2012.9347%2012.5653%2014%2013.875%2014C15.1847%2014%2016.25%2012.9347%2016.25%2011.625V8.37281C17.2619%208.05281%2018%207.1175%2018%206V4.5C18%204.22375%2017.7763%204%2017.5%204ZM8.5%2014.5H2.5V1.5H8.5V14.5ZM16.5%206C16.5%206.55125%2016.0513%207%2015.5%207C14.9487%207%2014.5%206.55125%2014.5%206V5.5H16.5V6Z'%20fill='black'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_480_2466'%3e%3crect%20width='18'%20height='16'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Di="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='14'%20height='16'%20viewBox='0%200%2014%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_480_2468)'%3e%3cpath%20d='M4%204.625V3.375C4%203.16875%204.16875%203%204.375%203H5.625C5.83125%203%206%203.16875%206%203.375V4.625C6%204.83125%205.83125%205%205.625%205H4.375C4.16875%205%204%204.83125%204%204.625ZM8.375%205H9.625C9.83125%205%2010%204.83125%2010%204.625V3.375C10%203.16875%209.83125%203%209.625%203H8.375C8.16875%203%208%203.16875%208%203.375V4.625C8%204.83125%208.16875%205%208.375%205ZM4.375%208H5.625C5.83125%208%206%207.83125%206%207.625V6.375C6%206.16875%205.83125%206%205.625%206H4.375C4.16875%206%204%206.16875%204%206.375V7.625C4%207.83125%204.16875%208%204.375%208ZM8.375%208H9.625C9.83125%208%2010%207.83125%2010%207.625V6.375C10%206.16875%209.83125%206%209.625%206H8.375C8.16875%206%208%206.16875%208%206.375V7.625C8%207.83125%208.16875%208%208.375%208ZM6%2010.625V9.375C6%209.16875%205.83125%209%205.625%209H4.375C4.16875%209%204%209.16875%204%209.375V10.625C4%2010.8313%204.16875%2011%204.375%2011H5.625C5.83125%2011%206%2010.8313%206%2010.625ZM8.375%2011H9.625C9.83125%2011%2010%2010.8313%2010%2010.625V9.375C10%209.16875%209.83125%209%209.625%209H8.375C8.16875%209%208%209.16875%208%209.375V10.625C8%2010.8313%208.16875%2011%208.375%2011ZM14%2014.875V16H0V14.875C0%2014.6687%200.16875%2014.5%200.375%2014.5H0.984375V0.75C0.984375%200.334375%201.31875%200%201.73438%200H12.2656C12.6812%200%2013.0156%200.334375%2013.0156%200.75V14.5H13.625C13.8313%2014.5%2014%2014.6687%2014%2014.875ZM2.48438%2014.4688H6V12.375C6%2012.1687%206.16875%2012%206.375%2012H7.625C7.83125%2012%208%2012.1687%208%2012.375V14.4688H11.5156V1.53125L2.5%201.5L2.48438%2014.4688Z'%20fill='black'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_480_2468'%3e%3crect%20width='14'%20height='16'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Pi="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='20'%20height='16'%20viewBox='0%200%2020%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M17%206H16.5L13.1003%201.75063C12.913%201.51641%2012.6754%201.32734%2012.405%201.19741C12.1347%201.06747%2011.8387%201.00001%2011.5387%201H4.85406C4.03625%201%203.30094%201.49781%202.99719%202.25719L1.5%206V6.07062C0.63875%206.29375%200%207.06906%200%208V11.5C0%2011.7762%200.22375%2012%200.5%2012H2C2%2013.6569%203.34312%2015%205%2015C6.65688%2015%208%2013.6569%208%2012H12C12%2013.6569%2013.3431%2015%2015%2015C16.6569%2015%2018%2013.6569%2018%2012H19.5C19.7763%2012%2020%2011.7762%2020%2011.5V9C20%207.34312%2018.6569%206%2017%206ZM8.75%202.5H11.5387C11.6916%202.5%2011.8338%202.56844%2011.9291%202.6875L14.5791%206H8.75V2.5ZM4.38969%202.81437C4.46625%202.62344%204.64844%202.5%204.85406%202.5H7.25V6H3.11562L4.38969%202.81437ZM5%2013.5C4.17156%2013.5%203.5%2012.8284%203.5%2012C3.5%2011.1716%204.17156%2010.5%205%2010.5C5.82844%2010.5%206.5%2011.1716%206.5%2012C6.5%2012.8284%205.82844%2013.5%205%2013.5ZM15%2013.5C14.1716%2013.5%2013.5%2012.8284%2013.5%2012C13.5%2011.1716%2014.1716%2010.5%2015%2010.5C15.8284%2010.5%2016.5%2011.1716%2016.5%2012C16.5%2012.8284%2015.8284%2013.5%2015%2013.5ZM18.5%2010.5H17.5841C17.0644%209.60719%2016.1078%209%2015%209C13.8922%209%2012.9359%209.60719%2012.4159%2010.5H7.58406C7.06437%209.60719%206.10781%209%205%209C3.89219%209%202.93594%209.60719%202.41594%2010.5H1.5V8C1.5%207.72437%201.72438%207.5%202%207.5H17C17.8272%207.5%2018.5%208.17281%2018.5%209V10.5Z'%20fill='black'/%3e%3c/svg%3e",Wt="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='12'%20height='16'%20viewBox='0%200%2012%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_480_2435)'%3e%3cpath%20d='M11.8068%205.24687C11.5506%204.8%2011.0849%204.53125%2010.5693%204.53125H7.61932L8.51619%201.79688C8.63182%201.36563%208.54119%200.9125%208.26932%200.55625C7.99432%200.203125%207.57869%200%207.13182%200H3.05369C2.34118%200%201.73181%200.534375%201.65368%201.15937L0.0161813%207.79063C-0.0431938%208.22188%200.0849314%208.65625%200.369307%208.98438C0.653682%209.3125%201.06618%209.5%201.50056%209.5H4.56619L3.47556%2014.2406C3.37556%2014.6688%203.47244%2015.1125%203.74431%2015.4563C4.01619%2015.8031%204.42556%2016%204.86619%2016C5.37556%2016%205.85057%2015.725%206.07869%2015.325L11.8037%206.67812C12.0662%206.23125%2012.0662%205.69375%2011.8068%205.24687ZM5.00369%2014.2937L6.45057%208H1.48493L3.05369%201.5L7.04119%201.47187L5.54744%206.03125H10.4381L5.00369%2014.2937Z'%20fill='%232A2A2A'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_480_2435'%3e%3crect%20width='12'%20height='16'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Ri="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='18'%20height='12'%20viewBox='0%200%2018%2012'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M16.2857%200H0.857143C0.383839%200%200%200.383839%200%200.857143V11.1429C0%2011.6162%200.383839%2012%200.857143%2012H16.2857C16.759%2012%2017.1429%2011.6162%2017.1429%2011.1429V0.857143C17.1429%200.383839%2016.759%200%2016.2857%200ZM15.8571%2010.7143H1.28571V1.28571H15.8571V10.7143ZM7.92857%207.71429H10.0714C10.1898%207.71429%2010.2857%207.61839%2010.2857%207.5V6.64286C10.2857%206.52446%2010.1898%206.42857%2010.0714%206.42857H7.92857C7.81018%206.42857%207.71429%206.52446%207.71429%206.64286V7.5C7.71429%207.61839%207.81018%207.71429%207.92857%207.71429ZM14.3571%206.42857H12.2143C12.0959%206.42857%2012%206.52446%2012%206.64286V7.5C12%207.61839%2012.0959%207.71429%2012.2143%207.71429H14.3571C14.4755%207.71429%2014.5714%207.61839%2014.5714%207.5V6.64286C14.5714%206.52446%2014.4755%206.42857%2014.3571%206.42857ZM7.92857%205.57143H14.3571C14.4755%205.57143%2014.5714%205.47554%2014.5714%205.35714V4.5C14.5714%204.38161%2014.4755%204.28571%2014.3571%204.28571H7.92857C7.81018%204.28571%207.71429%204.38161%207.71429%204.5V5.35714C7.71429%205.47554%207.81018%205.57143%207.92857%205.57143ZM3.60857%206.04607L4.73866%206.3525C4.85089%206.38304%204.92857%206.47437%204.92857%206.57482C4.92857%206.70339%204.80804%206.80786%204.65911%206.80786H3.95357C3.84241%206.80786%203.73312%206.78%203.6383%206.72884C3.5558%206.68411%203.45509%206.69214%203.3908%206.76045L3.0675%207.10143C2.9842%207.18929%202.99786%207.33286%203.09777%207.40116C3.32009%207.5525%203.58152%207.63902%203.85714%207.65616V7.92857C3.85714%208.04696%203.95304%208.14286%204.07143%208.14286H4.5C4.61839%208.14286%204.71429%208.04696%204.71429%207.92857V7.65402C5.30839%207.62455%205.78571%207.15661%205.78571%206.57455C5.78571%206.08786%205.44768%205.65634%204.96286%205.52536L3.83277%205.21893C3.72054%205.18839%203.64286%205.09705%203.64286%204.99661C3.64286%204.86804%203.76339%204.76357%203.91232%204.76357H4.61786C4.72902%204.76357%204.8383%204.79143%204.93312%204.84259C5.01562%204.88705%205.11634%204.87929%205.18062%204.81098L5.50393%204.47C5.58723%204.38214%205.57357%204.23857%205.47366%204.17027C5.25134%204.01893%204.98991%203.93241%204.71429%203.91527V3.64286C4.71429%203.52446%204.61839%203.42857%204.5%203.42857H4.07143C3.95304%203.42857%203.85714%203.52446%203.85714%203.64286V3.91741C3.26304%203.94688%202.78571%204.41482%202.78571%204.99688C2.78571%205.48357%203.12375%205.91509%203.60857%206.04607Z'%20fill='%232A2A2A'/%3e%3c/svg%3e";function Ai(e){return Ge[e.standard||e.connectorStandardType]}function Mi(e,n){return new Intl.NumberFormat(e,{maximumFractionDigits:2}).format(n)}const Hc={CONNECTOR_POWER_TYPE_UNSPECIFIED:"Unspecified",CONNECTOR_POWER_TYPE_AC_1_PHASE:"AC x 1",CONNECTOR_POWER_TYPE_AC_2_PHASE:"AC x 2",CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT:"AC x 2 Split",CONNECTOR_POWER_TYPE_AC_3_PHASE:"AC x 3",CONNECTOR_POWER_TYPE_DC:"DC",CONNECTOR_POWER_TYPE_AC:"AC",AC_3_PHASE:"AC x 3",AC_1_PHASE:"AC x 1",DC:"DC"};function ki(e){return[$c(e.standard||e.connectorStandardType),Hc[e.powerType||e.power_type||e.connectorPowerType],"Socket"].join(", ")}function $c(e){return e=(e||"").replace("CONNECTOR_STANDARD_TYPE_",""),e==="IEC_62196_T1"?"Type 1":e==="IEC_62196_T1_COMBO"?"Type 1 Combo":e==="IEC_62196_T2"?"Type 2":e==="IEC_62196_T2_COMBO"?"Type 2 Combo":e==="IEC_62196_T3A"?"Type 3A":e==="IEC_62196_T3C"?"Type 3C":e==="CHADEMO"?"CHAdeMO":e==="DOMESTIC_F"?"Domestic F":e==="DOMESTIC_E"?"Domestic E":e==="DOMESTIC_B"?"Domestic B":e==="CATARC"?"Catarc":e}function ji(e,n){switch(n){case"AVAILABLE":return e("evse.statusAvailable");case"CHARGING":return e("evse.statusCharging");case"UNAVAILABLE":return e("evse.statusUnavailable");case"ERROR":return e("evse.statusError");case"UNKNOWN":return e("evse.statusUnknown");case"REMOVED":return e("evse.statusRemoved");case"PLANNED":return e("evse.statusPlanned");case"RESERVED":return e("evse.statusReserved");case"INOPERATIVE":return e("evse.statusInoperative");case"OUTOFORDER":return e("evse.statusOutOfOrder");default:return e("evse.statusUnknown")}}function Li(e,n){return n?.type==="ON_STREET"?e("locationType.onStreet"):n?.type==="PARKING_GARAGE"?e("locationType.parkingGarage"):n?.type==="UNDERGROUND_GARAGE"?e("locationType.undergroundGarage"):n?.type==="PARKING_LOT"?e("locationType.parkingLot"):e("locationType.other")}function Vi(e=[]){return e.some(n=>n.status==="AVAILABLE")?Fe("AVAILABLE"):e.some(n=>n.status==="CHARGING")?Fe("CHARGING"):Fe("UNKNOWN")}function Hi(e,n){let i;["en","fr"].some(s=>{let l=new Intl.DateTimeFormat(s,{minute:"numeric",timeZone:n,timeZoneName:"short"}).formatToParts(e).filter(u=>u.type=="timeZoneName"&&u.value);if(/^(GMT|UTC)/.test(l[0].value))return i=l[0].value.replace(/GMT|UTC/,"")||"+0",!0});let r=i[0]=="+"?"+":"-",[o,t]=i.substring(1).split(":");return r+o.padStart(2,"0")+":"+(t||"00")}function $i(e){let n=/^-/.test(e)?-1:1,[i,r]=e.match(/\d\d/g);return n*(i*60+Number(r))}function Lr(e,n){const i=s=>("0"+s).slice(-2),{year:r,month:o,day:t}=new Intl.DateTimeFormat("en",{timeZone:e}).formatToParts(n).reduce((s,c)=>(s[c.type]=c.value,c),Object.create(null));return`${r}-${i(o)}-${i(t)}`}function Fi(e,n=new Date){const i=Hi(n,e),r=$i(i),o=new Date(+n);return o.setUTCMinutes(o.getUTCMinutes()+r),o}function Bi(e,n=new Date){const i=Hi(n,e),r=$i(i),o=new Date(+n);o.setUTCHours(0,-r,0,0);const t=Lr(e,n),s=Lr(e,o);return s>t?o.setUTCDate(o.getUTCDate()-1):s<t&&o.setUTCDate(o.getUTCDate()+1),o}function Fc(e,n=new Date){return new Date(Bi(e,n).valueOf()+86399999)}function Bc(e,n,i){const r=Fi(i,e);return r.getUTCDate()!==n&&r.setUTCDate(e.getUTCDate()+(7+n-e.getUTCDay()-1)%7+1),{start:Bi(i,r),end:Fc(i,r)}}function vt(e,n){return Fi(n,e).getUTCDay()}function Vr(e){const[n,i]=e.split(":");return parseInt(n)*60+parseInt(i)}function Hn(e){if(!e?.restrictions?.startTime)return{elements:[e],priceComponents:e.priceComponents,startTime:0,endTime:1440,isFullDay:!0};const n=Vr(e.restrictions.startTime),i=Vr(e.restrictions.endTime);return{elements:[e],priceComponents:e.priceComponents,isFullDay:n===0&&i===1440,startTime:n,endTime:i}}function zc(e,n,i){const r=(i.getHours()*60+i.getMinutes())%60;if(e.length<=1)return e.map(t=>(t.isActive=n&&t.startTime<=r&&t.endTime>=r,t));e=e.sort((t,s)=>t.startTime-s.startTime);let o=[e[0]];for(let t=1;t<e.length;t++){const s=e[t],c=o.findLast(u=>u.startTime<=s.startTime);if(!c)o=o.filter(u=>u.endTime>s.endTime),o.unshift(s);else{const u=c.endTime;c.endTime=s.startTime;const f=[s];u>s.endTime&&f.push({...c,startTime:s.endTime,endTime:u}),o.splice(o.indexOf(c)+1,0,...f)}let l=0;o=o.map((u,f)=>{const p=o[f-1];if(u.endTime>l)l=u.endTime;else return null;return p&&p.endTime!==u.startTime&&(u.startTime=p.endTime),u}).filter(Boolean)}return o.map(t=>(t.isActive=n&&t.startTime<=r&&t.endTime>=r,t.isFullDay=t.startTime===0&&t.endTime===1440,t))}function zi(e){return!e?.restrictions||!e?.restrictions?.start_date&&!e?.restrictions?.end_date&&!e?.restrictions?.start_time&&!e?.restrictions?.end_time&&!e?.restrictions?.day_of_week&&!e?.restrictions?.day_of_week}function Gt(e){return!e?.restrictions||!e?.restrictions?.startDate&&!e?.restrictions?.endDate&&!e?.restrictions?.startTime&&!e?.restrictions?.startTime&&!e?.restrictions?.dayOfWeek}function Uc(e,n=6,i=new Date){const o=[...e].filter(t=>!zi(t)).map(t=>({...t,restrictions:{_startDate:new Date(`${t.restrictions.start_date}T${t.restrictions.start_time}`),...t.restrictions}})).sort((t,s)=>t.restrictions._startDate.valueOf()-s.restrictions._startDate.valueOf()).filter(t=>t.restrictions._startDate.valueOf()>new Date().valueOf()-108e5).slice(0,n).reduce((t,s)=>{const c=s.restrictions._startDate.getDate();return t[c]={date:new Date(s.restrictions.start_date),items:[...t[c]?.items||[],s]},t},[]);return Object.keys(o).map(t=>{const{date:s,items:c}=o[t],l=c.map(({restrictions:u,...f})=>{const{_startDate:p,...h}=u;return{...f,restrictions:{...h}}}).map(Hn).map(u=>{const f=vt(i)===vt(s),p=i.getHours()*60+i.getMinutes(),h=f&&u.startTime<=p&&u.endTime-1>=p;return{...u,isActive:h}});return{date:s,items:l}})}function Ui({elements:e,limit:n=6,now:i=new Date}){const o=[...e].filter(t=>!Gt(t)).map(t=>({...t,restrictions:{_startDate:new Date(`${t.restrictions.startDate}T${t.restrictions.startTime}`),...t.restrictions}})).sort((t,s)=>t.restrictions._startDate.valueOf()-s.restrictions._startDate.valueOf()).filter(t=>t.restrictions._startDate.valueOf()>new Date().valueOf()-108e5).slice(0,n).reduce((t,s)=>{const c=s.restrictions._startDate.getDate();return t[c]={date:new Date(s.restrictions.startDate),items:[...t[c]?.items||[],s]},t},[]);return Object.keys(o).map(t=>{const{date:s,items:c}=o[t],l=c.map(({restrictions:u,...f})=>{const{_startDate:p,...h}=u;return{...f,restrictions:{...h}}}).map(Hn).map(u=>{const f=vt(i)===vt(s),p=i.getHours()*60+i.getMinutes(),h=f&&u.startTime<=p&&u.endTime-1>=p;return{...u,isActive:h}});return{date:s,items:l}})}function Yc(e,n){const i=new Date;return[...e].reduce((r,o)=>{const{startDate:t,endDate:s,dayOfWeek:c=[]}=o.restrictions||{};if(!Object.keys(o.restrictions||{}).length)return r;const l=t?new Date(t):null;if(t&&l.valueOf()>Date.now())return r;const u=s?new Date(s):null;return s&&u.valueOf()<Date.now()||["SUNDAY","MONDAY","TUESDAY","WEDNESDAY","THURSDAY","FRIDAY","SATURDAY"].forEach((f,p)=>{const{start:h,end:x}=Bc(i,p,n);l&&l.valueOf()>h.valueOf()||u&&u.valueOf()<x.valueOf()||c.length&&!c.includes(f)||(r[f]=[...r[f],o])}),r},{MONDAY:[],TUESDAY:[],WEDNESDAY:[],THURSDAY:[],FRIDAY:[],SATURDAY:[],SUNDAY:[]})}function Hr(e,n){return Object.keys(e).reduce((i,r)=>(n.includes(r)||(i[r]=e[r]),i),{})}function Kc(e,n){const i=e.map(o=>Hr(o,["isActive"])),r=n.map(o=>Hr(o,["isActive"]));return JSON.stringify(i)===JSON.stringify(r)}function Wc(e){return e.reduce((n,i)=>{const r=n.find(o=>o.startTime===i.startTime&&o.endTime===i.endTime);return r?r.elements.push(...i.elements):n.push(i),n},[])}function Gc(e,n,i){const r=Yc(e.concat().filter(l=>!Gt(l)),n),{SUNDAY:o,...t}=r,[s,...c]=Object.keys({SUNDAY:r.SUNDAY,...t}).map((l,u)=>{const f=r[l],p=vt(i,n)===u;return{day:l,isActive:p,items:zc(Wc(f.map(Hn)),p,i)}});return[...c,s].reduce((l,u,f,p)=>{const h=l[l.length-1],x=h?.items;if(!x||!Kc(x,u.items)){const{day:w,...N}=u;l.push({...N,days:[u.day]})}else h.days=[h.days[0],u.day],h.isActive=h.isActive||u.isActive;return l},[]).filter(l=>!!l.items.length)}function qc(e){return!e||!e.elements?.some(o=>o?.price_components?.length>0)?"none":e.elements.filter(zi).length===e.elements.length?"base":Uc(e.elements,6,new Date).length?"dynamic":"scheduled"}function Zc(e){const{elements:n=[]}=e;return n?.some(t=>t?.priceComponents?.length>0)?n.filter(Gt).length===n.length?"base":Ui({elements:n,limit:6,now:new Date}).length?"dynamic":"scheduled":"none"}const ct={CONNECTOR_POWER_TYPE_AC_1_PHASE:"CONNECTOR_POWER_TYPE_AC_1_PHASE",CONNECTOR_POWER_TYPE_AC_2_PHASE:"CONNECTOR_POWER_TYPE_AC_2_PHASE",CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT:"CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT",CONNECTOR_POWER_TYPE_AC_3_PHASE:"CONNECTOR_POWER_TYPE_AC_3_PHASE",CONNECTOR_POWER_TYPE_DC:"CONNECTOR_POWER_TYPE_DC"};function Jc(e){switch(e.connectorPowerType){case ct.CONNECTOR_POWER_TYPE_AC_1_PHASE:case ct.CONNECTOR_POWER_TYPE_DC:return e.power.maxVoltage*e.power.maxAmperage/1e3;case ct.CONNECTOR_POWER_TYPE_AC_2_PHASE:case ct.CONNECTOR_POWER_TYPE_AC_2_PHASE_SPLIT:return e.power.maxVoltage*e.power.maxAmperage*2/1e3;case ct.CONNECTOR_POWER_TYPE_AC_3_PHASE:return e.power.maxVoltage*e.power.maxAmperage*3/1e3;default:return 0}}const Xc="ConnectorTariff-module_container",Qc="ConnectorTariff-module_bold",el="ConnectorTariff-module_dynamicTariffItem",tl="ConnectorTariff-module_dynamicTariffItemRange",nl="ConnectorTariff-module_tariffHeader",rl="ConnectorTariff-module_tariffLabel",il="ConnectorTariff-module_tariffNote",ol="ConnectorTariff-module_activeNowLabel",Ee={container:Xc,bold:Qc,dynamicTariffItem:el,dynamicTariffItemRange:tl,tariffHeader:nl,tariffLabel:rl,tariffNote:il,activeNowLabel:ol},sl="Price-module_tariffItem",_n={tariffItem:sl};function al(e,n){return new Intl.NumberFormat(void 0,{style:"currency",currency:n.currency||"EUR",maximumFractionDigits:2}).format(e)}function cl(e){const n=e.vat?e.vat/100:0;return e.price+e.price*n}function ll({priceComponent:e,restrictions:n={},currency:i}){const{t:r}=Ie(),o={ENERGY:"tariffPriceComponent.energy",TIME:"tariffPriceComponent.time",FLAT:"tariffPriceComponent.flat",PARKING_TIME:"tariffPriceComponent.parkingTime"};return n?.minDuration===0&&n?.maxDuration&&e.type==="PARKING_TIME"?a.jsx("div",{className:_n.tariffItem,children:r("tariffPriceComponent.parkingTimeWait",{minutes:Math.floor(n.maxDuration/60)})}):o[e.type]?a.jsx("div",{className:_n.tariffItem,children:r(o[e.type],{total:al(cl(e),{currency:i})})}):null}const ul="PriceComponents-module_container",dl={container:ul},$r=["ENERGY","TIME","FLAT","PARKING_TIME"];function Dt({elements:e,currency:n}){const{t:i}=Ie(),r=e.reduce((t,s)=>(s.priceComponents.forEach(c=>{t[c.type]||(t[c.type]=[]),t[c.type].push({priceComponent:c,restrictions:s.restrictions})}),t),{}),o=Object.keys(r).map(t=>({type:t,elements:r[t]})).sort((t,s)=>{const c=$r.indexOf(t.type),l=$r.indexOf(s.type);return c===-1?1:l===-1?-1:c-l});return a.jsx("div",{className:dl.container,children:o.map(({type:t,elements:s},c)=>s.reverse().map((l,u)=>a.jsx(ll,{currency:n,priceComponent:l.priceComponent,restrictions:l.restrictions},`${t}-${c}-${u}`)))})}function fl(e,n){return new Intl.NumberFormat(void 0,{style:"currency",currency:n.currency||"EUR",maximumFractionDigits:2}).format(e)}function pl({vat:e,price:n}){const i=e?e/100:0;return n+n*i}function hl({cdrAdditionalCharge:e,currency:n}){const{t:i}=Ie(),r={FLAT_FEE:i("cdrPrice.flatFee",{total:fl(pl(e),{currency:n})})};return a.jsx("div",{className:_n.tariffItem,children:r[e.type]})}function Pt(e,n){const i=new Date(0),r=Math.floor(n/60),o=n%60;return i.setHours(r,o,0,0),i.toLocaleTimeString("nl",{hour:"2-digit",minute:"2-digit"})}const ml=Intl.DateTimeFormat().resolvedOptions().timeZone;function gl(e){const{format:n}=new Intl.DateTimeFormat(e,{weekday:"long"});return["SUNDAY","MONDAY","TUESDAY","WEDNESDAY","THURSDAY","FRIDAY","SATURDAY"].reduce((i,r,o)=>(i[r]=n(new Date(Date.UTC(2023,9,o+1))),i),{})}function lt({currency:e,cdrAdditionalCharges:n}){return n.map(i=>a.jsx(hl,{currency:e,cdrAdditionalCharge:i},i.id))}function $n({timezone:e=ml,tariff:n,compact:i=!0,cdrAdditionalCharges:r=[]}){const{t:o,language:t}=Ie(),s=gl(t);if(!n)return null;const c=n.elements||[],l=n.currency||"",u=c.some(w=>w.priceComponents&&w.priceComponents.length>0),f=Ui({elements:c,limit:i?6:40,now:new Date}),p=f.length?[]:Gc(c,e,new Date),h=c.filter(Gt);if(!u)return a.jsxs(a.Fragment,{children:[a.jsx("div",{className:Ee.tariffNote,children:o("tariffPriceComponent.noTariff")}),r.length>0&&a.jsx("div",{className:Ee.container,children:a.jsx(lt,{currency:l,cdrAdditionalCharges:r})})]});const x=!p.some(w=>w.isActive);return p.length?a.jsxs("div",{className:Ee.container,children:[h.length>0&&a.jsxs("div",{className:[Ee.tariffList,Ee.bold].join(" "),children:[a.jsxs("div",{className:Ee.tariffHeader,children:[o("tariffPriceComponent.baseTariff"),x&&a.jsx("span",{className:Ee.activeNowLabel,children:o("tariffPriceComponent.active")})]}),a.jsx(Dt,{elements:h,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r})]}),p.map(w=>a.jsxs("div",{className:Ee.tariffList,children:[a.jsxs("div",{className:Ee.tariffHeader,children:[w.days.map(N=>s[N]).join(" - "),w.isActive&&a.jsx("span",{className:Ee.activeNowLabel,children:o("tariffPriceComponent.active")})]}),w.items.map(N=>a.jsxs("div",{className:N.isActive&&Ee.bold,children:[!N.isFullDay&&a.jsxs("div",{className:Ee.tariffLabel,children:[Pt(t,N.startTime)," -"," ",Pt(t,N.endTime)]}),a.jsxs("div",{children:[a.jsx(Dt,{elements:N.elements,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r})]})]},N.startTime))]},w.days.join("-")))]}):a.jsxs("div",{className:Ee.container,children:[h.length>0&&a.jsxs("div",{className:Ee.tariffList,children:[a.jsx(Dt,{elements:h,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r})]}),f.length>0&&a.jsx(a.Fragment,{children:f.map((w,N)=>a.jsxs(a.Fragment,{children:[a.jsx("div",{className:Ee.tariffHeader,children:o("tariffPriceComponent.dynamicTariffHeader",{date:new Intl.DateTimeFormat(t,{weekday:"long",month:"short",day:"numeric"}).format(w.date)})}),a.jsx("div",{className:Ee.dynamicTariffList,children:w.items.map((E,k)=>a.jsxs("div",{className:[Ee.dynamicTariffItem,E.isActive&&Ee.bold].filter(Boolean).join(" "),children:[a.jsxs("div",{className:Ee.dynamicTariffItemRange,children:[Pt(t,E.startTime)," –"," ",Pt(t,E.endTime)]}),a.jsx(Dt,{elements:E.elements,currency:l}),a.jsx(lt,{currency:l,cdrAdditionalCharges:r}),E.isActive&&a.jsx("span",{className:Ee.activeNowLabel,children:o("tariffPriceComponent.active")})]},[E.startTime,E.endTime,k].join()))})]}))})]})}function zt(e,n,i){const r=[];return n?.customNote&&r.push(n?.customNote),i==="none"?r.length?r:[e("tariffNote.baseTariffNote")]:(i==="dynamic"&&r.push(e("tariffNote.dynamicScheduledTariffNote")),n?.infraProviderId==="NLEFL"||n?.party_id==="EFL"?(i==="scheduled"&&r.push(e("tariffNote.eFluxScheduledTariffNote")),r):(i==="scheduled"?r.push(e("tariffNote.baseTariffNote"),e("tariffNote.scheduledTariffNote")):r.push(e("tariffNote.baseTariffNote")),r))}const vl=({currentLocation:e,evses:n,setView:i,cdrAdditionalCharges:r})=>{const{options:o,t,language:s}=Ie(),c=n.filter(l=>l.status==="AVAILABLE");return a.jsxs("div",{className:S.container,children:[a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Si,alt:"station icon"}),a.jsxs("div",{className:S.text,children:[o.locationBaseUrl&&a.jsx("a",{href:`${o.locationBaseUrl}/${e.id}`,children:e.name||"-"}),!o.locationBaseUrl&&e.name]})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{className:S.icon,children:a.jsx("div",{style:{background:Vi(e.evses)},className:S.statusIcon})}),a.jsxs("div",{className:S.text,children:[c.length," / ",n.length," ",t("evse.statusAvailable")]})]}),e.subOperator?.name&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Di,alt:"building icon"}),a.jsx("div",{className:S.text,children:e.subOperator?.name})]}),e.parkingType!=="UNKNOWN"&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Pi,alt:"parking icon"}),a.jsx("div",{className:S.text,children:Li(t,e.parkingType)})]}),n.map(l=>a.jsxs("div",{children:[a.jsx("hr",{className:S.divider}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:l.evseId})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{style:{background:Fe(l.status)},className:S.statusIcon}),a.jsx("div",{className:S.text,children:[ji(t,l.status),l.maxPower&&`${Mi(s,Math.floor(l.maxPower))}kW`].filter(Boolean).join(", ")})]}),l.connectors.map((u,f)=>{const p=Zc(u.tariff),h=zt(t,e,p);return a.jsxs("div",{children:[" ",a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ai(u),alt:"socket type"}),a.jsx("div",{className:S.text,children:ki(u)})]}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ri,alt:"pricing"}),a.jsx("div",{className:S.text,children:t("evse.pricing")})]}),a.jsx($n,{tariff:u.tariff,cdrAdditionalCharges:r}),p==="dynamic"&&a.jsx("div",{className:S.tariffNoteLink,onClick:()=>{i("dynamicTariff",{connector:u,evseId:l.evseId,notes:h,locationName:e.name})},children:t("location.viewAllHourlyPrices")}),h.length>0&&a.jsxs("div",{className:S.tariffNoteLink,onClick:()=>{i("tariffNote",{locationName:e.name,evseId:l.evseId,notes:zt(t,e,p)})},children:[a.jsx(Vn,{})," ",t("tariffPriceComponent.viewTariff")]})]},`connector-${f}`)})]},l.evseId))]})};function _l(e){return e?.currency?{currency:e.currency,id:e.id,country_code:e.country_code,party_id:e.party_id,elements:(e?.elements||[]).map(n=>({priceComponents:(n?.price_components||[]).map(i=>({type:(()=>{switch(i.type){case"FLAT":return"FLAT";case"TIME":return"TIME";case"ENERGY":return"ENERGY";case"PARKING_TIME":return"PARKING_TIME"}})(),price:i.price,vat:i.vat,stepSize:i.step_size})),...n?.restrictions?{restrictions:{startTime:n?.restrictions?.start_time,endTime:n?.restrictions?.end_time,startDate:n?.restrictions?.start_date,endDate:n?.restrictions?.end_date,dayOfWeek:n?.restrictions?.day_of_week}}:{}}))}:null}const Cl=({tariff:e,additionalCharges:n})=>a.jsx($n,{tariff:_l(e),cdrAdditionalCharges:n}),El=({currentLocation:e,setView:n})=>{const{options:i,t:r,language:o}=Ie(),t=e?.evses?.filter(s=>s.status==="AVAILABLE")||[];return a.jsxs("div",{className:S.container,children:[i.context==="cpo"&&a.jsx("div",{className:S.publishingMode,children:e?.publish?"Public location":"Private location"}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Si,alt:"station icon"}),a.jsxs("div",{className:S.text,children:[i.locationBaseUrl&&a.jsx("a",{href:`${i.locationBaseUrl}/${e?.id}`,children:e?.name||"-"}),!i.locationBaseUrl&&e?.name]})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{className:S.icon,children:a.jsx("div",{style:{background:Vi(e.evses)},className:S.statusIcon})}),a.jsxs("div",{className:S.text,children:[t?.length," / ",e?.evses?.length," ",r("evse.statusAvailable")]})]}),e?.suboperator?.name&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Di,alt:"building icon"}),a.jsx("div",{className:S.text,children:e?.suboperator?.name})]}),e.parkingType!=="PARKING_TYPE_UNKNOWN"&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Pi,alt:"parking icon"}),a.jsx("div",{className:S.text,children:Li(r,e.parkingType)})]}),e?.evses?.map(s=>a.jsxs("div",{children:[a.jsx("hr",{className:S.divider}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:s.evse_id})]}),a.jsxs("div",{className:S.row,children:[a.jsx("div",{style:{background:Fe(s.status)},className:S.statusIcon}),a.jsx("div",{className:S.text,children:[ji(r,s.status),s.connectors[0]?.power&&s.connectors[0]?.connectorPowerType?`${Mi(o,Math.floor(Jc(s.connectors[0])))}kW`:null].filter(Boolean).join(", ")})]}),s.connectors.map((c,l)=>{const u=e?.tariffs?.find(h=>h.id===c?.tariff_ids?.[0]),f=qc(u),p=zt(r,e,f);return a.jsxs("div",{children:[" ",a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ai(c),alt:"socket type"}),a.jsx("div",{className:S.text,children:ki(c)})]}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Ri,alt:"pricing"}),a.jsx("div",{className:S.text,children:r("evse.pricing")})]}),a.jsx(Cl,{tariff:u,additionalCharges:e?.cdrAdditionalCharges||[]}),f==="dynamic"&&a.jsx("div",{className:S.tariffNoteLink,onClick:()=>{n("dynamicTariff",{connector:c,evseId:s.evse_id,notes:p,locationName:e.name})},children:r("location.viewAllHourlyPrices")}),i.context!=="cpo"&&p?.length>0&&a.jsxs("div",{className:S.tariffNoteLink,onClick:()=>{n("tariffNote",{locationName:e.name,evseId:s.evse_id,notes:zt(r,e,f)})},children:[a.jsx(Vn,{})," ",r("tariffPriceComponent.viewTariff")]})]},`connector-${l}`)})]},`${s.evse_id}-${s.uid}`))]})},yl=()=>{const{setView:e}=_t(),{locations:n,locationsStatus:i,options:r}=Ie(),[o,t]=v.useState(0);v.useEffect(()=>{t(0)},[n]);const s=n[o];if(i.type==="loading"||!s)return a.jsx("div",{className:S.container,children:a.jsx(Sc,{})});const{evses:c=[],cdrAdditionalCharges:l}=s,u=o<n.length-1,f=o>0,p=window.location?.search?.includes("debug"),h=()=>{switch(r.version){case"v2":return[s?.address,s?.city];default:return[s?.address,s?.city]}},x=r.version==="v2";return a.jsxs(a.Fragment,{children:[p&&s&&a.jsx(Vc,{location:s}),a.jsx("div",{className:S.headerContainer,children:a.jsxs("div",{className:S.header,children:[n.length>1&&a.jsxs("div",{className:S.pagingation,children:[a.jsxs("span",{children:[o+1," / ",n.length]}),a.jsx("button",{disabled:!f,onClick:()=>{t(Math.max(0,o-1))},children:a.jsx(Oi,{})}),a.jsx("button",{disabled:!u,onClick:()=>t(Math.min(n.length-1,o+1)),children:a.jsx(Dc,{})})]}),h().filter(Boolean).join(", ")]})}),!x&&a.jsx(vl,{setView:e,cdrAdditionalCharges:l,currentLocation:s,evses:c}),x&&a.jsx(El,{setView:e,currentLocation:s})]})},Tl="BackButton-module_backButton",xl={backButton:Tl};function Yi({onClick:e=()=>{}}){const{t:n}=Ie();return a.jsxs("button",{onClick:e,className:xl.backButton,children:[a.jsx(Oi,{}),n("backButton.backTo")]})}function bl(){const{t:e}=Ie(),{current:n,setView:i}=_t(),{notes:r=[],evseId:o,locationName:t}=n?.args||{};return a.jsxs(a.Fragment,{children:[a.jsx("div",{className:S.headerContainer,children:a.jsxs("div",{className:S.header,onClick:()=>i("locations"),style:{cursor:"pointer"},children:[a.jsx(Yi,{}),t?.text||t]})}),a.jsxs("div",{className:S.container,children:[a.jsx("div",{className:S.subheader,children:e("tariffNote.subHeader")}),o&&a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:o})]}),r.map(s=>a.jsx("p",{className:S.note,children:s},s))]})]})}function Il(){const{t:e}=Ie(),{current:n,setView:i}=_t(),{connector:r,locationName:o,evseId:t,notes:s}=n?.args||{};return r?.tariff?a.jsxs(a.Fragment,{children:[a.jsx("div",{className:S.headerContainer,children:a.jsxs("div",{className:S.header,onClick:()=>i("locations"),style:{cursor:"pointer"},children:[a.jsx(Yi,{}),o]})}),a.jsxs("div",{className:S.container,children:[a.jsx("div",{className:S.subheader,children:e("dynamicTariffs.subHeader")}),a.jsxs("div",{className:S.row,children:[a.jsx("img",{className:S.icon,src:Wt,alt:"power icon"}),a.jsx("div",{className:S.text,children:t})]}),a.jsx($n,{tariff:r.tariff,compact:!1}),a.jsxs("div",{className:S.tariffNoteLink,onClick:()=>{i("tariffNote",{locationName:o,evseId:t,notes:s})},children:[a.jsx(Vn,{})," ",e("tariffPriceComponent.viewTariff")]})]})]}):null}const wl="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='10'%20height='11'%20viewBox='0%200%2010%2011'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M6.48751%205.99758L9.85376%202.63133C10.0484%202.43664%2010.0484%202.1207%209.85376%201.9257L9.07157%201.14351C8.87688%200.948826%208.56095%200.948826%208.36595%201.14351L5.00001%204.51008L1.63376%201.14383C1.43907%200.949138%201.12313%200.949138%200.928135%201.14383L0.14626%201.9257C-0.0484277%202.12039%20-0.0484277%202.43633%200.14626%202.63133L3.51251%205.99758L0.14626%209.36383C-0.0484277%209.55851%20-0.0484277%209.87445%200.14626%2010.0695L0.928447%2010.8516C1.12313%2011.0463%201.43907%2011.0463%201.63407%2010.8516L5.00001%207.48508L8.36626%2010.8513C8.56095%2011.046%208.87688%2011.046%209.07188%2010.8513L9.85407%2010.0691C10.0488%209.87445%2010.0488%209.55851%209.85407%209.36351L6.48751%205.99758Z'%20fill='black'/%3e%3c/svg%3e",Nl="CloseButton-module_closeButton",Ol={closeButton:Nl};function Ki({onClick:e}){return a.jsx("button",{onClick:e,className:Ol.closeButton,children:a.jsx("img",{src:wl})})}function Sl(){const[e,n]=v.useState("locations"),{setView:i}=_t();return a.jsxs($e,{name:"locations",currentView:e,onViewChange:n,children:[a.jsx($e.View,{name:"locations",children:a.jsxs(mt,{children:[a.jsx(Ki,{onClick:()=>i("none")}),a.jsx(yl,{})]})}),a.jsx($e.View,{name:"tariffNote",children:a.jsx(mt,{children:a.jsx(bl,{})})}),a.jsx($e.View,{name:"dynamicTariff",children:a.jsx(mt,{children:a.jsx(Il,{})})})]})}const Dl="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='currentColor'%20xmlns='http://www.w3.org/2000/svg'%20%3e%3cpath%20d='M14.4985%200H1.50178C0.169343%200%20-0.502939%201.61659%200.441124%202.56066L5.5%207.62131V13C5.5%2013.4721%205.72228%2013.9167%206.1%2014.25L8.1%2015.7208C9.07728%2016.4038%2010.5%2015.7689%2010.5%2014.5208V7.62131L15.5592%202.56066C16.5013%201.6185%2015.8336%200%2014.4985%200ZM9%207V14.5L7%2013V7L1.5%201.5H14.5L9%207Z'%20fill='currentColor'%20/%3e%3c/svg%3e";function Pl(){const{locationIds:e,fetchLocations:n,filters:i,isSearching:r}=Ie(),[o,t]=v.useState("none");return v.useEffect(()=>{e.length>0&&t("locations")},[e,t]),a.jsxs("div",{className:Ke.container,children:[a.jsxs("div",{className:Ke.controlsContainer,children:[a.jsx(Os,{onFocus:()=>{t("none")}}),a.jsxs("div",{className:Ke.filterButton,onClick:()=>{t("filters")},children:[r??!1?a.jsx("div",{className:Ke.spinner}):a.jsx("img",{className:Ke.filterIcon,src:Dl}),ac(i)&&!(r??!1)&&a.jsx("span",{className:Ke.filterCounter})]})]}),a.jsx("div",{className:Ke.stackContainer,children:a.jsxs($e,{name:"router",currentView:o,onViewChange:s=>{t(s)},children:[a.jsx($e.View,{name:"locations",children:a.jsx(Sl,{})}),a.jsx($e.View,{name:"filters",children:a.jsxs(mt,{children:[a.jsx(Ki,{onClick:()=>t("none")}),a.jsx(uc,{})]})})]})})]})}function Rl(e){return a.jsx(Ro,{options:e,language:e.language,children:a.jsxs(Ao,{height:e?.height,children:[a.jsx(Pl,{}),a.jsx(Zo,{})]})})}exports.RoadMap=Rl;
|
|
74
74
|
//# sourceMappingURL=index.js.map
|