import{i as e,m as t}from"./sdks-Iaiwpgkq.js";var l=e=>e.charAt(0).toUpperCase()+e.slice(1),s=({houseNumber:e,street:t,city:l,state:s,country:i,postalCode:a})=>[`${e?""+(e&&t?`${e} `:`${e}`):""}${t||""}`,l,s,i,a].reduceRight((e,t)=>e&&t?`${t}, ${e}`:t||e||"")||"",i={all:()=>["schools"],list:e=>[...i.all(),e]};function a({lat:l,lng:s,geogId:a,include:n,radius:c=2e3,buffer:r=0,limit:u=30,attemptMinimum:o,includeCatchments:m=!1}){const{client:d}=e(),g={include:n,limit:u,attemptMinimum:o,include_catchments:m};return a?(g.geogId=a,g.buffer=r):(g.lat=l,g.lng=s,g.radius=c),t({queryKey:i.list(g),queryFn:async()=>d.getSchools(g),staleTime:1/0,enabled:!!(g&&g.include?.length&&(a||g.lat&&g.lng))})}export{l as n,s as r,a as t};
//# sourceMappingURL=useSchools-h48lA4bf.js.map