"use strict";(globalThis.webpackChunkacmsWebpackJsonp=globalThis.webpackChunkacmsWebpackJsonp||[]).push([[7246],{53961:(e,o,t)=>{t.r(o),t.d(o,{default:()=>a});var s=t(55373),r=t.n(s),i=t(12537),n=t(50369);const a=async e=>{if(!e.parentNode)throw new Error("Google Map element must be a child of a parent element");const{search:o}=new URL(e.src),t=r().parse(o,{ignoreQueryPrefix:!0}),s=e.alt.split("[[:split:]]");if(!(0,n.Kg)(t.key))return;if(""===t.key)return;if(!(0,n.Kg)(t.size))return;if(""===t.size)return;if(!(0,n.Kg)(t.center))return;if(!(0,n.Kg)(t.zoom))return;const a=await(0,i.A)(t.key),l=document.createElement("div"),p=t.size.split("x"),c=parseInt(p[0],10)||null,h=parseInt(p[1],10)||null,d=t.center.split(","),m=[],u=new a.maps.InfoWindow,g=new a.maps.Map(l,{center:{lat:parseFloat(d[0]),lng:parseFloat(d[1])},zoom:parseInt(t.zoom,10),mapTypeId:a.maps.MapTypeId.ROADMAP,scrollwheel:!1,styles:ACMS.Config.s2dStyle});l.className=e.className,l.style.aspectRatio=`${c} / ${h}`,l.style.overflow="hidden",e.parentNode.replaceChild(l,e),((0,n.Kg)(t.markers)?[t.markers]:(0,n.Bo)(t.markers)?t.markers:[]).forEach(e=>{const o=e.split("|"),t={icon:void 0,options:[]};if(o.length){for(let e=0;e<o.length;e+=1)if(0===o[e].indexOf("icon:"))t.icon=o[e].slice(5);else{const s=o[e].split(",");if(!s[0].length)continue;t.options.push({position:new a.maps.LatLng(parseFloat(s[0]),parseFloat(s[1])),map:g})}m.push(t)}});let w=0;m.forEach(e=>{for(let o=0;o<e.options.length;o+=1){const t=e.options[o],r=new a.maps.Marker({...t,icon:e.icon});void 0!==s[w]&&null!==c&&c>=180&&((e,o)=>{o&&a.maps.event.addListener(e,"click",()=>{u.setOptions({content:o}),u.open(g,e)})})(r,s[w].replace(/\[\[:quot:\]\]/gim,'"').replace(/\[\[:lt:\]\]/gim,"<").replace(/\[\[:gt:\]\]/gim,">").replace(/\[\[:amp:\]\]/gim,"&")),w+=1}})}},12537:(e,o,t)=>{t.d(o,{A:()=>n});class s{constructor(e=null,o={}){if(this.apiKey=e,this.options=o,"undefined"==typeof window)throw new Error("google-maps is supported only in browser environment")}load(){return void 0!==this.api?Promise.resolve(this.api):void 0!==this.loader?this.loader:(window[s.CALLBACK_NAME]=()=>{if(this.api=window.google,void 0===this.resolve)throw new Error("Should not happen");this.resolve(this.api)},window.gm_authFailure=()=>{if(void 0===this.reject)throw new Error("Should not happen");this.reject(new Error("google-maps: authentication error"))},this.loader=new Promise((e,o)=>{this.resolve=e,this.reject=o;const t=document.createElement("script");t.src=this.createUrl(),t.async=!0,t.onerror=e=>o(e),document.head.appendChild(t)}))}createUrl(){const e=[`callback=${s.CALLBACK_NAME}`];this.apiKey&&e.push(`key=${this.apiKey}`);for(let o in this.options)if(this.options.hasOwnProperty(o)){let t=this.options[o];"version"===o&&(o="v"),"libraries"===o&&(t=t.join(",")),e.push(`${o}=${t}`)}return`https://maps.googleapis.com/maps/api/js?${e.join("&")}`}}let r;s.CALLBACK_NAME="_dk_google_maps_loader_cb";const i={region:ACMS.Config.s2dRegion||"JP"},n=(e,o={})=>{if(r)return r;const t=new s(e,{...i,...o});return r=t.load(),r}}}]);