import{i as e}from"./chunk-aKtaBQYM.js";import{Ft as t}from"./mui-BgU4WrXF.js";import{n,r}from"./MapView-Bhqzv-Oc.js";var i=e(t(),1),a=e(r(),1),o=({latitude:e,longitude:t,positions:r,coordinates:o})=>((0,i.useEffect)(()=>{if(o||r){let e=o||r.map(e=>[e.longitude,e.latitude]);if(e.length){let t=e.reduce((e,t)=>e.extend(t),new a.default.LngLatBounds(e[0],e[0])),r=n.getCanvas();n.fitBounds(t,{padding:Math.min(r.width,r.height)*.1,duration:0})}}else n.jumpTo({center:[t,e],zoom:Math.max(n.getZoom(),10)})},[e,t,r,o]),null);export{o as t};