1import{_ as it}from"./hhtiSyJu.js";import{_ as nt}from"./z9GswrZH.js";import{_ as st}from"./DQGQnOwu.js";import{u as rt,d as at}from"./KBxUZaAn.js";import{d as Se,Q as ot,O as lt,e as $,o as w,n as P,s as B,q as b,m as V,p as E,t as D,F as le,x as L,z as ct,a_ as ut,g as dt,r as R,k as ft,C as se,a as pt,ar as mt,i as De,w as Ae,j as pe,h as W,B as ht,l as I,_ as gt,a0 as vt,a2 as kt,y as yt,D as _t,a4 as wt}from"./D1BBo57i.js";import{_ as bt}from"./CEs68L7H.js";import{_ as St}from"./C4wHSS-q.js";import{_ as Mt}from"./CgkPiwjc.js";import{_ as Et}from"./BxilpCjP.js";import{_ as Ot}from"./CeCHmhCh.js";import{a as xt,d as Pt}from"./BqZq3uaP.js";import{d as Dt}from"./CPKAbrZb.js";import{u as At}from"./CUN0TiVg.js";import"./Cm7I7SPc.js";import"./BZ_qjlfp.js";import"./BUw8Re5_.js";const It={class:"AtomMapProfileTeaser"},Nt={key:0,class:"AtomMapProfileTeaser__imageWrapper"},Ct={class:"AtomMapProfileTeaser__title"},$t={class:"AtomMapProfileTeaser__text"},Tt={key:0,class:"AtomMapProfileTeaser__seals"},Bt=Se({__name:"AtomMapProfileTeaser",props:{profile:{type:Object,required:!0}},setup(n){const e=n,t=ot(),{profile:i}=lt(e),{fullProfileName:s,city:r,seals:o,offeredProducts:l}=rt(i);return(a,u)=>{const d=nt,c=st;return w(),$("article",It,[b(i)?.logo?.url?(w(),$("div",Nt,[B(d,{alt:b(i)?.logo?.alt,srcSet:b(i)?.logo?.url,lazySrc:b(i)?.logo?.url,height:90,width:90,fit:"contain",class:"AtomMapProfileTeaser__image"},null,8,["alt","srcSet","lazySrc"])])):P("",!0),B(c,{to:b(t)({name:"map-slug",params:{slug:b(i).slug}}),class:"AtomMapProfileTeaser__link"},{default:V(()=>[E("h3",Ct,D(b(s)),1),E("p",$t,D(b(r)),1),b(o)||b(l)?(w(),$("p",Tt,[b(o)?(w(),$(le,{key:0},[E("strong",null,D(a.$t("general.commitment"))+":",1),L(" "+D(b(o)),1)],64)):P("",!0),b(l)?(w(),$(le,{key:1},[u[0]||(u[0]=E("br",null,null,-1)),E("strong",null,D(a.$t("general.offer"))+":",1),L(" "+D(b(l)),1)],64)):P("",!0)])):P("",!0)]),_:1},8,["to"])])}}}),Ft=Object.assign(ct(Bt,[["__scopeId","data-v-7fc1e6b5"]]),{__name:"AtomMapProfileTeaser"});var ce={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getMapProfiles"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"filter"}},type:{kind:"NamedType",name:{kind:"Name",value:"MapProfileFilter"}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"limit"}},type:{kind:"NamedType",name:{kind:"Name",value:"Int"}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"offset"}},type:{kind:"NamedType",name:{kind:"Name",value:"Int"}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"locale"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}},defaultValue:{kind:"StringValue",value:"de",block:!1},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mapProfiles"},arguments:[{kind:"Argument",name:{kind:"Name",value:"filter"},value:{kind:"Variable",name:{kind:"Name",value:"filter"}}},{kind:"Argument",name:{kind:"Name",value:"limit"},value:{kind:"Variable",name:{kind:"Name",value:"limit"}}},{kind:"Argument",name:{kind:"Name",value:"offset"},value:{kind:"Variable",name:{kind:"Name",value:"offset"}}},{kind:"Argument",name:{kind:"Name",value:"languageKey"},value:{kind:"Variable",name:{kind:"Name",value:"locale"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"longitude"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"latitude"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:294}};ce.loc.source={body:`query getMapProfiles( 2 $filter: MapProfileFilter 3 $limit: Int 4 $offset: Int 5 $locale: String = "de" 6) { 7 mapProfiles( 8 filter: $filter 9 limit: $limit 10 offset: $offset 11 languageKey: $locale 12 ) { 13 id 14 longitude 15 latitude 16 } 17} 18`,name:"GraphQL request",locationOffset:{line:1,column:1}};function re(n,e){if(n.kind==="FragmentSpread")e.add(n.name.value);else if(n.kind==="VariableDefinition"){var t=n.type;t.kind==="NamedType"&&e.add(t.name.value)}n.selectionSet&&n.selectionSet.selections.forEach(function(i){re(i,e)}),n.variableDefinitions&&n.variableDefinitions.forEach(function(i){re(i,e)}),n.definitions&&n.definitions.forEach(function(i){re(i,e)})}var ke={};(function(){ce.definitions.forEach(function(e){if(e.name){var t=new Set;re(e,t),ke[e.name.value]=t}})})();function Ie(n,e){for(var t=0;t<n.definitions.length;t++){var i=n.definitions[t];if(i.name&&i.name.value==e)return i}}function Lt(n,e){var t={kind:n.kind,definitions:[Ie(n,e)]};n.hasOwnProperty("loc")&&(t.loc=n.loc);var i=ke[e]||new Set,s=new Set,r=new Set;for(i.forEach(function(l){r.add(l)});r.size>0;){var o=r;r=new Set,o.forEach(function(l){if(!s.has(l)){s.add(l);var a=ke[l]||new Set;a.forEach(function(u){r.add(u)})}})}
18return s.forEach(function(l){var a=Ie(n,l);a&&t.definitions.push(a)}),t}Lt(ce,"getMapProfiles");var F={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getMapProfilesFilterOptions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"locale"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}},defaultValue:{kind:"StringValue",value:"de",block:!1},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",alias:{kind:"Name",value:"animalSeals"},name:{kind:"Name",value:"seals"},arguments:[{kind:"Argument",name:{kind:"Name",value:"filter"},value:{kind:"ObjectValue",fields:[{kind:"ObjectField",name:{kind:"Name",value:"type"},value:{kind:"StringValue",value:"race",block:!1}}]}},{kind:"Argument",name:{kind:"Name",value:"languageKey"},value:{kind:"Variable",name:{kind:"Name",value:"locale"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Seal"},directives:[]}]}},{kind:"Field",alias:{kind:"Name",value:"specieSeals"},name:{kind:"Name",value:"seals"},arguments:[{kind:"Argument",name:{kind:"Name",value:"filter"},value:{kind:"ObjectValue",fields:[{kind:"ObjectField",name:{kind:"Name",value:"type"},value:{kind:"StringValue",value:"seal",block:!1}}]}},{kind:"Argument",name:{kind:"Name",value:"languageKey"},value:{kind:"Variable",name:{kind:"Name",value:"locale"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Seal"},directives:[]}]}},{kind:"Field",alias:{kind:"Name",value:"products"},name:{kind:"Name",value:"products"},arguments:[{kind:"Argument",name:{kind:"Name",value:"languageKey"},value:{kind:"Variable",name:{kind:"Name",value:"locale"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Product"},directives:[]}]}},{kind:"Field",alias:{kind:"Name",value:"visitExperiences"},name:{kind:"Name",value:"tags"},arguments:[{kind:"Argument",name:{kind:"Name",value:"filter"},value:{kind:"ObjectValue",fields:[{kind:"ObjectField",name:{kind:"Name",value:"typeStrings"},value:{kind:"ListValue",values:[{kind:"StringValue",value:"visit_experience",block:!1}]}}]}},{kind:"Argument",name:{kind:"Name",value:"languageKey"},value:{kind:"Variable",name:{kind:"Name",value:"locale"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Tag"},directives:[]}]}}]}}],loc:{start:0,end:590}};F.loc.source={body:`#import "../fragments/Seal.fragment.gql" 19#import "../fragments/Product.fragment.gql" 20#import "../fragments/Tag.fragment.gql" 21 22query getMapProfilesFilterOptions($locale: String = "de") { 23 animalSeals: seals(filter: { type: "race" }, languageKey: $locale) { 24 ...Seal 25 } 26 specieSeals: seals(filter: { type: "seal" }, languageKey: $locale) { 27 ...Seal 28 } 29 products: products(languageKey: $locale) { 30 ...Product 31 } 32 visitExperiences: tags( 33 filter: { typeStrings: ["visit_experience"] } 34 languageKey: $locale 35 ) { 36 ...Tag 37 } 38} 39`,name:"GraphQL request",locationOffset:{line:1,column:1}};var Ne={};function Me(n){return n.filter(function(e){if(e.kind!=="FragmentDefinition")return!0;var t=e.name.value;return Ne[t]?!1:(Ne[t]=!0,!0)})}F.definitions=F.definitions.concat(Me(xt.definitions));F.definitions=F.definitions.concat(Me(Pt.definitions));F.definitions=F.definitions.concat(Me(Dt.definitions));function ae(n,e){if(n.kind==="FragmentSpread")e.add(n.name.value);else if(n.kind==="VariableDefinition"){var t=n.type;t.kind==="NamedType"&&e.add(t.name.value)}n.selectionSet&&n.selectionSet.selections.forEach(function(i){ae(i,e)}),n.variableDefinitions&&n.variableDefinitions.forEach(function(i){ae(i,e)}),n.definitions&&n.definitions.forEach(function(i){ae(i,e)})}var ye={};(function(){F.definitions.forEach(function(e){if(e.name){var t=new Set;ae(e,t),ye[e.name.value]=t}})})();function Ce(n,e){for(var t=0;t<n.definitions.length;t++){var i=n.definitions[t];if(i.name&&i.name.value==e)return i}}function Vt(n,e){var t={kind:n.kind,definitions:[Ce(n,e)]};n.hasOwnProperty("loc")&&(t.loc=n.loc);var i=ye[e]||new Set,s=new Set,r=new Set;for(i.forEach(function(l){r.add(l)});r.size>0;){var o=r;r=new Set,o.forEach(function(l){if(!s.has(l)){s.add(l);var a=ye[l]||new Set;a.forEach(function(u){r.add(u)})}})}
39return s.forEach(function(l){var a=Ce(n,l);a&&t.definitions.push(a)}),t}Vt(F,"getMapProfilesFilterOptions");var Q={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getMapProfileTeaser"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"Int"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"locale"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}},defaultValue:{kind:"StringValue",value:"de",block:!1},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",alias:{kind:"Name",value:"profile"},name:{kind:"Name",value:"mapProfile"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}},{kind:"Argument",name:{kind:"Name",value:"languageKey"},value:{kind:"Variable",name:{kind:"Name",value:"locale"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MapProfileTeaser"},directives:[]}]}}]}}],loc:{start:0,end:210}};Q.loc.source={body:`#import "../fragments/MapProfileTeaser.fragment.gql" 40 41query getMapProfileTeaser($id: Int!, $locale: String = "de") { 42 profile: mapProfile(id: $id, languageKey: $locale) { 43 ...MapProfileTeaser 44 } 45} 46`,name:"GraphQL request",locationOffset:{line:1,column:1}};var $e={};function Rt(n){return n.filter(function(e){if(e.kind!=="FragmentDefinition")return!0;var t=e.name.value;return $e[t]?!1:($e[t]=!0,!0)})}Q.definitions=Q.definitions.concat(Rt(at.definitions));function oe(n,e){if(n.kind==="FragmentSpread")e.add(n.name.value);else if(n.kind==="VariableDefinition"){var t=n.type;t.kind==="NamedType"&&e.add(t.name.value)}n.selectionSet&&n.selectionSet.selections.forEach(function(i){oe(i,e)}),n.variableDefinitions&&n.variableDefinitions.forEach(function(i){oe(i,e)}),n.definitions&&n.definitions.forEach(function(i){oe(i,e)})}var _e={};(function(){Q.definitions.forEach(function(e){if(e.name){var t=new Set;oe(e,t),_e[e.name.value]=t}})})();function Te(n,e){for(var t=0;t<n.definitions.length;t++){var i=n.definitions[t];if(i.name&&i.name.value==e)return i}}function jt(n,e){var t={kind:n.kind,definitions:[Te(n,e)]};n.hasOwnProperty("loc")&&(t.loc=n.loc);var i=_e[e]||new Set,s=new Set,r=new Set;for(i.forEach(function(l){r.add(l)});r.size>0;){var o=r;r=new Set,o.forEach(function(l){if(!s.has(l)){s.add(l);var a=_e[l]||new Set;a.forEach(function(u){r.add(u)})}})}return s.forEach(function(l){var a=Te(n,l);a&&t.definitions.push(a)}),t}jt(Q,"getMapProfileTeaser");function Zt(n,e,t,i){function s(r){return r instanceof t?r:new t(function(o){o(r)})}return new(t||(t=Promise))(function(r,o){function l(d){try{u(i.next(d))}catch(c){o(c)}}function a(d){try{u(i.throw(d))}catch(c){o(c)}}function u(d){d.done?r(d.value):s(d.value).then(l,a)}u((i=i.apply(n,[])).next())})}function Ut(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var qt=function n(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var i,s,r;if(Array.isArray(e)){if(i=e.length,i!=t.length)return!1;for(s=i;s--!==0;)if(!n(e[s],t[s]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(r=Object.keys(e),i=r.length,i!==Object.keys(t).length)return!1;for(s=i;s--!==0;)if(!Object.prototype.hasOwnProperty.call(t,r[s]))return!1;for(s=i;s--!==0;){var o=r[s];if(!n(e[o],t[o]))return!1}return!0}return e!==e&&t!==t},Kt=Ut(qt);const Be="__googleMapsScriptId";var z;(function(n){n[n.INITIALIZED=0]="INITIALIZED",n[n.LOADING=1]="LOADING",n[n.SUCCESS=2]="SUCCESS",n[n.FAILURE=3]="FAILURE"})(z||(z={}));class K{constructor({apiKey:e,authReferrerPolicy:t,channel:i,client:s,id:r=Be,language:o,libraries:l=[],mapIds:a,nonce:u,region:d,retries:c=3,url:m="https://maps.googleapis.com/ma
46ps/api/js",version:g}){if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=e,this.authReferrerPolicy=t,this.channel=i,this.client=s,this.id=r||Be,this.language=o,this.libraries=l,this.mapIds=a,this.nonce=u,this.region=d,this.retries=c,this.url=m,this.version=g,K.instance){if(!Kt(this.options,K.instance.options))throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(K.instance.options)}`);return K.instance}K.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?z.FAILURE:this.done?z.SUCCESS:this.loading?z.LOADING:z.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){let e=this.url;return e+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(e+=`&key=${this.apiKey}`),this.channel&&(e+=`&channel=${this.channel}`),this.client&&(e+=`&client=${this.client}`),this.libraries.length>0&&(e+=`&libraries=${this.libraries.join(",")}`),this.language&&(e+=`&language=${this.language}`),this.region&&(e+=`®ion=${this.region}`),this.version&&(e+=`&v=${this.version}`),this.mapIds&&(e+=`&map_ids=${this.mapIds.join(",")}`),this.authReferrerPolicy&&(e+=`&auth_referrer_policy=${this.authReferrerPolicy}`),e}deleteScript(){const e=document.getElementById(this.id);e&&e.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise((e,t)=>{this.loadCallback(i=>{i?t(i.error):e(window.google)})})}importLibrary(e){return this.execute(),google.maps.importLibrary(e)}loadCallback(e){this.callbacks.push(e),this.execute()}setScript(){var e,t;if(document.getElementById(this.id)){this.callback();return}const i={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};
46Object.keys(i).forEach(r=>!i[r]&&delete i[r]),!((t=(e=window?.google)===null||e===void 0?void 0:e.maps)===null||t===void 0)&&t.importLibrary||(r=>{let o,l,a,u="The Google Maps JavaScript API",d="google",c="importLibrary",m="__ib__",g=document,k=window;k=k[d]||(k[d]={});const h=k.maps||(k.maps={}),f=new Set,y=new URLSearchParams,_=()=>o||(o=new Promise((O,A)=>Zt(this,void 0,void 0,function*(){var v;yield l=g.createElement("script"),l.id=this.id,y.set("libraries",[...f]+"");for(a in r)y.set(a.replace(/[A-Z]/g,T=>"_"+T[0].toLowerCase()),r[a]);y.set("callback",d+".maps."+m),l.src=this.url+"?"+y,h[m]=O,l.onerror=()=>o=A(Error(u+" could not load.")),l.nonce=this.nonce||((v=g.querySelector("script[nonce]"))===null||v===void 0?void 0:v.nonce)||"",g.head.append(l)})));h[c]?console.warn(u+" only loads once. Ignoring:",r):h[c]=(O,...A)=>f.add(O)&&_().then(()=>h[c](O,...A))})(i);const s=this.libraries.map(r=>this.importLibrary(r));s.length||s.push(this.importLibrary("core")),Promise.all(s).then(()=>this.callback(),r=>{const o=new ErrorEvent("error",{error:r});this.loadErrorCallback(o)})}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(e){if(this.errors.push(e),this.errors.length<=this.retries){const t=this.errors.length*Math.pow(2,this.errors.length);console.error(`Failed to load Google Maps script, retrying in ${t} ms.`),setTimeout(()=>{this.deleteScript(),this.setScript()},t)}else this.onerrorEvent=e,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach(e=>{e(this.onerrorEvent)}),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),!this.loading)if(this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version){console.warn("Google Maps already loaded outside @googlemaps/js-api-loader. This may result in undesirable behavior as options and script parameters may not match."),this.callback();return}this.loading=!0,this.setScript()}}}var me,Fe;function Gt(){return Fe||(Fe=1,me=function n(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var i,s,r;if(Array.isArray(e)){if(i=e.length,i!=t.length)return!1;for(s=i;s--!==0;)if(!n(e[s],t[s]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(r=Object.keys(e),i=r.length,i!==Object.keys(t).length)return!1;for(s=i;s--!==0;)if(!Object.prototype.hasOwnProperty.call(t,r[s]))return!1;for(s=i;s--!==0;){var o=r[s];if(!n(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}),me}var Ht=Gt();const Le=ut(Ht),Ve=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],he=1,J=8;class Ee{static from(e){if(!(e instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");const[t,i]=new Uint8Array(e,0,2);if(t!==219)throw new Error("Data does not appear to be in a KDBush format.");const s=i>>4;if(s!==he)throw new Error(`Got v${s} data when expected v${he}.`);const r=Ve[i&15];if(!r)throw new Error("Unrecognized array type.");const[o]=new Uint16Array(e,2,1),[l]=new Uint32Array(e,4,1);return new Ee(l,o,r,e)}constructor(e,t=64,i=Float64Array,s){if(isNaN(e)||e<0)throw new Error(`Unpexpected numItems value: ${e}.`);this.numItems=+e,this.nodeSize=Math.min(Math.max(+t,2),65535),this.ArrayType=i,this.IndexArrayType=e<65536?Uint16Array:Uint32Array;const r=Ve.indexOf(this.ArrayType),o=e*2*this.ArrayType.BYTES_PER_ELEMENT,l=e*this.IndexArrayType.BYTES_PER_ELEMENT,a=(8-l%8)%8;if(r<0)throw new Error(`Unexpected typed array class: ${i}.`);s&&s instanceof ArrayBuffer?(this.data=s,this.ids=new this.IndexArrayType(this.data,J,e),this.coords=new this.ArrayType(this.data,J+l+a,e*2),this._pos=e*2,this._finished=!0):(this.data=new ArrayBuffer(J+o+l+a),this.ids=new this.IndexArrayType(this.data,J,e),this.coords=new this.ArrayType(this.data,J+l+a,e*2),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,(he<<4)+r]),new Uint16Array(this.data,2,1)[0]=t,new Uint32Array(this.data,4,1)[0]=e)}add(e,t){const i=this._pos>>1;return this.ids[i]=i,this.coords[this._pos++]=e,this.coords[this._pos++]=t,i}finish(){const e=this._pos>>1;if(e!==this.numItems)throw new Error(`Added ${e} items when expected ${this.numItems}.`);return we(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(e,t,i,s){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:r,coords:o,nodeSize:l}=this,a=[0,r.length-1,0],u=[];for(;a.length;){const d=a.pop()||0,c=a.pop()||0,m=a.pop()||0;if(c-m<=l){for(let f=m;f<=c;f++){const y=o[2*f],_=o[2*f+1];y>=e&&y<=i&&_>=t&&_<=s&&u.push(r[f])}continue}const g=m+c>>1,k=o[2*g],h=o[2*g+1];k>=e&&k<=i&&h>=t&&h<=s&&u.push(r[g]),(d===0?e<=k:t<=h)&&(a.push(m),a.push(g-1),a.push(1-d)),(d===0?i>=k:s>=h)&&(a.push(g+1),a.push(c),a.push(1-d))}return u}within(e,t,i){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:s,coords:r,nodeSize:o}=this,l=[0,s.length-1,0],a=[],u=i*i;for(;l.length;){const d=l.pop()||0,c=l.pop()||0,m=l.pop()||0;if(c-m<=o){for(let f=m;f<=c;f++)Re(r[2*f],r[2*f+1],e,t)<=u&&a.push(s[f]);continue}const g=m+c>>1,k=r[2*g],h=r[2*g+1];Re(k,h,e,t)<=u&&a.push(s[g]),(d===0?e-i<=k:t-i<=h)&&(l.push(m),l.push(g-1),l.push(1-d)),(d===0?e+i>=k:t+i>=h)&&(l.push(g+1),l.push(c),l.push(1-d))}return a}}function we(n,e,t,i,s,r){if(s-i<=t)return;const o=i+s>>1;
46Ue(n,e,o,i,s,r),we(n,e,t,i,o-1,1-r),we(n,e,t,o+1,s,1-r)}function Ue(n,e,t,i,s,r){for(;s>i;){if(s-i>600){const u=s-i+1,d=t-i+1,c=Math.log(u),m=.5*Math.exp(2*c/3),g=.5*Math.sqrt(c*m*(u-m)/u)*(d-u/2<0?-1:1),k=Math.max(i,Math.floor(t-d*m/u+g)),h=Math.min(s,Math.floor(t+(u-d)*m/u+g));Ue(n,e,t,k,h,r)}const o=e[2*t+r];let l=i,a=s;for(Y(n,e,i,t),e[2*s+r]>o&&Y(n,e,i,s);l<a;){for(Y(n,e,l,a),l++,a--;e[2*l+r]<o;)l++;for(;e[2*a+r]>o;)a--}e[2*i+r]===o?Y(n,e,i,a):(a++,Y(n,e,a,s)),a<=t&&(i=a+1),t<=a&&(s=a-1)}}function Y(n,e,t,i){ge(n,t,i),ge(e,2*t,2*i),ge(e,2*t+1,2*i+1)}function ge(n,e,t){const i=n[e];n[e]=n[t],n[t]=i}function Re(n,e,t,i){const s=n-t,r=e-i;return s*s+r*r}const zt={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:n=>n},je=Math.fround||(n=>(e=>(n[0]=+e,n[0])))(new Float32Array(1)),q=2,U=3,ve=4,Z=5,qe=6;class Qt{constructor(e){this.options=Object.assign(Object.create(zt),e),this.trees=new Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(e){const{log:t,minZoom:i,maxZoom:s}=this.options;t&&console.time("total time");const r=`prepare ${e.length} points`;t&&console.time(r),this.points=e;const o=[];for(let a=0;a<e.length;a++){const u=e[a];if(!u.geometry)continue;const[d,c]=u.geometry.coordinates,m=je(ie(d)),g=je(ne(c));o.push(m,g,1/0,a,-1,1),this.options.reduce&&o.push(0)}let l=this.trees[s+1]=this._createTree(o);t&&console.timeEnd(r);for(let a=s;a>=i;a--){const u=+Date.now();l=this.trees[a]=this._createTree(this._cluster(l,a)),t&&console.log("z%d: %d clusters in %dms",a,l.numItems,+Date.now()-u)}return t&&console.timeEnd("total time"),this}getClusters(e,t){let i=((e[0]+180)%360+360)%360-180;const s=Math.max(-90,Math.min(90,e[1]));let r=e[2]===180?180:((e[2]+180)%360+360)%360-180;const o=Math.max(-90,Math.min(90,e[3]));if(e[2]-e[0]>=360)i=-180,r=180;else if(i>r){const c=this.getClusters([i,s,180,o],t),m=this.getClusters([-180,s,r,o],t);return c.concat(m)}const l=this.trees[this._limitZoom(t)],a=l.range(ie(i),ne(o),ie(r),ne(s)),u=l.data,d=[];for(const c of a){const m=this.stride*c;d.push(u[m+Z]>1?Ze(u,m,this.clusterProps):this.points[u[m+U]])}return d}getChildren(e){const t=this._getOriginId(e),i=this._getOriginZoom(e),s="No cluster with the specified id.",r=this.trees[i];if(!r)throw new Error(s);const o=r.data;if(t*this.stride>=o.length)throw new Error(s);const l=this.options.radius/(this.options.extent*Math.pow(2,i-1)),a=o[t*this.stride],u=o[t*this.stride+1],d=r.within(a,u,l),c=[];for(const m of d){const g=m*this.stride;o[g+ve]===e&&c.push(o[g+Z]>1?Ze(o,g,this.clusterProps):this.points[o[g+U]])}if(c.length===0)throw new Error(s);return c}getLeaves(e,t,i){t=t||10,i=i||0;const s=[];return this._appendLeaves(s,e,t,i,0),s}getTile(e,t,i){const s=this.trees[this._limitZoom(e)],r=Math.pow(2,e),{extent:o,radius:l}=this.options,a=l/o,u=(i-a)/r,d=(i+1+a)/r,c={features:[]};return this._addTileFeatures(s.range((t-a)/r,u,(t+1+a)/r,d),s.data,t,i,r,c),t===0&&this._addTileFeatures(s.range(1-a/r,u,1,d),s.data,r,i,r,c),t===r-1&&this._addTileFeatures(s.range(0,u,a/r,d),s.data,-1,i,r,c),c.features.length?c:null}getClusterExpansionZoom(e){let t=this._getOriginZoom(e)-1;for(;t<=this.options.maxZoom;){const i=this.getChildren(e);if(t++,i.length!==1)break;e=i[0].properties.cluster_id}return t}_appendLeaves(e,t,i,s,r){const o=this.getChildren(t);for(const l of o){const a=l.properties;if(a&&a.cluster?r+a.point_count<=s?r+=a.point_count:r=this._appendLeaves(e,a.cluster_id,i,s,r):r<s?r++:e.push(l),e.length===i)break}return r}_createTree(e){const t=new Ee(e.length/this.stride|0,this.options.nodeSize,Float32Array);for(let i=0;i<e.length;i+=this.stride)t.add(e[i],e[i+1]);return t.finish(),t.data=e,t}_addTileFeatures(e,t,i,s,r,o){for(const l of e){const a=l*this.stride,u=t[a+Z]>1;let d,c,m;if(u)d=Ke(t,a,this.clusterProps),c=t[a],m=t[a+1];else{const h=this.points[t[a+U]];d=h.properties;const[f,y]=h.geometry.coordinates;c=ie(f),m=ne(y)}const g={type:1,geometry:[[Math.round(this.options.extent*(c*r-i)),Math.round(this.options.extent*(m*r-s))]],tags:d};let k;u||this.options.generateId?k=t[a+U]:k=this.points[t[a+U]].id,k!==void 0&&(g.id=k),o.features.push(g)}}_limitZoom(e){return Math.max(this.options.minZoom,Math.min(Math.floor(+e),this.options.maxZoom+1))}_cluster(e,t){const{radius:i,extent:s,reduce:r,minPoints:o}=this.options,l=i/(s*Math.pow(2,t)),a=e.data,u=[],d=this.stride;for(let c=0;c<a.length;c+=d){if(a[c+q]<=t)continue;a[c+q]=t;const m=a[c],g=a[c+1],k=e.within(a[c],a[c+1],l),h=a[c+Z];let f=h;for(const y of k){const _=y*d;a[_+q]>t&&(f+=a[_+Z])}if(f>h&&f>=o){let y=m*h,_=g*h,O,A=-1;const v=((c/d|0)<<5)+(t+1)+this.points.length;for(const T of k){const S=T*d;if(a[S+q]<=t)continue;a[S+q]=t;const C=a[S+Z];y+=a[S]*C,_+=a[S+1]*C,a[S+ve]=v,r&&(O||(O=this._map(a,c,!0),A=this.clusterProps.length,this.clusterProps.push(O)),r(O,this._map(a,S)))}a[c+ve]=v,u.push(y/f,_/f,1/0,v,-1,f),r&&u.push(A)}else{for(let y=0;y<d;y++)u.push(a[c+y]);if(f>1)for(const y of k){const _=y*d;if(!(a[_+q]<=t)){a[_+q]=t;for(let O=0;O<d;O++)u.push(a[_+O])}}}}return u}_getOriginId(e){return e-this.points.length>>5}_getOriginZoom(e){return(e-this.points.length)%32}_map(e,t,i){if(e[t+Z]>
461){const o=this.clusterProps[e[t+qe]];return i?Object.assign({},o):o}const s=this.points[e[t+U]].properties,r=this.options.map(s);return i&&r===s?Object.assign({},r):r}}function Ze(n,e,t){return{type:"Feature",id:n[e+U],properties:Ke(n,e,t),geometry:{type:"Point",coordinates:[Wt(n[e]),Jt(n[e+1])]}}}function Ke(n,e,t){const i=n[e+Z],s=i>=1e4?`${Math.round(i/1e3)}k`:i>=1e3?`${Math.round(i/100)/10}k`:i,r=n[e+qe],o=r===-1?{}:Object.assign({},t[r]);return Object.assign(o,{cluster:!0,cluster_id:n[e+U],point_count:i,point_count_abbreviated:s})}function ie(n){return n/360+.5}function ne(n){const e=Math.sin(n*Math.PI/180),t=.5-.25*Math.log((1+e)/(1-e))/Math.PI;return t<0?0:t>1?1:t}function Wt(n){return(n-.5)*360}function Jt(n){const e=(180-n*360)*Math.PI/180;return 360*Math.atan(Math.exp(e))/Math.PI-90}function Yt(n,e){var t={};for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&e.indexOf(i)<0&&(t[i]=n[i]);if(n!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(n);s<i.length;s++)e.indexOf(i[s])<0&&Object.prototype.propertyIsEnumerable.call(n,i[s])&&(t[i[s]]=n[i[s]]);return t}class N{static isAdvancedMarkerAvailable(e){return google.maps.marker&&e.getMapCapabilities().isAdvancedMarkersAvailable===!0}static isAdvancedMarker(e){return google.maps.marker&&e instanceof google.maps.marker.AdvancedMarkerElement}static setMap(e,t){this.isAdvancedMarker(e)?e.map=t:e.setMap(t)}static getPosition(e){if(this.isAdvancedMarker(e)){if(e.position){if(e.position instanceof google.maps.LatLng)return e.position;if(e.position.lat&&e.position.lng)return new google.maps.LatLng(e.position.lat,e.position.lng)}return new google.maps.LatLng(null)}return e.getPosition()}static getVisible(e){return this.isAdvancedMarker(e)?!0:e.getVisible()}}class be{constructor({markers:e,position:t}){this.markers=e,t&&(t instanceof google.maps.LatLng?this._position=t:this._position=new google.maps.LatLng(t))}get bounds(){if(this.markers.length===0&&!this._position)return;const e=new google.maps.LatLngBounds(this._position,this._position);for(const t of this.markers)e.extend(N.getPosition(t));return e}get position(){return this._position||this.bounds.getCenter()}get count(){return this.markers.filter(e=>N.getVisible(e)).length}push(e){this.markers.push(e)}delete(){this.marker&&(N.setMap(this.marker,null),this.marker=void 0),this.markers.length=0}}class Xt{constructor({maxZoom:e=16}){this.maxZoom=e}noop({markers:e}){return ei(e)}}const ei=n=>n.map(t=>new be({position:N.getPosition(t),markers:[t]}));class Ge extends Xt{constructor(e){var{maxZoom:t,radius:i=60}=e,s=Yt(e,["maxZoom","radius"]);super({maxZoom:t}),this.state={zoom:-1},this.superCluster=new Qt(Object.assign({maxZoom:this.maxZoom,radius:i},s))}calculate(e){let t=!1;const i={zoom:e.map.getZoom()};if(!Le(e.markers,this.markers)){t=!0,this.markers=[...e.markers];const s=this.markers.map(r=>{const o=N.getPosition(r);return{type:"Feature",geometry:{type:"Point",coordinates:[o.lng(),o.lat()]},properties:{marker:r}}});this.superCluster.load(s)}return t||(this.state.zoom<=this.maxZoom||i.zoom<=this.maxZoom)&&(t=!Le(this.state,i)),this.state=i,t&&(this.cluster
46s=this.cluster(e)),{clusters:this.clusters,changed:t}}cluster({map:e}){return this.superCluster.getClusters([-180,-90,180,90],Math.round(e.getZoom())).map(t=>this.transformCluster(t))}transformCluster({geometry:{coordinates:[e,t]},properties:i}){if(i.cluster)return new be({markers:this.superCluster.getLeaves(i.cluster_id,1/0).map(r=>r.properties.marker),position:{lat:t,lng:e}});const s=i.marker;return new be({markers:[s],position:N.getPosition(s)})}}class ti{constructor(e,t){this.markers={sum:e.length};const i=t.map(r=>r.count),s=i.reduce((r,o)=>r+o,0);this.clusters={count:t.length,markers:{mean:s/t.length,sum:s,min:Math.min(...i),max:Math.max(...i)}}}}class ii{render({count:e,position:t},i,s){const o=`<svg fill="${e>Math.max(10,i.clusters.markers.mean)?"#ff0000":"#0000ff"}" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240" width="50" height="50"> 47<circle cx="120" cy="120" opacity=".6" r="70" /> 48<circle cx="120" cy="120" opacity=".3" r="90" /> 49<circle cx="120" cy="120" opacity=".2" r="110" /> 50<text x="50%" y="50%" style="fill:#fff" text-anchor="middle" font-size="50" dominant-baseline="middle" font-family="roboto,arial,sans-serif">${e}</text> 51</svg>`,l=`Cluster of ${e} markers`,a=Number(google.maps.Marker.MAX_ZINDEX)+e;if(N.isAdvancedMarkerAvailable(s)){const c=new DOMParser().parseFromString(o,"image/svg+xml").documentElement;c.setAttribute("transform","translate(0 25)");const m={map:s,position:t,zIndex:a,title:l,content:c};return new google.maps.marker.AdvancedMarkerElement(m)}const u={position:t,zIndex:a,title:l,icon:{url:`data:image/svg+xml;base64,${btoa(o)}`,anchor:new google.maps.Point(25,25)}};return new google.maps.Marker(u)}}function ni(n,e){for(let t in e.prototype)n.prototype[t]=e.prototype[t]}class Oe{constructor(){ni(Oe,google.maps.OverlayView)}}var X;(function(n){n.CLUSTERING_BEGIN="clusteringbegin",n.CLUSTERING_END="clusteringend",n.CLUSTER_CLICK="click"})(X||(X={}));const si=(n,e,t)=>{t.fitBounds(e.bounds)};class ri extends Oe{constructor({map:e,markers:t=[],algorithmOptions:i={},algorithm:s=new Ge(i),renderer:r=new ii,onClusterClick:o=si}){super(),this.markers=[...t],this.clusters=[],this.algorithm=s,this.renderer=r,this.onClusterClick=o,e&&this.setMap(e)}addMarker(e,t){this.markers.includes(e)||(this.markers.push(e),t||this.render())}addMarkers(e,t){e.forEach(i=>{this.addMarker(i,!0)}),t||this.render()}removeMarker(e,t){const i=this.markers.indexOf(e);return i===-1?!1:(N.setMap(e,null),this.markers.splice(i,1),t||this.render(),!0)}removeMarkers(e,t){let i=!1;return e.forEach(s=>{i=this.removeMarker(s,!0)||i}),i&&!t&&this.render(),i}clearMarkers(e){this.markers.length=0,e||this.render()}render(){const e=this.getMap();if(e instanceof google.maps.Map&&e.getProjection()){google.maps.event.trigger(this,X.CLUSTERING_BEGIN,this);const{clusters:t,changed:i}=this.algorithm.calculate({markers:this.markers,map:e,mapCanvasProjection:this.getProjection()});if(i||i==null){const s=new Set;for(const o of t)o.markers.length==1&&s.add(o.markers[0]);const r=[];for(const o of this.clusters)o.marker!=null&&(o.markers.length==1?s.has(o.marker)||N.setMap(o.marker,null):r.push(o.marker));this.clusters=t,this.renderClusters(),requestAnimationFrame(()=>r.forEach(o=>N.setMap(o,null)))}google.maps.event.trigger(this,X.CLUSTERING_END,this)}}onAdd(){this.idleListener=this.getMap().addListener("idle",this.render.bind(this)),this.render()}onRemove(){google.maps.event.removeListener(this.idleListener),this.reset()}reset(){this.markers.forEach(e=>N.setMap(e,null)),this.clusters.forEach(e=>e.delete()),this.clusters=[]}renderClusters(){const e=new ti(this.markers,this.clusters),t=this.getMap();this.clusters.forEach(i=>{i.markers.length===1?i.marker=i.markers[0]:(i.marker=this.renderer.render(i,e,t),i.markers.forEach(s=>N.setMap(s,null)),this.onClusterClick&&i.marker.addListener("click",s=>{google.maps.event.trigger(this,X.CLUSTER_CLICK,i),this.onClusterClick(s,i,t)})),N.setMap(i.marker,t)})}}function ai(n,e,t){const i=dt(),{googleMapsMapId:s,googleMapsApiKey:r}=i.public,o={backgroundColor:"#eef0d1",center:{lat:46.8352186,lng:8.1718753},clickableIcons:!1,fullscreenControl:!1,mapId:s,mapTypeControl:!1,maxZoom:18,minZoom:7,rotateControl:!1,streetViewControl:!1,zoom:8},l=new K({apiKey:r,version:"weekly"});let a=null,u=null;const d=R(),c=R(null),m=R(null);let g=null,k=[];function h(A="marker"){const v=document.createElement("div");switch(v.style.backgroundColor="#AAB518",v.style.borderRadius="100%",v.style.color="#FFF",v.style.fontSize="18px",v.style.display="grid",v.style.placeContent="center",v.style.height="56px",v.style.width="56px",A){case"cluster":v.style.height="56px",v.style.width="56px";break;
51case"largeCluster":v.style.height="72px",v.style.width="72px";break;default:v.style.height="40px",v.style.width="40px",v.style.border="1px solid #e6e6e6",v.textContent="1";break}return v}async function f(){const[{Map:A,InfoWindow:v},,{ControlPosition:T}]=a;u=new A(n.value,{...o,zoomControlOptions:{position:T.INLINE_END_BLOCK_START}}),d.value=new v({content:""}),g=new ri({markers:[],map:u,algorithm:new Ge({radius:180,maxZoom:17}),renderer:{render({count:S,position:C}){const G=h(S>20?"largeCluster":"cluster");G.textContent=`${S}`;const j=document.createElement("img");return j.src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI0MCIgaGVpZ2h0PSI0MCIgZmlsbD0ibm9uZSIgdmlld0JveD0iMCAwIDQwIDQwIj48Y2lyY2xlIGN4PSIyMCIgY3k9IjIwIiByPSIyMCIgZmlsbD0iI0FBQjUxOCIvPjwvc3ZnPg==",new google.maps.marker.AdvancedMarkerElement({position:C,map:u,title:`Cluster of ${S} markers`,content:G})}}})}async function y(){const[,{AdvancedMarkerElement:A}]=a,v=new Set;k=t.value.map(T=>{const{position:S}=T;let C=`${S.lat}_${S.lng}`;if(v.has(C))for(;v.has(C);)S.lat+=5e-5,S.lng+=5e-5,C=`${S.lat}_${S.lng}`;v.add(C);const G=h(),j=new A({position:S,content:G,map:u,collisionBehavior:"REQUIRED"});return j.addListener("click",()=>{c.value===j?_():(m.value=T,c.value=j)}),j}),g?.clearMarkers(),g?.addMarkers(k)}function _(){d.value?.setContent(e.value?.innerHTML),d.value?.open({map:u,anchor:c.value})}async function O(){return a||(a=await Promise.all([l.importLibrary("maps"),l.importLibrary("marker"),l.importLibrary("core")])),a}return ft(async()=>{await O(),f(),y()}),se(t,()=>{y()}),{map:u,renderInfoWindow:_,activeItem:m,activeMarker:c}}const oi={class:"BlockMapOfDiversity__inner"},li={key:0,class:"BlockMapOfDiversity__filterTrigger__counter"},ci={class:"BlockMapOfDiversity__filter"},ui={class:"BlockMapOfDiversity__filter__inner"},di={class:"isVisuallyHidden"},fi={key:0,class:"BlockMapOfDiversity__filter__header isVisibleTabletPortrait"},pi={key:0,class:"BlockMapOfDiversity__filter__list"},mi={class:"BlockMapOfDiversity__filter__item"},hi=["onClick"],gi={key:1,class:"BlockMapOfDiversity__filter__active"},vi={class:"BlockMapOfDiversity__filter__active__title"},ki={class:"BlockMapOfDiversity__filter__active__filter"},yi={class:"BlockMapOfDiversity__filter__footer isVisibleTabletPortrait"},_i=Se({__name:"BlockMapOfDiversity",async setup(n){let e,t;const{t:i,locale:s}=pt(),{isOpen:r,open:o,close:l}=At(!1),a=mt("(max-width: 1000px)"),u=R([]),d=R(null),c=R(null),m=R(null),g=R(!1),k=[{key:"visitExperiences",label:i("components.BlockMapOfDiversity.visitExperiences"),icon:"backpack"},{key:"products",label:i("components.BlockMapOfDiversity.products"),icon:"products"},{key:"animalSeals",label:i("components.BlockMapOfDiversity.animalSeals"),icon:"animalbreeder"},{key:"specieSeals",label:i("components.BlockMapOfDiversity.specieSeals"),icon:"plantbreeder"}],h=R(null),f=De({textSearch:"",animalSeals:null,specieSeals:null,products:[],visitExperiences:null}),y=De({limit:1e4,offset:0,filter:void 0,locale:s}),{data:_,error:O}=([e,t]=Ae(()=>pe({query:F,variables:{locale:s},cache:!1})),e=await e,t(),e),{data:A,status:v,error:T,execute:S}=pe({key:"map-profiles",query:ce,variables:y,cache:!1},{immediate:!1}),C=W(()=>v.value==="pending"||v.value==="idle"),G=W(()=>u.value),j=W(()=>!!(f.textSearch||f.animalSeals||f.specieSeals||f.products?.length||f.visitExperiences)),He=W(()=>G.value.filter(p=>p.latitude&&p.longitude).map(p=>({...p,id:p.id,position:{lat:+p.latitude,lng:+p.longitude},title:p.profileName}))),ee=W(()=>_?.value?{animalSeals:[{name:i("components.BlockMapOfDiversity.allAnimalSeals"),id:null},..._.value.animalSeals||[]],specieSeals:[{name:i("components.BlockMapOfDiversity.allSpecieSeals"),id:null},..._.value.specieSeals||[]],products:_.value.products||[],visitExperiences:[{name:i("components.BlockMapOfDiversity.allExperiences"),id:null},..._.value.visitExperiences||[]]}:_?.value||{animalSeals:[],specieSeals:[],products:[],visitExperiences:[]});async function ze(p){const{data:M,error:de}=await pe({query:Q,variables:{id:p,locale:s},cache:!1});return de.value?g.value=!0:g.value=!1,M?.value?.profile}function Qe(){const p={},M=[];f.animalSeals&&M.push(f.animalSeals),f.specieSeals&&M.push(f.specieSeals),M.length&&(p.seals=M),f.products.length&&(p.products=f.products),f.visitExperiences&&(p.tagGroups=[[f.visitExperiences]]),f.textSearch&&(p.textSearch=f.textSearch),h.value?.key&&(h.value?.key==="visitExperiences"&&!p.tagGroups&&(p.hasVisitorExperience
51=!0),h.value?.key==="products"&&!p.products&&(p.hasProducts=!0),h.value?.key==="animalSeals"&&!p.seals&&(p.hasRaceSeals=!0),h.value?.key==="specieSeals"&&!p.seals&&(p.hasPlantSeals=!0)),y.filter=Object.keys(p).length===0?void 0:p}async function ue(){Qe(),y.offset=0,await S(),u.value=A?.value?.mapProfiles||[]}function We(){f.textSearch="",f.animalSeals=null,f.specieSeals=null,f.products=[],f.visitExperiences=null}function xe(p){We(),h.value=p}se(f,()=>{ue()}),se(h,()=>{ue()}),[e,t]=Ae(()=>ue()),await e,t();const{activeItem:Je,renderInfoWindow:Ye}=ai(d,c,He);return se(Je,async p=>{p&&(m.value=await ze(p.id)||null,await ht(),Ye())}),(p,M)=>{const de=Ft,fe=bt,Xe=St,H=Mt,Pe=yt,et=Et,te=Ot,tt=gt;return w(),I(tt,{class:"BlockMapOfDiversity siteWidth paddingBlock"},{default:V(()=>[E("div",oi,[E("div",{ref_key:"mapEl",ref:d,class:"BlockMapOfDiversity__map"},null,512),E("div",{ref_key:"infoWindowEl",ref:c,style:{display:"none"}},[m.value?(w(),I(de,{key:0,profile:m.value},null,8,["profile"])):P("",!0),g.value?(w(),I(fe,{key:1,variant:"error",icon:"warning"},{default:V(()=>[L(D(p.$t("error.500")),1)]),_:1})):P("",!0)],512),C.value?(w(),I(Xe,{key:0,class:"fill"})):P("",!0),b(T)?(w(),I(fe,{key:1,variant:"error",icon:"warning",class:"BlockMapOfDiversity__error large"},{default:V(()=>[L(D(p.$t("error.500")),1)]),_:1})):P("",!0),B(Pe,{class:"BlockMapOfDiversity__filterTrigger isVisibleTabletPortrait",type:"button",onClick:b(o)},{default:V(()=>[B(H,{name:"filter"}),L(" "+D(p.$t("general.filter"))+" ",1),j.value?(w(),$("span",li," 1 ")):P("",!0)]),_:1},8,["onClick"]),kt(E("div",ci,[E("div",ui,[E("button",{type:"button",class:"BlockMapOfDiversity__filter__close isVisibleTabletPortrait",onClick:M[0]||(M[0]=(...x)=>b(l)&&b(l)(...x))},[B(H,{name:"close-big"}),E("span",di,D(p.$t("components.BlockMapOfDiversity.closeFilter")),1)]),h.value?P("",!0):(w(),$("div",fi,D(p.$t("general.filter")),1)),b(O)?(w(),I(fe,{key:2,variant:"error",icon:"warning"},{default:V(()=>[L(D(p.$t("error.500")),1)]),_:1})):(w(),$(le,{key:1},[h.value?(w(),$("div",gi,[E("button",{type:"button",class:"BlockMapOfDiversity__filter__active__back",onClick:M[2]||(M[2]=x=>xe(null))},[B(H,{name:"arrow-left",class:"BlockMapOfDiversity__filter__active__back__icon"}),L(" "+D(p.$t("components.BlockMapOfDiversity.backButton")),1)]),E("div",vi,[h.value.icon?(w(),I(H,{key:0,class:"BlockMapOfDiversity__filter__tab__icon",name:h.value.icon},null,8,["name"])):P("",!0),E("span",null,D(h.value.label),1)]),E("div",ki,[h.value.key==="visitExperiences"?(w(),I(te,{key:0,modelValue:f.visitExperiences,"onUpdate:modelValue":M[3]||(M[3]=x=>f.visitExperiences=x),options:ee.value.visitExperiences,placeholder:p.$t("components.BlockMapOfDiversity.allExperiences"),label:p.$t("components.BlockMapOfDiversity.allExperiences"),showListHeader:!1,clearable:!1},null,8,["modelValue","options","placeholder","label"])):P("",!0),h.value.key==="products"?(w(),I(te,{key:1,modelValue:f.products,"onUpdate:modelValue":M[4]||(M[4]=x=>f.products=x),options:ee.value.products,multiple:!0,placeholder:p.$t("components.BlockMapOfDiversity.allProducts"),label:p.$t("components.BlockMapOfDiversity.allProducts"),showListHeader:!1},null,8,["modelValue","options","placeholder","label"])):P("",!0),h.value.key==="animalSeals"?(w(),I(te,{key:2,modelValue:f.animalSeals,"onUpdate:modelValue":M[5]||(M[5]=x=>f.animalSeals=x),options:ee.value.animalSeals,placeholder:p.$t("components.BlockMapOfDiversity.allAnimalSeals"),label:p.$t("components.BlockMapOfDiversity.allAnimalSeals"),showListHeader:!1,clearable:!1},null,8,["modelValue","options","placeholder","label"])):P("",!0),h.value.key==="specieSeals"?(w(),I(te,{key:3,modelValue:f.specieSeals,"onUpdate:modelValue":M[6]||(M[6]=x=>f.specieSeals=x),options:ee.value.specieSeals,placeholder:p.$t("components.BlockMapOfDiversity.allSpecieSeals"),label:p.$t("components.BlockMapOfDiversity.allSpecieSeals"),showListHeader:!1,clearable:!1},null,8,["modelValue","options","placeholder","label"])):P("",!0)])])):(w(),$("ul",pi,[E("li",mi,[B(et,{modelValue:f.textSearch,"onUpdate:modelValue":M[1]||(M[1]=x=>f.textSearch=x),type:"search",class:"BlockMapOfDiversity__filter__search",label:p.$t("form.labels.searchKeywords"),hideLabel:!0,placeholder:p.$t("form.labels.searchKeywords")},null,8,["modelValue","label","placeholder"])]),(w(),$(le,null,_t(k,x=>E("li",{key:x.key,class:"BlockMapOfDiversity__filter__item"},[E("button",{type:"button",class:"BlockMapOfDiversity__filter__tab",onClick:Mi=>xe(x)},[B(H,{class:"BlockMapOfDiversity__filter__tab__icon",name:x.icon},null,8,["name"]),L(" "+D(x.label)+" ",1),B(H,{class:"BlockMapOfDiversity__filter__tab__icon",name:"arrow-right"})],8,hi)])),64))])),E("div",yi,[B(Pe,{type:"button",class:"fullWidth",onClick:b(l)},{default:V(()=>[L(D(p.$t("general.show")),1)]),_:1},8,["onClick"])])],64))])],512),[[wt,!b(a)||b(a)&&b(r)]])]),vt(p.$slots,"default")]),_:3})}}}),wi=Object.assign(_i,{__name:"BlockMapOfDiversity"}),bi=["innerHTML"],Si=Se({__name:"CmsBlockMapOfDiversity",props:{blok:{type:Object,required:!0}},setup(n){return(e,t)=>{const i=it,s=wi;return w(),I(s,null,{default:V(()=>[n.blok.sponsorText?(w(),I(i,{key:0},{default:V(()=>[E("div",{innerHTML:n.blok.sponsorText},null,8,bi)]),_:1})):P("",!0)]),_:1})}}}),ji=Object.assign(Si,{__name:"CmsBlockMapOfDiversity"});export{ji as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.