import{d as C,l as i,G as v,o as c,b as f,w as e,q as a,L as x,P as y,A as p,I as t,W as w,ay as T,aw as h,B as S,b8 as B,n as k}from"./index-2e57ee69.js";import{V as U}from"./VAlert-69004a56.js";const N=k("span",null,"Compartir Oferta",-1),A=C({__name:"SharedCopyOfferModal",props:{modelValue:{type:Boolean},offerTitle:null,offerSlug:null},emits:["update:modelValue"],setup(m,{emit:s}){const l=m,o=i(!1),n=window.location.origin,r=i(`${n}/bolsa-laboral/${l.offerSlug}`);v(()=>l.offerSlug,()=>{r.value=`${n}/bolsa-laboral/${l.offerSlug}`});function V(){navigator.clipboard.writeText(r.value).then(()=>{o.value=!0,setTimeout(()=>o.value=!1,2e3)})}function _(){s("update:modelValue",!1)}function b(d){s("update:modelValue",d)}return(d,u)=>(c(),f(B,{"model-value":l.modelValue,"max-width":"500","onUpdate:modelValue":b,persistent:"",transition:"dialog-bottom-transition"},{default:e(()=>[a(x,null,{default:e(()=>[a(y,{class:"d-flex justify-space-between align-center"},{default:e(()=>[a(p,{start:""},{default:e(()=>[t("mdi-share-variant")]),_:1}),N,a(w,{icon:"",onClick:_,variant:"text"},{default:e(()=>[a(p,null,{default:e(()=>[t("mdi-close")]),_:1})]),_:1})]),_:1}),a(T,null,{default:e(()=>[a(h,{modelValue:l.offerSlug,"onUpdate:modelValue":u[0]||(u[0]=g=>l.offerSlug=g),label:"Enlace de la oferta",readonly:"","append-inner-icon":"mdi-content-copy","onClick:appendInner":V,class:"mb-4"},null,8,["modelValue"]),o.value?(c(),f(U,{key:0,type:"success",dense:"",border:"start",color:"success",class:"mt-2"},{default:e(()=>[t(" ¡Copiado al portapapeles! ")]),_:1})):S("",!0)]),_:1})]),_:1})]),_:1},8,["model-value"]))}}),D="/assets/empty_file_search-9fc136f6.svg";export{D as _,A as a};
