const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-hiUl-1yl.js","./index-BT5eY4j5.js","./index-CWUi-ziK.css"])))=>i.map(i=>d[i]);
import{aO as e,ab as r}from"./index-BT5eY4j5.js";async function s(){if(e.is.capacitor){const{Geolocation:t}=await r(async()=>{const{Geolocation:a}=await import("./index-hiUl-1yl.js");return{Geolocation:a}},__vite__mapDeps([0,1,2]),import.meta.url);let o=await t.checkPermissions();if((o.location==="prompt"||o.location==="prompt-with-rationale")&&(o=await t.requestPermissions()),o.location!=="granted")throw{code:GeolocationPositionError.PERMISSION_DENIED,message:"Location permission denied"};const{coords:i}=await t.getCurrentPosition();return{latitude:i.latitude,longitude:i.longitude}}return new Promise((t,o)=>navigator.geolocation.getCurrentPosition(({coords:{latitude:i,longitude:a}})=>t({latitude:i,longitude:a}),o))}export{s as g};
