@defra/interactive-map 0.0.8-alpha → 0.0.10-alpha
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/DOCS_README.md +39 -0
- package/dist/esm/im-core.js +1 -0
- package/dist/esm/im-shell.js +1 -0
- package/dist/esm/index.js +1 -2
- package/dist/umd/im-core.js +1 -1
- package/dist/umd/index.js +1 -1
- package/docs/api/button-definition.md +104 -3
- package/docs/api.md +22 -2
- package/docs/architecture/architecture-diagrams.md +1 -3
- package/docs/architecture/diagrams-viewer.mdx +12 -0
- package/docs/getting-started.md +78 -8
- package/docs/govuk-prototype.md +23 -0
- package/docs/index.md +23 -0
- package/docusaurus.config.cjs +106 -0
- package/mise.toml +2 -0
- package/package.json +51 -27
- package/plugins/beta/datasets/dist/css/index.css +50 -1
- package/plugins/beta/datasets/dist/esm/im-datasets-plugin.js +1 -0
- package/plugins/beta/datasets/dist/esm/index.js +1 -2
- package/plugins/beta/draw-es/dist/esm/im-draw-es-plugin.js +1 -0
- package/plugins/beta/draw-es/dist/esm/index.js +1 -2
- package/plugins/beta/draw-es/src/api/newPolygon.js +1 -3
- package/plugins/beta/draw-es/src/events.js +2 -2
- package/plugins/beta/draw-ml/dist/esm/im-draw-ml-plugin.js +1 -0
- package/plugins/beta/draw-ml/dist/esm/index.js +1 -2
- package/plugins/beta/draw-ml/dist/umd/im-draw-ml-plugin.js +1 -1
- package/plugins/beta/draw-ml/src/api/newLine.js +2 -2
- package/plugins/beta/draw-ml/src/api/newPolygon.js +2 -2
- package/plugins/beta/draw-ml/src/events.js +18 -10
- package/plugins/beta/frame/dist/css/index.css +11 -1
- package/plugins/beta/frame/dist/esm/im-frame-plugin.js +1 -0
- package/plugins/beta/frame/dist/esm/index.js +1 -2
- package/plugins/beta/map-styles/dist/css/index.css +79 -1
- package/plugins/beta/map-styles/dist/esm/im-map-styles-plugin.js +1 -0
- package/plugins/beta/map-styles/dist/esm/index.js +1 -2
- package/plugins/beta/scale-bar/dist/esm/im-scale-bar-plugin.js +1 -0
- package/plugins/beta/scale-bar/dist/esm/index.js +1 -2
- package/plugins/beta/use-location/dist/esm/im-use-location-plugin.js +1 -0
- package/plugins/beta/use-location/dist/esm/index.js +1 -2
- package/plugins/beta/use-location/dist/umd/index.js +1 -1
- package/plugins/interact/dist/esm/im-interact-plugin.js +1 -0
- package/plugins/interact/dist/esm/index.js +1 -2
- package/plugins/search/dist/esm/im-search-plugin.js +1 -0
- package/plugins/search/dist/esm/index.js +1 -2
- package/plugins/search/src/Search.test.jsx +170 -0
- package/plugins/search/src/components/CloseButton/CloseButton.test.jsx +67 -0
- package/plugins/search/src/components/Form/Form.test.jsx +158 -0
- package/plugins/search/src/components/OpenButton/OpenButton.test.jsx +47 -0
- package/plugins/search/src/components/Suggestions/Suggestions.module.scss +1 -1
- package/plugins/search/src/components/Suggestions/Suggestions.test.jsx +79 -0
- package/plugins/search/src/datasets.test.js +46 -0
- package/plugins/search/src/events/fetchSuggestions.test.js +212 -0
- package/plugins/search/src/events/formHandlers.test.js +232 -0
- package/plugins/search/src/events/index.test.js +118 -0
- package/plugins/search/src/events/inputHandlers.test.js +104 -0
- package/plugins/search/src/events/suggestionHandlers.test.js +166 -0
- package/plugins/search/src/index.test.js +47 -0
- package/plugins/search/src/reducer.test.js +80 -0
- package/plugins/search/src/search.scss +1 -1
- package/plugins/search/src/utils/parseOsNamesResults.js +2 -1
- package/plugins/search/src/utils/parseOsNamesResults.test.js +140 -0
- package/plugins/search/src/utils/updateMap.test.js +52 -0
- package/providers/beta/esri/dist/css/index.css +30 -1
- package/providers/beta/esri/dist/esm/im-esri-provider.js +1 -0
- package/providers/beta/esri/dist/esm/index.js +1 -2
- package/providers/beta/open-names/dist/esm/im-reverse-geocode.js +1 -0
- package/providers/beta/open-names/dist/esm/index.js +1 -2
- package/providers/beta/open-names/src/utils/mapToLocationModel.test.js +61 -0
- package/providers/maplibre/dist/esm/im-maplibre-provider.js +1 -0
- package/providers/maplibre/dist/esm/index.js +1 -2
- package/providers/maplibre/dist/umd/im-maplibre-provider.js +1 -1
- package/providers/maplibre/src/appEvents.test.js +44 -0
- package/providers/maplibre/src/index.test.js +60 -0
- package/providers/maplibre/src/mapEvents.test.js +115 -0
- package/providers/maplibre/src/maplibreProvider.test.js +205 -0
- package/providers/maplibre/src/utils/calculateLinearTextSize.test.js +31 -0
- package/providers/maplibre/src/utils/detectWebgl.test.js +63 -0
- package/providers/maplibre/src/utils/highlightFeatures.test.js +126 -0
- package/providers/maplibre/src/utils/labels.js +1 -3
- package/providers/maplibre/src/utils/labels.test.js +231 -0
- package/providers/maplibre/src/utils/maplibreFixes.test.js +66 -0
- package/providers/maplibre/src/utils/queryFeatures.test.js +60 -0
- package/providers/maplibre/src/utils/spatial.js +5 -4
- package/providers/maplibre/src/utils/spatial.test.js +96 -0
- package/rollup.esm.mjs +288 -0
- package/src/App/store/appActionsMap.js +1 -1
- package/src/InteractiveMap/InteractiveMap.js +3 -2
- package/webpack.dev.mjs +9 -1
- package/webpack.prod.mjs +8 -1
- package/webpack.umd.mjs +1 -2
- package/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/datasets/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/draw-es/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/draw-ml/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/frame/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/map-styles/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/scale-bar/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/beta/use-location/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/interact/dist/esm/index.js.LICENSE.txt +0 -1
- package/plugins/search/dist/esm/index.js.LICENSE.txt +0 -1
- package/providers/beta/esri/dist/esm/index.js.LICENSE.txt +0 -1
- package/providers/beta/open-names/dist/esm/index.js.LICENSE.txt +0 -1
- package/providers/maplibre/dist/esm/index.js.LICENSE.txt +0 -6
- package/webpack.esm.mjs +0 -154
package/dist/esm/index.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
var e={"./src/App/initialiseApp.js"(e,t,n){n.d(t,{initialiseApp:()=>ju}),n.r(t);var r,o,i,u,a,l,c,f,s,p,d,y,v={},m=[],b=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,h=Array.isArray;function _(e,t){for(var n in t)e[n]=t[n];return e}function g(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function O(e,t,n){var o,i,u,a={};for(u in t)"key"==u?o=t[u]:"ref"==u?i=t[u]:a[u]=t[u];if(arguments.length>2&&(a.children=arguments.length>3?r.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(u in e.defaultProps)void 0===a[u]&&(a[u]=e.defaultProps[u]);return P(e,a,o,i,null)}function P(e,t,n,r,u){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:null==u?++i:u,__i:-1,__u:0};return null==u&&null!=o.vnode&&o.vnode(a),a}function S(e){return e.children}function w(e,t){this.props=e,this.context=t}function E(e,t){if(null==t)return e.__?E(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?E(e):null}function j(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return j(e)}}function A(e){(!e.__d&&(e.__d=!0)&&u.push(e)&&!T.__r++||a!=o.debounceRendering)&&((a=o.debounceRendering)||l)(T)}function T(){for(var e,t,n,r,i,a,l,f=1;u.length;)u.length>f&&u.sort(c),e=u.shift(),f=u.length,e.__d&&(n=void 0,r=void 0,i=(r=(t=e).__v).__e,a=[],l=[],t.__P&&((n=_({},r)).__v=r.__v+1,o.vnode&&o.vnode(n),L(t.__P,n,r,t.__n,t.__P.namespaceURI,32&r.__u?[i]:null,a,null==i?E(r):i,!!(32&r.__u),l),n.__v=r.__v,n.__.__k[n.__i]=n,U(a,n,l),r.__e=r.__=null,n.__e!=i&&j(n)));T.__r=0}function k(e,t,n,r,o,i,u,a,l,c,f){var s,p,d,y,b,h,_,g=r&&r.__k||m,O=t.length;for(l=R(n,t,g,l,O),s=0;s<O;s++)null!=(d=n.__k[s])&&(p=-1==d.__i?v:g[d.__i]||v,d.__i=s,h=L(e,d,p,o,i,u,a,l,c,f),y=d.__e,d.ref&&p.ref!=d.ref&&(p.ref&&z(p.ref,null,d),f.push(d.ref,d.__c||y,d)),null==b&&null!=y&&(b=y),(_=!!(4&d.__u))||p.__k===d.__k?l=I(d,l,e,_):"function"==typeof d.type&&void 0!==h?l=h:y&&(l=y.nextSibling),d.__u&=-7);return n.__e=b,l}function R(e,t,n,r,o){var i,u,a,l,c,f=n.length,s=f,p=0;for(e.__k=new Array(o),i=0;i<o;i++)null!=(u=t[i])&&"boolean"!=typeof u&&"function"!=typeof u?("string"==typeof u||"number"==typeof u||"bigint"==typeof u||u.constructor==String?u=e.__k[i]=P(null,u,null,null,null):h(u)?u=e.__k[i]=P(S,{children:u},null,null,null):void 0===u.constructor&&u.__b>0?u=e.__k[i]=P(u.type,u.props,u.key,u.ref?u.ref:null,u.__v):e.__k[i]=u,l=i+p,u.__=e,u.__b=e.__b+1,a=null,-1!=(c=u.__i=C(u,n,l,s))&&(s--,(a=n[c])&&(a.__u|=2)),null==a||null==a.__v?(-1==c&&(o>f?p--:o<f&&p++),"function"!=typeof u.type&&(u.__u|=4)):c!=l&&(c==l-1?p--:c==l+1?p++:(c>l?p--:p++,u.__u|=4))):e.__k[i]=null;if(s)for(i=0;i<f;i++)null!=(a=n[i])&&!(2&a.__u)&&(a.__e==r&&(r=E(a)),q(a,a));return r}function I(e,t,n,r){var o,i;if("function"==typeof e.type){for(o=e.__k,i=0;o&&i<o.length;i++)o[i]&&(o[i].__=e,t=I(o[i],t,n,r));return t}e.__e!=t&&(r&&(t&&e.type&&!t.parentNode&&(t=E(e)),n.insertBefore(e.__e,t||null)),t=e.__e);do{t=t&&t.nextSibling}while(null!=t&&8==t.nodeType);return t}function D(e,t){return t=t||[],null==e||"boolean"==typeof e||(h(e)?e.some(function(e){D(e,t)}):t.push(e)),t}function C(e,t,n,r){var o,i,u,a=e.key,l=e.type,c=t[n],f=null!=c&&!(2&c.__u);if(null===c&&null==a||f&&a==c.key&&l==c.type)return n;if(r>(f?1:0))for(o=n-1,i=n+1;o>=0||i<t.length;)if(null!=(c=t[u=o>=0?o--:i++])&&!(2&c.__u)&&a==c.key&&l==c.type)return u;return-1}function M(e,t,n){"-"==t[0]?e.setProperty(t,null==n?"":n):e[t]=null==n?"":"number"!=typeof n||b.test(t)?n:n+"px"}function x(e,t,n,r,o){var i,u;e:if("style"==t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||M(e.style,t,"");if(n)for(t in n)r&&n[t]==r[t]||M(e.style,t,n[t])}else if("o"==t[0]&&"n"==t[1])i=t!=(t=t.replace(f,"$1")),u=t.toLowerCase(),t=u in e||"onFocusOut"==t||"onFocusIn"==t?u.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?r?n.u=r.u:(n.u=s,e.addEventListener(t,i?d:p,i)):e.removeEventListener(t,i?d:p,i);else{if("http://www.w3.org/2000/svg"==o)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=t&&"height"!=t&&"href"!=t&&"list"!=t&&"form"!=t&&"tabIndex"!=t&&"download"!=t&&"rowSpan"!=t&&"colSpan"!=t&&"role"!=t&&"popover"!=t&&t in e)try{e[t]=null==n?"":n;break e}catch(e){}"function"==typeof n||(null==n||!1===n&&"-"!=t[4]?e.removeAttribute(t):e.setAttribute(t,"popover"==t&&1==n?"":n))}}function N(e){return function(t){if(this.l){var n=this.l[t.type+e];if(null==t.t)t.t=s++;else if(t.t<n.u)return;return n(o.event?o.event(t):t)}}}function L(e,t,n,r,i,u,a,l,c,f){var s,p,d,y,v,m,b,O,P,E,j,A,T,R,I,D,C,M=t.type;if(void 0!==t.constructor)return null;128&n.__u&&(c=!!(32&n.__u),u=[l=t.__e=n.__e]),(s=o.__b)&&s(t);e:if("function"==typeof M)try{if(O=t.props,P="prototype"in M&&M.prototype.render,E=(s=M.contextType)&&r[s.__c],j=s?E?E.props.value:s.__:r,n.__c?b=(p=t.__c=n.__c).__=p.__E:(P?t.__c=p=new M(O,j):(t.__c=p=new w(O,j),p.constructor=M,p.render=G),E&&E.sub(p),p.state||(p.state={}),p.__n=r,d=p.__d=!0,p.__h=[],p._sb=[]),P&&null==p.__s&&(p.__s=p.state),P&&null!=M.getDerivedStateFromProps&&(p.__s==p.state&&(p.__s=_({},p.__s)),_(p.__s,M.getDerivedStateFromProps(O,p.__s))),y=p.props,v=p.state,p.__v=t,d)P&&null==M.getDerivedStateFromProps&&null!=p.componentWillMount&&p.componentWillMount(),P&&null!=p.componentDidMount&&p.__h.push(p.componentDidMount);else{if(P&&null==M.getDerivedStateFromProps&&O!==y&&null!=p.componentWillReceiveProps&&p.componentWillReceiveProps(O,j),t.__v==n.__v||!p.__e&&null!=p.shouldComponentUpdate&&!1===p.shouldComponentUpdate(O,p.__s,j)){for(t.__v!=n.__v&&(p.props=O,p.state=p.__s,p.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(e){e&&(e.__=t)}),A=0;A<p._sb.length;A++)p.__h.push(p._sb[A]);p._sb=[],p.__h.length&&a.push(p);break e}null!=p.componentWillUpdate&&p.componentWillUpdate(O,p.__s,j),P&&null!=p.componentDidUpdate&&p.__h.push(function(){p.componentDidUpdate(y,v,m)})}if(p.context=j,p.props=O,p.__P=e,p.__e=!1,T=o.__r,R=0,P){for(p.state=p.__s,p.__d=!1,T&&T(t),s=p.render(p.props,p.state,p.context),I=0;I<p._sb.length;I++)p.__h.push(p._sb[I]);p._sb=[]}else do{p.__d=!1,T&&T(t),s=p.render(p.props,p.state,p.context),p.state=p.__s}while(p.__d&&++R<25);p.state=p.__s,null!=p.getChildContext&&(r=_(_({},r),p.getChildContext())),P&&!d&&null!=p.getSnapshotBeforeUpdate&&(m=p.getSnapshotBeforeUpdate(y,v)),D=s,null!=s&&s.type===S&&null==s.key&&(D=H(s.props.children)),l=k(e,h(D)?D:[D],t,n,r,i,u,a,l,c,f),p.base=t.__e,t.__u&=-161,p.__h.length&&a.push(p),b&&(p.__E=p.__=null)}catch(e){if(t.__v=null,c||null!=u)if(e.then){for(t.__u|=c?160:128;l&&8==l.nodeType&&l.nextSibling;)l=l.nextSibling;u[u.indexOf(l)]=null,t.__e=l}else{for(C=u.length;C--;)g(u[C]);B(t)}else t.__e=n.__e,t.__k=n.__k,e.then||B(t);o.__e(e,t,n)}else null==u&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):l=t.__e=F(n.__e,t,n,r,i,u,a,c,f);return(s=o.diffed)&&s(t),128&t.__u?void 0:l}function B(e){e&&e.__c&&(e.__c.__e=!0),e&&e.__k&&e.__k.forEach(B)}function U(e,t,n){for(var r=0;r<n.length;r++)z(n[r],n[++r],n[++r]);o.__c&&o.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){o.__e(e,t.__v)}})}function H(e){return"object"!=typeof e||null==e||e.__b&&e.__b>0?e:h(e)?e.map(H):_({},e)}function F(e,t,n,i,u,a,l,c,f){var s,p,d,y,m,b,_,O=n.props||v,P=t.props,S=t.type;if("svg"==S?u="http://www.w3.org/2000/svg":"math"==S?u="http://www.w3.org/1998/Math/MathML":u||(u="http://www.w3.org/1999/xhtml"),null!=a)for(s=0;s<a.length;s++)if((m=a[s])&&"setAttribute"in m==!!S&&(S?m.localName==S:3==m.nodeType)){e=m,a[s]=null;break}if(null==e){if(null==S)return document.createTextNode(P);e=document.createElementNS(u,S,P.is&&P),c&&(o.__m&&o.__m(t,a),c=!1),a=null}if(null==S)O===P||c&&e.data==P||(e.data=P);else{if(a=a&&r.call(e.childNodes),!c&&null!=a)for(O={},s=0;s<e.attributes.length;s++)O[(m=e.attributes[s]).name]=m.value;for(s in O)if(m=O[s],"children"==s);else if("dangerouslySetInnerHTML"==s)d=m;else if(!(s in P)){if("value"==s&&"defaultValue"in P||"checked"==s&&"defaultChecked"in P)continue;x(e,s,null,m,u)}for(s in P)m=P[s],"children"==s?y=m:"dangerouslySetInnerHTML"==s?p=m:"value"==s?b=m:"checked"==s?_=m:c&&"function"!=typeof m||O[s]===m||x(e,s,m,O[s],u);if(p)c||d&&(p.__html==d.__html||p.__html==e.innerHTML)||(e.innerHTML=p.__html),t.__k=[];else if(d&&(e.innerHTML=""),k("template"==t.type?e.content:e,h(y)?y:[y],t,n,i,"foreignObject"==S?"http://www.w3.org/1999/xhtml":u,a,l,a?a[0]:n.__k&&E(n,0),c,f),null!=a)for(s=a.length;s--;)g(a[s]);c||(s="value","progress"==S&&null==b?e.removeAttribute("value"):null!=b&&(b!==e[s]||"progress"==S&&!b||"option"==S&&b!=O[s])&&x(e,s,b,O[s],u),s="checked",null!=_&&_!=e[s]&&x(e,s,_,O[s],u))}return e}function z(e,t,n){try{if("function"==typeof e){var r="function"==typeof e.__u;r&&e.__u(),r&&null==t||(e.__u=e(t))}else e.current=t}catch(e){o.__e(e,n)}}function q(e,t,n){var r,i;if(o.unmount&&o.unmount(e),(r=e.ref)&&(r.current&&r.current!=e.__e||z(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){o.__e(e,t)}r.base=r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&q(r[i],t,n||"function"!=typeof e.type);n||g(e.__e),e.__c=e.__=e.__e=void 0}function G(e,t,n){return this.constructor(e,n)}function W(e,t,n){var i,u,a,l;t==document&&(t=document.documentElement),o.__&&o.__(e,t),u=(i="function"==typeof n)?null:n&&n.__k||t.__k,a=[],l=[],L(t,e=(!i&&n||t).__k=O(S,null,[e]),u||v,v,t.namespaceURI,!i&&n?[n]:u?null:t.firstChild?r.call(t.childNodes):null,a,!i&&n?n:u?u.__e:t.firstChild,i,l),U(a,e,l)}function V(e,t){W(e,t,V)}function K(e,t,n){var o,i,u,a,l=_({},e.props);for(u in e.type&&e.type.defaultProps&&(a=e.type.defaultProps),t)"key"==u?o=t[u]:"ref"==u?i=t[u]:l[u]=void 0===t[u]&&null!=a?a[u]:t[u];return arguments.length>2&&(l.children=arguments.length>3?r.call(arguments,2):n),P(e.type,l,o||e.key,i||e.ref,null)}function Z(e){function t(e){var n,r;return this.getChildContext||(n=new Set,(r={})[t.__c]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(e){this.props.value!=e.value&&n.forEach(function(e){e.__e=!0,A(e)})},this.sub=function(e){n.add(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n&&n.delete(e),t&&t.call(e)}}),e.children}return t.__c="__cC"+y++,t.__=e,t.Provider=t.__l=(t.Consumer=function(e,t){return e.children(t)}).contextType=t,t}r=m.slice,o={__e:function(e,t,n,r){for(var o,i,u;t=t.__;)if((o=t.__c)&&!o.__)try{if((i=o.constructor)&&null!=i.getDerivedStateFromError&&(o.setState(i.getDerivedStateFromError(e)),u=o.__d),null!=o.componentDidCatch&&(o.componentDidCatch(e,r||{}),u=o.__d),u)return o.__E=o}catch(t){e=t}throw e}},i=0,w.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!=this.state?this.__s:this.__s=_({},this.state),"function"==typeof e&&(e=e(_({},n),this.props)),e&&_(n,e),null!=e&&this.__v&&(t&&this._sb.push(t),A(this))},w.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),A(this))},w.prototype.render=S,u=[],l="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,c=function(e,t){return e.__v.__b-t.__v.__b},T.__r=0,f=/(PointerCapture)$|Capture$/i,s=0,p=N(!1),d=N(!0),y=0;var $,Y,X,J,Q=0,ee=[],te=o,ne=te.__b,re=te.__r,oe=te.diffed,ie=te.__c,ue=te.unmount,ae=te.__;function le(e,t){te.__h&&te.__h(Y,e,Q||t),Q=0;var n=Y.__H||(Y.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function ce(e){return Q=1,fe(je,e)}function fe(e,t,n){var r=le($++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):je(void 0,t),function(e){var t=r.__N?r.__N[0]:r.__[0],n=r.t(t,e);t!==n&&(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=Y,!Y.__f)){var o=function(e,t,n){if(!r.__c.__H)return!0;var o=r.__c.__H.__.filter(function(e){return!!e.__c});if(o.every(function(e){return!e.__N}))return!i||i.call(this,e,t,n);var u=r.__c.props!==e;return o.forEach(function(e){if(e.__N){var t=e.__[0];e.__=e.__N,e.__N=void 0,t!==e.__[0]&&(u=!0)}}),i&&i.call(this,e,t,n)||u};Y.__f=!0;var i=Y.shouldComponentUpdate,u=Y.componentWillUpdate;Y.componentWillUpdate=function(e,t,n){if(this.__e){var r=i;i=void 0,o(e,t,n),i=r}u&&u.call(this,e,t,n)},Y.shouldComponentUpdate=o}return r.__N||r.__}function se(e,t){var n=le($++,3);!te.__s&&Ee(n.__H,t)&&(n.__=e,n.u=t,Y.__H.__h.push(n))}function pe(e,t){var n=le($++,4);!te.__s&&Ee(n.__H,t)&&(n.__=e,n.u=t,Y.__h.push(n))}function de(e){return Q=5,ve(function(){return{current:e}},[])}function ye(e,t,n){Q=6,pe(function(){if("function"==typeof e){var n=e(t());return function(){e(null),n&&"function"==typeof n&&n()}}if(e)return e.current=t(),function(){return e.current=null}},null==n?n:n.concat(e))}function ve(e,t){var n=le($++,7);return Ee(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function me(e,t){return Q=8,ve(function(){return e},t)}function be(e){var t=Y.context[e.__c],n=le($++,9);return n.c=e,t?(null==n.__&&(n.__=!0,t.sub(Y)),t.props.value):e.__}function he(e,t){te.useDebugValue&&te.useDebugValue(t?t(e):e)}function _e(){var e=le($++,11);if(!e.__){for(var t=Y.__v;null!==t&&!t.__m&&null!==t.__;)t=t.__;var n=t.__m||(t.__m=[0,0]);e.__="P"+n[0]+"-"+n[1]++}return e.__}function ge(){for(var e;e=ee.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Se),e.__H.__h.forEach(we),e.__H.__h=[]}catch(t){e.__H.__h=[],te.__e(t,e.__v)}}te.__b=function(e){Y=null,ne&&ne(e)},te.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),ae&&ae(e,t)},te.__r=function(e){re&&re(e),$=0;var t=(Y=e.__c).__H;t&&(X===Y?(t.__h=[],Y.__h=[],t.__.forEach(function(e){e.__N&&(e.__=e.__N),e.u=e.__N=void 0})):(t.__h.forEach(Se),t.__h.forEach(we),t.__h=[],$=0)),X=Y},te.diffed=function(e){oe&&oe(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(1!==ee.push(t)&&J===te.requestAnimationFrame||((J=te.requestAnimationFrame)||Pe)(ge)),t.__H.__.forEach(function(e){e.u&&(e.__H=e.u),e.u=void 0})),X=Y=null},te.__c=function(e,t){t.some(function(e){try{e.__h.forEach(Se),e.__h=e.__h.filter(function(e){return!e.__||we(e)})}catch(n){t.some(function(e){e.__h&&(e.__h=[])}),t=[],te.__e(n,e.__v)}}),ie&&ie(e,t)},te.unmount=function(e){ue&&ue(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(e){try{Se(e)}catch(e){t=e}}),n.__H=void 0,t&&te.__e(t,n.__v))};var Oe="function"==typeof requestAnimationFrame;function Pe(e){var t,n=function(){clearTimeout(r),Oe&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,35);Oe&&(t=requestAnimationFrame(n))}function Se(e){var t=Y,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),Y=t}function we(e){var t=Y;e.__c=e.__(),Y=t}function Ee(e,t){return!e||e.length!==t.length||t.some(function(t,n){return t!==e[n]})}function je(e,t){return"function"==typeof t?t(e):t}function Ae(e,t){for(var n in t)e[n]=t[n];return e}function Te(e,t){for(var n in e)if("__source"!==n&&!(n in t))return!0;for(var r in t)if("__source"!==r&&e[r]!==t[r])return!0;return!1}function ke(e,t){var n=t(),r=ce({t:{__:n,u:t}}),o=r[0].t,i=r[1];return pe(function(){o.__=n,o.u=t,Re(o)&&i({t:o})},[e,n,t]),se(function(){return Re(o)&&i({t:o}),e(function(){Re(o)&&i({t:o})})},[e]),n}function Re(e){var t,n,r=e.u,o=e.__;try{var i=r();return!((t=o)===(n=i)&&(0!==t||1/t==1/n)||t!=t&&n!=n)}catch(e){return!0}}function Ie(e){e()}function De(e){return e}function Ce(){return[!1,Ie]}var Me=pe;function xe(e,t){this.props=e,this.context=t}(xe.prototype=new w).isPureReactComponent=!0,xe.prototype.shouldComponentUpdate=function(e,t){return Te(this.props,e)||Te(this.state,t)};var Ne=o.__b;o.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Ne&&Ne(e)};var Le="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911,Be=function(e,t){return null==e?null:D(D(e).map(t))},Ue={map:Be,forEach:Be,count:function(e){return e?D(e).length:0},only:function(e){var t=D(e);if(1!==t.length)throw"Children.only";return t[0]},toArray:D},He=o.__e;o.__e=function(e,t,n,r){if(e.then)for(var o,i=t;i=i.__;)if((o=i.__c)&&o.__c)return null==t.__e&&(t.__e=n.__e,t.__k=n.__k),o.__c(e,t);He(e,t,n,r)};var Fe=o.unmount;function ze(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(e){"function"==typeof e.__c&&e.__c()}),e.__c.__H=null),null!=(e=Ae({},e)).__c&&(e.__c.__P===n&&(e.__c.__P=t),e.__c.__e=!0,e.__c=null),e.__k=e.__k&&e.__k.map(function(e){return ze(e,t,n)})),e}function qe(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(e){return qe(e,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=!0,e.__c.__P=n)),e}function Ge(){this.__u=0,this.o=null,this.__b=null}function We(e){if(!e.__)return null;var t=e.__.__c;return t&&t.__a&&t.__a(e)}function Ve(){this.i=null,this.l=null}o.unmount=function(e){var t=e.__c;t&&(t.__z=!0),t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),Fe&&Fe(e)},(Ge.prototype=new w).__c=function(e,t){var n=t.__c,r=this;null==r.o&&(r.o=[]),r.o.push(n);var o=We(r.__v),i=!1,u=function(){i||r.__z||(i=!0,n.__R=null,o?o(l):l())};n.__R=u;var a=n.__P;n.__P=null;var l=function(){if(! --r.__u){if(r.state.__a){var e=r.state.__a;r.__v.__k[0]=qe(e,e.__c.__P,e.__c.__O)}var t;for(r.setState({__a:r.__b=null});t=r.o.pop();)t.__P=a,t.forceUpdate()}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(u,u)},Ge.prototype.componentWillUnmount=function(){this.o=[]},Ge.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=ze(this.__b,n,r.__O=r.__P)}this.__b=null}var o=t.__a&&O(S,null,e.fallback);return o&&(o.__u&=-33),[O(S,null,t.__a?null:e.children),o]};var Ke=function(e,t,n){if(++n[1]===n[0]&&e.l.delete(t),e.props.revealOrder&&("t"!==e.props.revealOrder[0]||!e.l.size))for(n=e.i;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.i=n=n[2]}};function Ze(e){return this.getChildContext=function(){return e.context},e.children}function $e(e){var t=this,n=e.h;if(t.componentWillUnmount=function(){W(null,t.v),t.v=null,t.h=null},t.h&&t.h!==n&&t.componentWillUnmount(),!t.v){for(var r=t.__v;null!==r&&!r.__m&&null!==r.__;)r=r.__;t.h=n,t.v={nodeType:1,parentNode:n,childNodes:[],__k:{__m:r.__m},contains:function(){return!0},namespaceURI:n.namespaceURI,insertBefore:function(e,n){this.childNodes.push(e),t.h.insertBefore(e,n)},removeChild:function(e){this.childNodes.splice(this.childNodes.indexOf(e)>>>1,1),t.h.removeChild(e)}}}W(O(Ze,{context:t.context},e.__v),t.v)}function Ye(e,t){var n=O($e,{__v:e,h:t});return n.containerInfo=t,n}(Ve.prototype=new w).__a=function(e){var t=this,n=We(t.__v),r=t.l.get(e);return r[0]++,function(o){var i=function(){t.props.revealOrder?(r.push(o),Ke(t,e,r)):o()};n?n(i):i()}},Ve.prototype.render=function(e){this.i=null,this.l=new Map;var t=D(e.children);e.revealOrder&&"b"===e.revealOrder[0]&&t.reverse();for(var n=t.length;n--;)this.l.set(t[n],this.i=[1,0,this.i]);return e.children},Ve.prototype.componentDidUpdate=Ve.prototype.componentDidMount=function(){var e=this;this.l.forEach(function(t,n){Ke(e,n,t)})};var Xe="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,Je=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,Qe=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,et=/[A-Z0-9]/g,tt="undefined"!=typeof document,nt=function(e){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(e)};function rt(e,t,n){return null==t.__k&&(t.textContent=""),W(e,t),"function"==typeof n&&n(),e?e.__c:null}w.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(w.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var ot=o.event;function it(){}function ut(){return this.cancelBubble}function at(){return this.defaultPrevented}o.event=function(e){return ot&&(e=ot(e)),e.persist=it,e.isPropagationStopped=ut,e.isDefaultPrevented=at,e.nativeEvent=e};var lt,ct={enumerable:!1,configurable:!0,get:function(){return this.class}},ft=o.vnode;o.vnode=function(e){"string"==typeof e.type&&function(e){var t=e.props,n=e.type,r={},o=-1===n.indexOf("-");for(var i in t){var u=t[i];if(!("value"===i&&"defaultValue"in t&&null==u||tt&&"children"===i&&"noscript"===n||"class"===i||"className"===i)){var a=i.toLowerCase();"defaultValue"===i&&"value"in t&&null==t.value?i="value":"download"===i&&!0===u?u="":"translate"===a&&"no"===u?u=!1:"o"===a[0]&&"n"===a[1]?"ondoubleclick"===a?i="ondblclick":"onchange"!==a||"input"!==n&&"textarea"!==n||nt(t.type)?"onfocus"===a?i="onfocusin":"onblur"===a?i="onfocusout":Qe.test(i)&&(i=a):a=i="oninput":o&&Je.test(i)?i=i.replace(et,"-$&").toLowerCase():null===u&&(u=void 0),"oninput"===a&&r[i=a]&&(i="oninputCapture"),r[i]=u}}"select"==n&&r.multiple&&Array.isArray(r.value)&&(r.value=D(t.children).forEach(function(e){e.props.selected=-1!=r.value.indexOf(e.props.value)})),"select"==n&&null!=r.defaultValue&&(r.value=D(t.children).forEach(function(e){e.props.selected=r.multiple?-1!=r.defaultValue.indexOf(e.props.value):r.defaultValue==e.props.value})),t.class&&!t.className?(r.class=t.class,Object.defineProperty(r,"className",ct)):(t.className&&!t.class||t.class&&t.className)&&(r.class=r.className=t.className),e.props=r}(e),e.$$typeof=Xe,ft&&ft(e)};var st=o.__r;o.__r=function(e){st&&st(e),lt=e.__c};var pt=o.diffed;o.diffed=function(e){pt&&pt(e);var t=e.props,n=e.__e;null!=n&&"textarea"===e.type&&"value"in t&&t.value!==n.value&&(n.value=null==t.value?"":t.value),lt=null};var dt={ReactCurrentDispatcher:{current:{readContext:function(e){return lt.__n[e.__c].props.value},useCallback:me,useContext:be,useDebugValue:he,useDeferredValue:De,useEffect:se,useId:_e,useImperativeHandle:ye,useInsertionEffect:Me,useLayoutEffect:pe,useMemo:ve,useReducer:fe,useRef:de,useState:ce,useSyncExternalStore:ke,useTransition:Ce}}};function yt(e){return!!e&&e.$$typeof===Xe}function vt(e){return yt(e)?K.apply(null,arguments):e}function mt(e){return!!e.__k&&(W(null,e),!0)}var bt={useState:ce,useId:_e,useReducer:fe,useEffect:se,useLayoutEffect:pe,useInsertionEffect:Me,useTransition:Ce,useDeferredValue:De,useSyncExternalStore:ke,startTransition:Ie,useRef:de,useImperativeHandle:ye,useMemo:ve,useCallback:me,useContext:be,useDebugValue:he,version:"18.3.1",Children:Ue,render:rt,hydrate:function(e,t,n){return V(e,t),"function"==typeof n&&n(),e?e.__c:null},unmountComponentAtNode:mt,createPortal:Ye,createElement:O,createContext:Z,createFactory:function(e){return O.bind(null,e)},cloneElement:vt,createRef:function(){return{current:null}},Fragment:S,isValidElement:yt,isElement:yt,isFragment:function(e){return yt(e)&&e.type===S},isMemo:function(e){return!!e&&!!e.displayName&&("string"==typeof e.displayName||e.displayName instanceof String)&&e.displayName.startsWith("Memo(")},findDOMNode:function(e){return e&&(e.base||1===e.nodeType&&e)||null},Component:w,PureComponent:xe,memo:function(e,t){function n(e){var n=this.props.ref,r=n==e.ref;return!r&&n&&(n.call?n(null):n.current=null),t?!t(this.props,e)||!r:Te(this.props,e)}function r(t){return this.shouldComponentUpdate=n,O(e,t)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r.type=e,r},forwardRef:function(e){function t(t){var n=Ae({},t);return delete n.ref,e(n,t.ref||null)}return t.$$typeof=Le,t.render=e,t.prototype.isReactComponent=t.__f=!0,t.displayName="ForwardRef("+(e.displayName||e.name)+")",t},flushSync:function(e,t){return e(t)},unstable_batchedUpdates:function(e,t){return e(t)},StrictMode:S,Suspense:Ge,SuspenseList:Ve,lazy:function(e){var t,n,r,o=null;function i(i){if(t||(t=e()).then(function(e){e&&(o=e.default||e),r=!0},function(e){n=e,r=!0}),n)throw n;if(!r)throw t;return o?O(o,i):null}return i.displayName="Lazy",i.__f=!0,i},__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:dt};function ht(e){return{render:function(t){rt(t,e)},unmount:function(){mt(e)}}}var _t=n("./src/config/events.js"),gt=Z(null);function Ot(){return be(gt)}var Pt=[{id:"showKeyboardHelp",group:"General",title:"Show keyboard help",command:"<kbd>Alt</kbd> + <kbd>K</kbd>",enabled:!0},{id:"selectControl",group:"General",title:"Select a map control",command:"<kbd>Tab</kbd> or <kbd>Shift</kbd> + <kbd>Tab</kbd>",enabled:!0},{id:"moveLarge",group:"Navigation",title:"Move in large steps",command:"<kbd>←</kbd>, <kbd>↑</kbd>, <kbd>→</kbd> or <kbd>↓</kbd>",enabled:!0},{id:"nudgeMap",group:"Navigation",title:"Nudge map",command:"<kbd>Shift</kbd> + <kbd>←</kbd>, <kbd>↑</kbd>, <kbd>→</kbd> or <kbd>↓</kbd>",enabled:!1},{id:"zoomLarge",group:"Navigation",title:"Zoom in large steps",command:"<kbd>+</kbd> or <kbd>-</kbd>",enabled:!0},{id:"nudgeZoom",group:"Navigation",title:"Nudge zoom",command:"<kbd>Shift</kbd> + <kbd>+</kbd> or <kbd>-</kbd>",enabled:!1},{id:"highlightLabelAtCenter",group:"Labels",title:"Highlight label at centre",command:"<kbd>Alt</kbd> + <kbd>Enter</kbd>",enabled:!1,requiredConfig:["readMapText"]},{id:"highlightNextLabel",group:"Labels",title:"Highlight nearby label",command:"<kbd>Alt</kbd> + <kbd>→</kbd>, <kbd>←</kbd>, <kbd>↑</kbd> or <kbd>↓</kbd>",enabled:!1,requiredConfig:["readMapText"]}];function St(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var wt=[],Et=new Set,jt=new Set,At=function(){jt=new Set(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[])},Tt=0;function kt(e,t,n,r,i,u){t||(t={});var a,l,c=t;if("ref"in c)for(l in c={},t)"ref"==l?a=t[l]:c[l]=t[l];var f={type:e,props:c,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--Tt,__i:-1,__u:0,__source:i,__self:u};if("function"==typeof e&&(a=e.defaultProps))for(l in a)void 0===c[l]&&(c[l]=a[l]);return o.vnode&&o.vnode(f),f}function Rt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}Array.isArray;var It=function(){var e=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Pt.filter(function(t){return!!jt.has(t.id)&&(!t.requiredConfig||t.requiredConfig.every(function(t){return e[t]}))});return[].concat(function(e){return function(e){if(Array.isArray(e))return St(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return St(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?St(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t),wt)}(Ot()).reduce(function(e,t){return e[t.group]=e[t.group]||[],e[t.group].push(t),e},{});return kt("div",{className:"im-c-keyboard-help",children:Object.entries(e).map(function(e){var t=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Rt(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Rt(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e,2),n=t[0];return kt("div",{className:"im-c-keyboard-help__group",children:kt("dl",{className:"im-c-keyboard-help__list",children:t[1].map(function(e){return kt("div",{className:"im-c-keyboard-help__item",children:[kt("dt",{className:"im-c-keyboard-help__title",children:e.title}),kt("dd",{className:"im-c-keyboard-help__description",dangerouslySetInnerHTML:{__html:e.command}})]},e.id)})})},n)})})};function Dt(e){return Dt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Dt(e)}function Ct(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Mt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ct(Object(n),!0).forEach(function(t){xt(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ct(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function xt(e,t,n){return(t=function(e){var t=function(e){if("object"!=Dt(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Dt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Dt(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Nt={slot:"middle",initiallyOpen:!1,dismissable:!0,modal:!0},Lt={slot:"right-top",showLabel:!1},Bt={slot:"top-left",showLabel:!1},Ut={buttons:[{id:"exit",label:"Exit",iconId:"close",onClick:function(e,t){return t.services.closeApp()},excludeWhen:function(e){var t=e.appConfig,n=e.appState;return!t.hasExitButton||!(n.isFullscreen&&new URL(window.location.href).searchParams.has(t.mapViewParamKey))},mobile:Bt,tablet:Bt,desktop:Bt},{id:"fullscreen",label:function(){return"".concat(document.fullscreenElement?"Exit":"Enter"," fullscreen")},iconId:function(){return document.fullscreenElement?"minimise":"maximise"},onClick:function(e,t){var n=t.appState.layoutRefs.appContainerRef.current;document.fullscreenElement?document.exitFullscreen():n.requestFullscreen()},excludeWhen:function(e){var t=e.appState;return!e.appConfig.enableFullscreen||t.isFullscreen},mobile:Lt,tablet:Lt,desktop:Lt},{id:"zoomIn",group:"zoom",label:"Zoom in",iconId:"plus",onClick:function(e,t){var n=t.mapProvider,r=t.appConfig;return n.zoomIn(r.zoomDelta)},excludeWhen:function(e){var t=e.appState;return!e.appConfig.enableZoomControls||"touch"===t.interfaceType},enableWhen:function(e){return!e.mapState.isAtMaxZoom},mobile:Lt,tablet:Lt,desktop:Lt},{id:"zoomOut",group:"zoom",label:"Zoom out",iconId:"minus",onClick:function(e,t){var n=t.mapProvider,r=t.appConfig;return n.zoomOut(r.zoomDelta)},excludeWhen:function(e){var t=e.appState;return!e.appConfig.enableZoomControls||"touch"===t.interfaceType},enableWhen:function(e){return!e.mapState.isAtMinZoom},mobile:Lt,tablet:Lt,desktop:Lt}],panels:[{id:"keyboardHelp",label:"Keyboard shortcuts",mobile:Mt({},Nt),tablet:Mt(Mt({},Nt),{},{width:"500px"}),desktop:Mt(Mt({},Nt),{},{width:"500px"}),render:function(){return kt(It,{})}}],icons:[{id:"maximise",svgContent:'<path d="M15 3h6v6"/><path d="m21 3-7 7"/><path d="m3 21 7-7"/><path d="M9 21H3v-6"/>'},{id:"minimise",svgContent:'<path d="m14 10 7-7"/><path d="M20 10h-6V4"/><path d="m3 21 7-7"/><path d="M4 14h6v6"/>'},{id:"plus",svgContent:'<path d="M5 12h14"/><path d="M12 5v14"/>'},{id:"minus",svgContent:'<path d="M5 12h14"/>'}]},Ht={slot:"right-top",showLabel:!1},Ft={label:"Button",mobile:Ht,tablet:Ht,desktop:Ht},zt={showLabel:!0,label:"Panel",mobile:{slot:"bottom",initiallyOpen:!0,dismissable:!0,modal:!1},tablet:{slot:"inset",initiallyOpen:!0,dismissable:!0,modal:!1},desktop:{slot:"inset",initiallyOpen:!0,dismissable:!0,modal:!1},render:null,html:null},qt={label:"Control",mobile:{slot:"bottom"},tablet:{slot:"inset"},desktop:{slot:"inset"}},Gt={small:1,medium:1.5,large:2},Wt=[{shape:"pin",backgroundPath:"M31 16.001c0 7.489-8.308 15.289-11.098 17.698-.533.4-1.271.4-1.803 0C15.309 31.29 7 23.49 7 16.001c0-6.583 5.417-12 12-12s12 5.417 12 12z",graphicPath:"M19 11.001c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.241 5-5-2.24-5-5-5z"}];function Vt(e){return Vt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Vt(e)}function Kt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Zt(e,t,n){return(t=function(e){var t=function(e){if("object"!=Vt(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Vt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Vt(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var $t=function(e,t){var n=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Kt(Object(n),!0).forEach(function(t){Zt(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Kt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({},e);for(var r in t)"object"!==Vt(t[r])||Array.isArray(t[r])||null===t[r]?n[r]=t[r]:n[r]=$t(e[r]||{},t[r]);return n};function Yt(e){return Yt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Yt(e)}function Xt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Jt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Qt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jt(Object(n),!0).forEach(function(t){en(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function en(e,t,n){return(t=function(e){var t=function(e){if("object"!=Yt(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Yt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Yt(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var tn=function(e,t){return Qt(Qt({},e),t)},nn=function(e,t,n){var r=$t(Ft,n);return Qt(Qt({},e),{},en({},t,r))};function rn(){var e={};return{registerButton:function(t){e=tn(e,t)},addButton:function(t,n){return e=nn(e,t,n),t},getButtonConfig:function(t){return function(e,t){return t?Object.fromEntries(Object.entries(e).filter(function(e){var n=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Xt(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Xt(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e,2);return n[0],n[1].pluginId===t})):e}(e,t)},clear:function(){e={}}}}function on(e){return on="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},on(e)}function un(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function an(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?un(Object(n),!0).forEach(function(t){ln(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):un(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ln(e,t,n){return(t=cn(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cn(e){var t=function(e){if("object"!=on(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=on(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==on(t)?t:t+""}function fn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var sn=function(e,t){var n=Object.fromEntries(Object.entries(t).map(function(e){var t=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return fn(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?fn(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e,2);return[t[0],an({showLabel:!0},t[1])]}));return an(an({},e),n)},pn=function(e,t,n){var r=$t(zt,n);return an(an({},e),{},ln({},t,an(an({},r),{},{html:r.html,render:r.render})))},dn=function(e,t){e[t];var n=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,[t].map(cn));return n};function yn(e){return yn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yn(e)}function vn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function mn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vn(Object(n),!0).forEach(function(t){bn(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vn(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function bn(e,t,n){return(t=function(e){var t=function(e){if("object"!=yn(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=yn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==yn(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var hn=function(e,t){return mn(mn({},e),t)},_n=function(e,t,n){var r=$t(qt,n);return mn(mn({},e),{},bn({},t,mn({id:t},r)))};function gn(e){return gn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},gn(e)}function On(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Pn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?On(Object(n),!0).forEach(function(t){Sn(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):On(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Sn(e,t,n){return(t=function(e){var t=function(e){if("object"!=gn(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=gn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==gn(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var wn={close:'<path d="M18 6 6 18"/><path d="m6 6 12 12"/>'},En=function(){return wn};function jn(e){return jn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},jn(e)}function An(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Tn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?An(Object(n),!0).forEach(function(t){kn(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):An(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function kn(e,t,n){return(t=function(e){var t=function(e){if("object"!=jn(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=jn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==jn(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Rn=function(e){return Array.isArray(e)?e:[e]};function In(e){return In="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},In(e)}function Dn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Cn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Dn(Object(n),!0).forEach(function(t){Mn(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dn(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Mn(e,t,n){return(t=function(e){var t=function(e){if("object"!=In(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=In(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==In(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];Array.isArray(e)||(e=[]),Array.isArray(t)||(t=[]);var n=new Map(e.map(function(e){return[e.id,e]}));return t.forEach(function(e){null!=e&&e.id&&(n.has(e.id)?n.set(e.id,Cn(Cn({},n.get(e.id)),e)):n.set(e.id,e))}),Array.from(n.values())},r=Cn(Cn({},e),t);return(e.buttons||t.buttons)&&(r.buttons=n(e.buttons,t.buttons)),(e.panels||t.panels)&&(r.panels=n(e.panels,t.panels)),(e.controls||t.controls)&&(r.controls=n(e.controls,t.controls)),(e.icons||t.icons)&&(r.icons=n(e.icons,t.icons)),r}function Nn(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r={};return Object.keys(e).forEach(function(o){var i,u=e[o][t];null!==(i=null==u?void 0:u.initiallyOpen)&&void 0!==i&&i&&(r[o]=n[o]||{props:{}})}),r}var Ln=n("./src/utils/getIsFullscreen.js");function Bn(e){return Bn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Bn(e)}function Un(e){return Un="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Un(e)}function Hn(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function Fn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function zn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fn(Object(n),!0).forEach(function(t){qn(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fn(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function qn(e,t,n){return(t=Gn(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gn(e){var t=function(e){if("object"!=Un(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Un(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Un(t)?t:t+""}function Wn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Vn(e,t,n,r){var o,i=e.panelConfig||e.panelRegistry.getPanelConfig(),u=null===(o=i[t])||void 0===o?void 0:o[n],a=!!u.exclusive&&!u.modal,l=!!u.modal,c=Object.fromEntries(Object.entries(e.openPanels).filter(function(e){var t,r=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Wn(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Wn(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e,1)[0];return!(null!==(t=i[r])&&void 0!==t&&null!==(t=t[n])&&void 0!==t&&t.exclusive)}));return zn(zn(zn({},a?{}:c),l?e.openPanels:{}),{},qn({},t,{props:r}))}var Kn={SET_BREAKPOINT:function(e,t){var n,r=t.behaviour,o=t.hybridWidth,i=t.maxMobileWidth,u=Object.keys(e.openPanels).at(-1),a="hybrid"===r?e.isFullscreen:(0,Ln.g)({behaviour:r,hybridWidth:o,maxMobileWidth:i});return zn(zn({},e),{},{breakpoint:t.breakpoint,isFullscreen:a,previousOpenPanels:e.openPanels,openPanels:u?Vn(e,u,t.breakpoint,(null===(n=e.openPanels[u])||void 0===n?void 0:n.props)||{}):{}})},SET_MEDIA:function(e,t){return zn(zn({},e),t)},SET_HYBRID_FULLSCREEN:function(e,t){return zn(zn({},e),{},{isFullscreen:t})},SET_INTERFACE_TYPE:function(e,t){return e.interfaceType===t?e:zn(zn({},e),{},{interfaceType:t})},SET_MODE:function(e,t){var n=e.panelConfig||e.panelRegistry.getPanelConfig();return zn(zn({},e),{},{mode:t,previousMode:e.mode,openPanels:Nn(n,e.breakpoint,e.openPanels)})},SET_SAFE_ZONE_INSET:function(e,t){var n=t.safeZoneInset,r=t.syncMapPadding,o=void 0===r||r;return function(e,t){if(e===t)return!0;if(!e||!t||"object"!==Bn(e)||"object"!==Bn(t))return!1;var n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every(function(n){return Object.is(e[n],t[n])})}(e.safeZoneInset,n)?e:zn(zn({},e),{},{safeZoneInset:n,syncMapPadding:o,isLayoutReady:!0})},REVERT_MODE:function(e){var t=e.panelConfig||e.panelRegistry.getPanelConfig();return zn(zn({},e),{},{mode:e.previousMode,previousMode:e.mode,openPanels:Nn(t,e.breakpoint,e.openPanels)})},OPEN_PANEL:function(e,t){var n=t.panelId,r=t.props,o=void 0===r?{}:r;return zn(zn({},e),{},{previousOpenPanels:e.openPanels,openPanels:Vn(e,n,e.breakpoint,o)})},CLOSE_PANEL:function(e,t){var n=e.openPanels,r=(n[t],Hn(n,[t].map(Gn)));return zn(zn({},e),{},{previousOpenPanels:e.openPanels,openPanels:r})},CLOSE_ALL_PANELS:function(e){return zn(zn({},e),{},{previousOpenPanels:e.openPanels,openPanels:{}})},RESTORE_PREVIOUS_PANELS:function(e){return zn(zn({},e),{},{openPanels:e.previousOpenPanels||{},previousOpenPanels:e.openPanels})},TOGGLE_HAS_EXCLUSIVE_CONTROL:function(e,t){return zn(zn({},e),{},{hasExclusiveControl:t})},TOGGLE_BUTTON_DISABLED:function(e,t){var n=t.id,r=t.isDisabled,o=new Set(e.disabledButtons);return r?o.add(n):o.delete(n),zn(zn({},e),{},{disabledButtons:o})},TOGGLE_BUTTON_HIDDEN:function(e,t){var n=t.id,r=t.isHidden,o=new Set(e.hiddenButtons);return r?o.add(n):o.delete(n),zn(zn({},e),{},{hiddenButtons:o})},TOGGLE_BUTTON_PRESSED:function(e,t){var n=t.id,r=t.isPressed,o=new Set(e.pressedButtons);return r?o.add(n):o.delete(n),zn(zn({},e),{},{pressedButtons:o})},TOGGLE_BUTTON_EXPANDED:function(e,t){var n=t.id,r=t.isExpanded,o=new Set(e.expandedButtons);return r?o.add(n):o.delete(n),zn(zn({},e),{},{expandedButtons:o})},REGISTER_BUTTON:function(e,t){return zn(zn({},e),{},{buttonConfig:tn(e.buttonConfig,t)})},ADD_BUTTON:function(e,t){var n,r=t.id,o=t.config,i=nn(e.buttonConfig,r,o),u=new Set(e.hiddenButtons);o.isHidden&&u.add(r);var a=new Set(e.disabledButtons);o.isDisabled&&a.add(r);var l=new Set(e.pressedButtons);o.isPressed&&l.add(r);var c=new Set(e.expandedButtons);return o.isExpanded&&c.add(r),null!==(n=e.buttonRegistry)&&void 0!==n&&n.addButton&&e.buttonRegistry.addButton(r,o),zn(zn({},e),{},{buttonConfig:i,hiddenButtons:u,disabledButtons:a,pressedButtons:l,expandedButtons:c})},REGISTER_PANEL:function(e,t){return zn(zn({},e),{},{panelConfig:sn(e.panelConfig,t)})},ADD_PANEL:function(e,t){var n,r=t.id,o=t.config,i=pn(e.panelConfig,r,o),u=i[r];null!==(n=e.panelRegistry)&&void 0!==n&&n.addPanel&&e.panelRegistry.addPanel(r,o);var a=null==u?void 0:u[e.breakpoint],l=null==a?void 0:a.initiallyOpen;return zn(zn({},e),{},{panelConfig:i,openPanels:l?Vn(zn(zn({},e),{},{panelConfig:i}),r,e.breakpoint,{}):e.openPanels})},REMOVE_PANEL:function(e,t){var n,r=t,o=e.openPanels,i=(o[r],Hn(o,[r].map(Gn)));return null!==(n=e.panelRegistry)&&void 0!==n&&n.removePanel&&e.panelRegistry.removePanel(r),zn(zn({},e),{},{panelConfig:dn(e.panelConfig,r),openPanels:i})},REGISTER_CONTROL:function(e,t){return zn(zn({},e),{},{controlConfig:hn(e.controlConfig,t)})},ADD_CONTROL:function(e,t){var n,r=t.id,o=t.config,i=_n(e.controlConfig,r,o);return null!==(n=e.controlRegistry)&&void 0!==n&&n.addControl&&e.controlRegistry.addControl(r,o),zn(zn({},e),{},{controlConfig:i})}};function Zn(){return{preferredColorScheme:window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light",prefersReducedMotion:window.matchMedia("(prefers-reduced-motion: reduce)").matches}}var $n=function(e,t){var n=t.type,r=t.payload,o=Kn[n];return o?o(e,r):e};var Yn=n("./src/utils/detectInterfaceType.js");function Xn(e){return Xn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Xn(e)}function Jn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Qn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jn(Object(n),!0).forEach(function(t){er(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jn(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function er(e,t,n){return(t=function(e){var t=function(e){if("object"!=Xn(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Xn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Xn(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var nr=Z(null),rr=function(e){var t=e.options,n=e.children,r=t.pluginRegistry,o=t.buttonRegistry,i=t.panelRegistry,u=t.controlRegistry,a=t.eventBus,l=t.breakpointDetector,c={appContainerRef:de(null),sideRef:de(null),mainRef:de(null),topRef:de(null),topLeftColRef:de(null),topRightColRef:de(null),insetRef:de(null),rightRef:de(null),middleRef:de(null),bottomRef:de(null),footerRef:de(null),actionsRef:de(null),bannerRef:de(null),modalRef:de(null),viewportRef:de(null)},f=de({}),s=fe($n,function(e){var t=e.initialBreakpoint,n=e.initialInterfaceType,r=e.appColorScheme,o=e.autoColorScheme,i=e.pluginRegistry,u=e.buttonRegistry,a=e.panelRegistry,l=e.controlRegistry,c=e.mode,f=Zn(),s=f.preferredColorScheme,p=f.prefersReducedMotion,d=(0,Ln.g)(e),y=Nn(a.getPanelConfig(),t);return{isLayoutReady:!1,breakpoint:t,interfaceType:n,preferredColorScheme:o?s:r,prefersReducedMotion:p,isFullscreen:d,mode:c||null,previousMode:null,safeZoneInset:null,disabledButtons:new Set,hiddenButtons:new Set,pressedButtons:new Set,expandedButtons:new Set,hasExclusiveControl:!1,openPanels:y,previousOpenPanels:{},syncMapPadding:!0,pluginRegistry:i,buttonRegistry:u,panelRegistry:a,controlRegistry:l,buttonConfig:u.getButtonConfig(),panelConfig:a.getPanelConfig(),controlConfig:l.getControlConfig()}}(t)),p=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return tr(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?tr(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(s,2),d=p[0],y=p[1],v=me(function(e){var n=d.panelConfig||t.panelRegistry.getPanelConfig(),r=d;y(e),function(e,t,n,r){var o=e.type,i=e.payload;if("CLOSE_PANEL"===o&&queueMicrotask(function(){r.emit(_t.q.APP_PANEL_CLOSED,{panelId:i})}),"CLOSE_ALL_PANELS"===o&&queueMicrotask(function(){Object.keys(t.openPanels).forEach(function(e){r.emit(_t.q.APP_PANEL_CLOSED,{panelId:e})})}),"OPEN_PANEL"===o){var u=i.panelId,a=i.props,l=function(e,t,n,r){var o,i=null===(o=r[e])||void 0===o?void 0:o[n],u=!(null==i||!i.exclusive||null!=i&&i.modal),a=!(null==i||!i.modal),l=[];if(a)return l;var c=Object.keys(t);return u?c.forEach(function(e){var t,o=null===(t=r[e])||void 0===t?void 0:t[n];null!=o&&o.exclusive||l.push(e)}):c.forEach(function(e){var t,o=null===(t=r[e])||void 0===t?void 0:t[n];null==o||!o.exclusive||null!=o&&o.modal||l.push(e)}),l}(u,t.openPanels,t.breakpoint,n);queueMicrotask(function(){l.forEach(function(e){r.emit(_t.q.APP_PANEL_CLOSED,{panelId:e})}),r.emit(_t.q.APP_PANEL_OPENED,{panelId:u,props:a})})}}(e,r,n,a)},[d,t,a]);!function(e,t){var n=t.appColorScheme,r=t.autoColorScheme,o=t.behaviour,i=t.hybridWidth,u=t.maxMobileWidth;se(function(){var t=[window.matchMedia("(prefers-color-scheme: dark)"),window.matchMedia("(prefers-reduced-motion: reduce)")];function a(){var t=Zn(),o=t.preferredColorScheme,i=t.prefersReducedMotion;e({type:"SET_MEDIA",payload:{preferredColorScheme:r?o:n,prefersReducedMotion:i}})}t.forEach(function(e){return e.addEventListener("change",a)});var l=null,c=null;if("hybrid"===o){var f=null!=i?i:u;l=window.matchMedia("(max-width: ".concat(f,"px)")),c=function(t){e({type:"SET_HYBRID_FULLSCREEN",payload:t.matches})},l.addEventListener("change",c)}return function(){t.forEach(function(e){return e.removeEventListener("change",a)}),l&&c&&l.removeEventListener("change",c)}},[e,o,i,u])}(y,t);var m=function(e){v({type:"SET_MODE",payload:e})},b=function(){v({type:"REVERT_MODE"})};se(function(){a.on(_t.q.APP_SET_MODE,m),a.on(_t.q.APP_REVERT_MODE,b);var e=l.subscribe(function(e){v({type:"SET_BREAKPOINT",payload:{behaviour:t.behaviour,breakpoint:e,hybridWidth:t.hybridWidth,maxMobileWidth:t.maxMobileWidth}})}),n=(0,Yn.Ey)(function(e){v({type:"SET_INTERFACE_TYPE",payload:e})});return function(){a.off(_t.q.APP_SET_MODE,m),a.off(_t.q.APP_REVERT_MODE,b),e(),n()}},[]);var h=ve(function(){return Qn(Qn({},d),{},{dispatch:v,layoutRefs:c,buttonRefs:f,pluginRegistry:r,buttonRegistry:o,panelRegistry:i,controlRegistry:u})},[d,v]);return kt(gt.Provider,{value:t,children:kt(nr.Provider,{value:h,children:n})})};function or(e){return or="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},or(e)}function ir(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function ur(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ir(Object(n),!0).forEach(function(t){ar(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ir(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ar(e,t,n){return(t=function(e){var t=function(e){if("object"!=or(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=or(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==or(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var lr=function(e,t){return ur(ur({},e),t)},cr={SET_MAP_READY:function(e,t){return ur(ur({},e),{},{isMapReady:!0,mapProvider:t})},MAP_MOVE:lr,MAP_MOVE_END:lr,MAP_FIRST_IDLE:lr,SET_MAP_STYLE:function(e,t){return ur(ur({},e),{},{mapStyle:t})},SET_MAP_SIZE:function(e,t){return ur(ur({},e),{},{mapSize:t})},UPDATE_CROSS_HAIR:function(e,t){return ur(ur({},e),{},{crossHair:ur(ur({},e.crossHair),t)})},UPSERT_LOCATION_MARKER:function(e,t){var n=new Map(e.markers.items.map(function(e){return[e.id,e]}));n.set(t.id,t);var r=Array.from(n.values());return ur(ur({},e),{},{markers:ur(ur({},e.markers),{},{items:r})})},REMOVE_LOCATION_MARKER:function(e,t){var n=e.markers.items.filter(function(e){return e.id!==t});return ur(ur({},e),{},{markers:ur(ur({},e.markers),{},{items:n})})}},fr=function(e,t){var n=t.type,r=t.payload,o=cr[n];return o?o(e,r):e};function sr(e){return sr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},sr(e)}function pr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function dr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pr(Object(n),!0).forEach(function(t){yr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pr(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function yr(e,t,n){return(t=function(e){var t=function(e){if("object"!=sr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=sr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==sr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var mr=Z(null),br=function(e){var t,n,r,o,i,u,a,l,c,f=e.options,s=e.children,p=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return vr(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?vr(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(fe(fr,(n=(t=f).center,r=t.zoom,o=t.bounds,i=t.extent,u=t.mapStyle,a=t.mapSize,l=t.markers,{isMapReady:!1,mapProvider:null,mapStyle:null!=(c=t.pluginRegistry.registeredPlugins)&&c.find(function(e){var t;return null===(t=e.config)||void 0===t?void 0:t.handlesMapStyle})?null:u,mapSize:a,center:n,zoom:r,bounds:o||i,resolution:null,isAtMaxZoom:null,isAtMinZoom:null,crossHair:{isVisible:!1,isPinnedToMap:!1,state:"active"},markers:{items:l||[]}})),2),d=p[0],y=p[1],v=function(e){y({type:"SET_MAP_READY",payload:e})},m=function(e){var t=localStorage.getItem("".concat(f.id,":mapStyleId")),n=e.find(function(e){return e.id===t})||e[0],r=localStorage.getItem("".concat(f.id,":mapSize"))||f.mapSize;y({type:"SET_MAP_STYLE",payload:n}),y({type:"SET_MAP_SIZE",payload:r})},b=function(e){y({type:"SET_MAP_STYLE",payload:e})},h=function(e){y({type:"SET_MAP_SIZE",payload:e})},_=f.eventBus;se(function(){return _.on(_t.q.MAP_READY,v),_.on(_t.q.MAP_INIT_MAP_STYLES,m),_.on(_t.q.MAP_SET_STYLE,b),_.on(_t.q.MAP_SET_SIZE,h),function(){_.off(_t.q.MAP_READY,v),_.off(_t.q.MAP_INIT_MAP_STYLES,m),_.off(_t.q.MAP_SET_STYLE,b),_.off(_t.q.MAP_SET_SIZE,h)}},[]),se(function(){d.mapStyle&&d.mapSize&&(localStorage.setItem("".concat(f.id,":mapStyleId"),d.mapStyle.id),localStorage.setItem("".concat(f.id,":mapSize"),d.mapSize))},[d.mapStyle,d.mapSize]);var g=ve(function(){return dr(dr({},d),{},{dispatch:y})},[d]);return kt(mr.Provider,{value:g,children:s})};var hr=n("./src/services/reverseGeocode.js"),_r=Z(null),gr=function(e){var t=e.eventBus,n=e.children,r=Ot(),o=r.id,i=r.handleExitClick,u=de(null),a=ve(function(){return function(e){var t=!1,n=function(t){null!=e&&e.current&&t&&(e.current.textContent="",setTimeout(function(){e.current&&(e.current.textContent=t)},100))},r=function(e){var t=null,n=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];clearTimeout(t),t=setTimeout(function(){e.apply(void 0,r)},500)};return n.cancel=function(){t&&(clearTimeout(t),t=null)},n}(n);return function(e){if(e)return"plugin"===(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"core")?(t=!0,void n(e)):void(t?t=!1:r(e))}}(u)},[]),l=ve(function(){return{announce:a,reverseGeocode:function(e,t){return(0,hr.R)(e,t)},events:_t.q,eventBus:t,mapStatusRef:u,closeApp:function(){return function(e,t,n){var r;n.emit(_t.q.MAP_EXIT,{mapId:e}),null!==(r=history.state)&&void 0!==r&&r.isBack?history.back():t()}(o,i,t)}}},[a]);return kt(_r.Provider,{value:l,children:n})},Or=n("./src/InteractiveMap/domStateManager.js");function Pr(e){return Pr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pr(e)}function Sr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function wr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Er(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wr(Object(n),!0).forEach(function(t){jr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wr(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function jr(e,t,n){return(t=function(e){var t=function(e){if("object"!=Pr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Pr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Pr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ar=Z(null),Tr=function(e){var t=e.children,n=Ot().pluginRegistry,r={},o={},i=de({});n.registeredPlugins.forEach(function(e){var t=e.reducer;if(t){var n=t.initialState,u=t.actions;r[e.id]=function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0,r=null==e?void 0:e[null==n?void 0:n.type];return r?r(t,n.payload):t}}(u),o[e.id]=n}i.current[e.id]||(i.current[e.id]={})});var u=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Sr(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Sr(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(fe(function(e,t){var n=t.pluginId;return n&&r[n]?Er(Er({},e),{},jr({},n,r[n](e[n],t))):e},o),2),a=u[0],l=u[1],c=function(e,t){return i.current[e]||(i.current[e]={}),i.current[e][t]||(i.current[e][t]=bt.createRef()),i.current[e][t]},f=ve(function(){return{state:a,dispatch:l,refs:i,getPluginRef:c}},[a,l]);return kt(Ar.Provider,{value:f,children:t})},kr=function(e){var t=be(Ar);if(!t)throw new Error("usePlugin must be used within PluginProvider");var n=t.state,r=t.dispatch,o=t.refs,i=t.getPluginRef;return o.current[e]||(o.current[e]={}),Er(Er({},n[e]),{},{dispatch:function(t){return r(Er(Er({},t),{},{pluginId:e}))},refs:o.current[e],useRef:function(t){return i(e,t)}})};function Rr(){return be(nr)}function Ir(){return be(mr)}function Dr(){return be(_r)}function Cr(e){return Cr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Cr(e)}function Mr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function xr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Mr(Object(n),!0).forEach(function(t){Nr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mr(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Nr(e,t,n){return(t=function(e){var t=function(e){if("object"!=Cr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Cr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Cr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var Br=new Map;function Ur(e,t){var n=t.pluginId,r=t.pluginConfig,o=e;return Br.has(o)||Br.set(o,function(t){var o=Ot(),i=Rr(),u=Ir(),a=Dr(),l=kr(n);return kt(e,xr(xr({},t),{},{pluginConfig:r,pluginState:l,appConfig:o,appState:i,mapState:u,services:a,mapProvider:o.mapProvider,iconRegistry:En(),buttonConfig:Object.fromEntries(Object.entries(i.buttonConfig).filter(function(e){var t=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Lr(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Lr(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e,2);return t[0],t[1].pluginId===n}))}))}),Br.get(o)}function Hr(e){return Hr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Hr(e)}function Fr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function zr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fr(Object(n),!0).forEach(function(t){qr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fr(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function qr(e,t,n){return(t=function(e){var t=function(e){if("object"!=Hr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Hr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Hr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gr(e){return Gr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Gr(e)}function Wr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Vr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Wr(Object(n),!0).forEach(function(t){Kr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Wr(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Kr(e,t,n){return(t=function(e){var t=function(e){if("object"!=Gr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Gr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Gr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zr(e){return Zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Zr(e)}function $r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Yr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$r(Object(n),!0).forEach(function(t){Xr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$r(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Xr(e,t,n){return(t=function(e){var t=function(e){if("object"!=Zr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Zr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Zr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Jr(){var e=Ot(),t=Rr(),n=Ir(),r=Dr(),o=be(Ar),i={appConfig:e,appState:t,mapState:n,services:r,mapProvider:null==e?void 0:e.mapProvider,iconRegistry:En()};function u(t,n){var r,u;if(n){var a,l,c=e.pluginRegistry.registeredPlugins.find(function(e){return e.id===n});r=c?Yr({pluginId:c.id},c.config):{},u=Yr(Yr({},null!==(a=null==o||null===(l=o.state)||void 0===l?void 0:l[n])&&void 0!==a?a:{}),{},{dispatch:null==o?void 0:o.dispatch})}var f=Yr(Yr({},i),{},{pluginConfig:r,pluginState:u});return"function"==typeof t?t(f):t}return u.ctx=i,u}function Qr(e){return Qr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Qr(e)}function eo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function to(e,t,n){return(t=function(e){var t=function(e){if("object"!=Qr(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Qr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Qr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function no(e){var t=Rr(),n=Ot().pluginRegistry,r=be(Ar);pe(function(){if(null!=t&&t.dispatch&&r){var o=t.dispatch;n.registeredPlugins.forEach(function(n){var r,i,u=(null!==(r=null==n||null===(i=n.manifest)||void 0===i?void 0:i.buttons)&&void 0!==r?r:[]).flatMap(function(e){var t;return[e].concat(function(e){return function(e){if(Array.isArray(e))return eo(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return eo(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?eo(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(null!==(t=e.menuItems)&&void 0!==t?t:[]))});u.forEach(function(r){return function(e){var t=e.btn,n=e.pluginId,r=e.appState,o=e.dispatch,i=e.evaluateProp;[{prop:"enableWhen",state:r.disabledButtons,action:"TOGGLE_BUTTON_DISABLED",invert:!0,key:"isDisabled"},{prop:"hiddenWhen",state:r.hiddenButtons,action:"TOGGLE_BUTTON_HIDDEN",key:"isHidden"},{prop:"pressedWhen",state:r.pressedButtons,action:"TOGGLE_BUTTON_PRESSED",key:"isPressed"},{prop:"expandedWhen",state:r.expandedButtons,action:"TOGGLE_BUTTON_EXPANDED",key:"isExpanded"}].forEach(function(e){var r=e.prop,u=e.state,a=e.action,l=e.key,c=e.invert;if("function"==typeof t[r])try{var f=i(t[r],n),s=c?!f:f;u.has(t.id)!==s&&o({type:a,payload:to({id:t.id},l,s)})}catch(e){console.warn("".concat(r," error for button ").concat(t.id,":"),e)}})}({btn:r,pluginId:n.id,appState:t,dispatch:o,evaluateProp:e})})})}},[t,r,e])}var ro=["api"];function oo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var io=function(e){var t,n,r=e.plugin,o=e.mode,i=function(e){var t=de(null),n=Ot(),r=Rr(),o=Ir(),i=Dr(),u=kr(e);return se(function(){t.current={appConfig:n,appState:r,mapState:o,services:i,mapProvider:n.mapProvider,pluginState:u}}),t}(r.id);se(function(){r.api&&r._originalPlugin&&Object.entries(r.api).forEach(function(e){var t=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return oo(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?oo(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e,2),n=t[0],o=t[1];r._originalPlugin[n]=function(e,t){var n=t.pluginId,r=t.pluginConfig,o=t.stateRef;return function(){var t=o.current;if(!t)throw new Error('Plugin API "'.concat(n,'" called before state is initialized'));for(var i=arguments.length,u=new Array(i),a=0;a<i;a++)u[a]=arguments[a];return e.apply(void 0,[zr(zr({},t),{},{pluginConfig:r,pluginId:n})].concat(u))}}(o,{pluginId:r.id,pluginConfig:(null==r?void 0:r.config)||{},stateRef:i})})},[r,i]);var u=r.InitComponent,a=(null==r?void 0:r.config)||{},l=(a.api,function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(a,ro)),c=r.config||{},f=c.includeModes,s=c.excludeModes,p=null===(t=null==f?void 0:f.includes(o))||void 0===t||t,d=null!==(n=null==s?void 0:s.includes(o))&&void 0!==n&&n;return p&&!d&&u?kt(Ur(u,{pluginId:r.id,pluginConfig:l}),{}):null},uo=function(){var e,t,n,r,o,i,u,a,l,c=Rr().mode,f=Ot().pluginRegistry;e=Rr(),t=e.dispatch,n=e.hiddenButtons,r=e.disabledButtons,o=e.pressedButtons,i=e.expandedButtons,u=Dr().eventBus,a=de(t),l=de({hiddenButtons:n,disabledButtons:r,pressedButtons:o,expandedButtons:i}),a.current=t,l.current={hiddenButtons:n,disabledButtons:r,pressedButtons:o,expandedButtons:i},se(function(){var e=function(e){var t=e.id,n=e.config;a.current({type:"ADD_BUTTON",payload:{id:t,config:n}}),Array.isArray(n.menuItems)&&n.menuItems.forEach(function(e){a.current({type:"ADD_BUTTON",payload:{id:e.id,config:Vr(Vr({},e),{},{isMenuItem:!0})}})})},t=function(e){var t=e.id,n=e.prop,r=e.value,o=l.current,i=o.hiddenButtons,u=o.disabledButtons,c=o.pressedButtons,f=o.expandedButtons;switch(n){case"hidden":var s="boolean"==typeof r?r:!i.has(t);a.current({type:"TOGGLE_BUTTON_HIDDEN",payload:{id:t,isHidden:s}});break;case"disabled":var p="boolean"==typeof r?r:!u.has(t);a.current({type:"TOGGLE_BUTTON_DISABLED",payload:{id:t,isDisabled:p}});break;case"pressed":var d="boolean"==typeof r?r:!c.has(t);a.current({type:"TOGGLE_BUTTON_PRESSED",payload:{id:t,isPressed:d}});break;case"expanded":var y="boolean"==typeof r?r:!f.has(t);a.current({type:"TOGGLE_BUTTON_EXPANDED",payload:{id:t,isExpanded:y}})}},n=function(e){var t=e.id,n=e.config;return a.current({type:"ADD_PANEL",payload:{id:t,config:n}})},r=function(e){return a.current({type:"REMOVE_PANEL",payload:e})},o=function(e){return a.current({type:"OPEN_PANEL",payload:{panelId:e}})},i=function(e){return a.current({type:"CLOSE_PANEL",payload:e})},c=function(e){var t=e.id,n=e.config;return a.current({type:"ADD_CONTROL",payload:{id:t,config:n}})};return u.on(_t.q.APP_ADD_BUTTON,e),u.on(_t.q.APP_TOGGLE_BUTTON_STATE,t),u.on(_t.q.APP_ADD_PANEL,n),u.on(_t.q.APP_REMOVE_PANEL,r),u.on(_t.q.APP_SHOW_PANEL,o),u.on(_t.q.APP_HIDE_PANEL,i),u.on(_t.q.APP_ADD_CONTROL,c),function(){u.off(_t.q.APP_ADD_BUTTON,e),u.off(_t.q.APP_TOGGLE_BUTTON_STATE,t),u.off(_t.q.APP_ADD_PANEL,n),u.off(_t.q.APP_REMOVE_PANEL,r),u.off(_t.q.APP_SHOW_PANEL,o),u.off(_t.q.APP_HIDE_PANEL,i),u.off(_t.q.APP_ADD_CONTROL,c)}},[u]);var s=Jr();return no(s),kt(S,{children:f.registeredPlugins.map(function(e,t){return kt(io,{plugin:e,mode:c,evaluateProp:s},"init-".concat(e.id,"-").concat(t))})})};function ao(e){return function(e){if(Array.isArray(e))return fo(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||co(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function lo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||co(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function co(e,t){if(e){if("string"==typeof e)return fo(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?fo(e,t):void 0}}function fo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function so(e){return so="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},so(e)}function po(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function yo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?po(Object(n),!0).forEach(function(t){vo(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):po(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vo(e,t,n){return(t=function(e){var t=function(e){if("object"!=so(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=so(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==so(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var bo=function(e){var t=[e.mainRef,e.insetRef,e.rightRef,e.actionsRef,e.footerRef];if(!t.some(function(e){return!e.current})){var n=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return mo(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?mo(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t.map(function(e){return e.current}),5),r=n[0],o=n[1],i=n[2],u=n[3],a=n[4],l=document.documentElement,c=Number.parseInt(getComputedStyle(l).getPropertyValue("--divider-gap"),10),f=u.offsetTop-o.offsetTop-c,s=o.offsetLeft+i.offsetWidth+c,p=r.offsetWidth-2*s,d=o.offsetWidth-s+o.offsetLeft,y=p-d>f-o.offsetHeight,v=o.offsetTop+(!y&&o.offsetHeight>0?o.offsetHeight+c:0),m=y?o.offsetWidth+o.offsetLeft+c:s,b=r.offsetHeight-u.offsetTop,h=r.offsetHeight-a.offsetTop,_=d<p/2&&o.offsetHeight<f/2;return{top:_?o.offsetTop:v,right:s,left:r.offsetLeft+(_?s:Math.max(m,s)),bottom:Math.max(b,h)+c}}};function ho(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var _o=function(e,t){return Object.entries(e).reduce(function(e,n){var r=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ho(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ho(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(n,2),o=r[0],i=r[1];return e[o]=Math.round(i/t),e},{})};function go(e){return go="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},go(e)}function Oo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Po(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Oo(Object(n),!0).forEach(function(t){So(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Oo(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function So(e,t,n){return(t=function(e){var t=function(e){if("object"!=go(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=go(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==go(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var wo=function(e){var t=e.mapContainerRef,n=Ot(),r=n.id,o=n.mapProvider,i=Rr(),u=i.safeZoneInset,a=i.breakpoint,l=i.isLayoutReady,c=i.syncMapPadding,f=Ir(),s=f.isMapReady,p=f.mapStyle,d=f.mapSize,y=f.center,v=f.zoom,m=f.bounds,b=de(!1),h=function(e){var t=e.id,n=e.center,r=e.zoom,o=e.bounds,i=function(e,t){var n=new URLSearchParams(t),r=n.get("".concat(e,":center")),o=n.get("".concat(e,":zoom"));if(!r||!o)return null;var i=lo(r.split(",").map(Number),2);return{center:[i[0],i[1]],zoom:Number(o)}}(t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.location.search);return i?{center:i.center,zoom:i.zoom}:o?{bounds:o}:{center:n,zoom:r}}({id:r,center:y,zoom:v,bounds:m});return se(function(){if(u&&l&&p&&d&&!b.current)return requestAnimationFrame(function(){o.initMap(Po(Po({},n),{},{pixelRatio:window.devicePixelRatio*Gt[d],container:t.current,padding:u,center:h.center,zoom:h.zoom,bounds:h.bounds,mapStyle:p}))}),b.current=!0,function(){}},[u,l,p,d]),function(){var e=Ot().mapProvider,t=Ir().dispatch,n=Dr().eventBus,r=de(null),o=de(!1);se(function(){if(e){var i=function(e){t({type:"MAP_MOVE",payload:e})},u=function(e){t({type:"MAP_MOVE_END",payload:e}),n.emit(_t.q.MAP_STATE_UPDATED,{previous:r.current,current:e}),r.current=e},a=function(n){o.current||(r.current={center:e.getCenter(),zoom:e.getZoom()},o.current=!0),t({type:"MAP_FIRST_IDLE",payload:n})};return n.on(_t.q.MAP_MOVE,i),n.on(_t.q.MAP_MOVE_END,u),n.on(_t.q.MAP_FIRST_IDLE,a),function(){n.off(_t.q.MAP_MOVE,i),n.off(_t.q.MAP_MOVE_END,u),n.off(_t.q.MAP_FIRST_IDLE,a)}}},[e,t])}(),function(){var e=Ot().id,t=Dr().eventBus;se(function(){if(e){var n=function(t){var n=t.current;!function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:window.location.href,r=new URL(n||"http://localhost"),o=ao(new URLSearchParams(r.search)).map(function(e){var t=lo(e,2),n=t[0],r=t[1];return"".concat(n,"=").concat(r)}),i=[];t.center&&i.push("".concat(e,":center=").concat(t.center[0],",").concat(t.center[1])),null!=t.zoom&&i.push("".concat(e,":zoom=").concat(t.zoom));var u=o.filter(function(e){return!i.some(function(t){return t.split("=")[0]===e.split("=")[0]})}),a=r.hash||"",l="".concat(r.origin).concat(r.pathname,"?").concat([].concat(ao(u),i).join("&")).concat(a);window.history.replaceState(window.history.state,"",l)}(e,{center:n.center,zoom:n.zoom})};return t.on(_t.q.MAP_STATE_UPDATED,n),function(){return t.off(_t.q.MAP_STATE_UPDATED,n)}}},[e])}(),function(){var e=Ot().mapProvider,t=Dr(),n=t.eventBus,r=t.announce;se(function(){var t=function(t){var n=t.previous,o=t.current;if(null!=n&&n.center&&null!=o&&o.center){var i=function(e,t,n){var r,o,i,u=e.zoom!==t.zoom,a=e.center[0]!==t.center[0]||e.center[1]!==t.center[1],l=n.getAreaDimensions();return a&&!u?function(e){var t=e.direction;return"Map moved ".concat(t,".")}({direction:n.getCardinalMove(e.center,t.center),areaDimensions:l}):!a&&u?function(e){var t=e.from,n=e.to,r=e.areaDimensions,o=e.isAtMaxZoom,i=e.isAtMinZoom;return"Map zoomed ".concat(n>t?"in":"out").concat(o?" (Maximum zoom)":"").concat(i?" (Minimum zoom)":"",". New area approximately ").concat(r,".")}(yo(yo({},t),{},{from:e.zoom,to:t.zoom,areaDimensions:l})):a||u?function(e){var t=e.areaDimensions,n=e.isAtMaxZoom,r=e.isAtMinZoom;return"New area approximately ".concat(t).concat(n?" (Maximum zoom)":"").concat(r?" (Minimum zoom)":"",".")}(yo(yo({},t),{},{areaDimensions:l})):(o=(r=yo({},t)).isAtMaxZoom,i=r.isAtMinZoom,"No change, ".concat(o?"maximum zoom reached":"").concat(i?"minimum zoom reached":"","."))}(n,o,e);i&&r(i,"core")}};return n.on(_t.q.MAP_STATE_UPDATED,t),function(){n.off(_t.q.MAP_STATE_UPDATED,t)}},[e,r])}(),function(){var e=Ot().mapProvider,t=Rr(),n=t.dispatch,r=t.layoutRefs,o=Ir().mapSize,i=de(o);i.current=o;var u=function(){var t=bo(r),o=_o(t,Gt[i.current]);"function"==typeof n&&n({type:"SET_SAFE_ZONE_INSET",payload:{safeZoneInset:t,syncMapPadding:!1}}),"function"==typeof e.setPadding&&e.setPadding(o)};se(function(){if(e){var t=e.fitToBounds;e.fitToBounds=function(n){if(n)return arguments.length>1&&void 0!==arguments[1]&&arguments[1]||u(),t.call(e,n)};var n=e.setView;return e.setView=function(t){var r=t.center,o=t.zoom;if(r)return u(),n.call(e,{center:r,zoom:o})},function(){e.fitToBounds=t,e.setView=n}}},[e,n,r,o])}(),se(function(){s&&c&&o.setPadding(_o(u,Gt[d]))},[s,d,a,u]),null},Eo={keydown:{ArrowUp:"panUp",ArrowDown:"panDown",ArrowLeft:"panLeft",ArrowRight:"panRight","+":"zoomIn","=":"zoomIn","-":"zoomOut",_:"zoomOut"},keyup:{"Alt+k":"showKeyboardControls","Alt+K":"showKeyboardControls","Alt+ArrowRight":"highlightNextLabel","Alt+ArrowLeft":"highlightNextLabel","Alt+ArrowUp":"highlightNextLabel","Alt+ArrowDown":"highlightNextLabel","Alt+Enter":"highlightLabelAtCenter","Alt+i":"getInfo","Alt+I":"getInfo",Escape:"clearSelection"}};function jo(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var l=r&&r.prototype instanceof a?r:a,c=Object.create(l.prototype);return Ao(c,"_invoke",function(n,r,o){var i,a,l,c=0,f=o||[],s=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,l=e,p.n=n,u}};function d(n,r){for(a=n,l=r,t=0;!s&&c&&!o&&t<f.length;t++){var o,i=f[t],d=p.p,y=i[2];n>3?(o=y===r)&&(l=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=n<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<y&&(o=n<3||i[0]>r||r>y)&&(i[4]=n,i[5]=r,p.n=y,a=0))}if(o||n>1)return u;throw s=!0,r}return function(o,f,y){if(c>1)throw TypeError("Generator is already running");for(s&&1===f&&d(f,y),a=f,l=y;(t=a<2?e:l)||!s;){i||(a?a<3?(a>1&&(p.n=-1),d(a,l)):p.n=l:p.v=l);try{if(c=2,i){if(a||(o="next"),t=i[o]){if(!(t=t.call(i,l)))throw TypeError("iterator result is not an object");if(!t.done)return t;l=t.value,a<2&&(a=0)}else 1===a&&(t=i.return)&&t.call(i),a<2&&(l=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((t=(s=p.n<0)?l:n.call(r,p))!==u)break}catch(t){i=e,a=1,l=t}finally{c=1}}return{value:t,done:s}}}(n,o,i),!0),c}var u={};function a(){}function l(){}function c(){}t=Object.getPrototypeOf;var f=[][r]?t(t([][r]())):(Ao(t={},r,function(){return this}),t),s=c.prototype=a.prototype=Object.create(f);function p(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,Ao(e,o,"GeneratorFunction")),e.prototype=Object.create(s),e}return l.prototype=c,Ao(s,"constructor",c),Ao(c,"constructor",l),l.displayName="GeneratorFunction",Ao(c,o,"GeneratorFunction"),Ao(s),Ao(s,o,"Generator"),Ao(s,r,function(){return this}),Ao(s,"toString",function(){return"[object Generator]"}),(jo=function(){return{w:i,m:p}})()}function Ao(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}Ao=function(e,t,n,r){function i(t,n){Ao(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},Ao(e,t,n,r)}function To(e,t,n,r,o,i,u){try{var a=e[i](u),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function ko(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ro(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ro(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ro(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var Io=function(){return kt("div",{ref:Dr().mapStatusRef,role:"status",className:"im-c-viewport__status","aria-live":"polite","aria-atomic":"true","aria-label":"Map updates"})},Do={active:"M5.035 20H1v-2h4.035C5.525 11.069 11.069 5.525 18 5.035V1h2v4.035c6.931.49 12.475 6.034 12.965 12.965H37v2h-4.035c-.49 6.931-6.034 12.475-12.965 12.965V37h-2v-4.035C11.069 32.475 5.525 26.931 5.035 20zM19 7c-6.581.005-11.995 5.419-12 12 .005 6.581 5.419 11.995 12 12 6.581-.005 11.995-5.419 12-12-.005-6.581-5.419-11.995-12-12zm0 10a2.01 2.01 0 0 1 2 2 2.01 2.01 0 0 1-2 2 2.01 2.01 0 0 1-2-2 2.01 2.01 0 0 1 2-2z",inactive:"M5.035 20H1v-2h4.035a13.98 13.98 0 0 1 .246-1.8l1.96.399C7.083 17.375 7 18.178 7 19s.083 1.625.241 2.401l-1.96.399a13.98 13.98 0 0 1-.246-1.8zM20 5.035a13.98 13.98 0 0 1 1.8.246l-.399 1.96C20.625 7.083 19.822 7 19 7s-1.625.083-2.401.241l-.399-1.96a13.98 13.98 0 0 1 1.8-.246V1h2v4.035zm-2 27.93a13.98 13.98 0 0 1-1.8-.246l.399-1.96c.776.158 1.579.241 2.401.241s1.625-.083 2.401-.241l.399 1.96a13.98 13.98 0 0 1-1.8.246V37h-2v-4.035zM32.965 20a13.98 13.98 0 0 1-.246 1.8l-1.96-.399c.158-.776.241-1.579.241-2.401s-.083-1.625-.241-2.401l1.96-.399a13.98 13.98 0 0 1 .246 1.8H37v2h-4.035zM19 17a2.01 2.01 0 0 1 2 2 2.01 2.01 0 0 1-2 2 2.01 2.01 0 0 1-2-2 2.01 2.01 0 0 1 2-2zm3.8-9.385l.634-1.897c1.789.598 3.438 1.553 4.848 2.805l-1.327 1.496c-1.196-1.06-2.605-1.886-4.155-2.404zm5.181 3.43l1.496-1.327c1.252 1.41 2.207 3.059 2.805 4.848l-1.897.634c-.518-1.55-1.344-2.959-2.404-4.155zM30.385 22.8l1.897.634c-.598 1.789-1.553 3.438-2.805 4.848l-1.496-1.327c1.06-1.196 1.886-2.605 2.404-4.155zm-3.43 5.181l1.327 1.496c-1.41 1.252-3.059 2.207-4.848 2.805l-.634-1.897c1.55-.518 2.959-1.344 4.155-2.404zM15.2 30.385l-.634 1.897c-1.789-.598-3.438-1.553-4.848-2.805l1.327-1.496c1.196 1.06 2.605 1.886 4.155 2.404zm-5.181-3.43l-1.496 1.327c-1.252-1.41-2.207-3.059-2.805-4.848l1.897-.634c.518 1.55 1.344 2.959 2.404 4.155zM7.615 15.2l-1.897-.634c.598-1.789 1.553-3.438 2.805-4.848l1.496 1.327c-1.06 1.196-1.886 2.605-2.404 4.155zm3.43-5.181L9.718 8.523c1.41-1.252 3.059-2.207 4.848-2.805l.634 1.897c-1.55.518-2.959 1.344-4.155 2.404z"},Co=function(){var e=Ot().id,t=function(){var e=Ot().mapProvider,t=Rr().safeZoneInset,n=Dr().eventBus,r=Ir(),o=r.crossHair,i=r.dispatch,u=r.mapSize,a=function(e,n,r){if(t){var o=n*Gt[u],i=r*Gt[u];e.style.transform="translate(".concat(o-t.left,"px, ").concat(i-t.top,"px)"),e.style.left="0",e.style.top="0",e.style.display="block"}},l=me(function(t){if(t){!function(e,t,n,r,o){e.pinToMap=function(i,u){var a=n.mapToScreen(i),l=a.x,c=a.y;e.coords=i,r({type:"UPDATE_CROSS_HAIR",payload:{isPinnedToMap:!0,isVisible:!0,coords:i,state:u}}),o(t,l,c)},e.fixAtCenter=function(){t.style.left="50%",t.style.top="50%",t.style.transform="translate(0,0)",t.style.display="block",r({type:"UPDATE_CROSS_HAIR",payload:{isPinnedToMap:!1,isVisible:!0}})},e.remove=function(){t.style.display="none",r({type:"UPDATE_CROSS_HAIR",payload:{isPinnedToMap:!1,isVisible:!1}})},e.show=function(){t.style.display="block",r({type:"UPDATE_CROSS_HAIR",payload:{isVisible:!0}})},e.hide=function(){t.style.display="none",r({type:"UPDATE_CROSS_HAIR",payload:{isVisible:!1}})},e.setStyle=function(e){r({type:"UPDATE_CROSS_HAIR",payload:{state:e}})},e.getDetail=function(){var t=e.isPinnedToMap?e.coords:n.getCenter();return{state:e.state,point:n.mapToScreen(t),zoom:n.getZoom(),coords:t}}}(o,t,e,i,a);var r=function(){if(o.coords&&o.isPinnedToMap){var n=e.mapToScreen(o.coords),r=n.x,i=n.y;a(t,r,i)}};return n.on(_t.q.MAP_RENDER,r),function(){n.off(_t.q.MAP_RENDER,r)}}},[o,e,u,i,t]);return se(function(){o.coords&&o.isPinnedToMap&&o.pinToMap(o.coords,o.state)},[u]),{crossHair:o,crossHairRef:l}}(),n=t.crossHairRef,r=t.crossHair,o=r.isVisible,i=r.isPinnedToMap,u=r.state;return kt("svg",{id:"".concat(e,"-cross-hair"),ref:n,className:"im-c-cross-hair",width:"38",height:"38",viewBox:"0 0 38 38",fillRule:"evenodd",fill:"currentColor",style:{position:"absolute",left:i?0:"50%",top:i?0:"50%",pointerEvents:"none",display:o?"block":"none"},children:kt("path",{d:Do[u||"active"]})})};function Mo(e){return Mo="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Mo(e)}function xo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function No(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?xo(Object(n),!0).forEach(function(t){Lo(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xo(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Lo(e,t,n){return(t=function(e){var t=function(e){if("object"!=Mo(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Mo(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Mo(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Bo=function(e,t,n,r){if(!t||!r)return{x:0,y:0};var o=t.mapToScreen(e),i=o.x,u=o.y;return{x:i*Gt[n],y:u*Gt[n]-19}},Uo=function(e,t,n,r,o){e.forEach(function(e){var i=t.get(e.id);if(i&&e.coords){var u=Bo(e.coords,n,r,o),a=u.x,l=u.y;i.style.transform="translate(".concat(a,"px, ").concat(l,"px)"),i.style.display="block"}})};function Ho(e){return Ho="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ho(e)}var Fo=function(e,t){if(!e)return null;if("string"==typeof e)return e.trim();if("object"===Ho(e)){if(t&&e[t])return e[t];var n=Object.values(e)[0];return null!=n?n:null}return null};function zo(e){return null==e?void 0:e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}var qo=function(){var e=Ot(),t=e.id,n=e.markerShape,r=e.markerColor,o=Ir().mapStyle,i=function(){var e=Ot().mapProvider,t=Dr().eventBus,n=Ir(),r=n.markers,o=n.dispatch,i=n.mapSize,u=n.isMapReady,a=de(new Map);se(function(){e&&(r.markerRefs=a.current,r.add=function(t,n,r){var a=Bo(n,e,i,u),l=a.x,c=a.y;o({type:"UPSERT_LOCATION_MARKER",payload:No(No({id:t,coords:n},r),{},{x:l,y:c,isVisible:!0})})},r.remove=function(e){o({type:"REMOVE_LOCATION_MARKER",payload:e})},r.getMarker=function(e){return r.items.find(function(t){return t.id===e})})},[e,r,o,i]);var l=me(function(n){return function(o){if(o){a.current.set(n,o);var l=function(){u&&e&&Uo(r.items,a.current,e,i,u)};return t.on(_t.q.MAP_RENDER,l),function(){t.off(_t.q.MAP_RENDER,l)}}a.current.delete(n)}},[r,e,u,i]);return se(function(){u&&e&&Uo(r.items,a.current,e,i,u)},[i,r.items,e,u]),function(e,t){se(function(){var n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(null!=e&&e.id&&null!=e&&e.coords){var n=e.id,r=e.coords,o=e.options;t.add(n,r,o)}};e.on(_t.q.APP_ADD_MARKER,n);var r=function(e){e&&t.remove(e)};return e.on(_t.q.APP_REMOVE_MARKER,r),function(){e.off(_t.q.APP_ADD_MARKER,n),e.off(_t.q.APP_REMOVE_MARKER,r)}},[])}(t,r),{markers:r,markerRef:l}}(),u=i.markers,a=i.markerRef;if(o){var l=Wt.find(function(e){return e.shape===n});return kt(S,{children:u.items.map(function(e){return kt("svg",{ref:a(e.id),id:"".concat(t,"-marker-").concat(e.id),className:"im-c-marker im-c-marker--".concat(e.markerShape||zo(n)),width:"38",height:"38",viewBox:"0 0 38 38",style:{display:e.isVisible?"block":"none"},children:[kt("path",{className:"im-c-marker__background",d:l.backgroundPath,fill:Fo(e.color||r,o.id)}),kt("path",{className:"im-c-marker__graphic",d:l.graphicPath})]},e.id)})})}};function Go(e){return Go="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Go(e)}function Wo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var Vo=function(e){var t=e.keyboardHintPortalRef,n=Ot(),r=n.id,o=n.mapProvider,i=n.mapLabel,u=n.keyboardHintText,a=Rr(),l=a.interfaceType,c=a.mode,f=a.previousMode,s=a.layoutRefs,p=a.safeZoneInset,d=Ir().mapSize,y=de(null),v=de(null),m=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Wo(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Wo(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(ce(!1),2),b=m[0],h=m[1];!function(e){var t=Ot(),n=t.mapProvider,r=t.panDelta,o=t.nudgePanDelta,i=t.zoomDelta,u=t.nudgeZoomDelta,a=t.readMapText,l=Rr(),c=l.interfaceType,f=l.dispatch,s=Dr().announce;se(function(){var t=e.current;if(t&&"keyboard"===c){var l=function(e,t,n){var r,o=n.containerRef,i=n.dispatch,u=n.panDelta,a=n.nudgePanDelta,l=n.zoomDelta,c=n.nudgeZoomDelta,f=n.readMapText,s=function(e){return e?a:u},p=function(e){return e?c:l};return{showKeyboardControls:function(){i({type:"OPEN_PANEL",payload:{panelId:"keyboardHelp",props:{triggeringElement:o.current}}})},panUp:function(t){return e.panBy([0,-s(t.shiftKey)])},panDown:function(t){return e.panBy([0,s(t.shiftKey)])},panLeft:function(t){return e.panBy([-s(t.shiftKey),0])},panRight:function(t){return e.panBy([s(t.shiftKey),0])},zoomIn:function(t){return e.zoomIn(p(t.shiftKey))},zoomOut:function(t){return e.zoomOut(p(t.shiftKey))},getInfo:(r=function(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function u(e){To(i,r,o,u,a,"next",e)}function a(e){To(i,r,o,u,a,"throw",e)}u(void 0)})}}(jo().m(function n(r){var o,i,u,a,l;return jo().w(function(n){for(;;)switch(n.n){case 0:return i=e.getCenter(),n.n=1,(0,hr.R)(e.getZoom(),i);case 1:u=n.v,a=null===(o=e.getAreaDimensions)||void 0===o?void 0:o.call(e),l=a?"".concat(u,". Covering ").concat(a,"."):"".concat(u,"."),t(l,"core");case 2:return n.a(2)}},n)})),function(e){return r.apply(this,arguments)}),highlightNextLabel:function(n){if(f||!e.highlightNextLabel){var r=e.highlightNextLabel(n.key);t(r,"core")}},highlightLabelAtCenter:function(){if(f||!e.highlightNextLabel){var n=e.highlightLabelAtCenter();t(n,"core")}},clearSelection:function(){var t;return null==e||null===(t=e.clearHighlightedLabel)||void 0===t?void 0:t.call(e)}}}(n,s,{containerRef:e,dispatch:f,panDelta:r,nudgePanDelta:o,zoomDelta:i,nudgeZoomDelta:u,readMapText:a}),p=function(e){return function(t){var n=Eo[e][function(e){var t;return"Add"===(t=/^Key[A-Z]$/.test(e.code)?e.code.slice(3):e.key)||"NumpadAdd"===t?t="+":"Subtract"!==t&&"NumpadSubtract"!==t||(t="-"),e.altKey?"Alt+".concat(t):t}(t)];n&&l[n]&&(l[n](t),t.preventDefault())}},d=p("keydown"),y=p("keyup");return t.addEventListener("keydown",d),t.addEventListener("keyup",y),function(){t.removeEventListener("keydown",d),t.removeEventListener("keyup",y)}}},[e,c,n,r,o,i,u])}(s.viewportRef),function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Ot().mapProvider,n=Dr().eventBus;se(function(){if(t){var r={};return Object.entries(e).forEach(function(e){var t=ko(e,2),o=t[0],i=t[1],u=function(e){return i(e)};r[o]=u,n.on(o,u)}),function(){Object.entries(r).forEach(function(e){var t=ko(e,2),r=t[0],o=t[1];n.off(r,o)})}}},[t,e])}(function(e,t,n){return(t=function(e){var t=function(e){if("object"!=Go(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Go(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Go(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},_t.q.MAP_CLICK,function(){var e;return null==o||null===(e=o.clearHighlightedLabel)||void 0===e?void 0:e.call(o)}));var _=function(e){var t=e.interfaceType,n=e.containerRef,r=e.keyboardHintRef,o=e.onViewportFocusChange,i=e.keyboardHintVisible;return se(function(){if(i&&n.current){var e=n.current,t=function(e){["Escape","Tab"].includes(e.key)&&o(!1)},u=function(t){var n,i=e.contains(t.target),u=null===(n=r.current)||void 0===n?void 0:n.contains(t.target);i&&!u&&o(!1)};return e.addEventListener("keydown",t),e.addEventListener("mousedown",u),function(){e.removeEventListener("keydown",t),e.removeEventListener("mousedown",u)}}},[i,n,r,o]),{showHint:i,handleFocus:function(){"keyboard"===t&&o(!0)},handleBlur:function(){o(!1)}}}({interfaceType:l,containerRef:s.viewportRef,keyboardHintRef:v,keyboardHintVisible:b,onViewportFocusChange:h}),g=_.showHint,O=_.handleFocus,P=_.handleBlur;return se(function(){var e;c&&f&&c!==f&&(null===(e=s.viewportRef)||void 0===e||e.current.focus())},[c]),se(function(){var e,t=null===(e=s.mainRef)||void 0===e?void 0:e.current;if(t)return t.classList.toggle("im-o-app__main--keyboard-hint-visible",g),function(){return null==t?void 0:t.classList.remove("im-o-app__main--keyboard-hint-visible")}},[g]),kt(S,{children:[kt(wo,{mapContainerRef:y}),kt("div",{id:"".concat(r,"-viewport"),className:"im-c-viewport im-c-viewport--".concat(d),"aria-label":i,role:"application",tabIndex:"0",onFocus:O,onBlur:P,ref:s.viewportRef,children:[g&&(null==t?void 0:t.current)&&Ye(kt("div",{className:"im-c-viewport__keyboard-hint","aria-hidden":"true",ref:v,dangerouslySetInnerHTML:{__html:u}}),t.current),kt("div",{className:"im-c-viewport__map-container",ref:y}),kt("div",{className:"im-c-viewport__features"}),kt(Io,{}),kt("div",{className:"im-c-viewport__safezone",style:p,ref:s.safeZoneRef,children:kt(Co,{})}),kt(qo,{})]})]})};function Ko(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Zo(e,t){var n=de(),r=de(new WeakMap);return se(function(){var o=(Array.isArray(e)?e:[e]).map(function(e){return null==e?void 0:e.current}).filter(Boolean);if(o.length&&t){var i=new window.ResizeObserver(function(e){var n,o=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return Ko(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ko(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,u=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return u=e.done,e},e:function(e){a=!0,i=e},f:function(){try{u||null==n.return||n.return()}finally{if(a)throw i}}}}(e);try{for(o.s();!(n=o.n()).done;){var i=n.value,u=i.contentRect,a=u.width,l=u.height,c=r.current.get(i.target)||{};c.width===a&&c.height===l||(r.current.set(i.target,{width:a,height:l}),t(i))}}catch(e){o.e(e)}finally{o.f()}});return o.forEach(function(e){return i.observe(e)}),function(){i.disconnect(),n.current&&cancelAnimationFrame(n.current)}}},[e,t]),{frameRef:n}}var $o=function(){var e=Ir().mapStyle;if(null!=e&&e.logo)return kt("img",{className:"im-c-logo",src:e.logo,alt:e.logoAltText})},Yo=function(){var e=Rr().breakpoint,t=Ir().mapStyle;return t?"mobile"!==e&&kt("div",{className:"im-c-attributions",dangerouslySetInnerHTML:{__html:t.attribution}}):null},Xo=Object.freeze({SIDE:"side",BANNER:"banner",TOP_LEFT:"top-left",TOP_MIDDLE:"top-middle",TOP_RIGHT:"top-right",INSET:"inset",RIGHT_TOP:"right-top",RIGHT_BOTTOM:"right-bottom",MIDDLE:"middle",FOOTER_RIGHT:"footer-right",BOTTOM:"bottom",ACTIONS:"actions",MODAL:"modal"}),Jo=Object.freeze({control:[Xo.BANNER,Xo.TOP_LEFT,Xo.TOP_RIGHT,Xo.INSET,Xo.MIDDLE,Xo.FOOTER_RIGHT,Xo.BOTTOM,Xo.ACTIONS],panel:[Xo.SIDE,Xo.BANNER,Xo.INSET,Xo.MIDDLE,Xo.BOTTOM,Xo.ACTIONS,Xo.DRAWER,Xo.MODAL],button:[Xo.TOP_LEFT,Xo.TOP_MIDDLE,Xo.TOP_RIGHT,Xo.RIGHT_TOP,Xo.RIGHT_BOTTOM,Xo.ACTIONS]}),Qo=function(e,t){return e.modal?"modal":"bottom"===e.slot&&["tablet","desktop"].includes(t)?"inset":e.slot},ei=function(e,t){var n;return!(e.includeModes&&!e.includeModes.includes(t)||null!==(n=e.excludeModes)&&void 0!==n&&n.includes(t))},ti=function(e){return"string"==typeof e.html&&!e.pluginId},ni=n("./src/utils/toggleInertElements.js");function ri(e){var t=e.mainRef,n=e.panelRef,r=e.isModal,o=e.rootEl,i=e.buttonContainerEl,u=e.handleClose;!function(e,t,n){se(function(){if(t){var r=function(t){"Escape"===t.key&&(t.stopPropagation(),t.preventDefault(),n()),"Tab"===t.key&&e.current&&function(e,t){if("Tab"===t.key){var n=Array.from(e.querySelectorAll(["a[href]:not([disabled])","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'*[tabindex="0"]:not([disabled])'].join(",")));if(0!==(n=n.filter(function(e){return!!e.offsetParent})).length){var r=n[0],o=n[n.length-1];!t.shiftKey||document.activeElement!==e&&document.activeElement!==r||(o.focus(),t.preventDefault()),t.shiftKey||document.activeElement!==o||(r.focus(),t.preventDefault())}}}(e.current,t)},o=e.current;return null==o||o.addEventListener("keydown",r),function(){null==o||o.removeEventListener("keydown",r)}}},[t,e,n])}(n,r,u);var a=document.documentElement,l=Number.parseInt(getComputedStyle(a).getPropertyValue("--divider-gap"),10);Zo([t],function(){if(r&&i&&t.current){var e=t.current.getBoundingClientRect(),n=i.getBoundingClientRect(),o=n.top-e.top,u=Math.round(e.right-n.right+n.width+l);a.style.setProperty("--modal-inset","".concat(o,"px ").concat(u,"px auto auto"))}}),se(function(){if(r){var e=function(e){var t=e.target.closest(".im-o-app__modal-backdrop");o&&t&&o.contains(t)&&u()};return document.addEventListener("click",e),function(){document.removeEventListener("click",e)}}},[r,o,u]),se(function(){if(r&&n.current&&o)return(0,ni.U)({containerEl:n.current,isFullscreen:!0,boundaryEl:o}),function(){(0,ni.U)({containerEl:n.current,isFullscreen:!1,boundaryEl:o})}},[r,n,o]),function(e,t,n){se(function(){if(e){var r=function(e){var r=e.target,o=t.current;if(r&&o&&n){var i=n.contains(r),u=o.contains(r);i&&!u&&o.focus()}};return document.addEventListener("focusin",r),function(){document.removeEventListener("focusin",r)}}},[e,t,n])}(r,n,o)}function oi(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var ii=function(e){var t=e.id,n=e.svgContent;return kt("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",focusable:"false",dangerouslySetInnerHTML:{__html:En()[t]||n}})};function ui(e){return ui="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ui(e)}function ai(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function li(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ai(Object(n),!0).forEach(function(t){ci(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ai(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ci(e,t,n){return(t=function(e){var t=function(e){if("object"!=ui(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=ui(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ui(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var fi=function(e,t){return e?"dialog":t?"complementary":"region"},si=function(e){var t,n,r,o,i,u=e.panelId,a=e.panelConfig,l=e.props,c=e.WrappedChild,f=e.label,s=e.html,p=e.children,d=e.isOpen,y=void 0===d||d,v=e.rootRef,m=Ot().id,b=Rr(),h=b.dispatch,_=b.breakpoint,g=b.layoutRefs,O=document.getElementById("".concat(m,"-im-app")),P=a[_],S="".concat(m,"-panel-").concat(zo(u)),w=function(e,t){var n="side"===e.slot&&e.initiallyOpen&&!e.modal,r=!n&&e.dismissable,o=!0===e.modal;return{isAside:n,isDialog:r,isModal:o,isDismissable:!1!==e.dismissable,shouldFocus:Boolean(o||t),buttonContainerEl:e.slot.endsWith("button")?null==t?void 0:t.parentNode:void 0}}(P,null==l?void 0:l.triggeringElement),E=w.isAside,j=w.isDialog,A=w.isModal,T=w.isDismissable,k=w.shouldFocus,R=w.buttonContainerEl,I=A&&y,D=g.mainRef,C=de(null),M=de(null),x=de(y),N=(t=M,n=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return oi(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?oi(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(ce(!1),2),r=n[0],o=n[1],i=me(function(){var e=null==t?void 0:t.current;e&&o(e.scrollHeight>e.clientHeight)},[t]),Zo(t,i),r),L=v||C,B=function(){requestAnimationFrame(function(){var e,t;null===(e=(t=(null==l?void 0:l.triggeringElement)||g.viewportRef.current).focus)||void 0===e||e.call(t)}),h({type:"CLOSE_PANEL",payload:u})};ri({mainRef:D,panelRef:L,isModal:I,isAside:E,rootEl:O,buttonContainerEl:R,handleClose:B}),se(function(){var e,t=y&&!x.current;x.current=y,k&&(t||y)&&(null===(e=L.current)||void 0===e||e.focus())},[y]);var U,H,F=(U=P.slot,H=a.showLabel,["im-c-panel","im-c-panel--".concat(U),!H&&"im-c-panel--no-heading"].filter(Boolean).join(" ")),z=function(e,t){return["im-c-panel__body",!e&&t&&"im-c-panel__body--offset"].filter(Boolean).join(" ")}(a.showLabel,T),q=ve(function(){return s?{__html:s}:null},[s]),G=function(e){var t=e.elementId,n=e.shouldFocus,r=e.isDialog,o=e.isDismissable,i=e.isModal,u=e.width,a=e.panelClass;return{id:t,"aria-labelledby":"".concat(t,"-label"),tabIndex:n?-1:void 0,role:fi(r,o),"aria-modal":r&&i?"true":void 0,style:u?{width:u}:void 0,className:a}}({elementId:S,shouldFocus:k,isDialog:j,isDismissable:T,isModal:A,width:P.width,panelClass:F}),W=function(e){var t=e.isBodyScrollable;return{ref:e.bodyRef,className:e.panelBodyClass,tabIndex:t?0:void 0,role:t?"region":void 0,"aria-labelledby":t?"".concat(e.elementId,"-label"):void 0}}({bodyRef:M,panelBodyClass:z,isBodyScrollable:N,elementId:S});return kt("div",li(li({ref:L},G),{},{children:[kt("h2",{id:"".concat(S,"-label"),className:a.showLabel?"im-c-panel__heading im-e-heading-m":"im-u-visually-hidden",children:f}),T&&kt("button",{"aria-label":"Close ".concat(f),className:"im-c-panel__close",onClick:B,children:kt(ii,{id:"close"})}),kt("div",li(li({},W),{},q?{dangerouslySetInnerHTML:q}:{children:[" ",c?kt(c,li({},l)):p]}))]}))};function pi(e){return pi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pi(e)}function di(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function yi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?di(Object(n),!0).forEach(function(t){vi(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):di(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vi(e,t,n){return(t=function(e){var t=function(e){if("object"!=pi(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=pi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==pi(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return bi(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?bi(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function bi(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function hi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||_i(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _i(e,t){if(e){if("string"==typeof e)return gi(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?gi(e,t):void 0}}function gi(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Oi(e){return Oi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Oi(e)}function Pi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Si(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Si(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Si(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var wi=0,Ei=function(e){var t=e.children,n=e.content,r=Rr().interfaceType,o=de(null),i=de(null),u=Pi(ce(!1),2),a=u[0],l=u[1],c=Pi(ce(!1),2),f=c[0],s=c[1],p=Pi(ce(null),2),d=p[0],y=p[1],v=Pi(ce(function(){return"tooltip-".concat(wi+=1)}),1)[0],m=de(null),b=de(null),h=function(){clearTimeout(m.current),l(!1)},_=function(){clearTimeout(b.current),m.current=setTimeout(function(){return l(!0)},500)},g=function(){clearTimeout(m.current),b.current=setTimeout(function(){return l(!1)},0)};se(function(){var e=function(e){"Escape"===e.key&&(clearTimeout(m.current),clearTimeout(b.current),l(!1))};if(window.addEventListener("keydown",e),a){var t=function(e,t){if(!e)return"bottom";t||(t=e.closest(".im-o-app__main"));var n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),o={top:n.top-r.top,bottom:r.bottom-n.bottom,left:n.left-r.left,right:r.right-n.right},i=Object.entries(o),u=i.toSorted(function(e,t){return hi(e,2)[1]-hi(t,2)[1]}),a=hi(u[0],2),l=a[0],c=a[1];if("top"===l||"bottom"===l){var f,s=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=_i(e))){t&&(e=t);var n=0,r=function(){};return{s:r,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,u=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return i=e.done,e},e:function(e){u=!0,o=e},f:function(){try{i||null==t.return||t.return()}finally{if(u)throw o}}}}(i);try{for(s.s();!(f=s.n()).done;){var p=hi(f.value,2),d=p[0],y=p[1];if(("left"===d||"right"===d)&&Math.abs(y-c)<=50)return"left"===d?"right":"left"}}catch(e){s.e(e)}finally{s.f()}}return{top:"bottom",bottom:"top",left:"right",right:"left"}[l]}(o.current);y(t)}return function(){window.removeEventListener("keydown",e),clearTimeout(m.current),clearTimeout(b.current)}},[a]);var O=vt(t,{ref:function(e){var n;o.current=e;var r=null===(n=t.props)||void 0===n?void 0:n.ref;"function"==typeof r?r(e):r&&"object"===Oi(r)&&(r.current=e)},onMouseEnter:_,onMouseLeave:g,onMouseDown:h,onKeyDown:h,onFocus:function(){"keyboard"===r&&_(),s(!0)},onBlur:function(){g(),s(!1)},"aria-labelledby":v});return kt("div",{className:"im-c-tooltip-wrapper".concat(f?" im-c-tooltip-wrapper--has-focus":""),children:[O,kt("div",{id:v,ref:i,className:"im-c-tooltip im-c-tooltip--".concat(d||"hidden"," ").concat(a?"im-c-tooltip--is-visible":""),role:"tooltip","aria-hidden":!a,children:n})]})};function ji(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var Ai=function(e){var t=e.popupMenuId,n=e.buttonId,r=e.instigatorId,o=e.pluginId,i=e.startPos,u=e.startIndex,a=e.menuRef,l=e.items,c=e.setIsOpen,f=Ot().id,s=Rr(),p=s.buttonRefs,d=s.buttonConfig,y=s.hiddenButtons,v=s.disabledButtons,m=s.pressedButtons,b=null!=n?n:r,h=p.current[b],_=Jr(),g=ve(function(){var e=[];return l.forEach(function(t,n){y.has(t.id)||e.push(n)}),e},[l,y]),O=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ji(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ji(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(ce(function(){return"number"==typeof u?u:"first"===i?null!==(e=g[0])&&void 0!==e?e:-1:"last"===i&&null!==(t=g[g.length-1])&&void 0!==t?t:-1;var e,t}),2),P=O[0],S=O[1],w=function(e){arguments.length>1&&void 0!==arguments[1]&&arguments[1]&&null!=e&&e.preventDefault&&e.preventDefault(),h.focus(),c(!1)},E=function(e,t){var n=d[t.id];if("function"==typeof(null==n?void 0:n.onClick)?n.onClick(e,_(function(e){return e},o)):"function"==typeof t.onClick&&t.onClick(e.nativeEvent),e.nativeEvent instanceof KeyboardEvent){var r=document.getElementById("".concat(f,"-").concat(zo(t.id)));if(r){var i=new MouseEvent("click",{bubbles:!0,cancelable:!0});i._fromKeyboardActivation=!0,r.dispatchEvent(i)}}},j=function(e){var t,n;null!==(t=a.current)&&void 0!==t&&t.contains(e.target)||null!==(n=p.current[b])&&void 0!==n&&n.contains(e.target)||c(!1)};return se(function(){var e,t;if(null===(e=a.current)||void 0===e||e.focus(),"first"===i)S(null!==(t=g[0])&&void 0!==t?t:-1);else if("last"===i){var n;S(null!==(n=g[g.length-1])&&void 0!==n?n:-1)}return document.addEventListener("focusin",j),document.addEventListener("pointerdown",j),function(){document.removeEventListener("focusin",j),document.removeEventListener("pointerdown",j)}},[]),kt("ul",{ref:a,id:t,className:"im-c-popup-menu",role:"menu",tabIndex:"-1","aria-labelledby":b,"aria-activedescendant":P>=0?"".concat(f,"-").concat(zo(l[P].id)):void 0,onKeyDown:function(e){["Escape","Esc"].includes(e.key)?w(e,!0):"Tab"!==e.key?["ArrowDown","ArrowUp"].includes(e.key)?function(e){e.preventDefault();var t=g,n=t.length;if(0!==n){var r,o=t.indexOf(P);r="ArrowDown"===e.key?-1===o?0:(o+1)%n:-1===o?n-1:(o-1+n)%n,S(t[r])}}(e):"Home"===e.key&&g.length?S(g[0]):"End"===e.key&&g.length?S(g[g.length-1]):("Enter"===e.key&&function(e){e.preventDefault();var t=l[P];t&&!v.has(t.id)&&E(e,t),h.focus(),c(!1)}(e)," "===e.key&&function(e){e.preventDefault();var t=l[P];if(t&&!v.has(t.id)){var n=void 0!==t.isPressed||t.pressedWhen;E(e,t),n||(h.focus(),c(!1))}}(e)):w(e)},children:l.map(function(e,t){return kt("li",{id:"".concat(f,"-").concat(zo(l[t].id)),className:"im-c-popup-menu__item".concat(P===t?" im-c-popup-menu__item--selected":""),role:void 0!==l[t].isPressed||l[t].pressedWhen?"menuitemcheckbox":"menuitem","aria-disabled":v.has(l[t].id)||void 0,"aria-checked":void 0!==l[t].isPressed||l[t].pressedWhen?m.has(l[t].id):void 0,style:y.has(l[t].id)?{display:"none"}:void 0,onClick:function(e){return function(e,t){e.nativeEvent._fromKeyboardActivation||v.has(t.id)||(c(!1),E(e,t))}(e,l[t])},children:[(e.iconId||e.iconSvgContent)&&kt(ii,{id:e.iconId,svgContent:e.iconSvgContent}),kt("span",{className:"im-c-popup-menu__item-label",children:e.label})]},e.id)})})};function Ti(e){return Ti="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ti(e)}function ki(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ri(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ri(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ri(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Ii(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Di(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ii(Object(n),!0).forEach(function(t){Ci(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ii(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Ci(e,t,n){return(t=function(e){var t=function(e){if("object"!=Ti(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Ti(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ti(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Mi=function(e,t,n){return["im-c-map-button",e&&"im-c-map-button--".concat(zo(e)),t&&"im-c-map-button--".concat(t),n&&"im-c-map-button--with-label"].filter(Boolean).join(" ")},xi=function(e,t,n,r,o){return["im-c-button-wrapper",e&&"im-c-button-wrapper--".concat(zo(e)),t&&"im-c-button-wrapper--wide",n&&"im-c-button-wrapper--group-start",r&&"im-c-button-wrapper--group-middle",o&&"im-c-button-wrapper--group-end"].filter(Boolean).join(" ")},Ni=function(e){" "!==e.key&&"Spacebar"!==e.key||(e.preventDefault(),e.currentTarget.click())},Li=function(e){var t=e.buttonId,n=e.iconId,r=e.iconSvgContent,o=e.label,i=e.showLabel,u=e.isDisabled,a=e.isPressed,l=e.isExpanded,c=e.isHidden,f=e.isPanelOpen,s=e.variant,p=e.onClick,d=e.panelId,y=e.menuItems,v=e.idPrefix,m=e.href,b=e.groupMiddle,h=e.groupStart,_=e.groupEnd,g=Ot().id,O=Rr().buttonRefs,P=ki(ce(!1),2),S=P[0],w=P[1],E=ki(ce(null),2),j=E[0],A=E[1],T=de(null),k=m?"a":"button",R=(null==y?void 0:y.length)>=1,I=function(e){var t=e.idPrefix,n=e.panelId,r=e.buttonId,o=e.hasMenu;return n?{id:"".concat(t,"-panel-").concat(zo(n)),type:"panel"}:o?{id:"".concat(t,"-popup-").concat(zo(r)),type:"popup"}:null}({idPrefix:v,panelId:d,buttonId:t,hasMenu:R}),D=function(e){var t,n=e.appId,r=e.buttonId,o=e.className,i=e.onClick,u=e.onKeyUp,a=e.buttonRefs,l=e.isDisabled,c=e.isPressed,f=e.isExpanded,s=e.isPanelOpen,p=e.isPopupOpen,d=e.controlledElement,y=e.href;return"panel"===(null==d?void 0:d.type)?t=String(s):"popup"===(null==d?void 0:d.type)?t=p:"boolean"==typeof f&&(t=f),Di({id:"".concat(n,"-").concat(zo(r)),className:o,onClick:i,onKeyUp:u,ref:function(e){a.current&&r&&(a.current[r]=e)},"aria-disabled":l||void 0,"aria-expanded":t,"aria-pressed":"boolean"==typeof c?c:void 0,"aria-controls":null==d?void 0:d.id,"aria-haspopup":"popup"===(null==d?void 0:d.type)||void 0},y?{href:y,target:"_blank",onKeyUp:Ni,role:"button"}:{type:"button"})}({appId:g,buttonId:t,className:Mi(t,s,i),onClick:function(e){if(!u){if("popup"===(null==I?void 0:I.type)){var t=""===e.nativeEvent.pointerType;A(t?"first":null),w(function(e){return!e})}p&&p(e)}},onKeyUp:function(e){R&&["ArrowDown","ArrowUp"].includes(e.key)&&(e.preventDefault(),A("ArrowUp"===e.key?"last":"first"),w(!0))},buttonRefs:O,isDisabled:u,isPressed:a,isExpanded:l,isPanelOpen:f,isPopupOpen:S,controlledElement:I,href:m}),C=kt(k,Di(Di({},D),{},{children:[(n||r)&&kt(ii,{id:n,svgContent:r}),i&&kt("span",{children:o})]}));return kt("div",{className:xi(t,i,h,b,_),style:c?{display:"none"}:void 0,children:[i?C:kt(Ei,{content:o,children:C}),d&&kt(Ji,{slot:"".concat(zo(t),"-button")}),S&&kt(Ai,{popupMenuId:I.id,buttonId:t,startPos:j,menuRef:T,items:y,setIsOpen:w})]})};function Bi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||Ui(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ui(e,t){if(e){if("string"==typeof e)return Hi(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Hi(e,t):void 0}}function Hi(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Fi(e){var t,n=e.btn,r=e.appState,o=e.appConfig,i=e.evaluateProp,u=e.groupStart,a=e.groupMiddle,l=e.groupEnd,c=Bi(n,2),f=c[0],s=c[1],p=null!==(t=s[r.breakpoint])&&void 0!==t?t:{},d=function(e,t,n){var r=Bi(e,2)[1],o=!(!r.panelId||!t.openPanels[r.panelId]);return function(e){if("function"!=typeof r.onClick){if(r.panelId){var i=e.currentTarget;t.dispatch({type:o?"CLOSE_PANEL":"OPEN_PANEL",payload:o?r.panelId:{panelId:r.panelId,props:{triggeringElement:i}}})}}else r.onClick(e,n(function(e){return e},r.pluginId))}}(n,r,i),y=!(!s.panelId||!r.openPanels[s.panelId]);return kt(Li,{buttonId:f,iconId:i(s.iconId,s.pluginId),iconSvgContent:i(s.iconSvgContent,s.pluginId),variant:s.variant,label:i(s.label,s.pluginId),href:i(s.href,s.pluginId),showLabel:p.showLabel,isDisabled:r.disabledButtons.has(f),isHidden:r.hiddenButtons.has(f),isPressed:void 0!==s.isPressed||s.pressedWhen?r.pressedButtons.has(f):void 0,isExpanded:void 0!==s.isExpanded||s.expandedWhen?r.expandedButtons.has(f):void 0,isPanelOpen:y,onClick:d,panelId:s.panelId,menuItems:s.menuItems,idPrefix:o.id,groupStart:u,groupMiddle:a,groupEnd:l},f)}function zi(e){return zi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},zi(e)}var qi=["evaluateProp"];function Gi(e){return function(e){if(Array.isArray(e))return Vi(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Wi(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Wi(e,t){if(e){if("string"==typeof e)return Vi(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Vi(e,t):void 0}}function Vi(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Ki(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Zi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ki(Object(n),!0).forEach(function(t){$i(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ki(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function $i(e,t,n){return(t=function(e){var t=function(e){if("object"!=zi(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=zi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==zi(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yi(e){var t=e.evaluateProp,n=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,qi),r=function(e){var t=e.slot,n=e.appState,r=e.evaluateProp,o=n.breakpoint,i=n.mode,u=n.pluginRegistry,a=n.controlConfig;return Object.values(a).filter(function(e){var r,u,a,l;if(ti(e))return!1;var c=e[o];if(!c)return!1;var f=Jo.control.includes(c.slot),s=null===(r=null===(u=e.includeModes)||void 0===u?void 0:u.includes(i))||void 0===r||r,p=null!==(a=null===(l=e.excludeModes)||void 0===l?void 0:l.includes(i))&&void 0!==a&&a;return!(!1===e.inline&&!n.isFullscreen)&&s&&!p&&c.slot===t&&f}).map(function(e){var t,n,i,a=u.registeredPlugins.find(function(t){var n;return null===(n=t.manifest)||void 0===n||null===(n=n.controls)||void 0===n?void 0:n.some(function(t){return t.id===e.id})}),l=null==a?void 0:a.id;return i=e.html?kt("div",{className:"im-c-control",dangerouslySetInnerHTML:{__html:r(e.html,l)}},e.id):kt(Ur(e.render,{pluginId:l,pluginConfig:null==a?void 0:a.config}),{},e.id),{id:e.id,type:"control",order:null!==(t=null===(n=e[o])||void 0===n?void 0:n.order)&&void 0!==t?t:0,element:i}})}(Zi({evaluateProp:t},n)),o=function(e){var t=e.slot,n=e.appState,r=e.evaluateProp,o=n.breakpoint,i=n.pluginRegistry,u=n.panelConfig,a=n.mode,l=n.openPanels,c=Object.entries(l),f=c.filter(function(e){var t,n=mi(e,1)[0],r=null===(t=u[n])||void 0===t?void 0:t[o];return null==r?void 0:r.modal}),s=f.length>0?f[f.length-1][0]:null;return c.map(function(e){var l,c=mi(e,2),f=c[0],p=c[1].props,d=u[f];if(!d)return null;if(ti(d))return null;var y=d[o];if(!y)return null;var v=Qo(y,o);if(!function(e,t,n,r){var o=r.targetSlot,i=r.slot,u=r.mode,a=r.isFullscreen,l=r.allowedModalPanelId,c="".concat(zo(e),"-button")===o;return!(!Jo.panel.includes(o)&&!c||!ei(t,u)||!1===t.inline&&!a||o!==i||n.modal&&e!==l)}(f,d,y,{targetSlot:v,slot:t,mode:a,isFullscreen:n.isFullscreen,allowedModalPanelId:s}))return null;var m=i.registeredPlugins.find(function(e){return e.id===d.pluginId}),b=null==m?void 0:m.id,h=d.render?Ur(d.render,yi(yi({},p),{},{pluginId:b,pluginConfig:null==m?void 0:m.config})):null;return{id:f,type:"panel",order:null!==(l=y.order)&&void 0!==l?l:0,element:kt(si,{panelId:f,panelConfig:d,props:p,WrappedChild:h,label:r(d.label,b),html:b?r(d.html,b):d.html},f)}}).filter(Boolean)}(Zi({evaluateProp:t},n)),i=function(e){var t=e.slot,n=e.appState,r=e.appConfig,o=e.evaluateProp,i=n.buttonConfig,u=n.breakpoint,a=function(e){var t=e.appState,n=e.buttonConfig,r=e.slot,o=e.evaluateProp,i=t.breakpoint,u=t.mode;return n?Object.entries(n).filter(function(e){var n,a,l=Bi(e,2),c=(l[0],l[1]),f=c[i];return!(c.isMenuItem||"function"==typeof c.excludeWhen&&o(c.excludeWhen,c.pluginId)||c.includeModes&&(null===(n=c.includeModes)||void 0===n||!n.includes(u))||null!==(a=c.excludeModes)&&void 0!==a&&a.includes(u)||!1===c.inline&&!t.isFullscreen||(null==f?void 0:f.slot)!==r||!Jo.button.includes(f.slot))}):[]}({appState:n,appConfig:r,buttonConfig:i,slot:t,evaluateProp:o});if(!a.length)return[];var l=new Map;a.forEach(function(e,t){var n=Bi(e,2)[1].group;null!=n&&(l.has(n)||l.set(n,[]),l.get(n).push(t))});var c,f=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=Ui(e))){t&&(e=t);var n=0,r=function(){};return{s:r,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,u=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return i=e.done,e},e:function(e){u=!0,o=e},f:function(){try{i||null==t.return||t.return()}finally{if(u)throw o}}}}(l);try{for(f.s();!(c=f.n()).done;){var s=Bi(c.value,2),p=s[0];s[1].length<2&&l.delete(p)}}catch(e){f.e(e)}finally{f.f()}return a.map(function(e,t){var i,a,c=Bi(e,2),f=c[0],s=c[1],p=s.group,d=null==p?null:l.get(p),y=!!d&&t===d[0],v=!!d&&t===d[d.length-1],m=d&&d.length>=3&&!y&&!v;return{id:f,type:"button",order:null!==(i=null===(a=s[u])||void 0===a?void 0:a.order)&&void 0!==i?i:0,element:Fi({btn:e,appState:n,appConfig:r,evaluateProp:o,groupStart:y,groupMiddle:m,groupEnd:v})}})}(Zi({evaluateProp:t},n)),u=[].concat(Gi(r),Gi(o),Gi(i)),a=u.filter(function(e){return null==e.order||0===e.order}),l=u.filter(function(e){return null!=e.order&&0!==e.order});l.sort(function(e,t){return e.order-t.order});var c,f=Gi(a),s=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=Wi(e))){t&&(e=t);var n=0,r=function(){};return{s:r,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,u=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return i=e.done,e},e:function(e){u=!0,o=e},f:function(){try{i||null==t.return||t.return()}finally{if(u)throw o}}}}(l);try{for(s.s();!(c=s.n()).done;){var p=c.value,d=Math.min(Math.max(p.order-1,0),f.length);f.splice(d,0,p)}}catch(e){s.e(e)}finally{s.f()}return f}var Xi=function(e){var t=e.children,n=Rr(),r=n.openPanels,o=n.panelConfig,i=n.breakpoint,u=bt.Children.toArray(t).find(function(e){var t;return!1===(null===(t=e.props)||void 0===t?void 0:t.isHidden)});return kt("div",{className:["im-c-panel","im-c-actions",!u&&"im-c-actions--hidden",Object.keys(r).some(function(e){var t;return"mobile"===i&&"bottom"===(null===(t=o[e])||void 0===t||null===(t=t[i])||void 0===t?void 0:t.slot)})&&"im-c-actions--border-top"].filter(Boolean).join(" "),children:t})},Ji=function(e){var t=e.slot,n=Yi({slot:t,appConfig:Ot(),appState:Rr(),evaluateProp:Jr()});return n.length?kt(S,{children:"actions"===t?kt(Xi,{slot:t,children:n.map(function(e){return e.element})}):kt(S,{children:n.map(function(e){return e.element})})}):null};function Qi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,u,a=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(u=n.return(),Object(u)!==u))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return eu(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?eu(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function eu(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var tu=function(e,t,n,r,o){se(function(){var o=e.current;if(n){var i=function(e,t){return{side:t.sideRef,banner:t.bannerRef,"top-left":t.topLeftColRef,"top-right":t.topRightColRef,inset:t.insetRef,middle:t.middleRef,bottom:t.bottomRef,actions:t.actionsRef,modal:t.modalRef}[e]||null}(t,r);null!=i&&i.current&&(i.current.appendChild(o),o.style.display="")}else o.style.display="none";return function(){o.style.display="none"}},[n,t,r,o,e])},nu=function(e){var t=e.panelId,n=e.config,r=e.isOpen,o=e.openPanelProps,i=e.allowedModalPanelId,u=e.appState,a=de(null),l=u.breakpoint,c=u.mode,f=u.isFullscreen,s=u.layoutRefs,p=n[l],d=p?Qo(p,l):null,y=function(){if(!r||!p||!d)return!1;var e="".concat(zo(t),"-button")===d;if(!Jo.panel.includes(d)&&!e)return!1;var o=p.modal&&t!==i,u=!1===n.inline&&!f,a=!ei(n,c);return!(o||u||a)}();return tu(a,d,y,s,l),kt(si,{panelId:t,panelConfig:n,props:o,html:n.html,label:n.label,isOpen:r,rootRef:a})},ru=function(e){var t=e.control,n=e.appState,r=de(null),o=n.breakpoint,i=n.mode,u=n.isFullscreen,a=n.layoutRefs,l=t[o],c=function(e,t){var n=t.mode,r=t.isFullscreen,o=e[t.breakpoint];return!(!o||!Jo.control.includes(o.slot)||!ei(e,n)||!1===e.inline&&!r)}(t,{breakpoint:o,mode:i,isFullscreen:u}),f=(null==l?void 0:l.slot)||null;return tu(r,f,c,a,o),kt("div",{ref:r,className:"im-c-control",style:{display:"none"},dangerouslySetInnerHTML:ve(function(){return{__html:t.html}},[t.html])})},ou=function(){var e=Rr(),t=e.panelConfig,n=void 0===t?{}:t,r=e.controlConfig,o=void 0===r?{}:r,i=e.openPanels,u=void 0===i?{}:i,a=e.breakpoint,l=ve(function(){return Object.entries(n).filter(function(e){var t=Qi(e,2),n=(t[0],t[1]);return ti(n)})},[n]),c=ve(function(){return Object.values(o).filter(function(e){return ti(e)})},[o]),f=ve(function(){var e=Object.entries(u).filter(function(e){var t,r=Qi(e,1)[0],o=null===(t=n[r])||void 0===t?void 0:t[a];return null==o?void 0:o.modal});return e.length>0?e[e.length-1][0]:null},[u,n,a]);return l.length||c.length?kt(S,{children:[l.map(function(t){var n,r=Qi(t,2),o=r[0],i=r[1];return kt(nu,{panelId:o,config:i,isOpen:!!u[o],openPanelProps:null===(n=u[o])||void 0===n?void 0:n.props,allowedModalPanelId:f,appState:e},o)}),c.map(function(t){return kt(ru,{control:t,appState:e},t.id)})]}):null},iu=function(){var e=Ot().id,t=Rr(),n=t.breakpoint,r=t.interfaceType,o=t.preferredColorScheme,i=t.layoutRefs,u=t.isLayoutReady,a=t.hasExclusiveControl,l=t.isFullscreen,c=Ir().mapStyle;return function(){var e=Rr(),t=e.dispatch,n=e.breakpoint,r=e.layoutRefs,o=Ir(),i=o.mapSize,u=o.isMapReady,a=r.appContainerRef,l=r.mainRef,c=r.bannerRef,f=r.topRef,s=r.topLeftColRef,p=r.topRightColRef,d=r.insetRef,y=r.footerRef,v=r.actionsRef,m=function(){var e=a.current,t=l.current,n=f.current,r=s.current,o=p.current,i=d.current,u=y.current,c=v.current;if(t&&n&&i&&u){var m=document.documentElement,b=Number.parseInt(getComputedStyle(m).getPropertyValue("--divider-gap"),10),h=r.offsetHeight+n.offsetTop,_=t.offsetHeight-h-n.offsetTop;e.style.setProperty("--inset-offset-top","".concat(h,"px")),e.style.setProperty("--inset-max-height","".concat(_,"px"));var g=i.offsetHeight+h,O=Math.min(u.offsetTop,c.offsetTop)-b>g?0:i.offsetLeft+i.offsetWidth;e.style.setProperty("--offset-left","".concat(O,"px"));var P=o.offsetHeight+n.offsetTop,S=t.offsetHeight-u.offsetTop+b;e.style.setProperty("--right-offset-top","".concat(P,"px")),e.style.setProperty("--right-offset-bottom","".concat(S,"px"));var w=r.offsetWidth||0,E=o.offsetWidth||0,j=w||E?Math.max(w,E):0;e.style.setProperty("--top-col-width","".concat(j,"px"))}};pe(function(){requestAnimationFrame(function(){m();var e=bo(r);t({type:"SET_SAFE_ZONE_INSET",payload:{safeZoneInset:e}})})},[n,i,u]),Zo([c,l,f,v,y],function(){requestAnimationFrame(function(){m()})})}(),function(){var e=Rr(),t=e.interfaceType,n=e.layoutRefs,r=de(t);r.current=t,se(function(){if(n.appContainerRef.current)return document.addEventListener("focusin",e),document.addEventListener("focusout",t),document.addEventListener("pointerdown",o),function(){document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),document.removeEventListener("pointerdown",o)};function e(e){e.target.dataset.focusVisible="keyboard"===r.current}function t(e){delete e.target.dataset.focusVisible}function o(){delete document.activeElement.dataset.focusVisible}},[n.appContainerRef])}(),kt("div",{id:"".concat(e,"-im-app"),className:["im-o-app","im-o-app--".concat(n),"im-o-app--".concat(r),"im-o-app--".concat(l?"fullscreen":"inline"),"im-o-app--".concat((null==c?void 0:c.appColorScheme)||o,"-app"),"im-o-app--".concat((null==c?void 0:c.mapColorScheme)||"light","-map"),a&&"im-o-app--exclusive-control"].filter(Boolean).join(" "),style:{backgroundColor:(null==c?void 0:c.backgroundColor)||void 0},ref:i.appContainerRef,children:[kt(Vo,{keyboardHintPortalRef:i.topRef}),kt("div",{className:"im-o-app__overlay".concat(u?"":" im-o-app__overlay--not-ready"),children:[kt("div",{className:"im-o-app__side",ref:i.sideRef,children:kt(Ji,{slot:Xo.SIDE})}),kt("div",{className:"im-o-app__main",ref:i.mainRef,children:[["mobile","tablet"].includes(n)&&kt("div",{className:"im-o-app__banner",ref:i.bannerRef,children:kt(Ji,{slot:Xo.BANNER})}),kt("div",{className:"im-o-app__top",ref:i.topRef,children:[kt("div",{className:"im-o-app__top-col",ref:i.topLeftColRef,children:kt(Ji,{slot:Xo.TOP_LEFT})}),kt("div",{className:"im-o-app__top-col",children:[kt(Ji,{slot:Xo.TOP_MIDDLE}),["desktop"].includes(n)&&kt("div",{className:"im-o-app__banner",ref:i.bannerRef,children:kt(Ji,{slot:Xo.BANNER})})]}),kt("div",{className:"im-o-app__top-col",ref:i.topRightColRef,children:kt(Ji,{slot:Xo.TOP_RIGHT})})]}),kt("div",{className:"im-o-app__inset",ref:i.insetRef,children:kt(Ji,{slot:Xo.INSET})}),kt("div",{className:"im-o-app__right",ref:i.rightRef,children:[kt("div",{className:"im-o-app__right-top",children:kt(Ji,{slot:Xo.RIGHT_TOP})}),kt("div",{className:"im-o-app__right-bottom",children:kt(Ji,{slot:Xo.RIGHT_BOTTOM})})]}),kt("div",{className:"im-o-app__middle",ref:i.middleRef,children:kt(Ji,{slot:Xo.MIDDLE})}),kt("div",{className:"im-o-app__footer",ref:i.footerRef,children:[kt("div",{className:"im-o-app__footer-col",children:kt($o,{})}),kt("div",{className:"im-o-app__footer-col",children:[kt(Ji,{slot:Xo.FOOTER_RIGHT}),kt("div",{className:"im-o-app__attributions",children:kt(Yo,{})})]})]}),kt("div",{className:"im-o-app__bottom",ref:i.bottomRef,children:kt(Ji,{slot:Xo.BOTTOM})}),kt("div",{className:"im-o-app__actions",ref:i.actionsRef,children:kt(Ji,{slot:Xo.ACTIONS})})]})]}),kt(ou,{}),kt("div",{className:"im-o-app__modal",ref:i.modalRef,children:[kt(Ji,{slot:Xo.MODAL}),kt("div",{className:"im-o-app__modal-backdrop"})]})]})},uu=function(e){return se(function(){(0,Or.i)(),e.eventBus.emit(_t.q.APP_READY)},[]),kt(rr,{options:e,children:kt(br,{options:e,children:kt(gr,{eventBus:e.eventBus,children:kt(Tr,{children:[kt(uo,{}),kt(iu,{})]})})})})};function au(e){return au="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},au(e)}var lu=["id","load","manifest"],cu=["InitComponent","api","reducer"],fu=["MapProvider","mapProviderConfig","mapFramework","plugins"];function su(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function pu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?su(Object(n),!0).forEach(function(t){du(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):su(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function du(e,t,n){return(t=function(e){var t=function(e){if("object"!=au(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=au(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==au(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yu(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var l=r&&r.prototype instanceof a?r:a,c=Object.create(l.prototype);return vu(c,"_invoke",function(n,r,o){var i,a,l,c=0,f=o||[],s=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,l=e,p.n=n,u}};function d(n,r){for(a=n,l=r,t=0;!s&&c&&!o&&t<f.length;t++){var o,i=f[t],d=p.p,y=i[2];n>3?(o=y===r)&&(l=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=n<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<y&&(o=n<3||i[0]>r||r>y)&&(i[4]=n,i[5]=r,p.n=y,a=0))}if(o||n>1)return u;throw s=!0,r}return function(o,f,y){if(c>1)throw TypeError("Generator is already running");for(s&&1===f&&d(f,y),a=f,l=y;(t=a<2?e:l)||!s;){i||(a?a<3?(a>1&&(p.n=-1),d(a,l)):p.n=l:p.v=l);try{if(c=2,i){if(a||(o="next"),t=i[o]){if(!(t=t.call(i,l)))throw TypeError("iterator result is not an object");if(!t.done)return t;l=t.value,a<2&&(a=0)}else 1===a&&(t=i.return)&&t.call(i),a<2&&(l=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((t=(s=p.n<0)?l:n.call(r,p))!==u)break}catch(t){i=e,a=1,l=t}finally{c=1}}return{value:t,done:s}}}(n,o,i),!0),c}var u={};function a(){}function l(){}function c(){}t=Object.getPrototypeOf;var f=[][r]?t(t([][r]())):(vu(t={},r,function(){return this}),t),s=c.prototype=a.prototype=Object.create(f);function p(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,vu(e,o,"GeneratorFunction")),e.prototype=Object.create(s),e}return l.prototype=c,vu(s,"constructor",c),vu(c,"constructor",l),l.displayName="GeneratorFunction",vu(c,o,"GeneratorFunction"),vu(s),vu(s,o,"Generator"),vu(s,r,function(){return this}),vu(s,"toString",function(){return"[object Generator]"}),(yu=function(){return{w:i,m:p}})()}function vu(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}vu=function(e,t,n,r){function i(t,n){vu(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},vu(e,t,n,r)}function mu(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function bu(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return hu(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?hu(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,u=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return u=e.done,e},e:function(e){a=!0,i=e},f:function(){try{u||null==n.return||n.return()}finally{if(a)throw i}}}}function hu(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function _u(e,t,n,r,o,i,u){try{var a=e[i](u),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function gu(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function u(e){_u(i,r,o,u,a,"next",e)}function a(e){_u(i,r,o,u,a,"throw",e)}u(void 0)})}}var Ou=new WeakMap,Pu=new WeakMap,Su=new WeakMap,wu=function(e){var t,n,r,o,i,u,a,l=Su.get(e);if(!l){var c=rn(),f=(n={},{registerPanel:function(e){n=sn(n,e)},addPanel:function(e,t){return(n=pn(n,e,t))[e]},removePanel:function(e){n=dn(n,e)},getPanelConfig:function(){return n},clear:function(){n={}}}),s=(t={},{registerControl:function(e){t=hn(t,e)},addControl:function(e,n){return(t=_n(t,e,n))[e]},getControlConfig:function(){return t},clear:function(){t={}}});l={buttonRegistry:c,panelRegistry:f,controlRegistry:s,pluginRegistry:(r={registerButton:c.registerButton,registerPanel:f.registerPanel,registerControl:s.registerControl},o=r.registerButton,i=r.registerPanel,u=r.registerControl,a=[],{registeredPlugins:a,registerPlugin:function(e){var t,n,r=e.manifest,l={pluginId:e.id,includeModes:null===(t=e.config)||void 0===t?void 0:t.includeModes,excludeModes:null===(n=e.config)||void 0===n?void 0:n.excludeModes};r.buttons&&Rn(r.buttons).forEach(function(e){var t;o(kn({},e.id,Tn(Tn({},l),e))),null==e||null===(t=e.menuItems)||void 0===t||t.forEach(function(e){o(kn({},e.id,Tn(Tn(Tn({},l),e),{},{isMenuItem:!0})))})}),r.panels&&Rn(r.panels).forEach(function(e){i(kn({},e.id,Tn(Tn({},l),e)))}),r.controls&&Rn(r.controls).forEach(function(e){u(kn({},e.id,Tn(Tn({},l),e)))}),r.icons&&Rn(r.icons).forEach(function(e){return function(e){wn=Pn(Pn({},wn),e)}(kn({},e.id,e.svgContent))}),r.keyboardShortcuts&&Rn(r.keyboardShortcuts).forEach(function(e){return function(e){var t=e.shortcut;Et.has(t.id)||(Et.add(t.id),wt.push(t))}(Tn(Tn({},l),{},{shortcut:e}))}),a.push(e)},clear:function(){a.length=0}})},Su.set(e,l)}return l},Eu=function(){var e=gu(yu().m(function e(t,n){var r,o,i,u,a,l,c,f,s,p,d,y,v;return yu().w(function(e){for(;;)switch(e.p=e.n){case 0:r=bu(t),e.p=1,r.s();case 2:if((o=r.n()).done){e.n=5;break}if("function"!=typeof(i=o.value).load){e.n=4;break}return e.n=3,i.load();case 3:u=e.v,a=i.id,i.load,l=i.manifest,c=mu(i,lu),f=u.InitComponent,s=u.api,p=u.reducer,d=mu(u,cu),y=xn(d,l),n({id:a,InitComponent:f,api:s,reducer:p,config:c,manifest:y,_originalPlugin:i});case 4:e.n=2;break;case 5:e.n=7;break;case 6:e.p=6,v=e.v,r.e(v);case 7:return e.p=7,r.f(),e.f(7);case 8:return e.a(2)}},e,null,[[1,6,7,8]])}));return function(t,n){return e.apply(this,arguments)}}();function ju(e,t){return Au.apply(this,arguments)}function Au(){return(Au=gu(yu().m(function e(t,n){var r,o,i,u,a,l,c,f,s,p,d,y,v,m,b,h,_;return yu().w(function(e){for(;;)switch(e.n){case 0:return o=n.MapProvider,i=n.mapProviderConfig,u=n.mapFramework,a=n.plugins,l=void 0===a?[]:a,c=mu(n,fu),f=c.eventBus,(s=Pu.get(t))||(s=new o({mapFramework:u,mapProviderConfig:i,events:_t.q,eventBus:f}),Pu.set(t,s)),null!==(r=s.capabilities)&&void 0!==r&&r.supportedShortcuts&&At(s.capabilities.supportedShortcuts),p=wu(t),d=p.buttonRegistry,y=p.panelRegistry,v=p.controlRegistry,m=p.pluginRegistry,b=m.registerPlugin,m.clear(),b({id:"appConfig",manifest:Ut}),(h=Ou.get(t))||(h=ht(t),Ou.set(t,h)),_={_root:h,on:f.on,off:f.off,emit:f.emit,unmount:function(){var e,n;h.unmount(),Ou.delete(t),null===(e=(n=s).destroyMap)||void 0===e||e.call(n),Pu.delete(t),m.clear()}},e.n=1,Eu(l,b);case 1:return h.render(kt(uu,pu(pu({},c),{},{buttonRegistry:d,panelRegistry:y,controlRegistry:v,pluginRegistry:m,mapProvider:s}))),e.a(2,_)}},e)}))).apply(this,arguments)}},"./src/InteractiveMap/domStateManager.js"(e,t,n){n.d(t,{N:()=>a,i:()=>l});var r=n("./src/utils/queryString.js"),o=n("./src/utils/toggleInertElements.js"),i=n("./src/utils/getIsFullscreen.js"),u=n("./src/config/defaults.js");function a(e){var t=e.config,n=e.rootEl,a=t.pageTitle,l=t.behaviour,c=t.containerHeight,f=function(e){var t=e.id,n=e.behaviour,o=(0,r.q)(u.A.mapViewParamKey)===t;return"mapOnly"===n||o&&("buttonFirst"===n||(0,i.w)(e))}(t);["mapOnly","buttonFirst","hybrid"].includes(l)&&((0,o.U)({containerEl:n,isFullscreen:f}),document.documentElement.classList.toggle("im-is-fullscreen",f),n.classList.toggle("im-is-fullscreen",f)),["buttonFirst","hybrid"].includes(l)&&function(e){var t=e.pageTitle,n=e.isFullscreen,r=document.title.split(": "),o=r[r.length-1];document.title=n?"".concat(t,": ").concat(o):o}({pageTitle:a,isFullscreen:f});var s=f||"buttonFirst"!==l&&!(0,i.w)(t)?c:"auto";n.style.height=f?"100%":s}function l(){document.body.classList.remove("im-is-loading")}},"./src/config/defaults.js"(e,t,n){n.d(t,{A:()=>r});const r={appColorScheme:"light",autoColorScheme:!1,backgroundColor:"var(--background-color)",behaviour:"buttonFirst",buttonClass:"im-c-open-map-button",buttonText:"Map view",containerHeight:"600px",deviceNotSupportedText:"Your device is not supported. A map is available with a more up-to-date browser or device.",enableFullscreen:!1,enableZoomControls:!1,genericErrorText:"There was a problem loading the map. Please try again later.",hasExitButton:!1,hybridWidth:null,keyboardHintText:'<span class="im-u-visually-hidden">Press </span><kbd>Alt</kbd> + <kbd>K</kbd> <span class="im-u-visually-hidden">to view </span>keyboard shortcuts',mapLabel:"Interactive map",mapProvider:null,mapSize:"small",mapViewParamKey:"mv",maxMobileWidth:640,minDesktopWidth:835,markerColor:"#ff0000",markerShape:"pin",nudgePanDelta:5,nudgeZoomDelta:.1,panDelta:100,pageTitle:"Map view",preserveStateOnClose:!1,readMapText:!1,reverseGeocodeProvider:null,zoomDelta:1}},"./src/config/events.js"(e,t,n){n.d(t,{q:()=>r});var r={APP_ADD_MARKER:"app:addmarker",APP_REMOVE_MARKER:"app:removemarker",APP_SET_MODE:"app:setmode",APP_REVERT_MODE:"app:revertmode",APP_ADD_BUTTON:"app:addbutton",APP_TOGGLE_BUTTON_STATE:"app:togglebuttonstate",APP_ADD_PANEL:"app:addpanel",APP_REMOVE_PANEL:"app:removepanel",APP_SHOW_PANEL:"app:showpanel",APP_HIDE_PANEL:"app:hidepanel",APP_ADD_CONTROL:"app:addcontrol",APP_READY:"app:ready",APP_PANEL_OPENED:"app:panelopened",APP_PANEL_CLOSED:"app:panelclosed",MAP_SET_STYLE:"map:setstyle",MAP_SET_SIZE:"map:setsize",MAP_SET_PIXEL_RATIO:"map:setpixelratio",MAP_INIT_MAP_STYLES:"map:initmapstyles",MAP_STYLE_CHANGE:"map:stylechange",MAP_LOADED:"map:loaded",MAP_READY:"map:ready",MAP_FIRST_IDLE:"map:firstidle",MAP_MOVE_START:"map:movestart",MAP_MOVE:"map:move",MAP_MOVE_END:"map:moveend",MAP_STATE_UPDATED:"map:stateupdated",MAP_DATA_CHANGE:"map:datachange",MAP_RENDER:"map:render",MAP_CLICK:"map:click",MAP_EXIT:"map:exit",MAP_DESTROY:"map:destroy"}},"./src/services/reverseGeocode.js"(e,t,n){function r(){var e,t,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",u=n.toStringTag||"@@toStringTag";function a(n,r,i,u){var a=r&&r.prototype instanceof c?r:c,f=Object.create(a.prototype);return o(f,"_invoke",function(n,r,o){var i,u,a,c=0,f=o||[],s=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,u=0,a=e,p.n=n,l}};function d(n,r){for(u=n,a=r,t=0;!s&&c&&!o&&t<f.length;t++){var o,i=f[t],d=p.p,y=i[2];n>3?(o=y===r)&&(a=i[(u=i[4])?5:(u=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=n<2&&d<i[1])?(u=0,p.v=r,p.n=i[1]):d<y&&(o=n<3||i[0]>r||r>y)&&(i[4]=n,i[5]=r,p.n=y,u=0))}if(o||n>1)return l;throw s=!0,r}return function(o,f,y){if(c>1)throw TypeError("Generator is already running");for(s&&1===f&&d(f,y),u=f,a=y;(t=u<2?e:a)||!s;){i||(u?u<3?(u>1&&(p.n=-1),d(u,a)):p.n=a:p.v=a);try{if(c=2,i){if(u||(o="next"),t=i[o]){if(!(t=t.call(i,a)))throw TypeError("iterator result is not an object");if(!t.done)return t;a=t.value,u<2&&(u=0)}else 1===u&&(t=i.return)&&t.call(i),u<2&&(a=TypeError("The iterator does not provide a '"+o+"' method"),u=1);i=e}else if((t=(s=p.n<0)?a:n.call(r,p))!==l)break}catch(t){i=e,u=1,a=t}finally{c=1}}return{value:t,done:s}}}(n,i,u),!0),f}var l={};function c(){}function f(){}function s(){}t=Object.getPrototypeOf;var p=[][i]?t(t([][i]())):(o(t={},i,function(){return this}),t),d=s.prototype=c.prototype=Object.create(p);function y(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,s):(e.__proto__=s,o(e,u,"GeneratorFunction")),e.prototype=Object.create(d),e}return f.prototype=s,o(d,"constructor",s),o(s,"constructor",f),f.displayName="GeneratorFunction",o(s,u,"GeneratorFunction"),o(d),o(d,u,"Generator"),o(d,i,function(){return this}),o(d,"toString",function(){return"[object Generator]"}),(r=function(){return{w:a,m:y}})()}function o(e,t,n,r){var i=Object.defineProperty;try{i({},"",{})}catch(e){i=0}o=function(e,t,n,r){function u(t,n){o(e,t,function(e){return this._invoke(t,n,e)})}t?i?i(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(u("next",0),u("throw",1),u("return",2))},o(e,t,n,r)}function i(e,t,n,r,o,i,u){try{var a=e[i](u),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}n.d(t,{H:()=>a,R:()=>l});var u=null;function a(e,t){var n=e.url,o=e.transformRequest,a=e.load;u=function(){var e,u=(e=r().m(function e(i,u){var l;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,a();case 1:return l=e.v,e.a(2,l(n,o,t,i,u))}},e)}),function(){var t=this,n=arguments;return new Promise(function(r,o){var u=e.apply(t,n);function a(e){i(u,r,o,a,l,"next",e)}function l(e){i(u,r,o,a,l,"throw",e)}a(void 0)})});return function(e,t){return u.apply(this,arguments)}}()}function l(e,t){if(!u)throw new Error("ReverseGeocode not initialised");return u(e,t)}},"./src/utils/detectInterfaceType.js"(e,t,n){n.d(t,{C1:()=>u,Ey:()=>l,ip:()=>a});var r=window.matchMedia("(pointer: coarse)").matches?"touch":"unknown",o=new Set;function i(e){r!==e&&(r=e,o.forEach(function(t){t(e)}))}function u(){var e=window.matchMedia("(pointer: coarse)"),t=function(e){i(e.matches?"touch":"mouse")};e.addEventListener("change",t);var n=function(e){var t,n="pen"===(t=e.pointerType)||"touch"===t?"touch":"mouse"===t?"mouse":"unknown";setTimeout(function(){return i(n)},150)},r=function(e){"Tab"===e.key&&i("keyboard")};return window.addEventListener("pointerdown",n,{passive:!0}),window.addEventListener("keydown",r,{passive:!0}),function(){e.removeEventListener("change",t),window.removeEventListener("pointerdown",n),window.removeEventListener("keydown",r)}}function a(){return"unknown"===r?(r="mouse","mouse"):r}function l(e){return o.add(e),function(){o.delete(e)}}},"./src/utils/getIsFullscreen.js"(e,t,n){n.d(t,{g:()=>o,w:()=>r});var r=function(e){var t=e.behaviour,n=e.hybridWidth,r=e.maxMobileWidth;if("hybrid"!==t)return!1;var o=null!=n?n:r;return window.matchMedia("(max-width: ".concat(o,"px)")).matches},o=function(e){var t=e.behaviour;return["mapOnly","buttonFirst"].includes(t)||r(e)}},"./src/utils/queryString.js"(e,t,n){n.d(t,{q:()=>r});var r=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null===(t=window.location)||void 0===t?void 0:t.search;return new URLSearchParams(n).get(e)}},"./src/utils/toggleInertElements.js"(e,t,n){function r(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return o(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,u=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw u}}}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,{U:()=>u});var i=function(e,t,n,r){return e!==t&&!(null!=n&&n.contains(e))&&e.matches(":not([aria-hidden]):not([data-fm-inert])")&&r.contains(e)};function u(e){var t,n=e.containerEl,o=e.isFullscreen,u=e.boundaryEl,a=void 0===u?document.body:u,l=Array.from(a.querySelectorAll("[data-fm-inert]"));if(n&&(l=l.filter(function(e){return!n.contains(e)})),l.forEach(function(e){e.removeAttribute("aria-hidden"),delete e.dataset.fmInert}),o){null===(t=document.activeElement)||void 0===t||t.blur();for(var c=n;null!==(f=c)&&void 0!==f&&f.parentNode&&c!==a&&c!==document.body;){var f,s,p=c.parentNode,d=r(p.children);try{for(d.s();!(s=d.n()).done;){var y=s.value;i(y,c,n,a)&&(y.setAttribute("aria-hidden","true"),y.dataset.fmInert="")}}catch(e){d.e(e)}finally{d.f()}c=p}}}}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}if(n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},"undefined"!=typeof crypto&&!crypto.randomUUID){var r=0;crypto.randomUUID=function(){return r=Math.max(Date.now(),r+1),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e,t){var n=t<12?Number.parseInt(r.toString(16).padStart(12,"0")[t],16):16*Math.random()|0;return("x"===e?n:3&n|8).toString(16)})}}var o="undefined"!=typeof AbortController&&!Object.getPrototypeOf((new AbortController).signal).throwIfAborted;if(o&&(Object.getPrototypeOf((new AbortController).signal).throwIfAborted=function(){if(this.aborted){var e=new Error("The operation was aborted.");throw e.name="AbortError",e}}),o&&"undefined"!=typeof URL&&URL.createObjectURL){var i=URL.createObjectURL.bind(URL);URL.createObjectURL=function(e){return e instanceof Blob&&"text/javascript"===e.type&&(e=new Blob(['if(typeof AbortController!=="undefined"){var _p=Object.getPrototypeOf(new AbortController().signal);if(!_p.throwIfAborted){_p.throwIfAborted=function(){if(this.aborted){var e=new Error("The operation was aborted.");e.name="AbortError";throw e}}}}\n',e],{type:"text/javascript"})),i(e)}}var u=n("./src/utils/queryString.js"),a=n("./src/utils/getIsFullscreen.js"),l=n("./src/config/defaults.js");function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function f(e){var t,n;e._isHidden?null===(t=e.showApp)||void 0===t||t.call(e):null===(n=e.loadApp)||void 0===n||n.call(e)}function s(e){var t,n;e.config.preserveStateOnClose?null===(t=e.hideApp)||void 0===t||t.call(e):null===(n=e.removeApp)||void 0===n||n.call(e)}function p(){var e,t=(0,u.q)(l.A.mapViewParamKey),n=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return c(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?c(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,u=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return u=e.done,e},e:function(e){a=!0,i=e},f:function(){try{u||null==n.return||n.return()}finally{if(a)throw i}}}}(d.values());try{for(n.s();!(e=n.n()).done;){var r,o=e.value,i=o.id===t,p="hybrid"===o.config.behaviour&&!(0,a.w)(o.config),y=null===(r=o.rootEl)||void 0===r?void 0:r.children.length;!i||y&&!o._isHidden?i||!y||p||s(o):f(o)}}catch(e){n.e(e)}finally{n.f()}}var d=new Map,y=!1;const v=function(e){y||(window.addEventListener("popstate",p),y=!0),d.set(e.id,e)},m=function(e){d.delete(e.id)};function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}function h(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function _(e,t,n){return(t=function(e){var t=function(e){if("object"!=b(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=b(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==b(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function g(e){try{return JSON.parse(e)}catch(e){return console.log(e),null}}function O(e,t){e.innerHTML='<div class="im-c-error">'.concat(t,"</div>")}var P=n("./src/InteractiveMap/domStateManager.js");function S(e){var t=e.id,n=e.behaviour,r=(0,u.q)(l.A.mapViewParamKey)===t;return["mapOnly","inline"].includes(n)||"hybrid"===n&&!(0,a.w)(e)||r}function w(e){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w(e)}function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function j(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach(function(t){A(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function A(e,t,n){return(t=function(e){var t=function(e){if("object"!=w(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=w(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==w(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var T=n("./src/utils/detectInterfaceType.js"),k=n("./src/services/reverseGeocode.js"),R=n("./src/config/events.js");function I(e){return I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},I(e)}function D(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,C(r.key),r)}}function C(e){var t=function(e){if("object"!=I(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=I(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==I(t)?t:t+""}var M=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.events={}},t=[{key:"on",value:function(e,t){return this.events[e]||(this.events[e]=[]),this.events[e].push(t),this}},{key:"off",value:function(e,t){return this.events[e]?(this.events[e]=t?this.events[e].filter(function(e){return e!==t}):[],this):this}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return this.events[e]?(this.events[e].forEach(function(t){try{t.apply(void 0,n)}catch(t){console.error("Error in event handler for '".concat(e,"':"),t)}}),this):this}},{key:"destroy",value:function(){this.events={}}}],t&&D(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();new M;var x=n("./src/utils/toggleInertElements.js");function N(e){return N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},N(e)}function L(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var l=r&&r.prototype instanceof a?r:a,c=Object.create(l.prototype);return B(c,"_invoke",function(n,r,o){var i,a,l,c=0,f=o||[],s=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,l=e,p.n=n,u}};function d(n,r){for(a=n,l=r,t=0;!s&&c&&!o&&t<f.length;t++){var o,i=f[t],d=p.p,y=i[2];n>3?(o=y===r)&&(l=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=n<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<y&&(o=n<3||i[0]>r||r>y)&&(i[4]=n,i[5]=r,p.n=y,a=0))}if(o||n>1)return u;throw s=!0,r}return function(o,f,y){if(c>1)throw TypeError("Generator is already running");for(s&&1===f&&d(f,y),a=f,l=y;(t=a<2?e:l)||!s;){i||(a?a<3?(a>1&&(p.n=-1),d(a,l)):p.n=l:p.v=l);try{if(c=2,i){if(a||(o="next"),t=i[o]){if(!(t=t.call(i,l)))throw TypeError("iterator result is not an object");if(!t.done)return t;l=t.value,a<2&&(a=0)}else 1===a&&(t=i.return)&&t.call(i),a<2&&(l=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((t=(s=p.n<0)?l:n.call(r,p))!==u)break}catch(t){i=e,a=1,l=t}finally{c=1}}return{value:t,done:s}}}(n,o,i),!0),c}var u={};function a(){}function l(){}function c(){}t=Object.getPrototypeOf;var f=[][r]?t(t([][r]())):(B(t={},r,function(){return this}),t),s=c.prototype=a.prototype=Object.create(f);function p(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,B(e,o,"GeneratorFunction")),e.prototype=Object.create(s),e}return l.prototype=c,B(s,"constructor",c),B(c,"constructor",l),l.displayName="GeneratorFunction",B(c,o,"GeneratorFunction"),B(s),B(s,o,"Generator"),B(s,r,function(){return this}),B(s,"toString",function(){return"[object Generator]"}),(L=function(){return{w:i,m:p}})()}function B(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}B=function(e,t,n,r){function i(t,n){B(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},B(e,t,n,r)}function U(e,t,n,r,o,i,u){try{var a=e[i](u),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function H(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function F(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?H(Object(n),!0).forEach(function(t){q(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):H(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function z(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,G(r.key),r)}}function q(e,t,n){return(t=G(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function G(e){var t=function(e){if("object"!=N(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=N(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==N(t)?t:t+""}var W=function(){return e=function e(t){var n,r,o,i,u,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),q(this,"_openButton",null),q(this,"_root",null),q(this,"_breakpointDetector",null),q(this,"_interfaceDetectorCleanup",null),q(this,"_hybridBehaviourCleanup",null),q(this,"_isHidden",!1),this.id=t,this.rootEl=document.getElementById(t),!this.rootEl)throw new Error('Element with id "'.concat(t,'" not found'));this.eventBus=new M,this.config=this._buildConfig(a),n=this.rootEl,o=(r=this.config).mapProvider,i=r.deviceNotSupportedText,u=null==o?void 0:o.checkDeviceCapabilities(),(o?null!=u&&u.isSupported||(O(n,i),(0,P.i)(),console.log(null==u?void 0:u.error),0):(console.log("No map provider"),0))&&(["buttonFirst","hybrid"].includes(this.config.behaviour)&&v(this),this._breakpointDetector=function(e){var t,n=e.maxMobileWidth,r=e.minDesktopWidth,o=e.containerEl,i="unknown",u=new Set,a=function(e){e!==i&&(i=e,requestAnimationFrame(function(){i===e&&u.forEach(function(t){return t(e)})}))};if(o){var l=function(e,t,n){e.style.containerType="inline-size";var r=e.getBoundingClientRect().width,o=t(r);e.dataset.breakpoint=o;var i=new window.ResizeObserver(function(r){var o,i,u=(null===(o=r[0])||void 0===o||null===(o=o.borderBoxSize)||void 0===o||null===(o=o[0])||void 0===o?void 0:o.inlineSize)||(null===(i=r[0])||void 0===i?void 0:i.contentRect.width),a=t(u);e.dataset.breakpoint=a,n(a)});return i.observe(e),{initialType:o,cleanup:function(){i.disconnect(),e.style.containerType="",delete e.dataset.breakpoint}}}(o,function(e){return function(e,t,n){return e<=t?"mobile":e>=n?"desktop":"tablet"}(e,n,r)},a);i=l.initialType,a(l.initialType),t=l.cleanup}else{var c=function(e,t,n){var r={mobile:window.matchMedia("(max-width: ".concat(e,"px)")),desktop:window.matchMedia("(min-width: ".concat(t,"px)"))},o=function(){var e="tablet";r.mobile.matches?e="mobile":r.desktop.matches&&(e="desktop"),n(e)};return r.mobile.addEventListener("change",o),r.desktop.addEventListener("change",o),o(),{cleanup:function(){r.mobile.removeEventListener("change",o),r.desktop.removeEventListener("change",o)}}}(n,r,a);t=c.cleanup}return{subscribe:function(e){return u.add(e),function(){return u.delete(e)}},getBreakpoint:function(){return i},destroy:function(){var e;null===(e=t)||void 0===e||e(),u.clear()}}}({maxMobileWidth:this.config.maxMobileWidth,minDesktopWidth:this.config.minDesktopWidth,containerEl:this.rootEl}),this._interfaceDetectorCleanup=(0,T.C1)(),this._initialize())},t=[{key:"_buildConfig",value:function(e){var t=function(e){for(var t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?h(Object(n),!0).forEach(function(t){_(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):h(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({},null==e?void 0:e.dataset),n={},r=0,o=Object.keys(t);r<o.length;r++){var i=o[r];n[i]=g(t[i])}return n}(this.rootEl);return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return j(j({},l.A),e)}(F(F({id:this.id,title:document.title},t),e))}},{key:"_initialize",value:function(){var e=this;["buttonFirst","hybrid"].includes(this.config.behaviour)&&(this._openButton=function(t,n){var r=t.id,o=t.buttonText,i=t.buttonClass,u='\n <a class="'.concat(i,"\" role=\"button\">\n <svg focusable='false' aria-hidden='true' width='16' height='20' viewBox='0 0 16 20' fillRule='evenodd'>\n <path d='M15 7.5c.009 3.778-4.229 9.665-7.5 12.5C4.229 17.165-.009 11.278 0 7.5a7.5 7.5 0 1 1 15 0z'/>\n <path d='M7.5 12.961a5.46 5.46 0 1 0 0-10.922 5.46 5.46 0 1 0 0 10.922z' fill='#fff'/>\n </svg>\n <span>").concat(o,"</span>\n <span class='im-u-visually-hidden'> (Visual only)</span>\n </a>\n ");n.insertAdjacentHTML("beforebegin",u);var a=n.previousElementSibling,c=new URL(window.location.href);return c.searchParams.set(l.A.mapViewParamKey,r),a.setAttribute("href",c.toString()),a.addEventListener("click",function(t){t.preventDefault(),function(t){e._handleButtonClick(t)}(t)}),a}(this.config,this.rootEl)),this._hybridBehaviourCleanup=function(e){var t=e.config,n=t.behaviour,r=t.hybridWidth,o=t.maxMobileWidth;if("buttonFirst"===n&&e._breakpointDetector.subscribe(function(){S(e.config)?e.loadApp():e.removeApp()}),"hybrid"===n){var i=null!=r?r:o,u=window.matchMedia("(max-width: ".concat(i,"px)")),a=function(){S(e.config)?e._isHidden?e.showApp():null==e._root?e.loadApp():(0,P.N)(e):e._root&&e.hideApp()};return u.addEventListener("change",a),function(){return u.removeEventListener("change",a)}}return null}(this),S(this.config)?this.loadApp():(0,P.i)()}},{key:"_handleButtonClick",value:function(e){history.pushState({isBack:!0},"",e.currentTarget.getAttribute("href")),this._isHidden?this.showApp():this.loadApp()}},{key:"_removeMapParamFromUrl",value:function(e,t){var n=new RegExp("[?&]".concat(t,"=[^&]*(&|$)"));return n.test(e)?e.replace(n,function(e,t){return"&"===t?"?":""}).replace(/\?$/,""):e}},{key:"_handleExitClick",value:function(){this.config.preserveStateOnClose?this.hideApp():this.removeApp();var e=this.config.mapViewParamKey,t=location.href,n=this._removeMapParamFromUrl(t,e);history.replaceState(history.state,"",n)}},{key:"loadApp",value:(r=L().m(function e(){var t,r,o,i,u,a,l,c,f,s=this;return L().w(function(e){for(;;)switch(e.p=e.n){case 0:return this._openButton&&(this._openButton.style.display="none"),e.p=1,e.n=2,Promise.resolve().then(n.bind(n,"./src/App/initialiseApp.js"));case 2:return t=e.v,r=t.initialiseApp,e.n=3,this.config.mapProvider.load();case 3:return o=e.v,i=o.MapProvider,u=o.mapFramework,a=o.mapProviderConfig,this.config.reverseGeocodeProvider&&(0,k.H)(this.config.reverseGeocodeProvider,a.crs),e.n=4,r(this.rootEl,F(F({id:this.id,initialBreakpoint:this._breakpointDetector.getBreakpoint(),initialInterfaceType:(0,T.ip)()},this.config),{},{MapProvider:i,mapProviderConfig:a,mapFramework:u,eventBus:this.eventBus,breakpointDetector:this._breakpointDetector,handleExitClick:this._handleExitClick.bind(this)}));case 4:l=e.v,this._root=l._root,delete l._root,c=new Set(["on","off","emit"]),Object.keys(l).forEach(function(e){c.has(e)||(s[e]=l[e])}),(0,P.N)(this),e.n=6;break;case 5:throw e.p=5,f=e.v,O(this.rootEl,this.config.genericErrorText),console.error(f),f;case 6:return e.a(2)}},e,this,[[1,5]])}),o=function(){var e=this,t=arguments;return new Promise(function(n,o){var i=r.apply(e,t);function u(e){U(i,n,o,u,a,"next",e)}function a(e){U(i,n,o,u,a,"throw",e)}u(void 0)})},function(){return o.apply(this,arguments)})},{key:"removeApp",value:function(){this._root&&"function"==typeof this.unmount&&(this.unmount(),this._root=null),this._openButton&&(this._openButton.removeAttribute("style"),this._openButton.focus()),(0,P.N)(this),this.eventBus.emit(R.q.MAP_DESTROY,{mapId:this.id})}},{key:"hideApp",value:function(){this._isHidden=!0,this.rootEl.style.display="none",(0,x.U)({containerEl:this.rootEl,isFullscreen:!1}),this._openButton&&(this._openButton.removeAttribute("style"),this._openButton.focus()),document.documentElement.classList.remove("im-is-fullscreen"),this.rootEl.classList.remove("im-is-fullscreen");var e=document.title.split(": ");e.length>1&&(document.title=e[e.length-1])}},{key:"showApp",value:function(){this._isHidden=!1,this.rootEl.style.display="",this._openButton&&(this._openButton.style.display="none"),(0,P.N)(this)}},{key:"destroy",value:function(){var e,t,n;this.removeApp(),null===(e=this._breakpointDetector)||void 0===e||e.destroy(),null===(t=this._interfaceDetectorCleanup)||void 0===t||t.call(this),null===(n=this._hybridBehaviourCleanup)||void 0===n||n.call(this),m(this),this.eventBus.destroy()}},{key:"on",value:function(){var e;(e=this.eventBus).on.apply(e,arguments)}},{key:"off",value:function(){var e;(e=this.eventBus).off.apply(e,arguments)}},{key:"emit",value:function(){var e;(e=this.eventBus).emit.apply(e,arguments)}},{key:"addMarker",value:function(e,t,n){this.eventBus.emit(R.q.APP_ADD_MARKER,{id:e,coords:t,options:n})}},{key:"removeMarker",value:function(e){this.eventBus.emit(R.q.APP_REMOVE_MARKER,e)}},{key:"setMode",value:function(e){this.eventBus.emit(R.q.APP_SET_MODE,e)}},{key:"addButton",value:function(e,t){this.eventBus.emit(R.q.APP_ADD_BUTTON,{id:e,config:t})}},{key:"toggleButtonState",value:function(e,t,n){this.eventBus.emit(R.q.APP_TOGGLE_BUTTON_STATE,{id:e,prop:t,value:n})}},{key:"addPanel",value:function(e,t){this.eventBus.emit(R.q.APP_ADD_PANEL,{id:e,config:t})}},{key:"removePanel",value:function(e){this.eventBus.emit(R.q.APP_REMOVE_PANEL,e)}},{key:"showPanel",value:function(e){this.eventBus.emit(R.q.APP_SHOW_PANEL,e)}},{key:"hidePanel",value:function(e){this.eventBus.emit(R.q.APP_HIDE_PANEL,e)}},{key:"addControl",value:function(e,t){this.eventBus.emit(R.q.APP_ADD_CONTROL,{id:e,config:t})}}],t&&z(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,r,o}();export{W as InteractiveMap,W as default};export const EVENTS=R.q;
|
|
1
|
+
export{E as EVENTS,I as InteractiveMap,I as default}from"./im-shell.js";import"@babel/runtime/helpers/asyncToGenerator";import"@babel/runtime/helpers/defineProperty";
|