PageSourceSearch

https://mobilizon.fr/assets/LeafletMap-CGcKThem.js

js mobilizon.fr collected 2026-10-02 04:55:30 UTC 34,468 bytes, 3 lines download raw bytes

1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/leaflet-src-BalrW-oj.js","assets/main-BvDl5GqJ.js","assets/main-Ce-fKwcf.css"])))=>i.map(i=>d[i]);
2import{a as C}from"./leaflet-src-BalrW-oj.js";/* empty css                */import{e as I,an as N,aB as z,br as k,dv as U,cP as E,a7 as y,dw as q,dx as rt,cH as x,I as zt,c as A,a3 as ht,cX as ct,dy as Ht,G as bt,x as D,j as K,i as wt,t as Ct,o as lt,H as Zt,dz as $t,f as Ft,s as W,w as ot,k as j,h as mt,du as Ut,a4 as qt,av as Gt,v as Wt,dA as Kt,dB as Jt}from"./main-BvDl5GqJ.js";const ft=(t,e)=>{for(const o of Object.keys(e))t.on(o,e[o])},Lt=t=>{for(const e of Object.keys(t)){const o=t[e];o&&R(o.cancel)&&o.cancel()}},Xt=t=>!t||typeof t.charAt!="function"?t:t.charAt(0).toUpperCase()+t.slice(1),R=t=>typeof t=="function",H=(t,e,o)=>{for(const i in o){const n="set"+Xt(i);t[n]?ht(()=>o[i],(s,a)=>{t[n](s,a)}):e[n]&&ht(()=>o[i],s=>{e[n](s)})}},Z=(t,e,o={})=>{const i={...o};for(const n in t){const s=e[n],a=t[n];s&&(s&&s.custom===!0||a!==void 0&&(i[n]=a))}return i},J=t=>{const e={},o={};for(const i in t)if(i.startsWith("on")&&!i.startsWith("onUpdate")&&i!=="onReady"){const n=i.slice(2).toLocaleLowerCase();e[n]=t[i]}else o[i]=t[i];return{listeners:e,attrs:o}},Yt=async t=>{const e=await Promise.all([k(()=>import("./marker-icon-2x-D4k_ikNW.js"),[]),k(()=>import("./marker-icon-C2eJqgqv.js"),[]),k(()=>import("./marker-shadow-DU6CIJ0p.js"),[])]);delete t.Default.prototype._getIconUrl,t.Default.mergeOptions({iconRetinaUrl:e[0].default,iconUrl:e[1].default,shadowUrl:e[2].default})},it=t=>{const e=y((...i)=>console.warn(`Method ${t} has been invoked without being replaced`)),o=(...i)=>e.value(...i);return o.wrapped=e,x(t,o),o},st=(t,e)=>t.wrapped.value=e,B=typeof self=="object"&&self.self===self&&self||typeof global=="object"&&global.global===global&&global||globalThis,S=t=>{const e=N(t);if(e===void 0)throw new Error(`Attempt to inject ${t.description} before it was provided.`);return e},$=Symbol("useGlobalLeaflet"),Q=Symbol("addLayer"),kt=Symbol("removeLayer"),ut=Symbol("registerControl"),Qt=Symbol("registerLayerControl"),St=Symbol("canSetParentHtml"),Ot=Symbol("setParentHtml"),Tt=Symbol("setIcon"),At=Symbol("bindPopup"),te=Symbol("bindTooltip"),Pt=Symbol("unbindPopup"),ee=Symbol("unbindTooltip"),tt={options:{type:Object,default:()=>({}),custom:!0}},et=t=>({options:t.options,methods:{}}),X={...tt,pane:{type:String},attribution:{type:String},name:{type:String,custom:!0},layerType:{type:String,custom:!0},visible:{type:Boolean,custom:!0,default:!0}},Bt=(t,e,o)=>{const i=S(Q),n=S(kt),{options:s,methods:a}=et(t),l=Z(t,X,s),d=()=>i({leafletObject:e.value}),r=()=>n({leafletObject:e.value}),u={...a,setAttribution(p){r(),e.value.options.attribution=p,t.visible&&d()},setName(){r(),t.visible&&d()},setLayerType(){r(),t.visible&&d()},setVisible(p){e.value&&(p?d():r())},bindPopup(p){if(!e.value||!R(e.value.bindPopup)){console.warn("Attempt to bind popup before bindPopup method available on layer.");return}e.value.bindPopup(p)},bindTooltip(p){if(!e.value||!R(e.value.bindTooltip)){console.warn("Attempt to bind tooltip before bindTooltip method available on layer.");return}e.value.bindTooltip(p)},unbindTooltip(){e.value&&(R(e.value.closeTooltip)&&e.value.closeTooltip(),R(e.value.unbindTooltip)&&e.value.unbindTooltip())},unbindPopup(){e.value&&(R(e.value.closePopup)&&e.value.closePopup(),R(e.value.unbindPopup)&&e.value.unbindPopup())},updateVisibleProp(p){o.emit("update:visible",p)}};return x(At,u.bindPopup),x(te,u.bindTooltip),x(Pt,u.unbindPopup),x(ee,u.unbindTooltip),ct(()=>{u.unbindPopup(),u.unbindTooltip(),r()}),{options:l,methods:u}},oe=(t,e)=>{if(t&&e.default)return q("div",{style:{display:"none"}},e.default())},ie={...X,interactive:{type:Boolean,default:void 0},bubblingMouseEvents:{type:Boolean,default:void 0}},Et={...ie,stroke:{type:Boolean,default:void 0},color:{type:String},weight:{type:Number},opacity:{type:Number},lineCap:{type:String},lineJoin:{type:String},dashArray:{type:String},dashOffset:{type:String},fill:{type:Boolean,default:void 0},fillColor:{type:String},fillOpacity:{type:Number},fillRule:{type:String},className:{type:String}},se={...Et,radius:{type:Number},latLng:{type:[Object,Array],required:!0,custom:!0}};({...se});const Y={...tt,position:{type:String}},Mt=(t,e)=>{const{options:o,methods:i}=et(t),n=Z(t,Y,o),s={...i,setPosition(a){e.value&&e.value.setPosition(a)}};return ct(()=>{e.value&&e.value.remove()}),{options:n,methods:s}},ne=t=>t.default?q("div",{ref:"root"},t.default()):null;I({name:"LControl",props:{...Y,disableClickPropagation:{type:Boolean,custom:!0,default:!0},disableScrollPropagation:{type:Boolean,custom:!0,default:!1}},setup(t,e){const o=y(),i=y(),n=N($),s=S(ut),{options:a,methods:l}=Mt(t,o);return z(async()=>{const{Control:d,DomEvent:r}=n?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]),u=d.extend({onAdd(){return i.value}});o.value=U(new u(a)),H(l,o.value,t),s({leafletObject:o.value}),t.disableClickPropagation&&i.value&&r.disableClickPropagation(i.value),t.disableScrollPropagation&&i.value&&r.disableScrollPropagation(i.value),E(()=>e.emit("ready",o.value))}),{root:i,leafletObject:o}},render(){return ne(this.$slots)}});({...Y});({...Y});({...Y});const jt={...Y,zoomInText:{type:String},zoomInTitle:{type:String},zoomOutText:{type:String},zoomOutTitle:{type:String}},ae=(t,e)=>{const{options:o,methods:i}=Mt(t,e);return{options:Z(t,jt,o),methods:i}},le=I({name:"LControlZoom",props:jt,setup(t,e){const o=y(),i=N($),n=S(ut),{options:s,methods:a}=ae(t,o);return z(async()=>{const{control:l}=i?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]);o.value=U(l.zoom(s)),H(a,o.value,t),n({leafletObject:o.value}),E(()=>e.emit("ready",o.value))}),{leafletObject:o}},render(){return null}}),xt={...X};({...xt});({...xt});const dt={...X,opacity:{type:Number},zIndex:{type:Number},tileSize:{type:[Number,Array,Object]},noWrap:{type:Boolean,default:void 0},minZoom:{type:Number},maxZoom:{type:Number},className:{type:String}},It=(t,e,o)=>{const{options:i,methods:n}=Bt(t,e,o),s=Z(t,dt,i),a={...n,setTileComponent(){var l;(l=e.value)==null||l.redraw()}};return ct(()=>{e.value.off()}),{options:s,methods:a}},re=(t,e,o,i)=>t.extend({initialize(n){this.tileComponents={},this.on("tileunload",this._unloadTile),o.setOptions(this,n)},createTile(n){const s=this._tileCoordsToKey(n);this.tileComponents[s]=e.create("div");const a=q({setup:i,props:["coords"]}
2,{coords:n});return Ht(a,this.tileComponents[s]),this.tileComponents[s]},_unloadTile(n){const s=this._tileCoordsToKey(n.coords);this.tileComponents[s]&&(this.tileComponents[s].innerHTML="",this.tileComponents[s]=void 0)}});I({props:{...dt,childRender:{type:Function,required:!0}},setup(t,e){const o=y(),i=y(null),n=y(!1),s=N($),a=S(Q),{options:l,methods:d}=It(t,o,e);return z(async()=>{const{GridLayer:r,DomUtil:u,Util:p}=s?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]),_=re(r,u,p,t.childRender);o.value=U(new _(l));const{listeners:h}=J(e.attrs);o.value.on(h),H(d,o.value,t),a({...t,...d,leafletObject:o.value}),n.value=!0,E(()=>e.emit("ready",o.value))}),{root:i,ready:n,leafletObject:o}},render(){return this.ready?q("div",{style:{display:"none"},ref:"root"}):null}});const _t={iconUrl:{type:String},iconRetinaUrl:{type:String},iconSize:{type:[Object,Array]},iconAnchor:{type:[Object,Array]},popupAnchor:{type:[Object,Array]},tooltipAnchor:{type:[Object,Array]},shadowUrl:{type:String},shadowRetinaUrl:{type:String},shadowSize:{type:[Object,Array]},shadowAnchor:{type:[Object,Array]},bgPos:{type:[Object,Array]},className:{type:String}},ce=I({name:"LIcon",props:{..._t,...tt},setup(t,e){const o=y(),i=N($),n=S(St),s=S(Ot),a=S(Tt);let l,d,r,u,p;const _=(L,f,g)=>{const w=L&&L.innerHTML;if(!f){g&&p&&n()&&s(w);return}const{listeners:M}=J(e.attrs);p&&d(p,M);const{options:G}=et(t),T=Z(t,_t,G);w&&(T.html=w),p=T.html?r(T):u(T),l(p,M),a(p)},h=()=>{E(()=>_(o.value,!0,!1))},b=()=>{E(()=>_(o.value,!1,!0))},O={setIconUrl:h,setIconRetinaUrl:h,setIconSize:h,setIconAnchor:h,setPopupAnchor:h,setTooltipAnchor:h,setShadowUrl:h,setShadowRetinaUrl:h,setShadowAnchor:h,setBgPos:h,setClassName:h,setHtml:h};return z(async()=>{const{DomEvent:L,divIcon:f,icon:g}=i?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]);l=L.on,d=L.off,r=f,u=g,H(O,{},t),new MutationObserver(b).observe(o.value,{attributes:!0,childList:!0,characterData:!0,subtree:!0}),h()}),{root:o}},render(){const t=this.$slots.default?this.$slots.default():void 0;return q("div",{ref:"root"},t)}});({...X});function Vt(t,e,o){var i,n,s;e===void 0&&(e=50),o===void 0&&(o={});var a=(i=o.isImmediate)!=null&&i,l=(n=o.callback)!=null&&n,d=o.maxWait,r=Date.now(),u=[];function p(){if(d!==void 0){var h=Date.now()-r;if(h+e>=d)return d-h}return e}var _=function(){var h=[].slice.call(arguments),b=this;return new Promise(function(O,L){var f=a&&s===void 0;if(s!==void 0&&clearTimeout(s),s=setTimeout(function(){if(s=void 0,r=Date.now(),!a){var w=t.apply(b,h);l&&l(w),u.forEach(function(M){return(0,M.resolve)(w)}),u=[]}},p()),f){var g=t.apply(b,h);return l&&l(g),O(g)}u.push({resolve:O,reject:L})})};return _.cancel=function(h){s!==void 0&&clearTimeout(s),u.forEach(function(b){return(0,b.reject)(h)}),u=[]},_}const vt={...tt,center:{type:[Object,Array]},bounds:{type:[Array,Object]},maxBounds:{type:[Array,Object]},zoom:{type:Number},minZoom:{type:Number},maxZoom:{type:Number},paddingBottomRight:{type:[Object,Array]},paddingTopLeft:{type:Object},padding:{type:Object},worldCopyJump:{type:Boolean,default:void 0},crs:{type:[String,Object]},maxBoundsViscosity:{type:Number},inertia:{type:Boolean,default:void 0},inertiaDeceleration:{type:Number},inertiaMaxSpeed:{type:Number},easeLinearity:{type:Number},zoomAnimation:{type:Boolean,default:void 0},zoomAnimationThreshold:{type:Number},fadeAnimation:{type:Boolean,default:void 0},markerZoomAnimation:{type:Boolean,default:void 0},noBlockingAnimations:{type:Boolean,default:void 0},useGlobalLeaflet:{type:Boolean,default:!0,custom:!0}},ue=I({inheritAttrs:!1,emits:["ready","update:zoom","update:center","update:bounds"],props:vt,setup(t,e){const o=y(),i=zt({ready:!1,layersToAdd:[],layersInControl:[]}),{options:n}=et(t),s=Z(t,vt,n),{listeners:a,attrs:l}=J(e.attrs),d=it(Q),r=it(kt),u=it(ut),p=it(Qt);x($,t.useGlobalLeaflet);const _=A(()=>{const f={};return t.noBlockingAnimations&&(f.animate=!1),f}),h=A(()=>{const f=_.value;return t.padding&&(f.padding=t.padding),t.paddingTopLeft&&(f.paddingTopLeft=t.paddingTopLeft),t.paddingBottomRight&&(f.paddingBottomRight=t.paddingBottomRight),f}),b={moveend:Vt(f=>{i.leafletRef&&(e.emit("update:zoom",i.leafletRef.getZoom()),e.emit("update:center",i.leafletRef.getCenter()),e.emit("update:bounds",i.leafletRef.getBounds()))}),overlayadd(f){const g=i.layersInControl.find(w=>w.name===f.name);g&&g.updateVisibleProp(!0)},overlayremove(f){const g=i.layersInControl.find(w=>w.name===f.name);g&&g.updateVisibleProp(!1)}};z(async()=>{t.useGlobalLeaflet&&(B.L=B.L||await k(()=>import("./leaflet-src-BalrW-oj.js").then(c=>c.l),__vite__mapDeps([0,1,2])));const{map:f,CRS:g,Icon:w,latLngBounds:M,latLng:G,stamp:T}=t.useGlobalLeaflet?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]);try{s.beforeMapMount&&await s.beforeMapMount()}catch(c){console.error(`The following error occurred running the provided beforeMapMount hook ${c.message}`)}await Yt(w);const at=typeof s.crs=="string"?g[s.crs]:s.crs;s.crs=at||g.EPSG3857;const v={addLayer(c){c.layerType!==void 0&&(i.layerControl===void 0?i.layersToAdd.push(c):i.layersInControl.find(m=>T(m.leafletObject)===T(c.leafletObject))||(i.layerControl.addLayer(c),i.layersInControl.push(c))),c.visible!==!1&&i.leafletRef.addLayer(c.leafletObject)},removeLayer(c){c.layerType!==void 0&&(i.layerControl===void 0?i.layersToAdd=i.layersToAdd.filter(m=>m.name!==c.name):(i.layerControl.removeLayer(c.leafletObject),i.layersInControl
2=i.layersInControl.filter(m=>T(m.leafletObject)!==T(c.leafletObject)))),i.leafletRef.removeLayer(c.leafletObject)},registerLayerControl(c){i.layerControl=c,i.layersToAdd.forEach(m=>{i.layerControl.addLayer(m)}),i.layersToAdd=[],u(c)},registerControl(c){i.leafletRef.addControl(c.leafletObject)},setZoom(c){const m=i.leafletRef.getZoom();c!==m&&i.leafletRef.setZoom(c,_.value)},setCrs(c){const m=i.leafletRef.getBounds();i.leafletRef.options.crs=c,i.leafletRef.fitBounds(m,{animate:!1,padding:[0,0]})},fitBounds(c){i.leafletRef.fitBounds(c,h.value)},setBounds(c){if(!c)return;const m=M(c);m.isValid()&&!(i.lastSetBounds||i.leafletRef.getBounds()).equals(m,0)&&(i.lastSetBounds=m,i.leafletRef.fitBounds(m))},setCenter(c){if(c==null)return;const m=G(c),F=i.lastSetCenter||i.leafletRef.getCenter();(F.lat!==m.lat||F.lng!==m.lng)&&(i.lastSetCenter=m,i.leafletRef.panTo(m,_.value))}};st(d,v.addLayer),st(r,v.removeLayer),st(u,v.registerControl),st(p,v.registerLayerControl),i.leafletRef=U(f(o.value,s)),H(v,i.leafletRef,t),ft(i.leafletRef,b),ft(i.leafletRef,a),i.ready=!0,E(()=>e.emit("ready",i.leafletRef))}),rt(()=>{Lt(b),i.leafletRef&&(i.leafletRef.off(),i.leafletRef.remove())});const O=A(()=>i.leafletRef),L=A(()=>i.ready);return{root:o,ready:L,leafletObject:O,attrs:l}},render({attrs:t}){return t.style||(t.style={}),t.style.width||(t.style.width="100%"),t.style.height||(t.style.height="100%"),q("div",{...t,ref:"root"},this.ready&&this.$slots.default?this.$slots.default():{})}}),de=["Symbol(Comment)","Symbol(Text)"],pe=["LTooltip","LPopup"],Rt={...X,draggable:{type:Boolean,default:void 0},icon:{type:[Object]},zIndexOffset:{type:Number},latLng:{type:[Object,Array],custom:!0,required:!0}},he=(t,e,o)=>{const{options:i,methods:n}=Bt(t,e,o),s=Z(t,Rt,i),a={...n,setDraggable(l){e.value.dragging&&(l?e.value.dragging.enable():e.value.dragging.disable())},latLngSync(l){o.emit("update:latLng",l.latlng),o.emit("update:lat-lng",l.latlng)},setLatLng(l){if(l!=null&&e.value){const d=e.value.getLatLng();(!d||!d.equals(l))&&e.value.setLatLng(l)}}};return{options:s,methods:a}},me=(t,e)=>{const o=e.slots.default&&e.slots.default();return o&&o.length&&o.some(fe)};function fe(t){return!(de.includes(t.type.toString())||pe.includes(t.type.name))}const _e=I({name:"LMarker",props:Rt,setup(t,e){const o=y(),i=y(!1),n=N($),s=S(Q);x(St,()=>{var r;return!!((r=o.value)!=null&&r.getElement())}),x(Ot,r=>{var u,p;const _=R((u=o.value)==null?void 0:u.getElement)&&((p=o.value)==null?void 0:p.getElement());_&&(_.innerHTML=r)}),x(Tt,r=>{var u;return((u=o.value)==null?void 0:u.setIcon)&&o.value.setIcon(r)});const{options:a,methods:l}=he(t,o,e),d={moveHandler:Vt(l.latLngSync)};return z(async()=>{const{marker:r,divIcon:u}=n?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]);me(a,e)&&(a.icon=u({className:""})),o.value=U(r(t.latLng,a));const{listeners:p}=J(e.attrs);o.value.on(p),o.value.on("move",d.moveHandler),H(l,o.value,t),s({...t,...l,leafletObject:o.value}),i.value=!0,E(()=>e.emit("ready",o.value))}),rt(()=>Lt(d)),{ready:i,leafletObject:o}},render(){return oe(this.ready,this.$slots)}}),ve={...Et,smoothFactor:{type:Number},noClip:{type:Boolean,default:void 0},latLngs:{type:Array,required:!0,custom:!0}},yt={...ve},Dt={...tt,content:{type:String,default:null}},ye=(t,e)=>{const{options:o,methods:i}=et(t),n={...i,setContent(s){e.value&&s!==null&&s!==void 0&&e.value.setContent(s)}};return{options:o,methods:n}},ge=t=>t.default?q("div",{ref:"root"},t.default()):null,be={...Dt,latLng:{type:[Object,Array],default:()=>[]}},we=(t,e)=>{const{options:o,methods:i}=ye(t,e);return{options:o,methods:i}},Ce=I({name:"LPopup",props:be,setup(t,e){const o=y(),i=y(null),n=N($),s=S(At),a=S(Pt),{options:l,methods:d}=we(t,o);return z(async()=>{const{popup:r}=n?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]);o.value=U(r(l)),t.latLng!==void 0&&o.value.setLatLng(t.latLng),H(d,o.value,t);const{listeners:u}=J(e.attrs);o.value.on(u),o.value.setContent(t.content||i.value||""),s(o.value),E(()=>e.emit("ready",o.value))}),rt(()=>{a()}),{root:i,leafletObject:o}},render(){return ge(this.$slots)}});({...yt,latLngs:{...yt.latLngs}});const pt={...dt,tms:{type:Boolean,default:void 0}
2,subdomains:{type:[String,Array],validator:t=>typeof t=="string"?!0:Array.isArray(t)?t.every(e=>typeof e=="string"):!1},detectRetina:{type:Boolean,default:void 0},url:{type:String,required:!0,custom:!0}},Le=(t,e,o)=>{const{options:i,methods:n}=It(t,e,o),s=Z(t,pt,i),a={...n};return{options:s,methods:a}},ke=I({props:pt,setup(t,e){const o=y(),i=N($),n=S(Q),{options:s,methods:a}=Le(t,o,e);return z(async()=>{const{tileLayer:l}=i?B.L:await k(()=>import("./leaflet-src.esm-C210bVOb.js"),[]);o.value=U(l(t.url,s));const{listeners:d}=J(e.attrs);o.value.on(d),H(a,o.value,t),n({...t,...a,leafletObject:o.value}),E(()=>e.emit("ready",o.value))}),{leafletObject:o}},render(){return null}});({...Dt});({...pt});const gt=3.2808399;function V(t,e){e.split(" ").forEach(o=>{t.classList.add(o)})}function P(t,e){e.split(" ").forEach(o=>{t.classList.remove(o)})}function nt(t,e,o){const i=document.createElement(t);return e&&(i.className=e),o?.append(i),i}function Se(t){const e={};for(const o in t){const i=t[o];Array.isArray(i)?e[o]=[...i]:i?.constructor===Object?e[o]={...i}:e[o]=i}return e}const Nt=C.Marker.extend({initialize(t,e){C.Util.setOptions(this,e),this._latlng=t,this.createIcon()},createIcon(){const t=this.options,e=[["stroke",t.color],["stroke-width",t.weight],["fill",t.fillColor],["fill-opacity",t.fillOpacity],["opacity",t.opacity]].filter(([,i])=>i!==void 0).map(([i,n])=>`${i}="${n}"`).join(" "),o=this._getIconSVG(t,e);this._locationIcon=new C.DivIcon({className:o.className,html:o.svg,iconSize:[o.w,o.h]}),this.setIcon(this._locationIcon)},_getIconSVG(t,e){const o=t.radius,i=t.weight,n=o+i,s=n*2;return{className:"leaflet-control-locate-location",svg:`<svg xmlns="http://www.w3.org/2000/svg" width="${s}" height="${s}" version="1.1" viewBox="-${n} -${n} ${s} ${s}"><circle r="${o}" ${e} /></svg>`,w:s,h:s}},setStyle(t){C.Util.setOptions(this,t),this.createIcon()}}),Oe=Nt.extend({initialize(t,e,o){C.Util.setOptions(this,o),this._latlng=t,this._heading=e,this.createIcon()},setHeading(t){this._heading=t},_getIconSVG(t,e){const o=t.radius,i=o+t.weight+t.depth,n=i*2,s=this._arrowPoints(o,t.width,t.depth,this._heading);return{className:"leaflet-control-locate-heading",svg:`<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" version="1.1" viewBox="-${i} -${i} ${n} ${n}"><path d="${s}" ${e} /></svg>`,w:n,h:n}},_arrowPoints(t,e,o,i){const n=(i-90)*Math.PI/180,s=Math.cos(n),a=Math.sin(n),l=-Math.sin(n),d=Math.cos(n),r=e/2,u=t*s,p=t*a,_=u+r*l,h=p+r*d,b=u-r*l,O=p-r*d,L=u+o*s,f=p+o*a;return`M ${_},${h} L ${b},${O} L ${L},${f} Z`}}),Te=C.Control.extend({options:{position:"topleft",layer:void 0,setView:"untilPanOrZoom",keepCurrentZoomLevel:!1,initialZoomLevel:!1,getLocationBounds(t){return t.bounds},flyTo:!1,clickBehavior:{inView:"stop",outOfView:"setView",inViewNotFollowing:"inView"},returnToPrevBounds:!1,cacheLocation:!0,drawCircle:!0,drawMarker:!0,showCompass:!0,markerClass:Nt,compassClass:Oe,circleStyle:{className:"leaflet-control-locate-circle",color:"#136AEC",fillColor:"#136AEC",fillOpacity:.15,weight:0},markerStyle:{className:"leaflet-control-locate-marker",color:"#fff",fillColor:"#2A93EE",fillOpacity:1,weight:3,opacity:1,radius:9},compassStyle:{fillColor:"#2A93EE",fillOpacity:1,weight:0,color:"#fff",opacity:1,radius:9,width:9,depth:6},followCircleStyle:{},followMarkerStyle:{},followCompassStyle:{},icon:"leaflet-control-locate-location-arrow",iconLoading:"leaflet-control-locate-spinner",iconElementTag:"span",textElementTag:"small",circlePadding:[0,0],metric:!0,createButtonCallback(t,e){const o=nt("a","leaflet-bar-part leaflet-bar-part-single",t);o.title=e.strings.title,o.href="#",o.setAttribute("role","button"),o.setAttribute("aria-label",e.strings.title);const i=nt(e.iconElementTag,e.icon,o);if(i.classList.add("leaflet-locate-icon"),e.strings.text!==void 0){const n=nt(e.textElementTag,"leaflet-locate-text",o);n.textContent=e.strings.text,o.classList.add("leaflet-locate-text-active"),o.parentNode.style.display="flex"}return{link:o,icon:i}},onLocationError(t){alert(t.message)},onLocationOutsideMapBounds(t){t.stop(),alert(t.options.strings.outsideMapBoundsMsg)},showPopup:!0,strings:{title:"Show me where I am",metersUnit:"meters",feetUnit:"feet",popup:"You are within {distance} {unit} from this point",outsideMapBoundsMsg:"You seem located outside the boundaries of the map"},locateOptions:{maxZoom:1/0,watch:!0,setView:!1}},initialize(t={}){this.options=Se(this.options);for(const e in t){const o=t[e],i=this.options[e];o?.constructor===Object&&i?.constructor===Object?Object.assign(i,o):this.options[e]=o}this.options.followMarkerStyle={...this.options.markerStyle,...this.options.followMarkerStyle},this.options.followCircleStyle={...this.options.circleStyle,...this.options.followCircleStyle},this.options.followCompassStyle={...this.options.compassStyle,...this.options.followCompassStyle}},onAdd(t){const e=nt("div","leaflet-control-locate leaflet-bar leaflet-control");this._container=e,this._map=t,this._layer=this.options.layer||new C.LayerGroup,this._layer.addTo(t),this._event=void 0,this._compassHeading=null,this._prevBounds=null;const o=this.options.createButtonCallback(e,this.options);return this._link=o.link,this._icon=o.icon,this._linkClickHandler=i=>{i.stopPropagation(),i.preventDefault(),this._onClick()},this._linkDblClickHandler=i=>i.stopPropagation(),this._link.addEventListener("click",this._linkClickHandler),this._link.addEventListener("dblclick",this._linkDblClickHandler),this._resetVariables(),this._map.on("unload",this._unload,this),e},onRemove(){this._link&&this._linkClickHandler&&this._link.removeEventListener("click",this._linkClickHandler),this._link&&this._linkDblClickHandler&&this._link.removeEventListener("dblclick",this._linkDblClickHandler),this._map&&this._map.off("unload",this._unload,this),this._linkClickHandler=null,this._linkDblClickHandler=null,this.stop()},_onClick(){this._justClicked=!0;const t=this._isFollowing();if(this._userPanned=!1,this._userZoomed=!1,this._active&&!this._event)this.stop();else if(this._active){const e=this.options.clickBehavior;let o=e.outOfView;switch(this._map.getBounds().contains(this._event.latlng)&&(o=t?e.inView:e.inViewNotFollowing),e[o]&&(o=e[o]),o){case"setView":this.setView();break;case"stop":this.stop(),this.options.returnToPrevBounds&&(this.options.flyTo?this._map.flyToBounds:this._map.fitBounds).bind(this._map)(this._prevBounds);break}}else this.options.returnToPrevBounds&&(this._prevBounds=this._map.getBounds()),this.start();this._updateContainerStyle()},start(){this._activate(),this._event&&(this._drawMarker(this._map),this.options.setView&&this.setView()),this._updateContainerStyle()}
2,stop(){this._deactivate(),this._cleanClasses(),this._resetVariables(),this._removeMarker()},stopFollowing(){this._userPanned=!0,this._updateContainerStyle(),this._drawMarker()},_activate(){this._active||!this._map||(this._map.locate(this.options.locateOptions),this._map.fire("locateactivate",this),this._active=!0,this._map.on("locationfound",this._onLocationFound,this),this._map.on("locationerror",this._onLocationError,this),this._map.on("dragstart",this._onDrag,this),this._map.on("zoomstart",this._onZoom,this),this._map.on("zoomend",this._onZoomEnd,this),this._activateCompass())},async _activateCompass(){if(!this.options.showCompass)return;const t="ondeviceorientationabsolute"in window;if(!t&&!("ondeviceorientation"in window))return;const e=t?"deviceorientationabsolute":"deviceorientation";if(DeviceOrientationEvent&&typeof DeviceOrientationEvent.requestPermission=="function")try{if(await DeviceOrientationEvent.requestPermission()!=="granted")return}catch(o){console.warn("DeviceOrientation permission denied or unavailable:",o);return}this._compassEventName=e,C.DomEvent.on(window,e,this._onDeviceOrientation,this)},_deactivate(){!this._active||!this._map||(this._map.stopLocate(),this._map.fire("locatedeactivate",this),this._active=!1,this.options.cacheLocation||(this._event=void 0),this._map.off("locationfound",this._onLocationFound,this),this._map.off("locationerror",this._onLocationError,this),this._map.off("dragstart",this._onDrag,this),this._map.off("zoomstart",this._onZoom,this),this._map.off("zoomend",this._onZoomEnd,this),this._deactivateCompass())},_deactivateCompass(){this._compassEventName&&(this._compassHeading=null,C.DomEvent.off(window,this._compassEventName,this._onDeviceOrientation,this),this._compassEventName=null)},_shouldKeepCurrentZoom(){const t=this.options.keepCurrentZoomLevel;if(Array.isArray(t)&&t.length===2){const e=this._map.getZoom(),[o,i]=t;return e>=o&&e<=i}return t===!0},setView(){if(this._drawMarker(),this._isOutsideMapBounds()){this._event=void 0,this.options.onLocationOutsideMapBounds(this);return}const{latlng:t}=this._event,e=this.options.flyTo;let o,i;this._justClicked&&this.options.initialZoomLevel!==!1?(o=e?"flyTo":"setView",i=[t,this.options.initialZoomLevel]):this._shouldKeepCurrentZoom()?(o=e?"flyTo":"panTo",i=[t]):(o=e?"flyToBounds":"fitBounds",i=[this.options.getLocationBounds(this._event),{padding:this.options.circlePadding,maxZoom:this.options.locateOptions.maxZoom}]),this._setViewIgnoringEvents(o,i)},_setViewIgnoringEvents(t,e){this._ignoreEvent=!0,this._map[t](...e),requestAnimationFrame(()=>{this._ignoreEvent=!1})},_drawCompass(){if(!this._event)return;const t=this._event.latlng;if(this.options.showCompass&&t&&this._compassHeading!==null){const e=this._isFollowing()?this.options.followCompassStyle:this.options.compassStyle;this._compass?(this._compass.setLatLng(t),this._compass.setHeading(this._compassHeading),this._compass.setStyle&&this._compass.setStyle(e)):this._compass=new this.options.compassClass(t,this._compassHeading,e).addTo(this._layer)}this._compass&&(!this.options.showCompass||this._compassHeading===null)&&(this._compass.removeFrom(this._layer),this._compass=null)},_drawMarker(){if(!this._event)return;const t=this._event.latlng,e=this._event.accuracy??0,o=this._isFollowing();if(this.options.drawCircle){const i=o?this.options.followCircleStyle:this.options.circleStyle;if(this._circle)this._circle.setLatLng(t).setRadius(e).setStyle(i);else{const n={...i,radius:e};this._circle=new C.Circle(t,n).addTo(this._layer)}}if(this.options.drawMarker){const i=o?this.options.followMarkerStyle:this.options.markerStyle;this._marker?(this._marker.setLatLng(t),this._marker.setStyle&&this._marker.setStyle(i)):this._marker=new this.options.markerClass(t,i).addTo(this._layer)}this._drawCompass(),this._bindPopup(t,e)},_bindPopup(t,e){const o=this.options.strings.popup;if(!this.options.showPopup||!o)return;let i,n,s;this.options.metric?(i=e.toFixed(0),n=this.options.strings.metersUnit,s=this._event?.altitude!=null?this._event.altitude.toFixed(1):"N/A"):(i=(e*gt).toFixed(0),n=this.options.strings.feetUnit,s=this._event?.altitude!=null?(this._event.altitude*gt).toFixed(1):"N/A");const a=this._event?.speed!=null?this._event.speed.toFixed(2):"N/A",l=this._event?.heading!=null?this._event.heading.toFixed(0):"N/A",d={distance:i,unit:n,lat:t.lat.toFixed(6),lng:t.lng.toFixed(6),altitude:s,speed:a,heading:l};let r;
2typeof o=="string"?r=C.Util.template(o,d):typeof o=="function"?r=o(d):r=o,this._marker&&this._marker.bindPopup(r)._popup.setLatLng(t),this._compass&&this._compass.bindPopup(r)._popup.setLatLng(t)},_removeMarker(){this._layer.clearLayers(),this._marker=void 0,this._circle=void 0,this._compass=void 0},_unload(){this.stop(),this._map&&this._map.off("unload",this._unload,this)},_setCompassHeading(t){Number.isFinite(t)?(this._compassHeading=Math.round(t),requestAnimationFrame(()=>this._drawCompass())):(this._compassHeading=null,this._drawCompass())},_onCompassNeedsCalibration(){this._setCompassHeading()},_onDeviceOrientation(t){this._active&&(t.webkitCompassHeading?this._setCompassHeading(t.webkitCompassHeading):t.alpha!==null&&this._setCompassHeading(360-t.alpha))},_onLocationError(t){if(t.code===3&&this.options.locateOptions.watch){this._timeoutCount=(this._timeoutCount||0)+1,this._map.fire("locationtimeout",{error:t,control:this,count:this._timeoutCount}),this._timeoutCount>=3&&this._container&&V(this._container,"locate-timeout");return}this._timeoutCount=0,this.stop(),this.options.onLocationError(t,this)},_onLocationFound(t){if(!(this._event?.latlng?.lat===t.latlng.lat&&this._event?.latlng?.lng===t.latlng.lng&&this._event?.accuracy===t.accuracy)&&this._active){switch(this._timeoutCount=0,this._container&&P(this._container,"locate-timeout"),this._event=t,this._drawMarker(),this._updateContainerStyle(),this._map.fire("locatelocationfound",{...t,control:this}),this.options.setView){case"once":this._justClicked&&this.setView();break;case"untilPan":this._userPanned||this.setView();break;case"untilPanOrZoom":!this._userPanned&&!this._userZoomed&&this.setView();break;case"always":this.setView();break}this._justClicked=!1}},_onDrag(){this._event&&!this._ignoreEvent&&(this._userPanned=!0,this._updateContainerStyle(),this._drawMarker())},_onZoom(){this._event&&!this._ignoreEvent&&(this._userZoomed=!0,this._updateContainerStyle(),this._drawMarker())},_onZoomEnd(){this._event&&this._drawCompass(),this._event&&!this._ignoreEvent&&this._marker&&!this._map.getBounds().pad(-.3).contains(this._marker.getLatLng())&&(this._userPanned=!0,this._updateContainerStyle(),this._drawMarker())},_isFollowing(){return this._active?this.options.setView==="always"?!0:this.options.setView==="untilPan"?!this._userPanned:this.options.setView==="untilPanOrZoom"?!this._userPanned&&!this._userZoomed:!1:!1},_isOutsideMapBounds(){return this._event===void 0?!1:this._map.options.maxBounds&&!this._map.options.maxBounds.contains(this._event.latlng)},_updateContainerStyle(){this._container&&(this._active&&!this._event?this._setClasses("requesting"):this._isFollowing()?this._setClasses("following"):this._active?this._setClasses("active"):this._cleanClasses())},_setClasses(t){switch(t){case"requesting":P(this._container,"active following"),V(this._container,"requesting"),P(this._icon,this.options.icon),V(this._icon,this.options.iconLoading);break;case"active":P(this._container,"requesting following"),V(this._container,"active"),P(this._icon,this.options.iconLoading),V(this._icon,this.options.icon);break;case"following":P(this._container,"requesting"),V(this._container,"active following"),P(this._icon,this.options.iconLoading),V(this._icon,this.options.icon);break}},_cleanClasses(){P(this._container,"requesting active following"),P(this._icon,this.options.iconLoading),V(this._icon,this.options.icon)},_resetVariables(){this._active=!1,this._justClicked=!1,this._timeoutCount=0,this._container&&P(this._container,"locate-timeout"),this._userPanned=!1,this._userZoomed=!1}}),Ae={name:"CrosshairsGpsIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}},Pe=["aria-hidden","aria-label"],Be=["fill","width","height"],Ee={d:"M12,8A4,4 0 0,1 16,12A4,4 0 0,1 12,16A4,4 0 0,1 8,12A4,4 0 0,1 12,8M3.05,13H1V11H3.05C3.5,6.83 6.83,3.5 11,3.05V1H13V3.05C17.17,3.5 20.5,6.83 20.95,11H23V13H20.95C20.5,17.17 17.17,20.5 13,20.95V23H11V20.95C6.83,20.5 3.5,17.17 3.05,13M12,5A7,7 0 0,0 5,12A7,7 0 0,0 12,19A7,7 0 0,0 19,12A7,7 0 0,0 12,5Z"},Me={key:0};function je(t,e,o,i,n,s){return D(),K("span",Zt(t.$attrs,{"aria-hidden":o.title?null:"true","aria-label":o.title,class:"material-design-icon crosshairs-gps-icon",role:"img",onClick:e[0]||(e[0]=a=>t.$emit("click",a))}),[(D(),K("svg",{fill:o.fillColor,class:"material-design-icon__svg",width:o.size,height:o.size,viewBox:"0 0 24 24"},[wt("path",Ee,[o.title?(D(),K("title",Me,Ct(o.title),1)):lt("",!0)])],8,Be))],16,Pe)}const xe=bt(Ae,[["render",je]]),Ie={class:"map-container"},Ve=I({__name:"LeafletMap",props:{readOnly:{type:Boolean,default:!0},coords:{},marker:{},options:{},updateDraggableMarkerCallback:{}},setup(t){const e=t,o={zoom:15,height:"100%",width:"100%"},i=y(o.zoom),n=y(),s=y(),a=y(),l=y(),d=A(()=>l.value?.$el.innerHTML),r=async()=>{s.value=n.value.leafletObject,u()},u=()=>
2{at.value&&s.value&&(a.value=new Te({strings:{title:G("Show me where I am")},position:"topleft",drawCircle:!1,drawMarker:!1,createButtonCallback(v,c){const m=C.DomUtil.create("a","leaflet-bar-part leaflet-bar-part-single",v);m.title=c.strings.title,m.href="#",m.setAttribute("role","button");const F=C.DomUtil.create("span","material-design-icon rss-icon",m);return F.setAttribute("aria-hidden","true"),F.setAttribute("role","img"),F.insertAdjacentHTML("beforeend",d.value),{link:m,icon:F}},...e.options}),a.value?.addTo(s.value))},p=async v=>{await E(),v.target.openPopup()},_=A(()=>({...o,...e.options})),h=A(()=>Number.parseFloat(e.coords?.split(";")[1]||"0")),b=A(()=>Number.parseFloat(e.coords?.split(";")[0]||"0")),O=A(()=>{if(Array.isArray(e.marker?.text))return e.marker?.text;if(e.marker?.text)return[e.marker?.text]}),L=v=>{g(v.latlng)},f=v=>{e.updateDraggableMarkerCallback&&e.updateDraggableMarkerCallback(v,i.value)},g=Jt(v=>{f(v)},1e3),w=v=>{i.value=v},{tiles:M}=$t(),{t:G}=Ft({useScope:"global"}),T=A(()=>M.value?.attribution??G("© The OpenStreetMap Contributors")),at=A(()=>window.isSecureContext);return(v,c)=>(D(),K("div",Ie,[W(j(ue),{zoom:_.value.zoom,style:Kt({height:_.value.height,width:_.value.width}),class:"leaflet-map",center:[h.value,b.value],onClick:L,"onUpdate:zoom":w,options:{zoomControl:!1},ref_key:"mapComponent",ref:n,onReady:r},{default:ot(()=>[W(j(ke),{url:j(M)?.endpoint,attribution:T.value,options:{referrerPolicy:"strict-origin-when-cross-origin"}},null,8,["url","attribution"]),W(j(le),{position:"topleft",zoomInTitle:v.$t("Zoom in"),zoomOutTitle:v.$t("Zoom out")},null,8,["zoomInTitle","zoomOutTitle"]),h.value&&b.value?(D(),mt(j(_e),{key:0,"lat-lng":[h.value,b.value],onAdd:p,"onUpdate:latLng":j(g),draggable:!t.readOnly},{default:ot(()=>[W(j(ce),{"icon-size":[48,48],"shadow-size":[30,30],"icon-anchor":[24,48],"popup-anchor":[-24,-40]},{default:ot(()=>[W(Ut,{size:48,class:"text-mbz-purple"})]),_:1}),O.value?(D(),mt(j(Ce),{key:0,options:{offset:new(j(C.Point))(22,8)}},{default:ot(()=>[(D(!0),K(qt,null,Gt(O.value,m=>(D(),K("span",{key:m},[Wt(Ct(m),1),c[0]||(c[0]=wt("br",null,null,-1))]))),128))]),_:1},8,["options"])):lt("",!0)]),_:1},8,["lat-lng","onUpdate:latLng","draggable"])):lt("",!0)]),_:1},8,["zoom","style","center"]),W(xe,{ref_key:"locationIcon",ref:l,class:"hidden"},null,512)]))}}),ze=bt(Ve,[["__scopeId","data-v-576ac797"]]);export{ze as default};
3//# sourceMappingURL=LeafletMap-CGcKThem.js.map

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.