import{r as $}from"./index-CpO7mTKO.js";const u="https://zioinfo.co.kr",d="(주)지오정보기술";function S({title:a,description:o,path:m="",image:c="/logo.png",keywords:r=""}){$.useEffect(()=>{const l=a?`${a} | ${d}`:d,i=`${u}${m}`,p=c.startsWith("http")?c:`${u}${c}`;document.title=l;const t=(s,f,g)=>{let n=document.querySelector(s);if(!n){n=document.createElement("meta");const[h,E]=s.replace("meta[","").replace("]","").split("=");n.setAttribute(h,E.replace(/"/g,"")),document.head.appendChild(n)}n.setAttribute(f,g)};let e=document.querySelector('link[rel="canonical"]');e||(e=document.createElement("link"),e.rel="canonical",document.head.appendChild(e)),e.href=i,t('meta[name="description"]',"content",o),r&&t('meta[name="keywords"]',"content",r),t('meta[property="og:title"]',"content",l),t('meta[property="og:description"]',"content",o),t('meta[property="og:url"]',"content",i),t('meta[property="og:image"]',"content",p),t('meta[name="twitter:title"]',"content",l),t('meta[name="twitter:description"]',"content",o),t('meta[name="twitter:image"]',"content",p)},[a,o,m,c,r])}export{S as u};
